2f5afb354968e147ccb84bf2bb66c3707bb5a3d4.svn-base 73 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741
  1. <template>
  2. <!-- 问题处置-2020人饮问题编辑 -->
  3. <div style="height:100%;width:100%" id="wenTiContainer_sk">
  4. <el-container>
  5. <el-aside
  6. width="318px"
  7. style="border-right:2px solid #d5d5ff;float:left"
  8. :style="{'max-height':testHeight+'px','height':testHeight+'px'}"
  9. v-show="!rowId"
  10. >
  11. <wt-left-tree orgType="081" @treeNodeClickHandler="treeNodeClickHandler" @changeYear="changeYear"
  12. @organList="getAllTreeData" @changeTabType="changeTabType"></wt-left-tree>
  13. </el-aside>
  14. <!-- 主要窗口 -->
  15. <el-main style="margin:0px;padding:0px;overflow-y:hidden;" class="shuiku" v-loading="exportLoading">
  16. <!-- <el-card> -->
  17. <div class="pages" :style="{'max-height':testHeight+'px'}">
  18. <!-- 为什么要根据rowId来判断过滤条件的显示或者隐藏? -->
  19. <div style="padding: 12px 0 0 0">
  20. <el-row type="flex" justify="space-between">
  21. <el-col :span="24">
  22. <el-form :inline="true" size="mini" class="demo-form-inline"
  23. style="padding-left: 10px;">
  24. <el-form-item label="行政区划:">
  25. <el-input
  26. resize="none"
  27. type="input"
  28. :rows="3"
  29. placeholder="请输入行政区划名称"
  30. v-model.trim="findParams.adFullName"
  31. clearable
  32. ></el-input>
  33. </el-form-item>
  34. <el-form-item label="督查对象名称:">
  35. <el-input
  36. resize="none"
  37. type="input"
  38. :rows="3"
  39. placeholder="请输入名称"
  40. v-model.trim="findParams.nm"
  41. clearable
  42. ></el-input>
  43. </el-form-item>
  44. </el-form>
  45. </el-col>
  46. </el-row>
  47. <el-row type="flex" justify="space-between" v-show="showExpandSearchPanel">
  48. <el-col :span="24">
  49. <el-form :inline="true" size="mini" class="demo-form-inline"
  50. style="padding-left: 10px;">
  51. <el-form-item label="问题类别:">
  52. <el-select v-model="findParams.inspPblmName" clearable placeholder="请选择">
  53. <el-option
  54. v-for="item in problemList"
  55. :key="item.guid"
  56. :label="item.inspPblmsName"
  57. :value="item.inspPblmsName"
  58. ></el-option>
  59. </el-select>
  60. </el-form-item>
  61. <el-form-item label="问题筛选:">
  62. <el-select v-model="pblscr" clearable placeholder="请选择">
  63. <el-option
  64. v-for="item in pblscrList"
  65. :key="item.value"
  66. :label="item.lable"
  67. :value="item.value"
  68. ></el-option>
  69. </el-select>
  70. </el-form-item>
  71. <el-form-item label="上报人员:">
  72. <el-input
  73. resize="none"
  74. type="input"
  75. :rows="3"
  76. placeholder="请输入名称"
  77. v-model.trim="findParams.persName"
  78. ></el-input>
  79. </el-form-item>
  80. <el-form-item label="发现时间:">
  81. <el-date-picker
  82. style="width: 200px;"
  83. v-model="value6"
  84. type="daterange"
  85. value-format="yyyy-MM-dd"
  86. range-separator="至"
  87. start-placeholder="开始日期"
  88. end-placeholder="结束日期"
  89. ></el-date-picker>
  90. </el-form-item>
  91. <el-form-item label="所在组:">
  92. <el-input
  93. resize="none"
  94. type="input"
  95. :rows="3"
  96. placeholder="请输入所在组名称"
  97. v-model.trim="pblscrGroup"
  98. clearable
  99. ></el-input>
  100. </el-form-item>
  101. <el-form-item label="是否包含多媒体文件:">
  102. <el-select v-model="findParams.hasVedio" clearable placeholder="请选择">
  103. <el-option
  104. v-for="item in hasVedio1"
  105. :key="item.value"
  106. :label="item.label"
  107. :value="item.value"
  108. ></el-option>
  109. </el-select>
  110. </el-form-item>
  111. <el-form-item label="问题督查状态:">
  112. <el-select v-model="findParams.state" clearable placeholder="请选择">
  113. <el-option
  114. v-for="item in stateList"
  115. :key="item.value"
  116. :label="item.label"
  117. :value="item.value"
  118. ></el-option>
  119. </el-select>
  120. </el-form-item>
  121. </el-form>
  122. </el-col>
  123. </el-row>
  124. <el-row type="flex" justify="space-between" style="border-top:1px solid #0014ff2e;">
  125. <el-col style='padding-bottom:10px;' :span="12">
  126. <el-button style="float:right;margin-right:10px;border: 1px solid #0014ff2e;
  127. border-radius: 0px 0px 5px 5px;border-top: 0px;" type="info" plain
  128. size="mini"
  129. @click="showExpandSearchPanel = !showExpandSearchPanel"
  130. >
  131. {{showExpandSearchPanel?'收起':'更多条件'}}
  132. <i class="el-icon-arrow-down el-icon--right" v-show="!showExpandSearchPanel"/>
  133. <i class="el-icon-arrow-up el-icon--right" v-show="showExpandSearchPanel"/>
  134. </el-button>
  135. </el-col>
  136. <el-col :span="12">
  137. <el-button
  138. style="color:rgba(255,255,255,1);float:right;margin-right:10px;margin-top:5px;"
  139. type="success"
  140. @click="submitBtn"
  141. >问题提交
  142. </el-button>
  143. <el-button
  144. style="color:rgba(255,255,255,1);float:right;margin-right:10px;margin-top:5px;"
  145. type="primary"
  146. icon="el-icon-search"
  147. @click="search"
  148. >&nbsp;查&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;询&nbsp;
  149. </el-button>
  150. <el-button
  151. v-if="isGd"
  152. style="color:rgba(255,255,255,1);float:right;margin-right:10px;margin-top:5px;"
  153. type="success"
  154. icon="el-icon-download"
  155. @click="toForm"
  156. >导出一表一单
  157. </el-button>
  158. <!-- <el-button-->
  159. <!-- style="color:rgba(255,255,255,1);float:right;margin-right:10px;margin-top:5px;"-->
  160. <!-- type="success"-->
  161. <!-- icon="el-icon-download"-->
  162. <!-- @click="exportExcel"-->
  163. <!-- >导出EXCEL-->
  164. <!-- </el-button>-->
  165. <shuiKuWentiPl v-if="showShuiKuTianBaoPl"
  166. :showShuiKuTianBaoPl="showShuiKuTianBaoPl"
  167. titleName="小水库"
  168. @closePlDialog="closePlDialog">
  169. </shuiKuWentiPl>
  170. </el-col>
  171. </el-row>
  172. </div>
  173. <!-- 查询展示 -->
  174. <div class="search" style="margin-top:10px;">
  175. <el-table
  176. v-loading="loading"
  177. border
  178. ref="multipleTable"
  179. :height="tableHeight"
  180. :data="searchResult"
  181. tooltip-effect="dark"
  182. style="width: 100%"
  183. @selection-change="handleSelectionChange"
  184. >
  185. <el-table-column
  186. type="selection"
  187. min-width="55">
  188. </el-table-column>
  189. <el-table-column align="center" type="index" label="序号" min-width="25">
  190. <template slot-scope="scope">{{ (currentPage - 1) * pageSize + (scope.$index + 1) }}
  191. </template>
  192. </el-table-column>
  193. <!-- <el-table-column header-align="center" align="center" min-width="140" prop="inspPblmName" label="小水库问题类别"></el-table-column> -->
  194. <el-table-column
  195. header-align="center"
  196. align="center"
  197. min-width="60"
  198. prop="province"
  199. label="省" v-if="isXj"
  200. show-overflow-tooltip
  201. ></el-table-column>
  202. <el-table-column
  203. header-align="center"
  204. align="center"
  205. min-width="60"
  206. prop="city"
  207. :label="ownAdName"
  208. show-overflow-tooltip
  209. ></el-table-column>
  210. <el-table-column
  211. header-align="center"
  212. align="center"
  213. min-width="60"
  214. prop="country"
  215. label="县"
  216. v-if="isXj"
  217. show-overflow-tooltip
  218. ></el-table-column>
  219. <el-table-column
  220. header-align="center"
  221. align="center"
  222. min-width="110"
  223. prop="nm"
  224. label="督查对象名称"
  225. show-overflow-tooltip
  226. ></el-table-column>
  227. <el-table-column
  228. header-align="center"
  229. align="center"
  230. min-width="140"
  231. prop="inspPblmName"
  232. label="督查问题类别"
  233. show-overflow-tooltip
  234. ></el-table-column>
  235. <el-table-column
  236. header-align="center"
  237. align="center"
  238. min-width="100"
  239. prop="checkPoint"
  240. label="检查项目"
  241. show-overflow-tooltip>
  242. </el-table-column>
  243. <el-table-column
  244. header-align="center"
  245. align="center"
  246. min-width="100"
  247. prop="pblmDescBz"
  248. label="问题描述"
  249. show-overflow-tooltip>
  250. </el-table-column>
  251. <el-table-column
  252. header-align="center"
  253. align="center"
  254. min-width="70"
  255. prop="persName"
  256. label="上报人"
  257. ></el-table-column>
  258. <el-table-column
  259. header-align="center"
  260. align="center"
  261. min-width="80"
  262. show-overflow-tooltip
  263. prop="orgNm"
  264. label="所在组"
  265. ></el-table-column>
  266. <el-table-column
  267. prop="collTime"
  268. label="上报时间"
  269. :formatter="timestampToTime"
  270. sortable
  271. align="center"
  272. min-width="110"
  273. show-overflow-tooltip
  274. ></el-table-column>
  275. <el-table-column
  276. header-align="center"
  277. align="center"
  278. min-width="150"
  279. prop="hasVedio"
  280. label="是否包含多媒体文件"
  281. >
  282. <template slot-scope="scope">
  283. <p v-if="scope.row.hasVedio == 1">是</p>
  284. <p v-if="scope.row.hasVedio == 0">否</p>
  285. </template>
  286. </el-table-column>
  287. <el-table-column
  288. header-align="center"
  289. align="center"
  290. min-width="100"
  291. prop="state"
  292. label="问题督查状态">
  293. <template slot-scope="scope">
  294. <p v-if="Number(scope.row.state) === 0"><span class="inspPblmCate"
  295. style="background: #F56C6C;">未提交</span>
  296. </p>
  297. <p v-if="scope.row.state == 2"><span class="inspPblmCate"
  298. style="background: #409EFF;">已提交</span>
  299. </p>
  300. <p v-if="scope.row.state == 3"><span class="inspPblmCate"
  301. style="background: #67C23A;">已发布</span>
  302. </p>
  303. </template>
  304. </el-table-column>
  305. <el-table-column
  306. fixed="right"
  307. label="操作"
  308. min-width="130"
  309. >
  310. <template slot-scope="scope">
  311. <!-- <span style="margin-right:10px;" v-if="ownPriv('manage')">-->
  312. <!-- <el-button icon="el-icon-s-flag" type="text" v-if="scope.row.quote == '1'" title="已被督查简报引用"-->
  313. <!-- @click="changeSfYy(scope.row.pblmId,1)"></el-button>-->
  314. <!-- <i class="el-icon-s-flag" v-else title="未被督查简报引用" @click="changeSfYy(scope.row.pblmId,0)"-->
  315. <!-- style="cursor: pointer;"></i>-->
  316. <!-- </span>-->
  317. <el-button icon="el-icon-view" title="查看详情" type="text"
  318. @click="showDetails(scope.row.pblmId)"></el-button>
  319. <el-button icon="el-icon-edit" type="text" title="修改问题"
  320. @click="changeSup(scope.row.pblmId)"
  321. v-if="ownPriv('manage')"></el-button>
  322. <el-button
  323. icon="el-icon-delete"
  324. type="text"
  325. v-if="ownPriv('manage')"
  326. title="删除问题" @click="removeSuperviseOne(scope.row.pblmId)"
  327. ></el-button>
  328. </template>
  329. </el-table-column>
  330. </el-table>
  331. <!-- 分页 -->
  332. <div class="paginationWarpper">
  333. <el-pagination
  334. class="paginationCenter"
  335. background
  336. @size-change="handleSizeChange"
  337. @current-change="search"
  338. :current-page.sync="currentPage"
  339. :page-sizes="[10, 20, 50, 100]"
  340. :page-size="pageSize"
  341. layout="total, sizes, prev, pager, next, jumper"
  342. :total="total"
  343. ></el-pagination>
  344. </div>
  345. </div>
  346. <!-- 详情弹框 -->
  347. <el-dialog
  348. class="outerDialog custom_dialog"
  349. title="问题详情"
  350. width="60%"
  351. v-if="supervisionDetailsVisible"
  352. :visible.sync="supervisionDetailsVisible"
  353. >
  354. <supervision-details ref="xianqing" :problemId="currentProblemId"
  355. :objType="81"></supervision-details>
  356. <span slot="footer">
  357. <el-button style="margin-top:5px;" @click="supervisionDetailsVisible = false">返回</el-button>
  358. </span>
  359. </el-dialog>
  360. <!-- 删除的弹窗 -->
  361. <el-dialog class="deleteDialog" title="问题删除描述" :visible.sync="problemDeleteVisible">
  362. <Problem-delete
  363. ref="deleteMiaoShu"
  364. :deleteProblemId="deleteId"
  365. @deleteSuccess="deleteSuccess"
  366. ></Problem-delete>
  367. <span slot="footer">
  368. <el-button @click="problemDeleteVisible = false">返回</el-button>
  369. </span>
  370. </el-dialog>
  371. </div>
  372. </el-main>
  373. </el-container>
  374. <EditPicOnline
  375. ref="editPicWeakupEvnent"
  376. v-if="editPicDialog"
  377. :picUrl="picUrl"
  378. @cancelHandler="cancelHandler"
  379. @editPicData="editPicDataEvent"
  380. ></EditPicOnline>
  381. <!-- 修改组件 -->
  382. <problem-edit :editId="editId" @closeEditDialog="closeEditDialog" v-if="changeSupervisionVisible"
  383. :pType="pType"></problem-edit>
  384. </div>
  385. </template>
  386. <script>
  387. import {
  388. deleteFileById,
  389. findProblemPageInfo,
  390. getSupervisdByID,
  391. showDetailsXq,
  392. pblmSubmit,
  393. submitUpload,
  394. updatelist
  395. } from "@api/duChaAPI.js";
  396. import {exportModel} from "@util/gw_exportModel";
  397. import request from "@util/gw_ajax_request.js";
  398. import elaudio from "@widget/elAudioShort.vue";
  399. import inuptWithDuChaTreeNode from "@widget/inuptWithDuChaTreeNode.vue";
  400. import inputWidthDuChaNodes from "@widget/inputWithDuChaNodes.vue";
  401. import inputWidthDuChaShuiKu from "@widget/inputWith_sk.vue";
  402. import problemDialog from "./problemDialog.vue";
  403. import shuiKuWentiPl from "./problemBatchImp/tongYongWenti_piliang.vue"
  404. import wtLeftTree from "./wtcz_lefttree.vue"
  405. import { hostUrl } from "@util/global_variable.js";
  406. export default {
  407. props: ["codeId", "rowId"],
  408. components: {
  409. upload: resolve => {
  410. require(["@widget/uploadFile.vue"], resolve);
  411. },
  412. //详情页
  413. supervisionDetails: resolve => {
  414. require(["../duChaWenTi/supervisionDetails_bxzzqlaq.vue"], resolve);
  415. },
  416. // 删除描述页
  417. ProblemDelete: resolve => {
  418. require(["./problemDelete.vue"], resolve);
  419. },
  420. EditPicOnline: resolve => {
  421. require(["@widget/EditPicOnline/EditPicOnline.vue"], resolve);
  422. },
  423. // addPicDialog: resolve => {
  424. // require(["./addPicDialog.vue"], resolve);
  425. // },
  426. elaudio: elaudio,
  427. inuptWithDuChaTreeNode: inuptWithDuChaTreeNode,
  428. inputWidthDuChaNodes: inputWidthDuChaNodes,
  429. inputWidthDuChaShuiKu: inputWidthDuChaShuiKu,
  430. problemDialog: problemDialog,
  431. shuiKuWentiPl: shuiKuWentiPl,
  432. wtLeftTree: wtLeftTree,
  433. // 修改问题
  434. problemEdit: resolve => {
  435. require(["../duChaWenTi/bxzzqlaqProblemModify.vue"], resolve);
  436. },
  437. },
  438. data() {
  439. var validatePass1 = (rules1, value, callback) => {
  440. if (this.newSupervision.startTime > this.newSupervision.endTime) {
  441. callback(new Error("结束时间不能早于开始时间"));
  442. } else {
  443. callback();
  444. }
  445. };
  446. var validatePass2 = (rules1, value, callback) => {
  447. let startTime = this.changeSupervision.startTime.slice(0, 10);
  448. if (startTime > this.changeSupervision.endTime) {
  449. callback(new Error("结束时间不能早于开始时间"));
  450. } else {
  451. callback();
  452. }
  453. };
  454. var divisionList = (rules1, value, callback) => {
  455. if (this.newGroup.divisionList.length) {
  456. callback();
  457. } else {
  458. callback(new Error("至少要添加一个地区"));
  459. }
  460. };
  461. return {
  462. tabType: "0",//0全部,1当前数据,2历史数据
  463. editPicRefresh: true,
  464. showExpandSearchPanel: false,
  465. tableHeight: window.innerHeight - 291,
  466. globoId: "",
  467. addPicPanel: false,
  468. currentDate: new Date(),
  469. deleteId: "",
  470. treeNodeArray: [],
  471. treeNodeSelectVisible: false,
  472. adNodeArray: [],
  473. adNodeSelectVisible: false,
  474. areaSelectVisible: false,
  475. rsvrNodeArray: [],
  476. rsvrNodeSelectVisible: false,
  477. skSelectVisible: false,
  478. currentProblemId: "",
  479. updateIdXiuGai: "",
  480. rules1: {
  481. inspPblmName: [
  482. {
  483. required: true,
  484. message: "请输入问题名称",
  485. trigger: "blur"
  486. },
  487. {
  488. min: 1,
  489. max: 999,
  490. message: "不超过100字符",
  491. trigger: "blur"
  492. }
  493. ],
  494. inspPblmDesc: [
  495. {
  496. required: true,
  497. message: "请输入问题描述",
  498. trigger: "blur"
  499. }
  500. ],
  501. recPers: [
  502. {
  503. required: true,
  504. message: "请输入记录人",
  505. trigger: "blur"
  506. },
  507. {
  508. min: 1,
  509. max: 999,
  510. message: "不超过100字符",
  511. trigger: "blur"
  512. }
  513. ],
  514. objType: [
  515. {
  516. required: true,
  517. message: "请选择督查对象类型",
  518. trigger: "change"
  519. }
  520. ],
  521. objId: [
  522. {
  523. required: true,
  524. message: "请选择督查对象类型",
  525. trigger: "change"
  526. }
  527. ],
  528. inspPblmType: [
  529. {
  530. required: true,
  531. message: "请选择督查问题类型",
  532. trigger: "change"
  533. }
  534. ],
  535. dataStat: [
  536. {
  537. required: true,
  538. message: "请选择数据状态",
  539. trigger: "change"
  540. }
  541. ],
  542. collTime: [
  543. {
  544. required: true,
  545. message: "请选择采集时间",
  546. trigger: "change"
  547. }
  548. ],
  549. ifCasePblm: [
  550. {
  551. required: true,
  552. message: "请选择是否典型",
  553. trigger: "change"
  554. }
  555. ],
  556. pblmStat: [
  557. {
  558. required: true,
  559. message: "请选择问题类型",
  560. trigger: "change"
  561. }
  562. ],
  563. inspPblmCate: [
  564. {
  565. required: true,
  566. message: "请选择问题程度",
  567. trigger: "change"
  568. },
  569. {
  570. trigger: "change"
  571. }
  572. ]
  573. },
  574. dxdcAsideHeight: window.innerHeight - 220,
  575. maxHeight: window.innerHeight - 120,
  576. testHeight: window.innerHeight - 120,
  577. supervisionStateList: [
  578. {
  579. value: "0",
  580. label: "暂存"
  581. },
  582. {
  583. value: "1",
  584. label: "上报"
  585. }
  586. ],
  587. supervisionState: [
  588. {
  589. value: "0",
  590. label: "一般"
  591. },
  592. {
  593. value: "1",
  594. label: "较重"
  595. },
  596. {
  597. value: "2",
  598. label: "严重"
  599. },
  600. {
  601. value: "3",
  602. label: "特别严重"
  603. }
  604. ],
  605. supervision: [
  606. {
  607. value: "1",
  608. label: "是"
  609. },
  610. {
  611. value: "0",
  612. label: "否"
  613. }
  614. ],
  615. hasVedio1: [
  616. {
  617. value: "1",
  618. label: "是"
  619. },
  620. {
  621. value: "0",
  622. label: "否"
  623. }
  624. ],
  625. findUseOrgArray: [],
  626. areaInputValue: {},
  627. memberInputValue: {},
  628. multipleSelection: [], // 已选
  629. selectionType: {
  630. remove: 0,
  631. befor: 0,
  632. now: 0,
  633. after: 0
  634. },
  635. // 根据客户点击的督查类型查找督查对象ID
  636. // 新增
  637. listobjId: [],
  638. userId: localStorage.getItem("userid"),
  639. treeData: [],
  640. // 修改督查
  641. pictureArray: [],
  642. audioArray: [],
  643. videoArray: [],
  644. fileArray: [],
  645. audiotabName: "",
  646. videotabName: "",
  647. picturetabName: "",
  648. filetabName: "",
  649. playerOptions: {
  650. height: "120",
  651. autoplay: true,
  652. muted: true,
  653. language: "en",
  654. playbackRates: [0.7, 1.0, 1.5, 2.0],
  655. sources: [
  656. {
  657. type: "video/mp4",
  658. // mp4
  659. src: "http://vjs.zencdn.net/v/oceans.mp4"
  660. // webm
  661. // src: "https://cdn.theguardian.tv/webM/2015/07/20/150716YesMen_synd_768k_vp8.webm"
  662. },
  663. {
  664. type: "video/mp4",
  665. // mp4
  666. src: "http://vjs.zencdn.net/v/oceans.mp4"
  667. // webm
  668. // src: "https://cdn.theguardian.tv/webM/2015/07/20/150716YesMen_synd_768k_vp8.webm"
  669. },
  670. {
  671. type: "video/mp4",
  672. // mp4
  673. src: "http://vjs.zencdn.net/v/oceans.mp4"
  674. // webm
  675. // src: "https://cdn.theguardian.tv/webM/2015/07/20/150716YesMen_synd_768k_vp8.webm"
  676. },
  677. {
  678. type: "video/mp4",
  679. // mp4
  680. src: "http://vjs.zencdn.net/v/oceans.mp4"
  681. // webm
  682. // src: "https://cdn.theguardian.tv/webM/2015/07/20/150716YesMen_synd_768k_vp8.webm"
  683. }
  684. ]
  685. },
  686. changeSupervisionVisible: false,
  687. changeSupervisionLoading: false,
  688. changeSupervision: {
  689. nm: "",
  690. presId: localStorage.getItem("userid"),
  691. endTime: "",
  692. pblmId: "",
  693. objId: "",
  694. pType: "",
  695. inspGroupId: "",
  696. inspPblmName: "",
  697. inspPblmDesc: "",
  698. pblmLong: "",
  699. pblmLat: "",
  700. pblmStat: "",
  701. ifCasePblm: "",
  702. inspPblmOrgName: "",
  703. pblmPersName: "",
  704. inspPblmCate: "",
  705. reviOpin: "",
  706. reviConc: "",
  707. reviOrgGuid: "",
  708. collTime: "",
  709. recPers: "",
  710. gwComFiles: [
  711. {
  712. id: "",
  713. filePath: "",
  714. bizId: ""
  715. }
  716. ]
  717. },
  718. flash: false,
  719. // 督查类型
  720. supervisionTypeList: [
  721. {
  722. value: "1",
  723. label: "小水库"
  724. }
  725. ],
  726. // 查询
  727. value6: [],
  728. findParams: {
  729. hasVedio: "",
  730. adCode: "",
  731. pblmStat: "",
  732. nm: "",
  733. adFullName: "",
  734. startTime: "",
  735. endTime: "",
  736. pType: 81,
  737. inspPblmName: "",
  738. state: "",
  739. persId: localStorage.getItem("userid")
  740. },
  741. stateList: [
  742. {
  743. label: '未提交',
  744. value: '0'
  745. },
  746. {
  747. label: '已提交',
  748. value: '2'
  749. },
  750. {
  751. label: '已发布',
  752. value: '3'
  753. }
  754. ],
  755. currentPage: 1, // 页码
  756. pageSize: 20, // 条数
  757. loading: false,
  758. total: 0, // 总数
  759. searchResult: [], // 结果
  760. crId: "", // 当前督查id
  761. // 督查详情
  762. userid: localStorage.getItem("userid"),
  763. supervisionDetailsVisible: false,
  764. problemDeleteVisible: false,
  765. supervisionDetails: {},
  766. pblmId: "",
  767. gwComFiles: [],
  768. pblscr: "",
  769. pblscrList: [
  770. {
  771. lable: "我的问题",
  772. value: localStorage.getItem("userid")
  773. }
  774. ],
  775. pblscrGroup: "",
  776. t1: {},
  777. t2: {},
  778. t3: {},
  779. problemList: [],
  780. currentCheckPointList: [],
  781. currentProblemDescList: [],
  782. xiangqingmiaoshu: '',
  783. wenTiLeiBie: "",
  784. jianChaXiangMu: "",
  785. actionUrl: "",
  786. fileList: [],
  787. header: {
  788. 'persId': localStorage.getItem('userid'),
  789. 'accessToken': localStorage.getItem('accessToken')
  790. },
  791. fileListLength: 0,
  792. showShuiKuTianBaoPl: false,
  793. uploadDisabled: true,
  794. exportLoading: false,
  795. datas: {},
  796. orgIds: '001',
  797. editPicDialog: false,
  798. picUrl: "",
  799. picId: "",
  800. downloadIcon: "el-icon-download",
  801. buttonLoading: false,
  802. treeAllData: [],
  803. newYear: "",
  804. editId: "",
  805. pType: 81,
  806. };
  807. },
  808. computed: {
  809. hostUrl() {
  810. return hostUrl
  811. },
  812. isGd(){
  813. if(localStorage.getItem('currentRlcode').substring(0,2)=="44"){
  814. return true;
  815. }else{
  816. return false;
  817. }
  818. }
  819. },
  820. created() {
  821. if (this.userId) {
  822. console.log("已经登录");
  823. this.search();
  824. } else {
  825. this.$router.push("/login");
  826. }
  827. this.getproblemSmallType();
  828. this.addPicPanel = false;
  829. },
  830. activated() {
  831. },
  832. methods: {
  833. changeTabType(tabType) {
  834. this.treeNodeArray = [];
  835. this.tabType = tabType;
  836. this.search();
  837. },
  838. //图片编辑
  839. editPicEvent(item) {
  840. this.picUrl = this.hostUrl + "/" + item.filePath;
  841. this.editPicDialog = true;
  842. this.editPicRefresh = false;
  843. this.picId = item.id;
  844. },
  845. cancelHandler() {
  846. this.editPicDialog = false;
  847. this.editPicRefresh = true;
  848. },
  849. editPicDataEvent(item) {
  850. request.post(`/file/updateFile?bizId=${this.changeSupervision.pblmId}&id=${this.picId}`, item, {headers: {'Content-Type': 'multipart/form-data'}}).then(res => {
  851. console.log(res);
  852. if (res.success) {
  853. this.pictureArray = [];
  854. showDetailsXq(this.updateIdXiuGai).then(res => {
  855. res.data.gwComFiles.forEach(item => {
  856. this.pictureArray.push(item);
  857. this.editPicDialog = false;
  858. this.editPicRefresh = true;
  859. });
  860. this.picturetabName = "图片资料(" + this.pictureArray.length + ")";
  861. });
  862. }
  863. });
  864. },
  865. // 操作成功反馈
  866. successInfo() {
  867. this.$message({
  868. type: "success",
  869. message: "操作成功!"
  870. });
  871. },
  872. // 操作失败反馈
  873. failInfo(val) {
  874. this.$message.error(val);
  875. },
  876. // 已选择项
  877. handleSelectionChange(val) {
  878. this.multipleSelection = val;
  879. },
  880. toForm(){
  881. var idArr = [];
  882. if(this.multipleSelection && this.multipleSelection.length==0){
  883. this.$message.warning("请选择数据");
  884. return false;
  885. }else{
  886. this.multipleSelection.forEach((item)=>{
  887. idArr.push(item.pblmId);
  888. })
  889. }
  890. var ids = idArr.join(",");
  891. let host = hostUrl;
  892. let nginx = '/pageofficePath/';
  893. let href = 'pageoffice://|' + host + nginx + '/pageoffice/pblm/list/word?ids='+ids+'&filename=pblm|width=1100px;height=800px;ismodal=false;||91A4EE66EC1921F376873E85D6C74FFA|A890649B44577C32CE1930797E1299F9';
  894. let a = document.createElement('a'); // 创建a标签
  895. a.setAttribute('href', href);// href链接
  896. a.click();// 自执行点击事件
  897. },
  898. // 查询
  899. async search() {
  900. this.loading = true;
  901. let _self = this;
  902. let orgAllNode = this.treeAllData;
  903. _self.loading = true;
  904. let data = _self.findParams;
  905. data.startTime = _self.value6 && _self.value6.length > 0 ? _self.value6[0] : '';
  906. data.endTime = _self.value6 && _self.value6.length > 0 ? _self.value6[1] : '';
  907. data.pageNum = _self.currentPage;
  908. data.recPers = _self.pblscr;
  909. data.orgNm = _self.pblscrGroup;
  910. data.pageSize = _self.pageSize;
  911. data.villType = "";
  912. _self.findUseOrgArray = [];
  913. _self.treeNodeArray.forEach(item => {
  914. if (item.id.length < 12) {
  915. orgAllNode.forEach(orgItem => {
  916. if (orgItem.id.startsWith(item.code)) {
  917. _self.findUseOrgArray.push(orgItem.id);
  918. }
  919. });
  920. }
  921. _self.findUseOrgArray.push(item.id);
  922. });
  923. if (_self.findUseOrgArray.length > 0) {
  924. data["orgIds"] = _self.findUseOrgArray.join(",");
  925. this.orgIds = _self.findUseOrgArray.join(",");
  926. } else {
  927. data["orgIds"] = "";
  928. }
  929. if (this.rowId) {
  930. data["orgIds"] = this.rowId;
  931. }
  932. data["year"] = this.newYear;
  933. data.tabType = this.tabType;
  934. findProblemPageInfo(data).then(res => {
  935. _self.loading = false;
  936. _self.multipleSelection = [];
  937. if (res.success) {
  938. _self.searchResult = res.data.list;
  939. // console.log( "绝对是"+searchResult)
  940. _self.total = res.data.total;
  941. } else {
  942. _self.failInfo();
  943. }
  944. });
  945. },
  946. async submitBtn() {
  947. if (this.multipleSelection.length === 0) {
  948. this.$message.warning('请至少选择一条问题');
  949. return;
  950. }
  951. let newArray = this.multipleSelection.map((item) => {
  952. return {
  953. "objId": item.objId,
  954. "objType": item.objType,
  955. "state": "3"
  956. }
  957. });
  958. const {success, message} = await pblmSubmit(newArray);
  959. if (success) {
  960. this.$message.success('问题发布成功');
  961. this.search();
  962. } else {
  963. this.$message.warning(message);
  964. }
  965. },
  966. async exportExcel() {
  967. this.exportLoading = true;
  968. let _self = this;
  969. let orgAllNode = _self.treeAllData;
  970. let data = _self.findParams;
  971. data.pageNum = _self.currentPage;
  972. data.pageSize = _self.pageSize;
  973. data.villType = "";
  974. _self.datas = JSON.stringify(data);
  975. _self.treeNodeArray.forEach(item => {
  976. console.log(item);
  977. if (item.id.length < 12) {
  978. orgAllNode.forEach(orgItem => {
  979. if (orgItem.id.startsWith(item.id)) {
  980. _self.findUseOrgArray.push(orgItem.id);
  981. }
  982. });
  983. } else {
  984. _self.findUseOrgArray.push(item.id);
  985. }
  986. });
  987. let url = "/pdcApi/dc/insp/pblm/page/jsztfh/export";
  988. let type = "post";
  989. let exportName = "节水载体复核问题列表.xls"
  990. let result = await exportModel(type, url, exportName, this.datas);
  991. _self.exportLoading = result;
  992. },
  993. async exportWord() {
  994. let _self = this;
  995. _self.exportLoading = true;
  996. let orgAllNode = _self.treeAllData;
  997. let data = _self.findParams;
  998. data.pageNum = _self.currentPage;
  999. data.pageSize = _self.pageSize;
  1000. data.villType = "";
  1001. this.datas = data;
  1002. _self.treeNodeArray.forEach(item => {
  1003. if (item.id.length < 12) {
  1004. orgAllNode.forEach(orgItem => {
  1005. if (orgItem.id.startsWith(item.id)) {
  1006. _self.findUseOrgArray.push(orgItem.id);
  1007. }
  1008. });
  1009. } else {
  1010. _self.findUseOrgArray.push(item.id);
  1011. }
  1012. });
  1013. //下载word文档2
  1014. await request.post('/rever/doc', this.datas).then(res => {
  1015. if (res.success) {
  1016. console.log(this.response)
  1017. var a = document.createElement('a');
  1018. a.href = `${this.hostUrl}${res.data.downloadPath}`;
  1019. //设置文件名称
  1020. a.download = '小水库问题详情.doc';
  1021. a.click();
  1022. // window.open(`${this.hostUrl}${res.data.downloadPath}`)
  1023. _self.exportLoading = false;
  1024. } else {
  1025. _self.$mesage.error(res.message)
  1026. }
  1027. }).catch(res => {
  1028. _self.$mesage.error(res.message)
  1029. })
  1030. },
  1031. downFile(blob, fileName) {
  1032. // 非IE下载
  1033. if ("download" in document.createElement("a")) {
  1034. let link = document.createElement("a");
  1035. link.href = window.URL.createObjectURL(blob); // 创建下载的链接
  1036. link.download = fileName; // 下载后文件名
  1037. link.style.display = "none";
  1038. document.body.appendChild(link);
  1039. link.click(); // 点击下载
  1040. window.URL.revokeObjectURL(link.href); // 释放掉blob对象
  1041. document.body.removeChild(link); // 下载完成移除元素
  1042. } else {
  1043. // IE10+下载
  1044. window.navigator.msSaveBlob(blob, fileName);
  1045. }
  1046. },
  1047. // 下载模板
  1048. async downloadTemplate() {
  1049. await this.search();
  1050. await this.downloadTemplateSet();
  1051. this.uploadDisabled = false;
  1052. },
  1053. downloadTemplateSet() {
  1054. let _this = this;
  1055. _this.downloadIcon = "el-icon-loading"
  1056. // 使用POST传值下载文件,可以看到请求参数和避免请求参数过长导致请求失败
  1057. let xhr = new XMLHttpRequest();
  1058. this.findParams.orgIds = '';
  1059. let datas = JSON.stringify(this.findParams);
  1060. xhr.open('post', '/api/dc/imp/pblm/download', true);
  1061. xhr.responseType = 'blob';
  1062. // data传值方式和Content-Type要对应
  1063. let data = 'userId=' + this.userId + '&orgType=001&orgIds=' + this.orgIds + '&datas=' + datas;
  1064. xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
  1065. // xhr.setRequestHeader('Content-Type', 'application/json;charset=utf-8');
  1066. xhr.setRequestHeader('persId', localStorage.getItem('userid') ? localStorage.getItem('userid') : '');
  1067. xhr.onload = function () {
  1068. if (this.status == 200) {
  1069. let blob = this.response;
  1070. let a = document.createElement('a');
  1071. let url = window.URL.createObjectURL(blob);
  1072. a.href = url;
  1073. //设置文件名称
  1074. a.download = '小水库问题.xls';
  1075. a.click();
  1076. }
  1077. _this.downloadIcon = "el-icon-download"
  1078. }
  1079. xhr.send(data);
  1080. },
  1081. showPlDialog() {
  1082. this.showShuiKuTianBaoPl = true
  1083. },
  1084. closePlDialog(val) {
  1085. this.showShuiKuTianBaoPl = false
  1086. this.search();
  1087. },
  1088. handleSizeChange(pageSize) {
  1089. this.pageSize = pageSize;
  1090. this.search();
  1091. },
  1092. // 新增
  1093. getDuChaId() {
  1094. //新增中 获取督查对象id
  1095. getSupervisdByID(this.userid, 1).then(res => {
  1096. if (res.success) {
  1097. // alert(1)
  1098. this.listobjId = res.data;
  1099. } else {
  1100. this.failInfo();
  1101. }
  1102. });
  1103. },
  1104. // 取消
  1105. removeNewSupervision(arg) {
  1106. this.gwComFiles = [];
  1107. if (arg) {
  1108. this.gwComFiles = arg;
  1109. this.$refs.uploadFile.init();
  1110. }
  1111. },
  1112. // 详情弹框
  1113. showDetails(id) {
  1114. this.currentProblemId = id;
  1115. this.supervisionDetailsVisible = true;
  1116. },
  1117. // 删除弹窗
  1118. removeSuperviseOne(id) {
  1119. this.deleteId = id;
  1120. this.problemDeleteVisible = true;
  1121. // showDetailsXq(id).then(res => {
  1122. // // console.log("123" + res.data)
  1123. // this.persNameRen = res.data.persName;
  1124. // });
  1125. },
  1126. deleteSuccess() {
  1127. this.problemDeleteVisible = false;
  1128. this.search();
  1129. this.$emit("problemCount");
  1130. },
  1131. // 修改弹窗显示
  1132. // changeSup(id) {
  1133. // this.currentProblemId = '';
  1134. // this.pictureArray = [];
  1135. // this.audioArray = [];
  1136. // this.videoArray = [];
  1137. // this.fileArray = [];
  1138. // this.updateIdXiuGai = id;
  1139. // showDetailsXq(this.updateIdXiuGai).then(res => {
  1140. // this.changeSupervision = res.data;
  1141. // this.fileList = this.changeSupervision.gwComFiles;
  1142. // this.t1['inspPblmsName'] = this.changeSupervision.inspPblmsName
  1143. // this.problemList.forEach(ele => {
  1144. // if (ele.inspPblmsName == this.t1.inspPblmsName) {
  1145. // this.problemListChange(ele)
  1146. // }
  1147. // })
  1148. // this.t2['checkPointName'] = this.changeSupervision.checkPoint
  1149. // this.currentCheckPointList.forEach(ele => {
  1150. // if (ele.checkPointName == this.t2.checkPointName) {
  1151. // this.currentCheckPointListChange(ele)
  1152. // }
  1153. // })
  1154. // this.t3['pblmDesc'] = this.changeSupervision.pblmDesc
  1155. // this.changeSupervisionVisible = true;
  1156. // res.data.gwComFiles.forEach(item => {
  1157. // if (
  1158. // item.fileExt == "mp3" ||
  1159. // item.fileExt == "MP3" ||
  1160. // item.fileExt == "m4a"
  1161. // ) {
  1162. // this.audioArray.push(item);
  1163. // } else if (
  1164. // item.fileExt == "jpg" ||
  1165. // item.fileExt == "JPG" ||
  1166. // item.fileExt == "png" ||
  1167. // item.fileExt == "PNG" ||
  1168. // item.fileExt == "JPEG" ||
  1169. // item.fileExt == "jpeg"
  1170. // ) {
  1171. // this.pictureArray.push(item);
  1172. // } else if (item.fileExt == "mp4" || item.fileExt == "MP4") {
  1173. // this.videoArray.push({
  1174. // id: item.id,
  1175. // bizId: item.bizId,
  1176. // width: "130",
  1177. // height: "130",
  1178. // autoplay: false,
  1179. // muted: true,
  1180. // language: "en",
  1181. // playbackRates: [0.7, 1.0, 1.5, 2.0],
  1182. // sources: [
  1183. // {
  1184. // type: "video/mp4",
  1185. // // mp4
  1186. // src: this.hostUrl + item.filePath
  1187. // // webm
  1188. // // src: "https://cdn.theguardian.tv/webM/2015/07/20/150716YesMen_synd_768k_vp8.webm"
  1189. // }
  1190. // ]
  1191. // });
  1192. // } else {
  1193. // this.fileArray.push(item);
  1194. // }
  1195. // });
  1196. //
  1197. // this.picturetabName = "图片资料(" + this.pictureArray.length + ")";
  1198. // this.audiotabName = "音频资料(" + this.audioArray.length + ")";
  1199. // this.videotabName = "视频资料(" + this.videoArray.length + ")";
  1200. // this.filetabName = "其它资料(" + this.fileArray.length + ")";
  1201. // });
  1202. // },
  1203. changeSup(pblmId) {
  1204. this.editId = pblmId;
  1205. this.changeSupervisionVisible = true
  1206. },
  1207. // 提交修改信息
  1208. changeSupervisionInfo() {
  1209. this.$refs.changeSupFrom.validate(valid => {
  1210. if (valid) {
  1211. this.$nextTick(() => {
  1212. this.buttonLoading = true;
  1213. if (this.$refs.uploadFile.submitUpload(this.changeSupervision.pblmId)) {
  1214. this.removeNewSupervision();
  1215. }
  1216. setTimeout(() => {
  1217. this.changeSupervisionLoading = true;
  1218. this.changeSupervision.gwComFiles = this.gwComFiles;
  1219. let data = this.changeSupervision;
  1220. updatelist(data).then(res => {
  1221. this.pblmId = res.data.pblmId;
  1222. this.gwComFiles = res.data.gwComFiles;
  1223. this.changeSupervisionLoading = false;
  1224. if (res.success) {
  1225. this.buttonLoading = false;
  1226. this.search();
  1227. this.successInfo();
  1228. this.addPicPanel = false;
  1229. this.changeSupervisionVisible = false;
  1230. } else {
  1231. this.failInfo();
  1232. }
  1233. });
  1234. }, 1000)
  1235. })
  1236. }
  1237. });
  1238. },
  1239. // 时间格式化
  1240. timestampToTime(row, column) {
  1241. var date = new Date(row.collTime);
  1242. var Y = date.getFullYear() + "-";
  1243. var M =
  1244. (date.getMonth() + 1 < 10
  1245. ? "0" + (date.getMonth() + 1)
  1246. : date.getMonth() + 1) + "-";
  1247. var D =
  1248. (date.getDate() < 10 ? "0" + date.getDate() : date.getDate()) + " ";
  1249. var h =
  1250. (date.getHours() < 10 ? "0" + date.getHours() : date.getHours()) + ":";
  1251. var m =
  1252. date.getMinutes() < 10 ? "0" + date.getMinutes() : date.getMinutes();
  1253. return Y + M + D;
  1254. },
  1255. // 删除图片文件
  1256. removeFile(id, index) {
  1257. var _self = this;
  1258. this.$confirm("此操作将永久删除该文件, 是否继续?", "提示", {
  1259. confirmButtonText: "确定",
  1260. cancelButtonText: "返回",
  1261. type: "warning"
  1262. }).then(
  1263. res => {
  1264. if (res === "confirm") {
  1265. deleteFileById(id, this.userId).then(res => {
  1266. if (res.success) {
  1267. this.fileListLength = 0;
  1268. this.fileList.forEach(item => {
  1269. if (
  1270. item.fileExt == "mp3" ||
  1271. item.fileExt == "MP3" ||
  1272. item.fileExt == "m4a"
  1273. ) {
  1274. this.audioArray.splice(index, 1);
  1275. } else if (
  1276. item.fileExt == "jpg" ||
  1277. item.fileExt == "JPG" ||
  1278. item.fileExt == "png" ||
  1279. item.fileExt == "PNG" ||
  1280. item.fileExt == "JPEG" ||
  1281. item.fileExt == "jpeg"
  1282. ) {
  1283. this.pictureArray.splice(index, 1);
  1284. } else if (item.fileExt == "mp4" || item.fileExt == "MP4") {
  1285. this.videoArray.splice(index, 1);
  1286. }
  1287. });
  1288. _self.changeSup(this.updateIdXiuGai);
  1289. } else {
  1290. this.failInfo();
  1291. }
  1292. });
  1293. }
  1294. },
  1295. res => {
  1296. console.log("返回");
  1297. }
  1298. );
  1299. },
  1300. changeSupervisionVisiblefalse() {
  1301. this.$nextTick(() => {
  1302. if (this.flash) {
  1303. this.flash = false;
  1304. this.search();
  1305. }
  1306. });
  1307. this.changeSupervisionVisible = false;
  1308. this.changeSupervision = {
  1309. dataStat: "",
  1310. nm: "",
  1311. endTime: "",
  1312. pblmId: "",
  1313. objId: "",
  1314. pType: "",
  1315. inspGroupId: "",
  1316. inspPblmCate: "",
  1317. inspPblmName: "",
  1318. inspPblmDesc: "",
  1319. pblmLong: "",
  1320. pblmLat: "",
  1321. pblmStat: "",
  1322. ifCasePblm: "",
  1323. inspPblmOrgName: "",
  1324. pblmPersName: "",
  1325. reviOpin: "",
  1326. reviConc: "",
  1327. reviOrgGuid: "",
  1328. collTime: "",
  1329. recPers: "",
  1330. note: "",
  1331. gwComFiles: [
  1332. {
  1333. id: "",
  1334. filePath: "",
  1335. bizId: ""
  1336. }
  1337. ]
  1338. };
  1339. // this.$refs.uploadFile.init();
  1340. this.addPicPanel = false;
  1341. },
  1342. addPic() {
  1343. this.addPicPanel = !this.addPicPanel;
  1344. },
  1345. getproblemSmallType() {
  1346. let result = [];
  1347. request.get('/dc/insp/pblms/getPblmType', {
  1348. params: {
  1349. type: '81',
  1350. pguid: '00000000000000000000000000000000'
  1351. }
  1352. }).then(res => {
  1353. if (res.success) {
  1354. res.data.forEach((ele) => {
  1355. let haveinspPblmsName = false;
  1356. result.forEach((inspPblm) => {
  1357. if (inspPblm['inspPblmsName'] == ele.inspPblmsName) {
  1358. //
  1359. let havechekPoint = false;
  1360. inspPblm['checkPoints'].forEach((chekPoint) => {
  1361. if (chekPoint['checkPointName'] == ele.checkPoint) {
  1362. havechekPoint = true;
  1363. }
  1364. });
  1365. if (!havechekPoint) {
  1366. let newCheckPoint = {};
  1367. newCheckPoint['checkPointName'] = ele.checkPoint;
  1368. newCheckPoint['sort2'] = ele.sort2;
  1369. newCheckPoint['guid'] = ele.guid;
  1370. inspPblm['checkPoints'].push(newCheckPoint);
  1371. }
  1372. haveinspPblmsName = true;
  1373. }
  1374. });
  1375. if (!haveinspPblmsName) {
  1376. let haveinspPblmsObj = {};
  1377. haveinspPblmsObj['inspPblmsName'] = ele.inspPblmsName;
  1378. haveinspPblmsObj['sort1'] = ele.sort1;
  1379. haveinspPblmsObj['checkPoints'] = [{
  1380. checkPointName: ele.checkPoint,
  1381. sort2: ele.sort2,
  1382. guid: ele.guid
  1383. }];
  1384. result.push(haveinspPblmsObj);
  1385. }
  1386. })
  1387. this.problemList = result;
  1388. console.log(this.problemList);
  1389. }
  1390. })
  1391. },
  1392. problemListChange: function (item) {
  1393. this.t1 = item;
  1394. this.wenTiLeiBie = item.inspPblmsName;
  1395. this.currentCheckPointList = item.checkPoints;
  1396. },
  1397. currentCheckPointListChange: function (item) {
  1398. this.jianChaXiangMu = item.checkPointName;
  1399. this.currentProblemDescList = item.pblmDescs;
  1400. },
  1401. currentProblemDescListChange: function (item) {
  1402. this.xiangqingmiaoshu = item.pblmDesc;
  1403. console.log(item);
  1404. },
  1405. fileUpErr(err, file, fileList) {
  1406. this.$message.error("上传出错,请修改文件!");
  1407. this.fileList = [];
  1408. },
  1409. fileSuccess(item) {
  1410. this.fileList.push(item.data);
  1411. console.log(this.fileList);
  1412. },
  1413. // onChangeDialog() {
  1414. // this.changeSupervisionVisible = true;
  1415. // this.$refs.changeSupFrom.validate(valid => {
  1416. // if (valid) {
  1417. // this.changeSupervisionLoading = true;
  1418. // this.changeSupervision.inspPblmsName = this.wenTiLeiBie
  1419. // this.changeSupervision.checkPoint = this.jianChaXiangMu
  1420. // this.changeSupervision.inspPblmName = this.wenTiLeiBie //后台只需要这一个字段和问题id inspPblmsName和checkPoint可不传
  1421. // this.changeSupervision.inspPlbmType = this.t2.sort2;
  1422. // this.changeSupervision.pblmsTypeId = this.t2.guid;
  1423. // this.changeSupervision.gwComFiles = this.fileList;
  1424. // let data = this.changeSupervision;
  1425. // updatelist(data).then(res => {
  1426. // this.pblmId = res.data.pblmId;
  1427. // this.gwComFiles = res.data.gwComFiles;
  1428. // if (res.success) {
  1429. // if (this.$refs.uploadFile.submitUpload(data.pblmId)) {
  1430. // this.removeNewSupervision();
  1431. // this.successInfo();
  1432. // this.addPicPanel = false;
  1433. // this.changeSupervisionLoading = false;
  1434. // }
  1435. // } else {
  1436. // _self.failInfo();
  1437. // }
  1438. // });
  1439. // }
  1440. // });
  1441. // },
  1442. addFile(file, fileList) {
  1443. this.fileListLength = fileList.length;
  1444. },
  1445. UploadUrl: function () {
  1446. return `/pdcApi/file/insert?bizId=${this.changeSupervision.pblmId}`
  1447. },
  1448. beforeAvatarUpload(file) {
  1449. console.log(file);
  1450. },
  1451. //切换问题是否被督查简报调用
  1452. changeSfYy(row, val) {
  1453. this.$confirm('此问题将切换是否被督查简报引用, 是否继续?', '提示', {
  1454. confirmButtonText: '确定',
  1455. cancelButtonText: '取消',
  1456. type: 'warning'
  1457. }).then(() => {
  1458. if (val) {
  1459. request.post(`/dc/insp/pblm/update`, {
  1460. "pblmId": row,
  1461. "quote": 0
  1462. }).then(res => {
  1463. if (res.success) {
  1464. this.search();
  1465. }
  1466. })
  1467. } else {
  1468. request.post(`/dc/insp/pblm/update`, {
  1469. "pblmId": row,
  1470. "quote": 1
  1471. }).then(res => {
  1472. if (res.success) {
  1473. this.search();
  1474. }
  1475. })
  1476. }
  1477. }).catch(() => {
  1478. this.$message({
  1479. type: 'info',
  1480. message: '已取消切换'
  1481. });
  1482. });
  1483. },
  1484. treeNodeClickHandler(data) {
  1485. this.treeNodeArray = data;
  1486. },
  1487. changeYear(val) {
  1488. this.newYear = val;
  1489. this.search();
  1490. },
  1491. getAllTreeData(data) {
  1492. this.treeAllData = data;
  1493. },
  1494. closeEditDialog() {
  1495. this.changeSupervisionVisible = false
  1496. setTimeout(() => {
  1497. this.search()
  1498. }, 800)
  1499. }
  1500. },
  1501. watch: {
  1502. codeId: function () {
  1503. this.search();
  1504. },
  1505. showExpandSearchPanel: function (val) {
  1506. if (val) {
  1507. this.tableHeight = window.innerHeight - 390;
  1508. } else {
  1509. this.tableHeight = window.innerHeight - 291;
  1510. }
  1511. },
  1512. rowId(val) {
  1513. if (val) {
  1514. this.search();
  1515. }
  1516. }
  1517. },
  1518. };
  1519. </script>
  1520. <style rel="stylesheet/scss" lang="scss" scoped>
  1521. @import "./base.css";
  1522. @import url("/src/assets/iconfont/iconfont.css");
  1523. @import url("/src/assets/css/mixin.scss");
  1524. .upload-container {
  1525. width: 100%;
  1526. position: relative;
  1527. .image-uploader {
  1528. width: 35%;
  1529. float: left;
  1530. }
  1531. .image-preview {
  1532. width: 200px;
  1533. height: 200px;
  1534. position: relative;
  1535. border: 1px dashed #d9d9d9;
  1536. float: left;
  1537. // margin-left: 50px;
  1538. .image-preview-wrapper {
  1539. position: relative;
  1540. width: 100%;
  1541. height: 100%;
  1542. img {
  1543. width: 100%;
  1544. height: 100%;
  1545. }
  1546. }
  1547. .image-preview-action {
  1548. position: absolute;
  1549. width: 100%;
  1550. height: 100%;
  1551. left: 0;
  1552. top: 0;
  1553. cursor: default;
  1554. text-align: center;
  1555. color: #fff;
  1556. opacity: 0;
  1557. font-size: 20px;
  1558. background-color: rgba(0, 0, 0, 0.5);
  1559. transition: opacity 0.3s;
  1560. cursor: pointer;
  1561. text-align: center;
  1562. line-height: 200px;
  1563. .el-icon-delete {
  1564. font-size: 36px;
  1565. }
  1566. .el-icon-edit-outline {
  1567. font-size: 36px;
  1568. }
  1569. }
  1570. &:hover {
  1571. .image-preview-action {
  1572. opacity: 1;
  1573. }
  1574. }
  1575. }
  1576. .image-app-preview {
  1577. margin-bottom: 10px;
  1578. width: 40vh;
  1579. height: 180px;
  1580. position: relative;
  1581. border: 1px dashed #d9d9d9;
  1582. float: left;
  1583. // margin-left: 50px;
  1584. .app-fake-conver {
  1585. height: 44px;
  1586. position: absolute;
  1587. width: 100%; // background: rgba(0, 0, 0, .1);
  1588. text-align: center;
  1589. line-height: 64px;
  1590. color: #fff;
  1591. }
  1592. }
  1593. }
  1594. .bottom {
  1595. margin-top: 13px;
  1596. line-height: 12px;
  1597. }
  1598. .button {
  1599. padding: 0;
  1600. float: right;
  1601. }
  1602. .image {
  1603. width: 100%;
  1604. display: block;
  1605. }
  1606. .clearfix:before,
  1607. .clearfix:after {
  1608. display: table;
  1609. content: "";
  1610. }
  1611. .clearfix:after {
  1612. clear: both;
  1613. }
  1614. #wenTiContainer_sk .el-tree-node {
  1615. /* overflow: auto; */
  1616. }
  1617. #wenTiContainer_sk .el-tree-node > .el-tree-node__children {
  1618. overflow: auto;
  1619. }
  1620. .shuiku .el-date-editor.el-input {
  1621. min-width: 180px !important;
  1622. }
  1623. .shuiku .header {
  1624. padding: 0px 10px;
  1625. }
  1626. .shuiku .el-row {
  1627. margin-bottom: 5px;
  1628. }
  1629. .shuiku .content {
  1630. margin: 10px;
  1631. }
  1632. /* .search .el-table>>>.el-tooltip {
  1633. white-space: pre-wrap !important;
  1634. line-height: 30px;
  1635. font-size: 0;
  1636. } */
  1637. .shuiku .search > > > .el-table .el-button:nth-child(odd) {
  1638. margin-left: 0 !important;
  1639. }
  1640. .custom_dialog .el-dialog {
  1641. width: 60% !important;
  1642. }
  1643. .custom_dialog .scroll300 {
  1644. max-height: 60vh !important;
  1645. }
  1646. .scroll300 .el-form {
  1647. padding-top: 5px;
  1648. padding-right: 5px;
  1649. }
  1650. .shuiku .el-tag + .el-tag {
  1651. margin-left: 10px;
  1652. }
  1653. .shuiku .button-new-tag {
  1654. margin-left: 10px;
  1655. height: 29px;
  1656. line-height: 29px;
  1657. padding-top: 0;
  1658. padding-bottom: 0;
  1659. }
  1660. .shuiku .input-new-tag {
  1661. width: 90px;
  1662. margin-left: 10px;
  1663. vertical-align: bottom;
  1664. }
  1665. .inspPblmCate {
  1666. padding: 2px 10px;
  1667. border-radius: 10px;
  1668. color: #ffffff;
  1669. -webkit-border-radius: 10px;
  1670. -moz-border-radius: 10px;
  1671. border-radius: 10px;
  1672. }
  1673. #wenTiContainer_sk .el-select, #wenTiContainer_sk .el-input {
  1674. width: 140px !important;
  1675. }
  1676. </style>