|
@@ -480,7 +480,8 @@ export default {
|
|
|
{ required: true, message: '请选择商品分类', trigger: 'change' }
|
|
|
],
|
|
|
goodsName: [
|
|
|
- { required: true, message: '请填写商品名称', trigger: 'blur' }
|
|
|
+ { required: true, message: '请填写商品名称', trigger: 'blur' },
|
|
|
+ { required: true, message: '请填写商品名称', trigger: 'change' }
|
|
|
],
|
|
|
imgUrl: [
|
|
|
{ required: true, message: '请上传商品主图', trigger: 'change' }
|
|
@@ -625,22 +626,16 @@ export default {
|
|
|
})
|
|
|
})
|
|
|
this.step1Form = {
|
|
|
- isTrade: 'NO', // 是否以旧换新
|
|
|
- tradeRemark: '', // 以旧换新描述
|
|
|
- brand: {}, // 品牌
|
|
|
- orderSmallType: '', // 工单类型
|
|
|
- isVr: false, // 是否虚拟商品
|
|
|
- classify: '', // 商品分类
|
|
|
- attrs: [], // 商品属性
|
|
|
- tags: [], // 商品标签
|
|
|
+ ...this.step1Form,
|
|
|
goodsName: res.data.goodsName, // 商品名称
|
|
|
goodsDes: res.data.describeText, // 商品描述
|
|
|
imgUrl: res.data.imgUrl, // 商品主图
|
|
|
videoUrl: res.data.vedio, // 商品视频
|
|
|
images: res.data.imgs?imgs:[], // 轮播图
|
|
|
}
|
|
|
- this.specList = goodsLibrarySpecList
|
|
|
+ this.specList = [...this.specList,...goodsLibrarySpecList]
|
|
|
this.step3Form.detailContent = res.data.content
|
|
|
+ this.$refs.step1Form.validateField('goodsName')
|
|
|
})
|
|
|
|
|
|
}
|