|
|
@ -502,6 +502,7 @@ export default { |
|
|
|
methods: { |
|
|
|
methods: { |
|
|
|
showEdit(goodsId) { |
|
|
|
showEdit(goodsId) { |
|
|
|
// 记录商品ID |
|
|
|
// 记录商品ID |
|
|
|
|
|
|
|
GoodsModel.formData.goods = {} |
|
|
|
this.visible = true |
|
|
|
this.visible = true |
|
|
|
this.goodsId = goodsId |
|
|
|
this.goodsId = goodsId |
|
|
|
this.initData() |
|
|
|
this.initData() |
|
|
@ -528,8 +529,10 @@ export default { |
|
|
|
// 第二次赋值 (适用于动态渲染的form-item) |
|
|
|
// 第二次赋值 (适用于动态渲染的form-item) |
|
|
|
this.$nextTick(() => { |
|
|
|
this.$nextTick(() => { |
|
|
|
this.form.setFieldsValue(GoodsModel.getFieldsValue2()) |
|
|
|
this.form.setFieldsValue(GoodsModel.getFieldsValue2()) |
|
|
|
|
|
|
|
|
|
|
|
this.ruleList = this.formData.goods.rules ? this.formData.goods.rules : [] |
|
|
|
this.ruleList = this.formData.goods.rules ? this.formData.goods.rules : [] |
|
|
|
this.onForceUpdate() |
|
|
|
this.onForceUpdate() |
|
|
|
|
|
|
|
this.$forceUpdate() |
|
|
|
}) |
|
|
|
}) |
|
|
|
} |
|
|
|
} |
|
|
|
// this.ruleList = record.rule.map((item, index) => { return { ...item, key: index } }) |
|
|
|
// this.ruleList = record.rule.map((item, index) => { return { ...item, key: index } }) |
|
|
|