Browse Source

云仓模式下,次日达库存也走正常销售单

liyuan 2 weeks ago
parent
commit
4cc5e78ee7
1 changed files with 20 additions and 0 deletions
  1. 20 0
      pages/views/buyGoods/commodityDetails.vue

+ 20 - 0
pages/views/buyGoods/commodityDetails.vue

@@ -301,6 +301,26 @@
 					this.adminShow = true
 					return
 				}
+        if (this.cloudWarehouse === 1) {
+          uni.showLoading({
+            title: '加载中',
+            mask: true
+          });
+          addToCart({
+            ...this.form,
+            whetherIntegral: '0',
+            detailsText: ''
+          }).then(res => {
+            uni.hideLoading();
+            uni.showToast({
+              title: "加入购物车成功",
+              icon: "none",
+            });
+          }).catch(err => {
+            uni.hideLoading();
+          })
+          return;
+        }
 				if (this.inventoryDataForm.storeInventory == 0 && this.inventoryDataForm.storeInventoryShare > 0) {
 					let _this = this
 					uni.showModal({