From 671effa4a528ccfbfaf72193b50e2cf79d92b1e2 Mon Sep 17 00:00:00 2001 From: hyt <958868763@qq.com> Date: Mon, 4 Aug 2025 16:36:51 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=9A=E8=AE=A1=E4=BA=8B=E9=A1=B9=E5=B9=B3?= =?UTF-8?q?=E5=8F=B0=E6=9B=B4=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/ItemEntryTemplate/index.vue | 82 +++++--- .../compoments/datePickDialog.vue | 86 ++++++++ src/views/businessVoucher/index.vue | 186 ++++++++++++------ src/views/integrationOptionV2/index.vue | 1 + 4 files changed, 264 insertions(+), 91 deletions(-) create mode 100644 src/views/businessVoucher/compoments/datePickDialog.vue diff --git a/src/views/ItemEntryTemplate/index.vue b/src/views/ItemEntryTemplate/index.vue index b1d486a..85db6b3 100644 --- a/src/views/ItemEntryTemplate/index.vue +++ b/src/views/ItemEntryTemplate/index.vue @@ -21,7 +21,7 @@
-
{{ item.name }}{{ item.def1 === 'Y' ? '①' : ''}}
+
{{ item.name }}{{ item.def1 === 'Y' ? '①' : '' }}
@@ -73,16 +73,16 @@
凭证类别: -

{{typeMerge == 'Y'?'合并':typeMerge == 'N'?'拆分':''}}

- - +

{{ typeMerge == 'Y' ? '合并' : typeMerge == 'N' ? '拆分' : '' }}

+ +
@@ -119,6 +119,13 @@ type="primary" >保存 + 复制 + -
+
凭证类型名称:
@@ -1024,7 +1033,7 @@ export default { ], exchangeRate: [ { required: true, message: '请输入汇率', trigger: 'change' } - ], + ] // jNumField: [ // { required: true, message: '请选择借方数量字段', trigger: 'change' } // ], @@ -1205,7 +1214,7 @@ export default { children: 'sublistMdmModuleDbFileds', label: 'name' }, - typeMerge:'' + typeMerge: '' } }, methods: { @@ -1238,8 +1247,8 @@ export default { this.getAddTableData() } }, - getTableAddList(val){ - console.log(val,'val',this.fixedValueClickRow) + getTableAddList(val) { + console.log(val, 'val', this.fixedValueClickRow) this.pageModel.propValue7 = val this.pageModel.propValue8 = val this.pageModel.prop7 = this.fixedValueClickRow.codefieldname @@ -1251,9 +1260,9 @@ export default { this.$vmNews('请选择一条数据') return } - let obj =this.$refs.baseChoice2.optionData + let obj = this.$refs.baseChoice2.optionData this.$set(this.$refs.fixedValueFormRefsName.ruleForm, 'recordData', obj[this.fixedValueClickRow.namefieldname]) - console.log(this.fixedValueClickRow,'this.fixedValueClickRow') + console.log(this.fixedValueClickRow, 'this.fixedValueClickRow') this.textarea += `@@$${this.fixedValueClickRow.dbName}:id=${obj.id}` // this.$set(this.clickRow, `factorid${this.clickNum}`, this.$refs.baseChoice.optionData[this.clickObj.key]) // this.$set(this.clickRow, `factorname${this.clickNum}`, this.$refs.baseChoice.optionData[this.clickObj.labelKey]) @@ -1304,7 +1313,7 @@ export default { this.selected[0].assistEntityList.push({}) }, //凭证相关 - voucherCliclHandle(id, name,def1) { + voucherCliclHandle(id, name, def1) { this.voucherClickId = id this.voucherClickName = name this.voucherClickdef1 = def1 @@ -1350,7 +1359,7 @@ export default { const res = await typeSaveAPI({ name: this.billTypeADDName, mdmId: this.billTypeClickID, - def1: this.def1, + def1: this.def1 }) this.$vmNews('保存成功', 'success') this.getVoucherListHandle() @@ -1359,7 +1368,7 @@ export default { id: this.billTypeADDID, name: this.billTypeADDName, mdmId: this.billTypeClickID, - def1: this.def1, + def1: this.def1 }) this.$vmNews('保存成功', 'success') this.getVoucherListHandle() @@ -1383,18 +1392,33 @@ export default { } }) }) - let tableData = this.tableData.map(el=>{ - return{ - ...el, - typeMerge:this.typeMerge - } - }) + let tableData = this.tableData.map(el => { + return { + ...el, + typeMerge: this.typeMerge + } + }) console.log(this.tableData, 'this.tableData') const res = await confTempSaveAPI(tableData) this.$vmNews('保存成功', 'success') this.editFlag = false this.getTableData() }, + //复制方法 + async copyOperate() { + if (!this.selected.length) { + this.$vmNews('请至少选择一条数据') + return + } + let copyTarget = JSON.parse(JSON.stringify(this.selected[0])) + console.log(copyTarget.assistEntityList, 'copyTarget') + //恰掉id + delete copyTarget.id + copyTarget.assistEntityList.forEach(item => { + delete item.id + }) + this.tableData.push(copyTarget) + }, //关闭方法 closeOperate() { this.editFlag = false @@ -2013,7 +2037,7 @@ export default { templateTypeId: this.voucherClickId//20250704 }) this.tableData = res.attribute - this.typeMerge = this.tableData[0].typeMerge + this.typeMerge = this.tableData[0].typeMerge this.$nextTick(() => { this.$refs.customtable.clearRadioIndex() this.$refs.customtable.clearSelection() @@ -2148,7 +2172,7 @@ export default { currencyFieArr: [], assistEntityList: [], templateTypeId: this.voucherClickId, - typeMerge:this.typeMerge + typeMerge: this.typeMerge } this.tableData.push(obj) return diff --git a/src/views/businessVoucher/compoments/datePickDialog.vue b/src/views/businessVoucher/compoments/datePickDialog.vue new file mode 100644 index 0000000..d651b12 --- /dev/null +++ b/src/views/businessVoucher/compoments/datePickDialog.vue @@ -0,0 +1,86 @@ + + + + + diff --git a/src/views/businessVoucher/index.vue b/src/views/businessVoucher/index.vue index eb4b14c..a419693 100644 --- a/src/views/businessVoucher/index.vue +++ b/src/views/businessVoucher/index.vue @@ -1,19 +1,28 @@
- - + + + +