Kaynağa Gözat

1、商品详情数据未加载完毕点击进行提示

tags/0.0.15+9^0
PH2 3 yıl önce
ebeveyn
işleme
1c8938b464
3 değiştirilmiş dosya ile 14 ekleme ve 2 silme
  1. +4
    -0
      lib/widgets/goods_details/coupon/counpon_widget.dart
  2. +8
    -2
      lib/widgets/goods_details/footer/goods_details_footer_widget.dart
  3. +2
    -0
      lib/widgets/goods_details/store/store_widget.dart

+ 4
- 0
lib/widgets/goods_details/coupon/counpon_widget.dart Dosyayı Görüntüle

@@ -58,6 +58,10 @@ class _CounponWidgetContainerState extends State<CounponWidgetContainer> {

/// 点击领取
void _onJump(CounponModel model) async{
if (EmptyUtil.isEmpty(model?.convertArgs)) {
Fluttertoast.showToast(msg: '商品信息正在加载中,请稍后再试~');
return;
}
TurnChainUtil.openReceiveCoupon(context, _user, model?.good_id, model.provider, model?.convertArgs?.toJson());
}



+ 8
- 2
lib/widgets/goods_details/footer/goods_details_footer_widget.dart Dosyayı Görüntüle

@@ -100,7 +100,10 @@ class _GoodsDetailsFooterContainerState extends State<_GoodsDetailsFooterContain

/// 分享
void _shareOnClick(GoodsDetailsFooterModel model) async {
if (EmptyUtil.isEmpty(model?.share_value)) return;
if (EmptyUtil.isEmpty(model?.share_value)) {
Fluttertoast.showToast(msg: '商品信息正在加载中,请稍后再试~');
return;
}
Map<String, dynamic> result = await TurnChainUtil.getShareTurnChain(context, _user, model?.good_id, model.provider, model.convertArgs.toJson());
if (!EmptyUtil.isEmpty(result)) {
model.shareUrlArgs.buyUrl = result['open_app_url'];
@@ -110,7 +113,10 @@ class _GoodsDetailsFooterContainerState extends State<_GoodsDetailsFooterContain

/// 自购省
void _saveMoneyOnClick(GoodsDetailsFooterModel model) async {
if (EmptyUtil.isEmpty(model?.self_buy_value)) return;
if (EmptyUtil.isEmpty(model?.self_buy_value)) {
Fluttertoast.showToast(msg: '商品信息正在加载中,请稍后再试~');
return;
}
await TurnChainUtil.openReceiveCoupon(context, _user, model?.good_id, model?.provider, model?.convertArgs?.toJson(), isFree: widget?.isFree);
}



+ 2
- 0
lib/widgets/goods_details/store/store_widget.dart Dosyayı Görüntüle

@@ -56,6 +56,8 @@ class _StoreContainerState extends State<StoreContainer> {
Logger.log("店铺:" + model.shop_url);
if (!EmptyUtil.isEmpty(model.shop_url)) {
RouterUtil.openWebview(model.shop_url, context);
} else {
Fluttertoast.showToast(msg: '商品信息正在加载中,请稍后再试~');
}
}



Yükleniyor…
İptal
Kaydet