c7c1d8bde7badf74055fa9f1973a1af5473a7c6d.svn-base 9.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236
  1. <!-- -->
  2. <template>
  3. <div>
  4. <el-table
  5. :data="tableData"
  6. border
  7. style="width: 100%">
  8. <el-table-column
  9. align="center"
  10. prop="year"
  11. label="年度"
  12. width="60">
  13. </el-table-column>
  14. <el-table-column
  15. align="center"
  16. prop="batch"
  17. label="批次"
  18. width="60">
  19. </el-table-column>
  20. <el-table-column
  21. header-align="center"
  22. align="center"
  23. min-width="140"
  24. label="稽察组长"
  25. >
  26. <template slot-scope="scope">
  27. <transition name="el-fade-in-linear">
  28. <div style="width:100%;height:100%;display:flex;flex-direction:row;justify-content:center;align-items:center;" v-if="!scope.row.special.length">
  29. /
  30. </div>
  31. </transition>
  32. <transition name="el-fade-in-linear">
  33. <div v-if="scope.row.special.length" style="width:100%;height:100%;display:flex;flex-direction:row;justify-content:center;align-items:center;">
  34. <span>{{scope.row['special']&&scope.row['special'].length?testformatterArray(scope.row['special'],'name'):''}}</span>
  35. </div>
  36. </transition>
  37. </template>
  38. </el-table-column>
  39. <el-table-column
  40. header-align="center"
  41. align="center"
  42. min-width="140"
  43. label="助理"
  44. >
  45. <template slot-scope="scope">
  46. <transition name="el-fade-in-linear">
  47. <div style="width:100%;height:100%;display:flex;flex-direction:row;justify-content:center;align-items:center;" v-if="!scope.row.aid.length">
  48. /
  49. </div>
  50. </transition>
  51. <transition name="el-fade-in-linear">
  52. <div v-if="scope.row.aid.length" style="width:100%;height:100%;display:flex;flex-direction:row;justify-content:center;align-items:center;">
  53. <span>{{scope.row['aid']&&scope.row['aid'].length?testformatterArray(scope.row['aid'],'name'):''}}</span>
  54. </div>
  55. </transition>
  56. </template>
  57. </el-table-column>
  58. <el-table-column
  59. header-align="center"
  60. align="center"
  61. min-width="140"
  62. label="前期专家"
  63. >
  64. <template slot-scope="scope">
  65. <transition name="el-fade-in-linear">
  66. <div style="width:100%;height:100%;display:flex;flex-direction:row;justify-content:center;align-items:center;" v-if="!scope.row.qqzj.length">
  67. /
  68. </div>
  69. </transition>
  70. <transition name="el-fade-in-linear">
  71. <div v-if="scope.row.qqzj.length" style="width:100%;height:100%;display:flex;flex-direction:row;justify-content:center;align-items:center;">
  72. <span>{{scope.row['qqzj']&&scope.row['qqzj'].length?testformatterArray(scope.row['qqzj'],'name'):''}}</span>
  73. </div>
  74. </transition>
  75. </template>
  76. </el-table-column>
  77. <el-table-column
  78. header-align="center"
  79. align="center"
  80. min-width="140"
  81. label="建管专家"
  82. >
  83. <template slot-scope="scope">
  84. <transition name="el-fade-in-linear">
  85. <div style="width:100%;height:100%;display:flex;flex-direction:row;justify-content:center;align-items:center;" v-if="!scope.row.jgzj.length">
  86. /
  87. </div>
  88. </transition>
  89. <transition name="el-fade-in-linear">
  90. <div v-if="scope.row.jgzj.length" style="width:100%;height:100%;display:flex;flex-direction:row;justify-content:center;align-items:center;">
  91. <span>{{scope.row['jgzj']&&scope.row['jgzj'].length?testformatterArray(scope.row['jgzj'],'name'):''}}</span>
  92. </div>
  93. </transition>
  94. </template>
  95. </el-table-column>
  96. <el-table-column
  97. header-align="center"
  98. align="center"
  99. min-width="140"
  100. label="计划专家"
  101. >
  102. <template slot-scope="scope">
  103. <transition name="el-fade-in-linear">
  104. <div style="width:100%;height:100%;display:flex;flex-direction:row;justify-content:center;align-items:center;" v-if="!scope.row.jhzj.length">
  105. /
  106. </div>
  107. </transition>
  108. <transition name="el-fade-in-linear">
  109. <div v-if="scope.row.jhzj.length" style="width:100%;height:100%;display:flex;flex-direction:row;justify-content:center;align-items:center;">
  110. <span>{{scope.row['jhzj']&&scope.row['jhzj'].length?testformatterArray(scope.row['jhzj'],'name'):''}}</span>
  111. </div>
  112. </transition>
  113. </template>
  114. </el-table-column>
  115. <el-table-column
  116. header-align="center"
  117. align="center"
  118. min-width="140"
  119. label="财务专家"
  120. >
  121. <template slot-scope="scope">
  122. <transition name="el-fade-in-linear">
  123. <div style="width:100%;height:100%;display:flex;flex-direction:row;justify-content:center;align-items:center;" v-if="!scope.row.cwzj.length">
  124. /
  125. </div>
  126. </transition>
  127. <transition name="el-fade-in-linear">
  128. <div v-if="scope.row.cwzj.length" style="width:100%;height:100%;display:flex;flex-direction:row;justify-content:center;align-items:center;">
  129. <span>{{scope.row['cwzj']&&scope.row['cwzj'].length?testformatterArray(scope.row['cwzj'],'name'):''}}</span>
  130. </div>
  131. </transition>
  132. </template>
  133. </el-table-column>
  134. <el-table-column
  135. header-align="center"
  136. align="center"
  137. min-width="140"
  138. label="质量专家"
  139. >
  140. <template slot-scope="scope">
  141. <transition name="el-fade-in-linear">
  142. <div style="width:100%;height:100%;display:flex;flex-direction:row;justify-content:center;align-items:center;" v-if="!scope.row.zlzj.length">
  143. /
  144. </div>
  145. </transition>
  146. <transition name="el-fade-in-linear">
  147. <div v-if="scope.row.zlzj.length" style="width:100%;height:100%;display:flex;flex-direction:row;justify-content:center;align-items:center;">
  148. <span>{{scope.row['zlzj']&&scope.row['zlzj'].length?testformatterArray(scope.row['zlzj'],'name'):''}}</span>
  149. </div>
  150. </transition>
  151. </template>
  152. </el-table-column>
  153. <el-table-column
  154. header-align="center"
  155. align="center"
  156. min-width="140"
  157. label="安全专家"
  158. >
  159. <template slot-scope="scope">
  160. <transition name="el-fade-in-linear">
  161. <div style="width:100%;height:100%;display:flex;flex-direction:row;justify-content:center;align-items:center;" v-if="!scope.row.aqzj.length">
  162. /
  163. </div>
  164. </transition>
  165. <transition name="el-fade-in-linear">
  166. <div v-if="scope.row.aqzj.length" style="width:100%;height:100%;display:flex;flex-direction:row;justify-content:center;align-items:center;">
  167. <span>{{scope.row['aqzj']&&scope.row['aqzj'].length?testformatterArray(scope.row['aqzj'],'name'):''}}</span>
  168. </div>
  169. </transition>
  170. </template>
  171. </el-table-column>
  172. </el-table>
  173. </div>
  174. </template>
  175. <script>
  176. //这里可以导入其他文件(比如:组件,工具js,第三方插件js,json文件,图片文件等等)
  177. //例如:import 《组件名称》 from '《组件路径》';
  178. import request from '@util/gw_ajax_request'
  179. // import {formatterValueToLabel,formatterArrayToLabel} from "../../utils/gw_formatter.js";
  180. import {formatterValueToLabel,formatterArrayToLabel} from "../../../utils/gw_formatter.js";
  181. // import { getProjectJcInfo } from '../../../api/jcOneMapApi'
  182. export default {
  183. //import引入的组件需要注入到对象中才能使用
  184. props:['projectInfoCon','select_nd','select_pc','tableData'],
  185. components: {},
  186. data() {
  187. //这里存放数据
  188. return {
  189. };
  190. },
  191. //监听属性 类似于data概念
  192. computed: {
  193. },
  194. //监控data中的数据变化
  195. watch: {},
  196. //方法集合
  197. methods: {
  198. testformatterArray: function(
  199. arr,
  200. labelPropName,
  201. splitMark = ",",
  202. nonLabel = "",
  203. isAddNonLabel = true
  204. ) {
  205. let r = formatterArrayToLabel(
  206. arr,
  207. labelPropName,
  208. (splitMark = ","),
  209. (nonLabel = ""),
  210. (isAddNonLabel = true)
  211. );
  212. return r;
  213. },
  214. },
  215. //生命周期 - 创建完成(可以访问当前this实例)
  216. created() {
  217. },
  218. //生命周期 - 挂载完成(可以访问DOM元素)
  219. mounted() {
  220. // this.getTableData();
  221. },
  222. beforeCreate() {}, //生命周期 - 创建之前
  223. beforeMount() {}, //生命周期 - 挂载之前
  224. beforeUpdate() {}, //生命周期 - 更新之前
  225. updated() {}, //生命周期 - 更新之后
  226. beforeDestroy() {}, //生命周期 - 销毁之前
  227. destroyed() {}, //生命周期 - 销毁完成
  228. activated() {}, //如果页面有keep-alive缓存功能,这个函数会触发
  229. }
  230. </script>
  231. <style scoped>
  232. </style>