financeRecord.vue 26 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699
  1. <template>
  2. <el-tabs type="border-card">
  3. <!-- 全部table页 -->
  4. <el-tab-pane label="全部">
  5. <el-card class="fiche">
  6. <right-toolbar :showSearch.sync="showSearch" @queryTable="getList">收起</right-toolbar>
  7. <span style="margin-bottom: 10px;color:#333333;font:14px Helvetica Neue, Helvetica, PingFang SC, Tahoma, Arial,sans-serif">所选条件:</span>
  8. <div style="float: right;margin-right:1%">
  9. <el-button type="cyan" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
  10. <el-button icon="el-icon-refresh" size="mini" @click="resetQuery" style="float: ;">重置</el-button>
  11. </div>
  12. <hr style="margin-top: 16px;">
  13. <el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" label-width="68px">
  14. <el-form-item label="融资编号" prop="zfrNumber">
  15. <el-input
  16. v-model="queryParams.zfrNumber"
  17. placeholder="请输入融资编号"
  18. clearable
  19. size="small"
  20. @keyup.enter.native="handleQuery"
  21. />
  22. </el-form-item>
  23. </el-form>
  24. </el-card>
  25. <el-row :gutter="10" class="mb8">
  26. <el-col :span="1.5">
  27. <el-button
  28. type="primary"
  29. icon="el-icon-plus"
  30. size="mini"
  31. @click="handleAdd"
  32. v-hasPermi="['finance:record:add']"
  33. >申请融资</el-button>
  34. </el-col>
  35. </el-row>
  36. <el-table v-loading="loading" :data="recordIngList" @selection-change="handleSelectionChange">
  37. <el-table-column label="序号" type="index" width="50" align="center">
  38. <template slot-scope="scope">
  39. <span>{{(queryParams.pageNum - 1) * queryParams.pageSize + scope.$index + 1}}</span>
  40. </template>
  41. </el-table-column>
  42. <el-table-column label="融信编号" align="center" prop="zfiNumner" />
  43. <el-table-column label="融资编号" align="center" prop="zfrNumber" />
  44. <el-table-column label="开立方" align="center" prop="coreScyName" />
  45. <el-table-column label="融资金额" align="center" prop="zfrAmount" />
  46. <el-table-column label="融资利率" align="center" prop="zfrRate" />
  47. <el-table-column label="经办人" align="center" prop="zfrHandler" />
  48. <el-table-column label="承诺还款时间" align="center" prop="zfrRepaymentDate" width="180"/>
  49. <el-table-column label="融资申请日期" align="center" prop="zfrApplyDate" width="180"/>
  50. <el-table-column label="融资放款日期" align="center" prop="zfrLoanDate" width="180"/>
  51. <el-table-column label="融资状态" align="center" prop="zfrStatus" />
  52. <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
  53. <template slot-scope="scope">
  54. <el-button
  55. size="mini"
  56. type="text"
  57. icon="el-icon-edit"
  58. @click="handleUpdate(scope.row)"
  59. v-hasPermi="['sc-service:record:edit']"
  60. >修改</el-button>
  61. <el-button
  62. size="mini"
  63. type="text"
  64. icon="el-icon-delete"
  65. @click="handleDelete(scope.row)"
  66. v-hasPermi="['sc-service:record:remove']"
  67. >删除</el-button>
  68. </template>
  69. </el-table-column>
  70. </el-table>
  71. <pagination
  72. v-show="total>0"
  73. :total="total"
  74. :page.sync="queryParams.pageNum"
  75. :limit.sync="queryParams.pageSize"
  76. @pagination="getList"
  77. />
  78. </el-tab-pane>
  79. <!-- 融资中table页 -->
  80. <el-tab-pane label="融资中">
  81. <el-card class="fiche">
  82. <right-toolbar :showSearch.sync="showSearch" @queryTable="getList">收起</right-toolbar>
  83. <span style="margin-bottom: 10px;color:#333333;font:14px Helvetica Neue, Helvetica, PingFang SC, Tahoma, Arial,sans-serif">所选条件:</span>
  84. <div style="float: right;margin-right:1%">
  85. <el-button type="cyan" icon="el-icon-search" size="mini" @click="handleQueryIng">搜索</el-button>
  86. <el-button icon="el-icon-refresh" size="mini" @click="resetQueryIng" style="float: ;">重置</el-button>
  87. </div>
  88. <hr style="margin-top: 16px;">
  89. <el-form :model="queryParamsIng" ref="queryFormIng" :inline="true" v-show="showSearch" label-width="68px">
  90. <el-form-item label="融资编号" prop="zfrNumber">
  91. <el-input
  92. v-model="queryParamsIng.zfrNumber"
  93. placeholder="请输入融资编号"
  94. clearable
  95. size="small"
  96. @keyup.enter.native="handleQueryIng"
  97. />
  98. </el-form-item>
  99. </el-form>
  100. </el-card>
  101. <el-row :gutter="10" class="mb8">
  102. <el-col :span="1.5">
  103. <el-button
  104. type="primary"
  105. icon="el-icon-plus"
  106. size="mini"
  107. @click="handleAdd"
  108. v-hasPermi="['finance:record:add']"
  109. >申请融资</el-button>
  110. </el-col>
  111. </el-row>
  112. <el-table v-loading="loadingIng" :data="recordList" @selection-change="handleSelectionChangeIng">
  113. <el-table-column label="序号" type="index" width="50" align="center">
  114. <template slot-scope="scope">
  115. <span>{{(queryParamsIng.pageNum - 1) * queryParamsIng.pageSize + scope.$index + 1}}</span>
  116. </template>
  117. </el-table-column>
  118. <el-table-column label="融信编号" align="center" prop="zfiNumner" />
  119. <el-table-column label="融资编号" align="center" prop="zfrNumber" />
  120. <el-table-column label="开立方" align="center" prop="coreScyName" />
  121. <el-table-column label="融资金额" align="center" prop="zfrAmount" />
  122. <el-table-column label="融资利率" align="center" prop="zfrRate" />
  123. <el-table-column label="经办人" align="center" prop="zfrHandler" />
  124. <el-table-column label="承诺还款时间" align="center" prop="zfrRepaymentDate" width="180"/>
  125. <el-table-column label="融资申请日期" align="center" prop="zfrApplyDate" width="180"/>
  126. <el-table-column label="融资放款日期" align="center" prop="zfrLoanDate" width="180"/>
  127. <el-table-column label="融资状态" align="center" prop="zfrStatus" />
  128. <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
  129. <template slot-scope="scope">
  130. <el-button
  131. size="mini"
  132. type="text"
  133. icon="el-icon-edit"
  134. @click="handleUpdate(scope.row)"
  135. v-hasPermi="['sc-service:record:edit']"
  136. >修改</el-button>
  137. <el-button
  138. size="mini"
  139. type="text"
  140. icon="el-icon-delete"
  141. @click="handleDelete(scope.row)"
  142. v-hasPermi="['sc-service:record:remove']"
  143. >删除</el-button>
  144. </template>
  145. </el-table-column>
  146. </el-table>
  147. <pagination
  148. v-show="totalIng>0"
  149. :total="totalIng"
  150. :page.sync="queryParamsIng.pageNum"
  151. :limit.sync="queryParamsIng.pageSize"
  152. @pagination="getList"
  153. />
  154. </el-tab-pane>
  155. <!-- 已放款table页 -->
  156. <el-tab-pane label="已放款">
  157. <el-card class="fiche">
  158. <right-toolbar :showSearch.sync="showSearch" @queryTable="getList">收起</right-toolbar>
  159. <span style="margin-bottom: 10px;color:#333333;font:14px Helvetica Neue, Helvetica, PingFang SC, Tahoma, Arial,sans-serif">所选条件:</span>
  160. <div style="float: right;margin-right:1%">
  161. <el-button type="cyan" icon="el-icon-search" size="mini" @click="handleQueryEnd">搜索</el-button>
  162. <el-button icon="el-icon-refresh" size="mini" @click="resetQueryEnd" style="float: ;">重置</el-button>
  163. </div>
  164. <hr style="margin-top: 16px;">
  165. <el-form :model="queryParamsEnd" ref="queryFormEnd" :inline="true" v-show="showSearch" label-width="68px">
  166. <el-form-item label="融资编号" prop="zfrNumber">
  167. <el-input
  168. v-model="queryParamsEnd.zfrNumber"
  169. placeholder="请输入融资编号"
  170. clearable
  171. size="small"
  172. @keyup.enter.native="handleQueryEnd"
  173. />
  174. </el-form-item>
  175. </el-form>
  176. </el-card>
  177. <el-row :gutter="10" class="mb8">
  178. <el-col :span="1.5">
  179. <el-button
  180. type="primary"
  181. icon="el-icon-plus"
  182. size="mini"
  183. @click="handleAdd"
  184. v-hasPermi="['finance:record:add']"
  185. >申请融资</el-button>
  186. </el-col>
  187. </el-row>
  188. <el-table v-loading="loadingEnd" :data="recordEndList" @selection-change="handleSelectionChange">
  189. <el-table-column label="序号" type="index" width="50" align="center">
  190. <template slot-scope="scope">
  191. <span>{{(queryParamsEnd.pageNum - 1) * queryParamsEnd.pageSize + scope.$index + 1}}</span>
  192. </template>
  193. </el-table-column>
  194. <el-table-column label="融信编号" align="center" prop="zfiNumner" />
  195. <el-table-column label="融资编号" align="center" prop="zfrNumber" />
  196. <el-table-column label="开立方" align="center" prop="coreScyName" />
  197. <el-table-column label="融资金额" align="center" prop="zfrAmount" />
  198. <el-table-column label="融资利率" align="center" prop="zfrRate" />
  199. <el-table-column label="经办人" align="center" prop="zfrHandler" />
  200. <el-table-column label="承诺还款时间" align="center" prop="zfrRepaymentDate" width="180"/>
  201. <el-table-column label="融资申请日期" align="center" prop="zfrApplyDate" width="180"/>
  202. <el-table-column label="融资放款日期" align="center" prop="zfrLoanDate" width="180"/>
  203. <el-table-column label="融资状态" align="center" prop="zfrStatus" />
  204. <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
  205. <template slot-scope="scope">
  206. <el-button
  207. size="mini"
  208. type="text"
  209. icon="el-icon-edit"
  210. @click="handleUpdate(scope.row)"
  211. v-hasPermi="['sc-service:record:edit']"
  212. >修改</el-button>
  213. <el-button
  214. size="mini"
  215. type="text"
  216. icon="el-icon-delete"
  217. @click="handleDelete(scope.row)"
  218. v-hasPermi="['sc-service:record:remove']"
  219. >删除</el-button>
  220. </template>
  221. </el-table-column>
  222. </el-table>
  223. <pagination
  224. v-show="totalEnd>0"
  225. :total="totalEnd"
  226. :page.sync="queryParamsEnd.pageNum"
  227. :limit.sync="queryParamsEnd.pageSize"
  228. @pagination="getList"
  229. />
  230. </el-tab-pane>
  231. <!-- 融资失败table页 -->
  232. <el-tab-pane label="融资失败">
  233. <el-card class="fiche">
  234. <right-toolbar :showSearch.sync="showSearch" @queryTable="getList">收起</right-toolbar>
  235. <span style="margin-bottom: 10px;color:#333333;font:14px Helvetica Neue, Helvetica, PingFang SC, Tahoma, Arial,sans-serif">所选条件:</span>
  236. <div style="float: right;margin-right:1%">
  237. <el-button type="cyan" icon="el-icon-search" size="mini" @click="handleQueryLose">搜索</el-button>
  238. <el-button icon="el-icon-refresh" size="mini" @click="resetQueryLose" style="float: ;">重置</el-button>
  239. </div>
  240. <hr style="margin-top: 16px;">
  241. <el-form :model="queryParamsLose" ref="queryFormLose" :inline="true" v-show="showSearch" label-width="68px">
  242. <el-form-item label="融资编号" prop="zfrNumber">
  243. <el-input
  244. v-model="queryParamsLose.zfrNumber"
  245. placeholder="请输入融资编号"
  246. clearable
  247. size="small"
  248. @keyup.enter.native="handleQueryLose"
  249. />
  250. </el-form-item>
  251. </el-form>
  252. </el-card>
  253. <el-row :gutter="10" class="mb8">
  254. <el-col :span="1.5">
  255. <el-button
  256. type="primary"
  257. icon="el-icon-plus"
  258. size="mini"
  259. @click="handleAdd"
  260. v-hasPermi="['finance:record:add']"
  261. >申请融资</el-button>
  262. </el-col>
  263. </el-row>
  264. <el-table v-loading="loadingLose" :data="recordLoseList" @selection-change="handleSelectionChange">
  265. <el-table-column label="序号" type="index" width="50" align="center">
  266. <template slot-scope="scope">
  267. <span>{{(queryParamsLose.pageNum - 1) * queryParamsLose.pageSize + scope.$index + 1}}</span>
  268. </template>
  269. </el-table-column>
  270. <el-table-column label="融信编号" align="center" prop="zfiNumner" />
  271. <el-table-column label="融资编号" align="center" prop="zfrNumber" />
  272. <el-table-column label="开立方" align="center" prop="coreScyName" />
  273. <el-table-column label="融资金额" align="center" prop="zfrAmount" />
  274. <el-table-column label="融资利率" align="center" prop="zfrRate" />
  275. <el-table-column label="经办人" align="center" prop="zfrHandler" />
  276. <el-table-column label="承诺还款时间" align="center" prop="zfrRepaymentDate" width="180"/>
  277. <el-table-column label="融资申请日期" align="center" prop="zfrApplyDate" width="180"/>
  278. <el-table-column label="融资放款日期" align="center" prop="zfrLoanDate" width="180"/>
  279. <el-table-column label="融资状态" align="center" prop="zfrStatus" />
  280. <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
  281. <template slot-scope="scope">
  282. <el-button
  283. size="mini"
  284. type="text"
  285. icon="el-icon-edit"
  286. @click="handleUpdate(scope.row)"
  287. v-hasPermi="['sc-service:record:edit']"
  288. >修改</el-button>
  289. <el-button
  290. size="mini"
  291. type="text"
  292. icon="el-icon-delete"
  293. @click="handleDelete(scope.row)"
  294. v-hasPermi="['sc-service:record:remove']"
  295. >删除</el-button>
  296. </template>
  297. </el-table-column>
  298. </el-table>
  299. <pagination
  300. v-show="totalLose>0"
  301. :total="totalLose"
  302. :page.sync="queryParamsLose.pageNum"
  303. :limit.sync="queryParamsLose.pageSize"
  304. @pagination="getList"
  305. />
  306. </el-tab-pane>
  307. <!-- 添加或修改融资记录对话框 -->
  308. <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
  309. <el-form ref="form" :model="form" :rules="rules" label-width="80px">
  310. <el-form-item label="融信ID(zc_finance_inf.zfi_id)" prop="zfrFinanceId">
  311. <el-input v-model="form.zfrFinanceId" placeholder="请输入融信ID(zc_finance_inf.zfi_id)" />
  312. </el-form-item>
  313. <el-form-item label="融资编号" prop="zfrNumber">
  314. <el-input v-model="form.zfrNumber" placeholder="请输入融资编号" />
  315. </el-form-item>
  316. <el-form-item label="融资金额" prop="zfrAmount">
  317. <el-input v-model="form.zfrAmount" placeholder="请输入融资金额" />
  318. </el-form-item>
  319. <el-form-item label="融资利率" prop="zfrRate">
  320. <el-input v-model="form.zfrRate" placeholder="请输入融资利率" />
  321. </el-form-item>
  322. <el-form-item label="经办人" prop="zfrHandler">
  323. <el-input v-model="form.zfrHandler" placeholder="请输入经办人" />
  324. </el-form-item>
  325. <el-form-item label="承诺还款时间" prop="zfrRepaymentDate">
  326. <el-date-picker clearable size="small"
  327. v-model="form.zfrRepaymentDate"
  328. type="date"
  329. value-format="yyyy-MM-dd"
  330. placeholder="选择承诺还款时间">
  331. </el-date-picker>
  332. </el-form-item>
  333. <el-form-item label="融资申请日期" prop="zfrApplyDate">
  334. <el-date-picker clearable size="small"
  335. v-model="form.zfrApplyDate"
  336. type="date"
  337. value-format="yyyy-MM-dd"
  338. placeholder="选择融资申请日期">
  339. </el-date-picker>
  340. </el-form-item>
  341. <el-form-item label="融资放款日期" prop="zfrLoanDate">
  342. <el-date-picker clearable size="small"
  343. v-model="form.zfrLoanDate"
  344. type="date"
  345. value-format="yyyy-MM-dd"
  346. placeholder="选择融资放款日期">
  347. </el-date-picker>
  348. </el-form-item>
  349. <el-form-item label="已还款金额" prop="zfrApplyAmount">
  350. <el-input v-model="form.zfrApplyAmount" placeholder="请输入已还款金额" />
  351. </el-form-item>
  352. <el-form-item label="还款方式(0:线下, 1:线上)" prop="zfrApplyType">
  353. <el-select v-model="form.zfrApplyType" placeholder="请选择还款方式(0:线下, 1:线上)">
  354. <el-option label="请选择字典生成" value="" />
  355. </el-select>
  356. </el-form-item>
  357. <el-form-item label="状态">
  358. <el-radio-group v-model="form.zfrStatus">
  359. <el-radio label="1">请选择字典生成</el-radio>
  360. </el-radio-group>
  361. </el-form-item>
  362. <el-form-item label="审批状态(00:审核中 01:审批退回)" prop="zfrApproveStt">
  363. <el-input v-model="form.zfrApproveStt" placeholder="请输入审批状态(00:审核中 01:审批退回)" />
  364. </el-form-item>
  365. </el-form>
  366. <div slot="footer" class="dialog-footer">
  367. <el-button type="primary" @click="submitForm">确 定</el-button>
  368. <el-button @click="cancel">取 消</el-button>
  369. </div>
  370. </el-dialog>
  371. </el-tabs>
  372. </template>
  373. <script>
  374. import { listRecord, getRecord, delRecord, addRecord, updateRecord } from "@/api/service/financeRecord/record";
  375. import Cookies from 'js-cookie'
  376. export default {
  377. name: "finaceRecord",
  378. components: {
  379. },
  380. data() {
  381. return {
  382. // 遮罩层
  383. loading: true,
  384. loadingIng: true,
  385. loadingEnd: true,
  386. loadingLose: true,
  387. // 选中数组
  388. ids: [],
  389. // 非单个禁用
  390. single: true,
  391. // 非多个禁用
  392. multiple: true,
  393. // 显示搜索条件
  394. showSearch: true,
  395. // 总条数
  396. total: 0,
  397. totalIng: 0,
  398. totalEnd: 0,
  399. totalLose: 0,
  400. // 全部融资记录表格数据
  401. recordList: [],
  402. // 融资中融资记录表格数据
  403. recordIngList: [],
  404. // 已放款融资记录表格数据
  405. recordEndList: [],
  406. // 融资失败融资记录表格数据
  407. recordLoseList: [],
  408. // 弹出层标题
  409. title: "",
  410. // 是否显示弹出层
  411. open: false,
  412. // 查询参数
  413. queryParams: {
  414. pageNum: 1,
  415. pageSize: 10,
  416. zfrFinanceId: null,
  417. zfrNumber: null,
  418. zfrAmount: null,
  419. zfrRate: null,
  420. zfrHandler: null,
  421. zfrRepaymentDate: null,
  422. zfrApplyDate: null,
  423. zfrLoanDate: null,
  424. zfrApplyAmount: null,
  425. zfrApplyType: null,
  426. zfrStatus: null,
  427. zfrApproveStt: null,
  428. },
  429. queryParamsIng: {
  430. pageNum: 1,
  431. pageSize: 10,
  432. zfrFinanceId: null,
  433. zfrNumber: null,
  434. zfrAmount: null,
  435. zfrRate: null,
  436. zfrHandler: null,
  437. zfrRepaymentDate: null,
  438. zfrApplyDate: null,
  439. zfrLoanDate: null,
  440. zfrApplyAmount: null,
  441. zfrApplyType: null,
  442. zfrStatus: null,
  443. zfrApproveStt: null,
  444. },
  445. queryParamsEnd: {
  446. pageNum: 1,
  447. pageSize: 10,
  448. zfrFinanceId: null,
  449. zfrNumber: null,
  450. zfrAmount: null,
  451. zfrRate: null,
  452. zfrHandler: null,
  453. zfrRepaymentDate: null,
  454. zfrApplyDate: null,
  455. zfrLoanDate: null,
  456. zfrApplyAmount: null,
  457. zfrApplyType: null,
  458. zfrStatus: null,
  459. zfrApproveStt: null,
  460. },
  461. queryParamsLose: {
  462. pageNum: 1,
  463. pageSize: 10,
  464. zfrFinanceId: null,
  465. zfrNumber: null,
  466. zfrAmount: null,
  467. zfrRate: null,
  468. zfrHandler: null,
  469. zfrRepaymentDate: null,
  470. zfrApplyDate: null,
  471. zfrLoanDate: null,
  472. zfrApplyAmount: null,
  473. zfrApplyType: null,
  474. zfrStatus: null,
  475. zfrApproveStt: null,
  476. },
  477. // 表单参数
  478. form: {},
  479. // 表单校验
  480. rules: {
  481. zfrFinanceId: [
  482. { required: true, message: "融信ID(zc_finance_inf.zfi_id)不能为空", trigger: "blur" }
  483. ],
  484. zfrAmount: [
  485. { required: true, message: "融资金额不能为空", trigger: "blur" }
  486. ],
  487. zfrRate: [
  488. { required: true, message: "融资利率不能为空", trigger: "blur" }
  489. ],
  490. zfrHandler: [
  491. { required: true, message: "经办人不能为空", trigger: "blur" }
  492. ],
  493. zfrStatus: [
  494. { required: true, message: "状态不能为空", trigger: "blur" }
  495. ],
  496. }
  497. };
  498. },
  499. created() {
  500. this.getList();
  501. this.getIngList();
  502. this.getEndList();
  503. this.getLoseList();
  504. },
  505. methods: {
  506. /** 查询全部融资记录列表 */
  507. getList() {
  508. this.loading = true;
  509. listRecord(this.queryParams).then(response => {
  510. this.recordList = response.rows;
  511. this.total = response.total;
  512. this.loading = false;
  513. });
  514. },
  515. /** 查询融资中融资记录列表 */
  516. getIngList() {
  517. this.loading = true;
  518. this.queryParamsIng.zfrStatus = '00';
  519. listRecord(this.queryParamsIng).then(response => {
  520. this.recordIngList = response.rows;
  521. this.totalIng = response.total;
  522. this.loading = false;
  523. });
  524. },
  525. /** 查询已放款融资记录列表 */
  526. getEndList() {
  527. this.loading = true;
  528. this.queryParamsEnd.zfrStatus = '01';
  529. listRecord(this.queryParamsEnd).then(response => {
  530. this.recordEndList = response.rows;
  531. this.totalIng = response.total;
  532. this.loading = false;
  533. });
  534. },
  535. /** 查询融资失败融资记录列表 */
  536. getLoseList() {
  537. this.loading = true;
  538. this.queryParamsLose.zfrStatus = '02';
  539. listRecord(this.queryParamsLose).then(response => {
  540. this.recordLoseList = response.rows;
  541. this.totalEnd = response.total;
  542. this.loading = false;
  543. });
  544. },
  545. // 取消按钮
  546. cancel() {
  547. this.open = false;
  548. this.reset();
  549. },
  550. // 表单重置
  551. reset() {
  552. this.form = {
  553. zfrId: null,
  554. zfrFinanceId: null,
  555. zfrNumber: null,
  556. zfrAmount: null,
  557. zfrRate: null,
  558. zfrHandler: null,
  559. zfrRepaymentDate: null,
  560. zfrApplyDate: null,
  561. zfrLoanDate: null,
  562. zfrApplyAmount: null,
  563. zfrApplyType: null,
  564. zfrStatus: "0",
  565. zfrApproveStt: null,
  566. zfrProfitSpare1: null,
  567. zfrProfitSpare2: null,
  568. zfrProfitSpare3: null,
  569. zfrProfitSpare4: null,
  570. zfrProfitSpare5: null,
  571. zfrProfitSpare6: null,
  572. zfrProfitSpare7: null,
  573. zfrProfitSpare8: null,
  574. zfrProfitSpare9: null,
  575. createBy: null,
  576. createTime: null,
  577. updateBy: null,
  578. updateTime: null
  579. };
  580. this.resetForm("form");
  581. },
  582. /** 全部搜索按钮操作 */
  583. handleQuery() {
  584. this.queryParams.pageNum = 1;
  585. this.getList();
  586. },
  587. /** 全部重置按钮操作 */
  588. resetQuery() {
  589. this.resetForm("queryForm");
  590. this.handleQuery();
  591. },
  592. /** 融资中搜索按钮操作 */
  593. handleQueryIng() {
  594. this.queryParamsIng.pageNum = 1;
  595. this.getList();
  596. },
  597. /**融资中重置按钮操作 */
  598. resetQueryIng() {
  599. this.resetForm("queryFormIng");
  600. this.handleQueryIng();
  601. },
  602. /** 已放款搜索按钮操作 */
  603. handleQueryEnd() {
  604. this.queryParamsEnd.pageNum = 1;
  605. this.getList();
  606. },
  607. /**已放款重置按钮操作 */
  608. resetQueryEnd() {
  609. this.resetForm("queryFormEnd");
  610. this.handleQueryEnd();
  611. },
  612. /** 融资失败搜索按钮操作 */
  613. handleQueryLose() {
  614. this.queryParamsLose.pageNum = 1;
  615. this.getList();
  616. },
  617. /*融资失败重置按钮操作 */
  618. resetQueryLose() {
  619. this.resetForm("queryFormLose");
  620. this.handleQueryLose();
  621. },
  622. //全部 多选框选中数据
  623. handleSelectionChange(selection) {
  624. this.ids = selection.map(item => item.zfrId)
  625. this.single = selection.length!==1
  626. this.multiple = !selection.length
  627. },
  628. // 融资中多选框选中数据
  629. handleSelectionChangeIng(selection) {
  630. this.ids = selection.map(item => item.zfrId)
  631. this.single = selection.length!==1
  632. this.multiple = !selection.length
  633. },
  634. /** 新增按钮操作 */
  635. handleAdd() {
  636. Cookies.set("/financeRecord/addFinanceRecord/", this.$route.fullPath)
  637. this.$router.push("/financeRecord/addFinanceRecord/");
  638. // this.reset();
  639. // this.open = true;
  640. // this.title = "添加融资记录";
  641. },
  642. /** 修改按钮操作 */
  643. handleUpdate(row) {
  644. this.reset();
  645. const zfrId = row.zfrId || this.ids
  646. getRecord(zfrId).then(response => {
  647. this.form = response.data;
  648. this.open = true;
  649. this.title = "修改融资记录";
  650. });
  651. },
  652. /** 提交按钮 */
  653. submitForm() {
  654. this.$refs["form"].validate(valid => {
  655. if (valid) {
  656. if (this.form.zfrId != null) {
  657. updateRecord(this.form).then(response => {
  658. this.msgSuccess("修改成功");
  659. this.open = false;
  660. this.getList();
  661. });
  662. } else {
  663. addRecord(this.form).then(response => {
  664. this.msgSuccess("新增成功");
  665. this.open = false;
  666. this.getList();
  667. });
  668. }
  669. }
  670. });
  671. },
  672. /** 删除按钮操作 */
  673. handleDelete(row) {
  674. const zfrIds = row.zfrId || this.ids;
  675. this.$confirm('是否确认删除融资记录编号为"' + zfrIds + '"的数据项?', "警告", {
  676. confirmButtonText: "确定",
  677. cancelButtonText: "取消",
  678. type: "warning"
  679. }).then(function() {
  680. return delRecord(zfrIds);
  681. }).then(() => {
  682. this.getList();
  683. this.msgSuccess("删除成功");
  684. })
  685. },
  686. /** 导出按钮操作 */
  687. handleExport() {
  688. this.download('sc-service/record/export', {
  689. ...this.queryParams
  690. }, `sc-service_record.xlsx`)
  691. }
  692. }
  693. };
  694. </script>