planExecuteRecord.vue 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163
  1. <!--预案执行记录-->
  2. <template>
  3. <div class="app-container approval_handle">
  4. <div class="approval_handle-page" v-if="pageType == 1">
  5. <el-form :model="queryParams" ref="queryForm" style="margin-top:20px;" :inline="true">
  6. <el-form-item label="关键字" prop="name">
  7. <el-input
  8. v-model="queryParams.searchValue"
  9. placeholder="预案名称/实验室"
  10. clearable
  11. maxLength="30"
  12. size="small"
  13. />
  14. </el-form-item>
  15. <el-form-item label="预案属性" prop="zgType" label-width="80px">
  16. <el-select v-model="queryParams.status" placeholder="请选择" clearable size="small">
  17. <el-option label="全部" value="" />
  18. <el-option label="在线" value="0" />
  19. <el-option label="异常" value="1" />
  20. </el-select>
  21. </el-form-item>
  22. <el-form-item>
  23. <p class="inquire-button-one" @click="handleQuery">查询</p>
  24. <p class="reset-button-one" @click="resetQuery">重置</p>
  25. </el-form-item>
  26. </el-form>
  27. <el-table border v-loading="loading" :data="tableData">
  28. <el-table-column label="预案名称" align="left" prop="userName"/>
  29. <el-table-column label="实验室名称" align="left" prop="userNumber"></el-table-column>
  30. <el-table-column label="预案属性" align="left" prop="deptName">
  31. <template slot-scope="scope">
  32. <span>{{scope.row.deptName==1?'火灾预案':(scope.row.deptName==2?'非火灾预案':'')}}</span>
  33. </template>
  34. </el-table-column>
  35. <el-table-column label="预案发生时间" align="left" prop="userTelephone"></el-table-column>
  36. <el-table-column label="操作" align="left" class-name="small-padding fixed-width" width="120">
  37. <template slot-scope="scope">
  38. <div class="button-box">
  39. <p class="table-min-button" v-hasPermi="['laboratory:hardware5:edit']" @click="handleClick('',scope.row,'detail')">查看</p>
  40. </div>
  41. </template>
  42. </el-table-column>
  43. </el-table>
  44. <pagination
  45. :total="total"
  46. layout="total, prev, pager, next, sizes, jumper"
  47. :page.sync="queryParams.pageNum"
  48. :limit.sync="queryParams.pageSize"
  49. @pagination="getList"
  50. />
  51. </div>
  52. <!--详情页面-->
  53. <detail-page v-if="pageType==2" :pageData="pageData"></detail-page>
  54. </div>
  55. </template>
  56. <script>
  57. import {
  58. labCenterPersonList,
  59. } from '@/api/gasManage3_0/gasManage'
  60. import detailPage from "./planExecuteRecordDetail"
  61. export default {
  62. name: "Approval",
  63. components: {
  64. detailPage
  65. },
  66. data() {
  67. return {
  68. dialogVisible :false,
  69. //页面状态
  70. pageType:1,
  71. loading:false,
  72. // 查询参数
  73. queryParams: {
  74. pageNum: 1,
  75. pageSize:20,
  76. searchValue:'',
  77. },
  78. form:{
  79. tagCode:'',
  80. },
  81. total:0,
  82. pageData:{},
  83. tableData:[],
  84. };
  85. },
  86. methods: {
  87. handleClick(index,row,doType){
  88. let _this=this;
  89. if(doType=='detail'){//详情
  90. _this.pageType=2;
  91. }else if(doType=='back'){//返回
  92. _this.pageType=1;
  93. }
  94. },
  95. /** 搜索按钮操作 */
  96. handleQuery() {
  97. this.queryParams.pageNum = 1;
  98. this.getList();
  99. },
  100. /** 重置按钮操作 */
  101. resetQuery() {
  102. this.queryParams.searchValue = "";
  103. this.queryParams.deptIds = "";
  104. this.handleQuery();
  105. },
  106. getList(){
  107. let _this=this;
  108. labCenterPersonList(_this.queryParams).then( response => {
  109. let res=response.rows;
  110. _this.tableData=res;
  111. _this.total=response.total;
  112. });
  113. },
  114. },
  115. mounted() {
  116. this.getList();
  117. }
  118. };
  119. </script>
  120. <style scoped lang="scss">
  121. .approval_handle {
  122. display: flex!important;
  123. flex-direction: column;
  124. overflow: hidden;
  125. .approval_handle-page{
  126. flex:1;
  127. display: flex!important;
  128. flex-direction: column;
  129. box-shadow: 0 0 8px 2px rgba(0, 0, 0, 0.1);
  130. padding:20px 20px 20px!important;
  131. border-radius:10px;
  132. overflow: hidden;
  133. .button-box{
  134. width:200px;
  135. display: flex;
  136. }
  137. }
  138. .entering_t{
  139. font-size: 16px;
  140. font-family: Microsoft YaHei;
  141. font-weight: 400;
  142. color: #333333;
  143. line-height: 16px;
  144. margin: 36px auto 25px;
  145. text-align: center;
  146. }
  147. .entering_img{
  148. width: 288px;
  149. height: 140px;
  150. }
  151. .entering_input{
  152. width: 288px;
  153. }
  154. }
  155. </style>