Browse Source

助农商品也不bug更改;

首页轮播间隔更改;
我的页面轮播间隔更改;
会员价暂时隐藏;
门店列表0元显示处理;
dart3
wurong 6 months ago
parent
commit
421ac62492
  1. 19
      lib/home/help_farmers/help_farmers_page.dart
  2. 4
      lib/home/home_page.dart
  3. 2
      lib/mine/mine_page.dart
  4. 2
      lib/retrofit/retrofit_api.dart
  5. 41
      lib/store/store_view/product_sku.dart
  6. 9
      lib/store/store_view/store_info.dart
  7. 23
      lib/union/union_list.dart

19
lib/home/help_farmers/help_farmers_page.dart

@ -31,6 +31,7 @@ class _HelpFarmersPage extends State<HelpFarmersPage> {
final RefreshController refreshController = RefreshController(); final RefreshController refreshController = RefreshController();
List<Farmers> farmersList = []; List<Farmers> farmersList = [];
int tabIndex = 0; int tabIndex = 0;
int farmersListData = 0;
@override @override
void initState() { void initState() {
@ -57,10 +58,11 @@ class _HelpFarmersPage extends State<HelpFarmersPage> {
}); });
if (baseData?.isSuccess ?? false) { if (baseData?.isSuccess ?? false) {
farmersList.clear(); farmersList.clear();
farmersList.addAll(baseData!.data ?? []); farmersList.addAll(baseData?.data ?? []);
refreshController.refreshCompleted(); refreshController.refreshCompleted();
} else { } else {
refreshController.refreshFailed(); refreshController.refreshFailed();
farmersListData = 1;
} }
} finally { } finally {
setState(() {}); setState(() {});
@ -100,7 +102,9 @@ class _HelpFarmersPage extends State<HelpFarmersPage> {
centerTitle: true, centerTitle: true,
flexibleSpace: FlexibleSpaceBar( flexibleSpace: FlexibleSpaceBar(
background: MImage( background: MImage(
farmersList[tabIndex].agriculturaListImg ?? "", farmersList.isEmpty
? ""
: (farmersList[tabIndex].agriculturaListImg ?? ""),
fit: BoxFit.fill, fit: BoxFit.fill,
width: double.infinity, width: double.infinity,
height: 354.h, height: 354.h,
@ -127,7 +131,7 @@ class _HelpFarmersPage extends State<HelpFarmersPage> {
// //
indicatorColor: Colors.white, indicatorColor: Colors.white,
//tab排放方向 //tab排放方向
tabAlignment:TabAlignment.start, tabAlignment: TabAlignment.start,
//线 //线
dividerHeight: 0, dividerHeight: 0,
labelColor: Colors.white, labelColor: Colors.white,
@ -146,9 +150,8 @@ class _HelpFarmersPage extends State<HelpFarmersPage> {
indicatorSize: TabBarIndicatorSize.label, indicatorSize: TabBarIndicatorSize.label,
// //
tabs: farmersList tabs: farmersList
?.map((e) => MyTab(text: "${e.typeName}")) .map((e) => MyTab(text: "${e.typeName}"))
.toList() ?? .toList(),
[],
onTap: (index) { onTap: (index) {
// queryConfig("AgriculturalList"); // queryConfig("AgriculturalList");
tabIndex = index; tabIndex = index;
@ -172,8 +175,8 @@ class _HelpFarmersPage extends State<HelpFarmersPage> {
return Container( return Container(
color: Colors.white, color: Colors.white,
padding: EdgeInsets.symmetric(horizontal: 10.w), padding: EdgeInsets.symmetric(horizontal: 10.w),
child: (farmersList.isNotEmpty && child: (farmersList.isEmpty ||
(farmersList[tabIndex].goodList?.isEmpty ?? false)) (farmersList[tabIndex].goodList ?? []).isEmpty)
? NoDataView( ? NoDataView(
src: "assets/image/xiao_fei.webp", src: "assets/image/xiao_fei.webp",
isShowBtn: false, isShowBtn: false,

4
lib/home/home_page.dart

@ -582,7 +582,7 @@ class HomePageState extends State<HomePage> with AutomaticKeepAliveClientMixin {
), ),
autoplay: true, autoplay: true,
duration: 1000, duration: 1000,
autoplayDelay: 3000, autoplayDelay: 17000,
physics: BouncingScrollPhysics(), physics: BouncingScrollPhysics(),
itemBuilder: (context, position) { itemBuilder: (context, position) {
return InkWell( return InkWell(
@ -679,7 +679,7 @@ class HomePageState extends State<HomePage> with AutomaticKeepAliveClientMixin {
), ),
autoplay: true, autoplay: true,
duration: 1000, duration: 1000,
autoplayDelay: 2500, autoplayDelay: 10000,
itemBuilder: (context, position) { itemBuilder: (context, position) {
return InkWell( return InkWell(
onTap: () { onTap: () {

2
lib/mine/mine_page.dart

@ -455,7 +455,7 @@ class MinePageState extends State<MinePage> with AutomaticKeepAliveClientMixin {
), ),
autoplay: true, autoplay: true,
duration: 1000, duration: 1000,
autoplayDelay: 2000, autoplayDelay: 10000,
itemBuilder: (context, position) { itemBuilder: (context, position) {
return InkWell( return InkWell(
onTap: () { onTap: () {

2
lib/retrofit/retrofit_api.dart

@ -63,7 +63,7 @@ import 'package:huixiang/login/captcha/click_word_captcha.dart';
part 'retrofit_api.g.dart'; part 'retrofit_api.g.dart';
const localBaseUrl = "http://192.168.10.54:8766/app/";/// const localBaseUrl = "https://pos.platform.lotus-wallet.com/app//";///
// const localBaseUrl = "http://platform.test.api.lotus-wallet.com/app/";/// // const localBaseUrl = "http://platform.test.api.lotus-wallet.com/app/";///
const serviceBaseUrl = "https://pos.platform.lotus-wallet.com/app/";///线 const serviceBaseUrl = "https://pos.platform.lotus-wallet.com/app/";///线

41
lib/store/store_view/product_sku.dart

@ -158,26 +158,27 @@ class _ProductSku extends State<ProductSku> {
), ),
), ),
), ),
Row( ///
children: [ // Row(
Text( // children: [
S.of(context).huiyuanjia, // Text(
style: TextStyle( // S.of(context).huiyuanjia,
color: Color(0xFFFF7A1A), // style: TextStyle(
fontSize: 13.sp, // color: Color(0xFFFF7A1A),
fontWeight: MyFontWeight.medium, // fontSize: 13.sp,
), // fontWeight: MyFontWeight.medium,
), // ),
Text( // ),
selectedPrice, // Text(
style: TextStyle( // selectedPrice,
color: Color(0xFFFF7A1A), // style: TextStyle(
fontSize: 14.sp, // color: Color(0xFFFF7A1A),
fontWeight: MyFontWeight.medium, // fontSize: 14.sp,
), // fontWeight: MyFontWeight.medium,
), // ),
], // ),
), // ],
// ),
], ],
), ),
), ),

9
lib/store/store_view/store_info.dart

@ -113,7 +113,9 @@ class _StoreInfoView extends State<StoreInfoView> {
), ),
Row( Row(
children: [ children: [
Text( if( widget.storeInfo?.perCapitaConsumption != null && ( widget.storeInfo?.perCapitaConsumption ?? "") != "0")
Padding(padding:EdgeInsets.only(right:20.w),
child: Text(
S.of(context).ren(widget.storeInfo?.perCapitaConsumption ?? ""), S.of(context).ren(widget.storeInfo?.perCapitaConsumption ?? ""),
overflow: TextOverflow.ellipsis, overflow: TextOverflow.ellipsis,
style: TextStyle( style: TextStyle(
@ -121,10 +123,7 @@ class _StoreInfoView extends State<StoreInfoView> {
fontWeight: MyFontWeight.medium, fontWeight: MyFontWeight.medium,
color: Color(0xFF353535), color: Color(0xFF353535),
), ),
), ),),
SizedBox(
width: 20.w,
),
]..addAll(itemServer(widget.storeInfo?.businessService ?? "")), ]..addAll(itemServer(widget.storeInfo?.businessService ?? "")),
), ),
Text( Text(

23
lib/union/union_list.dart

@ -314,17 +314,18 @@ class _UnionList extends State<UnionList> with AutomaticKeepAliveClientMixin {
SizedBox(height: 6.h), SizedBox(height: 6.h),
Row( Row(
children: [ children: [
Text( if(store.perCapitaConsumption != null && (store.perCapitaConsumption ?? "") != "0")
S.of(context).ren( Padding(padding:EdgeInsets.only(right:22.w),
store.perCapitaConsumption ?? "", child:Text(
), S.of(context).ren(
style: TextStyle( store.perCapitaConsumption ?? "",
color: Color(0xFF4D4D4D), ),
fontSize: 12.sp, style: TextStyle(
fontWeight: MyFontWeight.regular, color: Color(0xFF4D4D4D),
), fontSize: 12.sp,
), fontWeight: MyFontWeight.regular,
SizedBox(width: 22.w), ),
)),
Image.asset( Image.asset(
"assets/image/icon_union_location_black.webp", "assets/image/icon_union_location_black.webp",
fit: BoxFit.fill, fit: BoxFit.fill,

Loading…
Cancel
Save