complaint.vue 25 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001
  1. <template>
  2. <van-overlay class="backgroundSty" z-index="2002" :show="showPop" :lock-scroll="false">
  3. <div style="height:5%">
  4. <van-sticky>
  5. <van-nav-bar
  6. :title="
  7. '投诉 ' +
  8. (typeValue == '1'
  9. ? '编制'
  10. : typeValue == '3'
  11. ? '修改'
  12. : typeValue == '2'
  13. ? '详情'
  14. : '')
  15. "
  16. :right-text="typeValue == '3' ? '退回原因' : ''"
  17. @click-left="closePop()"
  18. @click-right="getBack()"
  19. >
  20. <template #left>
  21. <van-icon name="cross" class="ibps-nav-bar__close-icon" />
  22. </template>
  23. </van-nav-bar>
  24. </van-sticky>
  25. </div>
  26. <div class="scrollView">
  27. <van-form @submit="onSubmit">
  28. <van-field
  29. v-model="form.touSuRen"
  30. required
  31. label="投诉者:"
  32. placeholder="请输入投诉者"
  33. label-width="6em"
  34. clearable
  35. :readonly="typeValue == '2' ? true : false"
  36. />
  37. <van-field
  38. v-model="form.touSuDanWei"
  39. required
  40. label="投诉单位:"
  41. placeholder="请输入投诉单位"
  42. label-width="6em"
  43. clearable
  44. :type="typeValue == '2' ? 'textarea' : 'text'"
  45. :readonly="typeValue == '2' ? true : false"
  46. />
  47. <van-field
  48. v-model="form.lianXiDianHua"
  49. required
  50. label="联系电话:"
  51. placeholder="请输入联系电话"
  52. label-width="6em"
  53. clearable
  54. :rules="[
  55. {
  56. validator: $common.getRequest.checkPhone,
  57. message: '手机号格式错误'
  58. }
  59. ]"
  60. :readonly="typeValue == '2' ? true : false"
  61. />
  62. <van-field
  63. v-model="form.touSuBuMenJiRenYu"
  64. required
  65. label="投诉部门及人员:"
  66. placeholder="请输入投诉部门及人员"
  67. label-width="6em"
  68. clearable
  69. :type="typeValue == '2' ? 'textarea' : 'text'"
  70. autosize
  71. :readonly="typeValue == '2' ? true : false"
  72. />
  73. <van-field
  74. name="radio"
  75. required
  76. label="投诉分类:"
  77. placeholder="请选择投诉类型"
  78. label-width="6em"
  79. :value="form.touSuFenLei"
  80. :readonly="typeValue == '2' ? true : false"
  81. >
  82. <template #input>
  83. <van-radio-group
  84. v-if="typeValue != '2'"
  85. v-model="form.touSuFenLei"
  86. direction="horizontal"
  87. >
  88. <van-radio
  89. v-for="(it, index) in touSuFenLeiList"
  90. :key="index"
  91. :name="it.name"
  92. shape="square"
  93. class="lineSty"
  94. >
  95. {{ it.name }}
  96. </van-radio>
  97. </van-radio-group>
  98. <div v-else>{{ form.touSuFenLei }}</div>
  99. </template>
  100. </van-field>
  101. <van-field
  102. v-if="form.touSuFenLei == '其它'"
  103. v-model="form.qiTaFenLei"
  104. required
  105. label="其它分类:"
  106. placeholder="请输入其它分类"
  107. label-width="6em"
  108. clearable
  109. :readonly="typeValue == '2' ? true : false"
  110. />
  111. <van-field
  112. required
  113. label="投诉方式:"
  114. label-width="6em"
  115. :value="form.touSuFangShi"
  116. :readonly="typeValue == '2' ? true : false"
  117. >
  118. <template #input>
  119. <van-radio-group
  120. v-if="typeValue != '2'"
  121. v-model="form.touSuFangShi"
  122. direction="horizontal"
  123. >
  124. <van-radio
  125. v-for="(it, index) in touSuFangShiList"
  126. :key="index"
  127. :name="it.name"
  128. shape="square"
  129. class="lineSty"
  130. >
  131. {{ it.name }}
  132. </van-radio>
  133. </van-radio-group>
  134. <div v-else>{{ form.touSuFangShi }}</div>
  135. </template>
  136. </van-field>
  137. </van-form>
  138. <van-cell-group>
  139. <div
  140. class="verticalLine"
  141. style="width:8em;text-align:left;padding: 1em 0 1em 0.5em;margin: 0;"
  142. >
  143. 投诉内容
  144. </div>
  145. <van-field
  146. v-model="form.touSuNeiRong"
  147. autosize
  148. type="textarea"
  149. label=""
  150. placeholder="投诉内容"
  151. label-width="0"
  152. clearable
  153. :readonly="typeValue == '2' ? true : false"
  154. />
  155. </van-cell-group>
  156. <ibps-uploader
  157. v-model="form.fuJian"
  158. label="上传附件"
  159. download
  160. placeholder="请上传附件"
  161. :have-padding="false"
  162. multiple
  163. clearable
  164. :readonly="typeValue == '2' ? true : false"
  165. />
  166. <div v-if="typeValue == '2'" class="spei">
  167. <van-cell-group>
  168. <div
  169. class="verticalLine"
  170. style="width:8em;text-align:left;padding: 1em 0 1em 0.5em;margin: 0;"
  171. >
  172. 审核
  173. </div>
  174. <!-- <van-field
  175. :value="form.touSuShouLi | getValue"
  176. autosize
  177. type="textarea"
  178. label="投诉受理审核:"
  179. label-width="7em"
  180. clearable
  181. :readonly="typeValue == '2'"
  182. class="typeStyle"
  183. /> -->
  184. <van-field
  185. :value="form.touSuFenLeiQiTa | getValueP(userList)"
  186. label="投诉处理人:"
  187. label-width="6em"
  188. clearable
  189. :readonly="typeValue == '2'"
  190. class="typeStyle"
  191. />
  192. </van-cell-group>
  193. <van-cell-group>
  194. <div
  195. class="verticalLine"
  196. style="width:8em;text-align:left;padding: 1em 0 1em 0.5em;margin: 0;"
  197. >
  198. 调查
  199. </div>
  200. <van-field
  201. :value="form.shiShiDiaoChaQing | getValue"
  202. autosize
  203. type="textarea"
  204. label="事实调查情况:"
  205. label-width="7em"
  206. clearable
  207. :readonly="typeValue == '2'"
  208. class="typeStyle"
  209. />
  210. <ibps-uploader
  211. v-model="form.diaoChaQingKuangF"
  212. class="paddingNone"
  213. label="调查附件"
  214. download
  215. :have-padding="false"
  216. multiple
  217. clearable
  218. :readonly="typeValue == '2' ? true : false"
  219. />
  220. <van-field
  221. :value="form.touSuQueRen | getValue"
  222. label="是否有效投诉:"
  223. label-width="7em"
  224. clearable
  225. :readonly="typeValue == '2'"
  226. class="typeStyle"
  227. />
  228. <van-field
  229. :value="form.chuLiCuoShi | getValue"
  230. autosize
  231. class="typeStyle"
  232. type="textarea"
  233. label="处理措施:"
  234. label-width="5em"
  235. clearable
  236. :readonly="typeValue == '2'"
  237. />
  238. </van-cell-group>
  239. <van-cell-group>
  240. <div
  241. class="verticalLine"
  242. style="width:8em;text-align:left;padding: 1em 0 1em 0.5em;margin: 0;"
  243. >
  244. 确认
  245. </div>
  246. <van-field
  247. :value="form.chuLiJieGuoQueRen | getValue"
  248. autosize
  249. class="typeStyle"
  250. type="textarea"
  251. label="处理结果确认:"
  252. label-width="7em"
  253. clearable
  254. :readonly="typeValue == '2'"
  255. />
  256. </van-cell-group>
  257. <van-cell-group>
  258. <div
  259. class="verticalLine"
  260. style="width:8em;text-align:left;padding: 1em 0 1em 0.5em;margin: 0;"
  261. >
  262. 通知
  263. </div>
  264. <van-field
  265. :value="form.chuLiJieGuoShiFou | getValue"
  266. autosize
  267. type="textarea"
  268. label="处理结果是否通知当事人:"
  269. label-width="12em"
  270. clearable
  271. :readonly="typeValue == '2'"
  272. class="typeStyle"
  273. />
  274. <ibps-uploader
  275. v-model="form.touSuFangShiQiTa"
  276. class="paddingNone"
  277. label="通知附件:"
  278. download
  279. :have-padding="false"
  280. multiple
  281. clearable
  282. :readonly="typeValue == '2' ? true : false"
  283. />
  284. <van-field
  285. :value="form.touSuRenQianMing | getValue"
  286. autosize
  287. class="typeStyle"
  288. type="textarea"
  289. label="通知内容:"
  290. label-width="5em"
  291. clearable
  292. :readonly="typeValue == '2'"
  293. />
  294. </van-cell-group>
  295. </div>
  296. <div class="padding flex flex-direction">
  297. <van-button
  298. v-if="id == ''"
  299. type="success"
  300. class="btn btn-back-color"
  301. @click="onSubmit"
  302. >提交</van-button
  303. >
  304. <van-button
  305. v-if="typeValue == '3'"
  306. type="success"
  307. class="btn btn-back-color"
  308. @click="getArgee()"
  309. >
  310. 修改
  311. </van-button>
  312. </div>
  313. </div>
  314. </van-overlay>
  315. </template>
  316. <script>
  317. import random from '@/mixins/random'
  318. import bpmnStatus from '@/mixins/bpmnStatus'
  319. import IbpsUploader from '@/business/platform/file/uploader'
  320. import {
  321. getNextIdByAlias,
  322. findFormJsonByBo
  323. } from '@/api/platform/form/transfer'
  324. import { agree } from '@/api/platform/bpmn/bpmTask'
  325. import test from './complaint.json'
  326. export default {
  327. components: {
  328. IbpsUploader
  329. },
  330. filters: {
  331. getValueP(value, arr) {
  332. if (value && value !== '') {
  333. const obj = arr.find(i => i.userId == value)
  334. return obj.userName
  335. } else {
  336. return '/'
  337. }
  338. },
  339. getValue(value) {
  340. if (value && value !== '') {
  341. return value
  342. } else {
  343. return '/'
  344. }
  345. },
  346. getNotVa(value) {
  347. if (!value) {
  348. return '/'
  349. }
  350. }
  351. },
  352. mixins: [random, bpmnStatus],
  353. props: {
  354. showPop: {
  355. type: Boolean,
  356. default: false
  357. },
  358. typeValue: {
  359. type: String,
  360. default: '1'
  361. },
  362. id: {
  363. type: String,
  364. default: ''
  365. }
  366. },
  367. data() {
  368. const { useId, userList = [] } = this.$store.getters
  369. return {
  370. useId,
  371. userList,
  372. show: this.showPop,
  373. sheetShow: false,
  374. option2: '',
  375. option3: '',
  376. option4: '',
  377. content: '',
  378. buMenList: [],
  379. fuJianShangChuanArray: [],
  380. popupShow: false,
  381. type: '',
  382. form: {
  383. id: '',
  384. diDian: '',
  385. bianZhiBuMen: '',
  386. bianZhiRen: '',
  387. bianZhiShiJian: '',
  388. touSuRen: '',
  389. lianXiDianHua: '',
  390. touSuDanWei: '',
  391. touSuBuMenJiRenYu: '',
  392. touSuFenLei: '患者',
  393. touSuFangShi: '电话',
  394. touSuNeiRong: '',
  395. fuJian: '',
  396. touSuRiQi: '',
  397. touSuQueRen: '',
  398. touSuShouLi: '',
  399. touSuFenLeiQiTa: '',
  400. shiShiDiaoChaQing: '',
  401. diaoChaQingKuangF: '',
  402. chuLiCuoShi: '',
  403. chuLiJieGuoQueRen: '',
  404. chuLiJieGuoShiFou: '',
  405. touSuRenQianMing: '',
  406. touSuFangShiQiTa: '',
  407. qiTaFenLei: ''
  408. },
  409. list: [
  410. {
  411. text: '投诉'
  412. },
  413. {
  414. text: '检验项目'
  415. },
  416. {
  417. text: '危机值报告'
  418. },
  419. {
  420. text: '口头报告结果'
  421. },
  422. {
  423. text: '延迟报告'
  424. },
  425. {
  426. text: '其它'
  427. }
  428. ],
  429. touSuFangShiQiTaList: [],
  430. diaoChaQingKuangFList: [],
  431. touSuFenLeiList: test.touSuFenLeiList,
  432. touSuFangShiList: test.touSuFangShiList,
  433. timeShow: false,
  434. yangPinList: [],
  435. option: '',
  436. orgId: '',
  437. backShow: false,
  438. level: null,
  439. mainPosition: {
  440. id: ''
  441. },
  442. xuanzeTime: null
  443. }
  444. },
  445. computed: {
  446. rightText() {
  447. return this.checkMode
  448. ? this.$t('common.button.cancel')
  449. : this.$t('common.button.manage')
  450. },
  451. selectedIds() {
  452. return this.checkedIds.join(',')
  453. }
  454. },
  455. watch: {
  456. showPop: {
  457. handler: function(val, oldVal) {
  458. if (val === true) {
  459. this.form = {
  460. id: '',
  461. diDian: '',
  462. bianZhiBuMen: '',
  463. bianZhiRen: '',
  464. bianZhiShiJian: '',
  465. touSuRen: '',
  466. lianXiDianHua: '',
  467. touSuDanWei: '',
  468. touSuBuMenJiRenYu: '',
  469. touSuFenLei: '患者',
  470. touSuFangShi: '电话',
  471. touSuNeiRong: '',
  472. fuJian: '',
  473. touSuRiQi: '',
  474. touSuQueRen: '',
  475. touSuShouLi: '',
  476. touSuFenLeiQiTa: '',
  477. shiShiDiaoChaQing: '',
  478. diaoChaQingKuangF: '',
  479. chuLiCuoShi: '',
  480. chuLiJieGuoQueRen: '',
  481. chuLiJieGuoShiFou: '',
  482. touSuRenQianMing: '',
  483. touSuFangShiQiTa: '',
  484. qiTaFenLei: ''
  485. }
  486. this.level = this.$store.getters.level
  487. const info = this.$store.getters.userInfo
  488. const mid = JSON.parse(localStorage.getItem('mainPosition'))
  489. const mainPosition =
  490. mid || (info && info.mainPosition ? info.mainPosition : null)
  491. this.mainPosition = mainPosition
  492. this.form.touSuRen = info.user.name
  493. this.form.touSuDanWei = info.user.qq
  494. this.form.lianXiDianHua = info.user.mobile
  495. this.orgId = info.employee.positions
  496. if (this.id) {
  497. this.getDe(this.id)
  498. if (this.typeValue == 3) {
  499. this.getTaskId(this.id)
  500. }
  501. }
  502. }
  503. },
  504. immediate: true
  505. }
  506. },
  507. created() {},
  508. methods: {
  509. closePop() {
  510. this.$emit('updataSet', false)
  511. },
  512. toCheckMode() {
  513. if (this.$utils.isEmpty(this.listData)) {
  514. return
  515. }
  516. if (this.checkMode) {
  517. this.showA = true
  518. this.checkedIds = []
  519. }
  520. this.checkMode = !this.checkMode
  521. },
  522. actionSheetCallback(e) {
  523. this.form.gouTongLeiXing = e.text
  524. this.sheetShow = false
  525. },
  526. timeShowCallback(e) {
  527. const nowDate = new Date(e.getTime() + 8 * 60 * 60 * 1000)
  528. const time = nowDate
  529. .toJSON()
  530. .split('T')
  531. .join(' ')
  532. .substr(0, 16)
  533. this.form.gouTongRiQi = time
  534. this.timeShow = false
  535. },
  536. gouTongRiQiClick(e) {
  537. this.timeShow = true
  538. },
  539. // 获取上传状态
  540. select(file) {
  541. this.$uploades.selectUpload(file).then(res => {
  542. res.forEach(item => {
  543. this.fuJianShangChuanArray.push(item)
  544. })
  545. })
  546. },
  547. // 删除
  548. deleteMe(id) {
  549. this.fuJianShangChuanArray = this.fuJianShangChuanArray.filter(
  550. item => item.id !== id
  551. )
  552. },
  553. // 获取上传进度
  554. progress(e) {},
  555. // 上传成功
  556. success(file) {},
  557. // 上传失败
  558. fail(e) {},
  559. // 弹出框显示
  560. qianming(index) {
  561. this.popupShow = true
  562. },
  563. // 清除签名
  564. deqianming(index) {
  565. this.form.keHu = ''
  566. },
  567. // 保存签名
  568. save(val) {
  569. this.form.keHu = val
  570. this.popupShow = false
  571. },
  572. // 清除签名
  573. clear(val) {
  574. this.form.keHu = ''
  575. },
  576. /**
  577. * 关闭签名弹窗
  578. */
  579. close() {
  580. this.popupShow = false
  581. },
  582. // 获取样品编号
  583. getGtbh(callback) {
  584. const smsParams = {
  585. alias: 'gtbh'
  586. }
  587. const this_ = this
  588. getNextIdByAlias(smsParams).then(res => {
  589. if (res.state === 200) {
  590. const data = res.data
  591. this_.form.biaoDanBianHao = data
  592. }
  593. })
  594. },
  595. getDe(id) {
  596. const sql = `select a.*,b.name_ from t_tsclb a left join ibps_party_employee b on a.tou_su_fen_lei_qi = b.id_ where a.id_ = '${id}'`
  597. this.$common.request('sql', sql).then(res => {
  598. if (res.state === 200) {
  599. const data = res.variables.data[0]
  600. this.form = {
  601. id: data.id_,
  602. diDian: data.di_dian_,
  603. bianZhiBuMen: data.bian_zhi_bu_men_,
  604. bianZhiRen: data.bian_zhi_ren_,
  605. bianZhiShiJian: data.bian_zhi_shi_jian,
  606. touSuRen: data.tou_su_ren_,
  607. lianXiDianHua: data.lian_xi_dian_hua_,
  608. touSuDanWei: data.tou_su_dan_wei_,
  609. touSuBuMenJiRenYu: data.tou_su_bu_men_ji_,
  610. touSuFenLei: data.tou_su_fen_lei_,
  611. touSuFangShi: data.tou_su_fang_shi_,
  612. touSuNeiRong: data.tou_su_nei_rong_,
  613. fuJian: data.fu_jian_,
  614. touSuRiQi: data.tou_su_ri_qi_,
  615. touSuQueRen: data.tou_su_que_ren_,
  616. touSuShouLi: data.tou_su_shou_li_sh,
  617. touSuFenLeiQiTa: data.tou_su_fen_lei_qi,
  618. shiShiDiaoChaQing: data.shi_shi_diao_cha_,
  619. diaoChaQingKuangF: data.diao_cha_qing_kua,
  620. chuLiCuoShi: data.chu_li_cuo_shi_,
  621. chuLiJieGuoQueRen: data.chu_li_jie_guo_qu,
  622. chuLiJieGuoShiFou: data.chu_li_jie_guo_sh,
  623. touSuRenQianMing: data.tou_su_ren_qian_m,
  624. touSuFangShiQiTa: data.tou_su_fang_shi_q,
  625. qiTaFenLei: data.qi_ta_fen_lei_
  626. }
  627. }
  628. })
  629. },
  630. onSubmit() {
  631. if (!this.getYanZheng()) {
  632. return
  633. }
  634. const tmpArray = []
  635. this.fuJianShangChuanArray.forEach(item => {
  636. tmpArray.push(item.id)
  637. })
  638. const info = this.$store.getters.userInfo
  639. const useId = info.user.id
  640. const para = {
  641. parameters: [
  642. {
  643. key: 'defId',
  644. value: '1133803612284125184'
  645. },
  646. {
  647. key: 'version',
  648. value: '0'
  649. },
  650. {
  651. key: 'data',
  652. value: ''
  653. }
  654. ]
  655. }
  656. // this.form.fuJian = tmpArray.join(',')
  657. this.form.bianZhiRen = useId
  658. this.form.bianZhiShiJian = this.$methCommon.time(16)
  659. this.form.shiFouGuoShen = '已登记'
  660. this.form.bianZhiBuMen = this.mainPosition===null ? this.orgId : this.mainPosition.id
  661. // this.form.bianZhiBuMen = this.orgId
  662. this.form.diDian = this.level.second
  663. para.parameters[2].value = JSON.stringify(this.form)
  664. findFormJsonByBo(para)
  665. .then(res => {
  666. if (res.state === 200) {
  667. this.$toast({
  668. duration: 2000, // 持续展示 toast
  669. message: '提交成功!'
  670. })
  671. setTimeout(() => {
  672. this.closePop()
  673. }, 1000)
  674. }
  675. })
  676. .catch(() => {
  677. // this.$methCommon.getPrompt('请求出现错误,请稍后再试', 'error')
  678. })
  679. },
  680. // 修改
  681. getArgee() {
  682. if (!this.getYanZheng()) {
  683. return
  684. }
  685. // uni.showLoading({
  686. // mask: true,
  687. // title: '加载中'
  688. // })
  689. const info = this.$store.getters.userInfo
  690. const useId = info.user.id
  691. const tmpArray = []
  692. this.fuJianShangChuanArray.forEach(item => {
  693. tmpArray.push(item.id)
  694. })
  695. this.form.fuJian = tmpArray.join(',')
  696. this.form.touSuQueRen = ''
  697. this.form.bianZhiRen = useId
  698. this.form.bianZhiShiJian = this.$methCommon.time(16)
  699. this.form.shiFouGuoShen = '已登记'
  700. this.form.bianZhiBuMen = this.mainPosition===null ? this.orgId : this.mainPosition.id
  701. this.form.diDian = this.level.second
  702. const editData = {
  703. data: JSON.stringify(this.form),
  704. opinion: '',
  705. taskId: this.taskId
  706. }
  707. agree(editData)
  708. .then(res => {
  709. if (res.state === 200) {
  710. // this.$methCommon.getPrompt('提交成功!')
  711. // uni.hideLoading()
  712. setTimeout(() => {
  713. this.closePop()
  714. }, 1000)
  715. } else {
  716. // this.$methCommon.getPrompt('提交异常', 'error')
  717. // uni.hideLoading()
  718. }
  719. })
  720. .catch(() => {
  721. // this.$methCommon.getPrompt('提交异常', 'error')
  722. // uni.hideLoading()
  723. })
  724. },
  725. getYanZheng() {
  726. const suList = [
  727. 'touSuRen',
  728. 'touSuDanWei',
  729. 'lianXiDianHua',
  730. 'touSuBuMenJiRenYu',
  731. 'touSuNeiRong'
  732. ]
  733. const suListName = [
  734. '投诉者',
  735. '投诉单位',
  736. '联系电话',
  737. '投诉部门及人员',
  738. '投诉内容'
  739. ]
  740. for (const item in suList) {
  741. if (!this.form[suList[item]]) {
  742. this.$toast({
  743. duration: 2000, // 持续展示 toast
  744. message: '请输入' + suListName[item]
  745. })
  746. return false
  747. }
  748. }
  749. if (!this.$common.getRequest.checkPhone(this.form.lianXiDianHua)) {
  750. return false
  751. }
  752. return true
  753. },
  754. // 根据委托单id查询 taskId
  755. getTaskId(id) {
  756. const sql = `select TASK_ID_,PROC_INST_ID_ from ibps_bpm_tasks where NAME_ = '登记' and NODE_ID_ = 'Activity_0276m43' and PROC_DEF_KEY_ = 'Process_09j5fge' and EXEC_ID_ = (select PROC_INST_ID_ from act_ru_execution where ACT_ID_ = 'Activity_0276m43' and BUSINESS_KEY_ = '${id}') ORDER BY CREATE_TIME_ desc`
  757. this.$common.request('sql', sql).then(res => {
  758. if (res.state === 200) {
  759. if (res.variables.data.length > 0) {
  760. const result = res.variables.data[0]
  761. if (result.TASK_ID_) {
  762. this.taskId = result.TASK_ID_
  763. this.getProcInstId(result.PROC_INST_ID_)
  764. }
  765. }
  766. }
  767. })
  768. },
  769. // 根据委托单id查询 taskId
  770. getProcInstId(id) {
  771. const sql = `select OPTION_ from ibps_bpm_oper_log where PROC_INST_ID_ = '${id}' order by create_time_ desc limit 1`
  772. this.$common.request('sql', sql).then(res => {
  773. if (res.state === 200) {
  774. const result = res.variables.data[0]
  775. this.option = result.OPTION_
  776. }
  777. })
  778. },
  779. getShow() {
  780. this.$refs['picker'].show()
  781. },
  782. getPageA() {
  783. // const pages = getCurrentPages()
  784. // const prevPage = pages[pages.length - 2]
  785. // prevPage.$vm.getValue()
  786. // uni.navigateBack({
  787. // dalta: 1
  788. // })
  789. },
  790. uploadClick(item) {
  791. if (/^(pdf|png|jpg|jpeg|gif)$/.test(item.ext)) {
  792. // uni.navigateTo({
  793. // url: `/pages/fileView/fileView?id=${item.id}&ext=${item.ext}`
  794. // })
  795. } else {
  796. this.$uploades.download(item.id, item.name, this)
  797. }
  798. },
  799. // 退回原因
  800. getBack() {
  801. this.content = this.option
  802. this.backShow = true
  803. this.$dialog
  804. .alert({
  805. title: '退回原因',
  806. message: this.option,
  807. theme: 'round-button',
  808. confirmButtonColor: '#1989fa'
  809. })
  810. .then(() => {
  811. // on close
  812. })
  813. },
  814. cancel() {
  815. this.backShow = false
  816. },
  817. formatter(type, val) {
  818. if (type === 'year') {
  819. return val + '年'
  820. }
  821. if (type === 'month') {
  822. return val + '月'
  823. }
  824. if (type === 'day') {
  825. return val + '日'
  826. }
  827. return val
  828. }
  829. }
  830. }
  831. </script>
  832. <style lang="scss" scoped>
  833. ::v-deep .van-cell__title {
  834. width: 65%;
  835. .van-cell__label {
  836. overflow-wrap: break-word;
  837. }
  838. }
  839. .sectionBox {
  840. display: flex;
  841. align-items: center;
  842. margin-bottom: 2px;
  843. font-size: 14px;
  844. color: rgba(128, 138, 135, 0.9);
  845. .left {
  846. width: 90px;
  847. }
  848. }
  849. .sectionBox::before {
  850. content: '';
  851. width: 5px;
  852. height: 14px;
  853. border-radius: 2px;
  854. margin-right: 5px;
  855. }
  856. .btn-back-color {
  857. background-color: #1989fa !important;
  858. border: none;
  859. }
  860. .btn-sty {
  861. padding: 0 13px;
  862. border-radius: 5px;
  863. }
  864. .u-m-r-15 {
  865. margin-right: 8px !important;
  866. }
  867. .verticalLine {
  868. color: #000;
  869. font-size: 13px;
  870. margin-bottom: 20px;
  871. }
  872. .verticalLine::before {
  873. content: '';
  874. width: 5px;
  875. height: 14px;
  876. background-color: #2979ff;
  877. border-radius: 2px;
  878. margin-right: 5px;
  879. }
  880. .suspensionBtn {
  881. width: 80px;
  882. height: 80px;
  883. position: fixed;
  884. top: 75%;
  885. right: 2%;
  886. img {
  887. width: 100%;
  888. height: 100%;
  889. }
  890. }
  891. .backgroundSty {
  892. height: 100%;
  893. background-color: #f8f8f8;
  894. }
  895. .cu-form-group .title {
  896. min-width: 180px;
  897. }
  898. .padding {
  899. padding-bottom: 15px;
  900. padding-top: 5px;
  901. background-color: #f8f8f8;
  902. display: flex;
  903. justify-content: center;
  904. }
  905. .btn {
  906. width: 90%;
  907. padding: 15px;
  908. border-radius: 5px;
  909. }
  910. .fileBox {
  911. line-height: 50px;
  912. color: #888888;
  913. display: flex;
  914. align-items: center;
  915. justify-content: space-between;
  916. border: 1px solid #dddddd;
  917. border-radius: 8px;
  918. padding: 5px;
  919. margin-top: 10px;
  920. }
  921. .u-update-content {
  922. font-size: 26px;
  923. // color: $u-content-color;
  924. line-height: 1.7;
  925. padding: 30px;
  926. }
  927. .verticalLine {
  928. display: flex;
  929. align-items: center;
  930. // justify-content: center;
  931. font-size: 14px;
  932. color: rgb(51, 51, 51);
  933. }
  934. .verticalLine::before {
  935. content: '';
  936. width: 5px;
  937. height: 14px;
  938. background-color: #2979ff;
  939. border-radius: 2px;
  940. margin-right: 5px;
  941. }
  942. .scrollView {
  943. overflow-y: scroll;
  944. height: 95%;
  945. }
  946. .scrollView::-webkit-scrollbar {
  947. display: none;
  948. }
  949. .typeStyle {
  950. padding-left: 0.5em;
  951. }
  952. .paddingNone {
  953. padding: 0;
  954. }
  955. ::v-deep .paddingNone .ibps-uploader {
  956. padding-left: 0.5em;
  957. }
  958. ::v-deep .typeStyle.van-cell::after {
  959. border-bottom: 0px solid #fff;
  960. }
  961. ::v-deep .yonghu .van-cell--borderless {
  962. padding-left: 8px;
  963. }
  964. ::v-deep .yonghu .van-cell .van-field__label {
  965. display: flex;
  966. align-items: center;
  967. justify-content: left;
  968. font-size: 14px;
  969. color: rgb(51, 51, 51);
  970. }
  971. ::v-deep .yonghu .van-cell .van-field__label::before {
  972. content: '';
  973. width: 5px;
  974. height: 14px;
  975. background-color: #2979ff;
  976. border-radius: 2px;
  977. margin-right: 5px;
  978. }
  979. .lineSty {
  980. margin-top: 3px;
  981. margin-bottom: 3px;
  982. }
  983. ::v-deep .spei .van-cell-group {
  984. margin-bottom: 10px;
  985. }
  986. </style>