643bbfeab5237994e31ef94aa6b587a00d8b2131.svn-base 60 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429
  1. <template>
  2. <div style="height:100%;width:100%" id="wenTiContainer_sk">
  3. <el-container>
  4. <el-aside
  5. width="318px"
  6. style="border-right:2px solid #d5d5ff;float:left;text-align: center;"
  7. :style="{'max-height':testHeight+'px','height':testHeight+'px'}">
  8. <span style="display: flex;justify-content: center;align-items: center;border-bottom: 1px solid #ebeef5;">
  9. <el-button size="mini" :class="tabType==1 ? 'skactive' : 'sknormal'" @click="tabChange('1')">当前数据</el-button>
  10. <!-- <el-button size="mini" :class="tabType==2 ? 'skactive' : 'sknormal'" @click="tabChange('2')">历史数据</el-button>-->
  11. <el-button size="mini" :class="tabType==0 ? 'skactive' : 'sknormal'" @click="tabChange('0')">全部数据</el-button>
  12. </span>
  13. <div
  14. class="tree"
  15. style="
  16. height: calc(100% - 50px);
  17. width: 100%;
  18. overflow: auto;
  19. display: inline-flex;">
  20. <el-tree
  21. :highlight-current="true"
  22. style="height:100%;"
  23. :data="treeData"
  24. node-key="id"
  25. show-checkbox
  26. @check-change="handleCheckChange"
  27. ref="jigou_tree"
  28. >
  29. <div class="custom-tree-node" slot-scope="{ node, data }">
  30. <span style="float:left;">{{ data.pnm}}</span>
  31. <div
  32. style="float:right;display: flex;justify-content: flex-end;align-items: center;width:50%;"
  33. >
  34. <span style="color:blue;width:80px;"></span>
  35. </div>
  36. </div>
  37. </el-tree>
  38. </div>
  39. </el-aside>
  40. <el-main style="margin:0px;padding:0px;" class="shuiku" v-loading="exportLoading">
  41. <div class="pages" :style="{'max-height':testHeight+'px'}">
  42. <div class="search">
  43. <el-row type="flex" justify="space-between">
  44. <el-col :span="24">
  45. <el-form
  46. :inline="true"
  47. size="mini"
  48. class="demo-form-inline"
  49. style="padding-left: 10px;"
  50. >
  51. <el-form-item label="行政区划:">
  52. <el-input
  53. resize="none"
  54. type="input"
  55. :rows="3"
  56. placeholder="请输入行政区划名称"
  57. v-model.trim="findParams.adFullName"
  58. clearable
  59. ></el-input>
  60. </el-form-item>
  61. <el-form-item label="工程名称:">
  62. <el-input
  63. resize="none"
  64. type="input"
  65. :rows="3"
  66. placeholder="请输入工程名称"
  67. v-model.trim="findParams.nm"
  68. clearable
  69. ></el-input>
  70. </el-form-item>
  71. </el-form>
  72. </el-col>
  73. </el-row>
  74. <el-row type="flex" justify="space-bv-fortween" v-show="showExpandSearchPanel">
  75. <el-col :span="24">
  76. <el-form
  77. :inline="true"
  78. size="mini"
  79. class="demo-form-inline"
  80. style="padding-left: 10px;"
  81. >
  82. <el-form-item label="是否典型:">
  83. <el-select v-model="findParams.ifCasePblm" clearable placeholder="请选择">
  84. <el-option
  85. v-for="item in supervision"
  86. :key="item.value"
  87. :label="item.label"
  88. :value="item.value"
  89. ></el-option>
  90. </el-select>
  91. </el-form-item>
  92. <el-form-item label="问题筛选:">
  93. <el-select v-model="pblscr" clearable placeholder="请选择">
  94. <el-option
  95. v-for="item in pblscrList"
  96. :key="item.value"
  97. :label="item.lable"
  98. :value="item.value"
  99. ></el-option>
  100. </el-select>
  101. </el-form-item>
  102. <el-form-item label="上报人员:">
  103. <el-input
  104. resize="none"
  105. type="input"
  106. :rows="3"
  107. placeholder="请输入名称"
  108. v-model.trim="findParams.persName"
  109. ></el-input>
  110. </el-form-item>
  111. <el-form-item label="发现时间:">
  112. <el-date-picker
  113. v-model="value6"
  114. type="daterange"
  115. value-format="yyyy-MM-dd"
  116. style="width:240px"
  117. range-separator="至"
  118. start-placeholder="开始日期"
  119. end-placeholder="结束日期"
  120. ></el-date-picker>
  121. </el-form-item>
  122. <el-form-item label="所在组:">
  123. <el-input
  124. resize="none"
  125. type="input"
  126. :rows="3"
  127. placeholder="请输入所在组名称"
  128. v-model.trim="pblscrGroup"
  129. clearable
  130. ></el-input>
  131. </el-form-item>
  132. <el-form-item label="是否包含多媒体文件:">
  133. <el-select v-model="findParams.hasVedio" clearable placeholder="请选择">
  134. <el-option
  135. v-for="item in hasVedio1"
  136. :key="item.value"
  137. :label="item.label"
  138. :value="item.value"
  139. ></el-option>
  140. </el-select>
  141. </el-form-item>
  142. <el-form-item label="问题督查状态:">
  143. <el-select v-model="findParams.state" clearable placeholder="请选择">
  144. <el-option
  145. v-for="item in stateList"
  146. :key="item.value"
  147. :label="item.label"
  148. :value="item.value"
  149. ></el-option>
  150. </el-select>
  151. </el-form-item>
  152. <el-form-item label="问题督查状态:">
  153. <el-select v-model="findParams.state" clearable placeholder="请选择">
  154. <el-option
  155. v-for="item in stateList"
  156. :key="item.value"
  157. :label="item.label"
  158. :value="item.value"
  159. ></el-option>
  160. </el-select>
  161. </el-form-item>
  162. </el-form>
  163. </el-col>
  164. </el-row>
  165. <el-row type="flex" justify="space-between" style="border-top:1px solid #0014ff2e;">
  166. <el-col style="padding-bottom:10px;" :offset="11" :span="2">
  167. <el-button
  168. style="float:right;margin-right:10px;border: 1px solid #0014ff2e;
  169. border-radius: 0px 0px 5px 5px;border-top: 0px;"
  170. type="info"
  171. plain
  172. size="mini"
  173. @click="showExpandSearchPanel = !showExpandSearchPanel"
  174. >
  175. {{showExpandSearchPanel?'收起':'更多条件'}}
  176. <i
  177. class="el-icon-arrow-down el-icon--right"
  178. v-show="!showExpandSearchPanel"
  179. />
  180. <i class="el-icon-arrow-up el-icon--right" v-show="showExpandSearchPanel"/>
  181. </el-button>
  182. </el-col>
  183. <el-col :offset="2" :span="9">
  184. <el-button
  185. style="color:rgba(255,255,255,1);float:right;margin-right:10px;margin-top:5px;"
  186. type="primary"
  187. icon="el-icon-search"
  188. @click="search"
  189. >&nbsp;查&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;询&nbsp;
  190. </el-button>
  191. <!-- <el-button
  192. style="color:rgba(255,255,255,1);float:right;margin-right:10px;margin-top:5px;"
  193. type="success"
  194. icon="el-icon-download"
  195. @click="exportWord"
  196. >导出WORD</el-button>
  197. -->
  198. <el-button
  199. style="color:rgba(255,255,255,1);float:right;margin-right:10px;margin-top:5px;"
  200. type="success"
  201. icon="el-icon-download"
  202. @click="exportExcel"
  203. >导出EXCEL
  204. </el-button>
  205. <el-button
  206. style="color:rgba(255,255,255,1);float:right;margin-right:10px;margin-top:5px;"
  207. type="success"
  208. @click="submitBtn"
  209. >问题提交
  210. </el-button>
  211. <el-button
  212. v-if="isGd"
  213. style="color:rgba(255,255,255,1);float:right;margin-right:10px;margin-top:5px;"
  214. type="success"
  215. icon="el-icon-download"
  216. @click="toForm"
  217. >导出一表一单
  218. </el-button>
  219. <!-- <el-button
  220. style="color:rgba(255,255,255,1);float:right;margin-right:10px;margin-top:5px;"
  221. type="success"
  222. icon="el-icon-download"
  223. @click="showPlDialog"
  224. :disabled="uploadDisabled"
  225. >上传模板</el-button>
  226. <el-button
  227. style="color:rgba(255,255,255,1);float:right;margin-right:10px;margin-top:5px;"
  228. type="success"
  229. icon="el-icon-download"
  230. @click="downloadTemplate"
  231. >导出模板</el-button>
  232. <shuiZhaWentiPl v-if="showTianBaoPl"
  233. :showTianBaoPl="showTianBaoPl"
  234. @closePlDialog="closePlDialog">
  235. </shuiZhaWentiPl>-->
  236. </el-col>
  237. </el-row>
  238. </div>
  239. <!-- 查询展示 -->
  240. <div class="search" style="margin-top:10px;">
  241. <el-table
  242. v-loading="loading"
  243. border
  244. ref="multipleTable"
  245. :height="tableHeight"
  246. :data="searchResult"
  247. tooltip-effect="dark"
  248. style="width: 100%"
  249. @selection-change="handleSelectionChange"
  250. >
  251. <el-table-column
  252. type="selection"
  253. min-width="55">
  254. </el-table-column>
  255. <!-- <el-table-column align="center" type="index" label="序号" min-width="25">-->
  256. <!-- <template slot-scope="scope">{{ (currentPage - 1) * pageSize + (scope.$index + 1) }}-->
  257. <!-- </template>-->
  258. <!-- </el-table-column>-->
  259. <el-table-column
  260. header-align="center"
  261. align="center"
  262. min-width="60"
  263. prop="province"
  264. label="省" v-if="isXj"
  265. show-overflow-tooltip
  266. ></el-table-column>
  267. <el-table-column
  268. header-align="center"
  269. align="center"
  270. min-width="60"
  271. prop="city"
  272. :label="ownAdName"
  273. show-overflow-tooltip
  274. ></el-table-column>
  275. <el-table-column
  276. header-align="center"
  277. align="center"
  278. min-width="60"
  279. prop="country"
  280. label="县"
  281. v-if="isXj"
  282. show-overflow-tooltip
  283. ></el-table-column>
  284. <el-table-column
  285. header-align="center"
  286. align="center"
  287. min-width="80"
  288. prop="nm"
  289. label="项目名称"
  290. show-overflow-tooltip
  291. ></el-table-column>
  292. <el-table-column
  293. header-align="center"
  294. align="center"
  295. min-width="80"
  296. prop="inspPblmDesc"
  297. label="问题描述"
  298. show-overflow-tooltip
  299. ></el-table-column>
  300. <el-table-column
  301. header-align="center"
  302. align="center"
  303. min-width="100"
  304. prop="state"
  305. label="问题督查状态">
  306. <template slot-scope="scope">
  307. <p v-if="Number(scope.row.state) === 0"><span class="inspPblmCate"
  308. style="background: #F56C6C;">未提交</span>
  309. </p>
  310. <p v-if="scope.row.state == 2"><span class="inspPblmCate"
  311. style="background: #409EFF;">已提交</span>
  312. </p>
  313. <p v-if="scope.row.state == 3"><span class="inspPblmCate"
  314. style="background: #67C23A;">已发布</span>
  315. </p>
  316. </template>
  317. </el-table-column>
  318. <el-table-column
  319. header-align="center"
  320. align="center"
  321. min-width="60"
  322. prop="ifCasePblm"
  323. label="典型"
  324. >
  325. <template slot-scope="scope">
  326. <p v-if="scope.row.ifCasePblm == 1">是</p>
  327. <p v-if="scope.row.ifCasePblm == 0">否</p>
  328. </template>
  329. </el-table-column>
  330. <el-table-column
  331. header-align="center"
  332. align="center"
  333. min-width="70"
  334. prop="persName"
  335. label="上报人"
  336. ></el-table-column>
  337. <el-table-column
  338. header-align="center"
  339. align="center"
  340. min-width="80"
  341. show-overflow-tooltip
  342. prop="orgNm"
  343. label="所在组"
  344. ></el-table-column>
  345. <el-table-column
  346. prop="collTime"
  347. label="上报时间"
  348. :formatter="timestampToTime"
  349. sortable
  350. align="center"
  351. min-width="110"
  352. show-overflow-tooltip>
  353. <template slot-scope="scope">
  354. {{scope.row.collTime ? formatDateTime(scope.row.collTime) : ''}}
  355. </template>
  356. </el-table-column>
  357. <el-table-column
  358. header-align="center"
  359. align="center"
  360. min-width="80"
  361. prop="hasVedio"
  362. label="是否包含多媒体文件"
  363. >
  364. <template slot-scope="scope">
  365. <p v-if="scope.row.hasVedio == 1">是</p>
  366. <p v-if="scope.row.hasVedio == 0">否</p>
  367. </template>
  368. </el-table-column>
  369. <el-table-column
  370. align="center"
  371. prop
  372. min-width="100"
  373. label="操作"
  374. show-overflow-tooltip
  375. fixed="right"
  376. >
  377. <template slot-scope="scope">
  378. <el-button icon="el-icon-view" title="查看详情" type="text"
  379. @click="showDetails(scope.row.pblmId)"></el-button>
  380. <el-button
  381. v-if="ownPriv('manage')"
  382. icon="el-icon-edit"
  383. type="text"
  384. @click="changeSup(scope.row.pblmId)"
  385. ></el-button>
  386. <el-button
  387. v-if="ownPriv('manage')"
  388. icon="el-icon-delete"
  389. type="text"
  390. title="删除问题" @click="removeSuperviseOne(scope.row.pblmId)"
  391. ></el-button>
  392. </template>
  393. </el-table-column>
  394. </el-table>
  395. <!-- 分页 -->
  396. <div class="paginationWarpper">
  397. <el-pagination
  398. class="paginationCenter"
  399. background
  400. @size-change="handleSizeChange"
  401. @current-change="search"
  402. :current-page.sync="currentPage"
  403. :page-sizes="[10, 20, 50, 100]"
  404. :page-size="pageSize"
  405. layout="total, sizes, prev, pager, next, jumper"
  406. :total="total"
  407. ></el-pagination>
  408. </div>
  409. </div>
  410. <!-- 详情弹框 -->
  411. <el-dialog
  412. class="outerDialog custom_dialog"
  413. title="问题详情"
  414. @close="detailClose"
  415. v-if="supervisionDetailsVisible"
  416. :visible.sync="supervisionDetailsVisible"
  417. >
  418. <supervision-details ref="xianqing" :problemId="currentProblemId"></supervision-details>
  419. <span slot="footer">
  420. <el-button style="margin-top:5px;" @click="supervisionDetailsVisible = false">返回</el-button>
  421. </span>
  422. </el-dialog>
  423. <!-- 删除弹窗 -->
  424. <el-dialog class="deleteDialog" title="问题删除描述" :visible.sync="problemDeleteVisible">
  425. <Problem-delete
  426. ref="deleteMiaoShu"
  427. :deleteProblemId="deleteId"
  428. @deleteSuccess="deleteSuccess"
  429. ></Problem-delete>
  430. <span slot="footer">
  431. <el-button @click="problemDeleteVisible = false">返回</el-button>
  432. </span>
  433. </el-dialog>
  434. <!-- 修改弹框 -->
  435. <problem-edit :editId="editId" @closeEditDialog="closeEditDialog"
  436. v-if="changeSupervisionVisible"></problem-edit>
  437. </div>
  438. </el-main>
  439. </el-container>
  440. </div>
  441. </template>
  442. <script>
  443. import {pblmSubmit, submitUpload} from "../../api/duChaAPI.js";
  444. import {formatDateTime2} from '@util/gw_date.js'
  445. import {exportModel} from "@util/gw_exportModel";
  446. import request from "../../utils/gw_ajax_request.js";
  447. import {hostUrl} from "@util/global_variable.js";
  448. import elaudio from "../../widgets/elAudioShort.vue";
  449. import inuptWithDuChaTreeNode from "../../widgets/inuptWithDuChaTreeNode.vue";
  450. import inputWidthDuChaNodes from "../../widgets/inputWithDuChaNodes.vue";
  451. import inputWidthDuChaShuiKu from "../../widgets/inputWith_sk.vue";
  452. import problemDialog from "./problemDialog.vue";
  453. import {formatDateTime2New} from "../../utils/gw_date";
  454. export default {
  455. props: ["codeId"],
  456. components: {
  457. // 问题详情
  458. supervisionDetails: resolve => {
  459. require(["./supervisionDetails_siluan.vue"], resolve);
  460. },
  461. // 问题删除
  462. ProblemDelete: resolve => {
  463. require(["./problemDelete.vue"], resolve);
  464. },
  465. // 问题修改
  466. problemEdit: resolve => {
  467. require(["./siLuanProblemModify.vue"], resolve);
  468. },
  469. elaudio: elaudio,
  470. inuptWithDuChaTreeNode: inuptWithDuChaTreeNode,
  471. inputWidthDuChaNodes: inputWidthDuChaNodes,
  472. inputWidthDuChaShuiKu: inputWidthDuChaShuiKu,
  473. problemDialog: problemDialog
  474. },
  475. data() {
  476. return {
  477. tabType: "0",//0全部数据,1当前数据,2历史数据
  478. showExpandSearchPanel: false,
  479. tableHeight: window.innerHeight - 290,
  480. dataAll: {},
  481. globoId: "",
  482. currentDate: new Date(),
  483. deleteId: "",
  484. treeNodeArray: [],
  485. treeNodeSelectVisible: false,
  486. adNodeArray: [],
  487. adNodeSelectVisible: false,
  488. areaSelectVisible: false,
  489. rsvrNodeArray: [],
  490. rsvrNodeSelectVisible: false,
  491. skSelectVisible: false,
  492. currentProblemId: "",
  493. updateIdXiuGai: "",
  494. rules1: {
  495. inspPblmName: [
  496. {
  497. required: true,
  498. message: "请输入问题名称",
  499. trigger: "blur"
  500. },
  501. {
  502. min: 1,
  503. max: 999,
  504. message: "不超过100字符",
  505. trigger: "blur"
  506. }
  507. ],
  508. inspPblmDesc: [
  509. {
  510. required: true,
  511. message: "请输入问题描述",
  512. trigger: "blur"
  513. }
  514. ],
  515. recPers: [
  516. {
  517. required: true,
  518. message: "请输入记录人",
  519. trigger: "blur"
  520. },
  521. {
  522. min: 1,
  523. max: 999,
  524. message: "不超过100字符",
  525. trigger: "blur"
  526. }
  527. ],
  528. objType: [
  529. {
  530. required: true,
  531. message: "请选择督查对象类型",
  532. trigger: "change"
  533. }
  534. ],
  535. objId: [
  536. {
  537. required: true,
  538. message: "请选择督查对象类型",
  539. trigger: "change"
  540. }
  541. ],
  542. inspPblmType: [
  543. {
  544. required: true,
  545. message: "请选择督查问题类型",
  546. trigger: "change"
  547. }
  548. ],
  549. dataStat: [
  550. {
  551. required: true,
  552. message: "请选择数据状态",
  553. trigger: "change"
  554. }
  555. ],
  556. collTime: [
  557. {
  558. required: true,
  559. message: "请选择采集时间",
  560. trigger: "change"
  561. }
  562. ],
  563. ifCasePblm: [
  564. {
  565. required: true,
  566. message: "请选择是否典型",
  567. trigger: "change"
  568. }
  569. ],
  570. pblmStat: [
  571. {
  572. required: true,
  573. message: "请选择问题类型",
  574. trigger: "change"
  575. }
  576. ],
  577. inspPblmCate: [
  578. {
  579. required: true,
  580. message: "请选择问题程度",
  581. trigger: "change"
  582. },
  583. {
  584. trigger: "change"
  585. }
  586. ]
  587. },
  588. dxdcAsideHeight: window.innerHeight - 220,
  589. maxHeight: window.innerHeight - 300,
  590. testHeight: window.innerHeight - 80,
  591. supervisionStateList: [
  592. {
  593. value: "0",
  594. label: "暂存"
  595. },
  596. {
  597. value: "1",
  598. label: "上报"
  599. }
  600. ],
  601. supervisionState: [
  602. {
  603. value: "0",
  604. label: "一般"
  605. },
  606. {
  607. value: "1",
  608. label: "较重"
  609. },
  610. {
  611. value: "2",
  612. label: "严重"
  613. },
  614. {
  615. value: "3",
  616. label: "特别严重"
  617. }
  618. ],
  619. supervision: [
  620. {
  621. value: "1",
  622. label: "是"
  623. },
  624. {
  625. value: "0",
  626. label: "否"
  627. }
  628. ],
  629. hasVedio1: [
  630. {
  631. value: "1",
  632. label: "是"
  633. },
  634. {
  635. value: "0",
  636. label: "否"
  637. }
  638. ],
  639. findUseOrgArray: [],
  640. areaInputValue: {},
  641. memberInputValue: {},
  642. multipleSelection: [], // 已选
  643. selectionType: {
  644. remove: 0,
  645. befor: 0,
  646. now: 0,
  647. after: 0
  648. },
  649. // 根据客户点击的督查类型查找督查对象ID
  650. // 新增
  651. listobjId: [],
  652. userId: localStorage.getItem("userid"),
  653. treeData: [],
  654. // 修改督查
  655. changeSupervisionVisible: false,
  656. leibie: [],
  657. // 查询
  658. value6: [],
  659. findParams: {
  660. hasVedio: "",
  661. adCode: "",
  662. pblmStat: "",
  663. inspPblmCate: "",
  664. ifCasePblm: "",
  665. nm: "",
  666. adFullName: "",
  667. startTime: "",
  668. endTime: "",
  669. objType: 19,
  670. inspPblmName: "",
  671. persId: localStorage.getItem("userid"),
  672. state: ''
  673. },
  674. stateList: [
  675. {
  676. label: '未提交',
  677. value: '0'
  678. },
  679. {
  680. label: '已提交',
  681. value: '2'
  682. },
  683. {
  684. label: '已发布',
  685. value: '3'
  686. }
  687. ],
  688. currentPage: 1, // 页码
  689. pageSize: 20, // 条数
  690. loading: false,
  691. total: 0, // 总数
  692. searchResult: [], // 结果
  693. crId: "", // 当前督查id
  694. // 督查详情
  695. userid: localStorage.getItem("userid"),
  696. supervisionDetailsVisible: false,
  697. problemDeleteVisible: false,
  698. supervisionDetails: {},
  699. pblmId: "",
  700. gwComFiles: [],
  701. pblscr: "",
  702. pblscrList: [
  703. {
  704. lable: "我的问题",
  705. value: localStorage.getItem("userid")
  706. }
  707. ],
  708. pblscrGroup: "",
  709. problemList: [],
  710. currentCheckPointList: [],
  711. currentProblemDescList: [],
  712. t1: {},
  713. t2: {},
  714. t3: {},
  715. xiangqingmiaoshu: "",
  716. wenTiLeiBie: "",
  717. jianChaXiangMu: "",
  718. header: {
  719. persId: localStorage.getItem("userid")
  720. },
  721. exportLoading: false,
  722. datas: {},
  723. showTianBaoPl: false,
  724. orgType: '019',
  725. // orgType:'006',
  726. };
  727. },
  728. computed: {
  729. hostUrl() {
  730. return hostUrl;
  731. },
  732. formatDateTime() {
  733. return formatDateTime2New
  734. },
  735. isGd(){
  736. if(localStorage.getItem('currentRlcode').substring(0,2)=="44"){
  737. return true;
  738. }else{
  739. return false;
  740. }
  741. }
  742. },
  743. created() {
  744. if (this.userId) {
  745. console.log("已经登录");
  746. this.search();
  747. } else {
  748. this.$router.push("/login");
  749. }
  750. this.getLeftTreeData();
  751. this.getproblemSmallType();
  752. },
  753. activated() {
  754. },
  755. methods: {
  756. tabChange(tabType) {
  757. this.tabType = tabType;
  758. this.getLeftTreeData();
  759. this.search();
  760. },
  761. handleCheckChange(data, checked, indeterminate) {
  762. let cNarray = this.$refs["jigou_tree"].getCheckedNodes();
  763. console.log(cNarray);
  764. this.treeNodeArray = cNarray;
  765. },
  766. getLeftTreeData() {
  767. var _self = this;
  768. request
  769. .get("/dc/organization/base/getAllNode", {
  770. params: {
  771. userId: this.userId,
  772. orgType: this.orgType,
  773. tabType: this.tabType
  774. }
  775. })
  776. .then(res => {
  777. let data = res.data;
  778. data.forEach(ele => {
  779. if (ele.pid == null || ele.pid == "") {
  780. ele.pid = "019";
  781. }
  782. });
  783. data = _self.getTrees(data);
  784. _self.treeData = data;
  785. });
  786. },
  787. //格式化树形数据
  788. getTrees(list) {
  789. //@wxcwater重写方法 适应多个树
  790. let highLevelLength = 99; //预设最大节点id长度,目前最大应该为12,所以设置为99保证正常
  791. let _self = this;
  792. list.forEach((item, index) => {
  793. item["pidLength"] = item.pid && item.pid != "" ? item.pid.length : 0;
  794. if (highLevelLength > item.pidLength) {
  795. highLevelLength = item.pidLength;
  796. }
  797. });
  798. console.log(highLevelLength);
  799. let heightLevelNode = [];
  800. list.forEach((item, index) => {
  801. if (highLevelLength >= item.pidLength) {
  802. heightLevelNode.push(item);
  803. }
  804. });
  805. list.forEach((item, index) => {
  806. heightLevelNode.forEach(pItem => {
  807. _self.addTreeNode(pItem, item);
  808. });
  809. });
  810. console.log(heightLevelNode);
  811. return heightLevelNode;
  812. },
  813. addTreeNode: function (treeNode, leafNode) {
  814. let _self = this;
  815. if (!treeNode.hasOwnProperty("children")) {
  816. treeNode["children"] = [];
  817. }
  818. if (leafNode.pid == treeNode.id) {
  819. treeNode.children.push(leafNode);
  820. return;
  821. }
  822. treeNode.children.forEach(item => {
  823. _self.addTreeNode(item, leafNode);
  824. });
  825. },
  826. // 查询参数逻辑
  827. insertTreeNode: function (params) {
  828. this.treeNodeArray.push({
  829. name: params.name,
  830. code: params.code
  831. });
  832. this.treeNodeSelectVisible = false;
  833. this.areaSelectVisible = false;
  834. this.skSelectVisible = false;
  835. },
  836. deleteTreeNode: function (tag) {
  837. let deleteIndex;
  838. this.treeNodeArray.forEach((item, index) => {
  839. if (item.code == tag.code) {
  840. deleteIndex = index;
  841. }
  842. });
  843. this.treeNodeArray.splice(deleteIndex, 1);
  844. },
  845. selectDuChaAreaNode(params) {
  846. this.adNodeArray.push(params);
  847. this.areaSelectVisible = false;
  848. this.skSelectVisible = false;
  849. },
  850. deleteAreaNode(tag) {
  851. let deleteIndex;
  852. this.adNodeArray.forEach((item, index) => {
  853. if (item.adCode == tag.adCode) {
  854. deleteIndex = index;
  855. return;
  856. }
  857. });
  858. this.adNodeArray.splice(deleteIndex, 1);
  859. },
  860. selectSkNode(params) {
  861. this.rsvrNodeArray.push(params);
  862. this.skSelectVisible = false;
  863. },
  864. deleteSkNode(tag) {
  865. let deleteIndex;
  866. this.rsvrNodeArray.forEach((item, index) => {
  867. if (item.rsCode == tag.rsCode) {
  868. deleteIndex = index;
  869. return;
  870. }
  871. });
  872. this.rsvrNodeArray.splice(deleteIndex, 1);
  873. },
  874. // end
  875. // 操作成功反馈
  876. successInfo() {
  877. this.$message({
  878. type: "success",
  879. message: "操作成功!"
  880. });
  881. },
  882. // 操作失败反馈
  883. failInfo(val) {
  884. this.$message.error(val);
  885. },
  886. // 已选择项
  887. handleSelectionChange(val) {
  888. this.multipleSelection = val;
  889. },
  890. // 文件上传
  891. submitUpload() {
  892. this.$refs.upload.submit();
  893. },
  894. // 查询
  895. search() {
  896. this.loading = true;
  897. let _self = this;
  898. request
  899. .get("/dc/organization/base/getAllNode", {
  900. params: {
  901. userId: this.userId,
  902. orgType: this.orgType,
  903. tabType: this.tabType
  904. }
  905. })
  906. .then(res => {
  907. let orgAllNode = res.data;
  908. _self.loading = true;
  909. let data = _self.findParams;
  910. data.startTime = _self.value6 && _self.value6.length > 0 ? _self.value6[0] : "";
  911. data.endTime = _self.value6 && _self.value6.length > 0 ? _self.value6[1] : "";
  912. data.pageNum = _self.currentPage;
  913. data.recPers = _self.pblscr;
  914. data.orgNm = _self.pblscrGroup;
  915. data.pageSize = _self.pageSize;
  916. _self.findUseOrgArray = [];
  917. _self.treeNodeArray.forEach(item => {
  918. if (item.id.length < 12) {
  919. orgAllNode.forEach(orgItem => {
  920. if (orgItem.id.startsWith(item.code)) {
  921. _self.findUseOrgArray.push(orgItem.id);
  922. }
  923. });
  924. }
  925. _self.findUseOrgArray.push(item.id);
  926. });
  927. if (_self.findUseOrgArray.length > 0) {
  928. data["orgIds"] = _self.findUseOrgArray.join(",");
  929. } else {
  930. data["orgIds"] = "";
  931. }
  932. this.dataAll = data;
  933. data.tabType = this.tabType;
  934. request.post(`/dc/insp/pblm/page/jswaPblm`, data).then(res => {
  935. _self.loading = false;
  936. _self.multipleSelection = [];
  937. if (res.success) {
  938. res.data.list.forEach(item => {
  939. if (item.inTm || item.upTm || item.rectTm || item.fdTm) {
  940. item.inTm =
  941. typeof item.inTm == "string"
  942. ? item.inTm
  943. : dateFormat(item.inTm, "yyyy-MM-dd");
  944. item.upTm =
  945. typeof item.upTm == "string"
  946. ? item.upTm
  947. : dateFormat(item.upTm, "yyyy-MM-dd");
  948. item.rectTm =
  949. typeof item.rectTm == "string"
  950. ? item.rectTm
  951. : dateFormat(item.rectTm, "yyyy-MM-dd");
  952. item.fdTm =
  953. typeof item.fdTm == "string"
  954. ? item.fdTm
  955. : dateFormat(item.fdTm, "yyyy-MM-dd");
  956. }
  957. });
  958. _self.searchResult = res.data.list;
  959. _self.total = res.data.total;
  960. } else {
  961. _self.failInfo();
  962. }
  963. });
  964. });
  965. },
  966. async submitBtn() {
  967. if (this.multipleSelection.length === 0) {
  968. this.$message.warning('请至少选择一条问题');
  969. return;
  970. }
  971. let newArray = this.multipleSelection.map((item) => {
  972. return {
  973. "objId": item.objId,
  974. "objType": item.objType,
  975. "state": "3"
  976. }
  977. });
  978. const {success, message} = await pblmSubmit(newArray);
  979. if (success) {
  980. this.$message.success('问题发布成功');
  981. this.search();
  982. } else {
  983. this.$message.warning(message);
  984. }
  985. },
  986. toForm(){
  987. var idArr = [];
  988. if(this.multipleSelection && this.multipleSelection.length==0){
  989. this.$message.warning("请选择数据");
  990. return false;
  991. }else{
  992. this.multipleSelection.forEach((item)=>{
  993. idArr.push(item.pblmId);
  994. })
  995. }
  996. var ids = idArr.join(",");
  997. let host = hostUrl;
  998. let nginx = '/pageofficePath/';
  999. let href = 'pageoffice://|' + host + nginx + '/pageoffice/pblm/list/word?ids='+ids+'&filename=pblm|width=1100px;height=800px;ismodal=false;||91A4EE66EC1921F376873E85D6C74FFA|A890649B44577C32CE1930797E1299F9';
  1000. let a = document.createElement('a'); // 创建a标签
  1001. a.setAttribute('href', href);// href链接
  1002. a.click();// 自执行点击事件
  1003. },
  1004. async exportExcel() {
  1005. let _self = this;
  1006. await request
  1007. .get("/dc/organization/base/getAllNode", {
  1008. params: {
  1009. userId: this.userId,
  1010. orgType: this.orgType
  1011. }
  1012. })
  1013. .then(res => {
  1014. let orgAllNode = res.data;
  1015. let data = _self.findParams;
  1016. data.pageNum = _self.currentPage;
  1017. data.pageSize = _self.pageSize;
  1018. data.villType = "0";
  1019. this.datas = JSON.stringify(data);
  1020. _self.treeNodeArray.forEach(item => {
  1021. console.log(item);
  1022. if (item.id.length < 12) {
  1023. orgAllNode.forEach(orgItem => {
  1024. if (orgItem.id.startsWith(item.id)) {
  1025. _self.findUseOrgArray.push(orgItem.id);
  1026. }
  1027. });
  1028. } else {
  1029. _self.findUseOrgArray.push(item.id);
  1030. }
  1031. });
  1032. });
  1033. let url = "/pdcApi/dc/insp/pblm/page/jswaPblm/export";
  1034. let type = "post";
  1035. let exportName = "非法采砂问题列表.xls";
  1036. let result = await exportModel(type, url, exportName, this.datas);
  1037. _self.exportLoading = result;
  1038. },
  1039. async exportWord() {
  1040. let _self = this;
  1041. _self.exportLoading = true;
  1042. await request
  1043. .get("/dc/organization/base/getAllNode", {
  1044. params: {
  1045. userId: this.userId,
  1046. orgType: this.orgType
  1047. }
  1048. })
  1049. .then(res => {
  1050. let orgAllNode = res.data;
  1051. let data = _self.findParams;
  1052. data.pageNum = _self.currentPage;
  1053. data.pageSize = _self.pageSize;
  1054. data.villType = "0";
  1055. _self.treeNodeArray.forEach(item => {
  1056. if (item.id.length < 12) {
  1057. orgAllNode.forEach(orgItem => {
  1058. if (orgItem.id.startsWith(item.id)) {
  1059. _self.findUseOrgArray.push(orgItem.id);
  1060. }
  1061. });
  1062. } else {
  1063. _self.findUseOrgArray.push(item.id);
  1064. }
  1065. });
  1066. });
  1067. await request
  1068. .post("/jswaPblm/doc", _self.dataAll)
  1069. .then(res => {
  1070. if (res.success) {
  1071. _self.exportLoading = false;
  1072. console.log(this.response);
  1073. var a = document.createElement("a");
  1074. a.href = `${this.hostUrl}${res.data.downloadPath}`;
  1075. //设置文件名称
  1076. a.download = "非法采砂问题详情.doc";
  1077. a.click();
  1078. } else {
  1079. _self.$mesage.error(res.message);
  1080. }
  1081. })
  1082. .catch(res => {
  1083. _self.$mesage.error(res.message);
  1084. });
  1085. },
  1086. downFile(blob, fileName) {
  1087. // 非IE下载
  1088. if ("download" in document.createElement("a")) {
  1089. let link = document.createElement("a");
  1090. link.href = window.URL.createObjectURL(blob); // 创建下载的链接
  1091. link.download = fileName; // 下载后文件名
  1092. link.style.display = "none";
  1093. document.body.appendChild(link);
  1094. link.click(); // 点击下载
  1095. window.URL.revokeObjectURL(link.href); // 释放掉blob对象
  1096. document.body.removeChild(link); // 下载完成移除元素
  1097. } else {
  1098. // IE10+下载
  1099. window.navigator.msSaveBlob(blob, fileName);
  1100. }
  1101. },
  1102. handleSizeChange(pageSize) {
  1103. this.pageSize = pageSize;
  1104. this.search();
  1105. },
  1106. // 详情弹框
  1107. showDetails(id) {
  1108. this.currentProblemId = id;
  1109. this.supervisionDetailsVisible = true;
  1110. },
  1111. // 删除弹窗
  1112. removeSuperviseOne(id) {
  1113. this.deleteId = id;
  1114. this.problemDeleteVisible = true;
  1115. },
  1116. deleteSuccess() {
  1117. this.problemDeleteVisible = false;
  1118. this.search();
  1119. this.$emit("problemCount");
  1120. },
  1121. // 时间格式化
  1122. timestampToTime(row, column) {
  1123. var date = new Date(row.collTime);
  1124. var Y = date.getFullYear() + "-";
  1125. var M =
  1126. (date.getMonth() + 1 < 10
  1127. ? "0" + (date.getMonth() + 1)
  1128. : "0" + date.getMonth() + 1) + "-";
  1129. var D =
  1130. (date.getDate() < 10 ? "0" + date.getDate() : date.getDate()) + " ";
  1131. var h =
  1132. (date.getHours() < 10 ? "0" + date.getHours() : date.getHours()) + ":";
  1133. var m =
  1134. date.getMinutes() < 10 ? "0" + date.getMinutes() : date.getMinutes();
  1135. return Y + M + D;
  1136. },
  1137. // 修改弹窗显示
  1138. changeSup(pblmId) {
  1139. this.editId = pblmId
  1140. this.changeSupervisionVisible = true
  1141. },
  1142. // 修改弹窗关闭
  1143. closeEditDialog(val) {
  1144. this.changeSupervisionVisible = false
  1145. if (val == 'success') this.search()
  1146. },
  1147. showPlDialog() {
  1148. this.showTianBaoPl = true;
  1149. },
  1150. closePlDialog(val) {
  1151. this.showTianBaoPl = false;
  1152. this.search();
  1153. },
  1154. getproblemSmallType() {
  1155. let result = [];
  1156. request.get('/dc/insp/pblms/getPblmType', {
  1157. params: {
  1158. type: 19
  1159. }
  1160. }).then(res => {
  1161. if (res.success) {
  1162. res.data.forEach((ele) => {
  1163. let haveinspPblmsName = false;
  1164. result.forEach((inspPblm) => {
  1165. if (inspPblm['inspPblmsName'] == ele.inspPblmsName) {
  1166. let havechekPoint = false;
  1167. inspPblm['checkPoints'].forEach((chekPoint) => {
  1168. if (chekPoint['checkPointName'] == ele.checkPoint) {
  1169. //
  1170. chekPoint['pblmDescs'].push({
  1171. pblmDesc: ele.pblmDesc,
  1172. sn: ele.sn,
  1173. guid: ele.guid,
  1174. });
  1175. havechekPoint = true;
  1176. }
  1177. });
  1178. if (!havechekPoint) {
  1179. let newCheckPoint = {};
  1180. newCheckPoint['checkPointName'] = ele.checkPoint;
  1181. newCheckPoint['sort2'] = ele.sort2;
  1182. newCheckPoint['pblmDescs'] = [{
  1183. pblmDesc: ele.pblmDesc,
  1184. sn: ele.sn,
  1185. guid: ele.guid,
  1186. }]
  1187. inspPblm['checkPoints'].push(newCheckPoint);
  1188. }
  1189. haveinspPblmsName = true;
  1190. }
  1191. });
  1192. if (!haveinspPblmsName) {
  1193. let haveinspPblmsObj = {};
  1194. haveinspPblmsObj['inspPblmsName'] = ele.inspPblmsName;
  1195. haveinspPblmsObj['sort1'] = ele.sort1;
  1196. haveinspPblmsObj['checkPoints'] = [{
  1197. checkPointName: ele.checkPoint,
  1198. sort2: ele.sort2,
  1199. pblmDescs: [{
  1200. pblmDesc: ele.pblmDesc,
  1201. sn: ele.sn,
  1202. guid: ele.guid,
  1203. }]
  1204. }];
  1205. result.push(haveinspPblmsObj);
  1206. }
  1207. })
  1208. this.problemList = result;
  1209. }
  1210. })
  1211. },
  1212. detailClose() {
  1213. this.currentProblemId = ''
  1214. }
  1215. },
  1216. watch: {
  1217. codeId: function () {
  1218. this.search();
  1219. },
  1220. showExpandSearchPanel: function (val) {
  1221. if (val) {
  1222. this.tableHeight = window.innerHeight - 389;
  1223. } else {
  1224. this.tableHeight = window.innerHeight - 290;
  1225. }
  1226. }
  1227. }
  1228. };
  1229. </script>
  1230. <style rel="stylesheet/scss" lang="scss" scoped>
  1231. @import "./base.css";
  1232. @import url("/src/assets/iconfont/iconfont.css");
  1233. @import url("/src/assets/css/mixin.scss");
  1234. .upload-container {
  1235. width: 100%;
  1236. position: relative;
  1237. .image-uploader {
  1238. width: 35%;
  1239. float: left;
  1240. }
  1241. .image-preview {
  1242. width: 200px;
  1243. height: 200px;
  1244. position: relative;
  1245. border: 1px dashed #d9d9d9;
  1246. float: left;
  1247. // margin-left: 50px;
  1248. .image-preview-wrapper {
  1249. position: relative;
  1250. width: 100%;
  1251. height: 100%;
  1252. img {
  1253. width: 100%;
  1254. height: 100%;
  1255. }
  1256. }
  1257. .image-preview-action {
  1258. position: absolute;
  1259. width: 100%;
  1260. height: 100%;
  1261. left: 0;
  1262. top: 0;
  1263. cursor: default;
  1264. text-align: center;
  1265. color: #fff;
  1266. opacity: 0;
  1267. font-size: 20px;
  1268. background-color: rgba(0, 0, 0, 0.5);
  1269. transition: opacity 0.3s;
  1270. cursor: pointer;
  1271. text-align: center;
  1272. line-height: 200px;
  1273. .el-icon-delete {
  1274. font-size: 36px;
  1275. }
  1276. }
  1277. &:hover {
  1278. .image-preview-action {
  1279. opacity: 1;
  1280. }
  1281. }
  1282. }
  1283. .image-app-preview {
  1284. margin-bottom: 10px;
  1285. width: 40vh;
  1286. height: 180px;
  1287. position: relative;
  1288. border: 1px dashed #d9d9d9;
  1289. float: left;
  1290. // margin-left: 50px;
  1291. .app-fake-conver {
  1292. height: 44px;
  1293. position: absolute;
  1294. width: 100%; // background: rgba(0, 0, 0, .1);
  1295. text-align: center;
  1296. line-height: 64px;
  1297. color: #fff;
  1298. }
  1299. }
  1300. }
  1301. .bottom {
  1302. margin-top: 13px;
  1303. line-height: 12px;
  1304. }
  1305. .button {
  1306. padding: 0;
  1307. float: right;
  1308. }
  1309. .image {
  1310. width: 100%;
  1311. display: block;
  1312. }
  1313. .clearfix:before,
  1314. .clearfix:after {
  1315. display: table;
  1316. content: "";
  1317. }
  1318. .clearfix:after {
  1319. clear: both;
  1320. }
  1321. #wenTiContainer_sk .el-tree-node {
  1322. /* overflow: auto; */
  1323. }
  1324. #wenTiContainer_sk .el-tree-node > .el-tree-node__children {
  1325. overflow: auto;
  1326. }
  1327. .shuiku .el-date-editor.el-input {
  1328. min-width: 180px !important;
  1329. }
  1330. .shuiku .header {
  1331. padding: 0px 10px;
  1332. }
  1333. .shuiku .el-row {
  1334. margin-bottom: 5px;
  1335. }
  1336. .shuiku .content {
  1337. margin: 10px;
  1338. }
  1339. /* .search .el-table>>>.el-tooltip {
  1340. white-space: pre-wrap !important;
  1341. line-height: 30px;
  1342. font-size: 0;
  1343. } */
  1344. .shuiku .search > > > .el-table .el-button:nth-child(odd) {
  1345. margin-left: 0 !important;
  1346. }
  1347. .custom_dialog .el-dialog {
  1348. width: 60% !important;
  1349. }
  1350. .custom_dialog .scroll300 {
  1351. max-height: 60vh !important;
  1352. }
  1353. .shuiku .el-tag + .el-tag {
  1354. margin-left: 10px;
  1355. }
  1356. .shuiku .button-new-tag {
  1357. margin-left: 10px;
  1358. height: 28px;
  1359. line-height: 28px;
  1360. padding-top: 0;
  1361. padding-bottom: 0;
  1362. }
  1363. .shuiku .input-new-tag {
  1364. width: 90px;
  1365. margin-left: 10px;
  1366. vertical-align: bottom;
  1367. }
  1368. .inspPblmCate {
  1369. padding: 2px 10px;
  1370. border-radius: 10px;
  1371. color: #ffffff;
  1372. -webkit-border-radius: 10px;
  1373. -moz-border-radius: 10px;
  1374. border-radius: 10px;
  1375. }
  1376. .skactive {
  1377. background: #3f8eff !important;
  1378. color: white !important;
  1379. margin-top: 5px;
  1380. margin-bottom: 5px;
  1381. }
  1382. .sknormal {
  1383. background: white;
  1384. margin-top: 5px;
  1385. margin-bottom: 5px;
  1386. }
  1387. </style>