recordSeal.vue 50 KB

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