qualificationApply.vue 5.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188
  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="button-box">
  39. <p class="table-min-button"
  40. v-hasPermi="['airbottle:qualificationApplyManage:query']"
  41. @click="handleClick('',scope.row,'detail')"
  42. >查看</p>
  43. </div>
  44. </template>
  45. </el-table-column>
  46. </el-table>
  47. <pagination
  48. :total="total"
  49. layout="total, prev, pager, next, sizes, jumper"
  50. :page.sync="queryParams.pageNum"
  51. :limit.sync="queryParams.pageSize"
  52. @pagination="getList"
  53. />
  54. </div>
  55. <!--添加页面-->
  56. <add-page v-if="pageType==2" :pageData="pageData"></add-page>
  57. <!--详情页面-->
  58. <detail-page v-if="pageType==3" :pageData2="pageData2"></detail-page>
  59. </div>
  60. </template>
  61. <script>
  62. import { getListGood, getLoginUser, qualificationApplyList, RFIDtagList } from '@/api/gasManage3_0/gasManage'
  63. import { getToken } from "@/utils/auth";
  64. import addPage from "./qualificationApplyAdd.vue"
  65. import detailPage from "./qualificationApplyDetail.vue"
  66. import { listCheckConfig } from '@/api/laboratory/checkConfig'
  67. export default {
  68. name: "Approval",
  69. components: {
  70. addPage,
  71. detailPage
  72. },
  73. data() {
  74. return {
  75. //页面状态
  76. pageType:1,
  77. loading:false,
  78. headers: {
  79. Authorization: "Bearer " + getToken()
  80. },
  81. // 查询参数
  82. queryParams: {
  83. pageNum: 1,
  84. pageSize:20,
  85. auditStatus:'',
  86. },
  87. total:0,
  88. tableData:[],
  89. pageData:{},//0添加1编辑
  90. pageData2:{},
  91. };
  92. },
  93. methods: {
  94. handleClick(index,row,doType){
  95. let _this=this;
  96. if(doType=='apply'){//申请
  97. _this.pageData.status=0;
  98. _this.pageType=2;
  99. }else if(doType=='detail'){//查看
  100. _this.pageData2.id=row.id;
  101. _this.pageData2.remark=row.remark;
  102. _this.pageType=3;
  103. }else if(doType=='back'){//返回
  104. _this.pageType=1;
  105. }else if(doType=='again'){//重新申请
  106. _this.pageType=2;
  107. _this.pageData.status=1;
  108. _this.pageData.id=row;
  109. }
  110. },
  111. /** 搜索按钮操作 */
  112. handleQuery() {
  113. this.queryParams.pageNum = 1;
  114. this.getList();
  115. },
  116. /** 重置按钮操作 */
  117. resetQuery() {
  118. this.queryParams.auditStatus = "";
  119. this.handleQuery();
  120. },
  121. getList(){
  122. let _this=this;
  123. qualificationApplyList(_this.queryParams).then( response => {
  124. let res=response.rows;
  125. _this.tableData=res;
  126. _this.total=response.total;
  127. });
  128. },
  129. },
  130. mounted() {
  131. this.getList();
  132. }
  133. };
  134. </script>
  135. <style scoped lang="scss">
  136. .approval_handle {
  137. display: flex!important;
  138. flex-direction: column;
  139. .approval_handle-page{
  140. flex:1;
  141. display: flex!important;
  142. flex-direction: column;
  143. box-shadow: 0 0 8px 2px rgba(0, 0, 0, 0.1);
  144. padding:20px 20px 20px!important;
  145. border-radius:10px;
  146. .top-click-img-box{
  147. width:1536px;
  148. height:250px;
  149. margin:0 auto 20px;
  150. position: relative;
  151. img{
  152. width:1536px;
  153. height:250px;
  154. }
  155. p{
  156. margin:0;
  157. position: absolute;
  158. left:294px;
  159. bottom:24px;
  160. width:200px;
  161. height:50px;
  162. border-radius:25px;
  163. line-height:50px;
  164. font-size:24px;
  165. text-align: center;
  166. color:#fff;
  167. font-weight: 500;
  168. border: 1px solid #69eeff;
  169. cursor: pointer;
  170. }
  171. }
  172. .form-box{
  173. }
  174. .button-box{
  175. width:200px;
  176. display: flex;
  177. }
  178. }
  179. }
  180. </style>