c336b3f06a01db022d06302dc9a32d3634b540b1.svn-base 8.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297
  1. <template>
  2. <div class="popupContentClass" :style="{'height':testHeight1+'px'}">
  3. <el-table
  4. :data="tableData"
  5. border
  6. :height="tableHeight"
  7. v-loading="loading"
  8. style="width: 100%">
  9. <el-table-column
  10. fixed
  11. prop="nm"
  12. show-overflow-tooltip
  13. label="工程名称"
  14. min-width="180">
  15. </el-table-column>
  16. <el-table-column
  17. min-width="140"
  18. prop="inspPblmsName"
  19. label="问题类别"
  20. show-overflow-tooltip
  21. ></el-table-column>
  22. <el-table-column
  23. show-overflow-tooltip
  24. prop="inspPblmDesc"
  25. label="督查问题描述"
  26. min-width="150">
  27. </el-table-column>
  28. <el-table-column
  29. prop="inspPblmCate"
  30. label="严重程度"
  31. min-width="90">
  32. <template slot-scope="scope">
  33. {{scope.row.inspPblmCate | inspPblmCate}}
  34. </template>
  35. </el-table-column>
  36. <el-table-column
  37. prop="ifCasePblm"
  38. label="是否典型"
  39. min-width="90">
  40. <template slot-scope="scope">
  41. {{scope.row.ifCasePblm == '1' ? '典型' : scope.row.ifCasePblm == '0' ? '非典型' : ''}}
  42. </template>
  43. </el-table-column>
  44. <el-table-column
  45. prop="collTime"
  46. label="发现时间"
  47. min-width="150">
  48. <template slot-scope="scope">
  49. {{scope.row.collTime ? formatDateTime(scope.row.collTime) : ''}}
  50. </template>
  51. </el-table-column>
  52. <el-table-column
  53. prop="hasVedio"
  54. label="有无多媒体"
  55. min-width="100">
  56. <template slot-scope="scope">
  57. <p v-if="scope.row.hasVedio == 1">是</p>
  58. <p v-if="scope.row.hasVedio == 0">否</p>
  59. </template>
  60. </el-table-column>
  61. <el-table-column
  62. fixed="right"
  63. label="操作"
  64. min-width="130">
  65. <template slot-scope="scope">
  66. <el-button type="text" size="small" @click="toShowDetail(scope.row)">详情</el-button>
  67. </template>
  68. </el-table-column>
  69. </el-table>
  70. <el-pagination :pager-count="5" :current-page="pageIndex"
  71. :page-size="pageSize" layout="total, prev, pager, next" :total="total"
  72. @current-change="pageIndexChange" @size-change="handleSizeChange"
  73. ></el-pagination>
  74. <!-- 详情组件-->
  75. <el-dialog
  76. class="custom_dialog"
  77. title="问题详情"
  78. width="60%"
  79. append-to-body
  80. :visible.sync="supervisionDetailsVisible">
  81. <supervision-details ref="xianqing" :problemId="problemId"></supervision-details>
  82. <span slot="footer">
  83. <el-button style="margin-top:5px;" @click="supervisionDetailsVisible = false">返回</el-button>
  84. </span>
  85. </el-dialog>
  86. </div>
  87. </template>
  88. <script>
  89. import request from '../../../../../utils/gw_ajax_request.js'
  90. export default {
  91. props: ['currentResCode','currentObjectId'],
  92. components: {
  93. upload: resolve => {
  94. require(["../../../../../widgets/uploadFile.vue"], resolve);
  95. },
  96. //详情页
  97. supervisionDetails: resolve => {
  98. require(["../../../../duChaWenTi/supervisionDetails_yudiba.vue"], resolve);
  99. }
  100. },
  101. data(){
  102. return{
  103. tableHeight: window.innerHeight * 0.5 + 50,
  104. // testHeight:(window.innerHeight * 0.5 - 114) / 6,
  105. testHeight1:window.innerHeight * 0.6,
  106. tableData:[
  107. {
  108. date: '',
  109. name: '',
  110. province: '',
  111. city: '',
  112. address: '',
  113. zip: ''
  114. }
  115. ],
  116. problemSearch:{
  117. pageSize: 20,
  118. pageNum: 1,
  119. persId: '',
  120. objId: '',
  121. pType: '11'
  122. },
  123. problemForm:{
  124. objId: '',
  125. objType: '',
  126. problemType: '',
  127. inspPblmDesc: '',
  128. pblmsTypeId: '',
  129. qualityTypeId: '',
  130. pblmsId: '',
  131. defectTypeId: '',
  132. ifCasePblm: '',
  133. inspPblmCate: '',
  134. weigui: '',
  135. hetong: '',
  136. quanlity: '',
  137. gongcheng: '',
  138. gwComFiles: []
  139. },
  140. imgList: [],
  141. videoList:[],
  142. audioList: [],
  143. pblmStat: '',
  144. gwComFiles: [],
  145. problemType: [],
  146. problemStatus: [],
  147. severity:[
  148. {name: '一般',value:'0'},
  149. {name: '较重',value:'1'},
  150. {name: '严重',value:'2'},
  151. // {name: '非常严重',value:'3'}
  152. ],
  153. dialogType: '添加',
  154. dialogVisible: true,
  155. checked: false,
  156. problemId: '',
  157. supervisionDetailsVisible:false,
  158. projectType: '',
  159. reviConc: '',
  160. findTime: [],
  161. activeName: 'problem-detail',
  162. pageIndex: 1,
  163. pageSize: 20,
  164. total: 0,
  165. loading: false,
  166. showWenTiTianBaoPl: false,
  167. //问题修改弹窗
  168. problemInfo: null,
  169. rectifyProblemInfo: null,
  170. edit_dialogVisible: false,
  171. recheck_edit_dialogVisible: false,
  172. showAddProblemDialog: false,
  173. supervision: [
  174. {
  175. value: "1",
  176. label: "是"
  177. },
  178. {
  179. value: "0",
  180. label: "否"
  181. }
  182. ]
  183. }
  184. },
  185. computed: {
  186. persId() {
  187. return localStorage.getItem("userid")
  188. ? localStorage.getItem("userid")
  189. : "1098101939614724096";
  190. },
  191. },
  192. mounted(){
  193. this.search();
  194. },
  195. activated(){
  196. this.search()
  197. },
  198. methods:{
  199. search(){
  200. this.searchList()
  201. },
  202. closePlDialog(val) {
  203. this.showAddProblemDialog = false;
  204. this.search()
  205. },
  206. searchList(){
  207. this.loading = true
  208. this.problemSearch.pageSize = this.pageSize
  209. this.problemSearch.pageNum = this.pageIndex
  210. this.problemSearch.objId = this.currentObjectId ? this.currentObjectId : '';
  211. this.problemSearch.persId = this.persId;
  212. request.post(`/dc/insp/pblm/page/sdPblm`, this.problemSearch).then(res => {
  213. if (res.success) {
  214. this.tableData = this.currentObjectId ? res.data.list : [];
  215. this.total = this.currentObjectId ? res.data.total : 0;
  216. }
  217. this.loading = false
  218. });
  219. },
  220. // 查看详情
  221. toShowDetail(row){
  222. this.problemId = row.pblmId
  223. this.supervisionDetailsVisible = true
  224. },
  225. handleDetailClick(tab, event) {
  226. console.log(tab, event);
  227. },
  228. pageIndexChange(val) {
  229. this.pageIndex = val;
  230. this.searchList();
  231. },
  232. handleSizeChange(val) {
  233. this.pageSize = val;
  234. this.searchList();
  235. },
  236. showPlDialog() {
  237. this.showWenTiTianBaoPl = true;
  238. }
  239. },
  240. watch:{
  241. 'currentRow.id':{
  242. deep: true,
  243. handler(newVal,oldVal){
  244. this.searchList()
  245. }
  246. },
  247. 'problemForm.problemType':{
  248. deep: true,
  249. handler(newVal,oldVal){
  250. this.convertGroup()
  251. }
  252. },
  253. },
  254. filters:{
  255. inspPblmCate(val){
  256. if(!val || val == ''){
  257. return ''
  258. }
  259. if(val == '0'){
  260. return '一般'
  261. }else if(val == '1'){
  262. return '较重'
  263. }else if(val == '2'){
  264. return '严重'
  265. }
  266. // else if(val == '3'){
  267. // return '非常严重'
  268. // }
  269. else{
  270. return val
  271. }
  272. },
  273. }
  274. }
  275. </script>
  276. <style lang="scss">
  277. .search_wrapper{
  278. display: flex;
  279. justify-content: space-between;
  280. div:last-child{
  281. min-width: 160px;
  282. }
  283. }
  284. .slide-line{
  285. width: 96%;
  286. margin-left: 3%;
  287. height: 1px;
  288. margin-bottom: 10px;
  289. border-bottom: dashed 1px #DCDFE6;
  290. }
  291. .detail_dialog .el-dialog__body{
  292. padding: 0 20px 30px;
  293. }
  294. </style>