audit-problem-rect-item.vue 26 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888
  1. <template>
  2. <div :class="$style.personalStatistics">
  3. <a-card :class="$style.conditions">
  4. <a-form-model
  5. ref="problemSearchForm"
  6. class="ant-advanced-search-form"
  7. :model="problemForm"
  8. :rules="problemRules"
  9. v-bind="formItemLayout"
  10. >
  11. <div>
  12. <a-card>
  13. <a-row :gutter="24" :class="$style.antformitem">
  14. <a-col :span="8">
  15. <span>查询维度: </span>
  16. <a-radio-group
  17. v-model="radioValue"
  18. :class="$style.radioGroup"
  19. @change="radioOnChange"
  20. >
  21. <a-radio :value="'01'"> 审计情况 </a-radio>
  22. <a-radio :value="'02'"> 被审计情况 </a-radio>
  23. </a-radio-group>
  24. </a-col>
  25. </a-row>
  26. </a-card>
  27. </div>
  28. <a-row :gutter="24" :class="$style.antformitem">
  29. <a-col :span="8">
  30. <a-form-model-item label="年度" prop="timeRange">
  31. <AuditRangePicker :time-range.sync="problemForm.timeRange" />
  32. </a-form-model-item>
  33. </a-col>
  34. <a-col :span="8">
  35. <a-form-model-item label="审计机构" prop="unitNames">
  36. <AuditGroupPicker
  37. ref="unitNames"
  38. v-model="problemForm.unitNames"
  39. :single="false"
  40. :read-only="false"
  41. :root-node="rootNode"
  42. />
  43. </a-form-model-item>
  44. </a-col>
  45. <a-col :span="8">
  46. <a-form-model-item label="被审计单位" prop="auditUnitedName">
  47. <sd-group-picker
  48. ref="auditUnitedName"
  49. v-model="problemForm.auditUnitedName"
  50. :single="false"
  51. :read-only="false"
  52. :root-node="rootNode"
  53. @change="changeunit"
  54. />
  55. </a-form-model-item>
  56. </a-col>
  57. </a-row>
  58. <a-row :gutter="24" :class="$style.antformitem">
  59. <a-col :span="8">
  60. <a-form-model-item label="项目分类" prop="auditType">
  61. <sd-select
  62. v-model="problemForm.auditType"
  63. :allow-clear="true"
  64. :options="auditTypeOptions"
  65. mode="multiple"
  66. />
  67. </a-form-model-item>
  68. </a-col>
  69. <!-- <a-col :span="8">
  70. <a-form-model-item label="被审计单位" prop="auditUnitedName">
  71. <AuditGroupPicker
  72. ref="auditUnitedName"
  73. v-model="problemForm.auditUnitedName"
  74. :single="false"
  75. :read-only="false"
  76. :root-node="rootNode"
  77. />
  78. </a-form-model-item>
  79. </a-col> -->
  80. <a-col :span="8">
  81. <a-form-model-item label="问题名称" prop="findTitle">
  82. <a-input v-model="problemForm.findTitle" />
  83. </a-form-model-item>
  84. </a-col>
  85. <a-col :span="8">
  86. <div :class="$style.buttonContent">
  87. <a-button @click="handleReset">重置</a-button>
  88. <a-button type="primary" @click="problemHandleAction('serach')">查询</a-button>
  89. <a-button
  90. :loading="exportLoading"
  91. type="primary"
  92. @click="problemHandleAction('export')"
  93. >导出</a-button
  94. >
  95. </div>
  96. </a-col>
  97. </a-row>
  98. </a-form-model>
  99. </a-card>
  100. <p :class="$style.tableTitle"> 审计问题整改明细台账 </p>
  101. <a-card class="reporttablecardxm">
  102. <sd-data-table
  103. ref="dataTable"
  104. :key="dataKey"
  105. :columns="columns"
  106. :process-req="processReq"
  107. :defultpagination-pagesize="10"
  108. data-url="api/xcoa-mobile/v1/spicAuditReportList/problemRectItemList"
  109. @dataLoaded="dataLoaded"
  110. >
  111. <div slot="projectLink" slot-scope="text, record">
  112. <a :title="text" @click="linkProject(record)">{{ text }}</a>
  113. </div>
  114. </sd-data-table>
  115. </a-card>
  116. </div>
  117. </template>
  118. <script>
  119. import moment from 'moment'
  120. import crossWindowWatcher from '@/common/services/cross-window-watcher'
  121. import components from './_import-components/audit-problem-rect-item-import'
  122. import AuditRangePicker from '@product/iam/components/picker/audit-range-picker.vue'
  123. import AuditGroupPicker from '@product/iam/components/picker/audit-group-picker.vue'
  124. import auditAdvancedQueryMixins from '../../components/audit-advanced-query-mixins'
  125. import auditAdvancedGroupMixins from '../../components/audit-advanced-group-mixins'
  126. import { message } from '@/common/one-ui'
  127. import download from '@/common/services/download'
  128. import axios from '@/common/services/axios-instance'
  129. import { getUserInfo } from '@/common/store-mixin'
  130. export default {
  131. name: 'AuditProblemRectItem',
  132. metaInfo: {
  133. title: '审计问题整改明细台账',
  134. },
  135. components: {
  136. ...components,
  137. AuditRangePicker,
  138. AuditGroupPicker,
  139. },
  140. mixins: [auditAdvancedQueryMixins, auditAdvancedGroupMixins],
  141. data() {
  142. return {
  143. radioValue: '01',
  144. radioType: true,
  145. auditTypeOptions: [],
  146. exportLoading: false,
  147. dataKey: 0,
  148. data: [],
  149. columns: [
  150. {
  151. title: '序号',
  152. dataIndex: 'id',
  153. width: '100px',
  154. },
  155. {
  156. title: '项目单位',
  157. dataIndex: 'unitName',
  158. width: '300px',
  159. },
  160. {
  161. title: '被审单位',
  162. dataIndex: 'auditedUnitNames',
  163. width: '280px',
  164. },
  165. {
  166. title: '项目名称',
  167. dataIndex: 'projectTitle',
  168. width: '200px',
  169. scopedSlots: { customRender: 'projectLink' },
  170. },
  171. {
  172. title: '项目分类',
  173. dataIndex: 'auditType',
  174. width: '250px',
  175. },
  176. {
  177. title: '问题名称',
  178. dataIndex: 'findTitle',
  179. width: '250px',
  180. },
  181. {
  182. title: '单移送',
  183. dataIndex: 'transferClueSingle',
  184. width: '200px',
  185. },
  186. {
  187. title: '双移送',
  188. dataIndex: 'transferClueDouble',
  189. width: '200px',
  190. },
  191. {
  192. title: '零容忍',
  193. dataIndex: 'zeroTolerate',
  194. width: '200px',
  195. },
  196. {
  197. title: '属于审计意见书',
  198. dataIndex: 'giveOpinion',
  199. width: '200px',
  200. },
  201. {
  202. title: '问题分类',
  203. dataIndex: 'problemType',
  204. width: '300px',
  205. },
  206. {
  207. title: '问题类型',
  208. dataIndex: 'rectType',
  209. width: '200px',
  210. },
  211. {
  212. title: '问题整改状态',
  213. dataIndex: 'rectState',
  214. width: '200px',
  215. },
  216. {
  217. title: '销号状态',
  218. dataIndex: 'cancellStatus',
  219. width: '150px',
  220. },
  221. {
  222. title: '是否完成当年整改阶段目标',
  223. dataIndex: 'whetherFinsh',
  224. width: '300px',
  225. },
  226. {
  227. title: '措施执行情况',
  228. dataIndex: 'draftRectMeasure',
  229. width: '200px',
  230. },
  231. {
  232. title: '计划完成时间',
  233. dataIndex: 'draftFinishDate',
  234. width: '200px',
  235. },
  236. {
  237. title: '审计发现问题整改(金额类)(万元)',
  238. children: [
  239. {
  240. title: '调整会计账目',
  241. dataIndex: 'adjustAccounts',
  242. width: '200px',
  243. },
  244. {
  245. title: '收回资金:增加收入数额',
  246. dataIndex: 'recoveryFunds',
  247. width: '250px',
  248. },
  249. {
  250. title: '收回资金:督促清理往来款项收回资金',
  251. dataIndex: 'avoidingWasteAmount',
  252. width: '350px',
  253. },
  254. {
  255. title: '收回资金:其他',
  256. dataIndex: 'reduceInvestmentAmount',
  257. width: '220px',
  258. },
  259. {
  260. title: '挽回损失:节约成本费用(开支)数额',
  261. dataIndex: 'costSavingAmount',
  262. width: '350px',
  263. },
  264. {
  265. title: '挽回损失:工程审减金额',
  266. dataIndex: 'engineeringReduction',
  267. width: '220px',
  268. },
  269. {
  270. title: '挽回损失:清退不当得利',
  271. dataIndex: 'improperClearanceAmount',
  272. width: '220px',
  273. },
  274. {
  275. title: '挽回损失:其他',
  276. dataIndex: 'recoveryLossAmount',
  277. width: '220px',
  278. },
  279. {
  280. title: '归还原资金渠道',
  281. dataIndex: 'repaymentChannels',
  282. width: '220px',
  283. },
  284. {
  285. title: '补缴税费',
  286. dataIndex: 'paymentTaxesFees',
  287. width: '220px',
  288. },
  289. {
  290. title: '其他',
  291. dataIndex: 'otherAmount',
  292. width: '220px',
  293. },
  294. ],
  295. },
  296. {
  297. title: '审计发现问题整改(非金额类)(个)',
  298. children: [
  299. {
  300. title: '新建制度、流程、标准(项)',
  301. dataIndex: 'newItems',
  302. width: '300px',
  303. },
  304. {
  305. title: '修订制度、流程、标准(项)',
  306. dataIndex: 'reviseItems',
  307. width: '300px',
  308. },
  309. ],
  310. },
  311. {
  312. title: '追责问责处理情况',
  313. children: [
  314. {
  315. title: '移送纪检监察部门案件线索(件)',
  316. dataIndex: 'transferMonitorClue',
  317. width: '300px',
  318. },
  319. {
  320. title: '追责问责人次',
  321. dataIndex: 'personNum',
  322. width: '220px',
  323. },
  324. {
  325. title: '党纪处分:警告',
  326. dataIndex: 'dealWay01',
  327. width: '220px',
  328. },
  329. {
  330. title: '党纪处分:严重警告',
  331. dataIndex: 'dealWay02',
  332. width: '220px',
  333. },
  334. {
  335. title: '党纪处分:撤销党内职务',
  336. dataIndex: 'dealWay03',
  337. width: '220px',
  338. },
  339. {
  340. title: '党纪处分:留党察看',
  341. dataIndex: 'dealWay04',
  342. width: '220px',
  343. },
  344. {
  345. title: '党纪处分:开除党籍',
  346. dataIndex: 'dealWay05',
  347. width: '220px',
  348. },
  349. {
  350. title: '政务处分:警告',
  351. dataIndex: 'dealWay06',
  352. width: '220px',
  353. },
  354. {
  355. title: '政务处分:记过',
  356. dataIndex: 'dealWay07',
  357. width: '220px',
  358. },
  359. {
  360. title: '政务处分:记大过',
  361. dataIndex: 'dealWay08',
  362. width: '220px',
  363. },
  364. {
  365. title: '政务处分:降级',
  366. dataIndex: 'dealWay09',
  367. width: '220px',
  368. },
  369. {
  370. title: '政务处分:撤职',
  371. dataIndex: 'dealWay10',
  372. width: '220px',
  373. },
  374. {
  375. title: '政务处分:开除',
  376. dataIndex: 'dealWay11',
  377. width: '220px',
  378. },
  379. {
  380. title: '内部纪律处分',
  381. dataIndex: 'dealWay12',
  382. width: '220px',
  383. },
  384. {
  385. title: '经济处罚金额(万元)',
  386. dataIndex: 'amountSum',
  387. width: '220px',
  388. },
  389. ],
  390. },
  391. {
  392. title: '根据审计建议给予党纪、政务和内部纪律处分',
  393. children: [
  394. {
  395. title: '合计',
  396. dataIndex: 'mentNum',
  397. width: '220px',
  398. },
  399. {
  400. title: '党纪处分:警告',
  401. dataIndex: 'dealManner01',
  402. width: '220px',
  403. },
  404. {
  405. title: '党纪处分:严重警告',
  406. dataIndex: 'dealManner02',
  407. width: '220px',
  408. },
  409. {
  410. title: '党纪处分:撤销党内职务',
  411. dataIndex: 'dealManner03',
  412. width: '220px',
  413. },
  414. {
  415. title: '党纪处分:留党察看',
  416. dataIndex: 'dealManner04',
  417. width: '220px',
  418. },
  419. {
  420. title: '党纪处分:开除党籍',
  421. dataIndex: 'dealManner05',
  422. width: '220px',
  423. },
  424. {
  425. title: '政务处分:警告',
  426. dataIndex: 'dealManner06',
  427. width: '220px',
  428. },
  429. {
  430. title: '政务处分:记过',
  431. dataIndex: 'dealManner07',
  432. width: '220px',
  433. },
  434. {
  435. title: '政务处分:记大过',
  436. dataIndex: 'dealManner08',
  437. width: '220px',
  438. },
  439. {
  440. title: '政务处分:降级',
  441. dataIndex: 'dealManner09',
  442. width: '220px',
  443. },
  444. {
  445. title: '政务处分:撤职',
  446. dataIndex: 'dealManner10',
  447. width: '220px',
  448. },
  449. {
  450. title: '政务处分:开除',
  451. dataIndex: 'dealManner11',
  452. width: '220px',
  453. },
  454. {
  455. title: '内部纪律处分',
  456. dataIndex: 'dealManner12',
  457. width: '220px',
  458. },
  459. ],
  460. },
  461. {
  462. title: '向司法机关移送或报告案件线索',
  463. dataIndex: 'accountability',
  464. width: '300px',
  465. },
  466. {
  467. title: '其中:涉案人员',
  468. dataIndex: 'otherItems',
  469. width: '300px',
  470. },
  471. ],
  472. problemForm: {
  473. unitNames: [],
  474. timeRange: [],
  475. auditType: [],
  476. auditUnitedName: [],
  477. findTitle: '',
  478. },
  479. problemRules: {
  480. timeRange: [{ required: true, message: '请选择统计时间', trigger: 'change' }],
  481. unitNames: [{ required: true, message: '请选择审计机构', trigger: 'change' }],
  482. auditUnitedName: [{ required: false, message: '请选择被审计单位', trigger: 'change' }],
  483. },
  484. formItemLayout: {
  485. labelCol: { span: 6 },
  486. wrapperCol: { span: 14 },
  487. },
  488. rootNode: {},
  489. reqData: {
  490. dateStart: '',
  491. dateEnd: '',
  492. unitNames: '',
  493. auditType: '',
  494. auditUnitedName: '',
  495. findTitle: '',
  496. },
  497. auditUnitedName: [],
  498. }
  499. },
  500. created() {
  501. let userInfo = getUserInfo()
  502. const params = {
  503. orgId: userInfo.deptId,
  504. }
  505. axios({
  506. url: 'api/xcoa-mobile/v1/iamorg/getCurrentUserGroup',
  507. method: 'get',
  508. }).then((res) => {
  509. userInfo = res.data
  510. params.orgId = res.data.id
  511. axios({
  512. url: 'api/xcoa-mobile/v1/iamorg/findIamOrg',
  513. method: 'post',
  514. params,
  515. }).then((res) => {
  516. this.id = res.data.id
  517. const deptCode = res.data.orgId + ''
  518. const deptName = res.data.orgName
  519. this.rootNode = { code: deptCode, name: deptName, id: this.id }
  520. })
  521. })
  522. },
  523. mounted() {
  524. this.tableResize()
  525. // 初始化审计类型数据字典信息
  526. this.initDictionaryInfo()
  527. this.initDatePicker()
  528. this.initGroupPicker()
  529. // this.problemHandleAction('serach')
  530. },
  531. methods: {
  532. hsaReadAuthorityPermission(record) {
  533. if (
  534. record.readAuthorityCodes != null &&
  535. record.readAuthorityCodes.indexOf(getUserInfo().account) > -1
  536. ) {
  537. return true
  538. }
  539. return false
  540. },
  541. linkProject(record) {
  542. if (
  543. (record.operatePermission || this.hsaReadAuthorityPermission(record)) &&
  544. (record.itemStatus === '02' ||
  545. record.itemStatus === '03' ||
  546. record.itemStatus === '04' ||
  547. record.itemStatus === '05' ||
  548. record.itemStatus === '07')
  549. ) {
  550. window.open('#/audit-work/?projectId=' + record.projectId)
  551. } else {
  552. var url = '/audit-project-detail?record=' + record.projectId
  553. crossWindowWatcher.waitForChanged(url).then((refreshFlag) => {
  554. if (refreshFlag) {
  555. }
  556. })
  557. }
  558. },
  559. initDatePicker() {
  560. const datePick = []
  561. const time = moment(new Date())
  562. datePick.push(time)
  563. datePick.push(time)
  564. this.problemForm.timeRange = datePick
  565. },
  566. initGroupPicker() {
  567. let userInfo = getUserInfo()
  568. const params = {
  569. orgId: userInfo.deptId,
  570. }
  571. axios({
  572. url: 'api/xcoa-mobile/v1/iamorg/getCurrentUserGroup',
  573. method: 'get',
  574. }).then((res) => {
  575. userInfo = res.data
  576. params.orgId = res.data.id
  577. axios({
  578. url: 'api/xcoa-mobile/v1/iamorg/findIamOrg',
  579. method: 'post',
  580. params,
  581. }).then((res) => {
  582. const userDeptValue = []
  583. const userDept = {
  584. code: res.data.orgId + '',
  585. name: res.data.orgName,
  586. text: res.data.orgName,
  587. id: res.data.orgId,
  588. type: 'Group',
  589. }
  590. userDeptValue.push(userDept)
  591. this.problemForm.unitNames = userDeptValue
  592. this.$refs.problemSearchForm.validate()
  593. this.problemHandleAction('serach')
  594. })
  595. })
  596. },
  597. initUnitedGroupPicker() {
  598. let userInfo = getUserInfo()
  599. const params = {
  600. orgId: userInfo.deptId,
  601. }
  602. axios({
  603. url: 'api/xcoa-mobile/v1/iamorg/getCurrentUserGroup',
  604. method: 'get',
  605. }).then((res) => {
  606. userInfo = res.data
  607. params.orgId = res.data.id
  608. axios({
  609. url: 'api/xcoa-mobile/v1/iamorg/findIamOrg',
  610. method: 'post',
  611. params,
  612. }).then((res) => {
  613. const userDeptValue = []
  614. const userDept = {
  615. code: res.data.orgId + '',
  616. name: res.data.orgName,
  617. text: res.data.orgName,
  618. id: res.data.orgId,
  619. type: 'Group',
  620. }
  621. userDeptValue.push(userDept)
  622. this.problemForm.auditUnitedName = userDeptValue
  623. this.$refs.problemSearchForm.validate()
  624. this.problemHandleAction('serach')
  625. })
  626. })
  627. },
  628. changeunit(values) {
  629. debugger
  630. this.problemForm.auditUnitedName = []
  631. values.forEach((element) => {
  632. const auditedUnit = {
  633. code: element.code + '',
  634. name: element.name,
  635. id: element.code,
  636. type: element.type,
  637. }
  638. this.problemForm.auditUnitedName.push(auditedUnit)
  639. })
  640. },
  641. initDictionaryInfo() {
  642. axios({
  643. url: 'api/xcoa-mobile/v1/iam-law/dictionary?key=PRODUCT_IAM_AUDIT_TYPE',
  644. method: 'get',
  645. }).then((res) => {
  646. if (res.status === 200) {
  647. this.auditTypeOptions = res.data
  648. }
  649. })
  650. },
  651. radioOnChange(e, info) {
  652. debugger
  653. if (this.radioValue === '01') {
  654. this.problemRules.unitNames[0].required = true
  655. this.problemRules.auditUnitedName[0].required = false
  656. this.problemForm.auditUnitedName = []
  657. this.initGroupPicker()
  658. } else {
  659. this.problemRules.unitNames[0].required = false
  660. this.problemRules.auditUnitedName[0].required = true
  661. this.problemForm.unitNames = []
  662. this.initUnitedGroupPicker()
  663. }
  664. },
  665. tableResize() {
  666. document
  667. .getElementsByClassName('ant-table-empty')[0]
  668. .getElementsByClassName('ant-table-tbody')[0]
  669. .appendChild(document.getElementsByClassName('ant-table-placeholder')[0])
  670. var width = document.getElementsByClassName('ant-table-tbody')[0].offsetWidth
  671. document.getElementsByClassName('ant-table-placeholder')[0].style.width = `${width}%`
  672. },
  673. dataLoaded(res) {
  674. if (res.data.length) {
  675. res.data.forEach((item, index) => {
  676. item.id = index + 1
  677. })
  678. } else {
  679. this.tableResize()
  680. }
  681. return res
  682. },
  683. handleReset() {
  684. this.$refs.problemSearchForm.resetFields()
  685. },
  686. processReq(req) {
  687. req.data = {
  688. maxResults: req.data.maxResults,
  689. startPosition: req.data.startPosition,
  690. dateStart: this.reqData.dateStart,
  691. dateEnd: this.reqData.dateEnd,
  692. unitIds: this.reqData.unitNames,
  693. auditType: this.reqData.auditType,
  694. auditUnitedId: this.reqData.auditUnitedName,
  695. findTitle: this.reqData.findTitle,
  696. }
  697. return req
  698. },
  699. handleSearch() {
  700. this.reqData.startPosition = 0
  701. this.dataKey++
  702. },
  703. // 审计问题整改明细台账
  704. problemHandleAction(type) {
  705. debugger
  706. this.$refs.problemSearchForm.validate((valid, values) => {
  707. if (valid) {
  708. if (type === 'serach') {
  709. if (
  710. this.problemForm.timeRange.length === 0 &&
  711. this.problemForm.unitNames.length === 0 &&
  712. this.problemForm.auditType.length === 0 &&
  713. this.problemForm.auditUnitedName.length === 0 &&
  714. this.problemForm.findTitle === ''
  715. ) {
  716. this.handleSearch()
  717. } else {
  718. // 处理时间
  719. this.reqData.dateStart = this.problemForm.timeRange[0].year() + ''
  720. this.reqData.dateEnd = this.problemForm.timeRange[1].year() + ''
  721. // 处理部门
  722. const arr = []
  723. this.problemForm.unitNames.forEach((item) => {
  724. arr.push(`'${item.id}'`)
  725. })
  726. this.reqData.unitNames = arr.join(',')
  727. this.reqData.unitIds = arr.join(',')
  728. if (this.problemForm.auditUnitedName.length !== 0) {
  729. const arrs = []
  730. this.problemForm.auditUnitedName.forEach((item) => {
  731. arrs.push(`'${item.id}'`)
  732. })
  733. this.reqData.auditUnitedName = arrs.join(',')
  734. this.reqData.auditUnitedId = arrs.join(',')
  735. } else {
  736. this.reqData.auditUnitedName = ''
  737. this.reqData.auditUnitedId = ''
  738. }
  739. if (this.problemForm.auditType.length !== 0) {
  740. const auditTypes = []
  741. this.problemForm.auditType.forEach((item) => {
  742. auditTypes.push(`'${item.id}'`)
  743. })
  744. this.reqData.auditType = auditTypes.join(',')
  745. } else {
  746. this.reqData.auditType = ''
  747. }
  748. if (this.problemForm.findTitle !== '') {
  749. this.reqData.findTitle = this.problemForm.findTitle + ''
  750. } else {
  751. this.reqData.findTitle = ''
  752. }
  753. this.handleSearch()
  754. this.auditUnitedName = []
  755. }
  756. } else {
  757. debugger
  758. if (
  759. this.problemForm.timeRange.length === 0 &&
  760. this.problemForm.unitNames.length === 0 &&
  761. this.problemForm.auditType.length === 0 &&
  762. this.problemForm.auditUnitedName.length === 0 &&
  763. this.problemForm.findTitle === ''
  764. ) {
  765. this.problemHandleExport()
  766. } else {
  767. // 处理时间
  768. this.reqData.dateStart = this.problemForm.timeRange[0].year() + ''
  769. this.reqData.dateEnd = this.problemForm.timeRange[1].year() + ''
  770. // 处理部门
  771. const arr = []
  772. this.problemForm.unitNames.forEach((item) => {
  773. arr.push(`'${item.id}'`)
  774. })
  775. this.reqData.unitNames = arr.join(',')
  776. this.reqData.unitIds = arr.join(',')
  777. if (this.problemForm.auditUnitedName.length !== 0) {
  778. const arrs = []
  779. this.problemForm.auditUnitedName.forEach((item) => {
  780. arrs.push(`'${item.id}'`)
  781. })
  782. this.reqData.auditUnitedName = arrs.join(',')
  783. this.reqData.auditUnitedId = arrs.join(',')
  784. } else {
  785. this.reqData.auditUnitedName = ''
  786. this.reqData.auditUnitedId = ''
  787. }
  788. if (this.problemForm.auditType.length !== 0) {
  789. const auditTypes = []
  790. this.problemForm.auditType.forEach((item) => {
  791. auditTypes.push(`'${item.id}'`)
  792. })
  793. this.reqData.auditType = auditTypes.join(',')
  794. } else {
  795. this.reqData.auditType = ''
  796. }
  797. if (this.problemForm.findTitle !== '') {
  798. this.reqData.findTitle = this.problemForm.findTitle + ''
  799. } else {
  800. this.reqData.findTitle = ''
  801. }
  802. this.problemHandleExport()
  803. }
  804. }
  805. }
  806. })
  807. },
  808. problemHandleExport() {
  809. axios({
  810. method: 'post',
  811. url: 'api/xcoa-mobile/v1/spicAuditReportExport/exportProblemRectItem',
  812. responseType: 'blob',
  813. data: {
  814. unitIds: this.reqData.unitIds,
  815. dateStart: this.reqData.dateStart,
  816. dateEnd: this.reqData.dateEnd,
  817. auditType: this.reqData.auditType,
  818. auditUnitedId: this.reqData.auditUnitedId,
  819. findTitle: this.reqData.findTitle,
  820. },
  821. }).then((res) => {
  822. const url = URL.createObjectURL(res.data)
  823. download(url, '审计问题整改明细台账-内审.xlsx')
  824. })
  825. },
  826. },
  827. }
  828. </script>
  829. <style module lang="scss">
  830. @use '@/common/design' as *;
  831. .personalStatistics {
  832. :global(.ant-table-body) {
  833. overflow-x: scroll !important;
  834. }
  835. :global(.ant-form-item) {
  836. margin: 0;
  837. }
  838. :global(.ant-table-empty) {
  839. :global(.ant-table-body) {
  840. overflow-x: scroll !important;
  841. }
  842. }
  843. .conditions {
  844. margin-bottom: 20px;
  845. }
  846. .buttonContent {
  847. padding-top: 6px;
  848. text-align: right;
  849. button {
  850. margin: 0 4px;
  851. }
  852. }
  853. :global(.anticon-setting) {
  854. display: none;
  855. }
  856. .tableTitle {
  857. padding-top: 16px;
  858. margin: 0;
  859. font-size: 22px;
  860. font-weight: bold;
  861. color: #404040;
  862. text-align: center;
  863. background: white;
  864. }
  865. :global(.reporttablecardxm) {
  866. :global(.ant-table-body) {
  867. height: auto !important;
  868. min-height: auto !important;
  869. overflow: auto;
  870. }
  871. }
  872. :global(.ant-table-placeholder) {
  873. height: auto !important;
  874. }
  875. }
  876. </style>