From cef0ffebad11bf1444be8ff3d54172c83800c78d Mon Sep 17 00:00:00 2001
From: yxh <172933527@qq.com>
Date: 星期一, 07 八月 2023 16:39:29 +0800
Subject: [PATCH] yxh
---
src/views/project/fund/expertFeeFundApply/index.vue | 251 +++++++++++++++++++++++++++++++-------------------
1 files changed, 156 insertions(+), 95 deletions(-)
diff --git a/src/views/project/fund/expertFeeFundApply/index.vue b/src/views/project/fund/expertFeeFundApply/index.vue
index 3ece74b..b3f77d6 100644
--- a/src/views/project/fund/expertFeeFundApply/index.vue
+++ b/src/views/project/fund/expertFeeFundApply/index.vue
@@ -96,10 +96,10 @@
<template slot-scope="scope">
<el-button v-if="scope.row.recordstatus == -1 ||
scope.row.recordstatus == 1
- " size="mini" type="text" icon="el-icon-edit" @click="(scope.row)">涓婃姤</el-button>
+ " size="mini" type="text" icon="el-icon-edit" @click="handleUp(scope.row)">涓婃姤</el-button>
<el-button v-if="scope.row.recordstatus == -1 ||
scope.row.recordstatus == 1
- " size="mini" type="text" icon="el-icon-edit" @click="date(scope.row)">淇敼</el-button>
+ " size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)">淇敼</el-button>
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleDetail(scope.row)">鏌ョ湅</el-button>
<!-- v-hasPermi="['project:expretfund:edit']" -->
<el-button v-if="scope.row.recordstatus == -1 ||
@@ -137,6 +137,14 @@
</el-form-item>
</el-col>
<el-col :span="5">
+ <el-form-item label="缁忓姙浜�" prop="username">
+ <el-select v-model="form.username" placeholder="鐢宠浜�" clearable filterable allow-create style="width: 100%">
+ <el-option v-for="dict in userlist" :key="dict.index" :label="dict.nickname"
+ :value="dict.nickname"></el-option>
+ </el-select>
+ </el-form-item>
+ </el-col>
+ <el-col :span="5">
<el-form-item label="鎵�灞炵粍鍒�" prop="deptmentname">
<el-input v-model="form.deptmentname" placeholder="璇疯緭鍏ユ墍灞炵粍鍒�" clearable />
</el-form-item>
@@ -144,13 +152,6 @@
<el-col :span="5">
<el-form-item label="缁勯暱" prop="managername">
<el-input v-model="form.managername" placeholder="璇疯緭鍏ョ粍闀�" clearable />
- </el-form-item>
- </el-col><el-col :span="5">
- <el-form-item label="缁忓姙浜�" prop="username">
- <el-select v-model="form.username" placeholder="鐢宠浜�" clearable filterable allow-create style="width: 100%">
- <el-option v-for="dict in userlist" :key="dict.index" :label="dict.nickname"
- :value="dict.nickname"></el-option>
- </el-select>
</el-form-item>
</el-col>
</el-row>
@@ -178,25 +179,38 @@
</el-form-item>
</el-col>
<el-col :span="5">
- <el-form-item label="鎹愮尞鑰�" prop="name">
- <el-input :disabled="true" v-model="form.name" placeholder="璇疯緭鍏ユ崘鐚�呭鍚�" />
+ <el-form-item label="鑱旂郴鐢佃瘽" prop="phone">
+ <el-input v-model="form.phone" placeholder="璇疯緭鍏ヨ仈绯荤數璇�" />
</el-form-item>
</el-col>
+
</el-row>
<el-row style="text-align: left">
+ <!--
<el-col :span="5">
<el-form-item label="鍚堣閲戦" prop="amountrequested">
<el-input v-model="form.amountrequested" placeholder="鐢宠閲戦" :disabled="true" />
</el-form-item>
</el-col>
+ -->
<el-col :span="5">
- <el-form-item label="绋庡墠閲戦" prop="pretaxcost">
+ <el-form-item label="鐢宠閲戦" prop="pretaxcost">
<el-input v-model="form.pretaxcost" placeholder="绋庡墠閲戦鍚堣" :disabled="true" />
</el-form-item>
</el-col>
<el-col :span="5">
+ <el-form-item label="搴旂即绋�" prop="taxcost">
+ <el-input v-model="form.taxcost" placeholder="搴旂即绋庨噾棰濆悎璁�" :disabled="true" />
+ </el-form-item>
+ </el-col><!--
+ <el-col :span="5">
<el-form-item label="绋庡悗閲戦" prop="pretaxcost">
<el-input v-model="form.taxedcost" placeholder="绋庡悗閲戦鍚堣" :disabled="true" />
+ </el-form-item>
+ </el-col>-->
+ <el-col :span="5">
+ <el-form-item label="鎹愮尞鑰�" prop="name">
+ <el-input :disabled="true" v-model="form.name" placeholder="璇疯緭鍏ユ崘鐚�呭鍚�" />
</el-form-item>
</el-col>
<el-col :span="5">
@@ -362,7 +376,8 @@
</template>
</el-table-column>
</el-table>
- </el-row> <!--
+ </el-row>
+ <!--
<el-row>
<el-col :span="7">
<el-form-item label="棰勬敮閲戦" prop="prepaidamount">
@@ -402,14 +417,14 @@
</el-form-item>
</el-col>
</el-row>
- -->
+ -->
<el-row>
<el-col :span="12">
<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) =>
uploadSccess(response, file, fileList)
- " :on-preview="downFile" :disabled='dialogType == "detail"' :on-error="loadError"
+ " :on-preview="downFile" :disabled='dialogType == "detail"' :on-error="handleUploadError"
:on-exceed="handleExceed" :on-remove="remove" accept="image/*,.pdf">
<el-button :disabled='dialogType == "detail"' size="small" type="primary">涓婁紶</el-button>
</el-upload>
@@ -539,6 +554,7 @@
listDonatebaseinfo,
getDonatebaseinfo
} from "@/api/project/donatebaseinfo";
+
import {
onelistFund,
listFund,
@@ -552,9 +568,10 @@
getdownloadSS,
getdownloadYX,
getdownloadBX,
- batchUploadFund,
+ addorupdateFund,
getdetailsByItemId
} from "@/api/project/fund";
+
import {
onelistFunds,
listFunddetails,
@@ -575,13 +592,16 @@
getTaxationByBeneFiciaryNo,
getTaxBeforeByAfterMoney
} from "@/api/project/funddetail";
+
import { listFundflow } from "@/api/project/fundflow";
+
import {
listOrganization,
getOrganization,
listReportname,
listUser
} from "@/api/project/organization";
+
import {
listExternalperson,
getExternalperson,
@@ -591,6 +611,7 @@
updateExternalperson,
exportExternalperson
} from "@/api/project/externalperson";
+
import { getUserProfile } from "@/api/system/user";
import Li_area_select from "@/components/Address";
import OrgSelecter from "@/views/project/components/orgselect";
@@ -603,7 +624,9 @@
Li_area_select,
OrgSelecter,
},
+
name: "fundApply",
+
dicts: [
//"sys_consolationfundlevel",
//"sys_OrganizationType",
@@ -619,11 +642,12 @@
"sys_recordstatus",
"sys_professionaltitle"
],
+
data() {
//杩欓噷瀛樻斁鏁版嵁
return {
// 閬僵灞�
- loading: true,
+ loading: false,
// 瀵煎嚭閬僵灞�
exportLoading: false,
total: 0,
@@ -729,9 +753,6 @@
//鏄惁鏄笓瀹惰垂鐨凮PO瀹℃壒浜哄憳
ismanager: false,
-
-
-
unitList: [],
dialogType: "edit",
fundflowList: [],
@@ -795,32 +816,33 @@
computed: {},
//鐩戞帶data涓殑鏁版嵁鍙樺寲
watch: {},
- // mounted(){
- // this.getUsermsg()
- // },
+ //鐢熷懡鍛ㄦ湡 - 鍒涘缓瀹屾垚锛堝彲浠ヨ闂綋鍓峵his瀹炰緥锛�
+ created() {
+ this.getList();
+ this.getBaseInfoList();
+ this.getCurFundType();
+ this.getUserList();
+ this.getUnitList();
+
+ },
+
+ //鐢熷懡鍛ㄦ湡 - 鎸傝浇瀹屾垚锛堝彲浠ヨ闂瓺OM鍏冪礌锛�
+ mounted() {
+ this.selectReporters();
+ this.getUsermsg();
+ this.getExternalpersonList();
+ },
+
+ beforeCreate() { }, //鐢熷懡鍛ㄦ湡 - 鍒涘缓涔嬪墠
+ beforeMount() { }, //鐢熷懡鍛ㄦ湡 - 鎸傝浇涔嬪墠
+ beforeUpdate() { }, //鐢熷懡鍛ㄦ湡 - 鏇存柊涔嬪墠
+ updated() { }, //鐢熷懡鍛ㄦ湡 - 鏇存柊涔嬪悗
+ beforeDestroy() { }, //鐢熷懡鍛ㄦ湡 - 閿�姣佷箣鍓�
+ destroyed() { }, //鐢熷懡鍛ㄦ湡 - 閿�姣佸畬鎴�
+ activated() { }, //濡傛灉椤甸潰鏈塳eep-alive缂撳瓨鍔熻兘锛岃繖涓嚱鏁颁細瑙﹀彂
+
//鏂规硶闆嗗悎
methods: {
- //鐢熷懡鍛ㄦ湡 - 鍒涘缓瀹屾垚锛堝彲浠ヨ闂綋鍓峵his瀹炰緥锛�
- created() {
- this.getUnitList();
- this.getList();
- this.getBaseInfoList();
- this.getlistUser();
- this.getCurFundType();
- },
- //鐢熷懡鍛ㄦ湡 - 鎸傝浇瀹屾垚锛堝彲浠ヨ闂瓺OM鍏冪礌锛�
- mounted() {
- this.selectReporters();
- this.getUsermsg();
- this.getlistExternalperson();
- },
- beforeCreate() { }, //鐢熷懡鍛ㄦ湡 - 鍒涘缓涔嬪墠
- beforeMount() { }, //鐢熷懡鍛ㄦ湡 - 鎸傝浇涔嬪墠
- beforeUpdate() { }, //鐢熷懡鍛ㄦ湡 - 鏇存柊涔嬪墠
- updated() { }, //鐢熷懡鍛ㄦ湡 - 鏇存柊涔嬪悗
- beforeDestroy() { }, //鐢熷懡鍛ㄦ湡 - 閿�姣佷箣鍓�
- destroyed() { }, //鐢熷懡鍛ㄦ湡 - 閿�姣佸畬鎴�
- activated() { }, //濡傛灉椤甸潰鏈塳eep-alive缂撳瓨鍔熻兘锛岃繖涓嚱鏁颁細瑙﹀彂
/** 鎼滅储鎸夐挳鎿嶄綔 */
handleQuery() {
@@ -835,16 +857,6 @@
this.handleQuery();
},
- /** 涓嬭浇鏂囦欢鎸夐挳鎿嶄綔 */
- downFile(item) {
- const url = process.env.VUE_APP_BASE_API + item.url
- var a = document.createElement('a');
- var event = new MouseEvent('click');
- a.download = item.name;
- a.href = url;
- a.dispatchEvent(event);
- },
-
/** 鏂板鎸夐挳鎿嶄綔 */
handleAdd() {
if (this.curCase.id) {
@@ -854,13 +866,14 @@
this.form.donorno = this.curCase.donorno;
this.form.name = this.curCase.name;
this.form.infoid = this.curCase.id;
+
this.form.username = this.defaultperson.nickName;
this.form.userno = this.defaultperson.userName;
- // this.form.phone = this.defaultperson.phone;
-
+ this.form.phone = this.defaultperson.phonenumber;
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();
@@ -999,7 +1012,7 @@
},
/** 涓婃姤鎸夐挳鎿嶄綔 */
- handleup(row) {
+ handleUp(row) {
this.$confirm("鏄惁纭灏嗙櫥璁拌褰曚笂鎶ワ紵", "鎻愮ず", {
confirmButtonText: "纭畾",
cancelButtonText: "鍙栨秷",
@@ -1014,12 +1027,12 @@
if (response.code == 200) {
this.$message({
type: "success",
- message: "鐢宠鎴愬姛",
+ message: "鎻愪氦涓撳璐圭敤鐢宠瀹℃壒鎴愬姛锛�",
});
} else {
this.$message({
type: "error",
- message: "鐢宠澶辫触",
+ message: "鎻愪氦涓撳璐圭敤鐢宠澶辫触锛�",
});
}
this.loading = false;
@@ -1032,7 +1045,7 @@
});
});
},
-
+
/** 鎻愪氦鎸夐挳 */
submitForm() {
this.$refs["form"].validate((valid) => {
@@ -1160,15 +1173,39 @@
if (this.form.id != null) {
//鎹愮尞鑰�
this.form.donorname = this.curCase.name;
- }
- else {
+
+ // updateFund(this.form).then((response) => {
+ // if (response.code === 200) {
+ // this.loading = false;
+ // for (let m = 0; m < this.fundDetails.length; m++) {
+ // if (this.fundDetails[m].id > 0) {
+ // updateFunddetail(this.fundDetails[m]).then((response2) => { if (response.code != 200) { this.$modal.msgError("涓撳鍔冲姟璐逛繚瀛樺け璐�1锛�" + response.msg); } });
+ // } else {
+ // addFunddetail(this.fundDetails[m]).then((response2) => { if (response.code != 200) { this.$modal.msgError("涓撳鍔冲姟璐逛繚瀛樺け璐�2锛�" + response.msg); } });
+ // }
+ // }
+ // this.$modal.msgSuccess("涓撳鍔冲姟璐逛繚瀛樻垚鍔燂紒");
+ // } else {
+ // this.$modal.msgError("涓撳鍔冲姟璐逛繚瀛樺け璐ワ細" + response.msg);
+ // }
+ // });
+
+ } else {
this.form.recordstatus = -1;
+
+ // addorupdateFund(this.form).then((response) => {
+ // if (response.code === 200) {
+ // this.selectDonotor(this.curCase);
+ // } else {
+ // this.$modal.msgError("涓撳鍔冲姟璐逛繚瀛樺け璐ワ細" + response.msg);
+ // }
+ // });
}
- batchUploadFund(this.form).then((response) => {
+ addorupdateFund(this.form).then((response) => {
if (response.code === 200) {
- this.$modal.msgSuccess("涓撳鍔冲姟璐逛繚瀛樻垚鍔燂紒");
this.selectDonotor(this.curCase);
+ this.$modal.msgSuccess("涓撳鍔冲姟璐逛繚瀛樻垚鍔燂紒");
} else {
this.$modal.msgError("涓撳鍔冲姟璐逛繚瀛樺け璐ワ細" + response.msg);
}
@@ -1177,6 +1214,10 @@
//鍏抽棴绐楀彛
this.loading = false;
this.dialogOpen = false;
+ // this.getfundList();
+ this.getList();
+ this.selectDonotor(this.curCase);
+
}
});
},
@@ -1364,8 +1405,8 @@
//鑾峰彇褰撳墠鐢ㄦ埛淇℃伅
getUsermsg() {
getUserProfile().then((response) => {
+ console.log("getUserProfile", response);
this.defaultperson = response.data;
- console.log("this.defaultperson", this.defaultperson);
this.standardlevel = response.data.standardlevel;
if (this.defaultperson.createBy == "admin" || this.defaultperson.createBy == "001" || this.defaultperson.createBy == "002") {
this.ismanager = true;
@@ -1382,9 +1423,11 @@
row.servicesscopename = item.expensedescribe;
if (row.servicesscopename.includes("绋庡悗")) {
row.amount = 0.0;
+ row.taxamount = 0.0;
row.taxedamount = item.expense;
} else {
row.amount = item.expense;
+ row.taxamount = 0.0;
row.taxedamount = 0.0;
}
@@ -1453,14 +1496,15 @@
this.queryParams.params["endReporttime"] = this.daterangeReporttime[1];
}
// this.queryParams.residencetown = this.$refs.areaSelect.getQu();
+
+ console.log("111", this.queryParams);
listDonatebaseinfo(this.queryParams).then((response) => {
this.donatebaseinfoList = response.rows;
- console.log("this.queryParams", this.queryParams)
- console.log("this.donatebaseinfoList", this.donatebaseinfoList)
this.total = response.total;
this.loading = false;
});
},
+
getUnitList() {
listOrganization(3).then((response) => {
for (let i = 0; i < response.rows.length; i++) {
@@ -1472,6 +1516,7 @@
}
});
},
+
getBaseInfoList() {
this.loading = true;
listDonatebaseinfo(this.queryParams).then((response) => {
@@ -1486,6 +1531,7 @@
this.curCase = row;
this.getfundList();
},
+
getfundList() {
this.loading = true;
this.reset();
@@ -1658,10 +1704,10 @@
// row.itemArr = res.data;
// this.$forceUpdate();
// });
- },
+ },
//鑾峰彇涓撳鍒楄〃
- getlistExternalperson() {
+ getExternalpersonList() {
listExternalperson().then((res) => {
this.personlist = res.rows;
});
@@ -1705,12 +1751,34 @@
});
},
- getlistUser() {
+ getUserList() {
listUser().then((res) => {
console.log("listUser", res);
this.userlist = res.data;
});
- },
+ },
+
+ //绛涙煡鍑哄搴旂殑璐圭敤椤圭洰
+ searchItemType(val, scope) {
+ let result = [];
+ if (val != "") {
+ let tempItemArr = scope.row.itemArr;
+ for (let i = 0; i < tempItemArr.length; i++) {
+ let pym = tempItemArr[i].itempinyin;
+ if (pym != null && pym != undefined && pym != "") {
+ if (pym.indexOf(val) != -1) {
+ result.push(tempItemArr[i]);
+ }
+ }
+ }
+ scope.row.itemArr = result;
+ } else {
+ getItemNames(scope.row.applytype).then((res) => {
+ scope.row.itemArr = res.data;
+ //this.$set(this.fundDetails, rowindex, row);
+ });
+ }
+ },
deleteRows(row, index, rows) {
this.$confirm("鏄惁纭鍒犻櫎?", "鎻愮ず", {
@@ -1872,36 +1940,29 @@
});
},
- //绛涙煡鍑哄搴旂殑璐圭敤椤圭洰
- searchItemType(val, scope) {
- let result = [];
- if (val != "") {
- let tempItemArr = scope.row.itemArr;
- for (let i = 0; i < tempItemArr.length; i++) {
- let pym = tempItemArr[i].itempinyin;
- if (pym != null && pym != undefined && pym != "") {
- if (pym.indexOf(val) != -1) {
- result.push(tempItemArr[i]);
- }
- }
- }
- scope.row.itemArr = result;
- } else {
- getItemNames(scope.row.applytype).then((res) => {
- scope.row.itemArr = res.data;
- //this.$set(this.fundDetails, rowindex, row);
- });
- }
- },
+
//鏂囦欢涓婁紶
handleUploadError() { },
+
+ /** 涓嬭浇鏂囦欢鎸夐挳鎿嶄綔 */
+ downFile(item) {
+ const url = process.env.VUE_APP_BASE_API + item.url
+ var a = document.createElement('a');
+ var event = new MouseEvent('click');
+ a.download = item.name;
+ a.href = url;
+ a.dispatchEvent(event);
+ },
+
remove(file) {
this.fileList.splice(this.fileList.indexOf(file), 1)
},
+
handleExceed() {
this.$message.error(`涓婁紶鏂囦欢鏁伴噺涓嶈兘瓒呰繃 ${5} 涓�!`);
},
+
//鏂囦欢涓婁紶鎴愬姛鍥炶皟
uploadSccess(response, file, fileList) {
//鑾峰彇闄勪欢淇℃伅浣嶇疆
@@ -1910,14 +1971,14 @@
this.$modal.msgSuccess(response.msg);
this.fileList.push({ name: response.fileName, url: response.fileName });
} else {
- this.$modal.msgError(response.msg);
+ console.log(response.msg);;
}
- },
+ },
},
-
};
+
</script>
<style scoped>
/* @import url(); 寮曞叆鍏叡css绫� */
--
Gitblit v1.9.3