index.vue 24 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622
  1. <template>
  2. <basic-container>
  3. <avue-crud :option="option" :data="dataList" ref="crud" v-model="form" :page.sync="page" :search.sync="search"
  4. :table-loading="loading" :cell-style="cellStyle" @search-change="searchChange" @search-reset="searchReset"
  5. @selection-change="selectionChange" @current-change="currentChange" @size-change="sizeChange"
  6. @refresh-change="refreshChange" @on-load="onLoad">
  7. <template slot="corpIdSearch">
  8. <!-- <select-component v-model="search.corpId" :configuration="configuration"></select-component>-->
  9. <el-select v-model="search.corpId" clearable placeholder="请选择">
  10. <el-option
  11. v-for="item in corpsList"
  12. :key="item.id"
  13. :label="item.cname"
  14. :value="item.id">
  15. </el-option>
  16. </el-select>
  17. </template>
  18. <template slot-scope="scope" slot="checkType">
  19. <span v-if="scope.row.checkType == 'HYCK-FFSQ'">付费申请</span>
  20. <span v-if="scope.row.checkType == 'HYCK-FPSQ'">发票申请</span>
  21. <span v-else-if="scope.row.checkType == 'HYCK-DJ'">海运出口</span>
  22. <span v-else-if="scope.row.checkType == 'HYCK-FY'">海运出口费用</span>
  23. <span v-else-if="scope.row.checkType == 'HYJK-DJ'">海运进口</span>
  24. <span v-else-if="scope.row.checkType == 'HYJK-FY'">海运进口费用</span>
  25. <span v-else-if="scope.row.checkType == 'sea-approve'">海运出口AMEND</span>
  26. <span v-else-if="scope.row.checkType == 'sia-approve'">海运进口AMEND</span>
  27. <span v-else-if="scope.row.checkType == 'aea-approve'">空运出口AMEND</span>
  28. <span v-else-if="scope.row.checkType == 'aia-approve'">空运进口AMEND</span>
  29. <span v-else-if="scope.row.checkType == 'KYCK-DJ'">空运出口</span>
  30. <span v-else-if="scope.row.checkType == 'KYJK-DJ'">空运进口</span>
  31. <span v-else-if="scope.row.checkType == 'BGSE'">海运出口报关</span>
  32. <span v-else-if="scope.row.checkType == 'BGSI'">海运进口报关</span>
  33. <span v-else-if="scope.row.checkType == 'BGAE'">空运出口报关</span>
  34. <span v-else-if="scope.row.checkType == 'BGAI'">空运进口报关</span>
  35. </template>
  36. <template slot-scope="scope" slot="billNo">
  37. <span style="color: #1e9fff;cursor: pointer;" @click="billNoDetails(scope.row)">{{scope.row.billNo}}</span>
  38. </template>
  39. <!-- <template slot="menuLeft">
  40. <el-button size="small" type="success" :disabled="selectionList.length == 0" @click.stop="batchCheck">批量审批
  41. </el-button>
  42. </template> -->
  43. <template slot-scope="scope" slot="menu">
  44. <!-- <el-button type="text" size="small" :disabled="scope.row.operate" @click.stop="jumpPage(scope.row)">查看-->
  45. <!-- </el-button>-->
  46. <el-button type="text" size="small" :disabled="scope.row.operate" @click.stop="jumpPage(scope.row)">查看
  47. </el-button>
  48. <el-button type="text" size="small"
  49. v-if="scope.row.checkType == 'HYCK-DJ'"
  50. :disabled="scope.row.auditStatus != 'S'"
  51. @click.stop="printWindowfun(scope.row,'HYCK-DJ')">审批
  52. </el-button>
  53. <el-button type="text" size="small"
  54. v-else-if="scope.row.checkType == 'HYJK-DJ'"
  55. :disabled="scope.row.auditStatus != 'S'"
  56. @click.stop="printWindowfun(scope.row,'HYJK-DJ')">审批
  57. </el-button>
  58. <el-button type="text" size="small"
  59. v-else-if="scope.row.checkType == 'KYCK-DJ'"
  60. :disabled="scope.row.auditStatus != 'S'"
  61. @click.stop="printWindowfun(scope.row,'KYCK-DJ')">审批
  62. </el-button>
  63. <el-button type="text" size="small"
  64. v-else-if="scope.row.checkType == 'KYJK-DJ'"
  65. :disabled="scope.row.auditStatus != 'S'"
  66. @click.stop="printWindowfun(scope.row,'KYJK-DJ')">审批
  67. </el-button>
  68. <el-button type="text" size="small"
  69. v-else-if="scope.row.checkType == 'HYCK-FFSQ'"
  70. :disabled="scope.row.auditStatus != 'S'"
  71. @click.stop="printWindowfun(scope.row,'HYCK-FFSQ')">审批
  72. </el-button>
  73. <el-button type="text" size="small"
  74. v-else-if="scope.row.checkType == 'sea-approve'"
  75. :disabled="scope.row.auditStatus != 'S'"
  76. @click.stop="printWindowfun(scope.row,'sea-approve')">审批
  77. </el-button>
  78. <el-button type="text" size="small"
  79. v-else-if="scope.row.checkType == 'sia-approve'"
  80. :disabled="scope.row.auditStatus != 'S'"
  81. @click.stop="printWindowfun(scope.row,'sia-approve')">审批
  82. </el-button>
  83. <el-button type="text" size="small"
  84. v-else-if="scope.row.checkType == 'aea-approve'"
  85. :disabled="scope.row.auditStatus != 'S'"
  86. @click.stop="printWindowfun(scope.row,'aea-approve')">审批
  87. </el-button>
  88. <el-button type="text" size="small"
  89. v-else-if="scope.row.checkType == 'aia-approve'"
  90. :disabled="scope.row.auditStatus != 'S'"
  91. @click.stop="printWindowfun(scope.row,'aia-approve')">审批
  92. </el-button>
  93. <el-button type="text" size="small"
  94. v-else
  95. :disabled="scope.row.auditStatus != 'S'"
  96. @click.stop="openCheck(scope.row)">审批
  97. </el-button>
  98. <el-button type="text" size="small" @click.stop="openCheckSchedule(scope.row)">审批流程
  99. </el-button>
  100. </template>
  101. </avue-crud>
  102. <el-dialog append-to-body title="审批进度" class="el-dialogDeep" :visible.sync="checkScheduleDialog" width="40%"
  103. :close-on-click-modal="false" :destroy-on-close="true" :close-on-press-escape="false" v-dialog-drag>
  104. <check-schedule :checkId="checkId" :batchNo="batchNo" @choceScheduleFun="choceScheduleFun">
  105. </check-schedule>
  106. </el-dialog>
  107. <!--单个审批-->
  108. <el-dialog append-to-body title="审批" class="el-dialogDeep" :visible.sync="checkDialog" width="50%"
  109. :close-on-click-modal="false" :destroy-on-close="true" :close-on-press-escape="false" v-dialog-drag>
  110. <check :checkData="checkData" :checkDetail="true" :idList="idList" @operationType="operationTypeFFSQ"
  111. @choceCheckFun="choceCheckFFSQ">
  112. </check>
  113. </el-dialog>
  114. <!--报表+审批-->
  115. <reportContainerlos style="width: 100%; height: 100vh" ref="reportContainer">
  116. <check :checkData="checkData" :checkDetail="true" :idList="idList" @operationType="operationType"
  117. @choceCheckFun="choceCheckFun">
  118. </check>
  119. </reportContainerlos>
  120. <!--<el-dialog-->
  121. <!-- title="打印"-->
  122. <!-- :visible.sync="selectPrintingDialog"-->
  123. <!-- append-to-body-->
  124. <!-- width="70%"-->
  125. <!-- :before-close="handleClose">-->
  126. <!-- <div>-->
  127. <!-- <reportformsList ref="reportformsList" @reportRadio="reportRadio"></reportformsList>-->
  128. <!-- </div>-->
  129. <!-- <span slot="footer" class="dialog-footer">-->
  130. <!-- <el-button size="small" @click="selectPrintingDialog = false;">取 消</el-button>-->
  131. <!-- </span>-->
  132. <!--</el-dialog>-->
  133. </basic-container>
  134. </template>
  135. <script>
  136. import option from "./configuration/mainList.json";
  137. import option2 from "./configuration/mainList2.json";
  138. import option3 from "./configuration/mainList3.json";
  139. import option4 from "./configuration/mainList4.json";
  140. import { getList, approvePass, financingExcess } from "@/api/approveDataH/main";
  141. import checkSchedule from "@/components/checkH/checkSchedule";
  142. import check from "./check";
  143. import { getUserInfo } from "@/api/system/user";
  144. import { gainUser } from "@/api/basicData/customerInquiry";
  145. import {corpsDescListAll} from "../../api/tirePartsMall/salesManagement/saleOrder";
  146. import reportContainerlos from "@/views/iosBasicData/report-container/report-container-los.vue"
  147. import {finstlbillsDetail} from "../../api/iosBasicData/finstlbills";
  148. import {reportsGetReportData} from "@/api/iosBasicData/reports";
  149. import reportformsList from "@/views/iosBasicData/SeafreightExportF/bills/assembly/reportformsList.vue";
  150. import {getList as getreportsList} from "@/api/iosBasicData/reports";
  151. let previousRouterName = "";
  152. let checkRefresh = "";
  153. export default {
  154. components: {
  155. reportformsList,
  156. check,
  157. checkSchedule,
  158. reportContainerlos
  159. },
  160. data() {
  161. return {
  162. selectPrintingDialog:false, // 打印弹窗
  163. reportsData:{}, // 当前要审核数据
  164. reportlist:[], // 报表数据
  165. corpsList: [],
  166. loading: false,
  167. form: {},
  168. search: {},
  169. show: true,
  170. checkDialog: false,
  171. checkId: "",
  172. batchNo: "",
  173. checkScheduleDialog: false,
  174. detailData: {},
  175. option: {},
  176. parentId: 0,
  177. checkData: {},
  178. dataList: [],
  179. idList: [],
  180. selectionList: [],
  181. page: {
  182. pageSize: 10,
  183. pagerCount: 5,
  184. total: 0
  185. },
  186. query: {},
  187. configuration: {
  188. multipleChoices: false,
  189. multiple: false,
  190. disabled: false,
  191. searchShow: true,
  192. collapseTags: false,
  193. clearable: true,
  194. placeholder: "请点击右边按钮选择",
  195. dicData: []
  196. }
  197. };
  198. },
  199. created() {
  200. getUserInfo().then(res => {
  201. if (res.data.data.billType == 1) {
  202. this.option = option2;
  203. } else {
  204. if (this.$store.getters.userInfo.tenant_id === "681169") {
  205. this.option = option3;
  206. }else if (this.$store.getters.userInfo.tenant_id === "673511") {
  207. this.option = option4;
  208. }else if (this.$store.getters.userInfo.tenant_id === "064132") {
  209. this.option = option4;
  210. } else {
  211. this.option = option;
  212. }
  213. }
  214. this.getWorkDicts("auditStatus").then(res => {
  215. this.findObject(this.option.column, "auditStatus").dicData =
  216. res.data.data;
  217. });
  218. gainUser().then(res => {
  219. this.findObject(this.option.column, "sendUserId").dicData =
  220. res.data.data;
  221. });
  222. this.getWorkDicts("tire_audit").then(res => {
  223. this.findObject(this.option.column, "processType").dicData =
  224. res.data.data;
  225. });
  226. });
  227. // 供应商
  228. // corpsDescListAll({corpType: "GYS"}).then(res => {
  229. // this.corpsList = res.data.data
  230. // })
  231. },
  232. mounted() {
  233. // option.height = window.innerHeight - 200 ;
  234. },
  235. activated() {
  236. if (this.$route.query.check === "refresh") {
  237. this.onLoad(this.page, this.search);
  238. }
  239. },
  240. methods: {
  241. // 点击审核弹出打印表格
  242. printWindowfun(row,type){
  243. // 当时选择的数据
  244. this.reportsData = row
  245. this.checkData = row
  246. let obj = {}
  247. if (type == 'HYCK-DJ') {
  248. obj = {
  249. businessType:'HYCK',
  250. classifyCode:'业务',
  251. groupCode:'销售报告'
  252. }
  253. }else if (type == 'HYJK-DJ') {
  254. obj = {
  255. businessType:'HYJK',
  256. classifyCode:'业务',
  257. groupCode:'销售报告'
  258. }
  259. } else if (type == 'KYCK-DJ') {
  260. obj = {
  261. businessType:'KYCK',
  262. classifyCode:'业务',
  263. groupCode:'销售报告'
  264. }
  265. }else if (type == 'KYJK-DJ') {
  266. obj = {
  267. businessType:'KYJK',
  268. classifyCode:'业务',
  269. groupCode:'销售报告'
  270. }
  271. } else if (type == 'HYCK-FFSQ') {
  272. obj = {
  273. businessType:'FFSQ',
  274. classifyCode:'付费申请',
  275. groupCode:'付费申请'
  276. }
  277. }else if (type == 'sea-approve') {
  278. obj = {
  279. businessType:'AMEND',
  280. classifyCode:'AMENDSE',
  281. groupCode:'SE'
  282. }
  283. }else if (type == 'sia-approve') {
  284. obj = {
  285. businessType:'AMEND',
  286. classifyCode:'AMENDSI',
  287. groupCode:'SI'
  288. }
  289. }else if (type == 'aea-approve') {
  290. obj = {
  291. businessType:'AMEND',
  292. classifyCode:'AMENDAE',
  293. groupCode:'AE'
  294. }
  295. }else if (type == 'aia-approve') {
  296. obj = {
  297. businessType:'AMEND',
  298. classifyCode:'AMENDAI',
  299. groupCode:'AI'
  300. }
  301. }else {}
  302. getreportsList(1, 10, obj).then(res=>{
  303. this.reportRadio(res.data.data.records[0])
  304. })
  305. // this.selectPrintingDialog = true
  306. // let page = {
  307. // pageSize: 10,
  308. // currentPage: 1,
  309. // total: 0
  310. // }
  311. // this.$nextTick(()=>{
  312. // this.$refs.reportformsList.onLoad(page,{
  313. // businessType:'HYCK',
  314. // classifyCode:'业务',
  315. // groupCode:'销售报告'
  316. // })
  317. // })
  318. },
  319. // 获取报表数据
  320. reportRadio(val){
  321. console.log(val,240)
  322. reportsGetReportData({
  323. billId:this.reportsData.billId,
  324. reportCode:val.classifyCode,
  325. groupCode:val.groupCode,
  326. type:val.businessType
  327. }).then(res=>{
  328. // 关闭弹窗
  329. this.selectPrintingDialog = false
  330. this.handleReportPreview(val.url,res.data.data.data)
  331. })
  332. },
  333. // 关闭弹窗
  334. handleClose(done) {
  335. this.$confirm('确认关闭?')
  336. .then(_ => {
  337. done();
  338. })
  339. .catch(_ => {});
  340. },
  341. // 预览报表
  342. handleReportPreview(url,data){
  343. this.reportlist = data // 存一下数据 打印的时候需要传
  344. Stimulsoft.Base.StiLicense.key = '6vJhGtLLLz2GNviWmUTrhSqnOItdDwjBylQzQcAOiHn0s4gy0Fr5YoUZ9V00Y0igCSFQzwEqYBh/N77k4f0fWXTHW5rqeBNLkaurJDenJ9o97TyqHs9HfvINK18Uwzsc/bG01Rq+x3H3Rf+g7AY92gvWmp7VA2Uxa30Q97f61siWz2dE5kdBVcCnSFzC6awE74JzDcJMj8OuxplqB1CYcpoPcOjKy1PiATlC3UsBaLEXsok1xxtRMQ283r282tkh8XQitsxtTczAJBxijuJNfziYhci2jResWXK51ygOOEbVAxmpflujkJ8oEVHkOA/CjX6bGx05pNZ6oSIu9H8deF94MyqIwcdeirCe60GbIQByQtLimfxbIZnO35X3fs/94av0ODfELqrQEpLrpU6FNeHttvlMc5UVrT4K+8lPbqR8Hq0PFWmFrbVIYSi7tAVFMMe2D1C59NWyLu3AkrD3No7YhLVh7LV0Tttr/8FrcZ8xirBPcMZCIGrRIesrHxOsZH2V8t/t0GXCnLLAWX+TNvdNXkB8cF2y9ZXf1enI064yE5dwMs2fQ0yOUG/xornE'
  345. // Stimulsoft.Base.StiLicense.Key = '6vJhGtLLLz2GNviWmUTrhSqnOItdDwjBylQzQcAOiHkcgIvwL0jnpsDqRpWg5FI5kt2G7A0tYIcUygBh1sPs7plofUOqPB1a4HBIXJB621mau2oiAIj+ysU7gKUXfjn/D5BocmduNB+ZMiDGPxFrAp3PoD0nYNkkWh8r7gBZ1v/JZSXGE3bQDrCQCNSy6mgby+iFAMV8/PuZ1z77U+Xz3fkpbm6MYQXYp3cQooLGLUti7k1TFWrnawT0iEEDJ2iRcU9wLqn2g9UiWesEZtKwI/UmEI2T7nv5NbgV+CHguu6QU4WWzFpIgW+3LUnKCT/vCDY+ymzgycw9A9+HFSzARiPzgOaAuQYrFDpzhXV+ZeX31AxWlnzjDWqpfluygSNPtGul5gyNt2CEoJD1Yom0VN9fvRonYsMsimkFFx2AwyVpPcs+JfVBtpPbTcZscnzUdmiIvxv8Gcin6sNSibM6in/uUKFt3bVgW/XeMYa7MLGF53kvBSwi78poUDigA2n12SmghLR0AHxyEDIgZGOTbNI33GWu7ZsPBeUdGu55R8w='
  346. Stimulsoft.Base.Localization.StiLocalization.addLocalizationFile( '/reports/stimulsoft/Localization/zh-CHS.xml', true, 'zh-CHS')
  347. Stimulsoft.Base.Localization.StiLocalization.setLocalizationFile('/reports/stimulsoft/Localization/zh-CHS.xml' )
  348. // 工具栏
  349. var options = new Stimulsoft.Viewer.StiViewerOptions()
  350. options.height = '100%'
  351. options.appearance.scrollbarsMode = true
  352. options.toolbar.showDesignButton = false
  353. options.toolbar.showAboutButton = false
  354. options.toolbar.showResourcesButton = false
  355. options.toolbar.showFullScreenButton = false
  356. options.toolbar.showOpenButton = false
  357. options.appearance.showTooltips = false
  358. options.appearance.showDialogsHelp = false
  359. options.exports.showExportToDocument = false
  360. options.toolbar.showParametersButton = true
  361. options.appearance.bookmarksPrint = true
  362. options.toolbar.printDestination = Stimulsoft.Viewer.StiPrintDestination.Direct
  363. options.appearance.htmlRenderMode = Stimulsoft.Report.Export.StiHtmlExportMode.Table
  364. let viewer = new Stimulsoft.Viewer.StiViewer(options, 'StiViewer', false)
  365. // 报表
  366. console.log("创建一个报表实例");
  367. let report = new window.Stimulsoft.Report.StiReport();
  368. // 加载文件
  369. console.log("从url加载报表");
  370. // report.loadFile("/reports/stimulsoft/demos/SimpleList.mrt");
  371. // report.load(row.url)
  372. report.load(url)
  373. // 加载数据
  374. var dataSet = new Stimulsoft.System.Data.DataSet(
  375. 'reportData'
  376. )
  377. dataSet.readJson(data)
  378. report.regData('reportData', 'reportData', dataSet)
  379. // 从模版和数据加载报表
  380. // loadReport(report, '', {})
  381. viewer.report = report;
  382. this.$refs.reportContainer.showContainer(
  383. ()=> {
  384. setTimeout(() => {
  385. viewer.renderHtml('reportContainer')
  386. this.createViewerButtons(viewer)
  387. }, 50)
  388. },
  389. ()=>{
  390. },
  391. )
  392. console.log(report,301)
  393. // var printButton = report.renderedPages[0].components.find(function(c) {
  394. // return c.name === 'printButton';
  395. // });
  396. // // 为按钮控件添加“PrintReport”事件
  397. // printButton.events.add('PrintReport', handlePrintReport);
  398. console.log("加载成功完成!");
  399. },
  400. // 报表的按钮
  401. createViewerButtons (viewer){
  402. viewer.jsObject.collections.images['myClose.png'] =
  403. 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABmJLR0QA/wD/AP+gvaeTAAAA0ElEQVQ4ja3TO05CQRQG4A8iOwAbtYWETndAaecK7NwCKmETtJZsSBNLobEz8ZFIJQ0UnOGSm3DnYviTybzO/895DQXGWGCVGQuMEqkRcwcfuMOLalziCaf4TIe9UG9nyMJmFRzNGoRK1BU4xxx9G7cfwostciGk+x8MqgySwDXe4tU53hVV+MNtTmAoX84JGv9NYgrHyR6DV8wUSW7hItZLm36ZVoVQxsFJLOMsPOrH/h7dQwR2cdxOTEn8DtUbPGc4V2H7Vb4Yqfedf/GYSGt8VUmxgyfuBAAAAABJRU5ErkJggg=='
  404. const closeBtn = viewer.jsObject.SmallButton(
  405. 'closeBtn',
  406. '关闭',
  407. 'myClose.png'
  408. )
  409. const toolbarTable = viewer.jsObject.controls.toolbar.firstChild.firstChild
  410. const buttonsTable = toolbarTable.rows[0].lastChild.lastChild
  411. const userButtonCell = buttonsTable.rows[0].insertCell(0)
  412. userButtonCell.className = 'stiJsViewerClearAllStyles'
  413. userButtonCell.appendChild(closeBtn)
  414. let that = this
  415. closeBtn.action = function() {
  416. console.log(that.$refs.ReportContainer)
  417. if (that.$refs.reportContainer)
  418. that.$refs.reportContainer.hideContainer()
  419. }
  420. },
  421. batchCheck() {
  422. for (let i = 0; i < this.selectionList.length; i++) {
  423. if (this.selectionList[i].auditStatus != "S") {
  424. return this.$message.error("审核状态必须都为待审核状态!");
  425. } else {
  426. this.idList.push(this.selectionList[i].id);
  427. }
  428. }
  429. //打开cheack
  430. this.checkDialog = true;
  431. },
  432. operationType() {
  433. // this.checkDialog = false;
  434. this.$refs.reportContainer.visible = false
  435. this.refreshChange();
  436. this.idList = [];
  437. },
  438. operationTypeFFSQ() {
  439. this.checkDialog = false;
  440. this.refreshChange();
  441. this.idList = [];
  442. },
  443. // 业务编号跳转详情
  444. billNoDetails(row){
  445. this.$router.push({
  446. path: '/iosBasicData/SeafreightExportF/bills/index',
  447. query: {
  448. id:row.billId
  449. }
  450. });
  451. },
  452. //跳转页面
  453. jumpPage(row) {
  454. console.log('row',row);
  455. console.log(eval("(" + row.pageStatus + ")"))
  456. if (row.url) {
  457. if (eval("(" + row.pageStatus + ")")) {
  458. this.$alert(
  459. "" +
  460. row.pageLabel +
  461. "页面已存在,请关闭" +
  462. row.pageLabel +
  463. "页面再进行操作",
  464. "温馨提示",
  465. {
  466. confirmButtonText: "确定",
  467. type: "warning",
  468. callback: action => { }
  469. }
  470. );
  471. } else {
  472. this.$router.$avueRouter.closeTag(row.url);
  473. this.$router.push({
  474. path: row.url,
  475. query: {
  476. billId:row.billId
  477. }
  478. });
  479. }
  480. }else {
  481. this.$message.warning('当前数据无法跳转')
  482. }
  483. },
  484. //审批通过
  485. pass(row, operate) {
  486. row.operate = operate;
  487. this.loading = true;
  488. approvePass(row)
  489. .then(res => {
  490. this.$message.success("操作成功!");
  491. this.refreshChange();
  492. })
  493. .finally(() => {
  494. this.loading = false;
  495. });
  496. },
  497. openCheck(row) {
  498. if (row.checkType == 'CK') {
  499. financingExcess({ id: row.corpId }).then(res => {
  500. if (res.data.data == '操作成功') {
  501. this.batch = false; //单条操作
  502. this.checkDialog = true;
  503. this.checkData = row;
  504. } else {
  505. this.$confirm(res.data.data, {
  506. confirmButtonText: "确定",
  507. cancelButtonText: "取消",
  508. type: "warning"
  509. }).then(() => {
  510. this.batch = false; //单条操作
  511. this.checkDialog = true;
  512. this.checkData = row;
  513. })
  514. }
  515. })
  516. } else {
  517. this.batch = false; //单条操作
  518. this.checkDialog = true;
  519. this.checkData = row;
  520. }
  521. },
  522. choceCheckFun() {
  523. // this.checkDialog = false;
  524. this.$refs.reportContainer.visible = false
  525. this.refreshChange();
  526. },
  527. choceCheckFFSQ() {
  528. this.checkDialog = false;
  529. this.refreshChange();
  530. },
  531. openCheckSchedule(row) {
  532. this.checkId = row.srcBillId;
  533. this.batchNo = row.batchNo;
  534. this.checkScheduleDialog = true;
  535. },
  536. //关闭审批流程页面
  537. choceScheduleFun() {
  538. this.checkScheduleDialog = false;
  539. },
  540. //新单打开
  541. addReceipt(row) { },
  542. //编辑打开
  543. editOpen(row, status) {
  544. this.detailData = {
  545. id: row.id,
  546. status: status
  547. };
  548. this.show = false;
  549. },
  550. //点击搜索按钮触发
  551. searchChange(params, done) {
  552. this.query = params;
  553. this.page.currentPage = 1;
  554. this.onLoad(this.page, params);
  555. done();
  556. },
  557. searchReset() {
  558. console.log("1");
  559. },
  560. selectionChange(list) {
  561. this.idList = []
  562. this.selectionList = list;
  563. },
  564. currentChange(val) {
  565. this.page.currentPage = val;
  566. },
  567. sizeChange() {
  568. console.log("1");
  569. },
  570. refreshChange(params) {
  571. this.onLoad(this.page, params);
  572. },
  573. paramsAdjustment(params) {
  574. params = Object.assign({}, this.search);
  575. if (!params.auditStatus && params.auditStatus !== "") {
  576. params.auditStatus = "S";
  577. }
  578. return params;
  579. },
  580. onLoad(page, params) {
  581. this.loading = true;
  582. params = this.paramsAdjustment(params);
  583. if (params.sendTime) {
  584. params.applybegintime = params.sendTime[0]
  585. params.applyendtime = params.sendTime[1]
  586. delete params.sendTime
  587. }
  588. getList(page.currentPage, page.pageSize, params).then(res => {
  589. this.dataList = res.data.data.records;
  590. this.page.total = res.data.data.total;
  591. }).finally(() => {
  592. this.loading = false;
  593. });
  594. },
  595. cellStyle() {
  596. return "padding:0;height:40px;";
  597. }
  598. }
  599. };
  600. </script>
  601. <style scoped>
  602. </style>