|
@@ -13,7 +13,10 @@
|
|
:saleModels="form.saleModel"
|
|
:saleModels="form.saleModel"
|
|
></salesInfo>
|
|
></salesInfo>
|
|
<el-descriptions title="商品详情" column="1"> </el-descriptions>
|
|
<el-descriptions title="商品详情" column="1"> </el-descriptions>
|
|
- <productInfo @updateValue="updateValue" ref="productRefs"></productInfo>
|
|
|
|
|
|
+ <productInfo
|
|
|
|
+ @updateValue="updateValue"
|
|
|
|
+ ref="productRefs"
|
|
|
|
+ ></productInfo>
|
|
|
|
|
|
<div class="dialog-footer" style="text-align: center">
|
|
<div class="dialog-footer" style="text-align: center">
|
|
<el-button @click="submitCancel">取 消</el-button>
|
|
<el-button @click="submitCancel">取 消</el-button>
|
|
@@ -21,7 +24,9 @@
|
|
>发 布</el-button
|
|
>发 布</el-button
|
|
>
|
|
>
|
|
|
|
|
|
- <el-button type="primary" @click="submitFormDraft">存入草稿箱</el-button>
|
|
|
|
|
|
+ <el-button type="primary" @click="submitFormDraft"
|
|
|
|
+ >存入草稿箱</el-button
|
|
|
|
+ >
|
|
</div>
|
|
</div>
|
|
</el-col>
|
|
</el-col>
|
|
<phoneView style="position: absolute; bottom: -80px; right: 50px">
|
|
<phoneView style="position: absolute; bottom: -80px; right: 50px">
|
|
@@ -63,7 +68,9 @@
|
|
class="price"
|
|
class="price"
|
|
:key="item"
|
|
:key="item"
|
|
v-for="item in form.skuList ? form.skuList.slice(0, 1) : []"
|
|
v-for="item in form.skuList ? form.skuList.slice(0, 1) : []"
|
|
- >{{ item.skuPriceList ? item.skuPriceList[0].price : 0 }}元</span
|
|
|
|
|
|
+ >{{
|
|
|
|
+ item.skuPriceList ? item.skuPriceList[0].price : 0
|
|
|
|
+ }}元</span
|
|
>
|
|
>
|
|
|
|
|
|
<span>/{{ form.unit }}</span>
|
|
<span>/{{ form.unit }}</span>
|
|
@@ -76,7 +83,9 @@
|
|
<div v-for="(item, index) in form.skuList" :key="index">
|
|
<div v-for="(item, index) in form.skuList" :key="index">
|
|
<div class="price_info">
|
|
<div class="price_info">
|
|
<span
|
|
<span
|
|
- >{{ item.skuSpecsList[0] ? item.skuSpecsList[0].specsName : "" }}
|
|
|
|
|
|
+ >{{
|
|
|
|
+ item.skuSpecsList[0] ? item.skuSpecsList[0].specsName : ""
|
|
|
|
+ }}
|
|
{{
|
|
{{
|
|
item.skuSpecsList[0].specsValue
|
|
item.skuSpecsList[0].specsValue
|
|
? item.skuSpecsList[0].specsValue
|
|
? item.skuSpecsList[0].specsValue
|
|
@@ -113,7 +122,8 @@
|
|
}}/{{ form.unit }}起购</span
|
|
}}/{{ form.unit }}起购</span
|
|
>
|
|
>
|
|
<span style="font-size: 14px"
|
|
<span style="font-size: 14px"
|
|
- >库存:{{ item.stock + item.predictStocks }}{{ form.unit }}</span
|
|
|
|
|
|
+ >库存:{{ item.stock + item.predictStocks
|
|
|
|
+ }}{{ form.unit }}</span
|
|
>
|
|
>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
@@ -131,7 +141,11 @@
|
|
<el-col :span="24">
|
|
<el-col :span="24">
|
|
<el-form-item label="发货地" prop="spuName">
|
|
<el-form-item label="发货地" prop="spuName">
|
|
<div style="width: 185px">
|
|
<div style="width: 185px">
|
|
- {{ form.shippingAddrBean ? form.shippingAddrBean.addr : "" }}
|
|
|
|
|
|
+ {{
|
|
|
|
+ form.shippingAddrBean
|
|
|
|
+ ? form.shippingAddrBean.addr
|
|
|
|
+ : ""
|
|
|
|
+ }}
|
|
{{
|
|
{{
|
|
form.shippingAddrBean
|
|
form.shippingAddrBean
|
|
? form.shippingAddrBean.addrDetail
|
|
? form.shippingAddrBean.addrDetail
|
|
@@ -229,7 +243,10 @@
|
|
<script>
|
|
<script>
|
|
import { getStoreInfo } from "@/api/common/index";
|
|
import { getStoreInfo } from "@/api/common/index";
|
|
import { publishGoods } from "@/api/publish/index";
|
|
import { publishGoods } from "@/api/publish/index";
|
|
-import { saveGoodsDraft, queryUserRelevanceTemplate } from "@/api/manage/product";
|
|
|
|
|
|
+import {
|
|
|
|
+ saveGoodsDraft,
|
|
|
|
+ queryUserRelevanceTemplate,
|
|
|
|
+} from "@/api/manage/product";
|
|
import basicInfo from "./module/basic-info.vue";
|
|
import basicInfo from "./module/basic-info.vue";
|
|
import productInfo from "./module/product-info.vue";
|
|
import productInfo from "./module/product-info.vue";
|
|
import salesInfo from "./module/sales-info.vue";
|
|
import salesInfo from "./module/sales-info.vue";
|
|
@@ -266,28 +283,31 @@ export default {
|
|
},
|
|
},
|
|
submitFormDraft() {
|
|
submitFormDraft() {
|
|
if (this.form.categoryId?.length > 0) {
|
|
if (this.form.categoryId?.length > 0) {
|
|
- this.form.categoryId = this.form.categoryId[this.form.categoryId.length - 1];
|
|
|
|
|
|
+ this.form.categoryId =
|
|
|
|
+ this.form.categoryId[this.form.categoryId.length - 1];
|
|
}
|
|
}
|
|
if (this.form.categoryIds.length < 1) {
|
|
if (this.form.categoryIds.length < 1) {
|
|
this.form.categoryIds = "";
|
|
this.form.categoryIds = "";
|
|
}
|
|
}
|
|
if (!this.form.presaleStartTime && !this.form.presaleEndTime) {
|
|
if (!this.form.presaleStartTime && !this.form.presaleEndTime) {
|
|
if (this.form.datePicke) {
|
|
if (this.form.datePicke) {
|
|
- this.form.presaleStartTime = moment(this.form.datePicker[0]).valueOf();
|
|
|
|
|
|
+ this.form.presaleStartTime = moment(
|
|
|
|
+ this.form.datePicker[0]
|
|
|
|
+ ).valueOf();
|
|
this.form.presaleEndTime = moment(this.form.datePicker[1]).valueOf();
|
|
this.form.presaleEndTime = moment(this.form.datePicker[1]).valueOf();
|
|
}
|
|
}
|
|
}
|
|
}
|
|
if (this.form.saleModel == 2) {
|
|
if (this.form.saleModel == 2) {
|
|
- this.form.merchantClassifyId = "217524";
|
|
|
|
|
|
+ this.form.merchantClassifyId = "[217524]";
|
|
this.form.merchantClassifyName = "预售专区";
|
|
this.form.merchantClassifyName = "预售专区";
|
|
} else if (this.form.saleModel == 3) {
|
|
} else if (this.form.saleModel == 3) {
|
|
- this.form.merchantClassifyId = "217522";
|
|
|
|
|
|
+ this.form.merchantClassifyId = "[217522]";
|
|
this.form.merchantClassifyName = "团购秒杀";
|
|
this.form.merchantClassifyName = "团购秒杀";
|
|
} else if (this.form.saleModel == 4) {
|
|
} else if (this.form.saleModel == 4) {
|
|
- this.form.merchantClassifyId = "217523";
|
|
|
|
|
|
+ this.form.merchantClassifyId = "[217523]";
|
|
this.form.merchantClassifyName = "特价卖场";
|
|
this.form.merchantClassifyName = "特价卖场";
|
|
} else if (this.form.saleModel == 5) {
|
|
} else if (this.form.saleModel == 5) {
|
|
- this.form.merchantClassifyId = "217521";
|
|
|
|
|
|
+ this.form.merchantClassifyId = "[217521]";
|
|
this.form.merchantClassifyName = "新人福利";
|
|
this.form.merchantClassifyName = "新人福利";
|
|
}
|
|
}
|
|
|
|
|
|
@@ -350,25 +370,28 @@ export default {
|
|
return;
|
|
return;
|
|
}
|
|
}
|
|
if (this.form.categoryId?.length > 0) {
|
|
if (this.form.categoryId?.length > 0) {
|
|
- this.form.categoryId = this.form.categoryId[this.form.categoryId.length - 1];
|
|
|
|
|
|
+ this.form.categoryId =
|
|
|
|
+ this.form.categoryId[this.form.categoryId.length - 1];
|
|
}
|
|
}
|
|
if (!this.form.presaleStartTime && !this.form.presaleEndTime) {
|
|
if (!this.form.presaleStartTime && !this.form.presaleEndTime) {
|
|
if (this.form.datePicke) {
|
|
if (this.form.datePicke) {
|
|
- this.form.presaleStartTime = moment(this.form.datePicker[0]).valueOf();
|
|
|
|
|
|
+ this.form.presaleStartTime = moment(
|
|
|
|
+ this.form.datePicker[0]
|
|
|
|
+ ).valueOf();
|
|
this.form.presaleEndTime = moment(this.form.datePicker[1]).valueOf();
|
|
this.form.presaleEndTime = moment(this.form.datePicker[1]).valueOf();
|
|
}
|
|
}
|
|
}
|
|
}
|
|
if (this.form.saleModel == 2) {
|
|
if (this.form.saleModel == 2) {
|
|
- this.form.merchantClassifyId = "217524";
|
|
|
|
|
|
+ this.form.merchantClassifyId = "[217524]";
|
|
this.form.merchantClassifyName = "预售专区";
|
|
this.form.merchantClassifyName = "预售专区";
|
|
} else if (this.form.saleModel == 3) {
|
|
} else if (this.form.saleModel == 3) {
|
|
- this.form.merchantClassifyId = "217522";
|
|
|
|
|
|
+ this.form.merchantClassifyId = "[217522]";
|
|
this.form.merchantClassifyName = "团购秒杀";
|
|
this.form.merchantClassifyName = "团购秒杀";
|
|
} else if (this.form.saleModel == 4) {
|
|
} else if (this.form.saleModel == 4) {
|
|
- this.form.merchantClassifyId = "217523";
|
|
|
|
|
|
+ this.form.merchantClassifyId = "[217523]";
|
|
this.form.merchantClassifyName = "特价卖场";
|
|
this.form.merchantClassifyName = "特价卖场";
|
|
} else if (this.form.saleModel == 5) {
|
|
} else if (this.form.saleModel == 5) {
|
|
- this.form.merchantClassifyId = "217521";
|
|
|
|
|
|
+ this.form.merchantClassifyId = "[217521]";
|
|
this.form.merchantClassifyName = "新人福利";
|
|
this.form.merchantClassifyName = "新人福利";
|
|
}
|
|
}
|
|
|
|
|