移动端
您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

approvalDetail11.vue 13 KiB

3 年前
2 年前
2 年前
3 年前
3 年前
2 年前
2 年前
3 年前
3 年前
2 年前
3 年前
3 年前
3 年前
2 年前
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353
  1. <template>
  2. <div class="app-container">
  3. <van-nav-bar
  4. left-arrow
  5. fixed
  6. placeholder
  7. @click-left="$router.back(-1)"
  8. >
  9. <template #title>
  10. <p style="font-weight: bold;">查看备付金支出申请</p>
  11. </template>
  12. <template #right>
  13. <van-icon name="../../../static/images/icon/icon_flow.png" size="20" @click="goFlow"/>
  14. </template>
  15. </van-nav-bar>
  16. <p class="main_title">基础信息</p>
  17. <div class="main_box">
  18. <van-field readonly label="申请时间" v-model="form.applyDate" input-align="right" />
  19. <van-field readonly label="资金支出类别" v-model="capitalExpenditureType" input-align="right" label-width="auto" />
  20. <van-field readonly label="支出总金额" v-model="form.expenditureAmount" input-align="right" label-width="auto"/>
  21. <van-field name="radio" label="审批模式" input-align="right" autocomplete="off" readonly>
  22. <template #input>
  23. <van-radio-group v-model="form.approvalMode" direction="horizontal">
  24. <van-radio name="1">线上审批</van-radio>
  25. <van-radio name="2">线下审批</van-radio>
  26. </van-radio-group>
  27. </template>
  28. </van-field>
  29. <van-field v-if="form.approvalMode==1" readonly label="审批流程" :value="tempalteFormat(form.approvalTemplateId)" input-align="right" label-width="auto"/>
  30. </div>
  31. <div class="main_box" style="margin-top: 10px;">
  32. <van-field readonly label="转账附言" v-model="form.remark" type="textarea" input-align="right" rows="3" label-width="auto"/>
  33. </div>
  34. <div class="main_box" style="margin-top: 10px;">
  35. <van-field readonly label="说明情况" v-model="form.explainSituation" type="textarea" input-align="right" rows="3" label-width="auto"/>
  36. </div>
  37. <p class="main_title">付款方信息</p>
  38. <div class="main_box">
  39. <van-field readonly label="付款方" v-model="form.payer" input-align="right" label-width="auto"/>
  40. <van-field readonly label="付款方账户" v-model="form.payerAccount" input-align="right" label-width="auto"/>
  41. </div>
  42. <div class="main_box" v-if="capitalExpenditureOpen" style="margin-bottom: 10px;margin-top: 10px;position:relative;">
  43. <van-field readonly label="项目名称" v-model="projectForm.projectName" input-align="right" />
  44. <van-field readonly label="承建单位" v-model="projectForm.projectContractor" input-align="right" label-width="auto"/>
  45. <van-field readonly label="合同价款(元)" v-model="projectForm.projectAmount" input-align="right" label-width="auto"/>
  46. <van-field readonly label="工程款类型" v-model="projectFundType" input-align="right" />
  47. <van-field readonly label="工程发票号" v-model="projectForm.projectBillNum" input-align="right" label-width="auto"/>
  48. </div>
  49. <div class="main_box" v-if="contractOpen" style="margin-bottom: 10px;margin-top: 10px;position:relative;">
  50. <van-field readonly label="合同名称" v-model="infoForm.name" input-align="right" />
  51. <van-field readonly label="合同编码" v-model="infoForm.code" input-align="right" label-width="auto"/>
  52. <van-field readonly label="合同价款(元)" v-model="infoForm.totalAmount" input-align="right" label-width="auto"/>
  53. </div>
  54. <p class="main_title">收款方信息</p>
  55. <div style="position:relative;">
  56. <div class="main_box" style="margin-bottom: 10px;position:relative;" v-for="(item, index) in chargeItme" :key="index" v-if="index<listLength">
  57. <van-field readonly label="收款方" v-model="item.payee" input-align="right" />
  58. <van-field readonly label="联系方式" v-model="item.phone" input-align="right" label-width="auto"/>
  59. <van-field readonly label="申请使用金额" v-model="item.incomeAmount" input-align="right" label-width="auto"/>
  60. <van-field readonly label="资金用途" v-model="item.remark" input-align="right" label-width="auto"/>
  61. </div>
  62. <p class="main_more" v-if="chargeItme.length>1 && showbtn" @click="listLength = chargeItme.length,showbtn=false">查看更多</p>
  63. <p class="main_more" v-if="chargeItme.length>1 && !showbtn" @click="listLength = 1,showbtn=true">收起列表</p>
  64. </div>
  65. <p class="main_title">上传附件</p>
  66. <div class="main_box" style="padding: 5px 0 0 0;">
  67. <van-cell value="收据" />
  68. <van-uploader v-model="fileList1" v-if="fileList1==null||fileList1.length==0" :deletable="false" disabled :upload-text="'未上传附件'" style="margin-left:8px;"></van-uploader>
  69. <van-uploader v-model="fileList1" v-if="fileList1!=null&&fileList1.length>0" :deletable="false" :max-count="fileList1.length" style="margin-left:8px;"></van-uploader>
  70. <van-cell value="发票" />
  71. <van-uploader v-model="fileList2" v-if="fileList2==null||fileList2.length==0" :deletable="false" disabled :upload-text="'未上传附件'" style="margin-left:8px;"></van-uploader>
  72. <van-uploader v-model="fileList2" v-if="fileList2!=null&&fileList2.length>0" :deletable="false" :max-count="fileList2.length" style="margin-left:8px;"></van-uploader>
  73. <van-cell value="其他" />
  74. <van-uploader v-model="fileList3" v-if="fileList3==null||fileList3.length==0" :deletable="false" disabled :upload-text="'未上传附件'" style="margin-left:8px;"></van-uploader>
  75. <van-uploader v-model="fileList3" v-if="fileList3!=null&&fileList3.length>0" :deletable="false" :max-count="fileList3.length" style="margin-left:8px;" ></van-uploader>
  76. </div>
  77. </div>
  78. </template>
  79. <script>
  80. import { getTransfer , queryTransferDetail , listPayee , updateTransfer , getProjectto ,
  81. listProject , addProjectto , customSubmit,getInfoto,listTemplate} from "@/api/onlineHome/bankAgriculture/paymentApproval";
  82. import request from '@/utils/request'
  83. import {
  84. attachmentList,
  85. commonAttach,
  86. getCash,
  87. listCashdetailByCashId
  88. } from "../../../../api/onlineHome/bankAgriculture/paymentApproval";
  89. export default {
  90. name: "approvalDetail11",
  91. data() {
  92. return {
  93. showcapital:false,
  94. showpayee:false,
  95. showlasj:false,
  96. showbankType:false,
  97. showproject:false,
  98. showFundType:false,
  99. showbtn:true,
  100. listLength:1,
  101. minDate: new Date(),
  102. maxDate: new Date(2025, 10, 1),
  103. currentDate: new Date(),
  104. form:{},
  105. fileList1:[],
  106. fileList2:[],
  107. fileList3:[],
  108. capitalExpenditureType:'',
  109. payee:'',
  110. bankType:'',
  111. wfydlxDictionaries:[],
  112. jglxDictionaries:[],
  113. sysDictionaries:[],
  114. capitalExpenditureTypeOptions:[],
  115. bankTypeDictionaries:[],
  116. projectList:[],
  117. projectFundTypeOptions:[],
  118. projectFundTypeDictionaries:[],
  119. projectListShow:[],
  120. chargeItme:[],
  121. chargeItmeShow:[],
  122. payeeList:[],
  123. // 查询参数
  124. queryParams: {
  125. transferType:11,
  126. orderByColumn: "id",
  127. isAsc: "desc",
  128. },
  129. capitalExpenditureOpen:false,
  130. contractOpen:false,
  131. projectForm:{
  132. projectId:null,
  133. projectName:null,
  134. projectContractor:null,
  135. projectAmount:null,
  136. projectBillNum:null,
  137. projectFundType:'1',
  138. outId:null,
  139. ynType:'1'
  140. },
  141. infoForm:{
  142. infoId:null,
  143. name:null,
  144. code:null,
  145. totalAmount:null,
  146. contractionId:null,
  147. transferId:null
  148. },
  149. projectFundType:'',
  150. templateList:[],
  151. };
  152. },
  153. created() {
  154. this.getDicts("project_fund_type").then((response) => {
  155. for (var i = 0; i < response.data.length; i++) {
  156. this.projectFundTypeOptions.push({text: response.data[i].dictLabel, value: response.data[i].dictValue});
  157. }
  158. this.projectFundTypeDictionaries = response.data;
  159. });
  160. this.getDictionaries();
  161. this.getFileList();
  162. this.getTemplateList();
  163. },
  164. methods: {
  165. getTemplateList(){
  166. let templateQueryParams = {
  167. // 分页
  168. pageNum: 1,
  169. pageSize: 999,
  170. };
  171. listTemplate(templateQueryParams).then(response => {
  172. this.templateList = response.rows;
  173. });
  174. },
  175. tempalteFormat(id){
  176. let name = ""
  177. this.templateList.map(res => {
  178. if(res.id==id){
  179. name = res.name
  180. }
  181. })
  182. return name
  183. },
  184. goFlow(){
  185. window.location='approvalProcess?id='+this.$route.query.id;
  186. },
  187. getDictionaries(){
  188. getCash(this.$route.query.id).then((response) => {
  189. this.getDicts("capital_expenditure_type").then((res) => {
  190. for (var i = 0; i < res.data.length; i++) {
  191. this.capitalExpenditureTypeOptions.push({text: res.data[i].dictLabel, value: res.data[i].dictValue});
  192. }
  193. this.capitalExpenditureType = this.selectDictLabel(res.data, response.data.capitalExpenditureType);
  194. });
  195. if(response.data.capitalExpenditureType==2){
  196. this.capitalExpenditureOpen = true
  197. let param={
  198. 'outId' : response.data.id,
  199. 'ynType' : '2'
  200. }
  201. getProjectto(param).then(res => {
  202. this.projectFundType = this.selectDictLabel(this.projectFundTypeDictionaries, res.data.projectFundType);
  203. this.projectForm = res.data
  204. })
  205. }else if(response.data.capitalExpenditureType==4){
  206. this.contractOpen = true
  207. let param={
  208. 'transferId' : response.data.id
  209. }
  210. getInfoto(param).then(res => {
  211. this.infoForm = res.data
  212. })
  213. }else{
  214. this.showproject = false
  215. }
  216. this.form = response.data;
  217. });
  218. listCashdetailByCashId(this.$route.query.id).then((response) => {
  219. this.chargeItme = response.data;
  220. console.log(response)
  221. this.getPayeeList();
  222. });
  223. },
  224. addChargeItme(index){
  225. this.chargeItme.splice(index + 1, 0, {
  226. payeeId: "", //收款方ID
  227. payee: "", //收款方
  228. payeeAccount: "", //收款账户
  229. bankDeposit: "", //开户银行
  230. incomeAmount: "", //收入金额
  231. bankType: "", //所属银行
  232. });
  233. },
  234. getPayeeList() {
  235. //普通转账
  236. this.queryParams.accountType = this.form.accountType
  237. this.queryParams.status = "0"
  238. listPayee(this.queryParams).then((response) => {
  239. for (var i = 0; i < response.rows.length; i++) {
  240. this.payeeList.push({text: response.rows[i].payee, value: response.rows[i].id});
  241. }
  242. });
  243. },
  244. getFileList(){
  245. let oData1= {
  246. tableId: this.$route.query.id,
  247. tableName: "t_yinnong_cash",
  248. bizPath: "yinnong",
  249. fileType: "1",
  250. }
  251. attachmentList(oData1).then(res => {
  252. res.rows.map(r => {
  253. let baseUrl = location.protocol+"//"+location.host+request.defaults.baseURL
  254. this.fileList1.push({"url":baseUrl + r.fileUrl,"file":new File([],r.fileName,{}),"id":r.id})
  255. })
  256. })
  257. let oData2= {
  258. tableId: this.$route.query.id,
  259. tableName: "t_yinnong_cash",
  260. bizPath: "yinnong",
  261. fileType: "2",
  262. }
  263. attachmentList(oData2).then(res => {
  264. res.rows.map(r => {
  265. let baseUrl = location.protocol+"//"+location.host+request.defaults.baseURL
  266. this.fileList2.push({"url":baseUrl + r.fileUrl,"file":new File([],r.fileName,{}),"id":r.id})
  267. })
  268. })
  269. let oData3= {
  270. tableId: this.$route.query.id,
  271. tableName: "t_yinnong_cash",
  272. bizPath: "yinnong",
  273. fileType: "3",
  274. }
  275. attachmentList(oData3).then(res => {
  276. res.rows.map(r => {
  277. let baseUrl = location.protocol+"//"+location.host+request.defaults.baseURL
  278. this.fileList3.push({"url":baseUrl + r.fileUrl,"file":new File([],r.fileName,{}),"id":r.id})
  279. })
  280. })
  281. },
  282. goBack(){
  283. window.history.go(-1)
  284. },
  285. //删除家庭成员
  286. deleteChargeItme(index){
  287. this.chargeItme.splice(index,1)
  288. },
  289. },
  290. }
  291. </script>
  292. <style scoped lang="scss">
  293. .app-container {
  294. padding: 2% 0;
  295. }
  296. .main_more{
  297. width: 96%;
  298. margin: 0 auto;
  299. margin-top: 10px;
  300. border-radius: 6px;
  301. box-shadow: 0px 3px 6px 0px rgba(0,0,0,0.16);
  302. overflow: hidden;
  303. background-color: #FFF;
  304. text-align: center;
  305. padding: 10PX 0;
  306. }
  307. .main_title{
  308. font-size: 0.4rem;
  309. color: #1D6FE9;
  310. margin: 0.2rem 6%;
  311. position: relative;
  312. }
  313. .main_box{
  314. width: 96%;
  315. margin: 0 auto;
  316. border-radius: 6px;
  317. box-shadow: 0px 3px 6px 0px rgba(0,0,0,0.16);
  318. overflow: hidden;
  319. background-color: #FFF;
  320. }
  321. .submitButton{
  322. width: 80%;
  323. margin: 0 auto;
  324. background-color: #1D6FE9;
  325. }
  326. .addFamily{
  327. position: absolute;
  328. top: -2px;
  329. right: 0;
  330. border-radius: 50%;
  331. }
  332. .deleteFamily{
  333. position: absolute;
  334. top: 0rem;
  335. right: 6%;
  336. z-index: 9;
  337. border-radius: 50%;
  338. }
  339. </style>