diff --git a/lib/home/home_page.dart b/lib/home/home_page.dart index 428699ab..2e7d8051 100644 --- a/lib/home/home_page.dart +++ b/lib/home/home_page.dart @@ -537,9 +537,11 @@ class HomePageState extends State with AutomaticKeepAliveClientMixin { // }), ///特惠专区 + if(coupons != null && coupons.length != 0) DiscountZone(coupons), ///特惠专区-推荐商品展示 + if(homeRank != null && homeRank.commodityZone.length != 0) HomeRecommendGoods(homeRank), ///助农专区 @@ -550,6 +552,7 @@ class HomePageState extends State with AutomaticKeepAliveClientMixin { WelfareCore(), ///吃喝玩商品热销榜 + if(homeRank != null && homeRank.commodityList.length != 0) TopSellingList(homeRank), // ///店铺推荐 diff --git a/lib/order/exchange_order_page.dart b/lib/order/exchange_order_page.dart index 11582c62..57e635cc 100644 --- a/lib/order/exchange_order_page.dart +++ b/lib/order/exchange_order_page.dart @@ -728,97 +728,97 @@ class _ExchangeOrderPage extends State { ], ), ), - Container( - margin: EdgeInsets.only(left: 16, right: 16, bottom: 8), - padding: EdgeInsets.all(20), - decoration: BoxDecoration( - color: Colors.white, - boxShadow: [ - BoxShadow( - color: Colors.black.withAlpha(12), - offset: Offset(0, 3), - blurRadius: 14, - spreadRadius: 0, - ) - ], - borderRadius: BorderRadius.all(Radius.circular(8)), - ), - child: Column( - children: [ - Row( - children: [ - Expanded( - child: Text( - "兑换数量", - style: TextStyle( - fontWeight: MyFontWeight.regular, - fontSize: 14.sp, - color: Color(0xFF353535)), - )), - InkWell( - onTap: () { - setState(() { - if (buyNum > 1) buyNum -= 1; - }); - }, - child: Image.asset( - "assets/image/reduce.webp", - width: 22, - height: 22, - ), - ), - Container( - width: 30, - alignment: Alignment.center, - child: Text( - buyNum.toString(), - style: TextStyle( - color: Colors.black, - fontSize: 14.sp, - fontWeight: MyFontWeight.medium, - ), - ), - ), - InkWell( - onTap: () { - setState(() { - if (widget.arguments["payType"] == 1 - ? (double.parse(widget - .arguments["oneBean"]) * - (buyNum + 1)) > - double.parse(happyBean) - : (widget.arguments["payType"] == 2 - ? (double.parse(widget.arguments[ - "onePrice"]) * - (buyNum + 1)) > - double.parse(points) - : (widget.arguments["price"] == - null || - widget.arguments["price"] == - "0" - ? false - : (double.parse(widget - .arguments["price"]) * - (buyNum + 1)) > - double.parse(points)))) { - SmartDialog.showToast("您的积分不足", - alignment: Alignment.center); - return; - } - buyNum += 1; - }); - }, - child: Image.asset( - "assets/image/add.webp", - width: 22, - height: 22, - ), - ), - ], - ), - ], - ), - ), + // Container( + // margin: EdgeInsets.only(left: 16, right: 16, bottom: 8), + // padding: EdgeInsets.all(20), + // decoration: BoxDecoration( + // color: Colors.white, + // boxShadow: [ + // BoxShadow( + // color: Colors.black.withAlpha(12), + // offset: Offset(0, 3), + // blurRadius: 14, + // spreadRadius: 0, + // ) + // ], + // borderRadius: BorderRadius.all(Radius.circular(8)), + // ), + // child: Column( + // children: [ + // Row( + // children: [ + // Expanded( + // child: Text( + // "兑换数量", + // style: TextStyle( + // fontWeight: MyFontWeight.regular, + // fontSize: 14.sp, + // color: Color(0xFF353535)), + // )), + // InkWell( + // onTap: () { + // setState(() { + // if (buyNum > 1) buyNum -= 1; + // }); + // }, + // child: Image.asset( + // "assets/image/reduce.webp", + // width: 22, + // height: 22, + // ), + // ), + // Container( + // width: 30, + // alignment: Alignment.center, + // child: Text( + // buyNum.toString(), + // style: TextStyle( + // color: Colors.black, + // fontSize: 14.sp, + // fontWeight: MyFontWeight.medium, + // ), + // ), + // ), + // InkWell( + // onTap: () { + // setState(() { + // if (widget.arguments["payType"] == 1 + // ? (double.parse(widget + // .arguments["oneBean"]) * + // (buyNum + 1)) > + // double.parse(happyBean) + // : (widget.arguments["payType"] == 2 + // ? (double.parse(widget.arguments[ + // "onePrice"]) * + // (buyNum + 1)) > + // double.parse(points) + // : (widget.arguments["price"] == + // null || + // widget.arguments["price"] == + // "0" + // ? false + // : (double.parse(widget + // .arguments["price"]) * + // (buyNum + 1)) > + // double.parse(points)))) { + // SmartDialog.showToast("您的积分不足", + // alignment: Alignment.center); + // return; + // } + // buyNum += 1; + // }); + // }, + // child: Image.asset( + // "assets/image/add.webp", + // width: 22, + // height: 22, + // ), + // ), + // ], + // ), + // ], + // ), + // ), if (widget.arguments["payType"] == 4 || (widget.arguments["payType"] == 3 && widget.arguments["money"] != "0.00")) @@ -1170,7 +1170,7 @@ class _ExchangeOrderPage extends State { "payType": (widget.arguments["payType"] == 1) ? 2 : ((widget.arguments["payType"] == 2) ? 1 : 3), - "number": buyNum, + "number": 1, "useTyped": widget.arguments["useTyped"], "payChannel": handleNeedPay().contains("元") ? (checkIndex == 3 ? "1" : "4") : "0",