fa82c792c932c819802ff01864e89fa858e1acd3.svn-base 15 KB

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