From 45d4fe24016c03fcccbe7c9798533ca97e2e7aea Mon Sep 17 00:00:00 2001
From: yxh <172933527@qq.com>
Date: 星期四, 03 十二月 2026 16:59:34 +0800
Subject: [PATCH] 回款新增和修改问题
---
src/views/project/tallage/computingBill/index.vue | 107 +++++++++++++++++++++++++++++++++++++++--------------
1 files changed, 79 insertions(+), 28 deletions(-)
diff --git a/src/views/project/tallage/computingBill/index.vue b/src/views/project/tallage/computingBill/index.vue
index 508a1cf..1d921a3 100644
--- a/src/views/project/tallage/computingBill/index.vue
+++ b/src/views/project/tallage/computingBill/index.vue
@@ -148,20 +148,20 @@
align="center"
fixed
label="搴忓彿"
- width="120"
+ width="60"
>
</el-table-column>
<el-table-column
prop="donorname"
align="center"
fixed
- label="妗堜緥鎹愮尞鑰�"
+ label="鎹愮尞妗堜緥"
width="120"
>
<template slot-scope="scope">
<el-input
v-model="scope.row.donorname"
- placeholder="妗堜緥鎹愮尞鑰�"
+ placeholder="鎹愮尞鑰�"
:disabled="true"
/>
</template>
@@ -185,7 +185,7 @@
prop="deptmentname"
align="center"
label="鎵�灞炵粍鍒�"
- width="280"
+ width="200"
>
<template slot-scope="scope">
<el-input
@@ -215,7 +215,7 @@
</el-date-picker>
</template>
</el-table-column>
- <el-table-column prop="pretaxcost" align="center" label="绋庡墠閲戦">
+ <el-table-column prop="pretaxcost" align="right" label="绋庡墠閲戦" width="120" header-align="right" class-name="money-column" :formatter="formatMoney">
<template slot-scope="scope">
<el-input
v-model="scope.row.pretaxcost"
@@ -224,7 +224,7 @@
/>
</template>
</el-table-column>
- <el-table-column prop="vatCost" align="center" label="澧炲�肩◣">
+ <el-table-column prop="vatCost" align="right" label="澧炲�肩◣" width="120" header-align="right" class-name="money-column" :formatter="formatMoney">
<template slot-scope="scope">
<el-input
v-model="scope.row.vatCost"
@@ -233,7 +233,7 @@
/>
</template>
</el-table-column>
- <el-table-column prop="cityTaxCost" align="center" label="鍩庡缓绋�">
+ <el-table-column prop="cityTaxCost" align="right" label="鍩庡缓绋�" width="120" header-align="right" class-name="money-column" :formatter="formatMoney">
<template slot-scope="scope">
<el-input
v-model="scope.row.cityTaxCost"
@@ -242,7 +242,7 @@
/>
</template>
</el-table-column>
- <el-table-column prop="laborPretaxCost" align="center" label="鍔冲姟绋庡墠">
+ <el-table-column prop="laborPretaxCost" align="right" label="鍔冲姟绋庡墠" width="120" header-align="right" class-name="money-column" :formatter="formatMoney">
<template slot-scope="scope">
<el-input
v-model="scope.row.laborPretaxCost"
@@ -251,7 +251,7 @@
/>
</template>
</el-table-column>
- <el-table-column label="鍔冲姟涓◣" align="center" prop="taxcost">
+ <el-table-column label="鍔冲姟涓◣" prop="taxcost" width="120" align="right" header-align="right" class-name="money-column" :formatter="formatMoney">
<template slot-scope="scope">
<el-input
v-model="scope.row.taxcost"
@@ -261,7 +261,7 @@
</template>
</el-table-column>
- <el-table-column prop="taxedcost" align="center" label="鍔冲姟绋庡悗">
+ <el-table-column prop="taxedcost" label="鍔冲姟绋庡悗" width="120" align="right" header-align="right" class-name="money-column" :formatter="formatMoney">
<template slot-scope="scope">
<el-input
@blur="chargeSum"
@@ -273,7 +273,6 @@
</el-table-column>
<el-table-column
prop="remark"
- width="280"
align="center"
label="澶囨敞"
>
@@ -446,42 +445,42 @@
show-overflow-tooltip
>
</el-table-column>
- <el-table-column
+ <!-- <el-table-column
prop="pretaxcost"
label="绋庡墠閲戦"
show-overflow-tooltip
- >
+ align="right" header-align="right" class-name="money-column" :formatter="formatMoney">
</el-table-column>
<el-table-column
prop="vatCost"
label="澧炲�肩◣"
show-overflow-tooltip
- >
+ align="right" header-align="right" class-name="money-column" :formatter="formatMoney">
</el-table-column>
<el-table-column
prop="cityTaxCost"
label="鍩庡缓绋�"
show-overflow-tooltip
- >
+ align="right" header-align="right" class-name="money-column" :formatter="formatMoney">
</el-table-column>
<el-table-column
prop="laborPretaxCost"
label="鍔冲姟绋庡墠"
show-overflow-tooltip
- >
+ align="right" header-align="right" class-name="money-column" :formatter="formatMoney">
</el-table-column>
<el-table-column
prop="taxcost"
label="鍔冲姟涓◣"
show-overflow-tooltip
- >
+ align="right" header-align="right" class-name="money-column" :formatter="formatMoney">
</el-table-column>
<el-table-column
prop="taxedcost"
label="鍔冲姟绋庡悗"
show-overflow-tooltip
- >
- </el-table-column>
+ align="right" header-align="right" class-name="money-column" :formatter="formatMoney">
+ </el-table-column> -->
<el-table-column
prop="remark"
label="澶囨敞"
@@ -561,7 +560,7 @@
</el-upload>
<el-table
:data="fileListto"
- @row-click="downFile"
+ @row-click="previewInline" @row-dblclick="downFile"
style="width: 100%"
height="400"
>
@@ -691,6 +690,8 @@
pdfVisible: false,
maxTaxId: "",
pdfimgsrcList: [],
+ // 2026-11-30锛氱エ鎹脊绐楅瑙堜护鐗岋紙闃叉鍒囨崲琛屾椂鏃ц姹傚洖鍐欙級
+ previewToken: 0,
Savereminder: false, //鎻愰啋淇濆瓨寮规
Reminderquantity: 0, //鎻愰啋鏁伴噺
totalquantity: 0, //鎬绘暟閲�
@@ -1268,11 +1269,24 @@
return sums;
},
// 鏂囦欢------------------------
+ /** 2026-11-23锛氭寜鏂囦欢鍚嶄粠鍒楄〃涓簿纭垹闄や竴椤癸紝閬垮厤鐢ㄩ瑙堝垪琛�(blob)鏁磋〃瑕嗙洊闄勪欢瀛楁 */
+ spliceByName(list, name) {
+ if (!list || !name) {
+ return;
+ }
+ const idx = list.findIndex(item => item && item.name === name);
+ if (idx > -1) {
+ list.splice(idx, 1);
+ }
+ },
remove(file, fileList) {
const donorchargeorgans = [...this.donorchargeorgans];
- this.fileListto.splice(this.fileListto.indexOf(file), 1);
- donorchargeorgans[this.atpresent].annexFilesList = this.fileListto;
+ this.spliceByName(this.fileListto, file && file.name);
+ this.spliceByName(
+ donorchargeorgans[this.atpresent].annexFilesList,
+ file && file.name
+ );
},
uploadSccess(response, file, fileList) {
@@ -1315,18 +1329,31 @@
},
// 鐐瑰嚮绁ㄦ嵁
+ /**
+ * 2026-11-30锛氭竻绌虹エ鎹脊绐楅瑙堢姸鎬侊紙鍚� embeddedFile / invoiceEmbeddedFile锛夛紝
+ * 閬垮厤鍐嶆鎵撳紑寮圭獥鏃朵粛鏄剧ず涓婁竴娆¢�夋嫨鐨勭エ鎹浘鐗囥��
+ */
+ resetPreviewState() {
+ this.fileListto = [];
+ this.invoicefileListto = [];
+ this.pdfimg = "";
+ this.invoicepdfimg = "";
+ this.pdfimgsrcList = [];
+ this.invoicepdfimgsrcList = [];
+ this.embeddedFile = null;
+ this.invoiceEmbeddedFile = null;
+ this.pdftitle = "";
+ this.previewToken = (this.previewToken || 0) + 1;
+ },
+
Filepopup(index, row) {
const config = {
headers: { Authorization: "Bearer " + this.ICDtoken }
};
this.tableDatatop = [];
- this.fileListto = [];
- this.invoicefileListto = [];
- this.pdfimg = "";
- this.invoicepdfimg = [];
- this.pdfimgsrcList = [];
- this.invoicepdfimgsrcList = [];
+ this.resetPreviewState();
+ const previewToken = ++this.previewToken;
this.tableDatatop.push(row);
this.atpresent = index;
this.pdfVisible = true;
@@ -1351,6 +1378,10 @@
);
Promise.all(fetchPromises).then(fileListto => {
+ // 2026-11-30锛氬垏鎹㈣鍚庝涪寮冭繃鏈熺粨鏋�
+ if (previewToken !== this.previewToken) {
+ return;
+ }
this.fileListto = fileListto.filter(item => item !== null);
this.pdfimg = this.fileListto[0].url;
console.log(this.pdfimg, "pdfimg");
@@ -1374,6 +1405,26 @@
},
// 鐐瑰嚮宸蹭笂浼犳枃浠讹細鍦ㄩ檮浠跺脊绐楀彸渚у唴宓岄瑙�
+ /**
+ * 2026-11-30锛氬崟鍑诲垪琛ㄩ」 鈫� 鍦ㄦ湰椤甸瑙堬紙鍙充晶 preview-pane锛夈��
+ * 鍙屽嚮鎵嶆墦寮�鐙珛鐨勯瑙堥〉闈紙downFile 鈫� $previewFile锛夈��
+ */
+ previewInline(row) {
+ if (!row) {
+ return;
+ }
+ const url = row.previewUrl || row.url;
+ if (!url) {
+ return;
+ }
+ const file = {
+ name: row.name || "",
+ url,
+ type: /\.pdf$/i.test(row.name || "") ? "pdf" : "image"
+ };
+ this.embeddedFile = file;
+ },
+
downFile(item) {
if (this.operationType == "detail") {
const list = (this.fileListto || []).map(f => ({
--
Gitblit v1.9.3