From 30b58af5365bc4d81c82ab2045de874aabb82c8a Mon Sep 17 00:00:00 2001 From: Gitea Date: Tue, 23 May 2023 16:21:41 +0800 Subject: [PATCH] =?UTF-8?q?=E4=B8=8B=E6=8B=89=E6=A1=86=E6=94=B9=E5=BC=B9?= =?UTF-8?q?=E5=87=BA=E6=A1=86=E8=81=94=E5=8A=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/views/zygoods/modules/ZyGoodsForm.vue | 76 ++++++++++++++++++- 1 file changed, 73 insertions(+), 3 deletions(-) diff --git a/ant-design-vue-jeecg/src/views/zygoods/modules/ZyGoodsForm.vue b/ant-design-vue-jeecg/src/views/zygoods/modules/ZyGoodsForm.vue index 8391ce0e..ada55544 100644 --- a/ant-design-vue-jeecg/src/views/zygoods/modules/ZyGoodsForm.vue +++ b/ant-design-vue-jeecg/src/views/zygoods/modules/ZyGoodsForm.vue @@ -11,17 +11,49 @@ - + + + - + + + - + + + @@ -129,6 +161,8 @@ lx:'zy_cloths_type ,type_name,id', ks:'zy_cloths_style,style_names,id', xh:'zy_style_model,model_number,id', + param:{type_id:""}, + param2:{style_id:""}, autoplay:true, model:{ customized:0, @@ -144,6 +178,7 @@ sm: { span: 16 }, }, confirmLoading: false, + multi: false, validatorRules: { enterprisesId:[{ required: true, message: '请选择企业!' @@ -206,6 +241,41 @@ this.modelDefault = JSON.parse(JSON.stringify(this.model)); }, methods: { + popupCallback(value,row){ + this.model = Object.assign(this.model, row); + this.param.type_id = this.model.clothsTypeId; + }, + popupCallback2(value,row){ + this.model = Object.assign(this.model, row); + this.param2.style_id = this.model.styleId; + getAction(this.url.zystyle, {ksid:this.model.styleId}).then((res) => { + if (res.success) { + // this.$forceUpdate(); + this.$set(this.model,'goodsIntr',res.result.productOverview); + this.$set(this.model,'goodsPicture',res.result.designSketch); + this.$set(this.model,'defaultPicture',res.result.designSketch); + } else { + + } + }); + }, + popupCallback3(value,row){ + this.model = Object.assign(this.model, row); + // //如果编辑-商品编码不该改变 + if(!this.model.id) + { + getAction(this.url.zy, {lxid:this.model.clothsTypeId,xhid:this.model.modelId}).then((res) => { + if (res.success) { + // console.log(res.result.nums) + // this.$forceUpdate(); + //写一个接口返回一个拼装好的商品编号 + this.$set(this.model,'goodsCode',res.result); + } else { + + } + }); + } + }, getlx(){ this.lx ="zy_cloths_type ,type_name,id,enterprise_id='" + this.model.enterprisesId + "'"; },