cbfde86e2918dede45422b62ee52e31b20cdd670.svn-base 35 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157
  1. <!-- -->
  2. <template>
  3. <div>
  4. <el-dialog
  5. width="65%"
  6. :title="'督查已填报问题列表'"
  7. :modal="true"
  8. :append-to-body="true"
  9. :before-close="closeProblemList"
  10. :visible.sync="showProblemList"
  11. >
  12. <!-- 查询展示 -->
  13. <div class="search" style="margin-top:10px;height:49vh">
  14. <el-table
  15. border
  16. :height="tableHeight"
  17. ref="multipleTable"
  18. :data="searchResult"
  19. tooltip-effect="dark"
  20. style="width: 100%"
  21. >
  22. <el-table-column align="center" type="index" label="序号" min-width="25" fixed>
  23. <template slot-scope="scope">{{ (currentPage - 1) * pageSize + (scope.$index + 1) }}</template>
  24. </el-table-column>
  25. <!-- <el-table-column
  26. header-align="center"
  27. align="center"
  28. min-width="55"
  29. prop="inspPblmCate"
  30. label="程度"
  31. fixed
  32. >
  33. <template slot-scope="scope">
  34. <p style="color:#27C19F;" v-if="scope.row.inspPblmCate == 0">一般</p>
  35. <p style="color:#E6A23C;" v-if="scope.row.inspPblmCate == 1">较重</p>
  36. <p style="color:#F56C6C;" v-if="scope.row.inspPblmCate == 2">严重</p>
  37. <p style="color:#F56C6C;" v-if="scope.row.inspPblmCate == 3">特别严重</p>
  38. </template>
  39. </el-table-column>
  40. <el-table-column
  41. header-align="center"
  42. align="center"
  43. min-width="60"
  44. prop="province"
  45. label="省" v-if="isXj"
  46. show-overflow-tooltip
  47. ></el-table-column>
  48. <el-table-column
  49. header-align="center"
  50. align="center"
  51. min-width="60"
  52. prop="city"
  53. :label="ownAdName"
  54. show-overflow-tooltip
  55. ></el-table-column>
  56. <el-table-column
  57. header-align="center"
  58. align="center"
  59. min-width="60"
  60. prop="country"
  61. label="县"
  62. v-if="isXj"
  63. show-overflow-tooltip
  64. ></el-table-column>-->
  65. <!-- <el-table-column
  66. header-align="center"
  67. align="center"
  68. min-width="100"
  69. prop="nm"
  70. label="督查水闸名称"
  71. show-overflow-tooltip
  72. ></el-table-column>-->
  73. <el-table-column
  74. header-align="center"
  75. align="center"
  76. min-width="140"
  77. prop="inspPblmName"
  78. label="问题类别"
  79. show-overflow-tooltip
  80. ></el-table-column>
  81. <el-table-column
  82. header-align="center"
  83. align="center"
  84. min-width="230"
  85. prop="checkPoint"
  86. label="检查项目"
  87. show-overflow-tooltip
  88. ></el-table-column>
  89. <el-table-column
  90. header-align="center"
  91. align="center"
  92. min-width="100"
  93. prop="inspPblmDesc"
  94. label="详细描述"
  95. show-overflow-tooltip
  96. ></el-table-column>
  97. <!-- <el-table-column
  98. header-align="center"
  99. align="center"
  100. min-width="60"
  101. prop="ifCasePblm"
  102. label="典型"
  103. >
  104. <template slot-scope="scope">
  105. <p v-if="scope.row.ifCasePblm == 1">是</p>
  106. <p v-if="scope.row.ifCasePblm == 0">否</p>
  107. </template>
  108. </el-table-column>-->
  109. <!-- <el-table-column
  110. header-align="center"
  111. align="center"
  112. min-width="60"
  113. prop="persName"
  114. label="上报人"
  115. ></el-table-column>
  116. <el-table-column
  117. header-align="center"
  118. align="center"
  119. min-width="80"
  120. show-overflow-tooltip
  121. prop="orgNm"
  122. label="所在组"
  123. ></el-table-column>-->
  124. <el-table-column
  125. prop="collTime"
  126. label="上报时间"
  127. :formatter="timestampToTime"
  128. sortable
  129. align="center"
  130. min-width="100"
  131. show-overflow-tooltip
  132. ></el-table-column>
  133. <el-table-column align="center" prop min-width="130" label="操作" fixed="right">
  134. <template slot-scope="scope">
  135. <el-button icon="el-icon-view" title="查看详情" type="text" @click="showDetails(scope.row.pblmId)"></el-button>
  136. <el-button
  137. v-if="ownPriv('manage')"
  138. icon="el-icon-edit"
  139. title="修改问题"
  140. type="text"
  141. @click="changeSup(scope.row.pblmId)"
  142. ></el-button>
  143. <el-button
  144. v-if="ownPriv('manage')"
  145. icon="el-icon-delete"
  146. type="text"
  147. title="删除问题" @click="removeSuperviseOne(scope.row.pblmId)"
  148. ></el-button>
  149. </template>
  150. </el-table-column>
  151. </el-table>
  152. <!-- 分页 -->
  153. <!-- <div class="paginationWarpper">
  154. <el-pagination
  155. class="paginationCenter"
  156. background
  157. @size-change="handleSizeChange"
  158. @current-change="search"
  159. :current-page.sync="currentPage"
  160. :page-sizes="[10, 20, 50, 100]"
  161. :page-size="pageSize"
  162. layout="total, sizes, prev, pager, next, jumper"
  163. :total="total"
  164. ></el-pagination>
  165. </div> -->
  166. </div>
  167. <!-- 详情弹框 -->
  168. <el-dialog
  169. class="outerDialog custom_dialog"
  170. title="问题详情"
  171. :visible.sync="supervisionDetailsVisible"
  172. :append-to-body="true"
  173. v-if="supervisionDetailsVisible"
  174. >
  175. <supervision-details ref="xianqing" :problemId="currentProblemId" :objType="6"></supervision-details>
  176. <span slot="footer">
  177. <el-button style="margin-top:5px;" @click="supervisionDetailsVisible = false">返回</el-button>
  178. </span>
  179. </el-dialog>
  180. <el-dialog
  181. width="60%"
  182. :append-to-body="true"
  183. class="outerDialog custom_dialog"
  184. title="修改督查问题"
  185. :close-on-click-modal="false"
  186. :visible.sync="changeSupervisionVisible"
  187. >
  188. <div class="scroll300">
  189. <div
  190. style="width:49%;overflow-y:auto;max-height:48vh;float:left;border:1px solid #d5d5ff;margin-right:5px;"
  191. >
  192. <p style="font-weight:bolder;background-color:#d5d5ff;padding:3px;">基本信息</p>
  193. <el-form ref="changeSupFrom" :model="changeSupervision" label-width="120px">
  194. <el-form-item label="水库名称" prop="nm">
  195. <el-input v-model="changeSupervision.nm" clearable :disabled="true"></el-input>
  196. </el-form-item>
  197. <el-form-item label="问题类别" prop="inspPblmsName">
  198. <el-input v-model="changeSupervision.inspPblmsName" clearable :disabled="true"></el-input>
  199. </el-form-item>
  200. <el-form-item label="检查项目" prop="checkPoint">
  201. <el-input v-model="changeSupervision.checkPoint" clearable :disabled="true"></el-input>
  202. </el-form-item>
  203. <el-form-item label="问题描述" prop="pblmDesc">
  204. <el-input
  205. :autosize="{ minRows: 4, maxRows: 6}"
  206. type="textarea"
  207. v-model="changeSupervision.pblmDesc"
  208. clearable
  209. :disabled="true"
  210. ></el-input>
  211. </el-form-item>
  212. <el-form-item label="详细描述" prop="inspPblmDesc">
  213. <el-input
  214. type="textarea"
  215. :rows="2"
  216. v-model="changeSupervision.inspPblmDesc"
  217. clearable
  218. ></el-input>
  219. </el-form-item>
  220. <el-form-item label="是否为典型问题:">
  221. <el-select v-model="changeSupervision.ifCasePblm" clearable placeholder="请选择">
  222. <el-option
  223. v-for="item in supervision"
  224. :key="item.value"
  225. :label="item.label"
  226. :value="item.value"
  227. ></el-option>
  228. </el-select>
  229. </el-form-item>
  230. <el-form-item label="严重程度:">
  231. <el-select v-model="changeSupervision.inspPblmCate" clearable placeholder="请选择">
  232. <el-option
  233. v-for="item in supervisionState"
  234. :key="item.value"
  235. :label="item.label"
  236. :value="item.value"
  237. ></el-option>
  238. </el-select>
  239. <!-- <el-radio v-model="changeSupervision.inspPblmCate" label="0">一般</el-radio>
  240. <el-radio v-model="changeSupervision.inspPblmCate" label="1">较重</el-radio>
  241. <el-radio v-model="changeSupervision.inspPblmCate" label="2">严重</el-radio>-->
  242. </el-form-item>
  243. <el-form-item label="备注" prop="note">
  244. <el-input type="textarea" :rows="2" v-model.trim="changeSupervision.note" clearable></el-input>
  245. <!-- <el-input resize="none" type="input" :rows="3" placeholder="请输入" v-model.trim="changeSupervision.pblmPersName"></el-input> -->
  246. </el-form-item>
  247. <el-form-item label="上报人" prop="persName">
  248. <el-input
  249. resize="none"
  250. disabled
  251. type="input"
  252. :rows="3"
  253. placeholder="请输入"
  254. v-model.trim="changeSupervision.persName"
  255. ></el-input>
  256. </el-form-item>
  257. <el-form-item label="采集时间" prop="collTime">
  258. <el-date-picker v-model="changeSupervision.collTime" disabled type="date"></el-date-picker>
  259. </el-form-item>
  260. </el-form>
  261. </div>
  262. <div
  263. style="width: 49%;float: left;border: 1px solid rgb(213, 213, 255);margin-right: 5px;overflow-y: auto;max-height: 48vh;"
  264. >
  265. <p style="font-weight:bolder;background-color:#d5d5ff;padding:3px;">多媒体信息</p>
  266. <el-tabs style="margin:0px 5px">
  267. <el-tab-pane :label="picturetabName">
  268. <!-- <el-table border :data="pictureArray" style="width: 100%;margin: 0 auto;">
  269. <el-table-column header-align="center" align="center" label="图片">
  270. <template slot-scope="scope">
  271. <img style="width:35%;" :src="`${hostUrl}/${scope.row.filePath}`" alt>
  272. </template>
  273. </el-table-column>
  274. <el-table-column header-align="center" align="center" label="操作">
  275. <template slot-scope="scope">
  276. <el-button size="mini" @click="removeFile(scope.row.id,scope.$index)" type="danger">删除</el-button>
  277. </template>
  278. </el-table-column>
  279. </el-table>-->
  280. <el-row style="text-align:right;">
  281. <el-button
  282. :v-if="!addPicPanel?addPicPanel:addPicPanel"
  283. size="mini"
  284. type="text"
  285. :icon="!addPicPanel?'el-icon-circle-plus-outline':'el-icon-circle-close-outline'"
  286. @click="addPic"
  287. >{{!addPicPanel?"添加":"取消"}}</el-button>
  288. </el-row>
  289. <el-row v-if="addPicPanel">
  290. <upload
  291. ref="uploadFile"
  292. :url="`/pdcApi/file/insert?bizId=`"
  293. @uploadOver="removeNewSupervision"
  294. ></upload>
  295. </el-row>
  296. <el-row>
  297. <div style="overflow-y:auto;overflow-x:hidden;max-height:30vh;padding:10px;">
  298. <div class="upload-container" id="imgView">
  299. <div
  300. v-for="(item, index) in pictureArray"
  301. :key="item"
  302. class="image-preview image-app-preview"
  303. >
  304. <div class="image-preview-wrapper">
  305. <img :src="`${hostUrl}/${item.filePath}`" />
  306. <div class="image-preview-action">
  307. <i @click="removeFile(item.id)" class="el-icon-delete"></i>
  308. </div>
  309. </div>
  310. </div>
  311. </div>
  312. </div>
  313. </el-row>
  314. </el-tab-pane>
  315. <el-tab-pane :label="audiotabName">
  316. <el-table border :data="audioArray" style="width: 100%;margin: 0 auto;">
  317. <el-table-column header-align="center" align="center" label="音频">
  318. <template slot-scope="scope">
  319. <elaudio
  320. style="margin-left:15%;width:100px;height:30px;"
  321. :theUrl="`${hostUrl}/${scope.row.filePath}`"
  322. ></elaudio>
  323. <!-- <span>{{scope.row.fileTitle}}</span> -->
  324. </template>
  325. </el-table-column>
  326. <el-table-column header-align="center" align="center" label="操作">
  327. <template slot-scope="scope">
  328. <el-button
  329. size="mini"
  330. @click="removeFile(scope.row.id,scope.$index)"
  331. type="danger"
  332. >删除</el-button>
  333. </template>
  334. </el-table-column>
  335. </el-table>
  336. </el-tab-pane>
  337. <el-tab-pane :label="videotabName">
  338. <el-table border :data="videoArray" style="width: 100%;margin: 0 auto;">
  339. <el-table-column header-align="center" align="center" label="视频">
  340. <template slot-scope="scope">
  341. <!-- <span>{{scope.row.fileTitle}}</span> -->
  342. <video-player
  343. class="vjs-custom-skin"
  344. ref="videoPlayer"
  345. :options="scope.row"
  346. :playsinline="true"
  347. ></video-player>
  348. </template>
  349. </el-table-column>
  350. <el-table-column header-align="center" align="center" label="操作">
  351. <template slot-scope="scope">
  352. <el-button
  353. size="mini"
  354. @click="removeFile(scope.row.id,scope.$index)"
  355. type="danger"
  356. >删除</el-button>
  357. </template>
  358. </el-table-column>
  359. </el-table>
  360. </el-tab-pane>
  361. <el-tab-pane :label="filetabName">
  362. <el-table border :data="fileArray" style="width: 100%;margin: 0 auto;">
  363. <el-table-column header-align="center" align="center" label="文档">
  364. <template slot-scope="scope">
  365. <p>
  366. <a :href="`${hostUrl}/${scope.row.filePath}`" target="_blank" rel="noopener noreferrer">
  367. {{scope.row.fileName}}
  368. </a>
  369. </p>
  370. </template>
  371. </el-table-column>
  372. <el-table-column header-align="center" align="center" label="操作">
  373. <template slot-scope="scope">
  374. <el-button
  375. size="mini"
  376. @click="removeFile(scope.row.id,scope.$index)"
  377. type="danger"
  378. >删除</el-button>
  379. </template>
  380. </el-table-column>
  381. </el-table>
  382. </el-tab-pane>
  383. </el-tabs>
  384. </div>
  385. <!-- <upload ref="changeUploadFile" :url="`/pdcApi/file/insert?bizId=`" @uploadOver="removeNewSupervision"></upload> -->
  386. </div>
  387. <span slot="footer">
  388. <el-button type="primary" @click="changeSupervisionInfo">保存</el-button>
  389. <el-button @click="changeSupervisionVisiblefalse">取消</el-button>
  390. </span>
  391. </el-dialog>
  392. <!-- 删除的弹窗 -->
  393. <el-dialog
  394. class="deleteDialog"
  395. title="问题删除描述"
  396. :visible.sync="problemDeleteVisible"
  397. :append-to-body="true"
  398. >
  399. <Problem-delete
  400. ref="deleteMiaoShu"
  401. :deleteProblemId="deleteId"
  402. @deleteSuccess="deleteSuccess"
  403. ></Problem-delete>
  404. <span slot="footer">
  405. <el-button @click="problemDeleteVisible = false">返回</el-button>
  406. </span>
  407. </el-dialog>
  408. </el-dialog>
  409. </div>
  410. </template>
  411. <script>
  412. //这里可以导入其他文件(比如:组件,工具js,第三方插件js,json文件,图片文件等等)
  413. //例如:import 《组件名称》 from '《组件路径》';
  414. import {
  415. findPageInfoShuiKu,
  416. getShuiKuWenTi,
  417. getXSKProblemNewExport,
  418. findPageInfo,
  419. getSzwtTable,
  420. removeSupervise,
  421. showDetailsXq,
  422. submitUpload,
  423. creatSupervise,
  424. getSupervisdByID,
  425. deleteFileById,
  426. updatelist,
  427. getEngId
  428. } from "../../api/duChaAPI.js";
  429. import request from "../../utils/gw_ajax_request.js";
  430. import elaudio from "../../widgets/elAudioShort.vue";
  431. import inuptWithDuChaTreeNode from "../../widgets/inuptWithDuChaTreeNode.vue";
  432. import inputWidthDuChaNodes from "../../widgets/inputWithDuChaNodes.vue";
  433. import inputWidthDuChaShuiKu from "../../widgets/inputWith_sk.vue";
  434. import {hostUrl} from "@util/global_variable.js";
  435. import Viewer from 'viewerjs';
  436. import 'viewerjs/dist/viewer.css';
  437. export default {
  438. //import引入的组件需要注入到对象中才能使用
  439. components: {
  440. //详情页
  441. supervisionDetails: resolve => {
  442. require(["../duChaWenTi/supervisionDetails_shuiku.vue"], resolve);
  443. },
  444. upload: resolve => {
  445. require(["../../widgets/uploadFile.vue"], resolve);
  446. },
  447. // 删除描述页
  448. ProblemDelete: resolve => {
  449. require(["../duChaWenTi/problemDelete.vue"], resolve);
  450. },
  451. elaudio: elaudio,
  452. inuptWithDuChaTreeNode: inuptWithDuChaTreeNode,
  453. inputWidthDuChaNodes: inputWidthDuChaNodes,
  454. inputWidthDuChaShuiKu: inputWidthDuChaShuiKu
  455. },
  456. props: ["activedName", "currentResCode", "showProblemList", "problData"],
  457. data() {
  458. //这里存放数据
  459. return {
  460. tableHeight: window.innerHeight - 450,
  461. supervisionState: [
  462. {
  463. value: "0",
  464. label: "一般"
  465. },
  466. {
  467. value: "1",
  468. label: "较重"
  469. },
  470. {
  471. value: "2",
  472. label: "严重"
  473. },
  474. {
  475. value: "3",
  476. label: "特别严重"
  477. }
  478. ],
  479. supervision: [
  480. {
  481. value: "1",
  482. label: "是"
  483. },
  484. {
  485. value: "0",
  486. label: "否"
  487. }
  488. ],
  489. updateIdXiuGai: "",
  490. pblmId: "",
  491. addPicPanel: false,
  492. supervisionDetailsVisible: false,
  493. currentProblemId: "",
  494. currentPage: 1, // 页码
  495. pageSize: 20,
  496. loading: false,
  497. total: 0, // 总数
  498. searchResult: [], // 结果
  499. userId: localStorage.getItem("userid"),
  500. pictureArray: [],
  501. audioArray: [],
  502. videoArray: [],
  503. fileArray: [],
  504. audiotabName: "",
  505. videotabName: "",
  506. filetabName:"",
  507. picturetabName: "",
  508. deleteId: "",
  509. playerOptions: {
  510. height: "120",
  511. autoplay: true,
  512. muted: true,
  513. language: "en",
  514. playbackRates: [0.7, 1.0, 1.5, 2.0],
  515. sources: [
  516. {
  517. type: "video/mp4",
  518. // mp4
  519. src: "http://vjs.zencdn.net/v/oceans.mp4"
  520. // webm
  521. // src: "https://cdn.theguardian.tv/webM/2015/07/20/150716YesMen_synd_768k_vp8.webm"
  522. },
  523. {
  524. type: "video/mp4",
  525. // mp4
  526. src: "http://vjs.zencdn.net/v/oceans.mp4"
  527. // webm
  528. // src: "https://cdn.theguardian.tv/webM/2015/07/20/150716YesMen_synd_768k_vp8.webm"
  529. },
  530. {
  531. type: "video/mp4",
  532. // mp4
  533. src: "http://vjs.zencdn.net/v/oceans.mp4"
  534. // webm
  535. // src: "https://cdn.theguardian.tv/webM/2015/07/20/150716YesMen_synd_768k_vp8.webm"
  536. },
  537. {
  538. type: "video/mp4",
  539. // mp4
  540. src: "http://vjs.zencdn.net/v/oceans.mp4"
  541. // webm
  542. // src: "https://cdn.theguardian.tv/webM/2015/07/20/150716YesMen_synd_768k_vp8.webm"
  543. }
  544. ]
  545. },
  546. changeSupervisionVisible: false,
  547. changeSupervisionLoading: false,
  548. changeSupervision: {
  549. nm: "",
  550. presId: localStorage.getItem("userid"),
  551. endTime: "",
  552. pblmId: "",
  553. objId: "",
  554. objType: "",
  555. inspGroupId: "",
  556. inspPblmName: "",
  557. inspPblmDesc: "",
  558. pblmLong: "",
  559. pblmLat: "",
  560. pblmStat: "",
  561. ifCasePblm: "",
  562. inspPblmOrgName: "",
  563. pblmPersName: "",
  564. inspPblmCate: "",
  565. reviOpin: "",
  566. reviConc: "",
  567. reviOrgGuid: "",
  568. collTime: "",
  569. recPers: "",
  570. gwComFiles: [
  571. {
  572. id: "",
  573. filePath: "",
  574. bizId: ""
  575. }
  576. ]
  577. },
  578. // 文件弹框
  579. fileList: [], // 当前文件列表
  580. flash: false,
  581. // 督查类型
  582. supervisionTypeList: [
  583. {
  584. value: "1",
  585. label: "小水库"
  586. }
  587. ],
  588. leibie: [],
  589. // 查询
  590. value6: [],
  591. findParams: {
  592. hasVedio: "",
  593. adCode: "",
  594. pblmStat: "",
  595. inspPblmCate: "",
  596. ifCasePblm: "",
  597. nm: "",
  598. rsName: "",
  599. adFullName: "",
  600. startTime: "",
  601. endTime: "",
  602. objType: 1,
  603. inspPblmName: "",
  604. persId: localStorage.getItem("userid")
  605. },
  606. currentPage: 1, // 页码
  607. pageSize: 20, // 条数
  608. loading: false,
  609. total: 0, // 总数
  610. searchResult: [], // 结果
  611. crId: "", // 当前督查id
  612. // 督查详情
  613. userid: localStorage.getItem("userid"),
  614. supervisionDetailsVisible: false,
  615. problemDeleteVisible: false,
  616. supervisionDetails: {},
  617. pblmId: "",
  618. gwComFiles: [],
  619. pblscr: "",
  620. pblscrList: [
  621. {
  622. lable: "我的问题",
  623. value: localStorage.getItem("userid")
  624. }
  625. ],
  626. pblscrGroup: ""
  627. };
  628. },
  629. //监听属性 类似于data概念
  630. computed: {
  631. hostUrl() {
  632. return hostUrl
  633. }
  634. },
  635. //监控data中的数据变化
  636. watch: {
  637. activedName() {
  638. this.search();
  639. },
  640. currentResCode(oldValue, newValue) {
  641. this.currentResCode = newValue;
  642. this.search();
  643. }
  644. },
  645. //方法集合
  646. methods: {
  647. handleSizeChange(pageSize) {
  648. this.pageSize = pageSize;
  649. this.search();
  650. },
  651. // 查询
  652. search() {
  653. this.loading = true;
  654. let _self = this;
  655. let data = {};
  656. data["gateName"] = "";
  657. data["inspPblmName"] = "";
  658. data["objType"] = 6;
  659. data["persId"] = _self.userId;
  660. data["pageNum"] = _self.currentPage;
  661. data["recPers"] = _self.userId;
  662. data["pageSize"] = _self.pageSize;
  663. data["villType"] = "7";
  664. data["codes"] = _self.currentResCode;
  665. let quesId = this.problData;
  666. // getSzwtTable(data).then(res => {
  667. request
  668. .get(`/dc/insp/pblm/getPblmList/${quesId}/${data.objType}`)
  669. .then(res => {
  670. _self.loading = false;
  671. if (res.success) {
  672. _self.searchResult = res.data;
  673. //_self.total = res.data.total;
  674. } else {
  675. this.$message("暂无数据");
  676. }
  677. });
  678. },
  679. //add by lch 关闭问题列表
  680. closeProblemList() {
  681. this.showProblemList = false;
  682. this.$emit("dialogFormVisible", this.showProblemList);
  683. },
  684. timestampToTime(row, column) {
  685. var date = new Date(row.collTime);
  686. var Y = date.getFullYear() + "-";
  687. var M =
  688. (date.getMonth() + 1 < 10
  689. ? "0" + (date.getMonth() + 1)
  690. : date.getMonth() + 1) + "-";
  691. var D =
  692. (date.getDate() < 10 ? "0" + date.getDate() : date.getDate()) + " ";
  693. var h =
  694. (date.getHours() < 10 ? "0" + date.getHours() : date.getHours()) + ":";
  695. var m =
  696. date.getMinutes() < 10 ? "0" + date.getMinutes() : date.getMinutes();
  697. return Y + M + D + h + m;
  698. },
  699. // 详情弹框
  700. showDetails(id) {
  701. this.currentProblemId = id;
  702. this.supervisionDetailsVisible = true;
  703. },
  704. // 修改弹窗显示
  705. changeSup(id) {
  706. this.pictureArray = [];
  707. this.audioArray = [];
  708. this.videoArray = [];
  709. this.fileArray = [];
  710. this.updateIdXiuGai = id;
  711. var _this = this;
  712. showDetailsXq(this.updateIdXiuGai).then(res => {
  713. // if(this.usersId==)
  714. this.changeSupervision = res.data;
  715. this.changeSupervisionVisible = true;
  716. res.data.gwComFiles.forEach(item => {
  717. if (
  718. item.fileExt == "mp3" ||
  719. item.fileExt == "MP3" ||
  720. item.fileExt == "m4a"
  721. ) {
  722. this.audioArray.push(item);
  723. } else if (
  724. item.fileExt == "jpg" ||
  725. item.fileExt == "JPG" ||
  726. item.fileExt == "png" ||
  727. item.fileExt == "PNG" ||
  728. item.fileExt == "JPEG" ||
  729. item.fileExt == "jpeg"
  730. ) {
  731. this.pictureArray.push(item);
  732. } else if (item.fileExt == "mp4" || item.fileExt == "MP4") {
  733. this.videoArray.push({
  734. id: item.id,
  735. bizId: item.bizId,
  736. width: "130",
  737. height: "130",
  738. autoplay: false,
  739. muted: true,
  740. language: "en",
  741. playbackRates: [0.7, 1.0, 1.5, 2.0],
  742. sources: [
  743. {
  744. type: "video/mp4",
  745. // mp4
  746. src: `${this.hostUrl}/${item.filePath}`,
  747. // webm
  748. // src: "https://cdn.theguardian.tv/webM/2015/07/20/150716YesMen_synd_768k_vp8.webm"
  749. }
  750. ]
  751. });
  752. }else{
  753. this.fileArray.push(item);
  754. }
  755. });
  756. _this.$nextTick(function(){
  757. var ViewerDom = document.getElementById('imgView');
  758. var viewer = new Viewer(ViewerDom, {})
  759. });
  760. this.picturetabName = "图片资料(" + this.pictureArray.length + ")";
  761. this.audiotabName = "音频资料(" + this.audioArray.length + ")";
  762. this.videotabName = "视频资料(" + this.videoArray.length + ")";
  763. this.filetabName = "其它资料(" + this.fileArray.length + ")";
  764. });
  765. },
  766. // 提交修改信息
  767. changeSupervisionInfo() {
  768. this.changeSupervisionVisible = true;
  769. this.$refs.changeSupFrom.validate(valid => {
  770. if (valid) {
  771. this.changeSupervisionLoading = true;
  772. let data = this.changeSupervision;
  773. updatelist(data).then(res => {
  774. this.pblmId = res.data.pblmId;
  775. this.gwComFiles = res.data.gwComFiles;
  776. if (res.success) {
  777. this.removeNewSupervision();
  778. this.successInfo();
  779. if (this.$refs.uploadFile.submitUpload(data.pblmId)) {
  780. this.removeNewSupervision();
  781. this.successInfo();
  782. this.addPicPanel = false;
  783. this.changeSupervisionLoading = false;
  784. }
  785. } else {
  786. this.failInfo();
  787. }
  788. });
  789. }
  790. });
  791. },
  792. removeNewSupervision(arg) {
  793. if (arg) {
  794. console.log(arg);
  795. var args = this.gwComFiles.concat(arg);
  796. this.updatefilelist(args);
  797. }
  798. this.search();
  799. this.gwComFiles = [];
  800. this.newSupervisionVisible = false;
  801. this.changeSupervisionVisible = false;
  802. this.newSupervision = {
  803. id: "",
  804. checkPoint: "",
  805. presId: localStorage.getItem("userid"),
  806. dataStat: "",
  807. nm: "",
  808. endTime: "",
  809. pblmId: "",
  810. objId: "",
  811. objType: "",
  812. inspGroupId: "",
  813. inspPblmCate: "",
  814. inspPblmName: "",
  815. inspPblmDesc: "",
  816. pblmLong: "",
  817. pblmLat: "",
  818. pblmStat: "",
  819. ifCasePblm: "",
  820. inspPblmOrgName: "",
  821. pblmPersName: "",
  822. inspPblmCate: "",
  823. reviOpin: "",
  824. reviConc: "",
  825. reviOrgGuid: "",
  826. collTime: "",
  827. recPers: "",
  828. note: ""
  829. };
  830. // this.$refs.uploadFile.init();
  831. },
  832. // 删除图片文件
  833. removeFile(id, index) {
  834. // this.updateIdXiuGai = this.updateIdXiuGai;
  835. var _self = this;
  836. this.$confirm("此操作将永久删除该文件, 是否继续?", "提示", {
  837. confirmButtonText: "确定",
  838. cancelButtonText: "返回",
  839. type: "warning"
  840. }).then(
  841. res => {
  842. if (res === "confirm") {
  843. deleteFileById(id, this.userId).then(res => {
  844. if (res.success) {
  845. // this.changeSupervision.gwComFiles.splice(index, 1);
  846. this.changeSupervision.gwComFiles.forEach(item => {
  847. if (
  848. item.fileExt == "mp3" ||
  849. item.fileExt == "MP3" ||
  850. item.fileExt == "m4a"
  851. ) {
  852. this.audiotabName.splice(index, 1);
  853. } else if (
  854. item.fileExt == "jpg" ||
  855. item.fileExt == "JPG" ||
  856. item.fileExt == "png" ||
  857. item.fileExt == "PNG" ||
  858. item.fileExt == "JPEG" ||
  859. item.fileExt == "jpeg"
  860. ) {
  861. this.pictureArray.splice(index, 1);
  862. } else if (item.fileExt == "mp4" || item.fileExt == "MP4") {
  863. this.videoArray.splice(index, 1);
  864. }
  865. });
  866. _self.changeSup(this.updateIdXiuGai);
  867. } else {
  868. this.failInfo();
  869. }
  870. });
  871. }
  872. },
  873. res => {
  874. console.log("返回");
  875. }
  876. );
  877. },
  878. // 操作成功反馈
  879. successInfo() {
  880. this.$message({
  881. type: "success",
  882. message: "操作成功!"
  883. });
  884. },
  885. // 操作失败反馈
  886. failInfo(val) {
  887. this.$message.error(val);
  888. },
  889. // 清空选择
  890. toggleSelection(rows) {
  891. this.$refs.multipleTable.clearSelection();
  892. },
  893. // 已选择项
  894. handleSelectionChange(val) {
  895. this.multipleSelection = val;
  896. },
  897. // 文件上传
  898. submitUpload() {
  899. this.$refs.upload.submit();
  900. },
  901. handleRemove(file, fileList) {
  902. console.log(file, fileList);
  903. },
  904. handlePreview(file) {
  905. console.log(file);
  906. },
  907. addPic() {
  908. this.addPicPanel = !this.addPicPanel;
  909. },
  910. // 删除弹窗
  911. removeSuperviseOne(id) {
  912. this.deleteId = id;
  913. this.problemDeleteVisible = true;
  914. },
  915. deleteSuccess() {
  916. this.problemDeleteVisible = false;
  917. this.search();
  918. },
  919. changeSupervisionVisiblefalse() {
  920. this.$nextTick(() => {
  921. if (this.flash) {
  922. this.flash = false;
  923. this.search();
  924. }
  925. });
  926. this.changeSupervisionVisible = false;
  927. this.changeSupervision = {
  928. dataStat: "",
  929. nm: "",
  930. endTime: "",
  931. pblmId: "",
  932. objId: "",
  933. objType: "",
  934. inspGroupId: "",
  935. inspPblmCate: "",
  936. inspPblmName: "",
  937. inspPblmDesc: "",
  938. pblmLong: "",
  939. pblmLat: "",
  940. pblmStat: "",
  941. ifCasePblm: "",
  942. inspPblmOrgName: "",
  943. pblmPersName: "",
  944. inspPblmCate: "",
  945. reviOpin: "",
  946. reviConc: "",
  947. reviOrgGuid: "",
  948. collTime: "",
  949. recPers: "",
  950. note: "",
  951. gwComFiles: [
  952. {
  953. id: "",
  954. filePath: "",
  955. bizId: ""
  956. }
  957. ]
  958. };
  959. this.$refs.uploadFile.init();
  960. this.addPicPanel = false;
  961. }
  962. },
  963. //生命周期 - 创建完成(可以访问当前this实例)
  964. created() {
  965. this.addPicPanel = false;
  966. if (this.userId) {
  967. console.log("已经登录");
  968. this.search();
  969. } else {
  970. this.$router.push("/login");
  971. }
  972. },
  973. //生命周期 - 挂载完成(可以访问DOM元素)
  974. mounted() {
  975. this.search();
  976. },
  977. beforeCreate() {}, //生命周期 - 创建之前
  978. beforeMount() {}, //生命周期 - 挂载之前
  979. beforeUpdate() {}, //生命周期 - 更新之前
  980. updated() {}, //生命周期 - 更新之后
  981. beforeDestroy() {}, //生命周期 - 销毁之前
  982. destroyed() {}, //生命周期 - 销毁完成
  983. activated() {} //如果页面有keep-alive缓存功能,这个函数会触发
  984. };
  985. </script>
  986. <style rel="stylesheet/scss" lang="scss" scoped>
  987. @import "../duChaWenTi/base.css";
  988. @import url("/src/assets/iconfont/iconfont.css");
  989. @import url("/src/assets/css/mixin.scss");
  990. .upload-container {
  991. width: 100%;
  992. position: relative;
  993. .image-uploader {
  994. width: 35%;
  995. float: left;
  996. }
  997. .image-preview {
  998. width: 200px;
  999. height: 200px;
  1000. position: relative;
  1001. border: 1px dashed #d9d9d9;
  1002. float: left;
  1003. // margin-left: 50px;
  1004. .image-preview-wrapper {
  1005. position: relative;
  1006. width: 100%;
  1007. height: 100%;
  1008. img {
  1009. width: 100%;
  1010. height: 100%;
  1011. }
  1012. }
  1013. .image-preview-action {
  1014. position: absolute;
  1015. width: 100%;
  1016. height: 30px;
  1017. left: 0;
  1018. bottom: 0;
  1019. cursor: default;
  1020. text-align: center;
  1021. color: #fff;
  1022. opacity: 0;
  1023. font-size: 20px;
  1024. background-color: rgba(0, 0, 0, 0.5);
  1025. transition: opacity 0.3s;
  1026. cursor: pointer;
  1027. text-align: center;
  1028. line-height: 30px;
  1029. .el-icon-delete {
  1030. font-size: 25px;
  1031. }
  1032. }
  1033. &:hover {
  1034. .image-preview-action {
  1035. opacity: 1;
  1036. }
  1037. }
  1038. }
  1039. .image-app-preview {
  1040. margin-bottom: 10px;
  1041. width: 40vh;
  1042. height: 180px;
  1043. position: relative;
  1044. border: 1px dashed #d9d9d9;
  1045. float: left;
  1046. // margin-left: 50px;
  1047. .app-fake-conver {
  1048. height: 44px;
  1049. position: absolute;
  1050. width: 100%; // background: rgba(0, 0, 0, .1);
  1051. text-align: center;
  1052. line-height: 64px;
  1053. color: #fff;
  1054. }
  1055. }
  1056. }
  1057. .bottom {
  1058. margin-top: 13px;
  1059. line-height: 12px;
  1060. }
  1061. .button {
  1062. padding: 0;
  1063. float: right;
  1064. }
  1065. .image {
  1066. width: 100%;
  1067. display: block;
  1068. }
  1069. .clearfix:before,
  1070. .clearfix:after {
  1071. display: table;
  1072. content: "";
  1073. }
  1074. .clearfix:after {
  1075. clear: both;
  1076. }
  1077. #wenTiContainer_sk .el-tree-node {
  1078. /* overflow: auto; */
  1079. }
  1080. #wenTiContainer_sk .el-tree-node > .el-tree-node__children {
  1081. overflow: auto;
  1082. }
  1083. .shuiku .el-date-editor.el-input {
  1084. min-width: 180px !important;
  1085. }
  1086. .shuiku .header {
  1087. padding: 0px 10px;
  1088. }
  1089. .shuiku .el-row {
  1090. margin-bottom: 5px;
  1091. }
  1092. .shuiku .content {
  1093. margin: 10px;
  1094. }
  1095. /* .search .el-table>>>.el-tooltip {
  1096. white-space: pre-wrap !important;
  1097. line-height: 30px;
  1098. font-size: 0;
  1099. } */
  1100. .shuiku .search >>> .el-table .el-button:nth-child(odd) {
  1101. margin-left: 0 !important;
  1102. }
  1103. .custom_dialog .el-dialog {
  1104. width: 60% !important;
  1105. }
  1106. .custom_dialog .scroll300 {
  1107. max-height: 60vh !important;
  1108. }
  1109. .shuiku .el-tag + .el-tag {
  1110. margin-left: 10px;
  1111. }
  1112. .shuiku .button-new-tag {
  1113. margin-left: 10px;
  1114. height: 28px;
  1115. line-height: 28px;
  1116. padding-top: 0;
  1117. padding-bottom: 0;
  1118. }
  1119. .shuiku .input-new-tag {
  1120. width: 90px;
  1121. margin-left: 10px;
  1122. vertical-align: bottom;
  1123. }
  1124. </style>