cmy 9 months ago
parent
commit
1d4f51cc5a
1 changed files with 28 additions and 28 deletions
  1. 28 28
      src/pages/product/productAdd/index.vue

+ 28 - 28
src/pages/product/productAdd/index.vue

@@ -512,11 +512,11 @@
 							<template slot-scope="{ row, index }" slot="ot_price">
 								<InputNumber v-model="oneFormBatch[0].ot_price" :min="0" class="priceBox"></InputNumber>
 							</template>
-							<!-- <template slot-scope="{ row, index }" slot="stock">
+							<template slot-scope="{ row, index }" slot="stock">
 								<InputNumber v-model="oneFormBatch[0].stock" :min="0"
 									:disabled="formValidate.product_type == 1 || openErp" class="priceBox">
 								</InputNumber>
-							</template> -->
+							</template>
 							<template slot-scope="{ row, index }" slot="bar_code">
 								<Input v-model="oneFormBatch[0].bar_code"></Input>
 							</template>
@@ -584,18 +584,18 @@
 								<InputNumber v-model="manyFormValidate[index].ot_price" :min="0" class="priceBox">
 								</InputNumber>
 							</template>
-							<!-- <template slot-scope="{ row, index }" slot="stock">
+							<template slot-scope="{ row, index }" slot="stock">
 								<InputNumber v-model="manyFormValidate[index].stock" :min="0" :precision="0"
 									:disabled="formValidate.product_type == 1 || openErp" class="priceBox">
 								</InputNumber>
-							</template> -->
-							<!-- <template slot-scope="{ row, index }" slot="fictitious"
+							</template>
+							<template slot-scope="{ row, index }" slot="fictitious"
 								v-if="formValidate.product_type == 1">
 								<Button v-if="(!row.virtual_list || !row.virtual_list.length) && !row.stock"
 									@click="addVirtual(index, 'manyFormValidate')">添加卡密</Button>
 								<span v-else class="seeCatMy"
 									@click="seeVirtual(row, 'manyFormValidate', index)">已设置</span>
-							</template> -->
+							</template>
 							<template slot-scope="{ row, index }" slot="bar_code">
 								<Input v-model="manyFormValidate[index].bar_code"></Input>
 							</template>
@@ -695,14 +695,14 @@
 							</InputNumber>
 						</FormItem>
 						</Col>
-						<!-- <Col span="24" class="asterisk">
+						<Col span="24" class="asterisk">
 						<div class="asteriskInfo">*</div>
 						<FormItem label="库存:">
 							<InputNumber v-model="oneFormValidate[0].stock" :min="0" :max="99999999"
 								:disabled="formValidate.product_type == 1 || openErp" :precision="0" v-width="'50%'">
 							</InputNumber>
 						</FormItem>
-						</Col> -->
+						</Col>
 						<Col span="24" v-if="formValidate.product_type != 4">
 						<FormItem label="商品条形码:">
 							<Input v-model.trim="oneFormValidate[0].bar_code" v-width="'50%'"
@@ -873,9 +873,9 @@
 							<template slot-scope="{ row, index }" slot="ot_price">{{
                     oneFormValidate[0].ot_price
                   }}</template>
-							<!-- <template slot-scope="{ row, index }" slot="stock">{{
+							<template slot-scope="{ row, index }" slot="stock">{{
                     oneFormValidate[0].stock
-                  }}</template> -->
+                  }}</template>
 							<template slot-scope="{ row, index }" slot="bar_code">{{
                     oneFormValidate[0].bar_code
                   }}</template>
@@ -942,9 +942,9 @@
 							<template slot-scope="{ row, index }" slot="ot_price">{{
                     manyFormValidate[index].ot_price
                   }}</template>
-							<!-- <template slot-scope="{ row, index }" slot="stock">{{
+							<template slot-scope="{ row, index }" slot="stock">{{
                     manyFormValidate[index].stock
-                  }}</template> -->
+                  }}</template>
 							<template slot-scope="{ row, index }" slot="bar_code">{{
                     manyFormValidate[index].bar_code
                   }}</template>
@@ -1676,7 +1676,7 @@
 					settle_price: 0,
 					cost: 0,
 					ot_price: 0,
-					// stock: 0,
+					stock: 0,
 					bar_code: "",
 					code: "",
 					weight: 0,
@@ -1720,12 +1720,12 @@
 						align: "center",
 						minWidth: 95,
 					},
-					// {
-					// 	title: "库存",
-					// 	slot: "stock",
-					// 	align: "center",
-					// 	minWidth: 95,
-					// },
+					{
+						title: "库存",
+						slot: "stock",
+						align: "center",
+						minWidth: 95,
+					},
 					{
 						title: "商品条形码",
 						slot: "bar_code",
@@ -1829,7 +1829,7 @@
 						price: 0,
 						cost: 0,
 						ot_price: 0,
-						// stock: 0,
+						stock: 0,
 						bar_code: "",
 						code: "",
 					}, ],
@@ -1857,7 +1857,7 @@
 					settle_price: 0,
 					cost: 0,
 					ot_price: 0,
-					// stock: 0,
+					stock: 0,
 					bar_code: "",
 					code: "",
 					weight: 0,
@@ -2191,7 +2191,7 @@
 									settle_price: 0,
 									cost: 0,
 									ot_price: 0,
-									// stock: 0,
+									stock: 0,
 									bar_code: "",
 									code: "",
 									weight: 0,
@@ -2467,7 +2467,7 @@
 				j.settle_price = 0;
 				j.cost = 0;
 				j.ot_price = 0;
-				// j.stock = 0;
+				j.stock = 0;
 				j.bar_code = '';
 				j.code = '';
 				j.weight = 0;
@@ -2886,7 +2886,7 @@
 						settle_price: 0,
 						cost: 0,
 						ot_price: 0,
-						// stock: 0,
+						stock: 0,
 						bar_code: "",
 						code: "",
 						weight: 0,
@@ -3143,7 +3143,7 @@
 					settle_price: 0,
 					cost: 0,
 					ot_price: 0,
-					// stock: 0,
+					stock: 0,
 					bar_code: "",
 					code: "",
 					weight: 0,
@@ -3219,9 +3219,9 @@
 						if (this.oneFormBatch[0].ot_price > 0) {
 							this.$set(val, "ot_price", this.oneFormBatch[0].ot_price);
 						}
-						// if (this.oneFormBatch[0].stock > 0) {
-						// 	this.$set(val, "stock", this.oneFormBatch[0].stock);
-						// }
+						if (this.oneFormBatch[0].stock > 0) {
+							this.$set(val, "stock", this.oneFormBatch[0].stock);
+						}
 						if (this.oneFormBatch[0].bar_code !== "") {
 							this.$set(val, "bar_code", this.oneFormBatch[0].bar_code);
 						}