Browse Source

提货提示

xiaomei 9 months ago
parent
commit
44e9cc9d05
3 changed files with 27 additions and 14 deletions
  1. 2 1
      src/language/en.json
  2. 1 1
      src/language/zh.json
  3. 24 12
      src/views/mine/teaRights.vue

+ 2 - 1
src/language/en.json

@@ -236,5 +236,6 @@
   "lang235": "Province, city and district:",
   "lang236": "Select province/city/district",
   "lang237": "Detailed address:",
-  "lang238": "Please fill in the information completely"
+  "lang238": "Please fill in the information completely",
+  "lang239": "XX Chabao logistics fee needs to be deducted when picking up goods"
 }

+ 1 - 1
src/language/zh.json

@@ -237,5 +237,5 @@
   "lang236": "选择省/市/区",
   "lang237": "详细地址:",
   "lang238": "请完整填写信息",
-  "lang239": ""
+  "lang239": "提货需要扣除 XX 茶宝物流费用"
 }

+ 24 - 12
src/views/mine/teaRights.vue

@@ -324,18 +324,30 @@ export default {
     },
     onSave(e) {
       // this.$toast('save');
-      homeApi.pickupOrder({ order_id: this.item.order_id, name: e.name, phone: e.tel, address: e.province + ' ' + e.city + ' ' + e.county + ' ' + e.addressDetail }).then(res => {
-        if (res.code == 200) {
-          this.addresPopop = false;
-          this.page = 1;
-          this.nft_list = [];
-          this.getNftList();
-          this.getUserInfo();
-          Notify({ type: 'success', message: this.$t('lang152') });
-        } else {
-          this.$toast(res.msg);
-        }
-      });
+      let _this = this
+      Dialog.confirm({
+        title: _this.$t('lang136'),
+        message: _this.$t('lang239').replace('XX', _this.logistics_freight),
+        confirmButtonText: _this.$t('lang111'),
+        cancelButtonText: _this.$t('lang135'),
+      })
+        .then(() => {
+          homeApi.pickupOrder({ order_id: _this.item.order_id, name: e.name, phone: e.tel, address: e.province + ' ' + e.city + ' ' + e.county + ' ' + e.addressDetail }).then(res => {
+            if (res.code == 200) {
+              _this.addresPopop = false;
+              _this.page = 1;
+              _this.nft_list = [];
+              _this.getNftList();
+              _this.getUserInfo();
+              Notify({ type: 'success', message: _this.$t('lang152') });
+            } else {
+              _this.$toast(res.msg);
+            }
+          });
+        })
+        .catch(() => {
+          // on cancel
+        });
     },
     // 转让
     transfer(item) {