Authored by 陈峰

Merge branch 'release/1.0' of http://git.yoho.cn/fe/yoho-shop-manage into release/1.0

... ... @@ -972,7 +972,15 @@ export default {
onChangeFactoryCode: function(index, code) {
// 注意这里vue 没有办法监听到,手动添加监听
this.$set(this.product, `goods[${index}].factoryGoodsName`, code);
this.product.goods[index].factoryGoodsName = code;
let goods = this.product.goods[index];
goods.factoryGoodsName = code;
// 同步图片中的factoryGoodsName 的值
goods.goodsImage.forEach((image) => {
image.factoryGoodsName = code || goods.goodsName;
});
},
validate: function() {
return Promise.all([this.validateProduct(), this.validateTable()]);
... ...
... ... @@ -30,6 +30,7 @@ const handleGoods = (goods) => {
orderBy: 0,
productSkn: goods.productSkn,
productSkc: goods.productSkc,
factoryGoodsName: goods.factoryGoodsName || goods.goodsName,
status: 1
}, { //1
angle: 0,
... ... @@ -39,6 +40,7 @@ const handleGoods = (goods) => {
orderBy: 0,
productSkn: goods.productSkn,
productSkc: goods.productSkc,
factoryGoodsName: goods.factoryGoodsName || goods.goodsName,
status: 1
}, { //2
angle: 0,
... ... @@ -48,6 +50,7 @@ const handleGoods = (goods) => {
orderBy: 0,
productSkn: goods.productSkn,
productSkc: goods.productSkc,
factoryGoodsName: goods.factoryGoodsName || goods.goodsName,
status: 1
}, { //3
angle: 0,
... ... @@ -57,6 +60,7 @@ const handleGoods = (goods) => {
orderBy: 0,
productSkn: goods.productSkn,
productSkc: goods.productSkc,
factoryGoodsName: goods.factoryGoodsName || goods.goodsName,
status: 1
}, { //4
angle: 0,
... ... @@ -66,6 +70,7 @@ const handleGoods = (goods) => {
orderBy: 0,
productSkn: goods.productSkn,
productSkc: goods.productSkc,
factoryGoodsName: goods.factoryGoodsName || goods.goodsName,
status: 1
}];
... ...