12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649 |
- <template>
- <div class="app-container zap-main">
- <el-row>
- <el-form
- ref="form"
- :model="form"
- :inline="true"
- :rules="rules"
- label-width="95px"
- >
- <div class="zap-title">申请融资信息</div>
- <el-row class="zap-form" style="padding-bottom: 0">
- <el-col :span="12">
- <el-form-item label="选择融信:" prop="zfrFinanceId" size="large">
- <el-select
- v-model="form.zfrFinanceId"
- clearable
- @clear="clearBoth"
- disabled
- >
- <el-option
- v-for="(item, index) in financeInfList"
- :key="index"
- :label="item.zfiNumber"
- :value="item.zfiId"
- @click.native="amount(item)"
- ></el-option>
- </el-select>
- </el-form-item>
- </el-col>
- <el-col :span="12">
- <el-form-item
- label="融资收款账户:"
- prop="zfrCollectionAccount"
- size="large"
- label-width="101px"
- >
- <el-input
- v-model="form.zfrCollectionAccount"
- clearable
- placeholder="请输入融资账户"
- maxlength="25"
- readonly
- />
- </el-form-item>
- </el-col>
- </el-row>
- <el-row class="zap-form" style="padding-bottom: 0">
- <el-col :span="12">
- <el-form-item label="融信金额:" prop="zfiAmount" size="large">
- <el-input
- v-model="form.zfiAmount"
- clearable
- placeholder="请输入融信金额"
- maxlength="25"
- readonly
- >
- <template slot="append">元</template>
- </el-input>
- </el-form-item>
- </el-col>
- <el-col :span="12">
- <el-form-item label="申请融资方:" prop="companyName" size="large">
- <el-input
- v-model="form.companyName"
- clearable
- placeholder="请输入申请融资方"
- maxlength="25"
- readonly
- />
- </el-form-item>
- </el-col>
- </el-row>
- <el-row class="zap-form" style="padding-bottom: 0">
- <el-col :span="12">
- <el-form-item label="融资金额:" prop="zfrAmount" size="large">
- <el-input
- v-model="form.zfrAmount"
- clearable
- placeholder="请输入融资金额"
- maxlength="25"
- readonly
- >
- <template slot="append">元</template>
- </el-input>
- </el-form-item>
- </el-col>
- <el-col :span="12">
- <el-form-item label="融资利率:" prop="zfrRate" size="large">
- <el-input
- v-model="form.zfrRate"
- clearable
- placeholder="请输入融资利率"
- maxlength="25"
- readonly
- >
- <template slot="append">%</template>
- </el-input>
- </el-form-item>
- </el-col>
- </el-row>
- <el-row class="zap-form" style="padding-bottom: 0">
- <el-col :span="12">
- <el-form-item
- label="承诺还款日期:"
- prop="zfrRepaymentDate"
- size="large"
- label-width="101px"
- >
- <el-input
- v-model="form.zfrRepaymentDate"
- clearable
- placeholder="请输入承诺还款日期"
- maxlength="25"
- readonly
- />
- </el-form-item>
- </el-col>
- <el-col :span="12">
- <el-form-item label="服务费率:" prop="zfpcrChargeRate" size="large">
- <el-input
- v-model="form.zfpcrChargeRate"
- clearable
- placeholder="请输入服务费率"
- maxlength="25"
- readonly
- >
- <template slot="append">%</template>
- </el-input>
- </el-form-item>
- </el-col>
- </el-row>
- <el-row class="zap-form" style="padding-bottom: 0">
- <el-col :span="12">
- <el-form-item
- label="预计融资成本:"
- prop="cost"
- size="large"
- label-width="101px"
- >
- <el-input
- v-model="form.cost"
- clearable
- placeholder="请输入预计融资成本"
- maxlength="25"
- readonly
- >
- <template slot="append">元</template>
- </el-input>
- </el-form-item>
- </el-col>
- <el-col :span="12">
- <el-form-item
- label="预计融资期限:"
- prop="term"
- size="large"
- label-width="101px"
- >
- <el-input
- v-model="form.term"
- clearable
- placeholder="请输入预计融资期限"
- maxlength="25"
- readonly
- >
- <template slot="append">天</template>
- </el-input>
- </el-form-item>
- </el-col>
- </el-row>
- <el-row class="zap-form" style="padding-bottom: 0">
- <el-col :span="12">
- <el-form-item
- label="预计净融资额:"
- prop="amount"
- size="large"
- label-width="101px"
- >
- <el-input
- v-model="form.amount"
- clearable
- placeholder="请输入预计净融资额"
- maxlength="25"
- readonly
- >
- <template slot="append">元</template>
- </el-input>
- </el-form-item>
- </el-col>
- </el-row>
- <div class="contain">
- <p>说明:</p>
- <p>1. 因银行结算原因,资金到账可能会在申请日期后2-5工作日;</p>
- <p>
- 2.
- 申请融资时,预计融资成本、预计融资期限、预计净融资额,由申请日期单日开始计算;准确数值以银行实际放款日期为准;
- </p>
- <p>
- 3.
- 因填写融资收款账户错误,或其他原因导致银行无法正常放款,款项将汇入备用收款账户,可在电子账户管理查看;
- </p>
- <p>4. 服务费缴纳与退还要求,可详细阅读《融信产品使用协议》</p>
- </div>
- <div class="zap-title">融信信息</div>
- <el-row class="zap-form">
- <el-col>
- <span style="font-size: 14px; color: #333333">融信凭证</span>
- </el-col>
- <table
- class="gridtable"
- style="width: 80%; text-align: center"
- align="center"
- >
- <tr>
- <td rowspan="4">开立方</td>
- <td>全称</td>
- <td>{{ openName }}</td>
- <td rowspan="4">接收方</td>
- <td>全称</td>
- <td>{{ receiveName }}</td>
- </tr>
- <tr>
- <td>社会统一码</td>
- <td>{{ openCode }}</td>
- <td>社会统一码</td>
- <td>{{ receiverCode }}</td>
- </tr>
- <tr>
- <td>开户银行</td>
- <td>{{ openBank }}</td>
- <td>开户银行</td>
- <td>{{ receiverBank }}</td>
- </tr>
- <tr>
- <td>账号</td>
- <td>{{ openAccount }}</td>
- <td>账号</td>
- <td>{{ receiverAccount }}</td>
- </tr>
- <tr>
- <td colspan="2">粮信金额</td>
- <td colspan="4">
- 人民币(大写):{{ issuedAmount }}<br />人民币(小写)¥{{
- form.zfiAmount
- }}
- </td>
- </tr>
- <tr>
- <td colspan="2">起止日期</td>
- <td colspan="4">{{ stopDate }}</td>
- </tr>
- </table>
- </el-row>
- <el-row class="zap-form">
- <el-row type="flex" align="middle" justify="end">
- <el-col>
- <span style="font-size: 14px; color: #333333">资产信息</span>
- </el-col>
- <el-col class="zap-margin-top;">
- <el-row type="flex" align="middle" justify="end">
- <el-form-item label="金额大写:" class="zap-margin-clear">
- <span>{{ smallToBig(allAmount()) }}</span>
- </el-form-item>
- <el-form-item label="合计金额:" class="zap-margin-clear">
- <span>{{ allAmount() }}</span>
- </el-form-item>
- </el-row>
- </el-col>
- </el-row>
- <el-row class="zap-margin-top">
- <el-table :data="billInfList">
- <el-table-column
- label="序号"
- type="index"
- width="50"
- align="center"
- >
- <template slot-scope="scope">
- <span>{{
- (queryParams.pageNum - 1) * queryParams.pageSize +
- scope.$index +
- 1
- }}</span>
- </template>
- </el-table-column>
- <el-table-column label="编号" align="center" prop="zbiNumber" />
- <el-table-column label="账款名称" align="center" prop="zbiName" />
- <el-table-column label="应收企业" align="center" prop="payee" />
- <el-table-column label="应付企业" align="center" prop="payer" />
- <el-table-column
- label="还款时间"
- align="center"
- prop="zbiPayDate"
- />
- <el-table-column label="金额" align="center" prop="zbiAmount" />
- <el-table-column
- label="操作"
- align="center"
- class-name="small-padding fixed-width"
- width="250"
- >
- <template slot-scope="scope">
- <el-button
- size="mini"
- type="text"
- icon="el-icon-view"
- @click="handleDetail(scope.$index, billInfList)"
- >详情</el-button
- >
- </template>
- </el-table-column>
- </el-table>
- </el-row>
- </el-row>
- </el-form>
- <!-- 签署合同 -->
- <el-row class="zap-margin-top zap-form">
- <div class="zap-title">签署合同</div>
- <el-table :data="creditSealList" style="width: 100%">
- <el-table-column
- label="文件名称"
- align="center"
- prop="pfiFileName"
- show-overflow-tooltip
- >
- <template slot-scope="scope">
- <img
- style="width: 30px; height: 30px"
- src="../../../assets/images/pdf.png"
- />
- <span>{{ scope.row.pfiFileName }} </span>
- </template>
- </el-table-column>
- <el-table-column
- label="操作"
- align="center"
- class-name="small-padding fixed-width"
- width="300"
- fixed="right"
- >
- <template slot-scope="scope">
- <el-button
- size="mini"
- type="text"
- icon="el-icon-view"
- @click="handleDownload(scope.row)"
- >下载</el-button
- >
- <el-button
- size="mini"
- type="text"
- icon="el-icon-view"
- @click="handlePreview(scope.row)"
- >预览</el-button
- >
- </template>
- </el-table-column>
- </el-table>
- </el-row>
- <!-- 发票附件 -->
- <!-- <el-row class="zap-margin-top zap-form">
- <div class="zap-title">发票附件</div>
- <el-table :data="invoiceFileList" stripe="" style="width: 100%">
- <el-table-column label="文件名称" align="center" prop="pfiFileName" show-overflow-tooltip />
- <el-table-column label="操作" align="center" class-name="small-padding fixed-width" width='300' fixed="right">
- <template slot-scope="scope">
- <el-button size="mini" type="text" icon="el-icon-view" @click="handlePreview(scope.row)">预览</el-button>
- </template>
- </el-table-column>
- </el-table>
- </el-row> -->
- <!-- 合同附件 -->
- <!-- <el-row class="zap-margin-top zap-form">
- <div class="zap-title">合同附件</div>
- <el-table :data="contractFileList" stripe="" style="width: 100%">
- <el-table-column label="文件名称" align="center" prop="pfiFileName" show-overflow-tooltip />
- <el-table-column label="操作" align="center" class-name="small-padding fixed-width" width='300' fixed="right">
- <template slot-scope="scope">
- <el-button size="mini" type="text" icon="el-icon-view" @click="handlePreview(scope.row)">预览</el-button>
- </template>
- </el-table-column>
- </el-table>
- </el-row> -->
- <!-- 其他附件 -->
- <!-- <el-row class="zap-margin-top zap-form">
- <div class="zap-title">其他附件</div>
- <el-table :data="otherFileList" stripe="" style="width: 100%">
- <el-table-column label="文件名称" align="center" prop="pfiFileName" show-overflow-tooltip />
- <el-table-column label="操作" align="center" class-name="small-padding fixed-width" width='300' fixed="right">
- <template slot-scope="scope">
- <el-button size="mini" type="text" icon="el-icon-view" @click="handlePreview(scope.row)">预览</el-button>
- </template>
- </el-table-column>
- </el-table>
- </el-row> -->
- <el-row type="flex" align="middle" justify="center" style="height: 77px">
- <!-- <el-button type="success" @click="cancelFtp">作废</el-button> -->
- <el-button type="primary" @click="selectPayment">合同签署</el-button>
- <el-button type="primary" plain="" @click="cancel">取消</el-button>
- <!-- <el-button @click="cancel">取 消</el-button> -->
- </el-row>
- </el-row>
- <!-- 附件详情 -->
- <el-dialog
- title="详情"
- :visible.sync="openDetailBill"
- width="1120px"
- append-to-body
- >
- <detail-bill :zbiId="this.zbiId" v-if="openDetailBill"></detail-bill>
- </el-dialog>
- <!--预览-->
- <el-dialog :visible.sync="openFile" width="1000px" append-to-body>
- <img :src="wordUrl" v-if="show" width="700px" height="500px" />
- <iframe
- :src="wordUrl"
- width="800px"
- height="600px"
- frameborder="1"
- v-if="heid"
- />
- </el-dialog>
- <!-- 合同预览 -->
- <el-dialog title="合同预览" :visible.sync="pdfShowDialog" width="60%" append-to-body :show-close="pdfIsShow">
- <pdf-show
- :pdfFileList="pdfFileList"
- :zfiId="this.form.zfiId"
- :parent="parent"
- ></pdf-show>
- <span slot="footer" class="dialog-footer">
- <el-button type="primary" @click="selectType" v-if="pdfIsShow">签署</el-button>
- <el-button type="primary" plain="" @click="pdfShowDialog = false" v-if="pdfIsShow"
- >取消</el-button>
- <el-button type="primary" @click="closePDF" v-if="!pdfIsShow">确定</el-button>
- </span>
- </el-dialog>
- <!--选择签署意愿类型-->
- <el-dialog
- title="签署意愿"
- :visible.sync="confirmIsShow"
- width="600px"
- append-to-body
- :before-close="cancelUpdate"
- center
- >
- <el-form
- ref="updateForm"
- :disabled="false"
- :model="updateForm"
- v-if="confirmIsShow"
- label-width="150px"
- class="demo-form-inline"
- :inline="true"
- >
- <el-radio-group v-model="updateForm.radio">
- <el-radio label="01">人脸</el-radio>
- <el-radio label="02">短信</el-radio>
- </el-radio-group>
- </el-form>
- <div slot="footer" class="dialog-footer">
- <el-button type="primary" @click="confirmSelect">确 定</el-button>
- <el-button @click="cancelUpdate">取 消</el-button>
- </div>
- </el-dialog>
- <!--盖章短信-->
- <el-dialog
- title="短信验证"
- :visible.sync="messageIsShow"
- width="600px"
- append-to-body
- :before-close="cancelMessage"
- center
- >
- <el-form
- ref="messageForm"
- :disabled="false"
- :model="messageForm"
- v-if="messageIsShow"
- label-width="150px"
- class="demo-form-inline"
- :inline="true"
- @submit.native.prevent
- >
- <el-form-item label="验证码" prop="validCode">
- <el-input
- v-model="messageForm.validCode"
- style="width: 200px"
- maxlength="6"
- />
- </el-form-item>
- <el-form-item>
- <el-button :disabled="!showCode" type="success" @click="send">
- 点击获取验证码
- <span v-show="!showCode" class="count">{{ count }} s</span>
- </el-button>
- </el-form-item>
- </el-form>
- <div slot="footer" class="dialog-footer">
- <el-button type="primary" @click="checkCode">确定</el-button>
- <el-button @click="cancelMessage">取 消</el-button>
- </div>
- </el-dialog>
- <!--授权编号激活短信-->
- <el-dialog
- :visible.sync="messageIfShow"
- width="600px"
- append-to-body
- :before-close="cancelMessages"
- center
- >
- <el-divider content-position="left">cfca签章授权编号激活</el-divider>
- <el-form
- ref="messageForm"
- :disabled="false"
- :model="messagesForm"
- v-if="messageIfShow"
- label-width="150px"
- class="demo-form-inline"
- :inline="true"
- @submit.native.prevent
- >
- <el-form-item label="验证码" prop="validCode">
- <el-input
- v-model="messagesForm.validCode"
- style="width: 200px"
- maxlength="6"
- />
- </el-form-item>
- <el-form-item>
- <el-button :disabled="!showCodes" type="success" @click="proSend">
- 点击获取验证码
- <span v-show="!showCodes" class="count">{{ countCode }} s</span>
- </el-button>
- </el-form-item>
- </el-form>
- <div slot="footer" class="dialog-footer">
- <el-button type="primary" @click="checkProCode">确定</el-button>
- <el-button @click="cancelMessages">取 消</el-button>
- </div>
- </el-dialog>
- <!--人脸二维码-->
- <el-dialog
- title="人脸验证"
- :visible.sync="faceIsShow"
- width="500px"
- append-to-body
- :before-close="cancelFace"
- center
- >
- <img
- :src="'data:image/jpeg;base64,' + this.fileUrl"
- style="overflow: auto; width: 100%; height: 100%"
- />
- </el-dialog>
- </div>
- </template>
- <script>
- import {
- addRecord,
- listBillInf,
- listAccInf,
- getContractFile,
- getRecord,
- contractSigning,
- updateChargeStatus,
- listChargeStatus,
- cancelContract,
- listStamped
- } from "@/api/service/financeRecord/record";
- import { listFinanceInf } from "@/api/common/financeInf";
- import { getFile } from "@/api/service/credit/credit";
- import { getToken } from "@/utils/auth";
- import { getUserProfile } from "@/api/system/user";
- import { getCreditDetail } from "@/api/service/credit/credit";
- import { getCreditSealFile } from "@/api/service/credit/creditHandle";
- import DetailBill from "@/views/service/credit/billDetail";
- import { isOpenApproval } from "@/api/service/credit/approvalRelatedCredit";
- import { listCompanyHandler } from "@/api/common/companyHandler";
- import {
- sendMessage,
- checkCode,
- faceAuth,
- checkFaceAuth,
- } from "@/api/service/credit/message";
- import {
- cfcaProjectNo,
- projectSendMessage,
- checkProCode,
- } from "@/api/service/credit/cfcaProject";
- import { balance, transfer } from "@/api/bank/bankInterface";
- import pdfShow from "@/views/service/financeRecord/pdfShow";
- export default {
- name: "financeRecord",
- components: { DetailBill, pdfShow },
- data() {
- return {
- pdfIsShow: true,
- //往来账款id
- zbiId: "",
- //融资账户是够编辑
- onlyRead: false,
- // 遮罩层
- loading: true,
- // 选中数组
- ids: [],
- // 非单个禁用
- single: true,
- // 非多个禁用
- multiple: true,
- // 显示搜索条件
- showSearch: true,
- // 总条数
- total: 0,
- // 全部融资记录表格数据
- recordList: [],
- //融信编号数据
- financeInfList: [],
- //应收账款
- billInfList: [],
- //合同附件
- contractFileList: [],
- //发票附件
- invoiceFileList: [],
- //其他文件
- otherFileList: [],
- //盖章文件
- creditSealList: [],
- //开立方
- openName: "",
- //开立社会码
- openCode: "",
- //开立银行
- openBank: "",
- //开立账户
- openAccount: "",
- //接收方
- receiveName: "",
- //接收方社会统一码
- receiverCode: "",
- //接收方银行
- receiverBank: "",
- //接收方账户
- receiverAccount: "",
- //起止日期
- stopDate: "",
- //签发金额大写
- issuedAmount: "零元整",
- // 弹出层标题
- title: "",
- // 是否显示弹出层
- open: false,
- openDetailBill: false,
- // 查询参数
- queryParams: {
- pageNum: 1,
- pageSize: 10,
- zfrFinanceId: null,
- zfrNumber: null,
- zfrAmount: null,
- zfrRate: null,
- zfrHandler: null,
- zfrRepaymentDate: null,
- zfrApplyDate: null,
- zfrLoanDate: null,
- zfrApplyAmount: null,
- zfrApplyType: null,
- zfrStatus: null,
- zfrApproveStt: null,
- zfpcrLoanType: null,
- zfiProductId: null,
- },
- queryParamsDown: {
- pfiFileUrl: null,
- },
- // 表单参数
- form: {},
- forms: {},
- // 表单校验
- rules: {
- zfrFinanceId: [
- {
- required: true,
- message: "融信编号不能为空",
- trigger: "blur",
- },
- ],
- zfrAmount: [
- {
- required: true,
- message: "融资金额不能为空",
- trigger: "blur",
- },
- ],
- },
- openFile: false,
- wordUrl: "",
- heid: false,
- show: false,
- //盖章预览
- parent: this,
- pdfShowDialog: false,
- pdfFileList: [],
- confirmIsShow: false,
- messageIsShow: false,
- messageIfShow: false,
- faceIsShow: false,
- fileUrl: "",
- //意愿
- updateForm: {},
- messageForm: {},
- messagesForm: {},
- count: "",
- timer: null,
- //授权编号激活短信验证码倒计时
- //项目编号
- projectCode: "",
- showCode: true,
- showCodes: true,
- countCode: "",
- timerCode: null,
- zfrId: null,
- };
- },
- created() {
- this.zfrId = this.$route.params && this.$route.params.zfrId;
- getRecord(this.zfrId).then((response) => {
- this.zcFinanceInf = response.data.zcFinanceInf;
- this.needPay = response.data.needPay;
- //意愿类型
- this.zfpAuthType = response.data.zfpAuthType;
- const zfiId = response.data.zcFinanceInf.zfiId;
- this.$set(this.form, "zfrFinanceId", zfiId);
- this.$set(this.form,"zfrCollectionAccount",response.data.zfrCollectionAccount);
- this.getFinanceInf(zfiId);
- });
- this.getUserProfile();
- },
- methods: {
- /** 查询融信编号 */
- getFinanceInf(zfrFinanceId) {
- this.loading = true;
- listFinanceInf(zfrFinanceId).then((response) => {
- if (response.data) {
- this.financeInfList = response.data;
- for (let item of this.financeInfList) {
- if (item.zfiId == zfrFinanceId) {
- this.amount(item);
- }
- }
- this.loading = false;
- }
- });
- },
- getUserProfile() {
- getUserProfile().then((response) => {
- if (response.company) {
- this.$set(this.form, "companyName", response.company.scyName);
- }
- });
- },
- //获取盖章文件
- getCreditSealFile() {
- getCreditSealFile(this.forms).then((response) => {
- if (response.data.list) {
- this.creditSealList = response.data.list;
- }
- });
- },
- // 取消按钮
- cancel() {
- this.$store.dispatch("tagsView/delView", this.$route);
- this.$router.go(-1);
- },
- // 表单重置
- reset() {
- this.form = {
- zfrId: null,
- zfrFinanceId: null,
- zfrNumber: null,
- zfrAmount: null,
- zfrRate: null,
- zfrHandler: null,
- zfrRepaymentDate: null,
- zfrApplyDate: null,
- zfrLoanDate: null,
- zfrApplyAmount: null,
- zfrApplyType: null,
- zfrStatus: "00",
- zfrApproveStt: null,
- zfrProfitSpare1: null,
- zfrProfitSpare2: null,
- zfrProfitSpare3: null,
- zfrProfitSpare4: null,
- zfrProfitSpare5: null,
- zfrProfitSpare6: null,
- zfrProfitSpare7: null,
- zfrProfitSpare8: null,
- zfrProfitSpare9: null,
- createBy: null,
- createTime: null,
- updateBy: null,
- updateTime: null,
- };
- this.resetForm("form");
- },
- /** 全部搜索按钮操作 */
- handleQuery() {
- this.queryParams.pageNum = 1;
- this.getList();
- },
- /** 全部重置按钮操作 */
- resetQuery() {
- this.resetForm("queryForm");
- this.handleQuery();
- },
- //全部 多选框选中数据
- handleSelectionChange(selection) {
- this.ids = selection.map((item) => item.zfrId);
- this.single = selection.length !== 1;
- this.multiple = !selection.length;
- },
- /* 融信编号赋值融资金额 */
- amount(item) {
- this.$set(this.form, "zfrAmount", item.zfiAmount);
- this.$set(this.form, "zfiAmount", item.zfiAmount);
- this.$set(this.form, "zfrRepaymentDate", item.zfiExpireDate);
- this.$set(this.form, "zfrRate", item.zfpcrRate);
- this.$set(this.form, "zfpcrLoanType", item.zfpcrLoanType);
- this.$set(this.form, "zfiProductId", item.zfiProductId);
- this.$set(this.form, "zfpcrChargeRate", item.zfpcrChargeRate);
- this.$set(this.form, "cost", item.cost);
- this.$set(this.form, "term", item.term);
- this.$set(this.form, "amount", item.amount);
- if (item.zfiId) {
- this.loading = true;
- listBillInf(item.zfiId)
- .then((response) => {
- this.billInfList = response.data;
- this.loading = false;
- })
- .then(() => {
- var queryParamsFile = {};
- queryParamsFile.ticketList = this.billInfList;
- getFile(queryParamsFile).then((response) => {
- if (response.data) {
- //获取发票文件
- this.invoiceFileList = response.data.invoiceFileList;
- //获取合同文件
- this.contractFileList = response.data.contractFileList;
- //获取其他文件
- this.otherFileList = response.data.otherFileList;
- }
- });
- if (item.zfpcrLoanType == "0") {
- listAccInf(item.zfiProductId).then((response) => {
- this.$set(this.form, "zfrCollectionAccount", response.msg);
- this.onlyRead = true;
- });
- }
- });
- getCreditDetail(item.zfiId).then((response) => {
- if (response.data) {
- this.forms = response.data.financeInf;
- //签发金额大写
- this.issuedAmount = this.smallToBig(this.forms.zfiAmount);
- //给表格赋值
- this.openName = response.data.openName;
- this.openCode = response.data.openCode;
- this.openBank = response.data.openBank;
- this.openAccount = response.data.openAccount;
- this.receiveName = response.data.receiveName;
- this.receiverCode = response.data.receiverCode;
- this.receiverBank = response.data.receiverBank;
- this.receiverAccount = response.data.receiverAccount;
- this.stopDate = response.data.stopDate;
- this.zfiRate = response.data.financeInf.zfiRate;
- }
- //盖章合同
- this.getCreditSealFile();
- });
- }
- },
- //详情按钮
- handleDetail(index, rows) {
- this.zbiId = rows[index].zbiId;
- this.openDetailBill = true;
- },
- /** 提交按钮 */
- submitForm() {
- this.$refs["form"].validate((valid) => {
- if (valid) {
- const loading = this.$loading({
- lock: true,
- text: "Loading",
- spinner: "el-icon-loading",
- background: "rgba(0, 0, 0, 0.7)",
- });
- addRecord(this.form)
- .then((response) => {
- loading.close();
- this.zfrId = response.data.zfrId;
- this.isOpenApproval();
- // this.msgSuccess("融资申请成功");
- // this.$store.dispatch("tagsView/delView", this.$route);
- // this.$router.go(-1);
- })
- .catch((response) => {
- loading.close();
- });
- }
- });
- },
- /* 清空 */
- clearBoth() {
- this.form.zfrAmount = "";
- this.form, (zfrRepaymentDate = "");
- this.form.zfrRate = "";
- this.form.zfpcrLoanType = "";
- this.billInfList = [];
- this.contractFileList = [];
- this.invoiceFileList = [];
- this.otherFileList = [];
- },
- //文件下载
- handleDownload(row) {
- debugger;
- const pfiFileUrl = row.pfiFileUrl;
- if (pfiFileUrl != null && pfiFileUrl != "") {
- const pfiFileName = row.pfiFileName;
- this.queryParamsDown.pfiFileUrl = pfiFileUrl;
- this.download(
- "sc-service/creditLine/jpgAuthorization",
- {
- ...this.queryParamsDown,
- },
- pfiFileName
- );
- // window.open(pfiUrl + "/" + getToken());
- } else {
- this.$message({
- message: "该附件不存在!",
- type: "warning",
- });
- return;
- }
- },
- //预览
- handlePreview(row) {
- const pfiUrl = row.pfiUrl;
- const pfiFileName = row.pfiFileName;
- if (row.pfiUrl) {
- console.log(pfiFileName.substr(-3));
- if (pfiFileName.substr(-3) == "pdf") {
- this.wordUrl = pfiUrl + "/" + getToken();
- this.show = false;
- this.heid = true;
- } else if (
- pfiFileName.substr(-3) == "jpg" ||
- pfiFileName.substr(-3) == "png" ||
- pfiFileName.substr(-3) == "JPG" ||
- pfiFileName.substr(-3) == "PNG" ||
- pfiFileName.substr(-4) == "jpeg" ||
- pfiFileName.substr(-3) == "JPEG"
- ) {
- this.wordUrl = pfiUrl + "/" + getToken();
- this.show = true;
- this.heid = false;
- console.log("====>", this.wordUrl);
- } else if (
- pfiFileName.substr(-3) == "doc" ||
- pfiFileName.substr(-3) == "DOC" ||
- pfiFileName.substr(-4) == "docx" ||
- pfiFileName.substr(-3) == "DOCX"
- ) {
- this.wordUrl =
- "https://view.officeapps.live.com/op/view.aspx?src=" +
- pfiUrl +
- "/" +
- getToken() +
- "/" +
- pfiFileName;
- this.show = false;
- this.heid = true;
- console.log("====>", this.wordUrl);
- } else {
- this.$message({
- message: "暂不支持该类型文件预览",
- type: "warning",
- });
- return;
- }
- }
- this.openFile = true;
- },
- //应收账款合计
- allAmount() {
- var strarr = [0.0];
- for (let i in this.billInfList) {
- strarr.push(this.billInfList[i]["zbiAmount"]);
- }
- return Math.floor(eval(strarr.join("+")) * 100) / 100; //结果
- },
- /* // 将数字金额转换为大写金额 */
- smallToBig(money) {
- // 将数字金额转换为大写金额
- var cnNums = new Array(
- "零",
- "壹",
- "贰",
- "叁",
- "肆",
- "伍",
- "陆",
- "柒",
- "捌",
- "玖"
- ); //汉字的数字
- var cnIntRadice = new Array("", "拾", "佰", "仟"); //基本单位
- var cnIntUnits = new Array("", "万", "亿", "兆"); //对应整数部分扩展单位
- var cnDecUnits = new Array("角", "分", "毫", "厘"); //对应小数部分单位
- var cnInteger = "整"; //整数金额时后面跟的字符
- var cnIntLast = "元"; //整数完以后的单位
- //最大处理的数字
- var maxNum = 999999999999999.9999;
- var integerNum; //金额整数部分
- var decimalNum; //金额小数部分
- //输出的中文金额字符串
- var chineseStr = "";
- var parts; //分离金额后用的数组,预定义
- if (money == "" || money == null || money == undefined) {
- return "零元零角零分";
- }
- money = parseFloat(money);
- if (money >= maxNum) {
- //超出最大处理数字
- return "超出最大处理数字";
- }
- if (money == 0) {
- chineseStr = cnNums[0] + cnIntLast + cnInteger;
- return chineseStr;
- }
- //四舍五入保留两位小数,转换为字符串
- money = Math.round(money * 100).toString();
- integerNum = money.substr(0, money.length - 2);
- decimalNum = money.substr(money.length - 2);
- //获取整型部分转换
- if (parseInt(integerNum, 10) > 0) {
- var zeroCount = 0;
- var IntLen = integerNum.length;
- for (var i = 0; i < IntLen; i++) {
- var n = integerNum.substr(i, 1);
- var p = IntLen - i - 1;
- var q = p / 4;
- var m = p % 4;
- if (n == "0") {
- zeroCount++;
- } else {
- if (zeroCount > 0) {
- chineseStr += cnNums[0];
- }
- //归零
- zeroCount = 0;
- chineseStr += cnNums[parseInt(n)] + cnIntRadice[m];
- }
- if (m == 0 && zeroCount < 4) {
- chineseStr += cnIntUnits[q];
- }
- }
- chineseStr += cnIntLast;
- }
- //小数部分
- if (decimalNum != "") {
- var decLen = decimalNum.length;
- for (var i = 0; i < decLen; i++) {
- var n = decimalNum.substr(i, 1);
- if (n != "0") {
- chineseStr += cnNums[Number(n)] + cnDecUnits[i];
- }
- }
- }
- if (chineseStr == "") {
- chineseStr += cnNums[0] + cnIntLast + cnInteger;
- } else if (decimalNum == "" || /^0*$/.test(decimalNum)) {
- chineseStr += cnInteger;
- }
- return chineseStr;
- },
- /** 导出按钮操作 */
- handleExport() {
- this.download(
- "sc-service/record/export",
- {
- ...this.queryParams,
- },
- `sc-service_record.xlsx`
- );
- },
- // 取消按钮
- cancelFtp() {
- let form = {};
- form.zfrId = this.zfrId;
- cancelContract(form).then((response) => {
- this.cancel();
- });
- this.pdfShowDialog = false;
- },
- //查询有无融资内部审批
- isOpenApproval() {
- var confirmParam = {};
- confirmParam.menuId = "1000000006";
- isOpenApproval(confirmParam).then((response) => {
- var result = response.data.isOpen;
- //有融资内部审批
- if (true == result) {
- this.msgSuccess("已提交内部审批,请内部审批通过后签署融资协议");
- this.cancel();
- } else {
- //无融资内部审批,显示融资合同预览页面
- // this.zfrId = '2c83a92dc238468aabd9cd3261748ae0'
- getRecord(this.zfrId).then((response) => {
- this.zcFinanceInf = response.data.zcFinanceInf;
- this.needPay = response.data.needPay;
- //意愿类型
- this.zfpAuthType = response.data.zfpAuthType;
- this.selectPayment();
- });
- }
- });
- },
- //取消选择意愿
- cancelUpdate() {
- this.confirmIsShow = false;
- this.resetUpdate();
- },
- //关闭盖章短信
- cancelMessage() {
- this.messageIsShow = false;
- this.resetMessage();
- },
- //关闭授权编号激活短信
- cancelMessages() {
- this.messageIfShow = false;
- this.resetMessages();
- },
- //关闭二维码
- cancelFace() {
- this.faceIsShow = false;
- },
- closePdfShow() {
- this.pdfShowDialog = false;
- },
- resetUpdate() {
- this.updateForm = {
- radio: "",
- };
- //意愿类型还原为全部
- this.zfpAuthType = "00";
- this.resetForm("updateForm");
- },
- resetMessage() {
- this.messageForm = {
- validCode: "",
- };
- this.resetForm("messageForm");
- },
- resetMessages() {
- this.messagesForm = {
- validCode: "",
- };
- this.resetForm("messagesForm");
- },
- //获取合同文件
- getContractFile() {
- const loading = this.$loading({
- lock: true,
- text: "Loading",
- background: "rgba(0, 0, 0,0)",
- });
- getContractFile(this.zcFinanceInf)
- .then((response) => {
- loading.close();
- if (response.data.list) {
- this.pdfFileList = response.data.list;
- }
- //文件存在
- if (this.pdfFileList.length > 0) {
- this.pdfIsShow = true
- this.pdfShowDialog = true;
- } else {
- this.$message({
- message: "文件不存在!",
- type: "warning",
- });
- }
- })
- .catch((response) => {
- loading.close();
- });
- },
- //缴费查询
- selectPayment() {
- listCompanyHandler().then((response) => {
- var self = this;
- //self.paiAccno = '3115730025233104147';
- if (response.data == true) {
- cfcaProjectNo().then((response) => {
- if (response.data.scyCfcaAuthNumber == null) {
- this.messageIfShow = true;
- } else {
- var zfrId = self.zfrId;
- listChargeStatus(zfrId).then((response) => {
- if (response.data.accInfList[0]) {
- self.paiAccno = response.data.accInfList[0].paiAccno;
- }
- if (response.data.chargeInfList[0]) {
- if (response.data.chargeInfList[0].zciStatus == "00") {
- self.zciId = response.data.chargeInfList[0].zciId;
- self
- .$confirm("请缴纳手续费" + self.needPay + "元", "警告", {
- confirmButtonText: "去缴费",
- cancelButtonText: "取消",
- type: "warning",
- })
- .then(function () {
- const loading = self.$loading({
- lock: true,
- text: "Loading",
- spinner: "el-icon-loading",
- background: "rgba(0, 0, 0, 0.7)",
- });
- if (self.paiAccno) {
- balance(self.paiAccno)
- .then((response) => {
- if (
- eval(self.needPay) > eval(response.data.kyAmt)
- ) {
- self.$message({
- message:
- "余额为" +
- response.data.kyAmt +
- "不足以抵扣本次缴费费用,请及时充值",
- type: "warning",
- });
- loading.close();
- } else {
- console.log();
- var map = {
- recvAccNo: "",
- recvAccNm: "",
- tranAmt: self.needPay,
- businessId: self.zciId,
- type: "00",
- };
- transfer(map)
- .then((response) => {
- debugger;
- loading.close();
- setTimeout(() => {
- if (response.data.status == "1") {
- self.msgSuccess("缴费成功");
- updateChargeStatus(zfrId, "02").then(
- (res) => {
- self.getContractFile();
- }
- );
- } else if (response.data.status == "0") {
- self.message("正在缴费中,请稍后再试");
- updateChargeStatus(zfrId, "01").then(
- (res) => {}
- );
- } else if (response.data.status == "2") {
- self.msgError(
- "缴费失败,前去费用管理再次缴费"
- );
- updateChargeStatus(zfrId, "05").then(
- (res) => {}
- );
- }
- }, 1000);
- })
- .catch(() => {
- loading.close();
- });
- }
- })
- .catch(() => {
- loading.close();
- });
- } else {
- self.$message({
- message: "您还没有电子账户,请联系平台开通电子账户",
- type: "warning",
- });
- loading.close();
- }
- });
- } else {
- self.getContractFile();
- }
- } else {
- self.getContractFile();
- }
- });
- }
- });
- } else {
- this.$message({
- message: "此操作需经办人权限,请确认您是否是经办人",
- type: 'warning'
- });
- }
- });
- },
- //缴费
- selectType() {
- //选择签署意愿
- if (this.zfpAuthType == "00") {
- this.confirmIsShow = true;
- } else {
- this.checking();
- }
- },
- //确认选择
- confirmSelect() {
- if (!this.updateForm.radio) {
- this.$message({
- message: "请选择签署意愿类型",
- type: "warning",
- });
- return;
- }
- this.confirmIsShow = false;
- this.zfpAuthType = this.updateForm.radio;
- //调用人脸识别或者短信验证
- this.checking();
- },
- //去签署
- checking() {
- //人脸
- if (this.zfpAuthType == "01") {
- //调用人脸识别生成二维码
- faceAuth().then((response) => {
- if (response.data) {
- //获取二维码
- this.fileUrl = response.data.fileUrl;
- //获取源流水号
- var originalTxSN = response.data.originalTxSN;
- this.faceIsShow = true;
- //每5秒查证人脸识别结果
- var timeInterval = window.setInterval(() => {
- setTimeout(() => {
- //源流水不为空并且结果为空
- if (originalTxSN && !this.faceResult) {
- this.authForm.originalTxSN = originalTxSN;
- //调用查证方法
- checkFaceAuth(this.authForm).then((res) => {
- //认证结果
- this.faceResult = res.data.Verification;
- //成功
- if (this.faceResult == "20") {
- this.msgSuccess("验证成功");
- //关闭验证码
- this.faceIsShow = false;
- //关闭定时
- window.clearInterval(timeInterval);
- //调用盖章
- this.contractSigning();
- } else if (this.faceResult == "30") {
- this.$message({
- message: "验证失败",
- type: "warning",
- });
- //关闭验证码
- this.faceIsShow = false;
- window.clearInterval(timeInterval);
- }
- });
- }
- }, 0);
- }, 10000);
- }
- });
- } else if (this.zfpAuthType == "02") {
- //短信
- this.messageIsShow = true;
- }
- },
- //发送短信验证码
- send() {
- //发送
- sendMessage().then((response) => {
- if (response.data) {
- //手机号
- var newIphone = response.data.newIphone;
- //结果
- var result = response.data.result;
- //倒计时
- const TIME_COUNT = 60;
- if (!this.timer) {
- this.count = TIME_COUNT;
- this.showCode = false;
- this.timer = setInterval(() => {
- if (this.count > 0 && this.count <= TIME_COUNT) {
- this.count--;
- } else {
- this.showCode = true;
- clearInterval(this.timer);
- this.timer = null;
- }
- }, 1000);
- }
- //成功
- if ("20" == result) {
- this.$message({
- message:
- "已向经办人手机号为" + newIphone + "发送短信验证码,请注意查收",
- type: "warning",
- });
- } else if ("10" == result) {
- //失败
- this.$message({
- message: "短信发送失败",
- type: "warning",
- });
- }
- }
- });
- },
- //校验验证码是否正确
- checkCode() {
- if (!this.messageForm.validCode) {
- this.$message({
- message: "请输入验证码",
- type: "warning",
- });
- return;
- }
- //校验验证码
- checkCode(this.messageForm).then((response) => {
- if (response.data) {
- //结果
- var verification = response.data.verification;
- //匹配
- if ("20" == verification) {
- //进行下一步-- 盖章
- this.contractSigning();
- } else if ("30" == verification) {
- //不匹配
- this.$message({
- message: "验证有误,请重新输入",
- type: "warning",
- });
- }
- }
- });
- },
- //生成项目授权编号发送短信
- proSend() {
- //发送
- projectSendMessage().then((response) => {
- if (response.data) {
- //手机号
- var newIphone = response.data.newIphone;
- //结果
- var result = response.data.result;
- //项目编号
- this.projectCode = response.data.projectCode;
- //倒计时
- const TIME_COUNT = 60;
- if (!this.timerCode) {
- this.countCode = TIME_COUNT;
- this.showCodes = false;
- this.timerCode = setInterval(() => {
- if (this.countCode > 0 && this.countCode <= TIME_COUNT) {
- this.countCode--;
- } else {
- this.showCodes = true;
- clearInterval(this.timerCode);
- this.timerCode = null;
- }
- }, 1000);
- }
- //成功
- if ("60000000" == result) {
- this.$message({
- message:
- "已向经办人手机号为" + newIphone + "发送短信验证码,请注意查收",
- type: "warning",
- });
- } else {
- //失败
- this.$message({
- message: "短信发送失败",
- type: "warning",
- });
- }
- }
- });
- },
- //校验授权编号验证码
- checkProCode() {
- if (!this.projectForm.code) {
- this.$message({
- message: "请输入验证码",
- type: "warning",
- });
- return;
- }
- //项目编号
- this.projectForm.projectCode = this.projectCode;
- //校验验证码
- checkProCode(this.projectForm).then((response) => {
- if (response.data) {
- //结果
- var verification = response.data.verification;
- //匹配
- if ("60000000" == verification) {
- var zfrId = this.zfrId;
- listChargeStatus(zfrId).then((response) => {
- if (response.data[0]) {
- if (response.data[0].zciStatus == "00") {
- this.$confirm("请缴纳手续费" + this.needPay + "元", "警告", {
- confirmButtonText: "去缴费",
- cancelButtonText: "取消",
- type: "warning",
- })
- .then(function () {
- return updateChargeStatus(zfrId);
- })
- .then(() => {
- this.getContractFile();
- });
- } else {
- this.getContractFile();
- }
- } else {
- this.getContractFile();
- }
- });
- } else {
- //不匹配
- this.$message({
- message: "验证有误,请重新输入",
- type: "warning",
- });
- }
- }
- });
- },
- //盖章
- contractSigning() {
- var self = this;
- const loading = this.$loading({
- lock: true,
- text: "Loading",
- background: "rgba(0, 0, 0,0)",
- });
- self.zcFinanceInf.zfrId = self.zfrId;
- contractSigning(self.zcFinanceInf)
- .then((response) => {
- loading.close();
- self.msgSuccess("盖章成功");
- if (self.zfpAuthType == "02") {
- //关闭短信验证
- self.messageIsShow = false;
- } else if (self.zfpAuthType == "01") {
- //关闭人脸二维码
- self.faceIsShow = false;
- }
- // self.cancel();
- //关闭预览合同
- //self.closePdfShow();
- let queryStamped = {};
- queryStamped.zfrId = this.zfrId
- const load = self.$loading({
- lock: true,
- text: "Loading",
- background: "rgba(0, 0, 0,0)",
- });
- listStamped(queryStamped).then((response) =>{
- if(response.data){
- this.pdfFileList = response.data.list;
- }
- this.pdfShowDialog = true;
- this.pdfIsShow = false;
- load.close()
- }).catch((response) => {
- load.close();
- });
- })
- .catch((response) => {
- loading.close();
- });
- },
- closePDF(){
- this.cancel();
- //关闭预览合同
- this.closePdfShow();
- }
- },
- };
- </script>
- <style lang="scss" scoped>
- .zap-title {
- padding: 20px 25px;
- font-size: 16px;
- color: #333333;
- background-color: #ffffff;
- }
- .zap-form {
- padding: 0px 25px 8px;
- background-color: #ffffff;
- }
- .zap-form--clear {
- padding-left: 0;
- padding-right: 0;
- }
- </style>
- <style type="text/css">
- table.gridtable {
- font-size: 11px;
- color: #333333;
- border-width: 1px;
- border-collapse: collapse;
- }
- table.gridtable th {
- border-width: 1px;
- padding: 8px;
- border-style: solid;
- background-color: #dedede;
- }
- table.gridtable td {
- border-width: 1px;
- padding: 8px;
- border-style: solid;
- }
- </style>
|