recordSeal.vue 50 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585
  1. <template>
  2. <div class="app-container zap-main">
  3. <el-row>
  4. <el-form
  5. ref="form"
  6. :model="form"
  7. :inline="true"
  8. :rules="rules"
  9. label-width="95px"
  10. >
  11. <div class="zap-title">申请融资信息</div>
  12. <el-row class="zap-form" style="padding-bottom: 0">
  13. <el-col :span="12">
  14. <el-form-item label="选择融信:" prop="zfrFinanceId" size="large">
  15. <el-select
  16. v-model="form.zfrFinanceId"
  17. clearable
  18. @clear="clearBoth"
  19. disabled
  20. >
  21. <el-option
  22. v-for="(item, index) in financeInfList"
  23. :key="index"
  24. :label="item.zfiNumber"
  25. :value="item.zfiId"
  26. @click.native="amount(item)"
  27. ></el-option>
  28. </el-select>
  29. </el-form-item>
  30. </el-col>
  31. <el-col :span="12">
  32. <el-form-item
  33. label="融资收款账户:"
  34. prop="zfrCollectionAccount"
  35. size="large"
  36. label-width="101px"
  37. >
  38. <el-input
  39. v-model="form.zfrCollectionAccount"
  40. clearable
  41. placeholder="请输入融资账户"
  42. maxlength="25"
  43. readonly
  44. />
  45. </el-form-item>
  46. </el-col>
  47. </el-row>
  48. <el-row class="zap-form" style="padding-bottom: 0">
  49. <el-col :span="12">
  50. <el-form-item label="融信金额:" prop="zfiAmount" size="large">
  51. <el-input
  52. v-model="form.zfiAmount"
  53. clearable
  54. placeholder="请输入融信金额"
  55. maxlength="25"
  56. readonly
  57. >
  58. <template slot="append">元</template>
  59. </el-input>
  60. </el-form-item>
  61. </el-col>
  62. <el-col :span="12">
  63. <el-form-item label="申请融资方:" prop="companyName" size="large">
  64. <el-input
  65. v-model="form.companyName"
  66. clearable
  67. placeholder="请输入申请融资方"
  68. maxlength="25"
  69. readonly
  70. />
  71. </el-form-item>
  72. </el-col>
  73. </el-row>
  74. <el-row class="zap-form" style="padding-bottom: 0">
  75. <el-col :span="12">
  76. <el-form-item label="融资金额:" prop="zfrAmount" size="large">
  77. <el-input
  78. v-model="form.zfrAmount"
  79. clearable
  80. placeholder="请输入融资金额"
  81. maxlength="25"
  82. readonly
  83. >
  84. <template slot="append">元</template>
  85. </el-input>
  86. </el-form-item>
  87. </el-col>
  88. <el-col :span="12">
  89. <el-form-item label="融资利率:" prop="zfrRate" size="large">
  90. <el-input
  91. v-model="form.zfrRate"
  92. clearable
  93. placeholder="请输入融资利率"
  94. maxlength="25"
  95. readonly
  96. >
  97. <template slot="append">%</template>
  98. </el-input>
  99. </el-form-item>
  100. </el-col>
  101. </el-row>
  102. <el-row class="zap-form" style="padding-bottom: 0">
  103. <el-col :span="12">
  104. <el-form-item
  105. label="承诺还款日期:"
  106. prop="zfrRepaymentDate"
  107. size="large"
  108. label-width="101px"
  109. >
  110. <el-input
  111. v-model="form.zfrRepaymentDate"
  112. clearable
  113. placeholder="请输入承诺还款日期"
  114. maxlength="25"
  115. readonly
  116. />
  117. </el-form-item>
  118. </el-col>
  119. <el-col :span="12">
  120. <el-form-item label="服务费率:" prop="zfpcrChargeRate" size="large">
  121. <el-input
  122. v-model="form.zfpcrChargeRate"
  123. clearable
  124. placeholder="请输入服务费率"
  125. maxlength="25"
  126. readonly
  127. >
  128. <template slot="append">%</template>
  129. </el-input>
  130. </el-form-item>
  131. </el-col>
  132. </el-row>
  133. <el-row class="zap-form" style="padding-bottom: 0">
  134. <el-col :span="12">
  135. <el-form-item
  136. label="预计融资成本:"
  137. prop="cost"
  138. size="large"
  139. label-width="101px"
  140. >
  141. <el-input
  142. v-model="form.cost"
  143. clearable
  144. placeholder="请输入预计融资成本"
  145. maxlength="25"
  146. readonly
  147. >
  148. <template slot="append">元</template>
  149. </el-input>
  150. </el-form-item>
  151. </el-col>
  152. <el-col :span="12">
  153. <el-form-item
  154. label="预计融资期限:"
  155. prop="term"
  156. size="large"
  157. label-width="101px"
  158. >
  159. <el-input
  160. v-model="form.term"
  161. clearable
  162. placeholder="请输入预计融资期限"
  163. maxlength="25"
  164. readonly
  165. >
  166. <template slot="append">天</template>
  167. </el-input>
  168. </el-form-item>
  169. </el-col>
  170. </el-row>
  171. <el-row class="zap-form" style="padding-bottom: 0">
  172. <el-col :span="12">
  173. <el-form-item
  174. label="预计净融资额:"
  175. prop="amount"
  176. size="large"
  177. label-width="101px"
  178. >
  179. <el-input
  180. v-model="form.amount"
  181. clearable
  182. placeholder="请输入预计净融资额"
  183. maxlength="25"
  184. readonly
  185. >
  186. <template slot="append">元</template>
  187. </el-input>
  188. </el-form-item>
  189. </el-col>
  190. </el-row>
  191. <div class="contain">
  192. <p>说明:</p>
  193. <p>1. 因银行结算原因,资金到账可能会在申请日期后2-5工作日;</p>
  194. <p>
  195. 2.
  196. 申请融资时,预计融资成本、预计融资期限、预计净融资额,由申请日期单日开始计算;准确数值以银行实际放款日期为准;
  197. </p>
  198. <p>
  199. 3.
  200. 因填写融资收款账户错误,或其他原因导致银行无法正常放款,款项将汇入备用收款账户,可在电子账户管理查看;
  201. </p>
  202. <p>4. 服务费缴纳与退还要求,可详细阅读《融信产品使用协议》</p>
  203. </div>
  204. <div class="zap-title">融信信息</div>
  205. <el-row class="zap-form">
  206. <el-col>
  207. <span style="font-size: 14px; color: #333333">融信凭证</span>
  208. </el-col>
  209. <table
  210. class="gridtable"
  211. style="width: 80%; text-align: center"
  212. align="center"
  213. >
  214. <tr>
  215. <td rowspan="4">开立方</td>
  216. <td>全称</td>
  217. <td>{{ openName }}</td>
  218. <td rowspan="4">接收方</td>
  219. <td>全称</td>
  220. <td>{{ receiveName }}</td>
  221. </tr>
  222. <tr>
  223. <td>社会统一码</td>
  224. <td>{{ openCode }}</td>
  225. <td>社会统一码</td>
  226. <td>{{ receiverCode }}</td>
  227. </tr>
  228. <tr>
  229. <td>开户银行</td>
  230. <td>{{ openBank }}</td>
  231. <td>开户银行</td>
  232. <td>{{ receiverBank }}</td>
  233. </tr>
  234. <tr>
  235. <td>账号</td>
  236. <td>{{ openAccount }}</td>
  237. <td>账号</td>
  238. <td>{{ receiverAccount }}</td>
  239. </tr>
  240. <tr>
  241. <td colspan="2">粮信金额</td>
  242. <td colspan="4">
  243. 人民币(大写):{{ issuedAmount }}<br />人民币(小写)¥{{
  244. form.zfiAmount
  245. }}
  246. </td>
  247. </tr>
  248. <tr>
  249. <td colspan="2">起止日期</td>
  250. <td colspan="4">{{ stopDate }}</td>
  251. </tr>
  252. </table>
  253. </el-row>
  254. <el-row class="zap-form">
  255. <el-row type="flex" align="middle" justify="end">
  256. <el-col>
  257. <span style="font-size: 14px; color: #333333">资产信息</span>
  258. </el-col>
  259. <el-col class="zap-margin-top;">
  260. <el-row type="flex" align="middle" justify="end">
  261. <el-form-item label="金额大写:" class="zap-margin-clear">
  262. <span>{{ smallToBig(allAmount()) }}</span>
  263. </el-form-item>
  264. <el-form-item label="合计金额:" class="zap-margin-clear">
  265. <span>{{ allAmount() }}</span>
  266. </el-form-item>
  267. </el-row>
  268. </el-col>
  269. </el-row>
  270. <el-row class="zap-margin-top">
  271. <el-table :data="billInfList" border stripe>
  272. <el-table-column
  273. label="序号"
  274. type="index"
  275. width="50"
  276. align="center"
  277. >
  278. <template slot-scope="scope">
  279. <span>{{
  280. (queryParams.pageNum - 1) * queryParams.pageSize +
  281. scope.$index +
  282. 1
  283. }}</span>
  284. </template>
  285. </el-table-column>
  286. <el-table-column label="编号" align="center" prop="zbiNumber" />
  287. <el-table-column label="账款名称" align="center" prop="zbiName" />
  288. <el-table-column label="应收企业" align="center" prop="payee" />
  289. <el-table-column label="应付企业" align="center" prop="payer" />
  290. <el-table-column
  291. label="还款时间"
  292. align="center"
  293. prop="zbiPayDate"
  294. />
  295. <el-table-column label="金额" align="center" prop="zbiAmount" />
  296. <el-table-column
  297. label="操作"
  298. align="center"
  299. class-name="small-padding fixed-width"
  300. width="250"
  301. fixed="right"
  302. >
  303. <template slot-scope="scope">
  304. <el-button
  305. size="mini"
  306. type="text"
  307. icon="el-icon-view"
  308. @click="handleDetail(scope.$index, billInfList)"
  309. >详情</el-button
  310. >
  311. </template>
  312. </el-table-column>
  313. </el-table>
  314. </el-row>
  315. </el-row>
  316. </el-form>
  317. <!-- 签署合同 -->
  318. <el-row class="zap-margin-top zap-form">
  319. <div class="zap-title">签署合同</div>
  320. <el-row class="zap-form" type="flex">
  321. <attachments v-for="(item, index) in creditSealList" :key="index" :fileName="item.pfiFileName">
  322. <img class="" src="../../../assets/images/pdf.png" />
  323. <div class="attachements__marker" slot="marker">
  324. <el-button class="zap-button-primary" size="mini" @click="handleDownload(item)">下载</el-button>
  325. <el-button class="zap-button-primary" size="mini" @click="handlePreview(item)">预览</el-button>
  326. </div>
  327. </attachments>
  328. </el-row>
  329. </el-row>
  330. <el-row type="flex" align="middle" justify="center" style="height: 77px">
  331. <el-button type="primary" @click="selectPayment">合同签署</el-button>
  332. <el-button type="primary" plain="" @click="cancel">取消</el-button>
  333. </el-row>
  334. </el-row>
  335. <!-- 附件详情 -->
  336. <el-dialog
  337. title="详情"
  338. :visible.sync="openDetailBill"
  339. width="1120px"
  340. append-to-body
  341. >
  342. <detail-bill :zbiId="this.zbiId" v-if="openDetailBill"></detail-bill>
  343. </el-dialog>
  344. <!--预览-->
  345. <el-dialog :visible.sync="openFile" width="1000px" append-to-body>
  346. <img :src="wordUrl" v-if="show" width="700px" height="500px" />
  347. <iframe
  348. :src="wordUrl"
  349. width="800px"
  350. height="600px"
  351. frameborder="1"
  352. v-if="heid"
  353. />
  354. </el-dialog>
  355. <!-- 合同预览 -->
  356. <el-dialog title="合同预览" :visible.sync="pdfShowDialog" width="60%" append-to-body :show-close="pdfIsShow">
  357. <pdf-show
  358. :pdfFileList="pdfFileList"
  359. :zfiId="this.form.zfiId"
  360. :parent="parent"
  361. ></pdf-show>
  362. <span slot="footer" class="dialog-footer">
  363. <el-button type="primary" @click="selectType" v-if="pdfIsShow">签署</el-button>
  364. <el-button type="primary" plain="" @click="pdfShowDialog = false" v-if="pdfIsShow"
  365. >取消</el-button>
  366. <el-button type="primary" @click="closePDF" v-if="!pdfIsShow">确定</el-button>
  367. </span>
  368. </el-dialog>
  369. <!--选择签署意愿类型-->
  370. <el-dialog
  371. title="签署意愿"
  372. :visible.sync="confirmIsShow"
  373. width="600px"
  374. append-to-body
  375. :before-close="cancelUpdate"
  376. center
  377. >
  378. <el-form
  379. ref="updateForm"
  380. :disabled="false"
  381. :model="updateForm"
  382. v-if="confirmIsShow"
  383. label-width="150px"
  384. class="demo-form-inline"
  385. :inline="true"
  386. >
  387. <el-radio-group v-model="updateForm.radio">
  388. <el-radio label="01">人脸</el-radio>
  389. <el-radio label="02">短信</el-radio>
  390. </el-radio-group>
  391. </el-form>
  392. <div slot="footer" class="dialog-footer">
  393. <el-button type="primary" @click="confirmSelect">确 定</el-button>
  394. <el-button @click="cancelUpdate">取 消</el-button>
  395. </div>
  396. </el-dialog>
  397. <!--盖章短信-->
  398. <el-dialog
  399. title="短信验证"
  400. :visible.sync="messageIsShow"
  401. width="600px"
  402. append-to-body
  403. :before-close="cancelMessage"
  404. center
  405. >
  406. <el-form
  407. ref="messageForm"
  408. :disabled="false"
  409. :model="messageForm"
  410. v-if="messageIsShow"
  411. label-width="150px"
  412. class="demo-form-inline"
  413. :inline="true"
  414. @submit.native.prevent
  415. >
  416. <el-form-item label="验证码" prop="validCode">
  417. <el-input
  418. v-model="messageForm.validCode"
  419. style="width: 200px"
  420. maxlength="6"
  421. />
  422. </el-form-item>
  423. <el-form-item>
  424. <el-button :disabled="!showCode" type="success" @click="send">
  425. 点击获取验证码
  426. <span v-show="!showCode" class="count">{{ count }} s</span>
  427. </el-button>
  428. </el-form-item>
  429. </el-form>
  430. <div slot="footer" class="dialog-footer">
  431. <el-button type="primary" @click="checkCode">确定</el-button>
  432. <el-button @click="cancelMessage">取 消</el-button>
  433. </div>
  434. </el-dialog>
  435. <!--授权编号激活短信-->
  436. <el-dialog
  437. :visible.sync="messageIfShow"
  438. width="600px"
  439. append-to-body
  440. :before-close="cancelMessages"
  441. center
  442. >
  443. <el-divider content-position="left">cfca签章授权编号激活</el-divider>
  444. <el-form
  445. ref="messageForm"
  446. :disabled="false"
  447. :model="messagesForm"
  448. v-if="messageIfShow"
  449. label-width="150px"
  450. class="demo-form-inline"
  451. :inline="true"
  452. @submit.native.prevent
  453. >
  454. <el-form-item label="验证码" prop="validCode">
  455. <el-input
  456. v-model="messagesForm.validCode"
  457. style="width: 200px"
  458. maxlength="6"
  459. />
  460. </el-form-item>
  461. <el-form-item>
  462. <el-button :disabled="!showCodes" type="success" @click="proSend">
  463. 点击获取验证码
  464. <span v-show="!showCodes" class="count">{{ countCode }} s</span>
  465. </el-button>
  466. </el-form-item>
  467. </el-form>
  468. <div slot="footer" class="dialog-footer">
  469. <el-button type="primary" @click="checkProCode">确定</el-button>
  470. <el-button @click="cancelMessages">取 消</el-button>
  471. </div>
  472. </el-dialog>
  473. <!--人脸二维码-->
  474. <el-dialog
  475. title="人脸验证"
  476. :visible.sync="faceIsShow"
  477. width="500px"
  478. append-to-body
  479. :before-close="cancelFace"
  480. center
  481. >
  482. <img
  483. :src="'data:image/jpeg;base64,' + this.fileUrl"
  484. style="overflow: auto; width: 100%; height: 100%"
  485. />
  486. </el-dialog>
  487. </div>
  488. </template>
  489. <script>
  490. import {
  491. addRecord,
  492. listBillInf,
  493. listAccInf,
  494. getContractFile,
  495. getRecord,
  496. contractSigning,
  497. updateChargeStatus,
  498. listChargeStatus,
  499. cancelContract,
  500. listStamped
  501. } from "@/api/service/financeRecord/record";
  502. import { listFinanceInf } from "@/api/common/financeInf";
  503. import { getFile } from "@/api/service/credit/credit";
  504. import { getToken } from "@/utils/auth";
  505. import { getUserProfile } from "@/api/system/user";
  506. import { getCreditDetail } from "@/api/service/credit/credit";
  507. import { getCreditSealFile } from "@/api/service/credit/creditHandle";
  508. import DetailBill from "@/views/service/credit/billDetail";
  509. import { isOpenApproval } from "@/api/service/credit/approvalRelatedCredit";
  510. import { listCompanyHandler } from "@/api/common/companyHandler";
  511. import {
  512. sendMessage,
  513. checkCode,
  514. faceAuth,
  515. checkFaceAuth,
  516. } from "@/api/service/credit/message";
  517. import {
  518. cfcaProjectNo,
  519. projectSendMessage,
  520. checkProCode,
  521. } from "@/api/service/credit/cfcaProject";
  522. import { balance, transfer } from "@/api/bank/bankInterface";
  523. import pdfShow from "@/views/service/financeRecord/pdfShow";
  524. export default {
  525. name: "financeRecord",
  526. components: { DetailBill, pdfShow },
  527. data() {
  528. return {
  529. pdfIsShow: true,
  530. //往来账款id
  531. zbiId: "",
  532. //融资账户是够编辑
  533. onlyRead: false,
  534. // 遮罩层
  535. loading: true,
  536. // 选中数组
  537. ids: [],
  538. // 非单个禁用
  539. single: true,
  540. // 非多个禁用
  541. multiple: true,
  542. // 显示搜索条件
  543. showSearch: true,
  544. // 总条数
  545. total: 0,
  546. // 全部融资记录表格数据
  547. recordList: [],
  548. //融信编号数据
  549. financeInfList: [],
  550. //应收账款
  551. billInfList: [],
  552. //合同附件
  553. contractFileList: [],
  554. //发票附件
  555. invoiceFileList: [],
  556. //其他文件
  557. otherFileList: [],
  558. //盖章文件
  559. creditSealList: [],
  560. //开立方
  561. openName: "",
  562. //开立社会码
  563. openCode: "",
  564. //开立银行
  565. openBank: "",
  566. //开立账户
  567. openAccount: "",
  568. //接收方
  569. receiveName: "",
  570. //接收方社会统一码
  571. receiverCode: "",
  572. //接收方银行
  573. receiverBank: "",
  574. //接收方账户
  575. receiverAccount: "",
  576. //起止日期
  577. stopDate: "",
  578. //签发金额大写
  579. issuedAmount: "零元整",
  580. // 弹出层标题
  581. title: "",
  582. // 是否显示弹出层
  583. open: false,
  584. openDetailBill: false,
  585. //人脸验证结果
  586. faceResult:"",
  587. //人脸识别结果传参
  588. authForm:{},
  589. // 查询参数
  590. queryParams: {
  591. pageNum: 1,
  592. pageSize: 10,
  593. zfrFinanceId: null,
  594. zfrNumber: null,
  595. zfrAmount: null,
  596. zfrRate: null,
  597. zfrHandler: null,
  598. zfrRepaymentDate: null,
  599. zfrApplyDate: null,
  600. zfrLoanDate: null,
  601. zfrApplyAmount: null,
  602. zfrApplyType: null,
  603. zfrStatus: null,
  604. zfrApproveStt: null,
  605. zfpcrLoanType: null,
  606. zfiProductId: null,
  607. },
  608. queryParamsDown: {
  609. pfiFileUrl: null,
  610. },
  611. // 表单参数
  612. form: {},
  613. forms: {},
  614. // 表单校验
  615. rules: {
  616. zfrFinanceId: [
  617. {
  618. required: true,
  619. message: "融信编号不能为空",
  620. trigger: "blur",
  621. },
  622. ],
  623. zfrAmount: [
  624. {
  625. required: true,
  626. message: "融资金额不能为空",
  627. trigger: "blur",
  628. },
  629. ],
  630. },
  631. openFile: false,
  632. wordUrl: "",
  633. heid: false,
  634. show: false,
  635. //盖章预览
  636. parent: this,
  637. pdfShowDialog: false,
  638. pdfFileList: [],
  639. confirmIsShow: false,
  640. messageIsShow: false,
  641. messageIfShow: false,
  642. faceIsShow: false,
  643. fileUrl: "",
  644. //意愿
  645. updateForm: {},
  646. messageForm: {},
  647. messagesForm: {},
  648. count: "",
  649. timer: null,
  650. //授权编号激活短信验证码倒计时
  651. //项目编号
  652. projectCode: "",
  653. showCode: true,
  654. showCodes: true,
  655. countCode: "",
  656. timerCode: null,
  657. zfrId: null,
  658. };
  659. },
  660. created() {
  661. this.zfrId = this.$route.params && this.$route.params.zfrId;
  662. getRecord(this.zfrId).then((response) => {
  663. this.zcFinanceInf = response.data.zcFinanceInf;
  664. this.needPay = response.data.needPay;
  665. //意愿类型
  666. this.zfpAuthType = response.data.zfpAuthType;
  667. const zfiId = response.data.zcFinanceInf.zfiId;
  668. this.$set(this.form, "zfrFinanceId", zfiId);
  669. this.$set(this.form,"zfrCollectionAccount",response.data.zfrCollectionAccount);
  670. this.getFinanceInf(zfiId);
  671. });
  672. this.getUserProfile();
  673. },
  674. methods: {
  675. /** 查询融信编号 */
  676. getFinanceInf(zfrFinanceId) {
  677. this.loading = true;
  678. listFinanceInf(zfrFinanceId).then((response) => {
  679. if (response.data) {
  680. this.financeInfList = response.data;
  681. for (let item of this.financeInfList) {
  682. if (item.zfiId == zfrFinanceId) {
  683. this.amount(item);
  684. }
  685. }
  686. this.loading = false;
  687. }
  688. });
  689. },
  690. getUserProfile() {
  691. getUserProfile().then((response) => {
  692. if (response.company) {
  693. this.$set(this.form, "companyName", response.company.scyName);
  694. }
  695. });
  696. },
  697. //获取盖章文件
  698. getCreditSealFile() {
  699. getCreditSealFile(this.forms).then((response) => {
  700. if (response.data.list) {
  701. this.creditSealList = response.data.list;
  702. }
  703. });
  704. },
  705. // 取消按钮
  706. cancel() {
  707. this.$store.dispatch("tagsView/delView", this.$route);
  708. this.$router.go(-1);
  709. },
  710. // 表单重置
  711. reset() {
  712. this.form = {
  713. zfrId: null,
  714. zfrFinanceId: null,
  715. zfrNumber: null,
  716. zfrAmount: null,
  717. zfrRate: null,
  718. zfrHandler: null,
  719. zfrRepaymentDate: null,
  720. zfrApplyDate: null,
  721. zfrLoanDate: null,
  722. zfrApplyAmount: null,
  723. zfrApplyType: null,
  724. zfrStatus: "00",
  725. zfrApproveStt: null,
  726. zfrProfitSpare1: null,
  727. zfrProfitSpare2: null,
  728. zfrProfitSpare3: null,
  729. zfrProfitSpare4: null,
  730. zfrProfitSpare5: null,
  731. zfrProfitSpare6: null,
  732. zfrProfitSpare7: null,
  733. zfrProfitSpare8: null,
  734. zfrProfitSpare9: null,
  735. createBy: null,
  736. createTime: null,
  737. updateBy: null,
  738. updateTime: null,
  739. };
  740. this.resetForm("form");
  741. },
  742. /** 全部搜索按钮操作 */
  743. handleQuery() {
  744. this.queryParams.pageNum = 1;
  745. this.getList();
  746. },
  747. /** 全部重置按钮操作 */
  748. resetQuery() {
  749. this.resetForm("queryForm");
  750. this.handleQuery();
  751. },
  752. //全部 多选框选中数据
  753. handleSelectionChange(selection) {
  754. this.ids = selection.map((item) => item.zfrId);
  755. this.single = selection.length !== 1;
  756. this.multiple = !selection.length;
  757. },
  758. /* 融信编号赋值融资金额 */
  759. amount(item) {
  760. this.$set(this.form, "zfrAmount", item.zfiAmount);
  761. this.$set(this.form, "zfiAmount", item.zfiAmount);
  762. this.$set(this.form, "zfrRepaymentDate", item.zfiExpireDate);
  763. this.$set(this.form, "zfrRate", item.zfpcrRate);
  764. this.$set(this.form, "zfpcrLoanType", item.zfpcrLoanType);
  765. this.$set(this.form, "zfiProductId", item.zfiProductId);
  766. this.$set(this.form, "zfpcrChargeRate", item.zfpcrChargeRate);
  767. this.$set(this.form, "cost", item.cost);
  768. this.$set(this.form, "term", item.term);
  769. this.$set(this.form, "amount", item.amount);
  770. if (item.zfiId) {
  771. this.loading = true;
  772. listBillInf(item.zfiId)
  773. .then((response) => {
  774. this.billInfList = response.data;
  775. this.loading = false;
  776. })
  777. .then(() => {
  778. var queryParamsFile = {};
  779. queryParamsFile.ticketList = this.billInfList;
  780. getFile(queryParamsFile).then((response) => {
  781. if (response.data) {
  782. //获取发票文件
  783. this.invoiceFileList = response.data.invoiceFileList;
  784. //获取合同文件
  785. this.contractFileList = response.data.contractFileList;
  786. //获取其他文件
  787. this.otherFileList = response.data.otherFileList;
  788. }
  789. });
  790. if (item.zfpcrLoanType == "0") {
  791. listAccInf(item.zfiProductId).then((response) => {
  792. this.$set(this.form, "zfrCollectionAccount", response.msg);
  793. this.onlyRead = true;
  794. });
  795. }
  796. });
  797. getCreditDetail(item.zfiId).then((response) => {
  798. if (response.data) {
  799. this.forms = response.data.financeInf;
  800. //签发金额大写
  801. this.issuedAmount = this.smallToBig(this.forms.zfiAmount);
  802. //给表格赋值
  803. this.openName = response.data.openName;
  804. this.openCode = response.data.openCode;
  805. this.openBank = response.data.openBank;
  806. this.openAccount = response.data.openAccount;
  807. this.receiveName = response.data.receiveName;
  808. this.receiverCode = response.data.receiverCode;
  809. this.receiverBank = response.data.receiverBank;
  810. this.receiverAccount = response.data.receiverAccount;
  811. this.stopDate = response.data.stopDate;
  812. this.zfiRate = response.data.financeInf.zfiRate;
  813. }
  814. //盖章合同
  815. this.getCreditSealFile();
  816. });
  817. }
  818. },
  819. //详情按钮
  820. handleDetail(index, rows) {
  821. this.zbiId = rows[index].zbiId;
  822. this.openDetailBill = true;
  823. },
  824. /** 提交按钮 */
  825. submitForm() {
  826. this.$refs["form"].validate((valid) => {
  827. if (valid) {
  828. const loading = this.$loading({
  829. lock: true,
  830. text: "Loading",
  831. spinner: "el-icon-loading",
  832. background: "rgba(0, 0, 0, 0.7)",
  833. });
  834. addRecord(this.form)
  835. .then((response) => {
  836. loading.close();
  837. this.zfrId = response.data.zfrId;
  838. this.isOpenApproval();
  839. // this.msgSuccess("融资申请成功");
  840. // this.$store.dispatch("tagsView/delView", this.$route);
  841. // this.$router.go(-1);
  842. })
  843. .catch((response) => {
  844. loading.close();
  845. });
  846. }
  847. });
  848. },
  849. /* 清空 */
  850. clearBoth() {
  851. this.form.zfrAmount = "";
  852. this.form, (zfrRepaymentDate = "");
  853. this.form.zfrRate = "";
  854. this.form.zfpcrLoanType = "";
  855. this.billInfList = [];
  856. this.contractFileList = [];
  857. this.invoiceFileList = [];
  858. this.otherFileList = [];
  859. },
  860. //文件下载
  861. handleDownload(row) {
  862. debugger;
  863. const pfiFileUrl = row.pfiFileUrl;
  864. if (pfiFileUrl != null && pfiFileUrl != "") {
  865. const pfiFileName = row.pfiFileName;
  866. this.queryParamsDown.pfiFileUrl = pfiFileUrl;
  867. this.download(
  868. "sc-service/creditLine/jpgAuthorization",
  869. {
  870. ...this.queryParamsDown,
  871. },
  872. pfiFileName
  873. );
  874. // window.open(pfiUrl + "/" + getToken());
  875. } else {
  876. this.$message({
  877. message: "该附件不存在!",
  878. type: "warning",
  879. });
  880. return;
  881. }
  882. },
  883. //预览
  884. handlePreview(row) {
  885. const pfiUrl = row.pfiUrl;
  886. const pfiFileName = row.pfiFileName;
  887. if (row.pfiUrl) {
  888. console.log(pfiFileName.substr(-3));
  889. if (pfiFileName.substr(-3) == "pdf") {
  890. this.wordUrl = pfiUrl + "/" + getToken();
  891. this.show = false;
  892. this.heid = true;
  893. } else if (
  894. pfiFileName.substr(-3) == "jpg" ||
  895. pfiFileName.substr(-3) == "png" ||
  896. pfiFileName.substr(-3) == "JPG" ||
  897. pfiFileName.substr(-3) == "PNG" ||
  898. pfiFileName.substr(-4) == "jpeg" ||
  899. pfiFileName.substr(-3) == "JPEG"
  900. ) {
  901. this.wordUrl = pfiUrl + "/" + getToken();
  902. this.show = true;
  903. this.heid = false;
  904. console.log("====>", this.wordUrl);
  905. } else if (
  906. pfiFileName.substr(-3) == "doc" ||
  907. pfiFileName.substr(-3) == "DOC" ||
  908. pfiFileName.substr(-4) == "docx" ||
  909. pfiFileName.substr(-3) == "DOCX"
  910. ) {
  911. this.wordUrl =
  912. "https://view.officeapps.live.com/op/view.aspx?src=" +
  913. pfiUrl +
  914. "/" +
  915. getToken() +
  916. "/" +
  917. pfiFileName;
  918. this.show = false;
  919. this.heid = true;
  920. console.log("====>", this.wordUrl);
  921. } else {
  922. this.$message({
  923. message: "暂不支持该类型文件预览",
  924. type: "warning",
  925. });
  926. return;
  927. }
  928. }
  929. this.openFile = true;
  930. },
  931. //应收账款合计
  932. allAmount() {
  933. var strarr = [0.0];
  934. for (let i in this.billInfList) {
  935. strarr.push(this.billInfList[i]["zbiAmount"]);
  936. }
  937. return Math.round(eval(strarr.join("+")) * 100) / 100; //结果
  938. },
  939. /* // 将数字金额转换为大写金额 */
  940. smallToBig(money) {
  941. // 将数字金额转换为大写金额
  942. var cnNums = new Array(
  943. "零",
  944. "壹",
  945. "贰",
  946. "叁",
  947. "肆",
  948. "伍",
  949. "陆",
  950. "柒",
  951. "捌",
  952. "玖"
  953. ); //汉字的数字
  954. var cnIntRadice = new Array("", "拾", "佰", "仟"); //基本单位
  955. var cnIntUnits = new Array("", "万", "亿", "兆"); //对应整数部分扩展单位
  956. var cnDecUnits = new Array("角", "分", "毫", "厘"); //对应小数部分单位
  957. var cnInteger = "整"; //整数金额时后面跟的字符
  958. var cnIntLast = "元"; //整数完以后的单位
  959. //最大处理的数字
  960. var maxNum = 999999999999999.9999;
  961. var integerNum; //金额整数部分
  962. var decimalNum; //金额小数部分
  963. //输出的中文金额字符串
  964. var chineseStr = "";
  965. var parts; //分离金额后用的数组,预定义
  966. if (money == "" || money == null || money == undefined) {
  967. return "零元零角零分";
  968. }
  969. money = parseFloat(money);
  970. if (money >= maxNum) {
  971. //超出最大处理数字
  972. return "超出最大处理数字";
  973. }
  974. if (money == 0) {
  975. chineseStr = cnNums[0] + cnIntLast + cnInteger;
  976. return chineseStr;
  977. }
  978. //四舍五入保留两位小数,转换为字符串
  979. money = Math.round(money * 100).toString();
  980. integerNum = money.substr(0, money.length - 2);
  981. decimalNum = money.substr(money.length - 2);
  982. //获取整型部分转换
  983. if (parseInt(integerNum, 10) > 0) {
  984. var zeroCount = 0;
  985. var IntLen = integerNum.length;
  986. for (var i = 0; i < IntLen; i++) {
  987. var n = integerNum.substr(i, 1);
  988. var p = IntLen - i - 1;
  989. var q = p / 4;
  990. var m = p % 4;
  991. if (n == "0") {
  992. zeroCount++;
  993. } else {
  994. if (zeroCount > 0) {
  995. chineseStr += cnNums[0];
  996. }
  997. //归零
  998. zeroCount = 0;
  999. chineseStr += cnNums[parseInt(n)] + cnIntRadice[m];
  1000. }
  1001. if (m == 0 && zeroCount < 4) {
  1002. chineseStr += cnIntUnits[q];
  1003. }
  1004. }
  1005. chineseStr += cnIntLast;
  1006. }
  1007. //小数部分
  1008. if (decimalNum != "") {
  1009. var decLen = decimalNum.length;
  1010. for (var i = 0; i < decLen; i++) {
  1011. var n = decimalNum.substr(i, 1);
  1012. if (n != "0") {
  1013. chineseStr += cnNums[Number(n)] + cnDecUnits[i];
  1014. }
  1015. }
  1016. }
  1017. if (chineseStr == "") {
  1018. chineseStr += cnNums[0] + cnIntLast + cnInteger;
  1019. } else if (decimalNum == "" || /^0*$/.test(decimalNum)) {
  1020. chineseStr += cnInteger;
  1021. }
  1022. return chineseStr;
  1023. },
  1024. /** 导出按钮操作 */
  1025. handleExport() {
  1026. this.download(
  1027. "sc-service/record/export",
  1028. {
  1029. ...this.queryParams,
  1030. },
  1031. `sc-service_record.xlsx`
  1032. );
  1033. },
  1034. // 取消按钮
  1035. cancelFtp() {
  1036. let form = {};
  1037. form.zfrId = this.zfrId;
  1038. cancelContract(form).then((response) => {
  1039. this.cancel();
  1040. });
  1041. this.pdfShowDialog = false;
  1042. },
  1043. //查询有无融资内部审批
  1044. isOpenApproval() {
  1045. var confirmParam = {};
  1046. confirmParam.menuId = "1000000006";
  1047. isOpenApproval(confirmParam).then((response) => {
  1048. var result = response.data.isOpen;
  1049. //有融资内部审批
  1050. if (true == result) {
  1051. this.msgSuccess("已提交内部审批,请内部审批通过后签署融资协议");
  1052. this.cancel();
  1053. } else {
  1054. //无融资内部审批,显示融资合同预览页面
  1055. // this.zfrId = '2c83a92dc238468aabd9cd3261748ae0'
  1056. getRecord(this.zfrId).then((response) => {
  1057. this.zcFinanceInf = response.data.zcFinanceInf;
  1058. this.needPay = response.data.needPay;
  1059. //意愿类型
  1060. this.zfpAuthType = response.data.zfpAuthType;
  1061. this.selectPayment();
  1062. });
  1063. }
  1064. });
  1065. },
  1066. //取消选择意愿
  1067. cancelUpdate() {
  1068. this.confirmIsShow = false;
  1069. this.resetUpdate();
  1070. },
  1071. //关闭盖章短信
  1072. cancelMessage() {
  1073. this.messageIsShow = false;
  1074. this.resetMessage();
  1075. },
  1076. //关闭授权编号激活短信
  1077. cancelMessages() {
  1078. this.messageIfShow = false;
  1079. this.resetMessages();
  1080. },
  1081. //关闭二维码
  1082. cancelFace() {
  1083. this.faceIsShow = false;
  1084. },
  1085. closePdfShow() {
  1086. this.pdfShowDialog = false;
  1087. },
  1088. resetUpdate() {
  1089. this.updateForm = {
  1090. radio: "",
  1091. };
  1092. //意愿类型还原为全部
  1093. this.zfpAuthType = "00";
  1094. this.resetForm("updateForm");
  1095. },
  1096. resetMessage() {
  1097. this.messageForm = {
  1098. validCode: "",
  1099. };
  1100. this.resetForm("messageForm");
  1101. },
  1102. resetMessages() {
  1103. this.messagesForm = {
  1104. validCode: "",
  1105. };
  1106. this.resetForm("messagesForm");
  1107. },
  1108. //获取合同文件
  1109. getContractFile() {
  1110. const loading = this.$loading({
  1111. lock: true,
  1112. text: "Loading",
  1113. background: "rgba(0, 0, 0,0)",
  1114. });
  1115. getContractFile(this.zcFinanceInf)
  1116. .then((response) => {
  1117. loading.close();
  1118. if (response.data.list) {
  1119. this.pdfFileList = response.data.list;
  1120. }
  1121. //文件存在
  1122. if (this.pdfFileList.length > 0) {
  1123. this.pdfIsShow = true
  1124. this.pdfShowDialog = true;
  1125. } else {
  1126. this.$message({
  1127. message: "文件不存在!",
  1128. type: "warning",
  1129. });
  1130. }
  1131. })
  1132. .catch((response) => {
  1133. loading.close();
  1134. });
  1135. },
  1136. //缴费查询
  1137. selectPayment() {
  1138. listCompanyHandler().then((response) => {
  1139. var self = this;
  1140. //self.paiAccno = '3115730025233104147';
  1141. if (response.data == true) {
  1142. cfcaProjectNo().then((response) => {
  1143. if (response.data.scyCfcaAuthNumber == null) {
  1144. this.messageIfShow = true;
  1145. } else {
  1146. var zfrId = self.zfrId;
  1147. listChargeStatus(zfrId).then((response) => {
  1148. if (response.data.accInfList[0]) {
  1149. self.paiAccno = response.data.accInfList[0].paiAccno;
  1150. }
  1151. if (response.data.chargeInfList[0]) {
  1152. if (response.data.chargeInfList[0].zciStatus == "00") {
  1153. self.zciId = response.data.chargeInfList[0].zciId;
  1154. self
  1155. .$confirm("请缴纳手续费" + self.needPay + "元", "警告", {
  1156. confirmButtonText: "去缴费",
  1157. cancelButtonText: "取消",
  1158. type: "warning",
  1159. })
  1160. .then(function () {
  1161. const loading = self.$loading({
  1162. lock: true,
  1163. text: "Loading",
  1164. spinner: "el-icon-loading",
  1165. background: "rgba(0, 0, 0, 0.7)",
  1166. });
  1167. if (self.paiAccno) {
  1168. balance(self.paiAccno)
  1169. .then((response) => {
  1170. if (
  1171. eval(self.needPay) > eval(response.data.kyAmt)
  1172. ) {
  1173. self.$message({
  1174. message:
  1175. "余额为" +
  1176. response.data.kyAmt +
  1177. "不足以抵扣本次缴费费用,请及时充值",
  1178. type: "warning",
  1179. });
  1180. loading.close();
  1181. } else {
  1182. console.log();
  1183. var map = {
  1184. recvAccNo: "",
  1185. recvAccNm: "",
  1186. tranAmt: self.needPay,
  1187. businessId: self.zciId,
  1188. type: "00",
  1189. };
  1190. transfer(map)
  1191. .then((response) => {
  1192. debugger;
  1193. loading.close();
  1194. setTimeout(() => {
  1195. if (response.data.status == "1") {
  1196. self.msgSuccess("缴费成功");
  1197. updateChargeStatus(zfrId, "02").then(
  1198. (res) => {
  1199. self.getContractFile();
  1200. }
  1201. );
  1202. } else if (response.data.status == "0") {
  1203. self.message("正在缴费中,请稍后再试");
  1204. updateChargeStatus(zfrId, "01").then(
  1205. (res) => {}
  1206. );
  1207. } else if (response.data.status == "2") {
  1208. self.msgError(
  1209. "缴费失败,前去费用管理再次缴费"
  1210. );
  1211. updateChargeStatus(zfrId, "05").then(
  1212. (res) => {}
  1213. );
  1214. }
  1215. }, 1000);
  1216. })
  1217. .catch(() => {
  1218. loading.close();
  1219. });
  1220. }
  1221. })
  1222. .catch(() => {
  1223. loading.close();
  1224. });
  1225. } else {
  1226. self.$message({
  1227. message: "您还没有电子账户,请联系平台开通电子账户",
  1228. type: "warning",
  1229. });
  1230. loading.close();
  1231. }
  1232. });
  1233. } else {
  1234. self.getContractFile();
  1235. }
  1236. } else {
  1237. self.getContractFile();
  1238. }
  1239. });
  1240. }
  1241. });
  1242. } else {
  1243. this.$message({
  1244. message: "此操作需经办人权限,请确认您是否是经办人",
  1245. type: 'warning'
  1246. });
  1247. }
  1248. });
  1249. },
  1250. //缴费
  1251. selectType() {
  1252. //选择签署意愿
  1253. if (this.zfpAuthType == "00") {
  1254. this.confirmIsShow = true;
  1255. } else {
  1256. this.checking();
  1257. }
  1258. },
  1259. //确认选择
  1260. confirmSelect() {
  1261. if (!this.updateForm.radio) {
  1262. this.$message({
  1263. message: "请选择签署意愿类型",
  1264. type: "warning",
  1265. });
  1266. return;
  1267. }
  1268. this.confirmIsShow = false;
  1269. this.zfpAuthType = this.updateForm.radio;
  1270. //调用人脸识别或者短信验证
  1271. this.checking();
  1272. },
  1273. //去签署
  1274. checking() {
  1275. //人脸
  1276. if (this.zfpAuthType == "01") {
  1277. //调用人脸识别生成二维码
  1278. faceAuth().then((response) => {
  1279. console.log(response);
  1280. if (response.data) {
  1281. //获取二维码
  1282. this.fileUrl = response.data.fileUrl;
  1283. //获取源流水号
  1284. var originalTxSN = response.data.originalTxSN;
  1285. this.faceIsShow = true;
  1286. //每5秒查证人脸识别结果
  1287. var timeInterval = window.setInterval(() => {
  1288. setTimeout(() => {
  1289. //源流水不为空并且结果为空
  1290. if (originalTxSN && !this.faceResult) {
  1291. this.authForm.originalTxSN = originalTxSN;
  1292. //调用查证方法
  1293. checkFaceAuth(this.authForm).then((res) => {
  1294. //认证结果
  1295. this.faceResult = res.data.Verification;
  1296. console.log("result:"+res.data.Verification);
  1297. //成功
  1298. if (this.faceResult == "20") {
  1299. this.msgSuccess("验证成功");
  1300. //关闭验证码
  1301. this.faceIsShow = false;
  1302. //关闭定时
  1303. window.clearInterval(timeInterval);
  1304. //调用盖章
  1305. this.contractSigning();
  1306. } else if (this.faceResult == "30") {
  1307. this.$message({
  1308. message: "验证失败",
  1309. type: "warning",
  1310. });
  1311. //关闭验证码
  1312. this.faceIsShow = false;
  1313. window.clearInterval(timeInterval);
  1314. }
  1315. });
  1316. }
  1317. }, 0);
  1318. }, 10000);
  1319. }
  1320. });
  1321. } else if (this.zfpAuthType == "02") {
  1322. //短信
  1323. this.messageIsShow = true;
  1324. }
  1325. },
  1326. //发送短信验证码
  1327. send() {
  1328. //发送
  1329. sendMessage().then((response) => {
  1330. if (response.data) {
  1331. //手机号
  1332. var newIphone = response.data.newIphone;
  1333. //结果
  1334. var result = response.data.result;
  1335. //倒计时
  1336. const TIME_COUNT = 60;
  1337. if (!this.timer) {
  1338. this.count = TIME_COUNT;
  1339. this.showCode = false;
  1340. this.timer = setInterval(() => {
  1341. if (this.count > 0 && this.count <= TIME_COUNT) {
  1342. this.count--;
  1343. } else {
  1344. this.showCode = true;
  1345. clearInterval(this.timer);
  1346. this.timer = null;
  1347. }
  1348. }, 1000);
  1349. }
  1350. //成功
  1351. if ("20" == result) {
  1352. this.$message({
  1353. message:
  1354. "已向经办人手机号为" + newIphone + "发送短信验证码,请注意查收",
  1355. type: "warning",
  1356. });
  1357. } else if ("10" == result) {
  1358. //失败
  1359. this.$message({
  1360. message: "短信发送失败",
  1361. type: "warning",
  1362. });
  1363. }
  1364. }
  1365. });
  1366. },
  1367. //校验验证码是否正确
  1368. checkCode() {
  1369. if (!this.messageForm.validCode) {
  1370. this.$message({
  1371. message: "请输入验证码",
  1372. type: "warning",
  1373. });
  1374. return;
  1375. }
  1376. //校验验证码
  1377. checkCode(this.messageForm).then((response) => {
  1378. if (response.data) {
  1379. //结果
  1380. var verification = response.data.verification;
  1381. //匹配
  1382. if ("20" == verification) {
  1383. //进行下一步-- 盖章
  1384. this.contractSigning();
  1385. } else if ("30" == verification) {
  1386. //不匹配
  1387. this.$message({
  1388. message: "验证有误,请重新输入",
  1389. type: "warning",
  1390. });
  1391. }
  1392. }
  1393. });
  1394. },
  1395. //生成项目授权编号发送短信
  1396. proSend() {
  1397. //发送
  1398. projectSendMessage().then((response) => {
  1399. if (response.data) {
  1400. //手机号
  1401. var newIphone = response.data.newIphone;
  1402. //结果
  1403. var result = response.data.result;
  1404. //项目编号
  1405. this.projectCode = response.data.projectCode;
  1406. //倒计时
  1407. const TIME_COUNT = 60;
  1408. if (!this.timerCode) {
  1409. this.countCode = TIME_COUNT;
  1410. this.showCodes = false;
  1411. this.timerCode = setInterval(() => {
  1412. if (this.countCode > 0 && this.countCode <= TIME_COUNT) {
  1413. this.countCode--;
  1414. } else {
  1415. this.showCodes = true;
  1416. clearInterval(this.timerCode);
  1417. this.timerCode = null;
  1418. }
  1419. }, 1000);
  1420. }
  1421. //成功
  1422. if ("60000000" == result) {
  1423. this.$message({
  1424. message:
  1425. "已向经办人手机号为" + newIphone + "发送短信验证码,请注意查收",
  1426. type: "warning",
  1427. });
  1428. } else {
  1429. //失败
  1430. this.$message({
  1431. message: "短信发送失败",
  1432. type: "warning",
  1433. });
  1434. }
  1435. }
  1436. });
  1437. },
  1438. //校验授权编号验证码
  1439. checkProCode() {
  1440. if (!this.projectForm.code) {
  1441. this.$message({
  1442. message: "请输入验证码",
  1443. type: "warning",
  1444. });
  1445. return;
  1446. }
  1447. //项目编号
  1448. this.projectForm.projectCode = this.projectCode;
  1449. //校验验证码
  1450. checkProCode(this.projectForm).then((response) => {
  1451. if (response.data) {
  1452. //结果
  1453. var verification = response.data.verification;
  1454. //匹配
  1455. if ("60000000" == verification) {
  1456. var zfrId = this.zfrId;
  1457. listChargeStatus(zfrId).then((response) => {
  1458. if (response.data[0]) {
  1459. if (response.data[0].zciStatus == "00") {
  1460. this.$confirm("请缴纳手续费" + this.needPay + "元", "警告", {
  1461. confirmButtonText: "去缴费",
  1462. cancelButtonText: "取消",
  1463. type: "warning",
  1464. })
  1465. .then(function () {
  1466. return updateChargeStatus(zfrId);
  1467. })
  1468. .then(() => {
  1469. this.getContractFile();
  1470. });
  1471. } else {
  1472. this.getContractFile();
  1473. }
  1474. } else {
  1475. this.getContractFile();
  1476. }
  1477. });
  1478. } else {
  1479. //不匹配
  1480. this.$message({
  1481. message: "验证有误,请重新输入",
  1482. type: "warning",
  1483. });
  1484. }
  1485. }
  1486. });
  1487. },
  1488. //盖章
  1489. contractSigning() {
  1490. var self = this;
  1491. const loading = this.$loading({
  1492. lock: true,
  1493. text: "Loading",
  1494. background: "rgba(0, 0, 0,0)",
  1495. });
  1496. self.zcFinanceInf.zfrId = self.zfrId;
  1497. contractSigning(self.zcFinanceInf)
  1498. .then((response) => {
  1499. loading.close();
  1500. self.msgSuccess("盖章成功");
  1501. if (self.zfpAuthType == "02") {
  1502. //关闭短信验证
  1503. self.messageIsShow = false;
  1504. } else if (self.zfpAuthType == "01") {
  1505. //关闭人脸二维码
  1506. self.faceIsShow = false;
  1507. }
  1508. // self.cancel();
  1509. //关闭预览合同
  1510. //self.closePdfShow();
  1511. let queryStamped = {};
  1512. queryStamped.zfrId = self.zfrId
  1513. const load = self.$loading({
  1514. lock: true,
  1515. text: "Loading",
  1516. background: "rgba(0, 0, 0,0)",
  1517. });
  1518. listStamped(queryStamped).then((response) =>{
  1519. if(response.data){
  1520. self.pdfFileList = response.data.list;
  1521. }
  1522. self.pdfShowDialog = true;
  1523. self.pdfIsShow = false;
  1524. load.close()
  1525. }).catch((response) => {
  1526. load.close();
  1527. });
  1528. })
  1529. .catch((response) => {
  1530. loading.close();
  1531. });
  1532. },
  1533. closePDF(){
  1534. this.cancel();
  1535. //关闭预览合同
  1536. this.closePdfShow();
  1537. }
  1538. },
  1539. };
  1540. </script>
  1541. <style lang="scss" scoped>
  1542. .zap-title {
  1543. padding: 20px 25px;
  1544. font-size: 16px;
  1545. color: #333333;
  1546. background-color: #ffffff;
  1547. }
  1548. .zap-form {
  1549. padding: 0px 25px 8px;
  1550. background-color: #ffffff;
  1551. }
  1552. .zap-form--clear {
  1553. padding-left: 0;
  1554. padding-right: 0;
  1555. }
  1556. </style>
  1557. <style type="text/css">
  1558. table.gridtable {
  1559. font-size: 11px;
  1560. color: #333333;
  1561. border-width: 1px;
  1562. border-collapse: collapse;
  1563. }
  1564. table.gridtable th {
  1565. border-width: 1px;
  1566. padding: 8px;
  1567. border-style: solid;
  1568. background-color: #dedede;
  1569. }
  1570. table.gridtable td {
  1571. border-width: 1px;
  1572. padding: 8px;
  1573. border-style: solid;
  1574. }
  1575. </style>