From 0e394ed580b09329ecaa8476bbb6334f8212b009 Mon Sep 17 00:00:00 2001 From: schangxiang@126.com <schangxiang@126.com> Date: 周四, 25 4月 2024 13:40:31 +0800 Subject: [PATCH] Merge branch 'master' of http://222.71.245.114:9086/r/iWare_RawMaterialWarehouse --- iWare_RawMaterialWarehouse_Web/src/views/main/WmsBase/WmsMaterial/tabForm.vue | 42 ++++++++++++++++++++++++++---------------- 1 files changed, 26 insertions(+), 16 deletions(-) diff --git a/iWare_RawMaterialWarehouse_Web/src/views/main/WmsBase/WmsMaterial/tabForm.vue b/iWare_RawMaterialWarehouse_Web/src/views/main/WmsBase/WmsMaterial/tabForm.vue index 603bca0..717475c 100644 --- a/iWare_RawMaterialWarehouse_Web/src/views/main/WmsBase/WmsMaterial/tabForm.vue +++ b/iWare_RawMaterialWarehouse_Web/src/views/main/WmsBase/WmsMaterial/tabForm.vue @@ -1,5 +1,5 @@ <template> - <a-modal title="鏂板鍩虹鐗╂枡淇℃伅" :width="1200" :visible="visible" :confirmLoading="confirmLoading" @ok="handleSubmit" + <a-modal :title="title" :width="1200" :visible="visible" :confirmLoading="confirmLoading" @ok="handleSubmit" @cancel="handleCancel"> <a-spin :spinning="confirmLoading"> <!-- tab --> @@ -142,9 +142,12 @@ }, created() { this.materialTypeDataList() + const materialTypeOption = this.$options + this.materialTypeData2 = materialTypeOption.filters['dictData']('abc_class_type') }, data() { return { + title: '', labelCol: { // xs: { span: 24 }, // sm: { span: 5 } @@ -161,7 +164,8 @@ stationNameParameterData: [], visible: false, confirmLoading: false, - form: this.$form.createForm(this) + form: this.$form.createForm(this), + materialTypeData2:[] } }, methods: { @@ -207,14 +211,20 @@ handleOk() { }, // 鍒濆鍖栨柟娉� add(record) { + + this.visible = true - // this.$nextTick(() => { - // // this.getSelects() - // }) - const materialTypeOption = this.$options - this.materialTypeData2 = materialTypeOption.filters['dictData']('abc_class') - // const inspectionMethodOption = this.$options - // this.inspectionMethodData = inspectionMethodOption.filters['dictData']('material_inspection') + if (record) {//缂栬緫 + this.title = '缂栬緫鍩虹鐗╂枡淇℃伅'; + this.$nextTick(() => { + this.form.setFieldsValue({ + ...record + }) + }) + + } else { // 鏂板 + this.title = '鏂板鍩虹鐗╂枡淇℃伅'; + } }, getSelects() { if (this.areaNameParameterData.length <= 0 || this.stationNameParameterData.length <= 0) { @@ -274,7 +284,7 @@ BaseCustomerList = this.$refs.addFormBaseCustomer.list } - console.log(6666666666666 + '瀹㈡埛妗f闆嗗悎') + console.log(6666666666666 + '寰�鏉ュ叧绯婚泦鍚�') // console.log(6666666666666 + '鍖呰鍏崇郴') // console.log(this.$refs.addFormContainerPackagingRef.list) @@ -283,7 +293,7 @@ MaterialInput: values, ControlRuleld: ControlRuleld, //鎺у埗灞炴�� SubstituteGoodList: SubstituteGoodList, //鏇夸唬鍝� - BaseCustomerList: BaseCustomerList, //瀹㈡埛妗f闆嗗悎 + BaseCustomerList: BaseCustomerList, //寰�鏉ュ叧绯婚泦鍚� // ContainerPackagingList: this.$refs.addFormContainerPackagingRef.list //鍖呰鍏崇郴 } this.confirmLoading = true @@ -328,9 +338,9 @@ } </script> -<style lang="less"> - .ant-row.ant-form-item { - width: 50% !important; - display: inline-block; - } +<style lang="less" scoped> +.ant-row.ant-form-item { + width: 50% !important; + display: inline-block; +} </style> -- Gitblit v1.9.3