|
|
@@ -127,9 +127,32 @@
|
|
|
:key="detailKey" class="vxe-table-element" :data="inputForm.detailInfos"
|
|
|
style="margin-left: 5em" highlight-current-row
|
|
|
:edit-config="{ trigger: 'click', mode: 'row', showStatus: true, autoClear: true, icon: '_' }"
|
|
|
- :edit-rules="validRules">
|
|
|
+ :edit-rules="validRules"
|
|
|
+ :expand-config="{ expandAll: true, accordion: false, toggleMethod: handleExpand }">
|
|
|
+ <vxe-column type="expand" width="80">
|
|
|
+ <template #content="{ row, rowIndex }">
|
|
|
+ <InvoiceReimbursementUpLoadComponent v-if="row.reimbursementType == 1"
|
|
|
+ @changeConfirmList="changeConfirmList" @handleCount="handleCount"
|
|
|
+ @handleUploadSuccess="handleUploadSuccess" :ref="row.uniqueId + 'Upload'"
|
|
|
+ v-show="'1' === this.inputForm.reimbursementType">
|
|
|
+ </InvoiceReimbursementUpLoadComponent>
|
|
|
+
|
|
|
+
|
|
|
+ <UpLoadComponent @handleUploadSuccess="handleUploadSuccess"
|
|
|
+ v-if="row.reimbursementType == 0" :ref="row.uniqueId + 'UploadFiles'">
|
|
|
+ </UpLoadComponent>
|
|
|
+
|
|
|
+ </template>
|
|
|
+ </vxe-column>
|
|
|
<vxe-table-column field="userName" title="报销人" show-overflow="title"></vxe-table-column>
|
|
|
<vxe-table-column field="deptName" title="报销部门" show-overflow="title"></vxe-table-column>
|
|
|
+ <vxe-table-column field="reimbursementType" title="报销类型" :edit-render="{}"
|
|
|
+ show-overflow="title">
|
|
|
+ <template #default="{ row }">
|
|
|
+ <span>{{ $dictUtils.getDictLabel('reimbursement_type', row.reimbursementType,
|
|
|
+ '') }}</span>
|
|
|
+ </template>
|
|
|
+ </vxe-table-column>
|
|
|
<vxe-table-column field="typeName" title="报销类别" show-overflow="title"></vxe-table-column>
|
|
|
<vxe-table-column field="projectName" title="报销项目" show-overflow="title">
|
|
|
<template #edit="scope">
|
|
|
@@ -163,7 +186,8 @@
|
|
|
:key="detailKey" class="vxe-table-element" :data="inputForm.detailInfos"
|
|
|
style="margin-left: 5em" highlight-current-row
|
|
|
:edit-config="{ trigger: 'click', mode: 'row', showStatus: true, autoClear: true, icon: '_' }"
|
|
|
- :edit-rules="validRules" :expand-config="{ accordion: false, toggleMethod: handleExpand }">
|
|
|
+ :edit-rules="validRules"
|
|
|
+ :expand-config="{ expandAll: true, accordion: false, toggleMethod: handleExpand }">
|
|
|
<vxe-column type="expand" width="80">
|
|
|
<template #content="{ row, rowIndex }">
|
|
|
<InvoiceReimbursementUpLoadComponent v-if="row.reimbursementType == 1"
|
|
|
@@ -360,7 +384,8 @@
|
|
|
ref="detailTableReport" :key="detailKeyReport" class="vxe-table-element"
|
|
|
:data="inputForm.detailInfoReports" style="margin-left: 5em" highlight-current-row
|
|
|
:edit-config="{ trigger: 'click', mode: 'row', showStatus: true, autoClear: true, icon: '_' }"
|
|
|
- :edit-rules="validRules" :expand-config="{ accordion: false, toggleMethod: handleExpand }">
|
|
|
+ :edit-rules="validRules"
|
|
|
+ :expand-config="{ expandAll: true, accordion: false, toggleMethod: handleExpand }">
|
|
|
<vxe-column type="expand" width="80">
|
|
|
<template #content="{ row, rowIndex }">
|
|
|
<InvoiceReimbursementUpLoadComponent v-if="row.reimbursementType == 1"
|
|
|
@@ -476,7 +501,8 @@
|
|
|
ref="detailTableOthers" class="vxe-table-element" :data="inputForm.detailInfoOthers"
|
|
|
style="margin-left: 5em" :key="detailKeyOthers" highlight-current-row
|
|
|
:edit-config="{ trigger: 'click', mode: 'row', showStatus: true, autoClear: true, icon: '_' }"
|
|
|
- :edit-rules="validRules" :expand-config="{ accordion: false, toggleMethod: handleExpand }">
|
|
|
+ :edit-rules="validRules"
|
|
|
+ :expand-config="{ expandAll: true, accordion: false, toggleMethod: handleExpand }">
|
|
|
<vxe-column type="expand" width="80">
|
|
|
<template #content="{ row, rowIndex }">
|
|
|
<InvoiceReimbursementUpLoadComponent v-if="row.reimbursementType == 1"
|
|
|
@@ -1258,18 +1284,17 @@ export default {
|
|
|
this.handleTableInfo(this.inputForm.sourceType)
|
|
|
// 获取当前审核节点
|
|
|
this.commonApi.getTaskNameByProcInsId(this.inputForm.procInsId).then(name => {
|
|
|
- console.log(name);
|
|
|
- console.log(name);
|
|
|
- console.log(name);
|
|
|
- console.log(name);
|
|
|
- console.log(name);
|
|
|
-
|
|
|
this.currentNodeName = name
|
|
|
- if (name == "综合管理部主任审批") {
|
|
|
+
|
|
|
+ if (name == "综合管理部主任审批" && this.status != "taskFormDetail") {
|
|
|
this.isConfirm = 1
|
|
|
} else {
|
|
|
this.isConfirm = 2
|
|
|
}
|
|
|
+
|
|
|
+ if (this.status == "startAndHold" || this.method == "add") {
|
|
|
+ this.isConfirm = 3
|
|
|
+ }
|
|
|
})
|
|
|
// 获取文件确认状态
|
|
|
this.invoiceConfirmStatusService.getListByUser(this.inputForm.id).then(data => {
|
|
|
@@ -1453,7 +1478,6 @@ export default {
|
|
|
if (row.reimbursementType == 0) {
|
|
|
this.inputForm.files = this.inputForm.files.filter(item => item.remarks != row.uniqueId)
|
|
|
}
|
|
|
-
|
|
|
if (type === 'detail') {
|
|
|
this.$refs.detailTable.remove(row)
|
|
|
this.inputForm.detailInfos.splice(rowIndex, 1)
|
|
|
@@ -3082,6 +3106,36 @@ export default {
|
|
|
this.inputForm.files.push(...files)
|
|
|
}
|
|
|
},
|
|
|
+ handleCheckAmount() {
|
|
|
+ let countFlag = false
|
|
|
+ let countIndex = 0
|
|
|
+ this.handleTableInfo(this.inputForm.sourceType)
|
|
|
+ this.tableData.forEach((element, index) => {
|
|
|
+
|
|
|
+ if (element.reimbursementType == 1) {
|
|
|
+ let files = this.inputForm.invoiceReimbursementFiles.filter(item => {
|
|
|
+ return item.remarks == element.uniqueId
|
|
|
+ })
|
|
|
+ let count = 0
|
|
|
+ files.forEach((item) => {
|
|
|
+ if (this.commonJS.isNotEmpty(item.count)) {
|
|
|
+ count += Number(item.count)
|
|
|
+ }
|
|
|
+ });
|
|
|
+ if (count != element.number) {
|
|
|
+ countFlag = true
|
|
|
+ countIndex = index
|
|
|
+ }
|
|
|
+ }
|
|
|
+ })
|
|
|
+ if (countFlag) {
|
|
|
+ this.$message.warning(`第${countIndex + 1}行报销费用与发票金额不一致`);
|
|
|
+ this.loading = false
|
|
|
+ throw new Error(`第${countIndex + 1}行报销费用与发票金额不一致`);
|
|
|
+ } else {
|
|
|
+ this.loading = false
|
|
|
+ }
|
|
|
+ }
|
|
|
|
|
|
}
|
|
|
}
|