fc7d4c8cd8c7a1dd0f6f83bc56a5f8f4d7b918df.svn-base 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356
  1. <template>
  2. <div id="eventDetailBody" style="padding: 3px;position: relative;" :style="{'height':testHeight+'px',}" class="problem_detail_wrapper">
  3. <div :style="{'height':testHeight+'px',}" style="width:46%;float:left;border:1px solid #d5d5ff;margin-right:5px;">
  4. <p style="font-weight:bolder;background-color:#d5d5ff;padding:3px;">基本信息</p>
  5. <el-form label-position="right" label-width="120px" :style="{'max-height':testHeight-30+'px',}"
  6. style="overflow-y: auto;height:100%;margin:5px;" :model="problemDetail">
  7. <el-form-item label="对象名称">
  8. <p style="font-weight: bold;border-bottom:1px dashed rgb(198, 226, 255);">{{ problemDetail.nm }}</p>
  9. <!-- <el-input v-model="problemDetail.nm" :disabled="true"></el-input> -->
  10. </el-form-item>
  11. <el-form-item label="问题类别:">
  12. <p style="font-weight: bold;border-bottom:1px dashed rgb(198, 226, 255);">
  13. {{ problemDetail.inspPblmsName }}</p>
  14. <!-- <el-input v-model="problemDetail.inspPblmsName"></el-input> -->
  15. </el-form-item>
  16. <el-form-item label="检查项目:">
  17. <p style="font-weight: bold;border-bottom:1px dashed rgb(198, 226, 255);">{{ problemDetail.checkPoint }}</p>
  18. <!-- <el-input v-model="problemDetail.checkPoint"></el-input> -->
  19. </el-form-item>
  20. <el-form-item label="问题描述:">
  21. <p style="font-weight: bold;border-bottom:1px dashed rgb(198, 226, 255);">{{ problemDetail.pblmDesc }}</p>
  22. <!-- <el-input v-model="problemDetail.pblmDesc"></el-input> -->
  23. </el-form-item>
  24. <el-form-item label="详情" style=" text-align:left">
  25. <span style="font-size: 12px">{{problemDetail.pblmDesc}}</span>
  26. </el-form-item>
  27. <el-form-item label="问题依据" style=" text-align:left">
  28. <span style="font-size: 12px">{{problemDetail.relBasis}}</span>
  29. </el-form-item>
  30. <el-form-item label="严重程度:">
  31. <span
  32. style="padding: 3px 10px;background:#27C19F;border-radius:15px;color:rgba(255,255,255,1)"
  33. v-if="problemDetail.inspPblmCate == 0"
  34. >一般</span>
  35. <span
  36. style="padding: 3px 10px;background:#E6A23C;border-radius:15px;color:rgba(255,255,255,1)"
  37. v-if="problemDetail.inspPblmCate == 1"
  38. >较重</span>
  39. <span
  40. style="padding: 3px 10px;background:#F56C6C;border-radius:15px;color:rgba(255,255,255,1)"
  41. v-if="problemDetail.inspPblmCate == 2"
  42. >严重</span>
  43. <span
  44. style="padding: 3px 10px;background:#F56C6C;border-radius:15px;color:rgba(255,255,255,1)"
  45. v-if="problemDetail.inspPblmCate == 3"
  46. >特别严重</span>
  47. </el-form-item>
  48. <el-form-item label="是否为典型问题:">
  49. <span v-if="problemDetail.ifCasePblm == 1">典型</span>
  50. <span v-if="problemDetail.ifCasePblm == 0">非典型</span>
  51. </el-form-item>
  52. <el-form-item label="处理状态:">
  53. <span v-if="problemDetail.pblmStat == 1">已上报</span>
  54. <span v-else-if="problemDetail.pblmStat == 0">未上报</span>
  55. </el-form-item>
  56. <!-- <el-form-item label="处理状态:">
  57. <span
  58. style="padding: 3px 10px;background:#27C19F;border-radius:15px;color:rgba(255,255,255,1)"
  59. v-if="problemDetail.pblmStat == 0"
  60. >未督查</span>
  61. <span
  62. style="padding: 3px 10px;background:#E6A23C;border-radius:15px;color:rgba(255,255,255,1)"
  63. v-if="problemDetail.pblmStat == 1"
  64. >督查中</span>
  65. <span
  66. style="padding: 3px 10px;background:#F56C6C;border-radius:15px;color:rgba(255,255,255,1)"
  67. v-if="problemDetail.state == 2"
  68. >严重</span>
  69. </el-form-item> -->
  70. <el-form-item label="详细描述:">
  71. <p style="font-weight: bold;border-bottom:1px dashed rgb(198, 226, 255);">{{ problemDetail.inspPblmDesc }}</p>
  72. <!-- <el-input v-model="problemDetail.pblmDesc"></el-input> -->
  73. </el-form-item>
  74. <el-form-item label="备注:">
  75. <p style="font-weight: bold;border-bottom:1px dashed rgb(198, 226, 255);;">{{ problemDetail.note }}</p>
  76. <!-- <el-input v-model="problemDetail.note"></el-input> -->
  77. </el-form-item>
  78. <el-form-item label="上报人:">
  79. <p style="font-weight: bold;border-bottom:1px dashed rgb(198, 226, 255);;">{{ problemDetail.persName }}</p>
  80. <!-- <el-input v-model="problemDetail.persName"></el-input> -->
  81. </el-form-item>
  82. </el-form>
  83. </div>
  84. <div :style="{'height':testHeight+'px',}" style="width:50%;float:left;border:1px solid #d5d5ff;">
  85. <p style="font-weight:bolder;background-color:#d5d5ff;padding:3px;">多媒体信息</p>
  86. <el-tabs style="overflow-y: auto;margin:5px;" :style="{'max-height':testHeight-40 +'px',}">
  87. <el-tab-pane :label="picturetabName" style="height: 350px;">
  88. <el-carousel :interval="4000" height="350px" id="detailImg">
  89. <el-carousel-item v-for="(item,index) in pictureArray" :key="index">
  90. <!-- <a :href="item.filePath" target="_blank" v-if="item.filePath.indexOf('http')>-1">-->
  91. <img style="height:100%;" :src="item.filePath" alt v-if="item.filePath.indexOf('http')>-1">
  92. <!-- </a>-->
  93. <!-- <a :href="`${hostUrl}/${item.filePath}`" target="_blank" v-if="item.filePath.indexOf('http')<0">-->
  94. <img style="height:100%;" :src="`${hostUrl}/${item.filePath}`" alt v-if="item.filePath.indexOf('http')<0">
  95. <!-- </a>-->
  96. </el-carousel-item>
  97. <el-carousel-item v-if="pictureArray.length==0">
  98. <p>暂无图片信息</p>
  99. </el-carousel-item>
  100. </el-carousel>
  101. </el-tab-pane>
  102. <el-tab-pane :label="audiotabName">
  103. <elaudio v-for="(audio,index) in audioArray" :key="index" style="margin-left:15%"
  104. :theUrl="`${hostUrl}/${audio.filePath}`"></elaudio>
  105. <p v-if="audioArray.length==0">暂无音频信息</p>
  106. </el-tab-pane>
  107. <el-tab-pane :label="videotabName">
  108. <el-carousel :interval="4000" height="350px">
  109. <el-carousel-item v-for="(item,index) in videoArray" :key="index">
  110. <video-player class="vjs-custom-skin" ref="videoPlayer" :options="item"
  111. :playsinline="true" ></video-player>
  112. </el-carousel-item>
  113. <el-carousel-item v-if="videoArray.length==0">
  114. <p>暂无视频信息</p>
  115. </el-carousel-item>
  116. </el-carousel>
  117. </el-tab-pane>
  118. <el-tab-pane :label="filetabName">
  119. <el-table border :data="fileArray" style="width: 100%;margin: 0 auto;">
  120. <el-table-column header-align="center" align="center" label="文档">
  121. <template slot-scope="scope">
  122. <p>
  123. <a :href="`${hostUrl}/${scope.row.filePath}`" target="_blank" rel="noopener noreferrer">
  124. {{ scope.row.fileName }}
  125. </a>
  126. </p>
  127. </template>
  128. </el-table-column>
  129. </el-table>
  130. </el-tab-pane>
  131. </el-tabs>
  132. </div>
  133. </div>
  134. </template>
  135. <script>
  136. import Viewer from 'viewerjs';
  137. import 'viewerjs/dist/viewer.css';
  138. import {
  139. deleteFileById,
  140. getsuperviseinspect,
  141. getFileByBiz,
  142. getSuperviseGroup,
  143. showDetailsXq,
  144. } from "../../api/duChaAPI.js";
  145. import {hostUrl} from "@util/global_variable.js";
  146. // import elaudio from '../widgets/elAudio.vue'
  147. export default {
  148. props: ["details", 'problemId', 'objType'],
  149. components: {
  150. elaudio: resolve => {
  151. require(["../../widgets/elAudio.vue"], resolve);
  152. },
  153. },
  154. data() {
  155. return {
  156. testHeight: window.innerHeight * 0.6,
  157. activeName: "0",
  158. superviseinspect: {},
  159. fileList: [],
  160. groupingList: [],
  161. fileListloading: false,
  162. groupListloading: false,
  163. problemDetail: {
  164. checkPoint: '',
  165. collTime: '',
  166. commonFileIds: '',
  167. cwsCode: '',
  168. cwsName: '',
  169. dataStat: '',
  170. endTime: '',
  171. fileNo: '',
  172. fileNoNumber: '',
  173. gwComFiles: '',
  174. ifCasePblm: '',
  175. inspAddDesc: '',
  176. inspGroupId: '',
  177. inspPblmCate: '',
  178. inspPblmCode: '',
  179. inspPblmDesc: '',
  180. inspPblmName: '',
  181. inspPblmOrgName: '',
  182. inspPblmType: '',
  183. inspPblmsName: '',
  184. nm: '',
  185. note: '',
  186. objId: '',
  187. objNm: '',
  188. objType: '',
  189. pblmDesc: '',
  190. pblmId: '',
  191. pblmLat: '',
  192. pblmLong: '',
  193. pblmPersName: '',
  194. pblmStat: '',
  195. pblmsId: '',
  196. pblmsTypeId: '',
  197. persName: '',
  198. pguid: '',
  199. recPers: '',
  200. regid: '',
  201. reviConc: '',
  202. reviOpin: '',
  203. reviOrgGuid: '',
  204. srcDesc: '',
  205. startTime: '',
  206. state: '',
  207. villType: '',
  208. villageCode: '',
  209. },
  210. pictureArray: [],
  211. audioArray: [],
  212. videoArray: [],
  213. fileArray: [],
  214. audiotabName: "",
  215. videotabName: "",
  216. picturetabName: "",
  217. filetabName: "",
  218. playerOptions: {
  219. height: '120',
  220. autoplay: true,
  221. muted: true,
  222. language: 'en',
  223. playbackRates: [0.7, 1.0, 1.5, 2.0],
  224. labelName: '',
  225. sources: [{
  226. type: "video/mp4",
  227. // mp4
  228. src: "http://vjs.zencdn.net/v/oceans.mp4",
  229. // webm
  230. // src: "https://cdn.theguardian.tv/webM/2015/07/20/150716YesMen_synd_768k_vp8.webm"
  231. },
  232. {
  233. type: "video/mp4",
  234. // mp4
  235. src: "http://vjs.zencdn.net/v/oceans.mp4",
  236. // webm
  237. // src: "https://cdn.theguardian.tv/webM/2015/07/20/150716YesMen_synd_768k_vp8.webm"
  238. },
  239. {
  240. type: "video/mp4",
  241. // mp4
  242. src: "http://vjs.zencdn.net/v/oceans.mp4",
  243. // webm
  244. // src: "https://cdn.theguardian.tv/webM/2015/07/20/150716YesMen_synd_768k_vp8.webm"
  245. },
  246. {
  247. type: "video/mp4",
  248. // mp4
  249. src: "http://vjs.zencdn.net/v/oceans.mp4",
  250. // webm
  251. // src: "https://cdn.theguardian.tv/webM/2015/07/20/150716YesMen_synd_768k_vp8.webm"
  252. }],
  253. },
  254. };
  255. },
  256. computed: {
  257. hostUrl() {
  258. return hostUrl
  259. }
  260. },
  261. mounted: function () {
  262. this.problemDetail = {};
  263. this.pictureArray = [];
  264. this.audioArray = [];
  265. this.videoArray = [];
  266. this.fileArray = [];
  267. this.showDetails();
  268. },
  269. watch: {
  270. problemId: function () {
  271. this.problemDetail = {};
  272. this.pictureArray = [];
  273. this.audioArray = [];
  274. this.videoArray = [];
  275. this.fileArray = [];
  276. this.showDetails();
  277. }
  278. },
  279. methods: {
  280. init() {
  281. this.activeName = "0";
  282. },
  283. showDetails() {
  284. showDetailsXq(this.problemId).then(res => {
  285. this.problemDetail = res.data;
  286. console.log(this.hostUrl);
  287. if (res.data.gwComFiles) {
  288. res.data.gwComFiles.forEach(
  289. (item) => {
  290. if (item.fileExt == 'mp3' || item.fileExt == 'MP3' || item.fileExt == 'm4a') {
  291. this.audioArray.push(item);
  292. } else if (item.fileExt == 'jpg' || item.fileExt == 'JPEG' || item.fileExt == 'jpeg' || item.fileExt == 'JPG' || item.fileExt == 'png' || item.fileExt == 'PNG') {
  293. this.pictureArray.push(item);
  294. this.$nextTick(function(){
  295. var ViewerDom = document.getElementById('detailImg');
  296. var viewer = new Viewer(ViewerDom, {
  297. // hide:function(){ //在图片消失的时候销毁viewer
  298. // viewer.destroy();
  299. // }
  300. })
  301. });
  302. } else if (item.fileExt == 'mp4' || item.fileExt == 'MP4') {
  303. this.videoArray.push(
  304. {
  305. height: '350',
  306. autoplay: false,
  307. muted: true,
  308. language: 'en',
  309. playbackRates: [0.7, 1.0, 1.5, 2.0],
  310. sources: [{
  311. type: "video/mp4",
  312. // mp4
  313. src: `${this.hostUrl}/${item.filePath}`,
  314. // webm
  315. // src: "https://cdn.theguardian.tv/webM/2015/07/20/150716YesMen_synd_768k_vp8.webm"
  316. }],
  317. },
  318. );
  319. } else {
  320. this.fileArray.push(item);
  321. }
  322. }
  323. );
  324. this.picturetabName = "图片资料(" + this.pictureArray.length + ")";
  325. this.audiotabName = "音频资料(" + this.audioArray.length + ")";
  326. this.videotabName = "视频资料(" + this.videoArray.length + ")";
  327. this.filetabName = "其它资料(" + this.fileArray.length + ")";
  328. }
  329. });
  330. },
  331. }
  332. };
  333. </script>
  334. <style scoped>
  335. @import '../../assets/style/global.css';
  336. .el-form-item {
  337. width: 100%;
  338. margin-bottom: 0;
  339. }
  340. </style>