498717c5dcbd6fbb57e5281651cc8a59010fe530.svn-base 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272
  1. <template>
  2. <div id="eventDetailBody" style="padding: 3px;" :style="{'height':testHeight+'px',}">
  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);min-height: 24px;">{{problemDetail.pblmNm}}</p>
  8. </el-form-item>
  9. <el-form-item label="整改状态:">
  10. <p style="font-weight: bold;border-bottom:1px dashed rgb(198, 226, 255);min-height: 24px;">
  11. <span v-if="problemDetail.rectState == 1">整改中</span>
  12. <span v-if="problemDetail.rectState == 2">未整改</span>
  13. <span v-if="problemDetail.rectState == 3">已整改</span>
  14. <span v-if="problemDetail.rectState == 4">不具备整改条件</span>
  15. </p>
  16. </el-form-item>
  17. <el-form-item label="整改说明:">
  18. <p style="font-weight: bold;border-bottom:1px dashed rgb(198, 226, 255);min-height: 24px;">{{problemDetail.rectExplain}}</p>
  19. </el-form-item>
  20. <el-form-item label="责任单位:">
  21. <p style="font-weight: bold;border-bottom:1px dashed rgb(198, 226, 255);min-height: 24px;">{{problemDetail.rectDept}}</p>
  22. </el-form-item>
  23. <el-form-item label="整改说明:">
  24. <p style="font-weight: bold;border-bottom:1px dashed rgb(198, 226, 255);min-height: 24px;">{{problemDetail.rectExplain}}</p>
  25. </el-form-item>
  26. <el-form-item label="问责方式:">
  27. <p style="font-weight: bold;border-bottom:1px dashed rgb(198, 226, 255);min-height: 24px;">{{problemDetail.rectBlame}}</p>
  28. </el-form-item>
  29. <el-form-item label="督促措施:">
  30. <p style="font-weight: bold;border-bottom:1px dashed rgb(198, 226, 255);min-height: 24px;">{{problemDetail.rectSps}}</p>
  31. </el-form-item>
  32. <el-form-item label="完成时间:">
  33. <p style="font-weight: bold;border-bottom:1px dashed rgb(198, 226, 255);min-height: 24px;">{{formatDate(problemDetail.rectCompTm)}}</p>
  34. </el-form-item>
  35. </el-form>
  36. </div>
  37. <div :style="{'height':testHeight+'px',}" style="width:50%;float:left;border:1px solid #d5d5ff;">
  38. <p style="font-weight:bolder;background-color:#d5d5ff;padding:3px;">多媒体信息</p>
  39. <el-tabs style="overflow-y: auto;margin:5px;" :style="{'max-height':testHeight-40 +'px',}">
  40. <el-tab-pane :label="picturetabName" style="height: 350px;">
  41. <el-carousel :interval="4000" height="350px">
  42. <el-carousel-item v-for="(item,index) in pictureArray" :key="index" >
  43. <a :href="`${hostUrl}${item.filePath}`" target="_blank">
  44. <img style="height:100%;" :src="`${hostUrl}${item.filePath}`" alt>
  45. </a>
  46. </el-carousel-item>
  47. <el-carousel-item v-if="pictureArray.length==0">
  48. <p>暂无图片信息</p>
  49. </el-carousel-item>
  50. </el-carousel>
  51. </el-tab-pane>
  52. <el-tab-pane :label="audiotabName">
  53. <elaudio v-for="(audio,index) in audioArray" :key="index" style="margin-left:15%" :theUrl="`${hostUrl}${audio.filePath}`"></elaudio>
  54. <p v-if="audioArray.length==0">暂无音频信息</p>
  55. </el-tab-pane>
  56. <el-tab-pane :label="videotabName">
  57. <el-carousel :interval="4000" height="350px">
  58. <el-carousel-item v-for="(item,index) in videoArray" :key="index" >
  59. <video-player class="vjs-custom-skin"
  60. ref="videoPlayer"
  61. :options="item"
  62. :playsinline="true"
  63. >
  64. </video-player>
  65. </el-carousel-item>
  66. <el-carousel-item v-if="videoArray.length==0">
  67. <p>暂无视频信息</p>
  68. </el-carousel-item>
  69. </el-carousel>
  70. </el-tab-pane>
  71. <el-tab-pane :label="filetabName">
  72. <el-table border :data="fileArray" style="width: 100%;margin: 0 auto;">
  73. <el-table-column header-align="center" align="center" label="文档">
  74. <template slot-scope="scope">
  75. <p>
  76. <a :href="`${hostUrl}/${scope.row.filePath}`" target="_blank" rel="noopener noreferrer">
  77. {{scope.row.fileName}}
  78. </a>
  79. </p>
  80. </template>
  81. </el-table-column>
  82. </el-table>
  83. </el-tab-pane>
  84. </el-tabs>
  85. </div>
  86. </div>
  87. </template>
  88. <script>
  89. import request from '@util/gw_ajax_request.js'
  90. import { hostUrl } from "@util/global_variable.js";
  91. import {dateFormat} from '@util/gw_date';
  92. export default {
  93. props: ['problemId'],
  94. components: {
  95. elaudio: resolve => {
  96. require(["@widget/elAudio.vue"], resolve);
  97. },
  98. },
  99. data() {
  100. return {
  101. testHeight: window.innerHeight * 0.6,
  102. activeName: "0",
  103. superviseinspect: {},
  104. fileList: [],
  105. groupingList: [],
  106. fileListloading: false,
  107. groupListloading: false,
  108. problemDetail:{
  109. inspPblmDesc:'',
  110. pblmNm:'',
  111. rectState: '',
  112. rectExplain: '',
  113. rectDept: '',
  114. rectBlame:'',
  115. rectSps: '',
  116. rectCompTm: ''
  117. },
  118. pictureArray:[],
  119. audioArray:[],
  120. videoArray:[],
  121. fileArray: [],
  122. audiotabName: "",
  123. videotabName: "",
  124. picturetabName: "",
  125. filetabName: "",
  126. playerOptions: {
  127. height: '120',
  128. autoplay: true,
  129. muted: true,
  130. language: 'en',
  131. playbackRates: [0.7, 1.0, 1.5, 2.0],
  132. sources: [
  133. {
  134. type: "video/mp4",
  135. src: "http://vjs.zencdn.net/v/oceans.mp4",
  136. },
  137. {
  138. type: "video/mp4",
  139. src: "http://vjs.zencdn.net/v/oceans.mp4",
  140. },
  141. {
  142. type: "video/mp4",
  143. src: "http://vjs.zencdn.net/v/oceans.mp4",
  144. },
  145. {
  146. type: "video/mp4",
  147. src: "http://vjs.zencdn.net/v/oceans.mp4",
  148. }
  149. ]
  150. },
  151. };
  152. },
  153. computed:{
  154. hostUrl(){
  155. return hostUrl
  156. }
  157. },
  158. mounted:function(){
  159. this.problemDetail = {};
  160. this.pictureArray = [];
  161. this.audioArray = [];
  162. this.videoArray = [];
  163. this.fileArray = [];
  164. this.showDetails();
  165. },
  166. watch:{
  167. problemId:function(){
  168. this.problemDetail = {};
  169. this.pictureArray = [];
  170. this.audioArray = [];
  171. this.videoArray = [];
  172. this.fileArray = [];
  173. this.showDetails();
  174. }
  175. },
  176. methods: {
  177. init() {
  178. this.activeName = "0";
  179. },
  180. showDetails() {
  181. request.get(`/tac/pblm/rect/pblm/${this.problemId}`).then(res => {
  182. if(res.success){
  183. this.problemDetail = res.data;
  184. if(res.data.gwComFiles){
  185. res.data.gwComFiles.forEach(
  186. (item) =>{
  187. if(item.fileExt == 'mp3'||item.fileExt == 'MP3'||item.fileExt == 'm4a'){
  188. this.audioArray.push(item);
  189. }else if(item.fileExt == 'jpg' || item.fileExt == 'JPEG' || item.fileExt == 'jpeg' || item.fileExt == 'JPG' || item.fileExt == 'png' || item.fileExt == 'PNG'){
  190. this.pictureArray.push(item);
  191. }else if(item.fileExt == 'mp4'||item.fileExt == 'MP4'){
  192. this.videoArray.push(
  193. {
  194. height: '350',
  195. autoplay: false,
  196. muted: true,
  197. language: 'en',
  198. playbackRates: [0.7, 1.0, 1.5, 2.0],
  199. sources: [{
  200. type: "video/mp4",
  201. // mp4
  202. src: `${this.hostUrl}/${item.filePath}`,
  203. // webm
  204. // src: "https://cdn.theguardian.tv/webM/2015/07/20/150716YesMen_synd_768k_vp8.webm"
  205. }],
  206. },
  207. );
  208. } else {
  209. this.fileArray.push(item);
  210. }
  211. }
  212. );
  213. this.picturetabName = "图片资料(" + this.pictureArray.length + ")";
  214. this.audiotabName = "音频资料(" + this.audioArray.length + ")";
  215. this.videotabName = "视频资料(" + this.videoArray.length + ")";
  216. this.filetabName = "其它资料(" + this.fileArray.length + ")";
  217. }
  218. }
  219. });
  220. },
  221. formatDate(timestamp) {
  222. return timestamp ? dateFormat(timestamp, 'yyyy-MM-dd') : "";
  223. }
  224. }
  225. };
  226. </script>
  227. <style scoped>
  228. .name {
  229. background-color: #ebf8ff;
  230. }
  231. .details>>>.el-tabs__content {
  232. height: 360px;
  233. overflow-y: auto;
  234. }
  235. .flexbody>div {
  236. display: flex;
  237. align-items: flex-start;
  238. line-height: 30px;
  239. }
  240. .flexbody div span:first-child {
  241. width: 100px;
  242. flex-shrink: 0;
  243. }
  244. .flexbody div span:first-child {
  245. color: blue;
  246. }
  247. .fileList span {
  248. margin-right: 10px;
  249. cursor: pointer;
  250. }
  251. .fileList span:hover {
  252. color: blueviolet;
  253. }
  254. .el-form-item {
  255. width: 100%;
  256. margin-bottom: 0;
  257. }
  258. </style>