|
@@ -31,7 +31,7 @@
|
|
|
style="width: 100%; margin-top: 20px"
|
|
|
v-if="shopInfo.scope == 0"
|
|
|
>
|
|
|
- <el-table-column prop="name" label="规格名称" width="160">
|
|
|
+ <el-table-column prop="name" label="规格名称" width="140">
|
|
|
<template slot-scope="scope">
|
|
|
<el-input
|
|
|
v-model="scope.row.skuSpecsList[0].specsName"
|
|
@@ -43,7 +43,7 @@
|
|
|
/>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
- <el-table-column prop="address" label="规格内容" width="160">
|
|
|
+ <el-table-column prop="address" label="规格内容" width="140">
|
|
|
<template slot-scope="scope">
|
|
|
<el-input
|
|
|
v-model="scope.row.skuSpecsList[0].specsValue"
|
|
@@ -55,7 +55,7 @@
|
|
|
/>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
- <el-table-column prop="name" label="库存" width="160">
|
|
|
+ <el-table-column prop="name" label="库存" width="140">
|
|
|
<template slot-scope="scope">
|
|
|
<el-input-number
|
|
|
:controls="false"
|
|
@@ -68,7 +68,7 @@
|
|
|
</el-input-number>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
- <el-table-column prop="address" label="起批量" width="160">
|
|
|
+ <el-table-column prop="address" label="起批量" width="140">
|
|
|
<template slot-scope="scope">
|
|
|
<el-input-number
|
|
|
:controls="false"
|
|
@@ -83,7 +83,7 @@
|
|
|
</el-input-number>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
- <el-table-column prop="address" label="收购价" width="160">
|
|
|
+ <el-table-column prop="address" label="收购价" width="140">
|
|
|
<template slot-scope="scope">
|
|
|
<el-input-number
|
|
|
:controls="false"
|
|
@@ -96,7 +96,7 @@
|
|
|
</el-input-number>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
- <el-table-column prop="address" label="人工费" width="160">
|
|
|
+ <el-table-column prop="address" label="人工费" width="140">
|
|
|
<template slot-scope="scope">
|
|
|
<el-input-number
|
|
|
:controls="false"
|
|
@@ -109,7 +109,7 @@
|
|
|
</el-input-number>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
- <el-table-column prop="address" label="代办费" width="160">
|
|
|
+ <el-table-column prop="address" label="代办费" width="140">
|
|
|
<template slot-scope="scope">
|
|
|
<el-input-number
|
|
|
:controls="false"
|
|
@@ -122,7 +122,7 @@
|
|
|
</el-input-number>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
- <el-table-column prop="address" label="材料费" width="160">
|
|
|
+ <el-table-column prop="address" label="材料费" width="140">
|
|
|
<template slot-scope="scope">
|
|
|
<el-input-number
|
|
|
:controls="false"
|
|
@@ -140,12 +140,12 @@
|
|
|
{{ computePrice(scope.row) }}元/{{ form.unit }}
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
- <el-table-column label="规格重量" width="160">
|
|
|
+ <el-table-column label="净重量(kg)" width="160">
|
|
|
<template slot-scope="scope">
|
|
|
<el-input-number
|
|
|
:controls="false"
|
|
|
v-model="scope.row.weight"
|
|
|
- placeholder="请输入单个规格重量"
|
|
|
+ placeholder="净重量"
|
|
|
clearable
|
|
|
@input="passValue"
|
|
|
>
|
|
@@ -153,7 +153,13 @@
|
|
|
</el-input-number>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
- <el-table-column prop="address" label="操作" width="160">
|
|
|
+ <el-table-column label="是否上架">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ <el-switch v-model="sj"> </el-switch>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+
|
|
|
+ <el-table-column prop="address" label="操作">
|
|
|
<template slot-scope="scope">
|
|
|
<el-button
|
|
|
type="text"
|
|
@@ -276,12 +282,12 @@
|
|
|
<el-table-column prop="address" label="商品单价" width="80" v-else>
|
|
|
<template slot-scope="scope">
|
|
|
{{
|
|
|
- scope.row.skuPriceList[0].price ? scope.row.skuPriceList[0].price : 0
|
|
|
+ scope.row.skuPriceList[0].price ? scope.row.skuPriceList[0].price.toFixed(2) : 0
|
|
|
}}
|
|
|
元/{{ form.unit }}
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
- <el-table-column label="净重量" width="160">
|
|
|
+ <el-table-column label="净重量(kg )" width="160">
|
|
|
<template slot-scope="scope">
|
|
|
<el-input-number
|
|
|
:controls="false"
|
|
@@ -294,6 +300,11 @@
|
|
|
</el-input-number>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
+ <el-table-column label="是否上架">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ <el-switch v-model="sj"> </el-switch>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
<el-table-column prop="address" label="操作" width="160">
|
|
|
<template slot-scope="scope">
|
|
|
<el-button
|
|
@@ -391,7 +402,7 @@
|
|
|
</div>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
- <el-col :span="24" style="margin-top: 20px" v-if="shopInfo.scope == 0">
|
|
|
+ <el-col :span="24" style="margin-top: 20px" v-if="showCom">
|
|
|
<el-form-item prop="freeShipping">
|
|
|
<span slot="label">运费</span>
|
|
|
<div class="main1">
|
|
@@ -485,6 +496,9 @@ export default {
|
|
|
},
|
|
|
shopInfo: {},
|
|
|
saleType: undefined,
|
|
|
+ sj: true,
|
|
|
+
|
|
|
+ showCom: true,
|
|
|
};
|
|
|
},
|
|
|
mounted() {
|
|
@@ -532,13 +546,18 @@ export default {
|
|
|
},
|
|
|
},
|
|
|
methods: {
|
|
|
+ setShowCom(val) {
|
|
|
+ this.showCom = val;
|
|
|
+ console.log(this.showCom);
|
|
|
+
|
|
|
+ },
|
|
|
compilatePrice(data) {
|
|
|
if (data.price) {
|
|
|
- return data.price;
|
|
|
+ return data.price.toFixed(2);
|
|
|
} else if (data.originalPrice) {
|
|
|
- return data.originalPrice;
|
|
|
+ return data.originalPrice.toFixed(2);
|
|
|
} else if (data.originalPrice && data.price) {
|
|
|
- return data.price;
|
|
|
+ return data.price.toFixed(2);
|
|
|
}
|
|
|
},
|
|
|
formvalidate() {
|
|
@@ -588,11 +607,11 @@ export default {
|
|
|
data.skuCost.materialFee
|
|
|
) {
|
|
|
return (
|
|
|
- parseInt(data.skuCost.purchaseFee) +
|
|
|
- parseInt(data.skuCost.laborFee) +
|
|
|
- parseInt(data.skuCost.agencyFee) +
|
|
|
- parseInt(data.skuCost.materialFee)
|
|
|
- );
|
|
|
+ Number(data.skuCost.purchaseFee) +
|
|
|
+ Number(data.skuCost.laborFee) +
|
|
|
+ Number(data.skuCost.agencyFee) +
|
|
|
+ Number(data.skuCost.materialFee)
|
|
|
+ ).toFixed(2);
|
|
|
} else {
|
|
|
return 0;
|
|
|
}
|
|
@@ -600,7 +619,7 @@ export default {
|
|
|
console.log("1231231", data);
|
|
|
}
|
|
|
},
|
|
|
-
|
|
|
+
|
|
|
passValue(val) {
|
|
|
if (this.shopInfo.scope == 0) {
|
|
|
this.form.skuList.forEach((e) => {
|
|
@@ -610,8 +629,7 @@ export default {
|
|
|
a.lowestPrice = this.computePrice(e);
|
|
|
});
|
|
|
});
|
|
|
- }
|
|
|
- else {
|
|
|
+ } else {
|
|
|
if (this.saleType != 4) {
|
|
|
this.form.skuList.forEach((e) => {
|
|
|
e.skuPriceList.forEach((a) => {
|