qualificationApply.vue 5.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190
  1. <!--资格申请-->
  2. <template>
  3. <div class="app-container approval_handle">
  4. <div class="approval_handle-page" v-if="pageType == 1">
  5. <div class="top-click-img-box">
  6. <img src="@/assets/ZDimages/icon_banner_zgsq.png" alt="">
  7. <p v-hasPermi="['airbottle:qualificationApplyManage:add']" @click="handleClick('','','apply')">开始申请</p>
  8. </div>
  9. <el-form :model="queryParams" ref="queryForm" style="margin-top:20px;" :inline="true">
  10. <el-form-item label="状态" prop="zgType" label-width="80px">
  11. <el-select v-model="queryParams.auditStatus" placeholder="请选择" clearable size="small">
  12. <el-option label="待审核" value="0" />
  13. <el-option label="已通过" value="1" />
  14. <el-option label="未通过" value="2" />
  15. </el-select>
  16. </el-form-item>
  17. <el-form-item>
  18. <p class="inquire-button-one" @click="handleQuery">查询</p>
  19. <p class="reset-button-one" @click="resetQuery">重置</p>
  20. </el-form-item>
  21. </el-form>
  22. <el-table border v-loading="loading" :data="tableData">
  23. <el-table-column label="申请实验室" align="left" prop="location"/>
  24. <el-table-column label="申请时间" align="left" prop="createTime"></el-table-column>
  25. <el-table-column label="气瓶数量" align="left" prop="bottleNumber"></el-table-column>
  26. <el-table-column label="使用期限" align="left" prop="startTime">
  27. <template slot-scope="scope">
  28. {{scope.row.startTime}}至{{scope.row.endTime}}
  29. </template>
  30. </el-table-column>
  31. <el-table-column label="状态" align="left" prop="auditStatus">
  32. <template slot-scope="scope">
  33. <p :class="scope.row.remark == 0?'color_warn':(scope.row.remark == 1?'color_14AE10':(scope.row.remark == 2?'color_red':''))">{{scope.row.remark == 0?'待审核':(scope.row.remark == 1?'通过':(scope.row.remark == 2?'驳回':''))}}</p>
  34. </template>
  35. </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="table-button-box">
  39. <p class="table-button-null"></p>
  40. <p class="table-button-p"
  41. v-hasPermi="['airbottle:qualificationApplyManage:query']"
  42. @click="handleClick('',scope.row,'detail')"
  43. >查看</p>
  44. <p class="table-button-null"></p>
  45. </div>
  46. </template>
  47. </el-table-column>
  48. </el-table>
  49. <pagination
  50. :total="total"
  51. layout="total, prev, pager, next, sizes, jumper"
  52. :page.sync="queryParams.pageNum"
  53. :limit.sync="queryParams.pageSize"
  54. @pagination="getList"
  55. />
  56. </div>
  57. <!--添加页面-->
  58. <add-page v-if="pageType==2" :pageData="pageData"></add-page>
  59. <!--详情页面-->
  60. <detail-page v-if="pageType==3" :pageData2="pageData2"></detail-page>
  61. </div>
  62. </template>
  63. <script>
  64. import { getListGood, getLoginUser, qualificationApplyList, RFIDtagList } from '@/api/gasManage3_0/gasManage'
  65. import { getToken } from "@/utils/auth";
  66. import addPage from "./qualificationApplyAdd.vue"
  67. import detailPage from "./qualificationApplyDetail.vue"
  68. import { listCheckConfig } from '@/api/laboratory/checkConfig'
  69. export default {
  70. name: "Approval",
  71. components: {
  72. addPage,
  73. detailPage
  74. },
  75. data() {
  76. return {
  77. //页面状态
  78. pageType:1,
  79. loading:false,
  80. headers: {
  81. Authorization: "Bearer " + getToken()
  82. },
  83. // 查询参数
  84. queryParams: {
  85. pageNum: 1,
  86. pageSize:20,
  87. auditStatus:'',
  88. },
  89. total:0,
  90. tableData:[],
  91. pageData:{},//0添加1编辑
  92. pageData2:{},
  93. };
  94. },
  95. methods: {
  96. handleClick(index,row,doType){
  97. let _this=this;
  98. if(doType=='apply'){//申请
  99. _this.pageData.status=0;
  100. _this.pageType=2;
  101. }else if(doType=='detail'){//查看
  102. _this.pageData2.id=row.id;
  103. _this.pageData2.remark=row.remark;
  104. _this.pageType=3;
  105. }else if(doType=='back'){//返回
  106. _this.pageType=1;
  107. }else if(doType=='again'){//重新申请
  108. _this.pageType=2;
  109. _this.pageData.status=1;
  110. _this.pageData.id=row;
  111. }
  112. },
  113. /** 搜索按钮操作 */
  114. handleQuery() {
  115. this.queryParams.pageNum = 1;
  116. this.getList();
  117. },
  118. /** 重置按钮操作 */
  119. resetQuery() {
  120. this.queryParams.auditStatus = "";
  121. this.handleQuery();
  122. },
  123. getList(){
  124. let _this=this;
  125. qualificationApplyList(_this.queryParams).then( response => {
  126. let res=response.rows;
  127. _this.tableData=res;
  128. _this.total=response.total;
  129. });
  130. },
  131. },
  132. mounted() {
  133. this.getList();
  134. }
  135. };
  136. </script>
  137. <style scoped lang="scss">
  138. .approval_handle {
  139. display: flex!important;
  140. flex-direction: column;
  141. .approval_handle-page{
  142. flex:1;
  143. display: flex!important;
  144. flex-direction: column;
  145. box-shadow: 0 0 8px 2px rgba(0, 0, 0, 0.1);
  146. padding:20px 20px 20px!important;
  147. border-radius:10px;
  148. .top-click-img-box{
  149. width:1536px;
  150. height:250px;
  151. margin:0 auto 20px;
  152. position: relative;
  153. img{
  154. width:1536px;
  155. height:250px;
  156. }
  157. p{
  158. margin:0;
  159. position: absolute;
  160. left:294px;
  161. bottom:24px;
  162. width:200px;
  163. height:50px;
  164. border-radius:25px;
  165. line-height:50px;
  166. font-size:24px;
  167. text-align: center;
  168. color:#fff;
  169. font-weight: 500;
  170. border: 1px solid #69eeff;
  171. cursor: pointer;
  172. }
  173. }
  174. .form-box{
  175. }
  176. .button-box{
  177. width:200px;
  178. display: flex;
  179. }
  180. }
  181. }
  182. </style>