From 30c170388fb4d26df6befff68b54e3d9c7ad2ce3 Mon Sep 17 00:00:00 2001
From: WXL <1785969728@qq.com>
Date: 星期一, 28 八月 2023 10:52:50 +0800
Subject: [PATCH] 更改问题
---
src/views/project/fund/ethicalExpertFeeApply/index.vue | 713 +++++++++++++++++++++++++++++++++--------------------------
1 files changed, 396 insertions(+), 317 deletions(-)
diff --git a/src/views/project/fund/ethicalExpertFeeApply/index.vue b/src/views/project/fund/ethicalExpertFeeApply/index.vue
index c3f7c95..46bcfe8 100644
--- a/src/views/project/fund/ethicalExpertFeeApply/index.vue
+++ b/src/views/project/fund/ethicalExpertFeeApply/index.vue
@@ -51,10 +51,6 @@
<el-card shadow="naver">
<el-form ref="infoform" label-width="100px">
<el-row :gutter="4" align="right" class="mb8">
- <el-col :span="1.5">
- <el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd"
- v-hasPermi="['project:ethicalfund:add']">浼︾悊瀹℃煡涓撳璐圭敵璇�</el-button>
- </el-col>
<el-col :span="9">
<el-form-item label="鎹愮尞缂栧彿">
<el-input v-model="curCase.donorno" :disabled="true"></el-input>
@@ -65,7 +61,12 @@
<el-input v-model="curCase.name" :disabled="true"></el-input>
</el-form-item>
</el-col>
- <el-col> </el-col>
+ </el-row>
+ <el-row :gutter="10" class="mb8">
+ <el-col :span="1.5">
+ <el-button type="primary" plain icon="el-icon-plus" size="mini" @click="handleAdd"
+ v-hasPermi="['project:ethicalfund:add']">鏂板鐢宠鍗�</el-button>
+ </el-col>
</el-row>
<el-row>
<el-table v-loading="loading" border :data="donateconsolationfundList">
@@ -373,8 +374,8 @@
<el-row>
<el-col :span="24">
<el-form-item label="鐢宠闄勪欢锛�" align="left" prop="annexbankcard">
- <el-upload size="mini" class="upload-demo" :action="uploadFileUrl" :file-list="fileList" multiple :limit="20"
- :headers="headers" :on-success="(response, file, fileList) =>
+ <el-upload size="mini" class="upload-demo" :action="uploadFileUrl" :file-list="fileList" multiple
+ :limit="20" :headers="headers" :on-success="(response, file, fileList) =>
uploadSccess(response, file, fileList)
" :on-preview="downFile" :disabled='dialogType == "detail"' :on-error="handleUploadError"
:on-exceed="handleExceed" :on-remove="remove" accept="image/*,.pdf">
@@ -612,62 +613,186 @@
},
};
},
+
//鐩戝惉灞炴�� 绫讳技浜巇ata姒傚康
computed: {},
//鐩戞帶data涓殑鏁版嵁鍙樺寲
watch: {},
- //鏂规硶闆嗗悎
+
+ //鏂规硶闆嗗悎
methods: {
- ShowDetailDialog(spoce, showType) {
- this.funddetailForm.index = spoce.$index;
- this.funddetailForm.beneficiaryno = spoce.row.beneficiaryno;
- this.funddetailForm.beneficiaryname = spoce.row.beneficiaryname;
- this.funddetailForm.unitno = spoce.row.unitno;
- this.funddetailForm.unitname = spoce.row.unitname;
- this.detailInfoDialogShow = true;
- this.detailInfoDialogShowType = showType;
+ /** 鎼滅储鎸夐挳鎿嶄綔 */
+ handleQuery() {
+ this.queryParams.pageNum = 1;
+ this.getList();
},
- ConfirmDetailDialog() {
- let tempIndex = this.funddetailForm.index;
- let tempName = this.funddetailForm.beneficiaryname;
- let tempUnitname = this.funddetailForm.unitname;
- let singleDetail = this.fundDetailArr[tempIndex];
- if (this.detailInfoDialogShowType == "name") {
- this.personlist.map((res) => {
- if (tempName == res.username) {
- singleDetail.beneficiaryno = res.userno;
- singleDetail.beneficiaryname = res.username;
- singleDetail.bankcardno = res.bankcardno;
- singleDetail.branchbankname = res.branchbankname;
- singleDetail.depositbank = res.depositbank;
- singleDetail.idcardno = res.idcardno;
- singleDetail.phone = res.telephone;
- singleDetail.title = res.title;
- singleDetail.unitname = res.unitname;
- singleDetail.unitno = parseInt(res.unitno);
- } else {
- singleDetail.beneficiaryname = tempName;
- singleDetail.beneficiaryno = tempName;
+
+ /** 閲嶇疆鎸夐挳鎿嶄綔 */
+ resetQuery() {
+ this.daterangeReporttime = [];
+
+ this.resetForm("queryForm");
+ this.handleQuery();
+ },
+ /** 鏂板鎸夐挳鎿嶄綔 */
+ handleAdd() {
+ if (this.curCase.id) {
+ this.$router.push({
+ path: "/finance/applyDetail/",
+ query: {
+ id: 0,
+ businessType: "2",
+ operationType: "add",
+ curCase: this.curCase
}
});
- } else if (this.detailInfoDialogShowType == "unit") {
- singleDetail.unitno = this.funddetailForm.unitno;
- try {
- let unitIndex = this.unitList.findIndex(
- (item) => singleDetail.unitno == item.organizationid
- );
- if (unitIndex > -1) {
- singleDetail.unitname = this.unitList[unitIndex].organizationname;
- } else {
- singleDetail.unitname = singleDetail.unitno;
- }
- } catch {
- singleDetail.unitname = singleDetail.unitno;
- }
+ } else {
+ const h = this.$createElement;
+ this.$message({
+ message: h("p", null, [h("span", null, "璇峰湪宸﹁竟鐨勬崘鐚渚嬭〃閫夋嫨闇�瑕佹搷浣滅殑妗堜緥锛�")]),
+ });
}
- this.fundDetailArr[tempIndex] = singleDetail;
- this.detailInfoDialogShow = false;
+ return;
+
+
+ if (this.curCase.id) {
+ this.istrue += 2;
+ this.reset();
+ this.dialogOpen = true;
+ this.title = "娣诲姞璐圭敤鐢宠";
+ this.dialogType = "edit";
+ this.queryParams.params = {};
+
+ this.form.infoid = this.curCase.id;
+ this.form.donorno = this.curCase.donorno;
+ this.form.donorname = this.curCase.name;
+ this.form.username = this.defaultperson.nickName;
+ this.form.userno = this.defaultperson.userName;
+
+ this.form.deptmentname = this.defaultperson.dept.deptName;
+ this.form.deptmentno = this.defaultperson.dept.deptId;
+ this.form.managername = this.defaultperson.dept.leader;
+ // this.form.createTime = nowdate;
+ //this.open = true;
+ //this.initFundApplyForm();
+ this.fundDetailArr = [];
+ this.fundflowList = [];
+ this.addRow();
+ } else {
+ const h = this.$createElement;
+ this.$message({
+ message: h("p", null, [h("span", null, "璇峰厛閫夋嫨宸︽柟鎹愮尞妗堜緥 ")]),
+ });
+ }
},
+ /** 淇敼鎸夐挳鎿嶄綔 */
+ handleUpdate(row) {
+ this.$router.push({
+ path: "/finance/applyDetail/",
+ query: {
+ id: row.id,
+ businessType: "2",
+ operationType: "update",
+ curCase: this.curCase
+ }
+ });
+ return;
+
+ this.isopen = 0;
+ this.reset();
+ this.queryParams.params = {};
+ this.dialogOpen = true;
+ this.title = "淇敼璐圭敤鐢宠";
+ this.dialogType = "edit";
+
+ const id = row.id || this.ids;
+ getFund(id).then((response) => {
+ this.form = response.data;
+ //闄勪欢澶勭悊
+ this.fileList = this.form.annexbankcard ? this.form.annexbankcard.split(",").map(item => ({ url: item, name: item })) : []
+
+ getownFundDetail(id).then(async (res) => {
+ this.fundDetailArr = res.data;
+ for (let m = 0; m < this.fundDetailArr.length; m++) {
+ this.fundDetailArr[m].itemArr = [];
+ this.getItemArr(m, this.fundDetailArr[m]);
+ }
+ });
+ });
+ },
+
+ /** 鏌ョ湅鎸夐挳鎿嶄綔 */
+ handleDetail(row) {
+ this.$router.push({
+ path: "/finance/applyDetail/",
+ query: {
+ id: row.id,
+ businessType: "2",
+ operationType: "detail",
+ curCase: this.curCase
+ }
+ });
+ return;
+
+ this.isopen = 0;
+ this.reset();
+ this.queryParams.params = {};
+ this.dialogOpen = true;
+ this.title = "鏌ョ湅璐圭敤鐢宠";
+ this.dialogType = "detail";
+ const id = row.id || this.ids;
+
+ getFund(id).then((response) => {
+ this.form = response.data;
+ let listFundflowparams = {
+ fundid: row.id,
+ fundtype: 2,
+ };
+ //闄勪欢澶勭悊
+ this.fileList = this.form.annexbankcard ? this.form.annexbankcard.split(",").map(item => ({ url: item, name: item })) : []
+
+ listFundflow(listFundflowparams).then((res) => {
+ this.fundflowList = res.rows;
+ });
+ getownFundDetail(id).then((res) => {
+ this.fundDetailArr = res.data;
+ for (let m = 0; m < this.fundDetailArr.length; m++) {
+ this.fundDetailArr[m].itemArr = [];
+ this.getItemArr(m, this.fundDetailArr[m]);
+ this.fundDetailArr[m].fundblock = [];
+ this.fundDetailArr[m].fundblock.push({
+ expense: this.fundDetailArr[m].expense,
+ expensedescribe: this.fundDetailArr[m].servicesscopename,
+ remark: this.fundDetailArr[m].servicesscope,
+ servicesscope: this.fundDetailArr[m].servicesscope,
+ });
+ }
+ });
+ });
+ },
+
+ /** 鍒犻櫎鎸夐挳鎿嶄綔 */
+ handleDelete(row) {
+ const ids = row.id || this.ids;
+ this.$modal
+ .confirm("鏄惁纭鍒犻櫎璇ヨ褰曪紵")
+ .then(function () {
+ return delFund(ids);
+ })
+ .then(() => {
+ getownFundDetail(ids).then((res) => {
+ let listdetails = res.data;
+ for (let i = 0; i < listdetails.length; i++) {
+ delFunddetail(listdetails[i].id);
+ }
+ });
+ // this.getList();
+ this.getfundList();
+ this.$modal.msgSuccess("鍒犻櫎鎴愬姛");
+ })
+ .catch(() => { });
+ },
+ /** 涓婃姤鎸夐挳鎿嶄綔 */
handleup(row) {
this.$confirm("鏄惁纭灏嗙櫥璁拌褰曚笂鎶ワ紵", "鎻愮ず", {
confirmButtonText: "纭畾",
@@ -701,24 +826,160 @@
});
});
},
+
+ /** 瀵煎嚭鎸夐挳鎿嶄綔 */
+ handleExport() {
+ const queryParams = this.queryParams;
+ this.$modal
+ .confirm("鏄惁纭瀵煎嚭鎵�鏈夋姤閿�鐢宠鏁版嵁椤癸紵")
+ .then(() => {
+ this.exportLoading = true;
+ return exportReimbursement(queryParams);
+ })
+ .then(response => {
+ this.$download.name(response.msg);
+ this.exportLoading = false;
+ })
+ .catch(() => { });
+ },
+
+ /** 鎻愪氦鎸夐挳 */
+ submitForm() {
+ this.$refs["form"].validate((valid) => {
+ if (valid) {
+ let formData = this.form;
+ let totalPreTaxAmount = 0.0;
+ let totalAfterTaxAmount = 0.0;
+ let totalAmount = 0.0;
+ for (let k = 0; k < this.fundDetailArr.length; k++) {
+ let tempDetail = this.fundDetailArr[k];
+ if (tempDetail.itemid == null) {
+ this.$modal.msgWarning("璇烽�夋嫨鏈嶅姟椤圭洰");
+ return;
+ }
+ //鍒ゆ柇鍗曚綅 unitSel
+ // try {
+ // //鑾峰彇鏈嶅姟椤圭洰鏄庣粏
+ // let unitIndex = this.unitList.findIndex(
+ // (item) => tempDetail.unitno == item.organizationid
+ // );
+ // if (unitIndex > -1) {
+ // tempDetail.unitname = this.unitList[unitIndex].organizationname;
+ // }
+ // else{
+ // tempDetail.unitname = tempDetail.unitno;
+ // }
+ // } catch {
+ // tempDetail.unitname = tempDetail.unitno;
+ // }
+ if (!isNaN(parseFloat(tempDetail.amount))) {
+ totalPreTaxAmount += parseFloat(tempDetail.amount);
+ totalAmount += parseFloat(tempDetail.amount);
+ }
+ if (!isNaN(parseFloat(tempDetail.taxedamount))) {
+ totalAfterTaxAmount += parseFloat(tempDetail.taxedamount);
+ totalAmount += parseFloat(tempDetail.taxedamount);
+ }
+ }
+ try {
+ this.form.unitname = this.$refs.orgSelecter.getOptionByValue(
+ this.form.unitno
+ ).organizationname;
+ } catch {
+ this.form.treatmenthospitalname = this.form.treatmenthospitalno;
+ }
+ this.form.pretaxcost = parseFloat(totalPreTaxAmount).toFixed(2);
+ this.form.taxedcost = parseFloat(totalAfterTaxAmount).toFixed(2);
+ this.form.amountrequested = totalAmount.toFixed(2);
+
+ this.loading = true;
+ //闄勪欢澶勭悊
+ let list = this.fileList;
+ if (list.length > 0) {
+ this.form.annexbankcard = list.map(item => item.url).join(",");
+ }
+
+ if (this.form.id != null) {
+ updateFund(this.form).then((response) => {
+ this.getfundList();
+ this.dialogOpen = false;
+ this.getList();
+ this.selectDonotor(this.curCase);
+ this.$modal.msgSuccess("淇敼鎴愬姛");
+ this.loading = false;
+ for (let m = 0; m < this.fundDetailArr.length; m++) {
+ let tempData = this.fundDetailArr[m];
+ let tempItemArr = tempData.itemArr;
+ tempData.fundid = formData.id;
+ //鑾峰彇鏈嶅姟椤圭洰鏄庣粏
+ let itemIndex = tempItemArr.findIndex(
+ (item) => tempData.itemid == item.id
+ );
+ if (itemIndex > -1) {
+ tempData.itemname = tempItemArr[itemIndex].itemName;
+ tempData.itemid = tempItemArr[itemIndex].id;
+ }
+ if (tempData.id > 0) {
+ updateFunddetail(tempData).then((response2) => { });
+ } else {
+ addFunddetail(tempData).then((response2) => { });
+ }
+ }
+ });
+ } else {
+ //淇濆瓨璐圭敤鐢宠
+ for (let m = 0; m < this.fundDetailArr.length; m++) {
+ let tempData = this.fundDetailArr[m];
+ let tempUtemArr = tempData.itemArr;
+ //鑾峰彇鏈嶅姟椤圭洰鏄庣粏
+ let itemIndex = tempUtemArr.findIndex(
+ (item) => tempData.itemid == item.id
+ );
+ if (itemIndex > -1) {
+ tempData.itemname = tempUtemArr[itemIndex].itemName;
+ tempData.itemid = tempUtemArr[itemIndex].id;
+ }
+ //鑾峰彇applytypename
+ let applytypeIndex = this.fundtypeArr.findIndex(
+ (item) => tempData.applytype == item.value
+ );
+ if (applytypeIndex > -1) {
+ tempData.applytypename = this.fundtypeArr[applytypeIndex].label;
+ }
+ this.fundDetailArr[m] = tempData;
+ }
+
+ this.form.serviceFunddetails = this.fundDetailArr;
+ addorupdateFund(this.form).then((response) => {
+ if (response.code === 200) {
+ this.$modal.msgSuccess("鏂板鎴愬姛");
+ this.loading = false;
+ this.selectDonotor(this.curCase);
+ } else {
+ this.$modal.msgError("鏂板澶辫触锛�" + response.msg);
+ this.loading = false;
+ }
+ });
+ this.dialogOpen = false;
+ }
+ }
+ });
+ },
+ /** 鍙栨秷鎸夐挳 */
+ cancel() {
+ this.dialogOpen = false;
+ this.reset();
+ },
+
+
+ //鑾峰彇鎵�鏈夌敤鎴峰垪琛�
getUsermsg() {
getUserProfile().then((response) => {
this.defaultperson = response.data;
this.standardlevel = response.data.standardlevel;
});
},
- /** 鎼滅储鎸夐挳鎿嶄綔 */
- handleQuery() {
- this.queryParams.pageNum = 1;
- this.getList();
- },
- /** 閲嶇疆鎸夐挳鎿嶄綔 */
- resetQuery() {
- this.daterangeReporttime = [];
- this.resetForm("queryForm");
- this.handleQuery();
- },
/** 鏌ヨ鎹愮尞浜洪亾鎱伴棶閲戝垪琛� */
getList() {
this.loading = true;
@@ -736,6 +997,7 @@
});
},
+ //鑾峰彇鎹愮尞妗堜緥鍒楄〃
getBaseInfoList() {
this.loading = true;
listDonatebaseinfo(this.queryParams).then((response) => {
@@ -745,43 +1007,13 @@
});
},
- /** 鏂板鎸夐挳鎿嶄綔 */
- handleAdd() {
- if (this.curCase.id) {
- this.istrue += 2;
- this.reset();
- this.dialogOpen = true;
- this.title = "娣诲姞璐圭敤鐢宠";
- this.dialogType = "edit";
- this.queryParams.params = {};
-
- this.form.infoid = this.curCase.id;
- this.form.donorno = this.curCase.donorno;
- this.form.donorname = this.curCase.name;
- this.form.username = this.defaultperson.nickName;
- this.form.userno = this.defaultperson.userName;
-
- this.form.deptmentname = this.defaultperson.dept.deptName;
- this.form.deptmentno = this.defaultperson.dept.deptId;
- this.form.managername = this.defaultperson.dept.leader;
- // this.form.createTime = nowdate;
- //this.open = true;
- //this.initFundApplyForm();
- this.fundDetailArr = [];
- this.fundflowList = [];
- this.addRow();
- } else {
- const h = this.$createElement;
- this.$message({
- message: h("p", null, [h("span", null, "璇峰厛閫夋嫨宸︽柟鎹愮尞妗堜緥 ")]),
- });
- }
- },
//鐐瑰嚮鎹愮尞妗堜緥鍒楄〃瑙﹀彂鏂规硶
selectDonotor(row, column, event) {
this.curCase = row;
this.getfundList();
},
+
+ //鑾峰彇妗堜緥涓撳璐圭敤鐢宠鍗�
getfundList() {
this.loading = true;
this.reset();
@@ -825,11 +1057,6 @@
row.servicesscope = null;
row.servicesscopename = "";
});
- },
- // 鍙栨秷鎸夐挳
- cancel() {
- this.dialogOpen = false;
- this.reset();
},
// 琛ㄥ崟閲嶇疆
@@ -947,128 +1174,7 @@
// });
},
- /** 鎻愪氦鎸夐挳 */
- submitForm() {
- this.$refs["form"].validate((valid) => {
- if (valid) {
- let formData = this.form;
- let totalPreTaxAmount = 0.0;
- let totalAfterTaxAmount = 0.0;
- let totalAmount = 0.0;
- for (let k = 0; k < this.fundDetailArr.length; k++) {
- let tempDetail = this.fundDetailArr[k];
- if (tempDetail.itemid == null) {
- this.$modal.msgWarning("璇烽�夋嫨鏈嶅姟椤圭洰");
- return;
- }
- //鍒ゆ柇鍗曚綅 unitSel
- // try {
- // //鑾峰彇鏈嶅姟椤圭洰鏄庣粏
- // let unitIndex = this.unitList.findIndex(
- // (item) => tempDetail.unitno == item.organizationid
- // );
- // if (unitIndex > -1) {
- // tempDetail.unitname = this.unitList[unitIndex].organizationname;
- // }
- // else{
- // tempDetail.unitname = tempDetail.unitno;
- // }
- // } catch {
- // tempDetail.unitname = tempDetail.unitno;
- // }
- if (!isNaN(parseFloat(tempDetail.amount))) {
- totalPreTaxAmount += parseFloat(tempDetail.amount);
- totalAmount += parseFloat(tempDetail.amount);
- }
- if (!isNaN(parseFloat(tempDetail.taxedamount))) {
- totalAfterTaxAmount += parseFloat(tempDetail.taxedamount);
- totalAmount += parseFloat(tempDetail.taxedamount);
- }
- }
- try {
- this.form.unitname = this.$refs.orgSelecter.getOptionByValue(
- this.form.unitno
- ).organizationname;
- } catch {
- this.form.treatmenthospitalname = this.form.treatmenthospitalno;
- }
- this.form.pretaxcost = parseFloat(totalPreTaxAmount).toFixed(2);
- this.form.taxedcost = parseFloat(totalAfterTaxAmount).toFixed(2);
- this.form.amountrequested = totalAmount.toFixed(2);
- this.loading = true;
- //闄勪欢澶勭悊
- let list = this.fileList;
- if (list.length > 0) {
- this.form.annexbankcard = list.map(item => item.url).join(",");
- }
-
- if (this.form.id != null) {
- updateFund(this.form).then((response) => {
- this.getfundList();
- this.dialogOpen = false;
- this.getList();
- this.selectDonotor(this.curCase);
- this.$modal.msgSuccess("淇敼鎴愬姛");
- this.loading = false;
- for (let m = 0; m < this.fundDetailArr.length; m++) {
- let tempData = this.fundDetailArr[m];
- let tempItemArr = tempData.itemArr;
- tempData.fundid = formData.id;
- //鑾峰彇鏈嶅姟椤圭洰鏄庣粏
- let itemIndex = tempItemArr.findIndex(
- (item) => tempData.itemid == item.id
- );
- if (itemIndex > -1) {
- tempData.itemname = tempItemArr[itemIndex].itemName;
- tempData.itemid = tempItemArr[itemIndex].id;
- }
- if (tempData.id > 0) {
- updateFunddetail(tempData).then((response2) => { });
- } else {
- addFunddetail(tempData).then((response2) => { });
- }
- }
- });
- } else {
- //淇濆瓨璐圭敤鐢宠
- for (let m = 0; m < this.fundDetailArr.length; m++) {
- let tempData = this.fundDetailArr[m];
- let tempUtemArr = tempData.itemArr;
- //鑾峰彇鏈嶅姟椤圭洰鏄庣粏
- let itemIndex = tempUtemArr.findIndex(
- (item) => tempData.itemid == item.id
- );
- if (itemIndex > -1) {
- tempData.itemname = tempUtemArr[itemIndex].itemName;
- tempData.itemid = tempUtemArr[itemIndex].id;
- }
- //鑾峰彇applytypename
- let applytypeIndex = this.fundtypeArr.findIndex(
- (item) => tempData.applytype == item.value
- );
- if (applytypeIndex > -1) {
- tempData.applytypename = this.fundtypeArr[applytypeIndex].label;
- }
- this.fundDetailArr[m] = tempData;
- }
-
- this.form.serviceFunddetails = this.fundDetailArr;
- addorupdateFund(this.form).then((response) => {
- if (response.code === 200) {
- this.$modal.msgSuccess("鏂板鎴愬姛");
- this.loading = false;
- this.selectDonotor(this.curCase);
- } else {
- this.$modal.msgError("鏂板澶辫触锛�" + response.msg);
- this.loading = false;
- }
- });
- this.dialogOpen = false;
- }
- }
- });
- },
selectremark(row) {
this.fundblock.forEach((item, i) => {
if (item.expensedescribe === row.servicesscopename) {
@@ -1105,90 +1211,7 @@
});
},
- /** 淇敼鎸夐挳鎿嶄綔 */
- handleUpdate(row) {
- this.isopen = 0;
- this.reset();
- this.queryParams.params = {};
- this.dialogOpen = true;
- this.title = "淇敼璐圭敤鐢宠";
- this.dialogType = "edit";
- const id = row.id || this.ids;
- getFund(id).then((response) => {
- this.form = response.data;
- //闄勪欢澶勭悊
- this.fileList = this.form.annexbankcard ? this.form.annexbankcard.split(",").map(item => ({ url: item, name: item })) : []
-
- getownFundDetail(id).then(async (res) => {
- this.fundDetailArr = res.data;
- for (let m = 0; m < this.fundDetailArr.length; m++) {
- this.fundDetailArr[m].itemArr = [];
- this.getItemArr(m, this.fundDetailArr[m]);
- }
- });
- });
- },
-
- /** 鏌ョ湅鎸夐挳鎿嶄綔 */
- handleDetail(row) {
- this.isopen = 0;
- this.reset();
- this.queryParams.params = {};
- this.dialogOpen = true;
- this.title = "鏌ョ湅璐圭敤鐢宠";
- this.dialogType = "detail";
- const id = row.id || this.ids;
-
- getFund(id).then((response) => {
- this.form = response.data;
- let listFundflowparams = {
- fundid: row.id,
- fundtype: 2,
- };
- //闄勪欢澶勭悊
- this.fileList = this.form.annexbankcard ? this.form.annexbankcard.split(",").map(item => ({ url: item, name: item })) : []
-
- listFundflow(listFundflowparams).then((res) => {
- this.fundflowList = res.rows;
- });
- getownFundDetail(id).then((res) => {
- this.fundDetailArr = res.data;
- for (let m = 0; m < this.fundDetailArr.length; m++) {
- this.fundDetailArr[m].itemArr = [];
- this.getItemArr(m, this.fundDetailArr[m]);
- this.fundDetailArr[m].fundblock = [];
- this.fundDetailArr[m].fundblock.push({
- expense: this.fundDetailArr[m].expense,
- expensedescribe: this.fundDetailArr[m].servicesscopename,
- remark: this.fundDetailArr[m].servicesscope,
- servicesscope: this.fundDetailArr[m].servicesscope,
- });
- }
- });
- });
- },
-
- handleDelete(row) {
- const ids = row.id || this.ids;
- this.$modal
- .confirm("鏄惁纭鍒犻櫎璇ヨ褰曪紵")
- .then(function () {
- return delFund(ids);
- })
- .then(() => {
- getownFundDetail(ids).then((res) => {
- let listdetails = res.data;
- for (let i = 0; i < listdetails.length; i++) {
- delFunddetail(listdetails[i].id);
- }
- });
- // this.getList();
- this.getfundList();
- this.$modal.msgSuccess("鍒犻櫎鎴愬姛");
- })
- .catch(() => { });
- },
deleteRows(row, index, rows) {
this.$confirm("鏄惁纭鍒犻櫎?", "鎻愮ず", {
@@ -1327,7 +1350,7 @@
});
},
- //姹囨�绘墦鍗�
+ //涓嬭浇鎵撳嵃
totaldayin(e) {
// const id =this.row.id
getdownloadBX(e).then((res) => {
@@ -1349,6 +1372,7 @@
}
});
},
+
selectReporters() {
//涓撳浜哄憳鍒楄〃
let arr = ["zzry"];
@@ -1361,6 +1385,7 @@
});
}
},
+
getlistExternalperson() {
listExternalperson().then((res) => {
this.personlist = res.rows;
@@ -1383,6 +1408,18 @@
}
});
},
+
+ getUnitList() {
+ listOrganization(3).then((response) => {
+ for (let i = 0; i < response.rows.length; i++) {
+ this.unitList.push({
+ organizationid: response.rows[i].organizationid,
+ organizationname: response.rows[i].organizationname,
+ });
+ }
+ });
+ },
+
SearchItem(val, scope) {
let result = [];
if (val != "") {
@@ -1402,17 +1439,6 @@
//this.$set(this.fundDetailArr, rowindex, row);
});
}
- },
-
- getUnitList() {
- listOrganization(3).then((response) => {
- for (let i = 0; i < response.rows.length; i++) {
- this.unitList.push({
- organizationid: response.rows[i].organizationid,
- organizationname: response.rows[i].organizationname,
- });
- }
- });
},
addAlls() {
@@ -1478,7 +1504,59 @@
a.href = url;
a.dispatchEvent(event);
},
+
+ ShowDetailDialog(spoce, showType) {
+ this.funddetailForm.index = spoce.$index;
+ this.funddetailForm.beneficiaryno = spoce.row.beneficiaryno;
+ this.funddetailForm.beneficiaryname = spoce.row.beneficiaryname;
+ this.funddetailForm.unitno = spoce.row.unitno;
+ this.funddetailForm.unitname = spoce.row.unitname;
+ this.detailInfoDialogShow = true;
+ this.detailInfoDialogShowType = showType;
+ },
+ ConfirmDetailDialog() {
+ let tempIndex = this.funddetailForm.index;
+ let tempName = this.funddetailForm.beneficiaryname;
+ let tempUnitname = this.funddetailForm.unitname;
+ let singleDetail = this.fundDetailArr[tempIndex];
+ if (this.detailInfoDialogShowType == "name") {
+ this.personlist.map((res) => {
+ if (tempName == res.username) {
+ singleDetail.beneficiaryno = res.userno;
+ singleDetail.beneficiaryname = res.username;
+ singleDetail.bankcardno = res.bankcardno;
+ singleDetail.branchbankname = res.branchbankname;
+ singleDetail.depositbank = res.depositbank;
+ singleDetail.idcardno = res.idcardno;
+ singleDetail.phone = res.telephone;
+ singleDetail.title = res.title;
+ singleDetail.unitname = res.unitname;
+ singleDetail.unitno = parseInt(res.unitno);
+ } else {
+ singleDetail.beneficiaryname = tempName;
+ singleDetail.beneficiaryno = tempName;
+ }
+ });
+ } else if (this.detailInfoDialogShowType == "unit") {
+ singleDetail.unitno = this.funddetailForm.unitno;
+ try {
+ let unitIndex = this.unitList.findIndex(
+ (item) => singleDetail.unitno == item.organizationid
+ );
+ if (unitIndex > -1) {
+ singleDetail.unitname = this.unitList[unitIndex].organizationname;
+ } else {
+ singleDetail.unitname = singleDetail.unitno;
+ }
+ } catch {
+ singleDetail.unitname = singleDetail.unitno;
+ }
+ }
+ this.fundDetailArr[tempIndex] = singleDetail;
+ this.detailInfoDialogShow = false;
+ },
},
+
//鐢熷懡鍛ㄦ湡 - 鍒涘缓瀹屾垚锛堝彲浠ヨ闂綋鍓峵his瀹炰緥锛�
created() {
this.getUnitList();
@@ -1500,6 +1578,7 @@
beforeDestroy() { }, //鐢熷懡鍛ㄦ湡 - 閿�姣佷箣鍓�
destroyed() { }, //鐢熷懡鍛ㄦ湡 - 閿�姣佸畬鎴�
activated() { }, //濡傛灉椤甸潰鏈塳eep-alive缂撳瓨鍔熻兘锛岃繖涓嚱鏁颁細瑙﹀彂
+
};
</script>
<style scoped>
--
Gitblit v1.9.3