فهرست منبع

Merge branch 'master' of http://47.114.101.16:7070/ssy/newcpms

 Conflicts:
	master/src/main/java/com/ruoyi/project/intact/domain/TIntactGj.java
	master/src/main/java/com/ruoyi/project/intact/domain/TIntactPump.java
	master/src/main/java/com/ruoyi/project/intact/mapper/TIntactPumpMapper.java
	master/src/main/java/com/ruoyi/project/intact/service/ITIntactGjService.java
	master/src/main/java/com/ruoyi/project/intact/service/ITIntactPumpService.java
	master/src/main/java/com/ruoyi/project/intact/service/impl/TIntactGjServiceImpl.java
	master/src/main/java/com/ruoyi/project/intact/service/impl/TIntactPumpServiceImpl.java
	ui/src/views/approve/pending/index.vue
	ui/src/views/intact/gj/index.vue
	ui/src/views/intact/gyl/index.vue
	ui/src/views/intact/pump/index.vue
zhangding 3 سال پیش
والد
کامیت
69a69d400c

+ 6 - 0
master/src/main/java/com/ruoyi/project/ehs/controller/TApproveDangerController.java

@@ -410,6 +410,12 @@ public class TApproveDangerController extends BaseController
                     devProcess.setApNo(approve.getApNo());
                     devProcess.setApName(user.getNickName());
                     devProcess.setApproveObject(approve);
+                }else if (pi.getProcessDefinitionName().equals("设备维修审批流程")) {
+                    TApproveMaintenance approve = tApproveMaintenanceService.selectTApproveMaintenanceById(Long.parseLong(pi.getBusinessKey()));
+                    SysUser user = sysUserService.selectUserById(approve.getUserId());
+                    devProcess.setApNo(approve.getApNo());
+                    devProcess.setApName(user.getNickName());
+                    devProcess.setApproveObject(approve);
                 }else {
                     TApproveDanger approveDanger = tApproveDangerService.selectTApproveDangerById(Long.parseLong(pi.getBusinessKey()));
                     SysUser user = sysUserService.selectUserById(approveDanger.getRecorderId());

+ 126 - 61
master/src/main/java/com/ruoyi/project/intact/controller/TApproveMaintenanceController.java

@@ -4,12 +4,16 @@ import java.text.SimpleDateFormat;
 import java.util.*;
 
 import com.alibaba.fastjson.JSON;
+import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
+import com.ruoyi.common.utils.StringUtils;
 import com.ruoyi.project.approve.damain.DevTask;
-import com.ruoyi.project.intact.domain.TIntactGyl;
-import com.ruoyi.project.intact.domain.TIntactYsj;
+import com.ruoyi.project.intact.domain.*;
+import com.ruoyi.project.intact.mapper.TApproveMaintenanceMapper;
 import com.ruoyi.project.intact.service.*;
 import com.ruoyi.project.sems.domain.*;
 import com.ruoyi.project.sems.his.domain.*;
+import com.ruoyi.project.system.domain.SysUser;
+import com.ruoyi.project.system.service.ISysUserService;
 import org.activiti.engine.*;
 import org.activiti.engine.impl.identity.Authentication;
 import org.activiti.engine.runtime.ProcessInstance;
@@ -17,17 +21,9 @@ import org.activiti.engine.task.Task;
 import org.apache.poi.ss.formula.functions.T;
 import org.springframework.security.access.prepost.PreAuthorize;
 import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.web.bind.annotation.GetMapping;
-import org.springframework.web.bind.annotation.PostMapping;
-import org.springframework.web.bind.annotation.PutMapping;
-import org.springframework.web.bind.annotation.DeleteMapping;
-import org.springframework.web.bind.annotation.PathVariable;
-import org.springframework.web.bind.annotation.RequestBody;
-import org.springframework.web.bind.annotation.RequestMapping;
-import org.springframework.web.bind.annotation.RestController;
+import org.springframework.web.bind.annotation.*;
 import com.ruoyi.framework.aspectj.lang.annotation.Log;
 import com.ruoyi.framework.aspectj.lang.enums.BusinessType;
-import com.ruoyi.project.intact.domain.TApproveMaintenance;
 import com.ruoyi.framework.web.controller.BaseController;
 import com.ruoyi.framework.web.domain.AjaxResult;
 import com.ruoyi.common.utils.poi.ExcelUtil;
@@ -45,6 +41,8 @@ public class TApproveMaintenanceController extends BaseController
 {
     @Autowired
     private ITApproveMaintenanceService tApproveMaintenanceService;
+    @Autowired
+    private TApproveMaintenanceMapper maintenanceMapper;
 
     @Autowired
     private RuntimeService runtimeService;
@@ -61,6 +59,24 @@ public class TApproveMaintenanceController extends BaseController
     private ITIntactGjService gjService;
     @Autowired
     private ITIntactPumpService pumpService;
+    @Autowired
+    private ISysUserService sysUserService;
+
+    @RequestMapping("/hisApprovelist")
+    public AjaxResult hisApprovelist(@RequestParam Map<String, Object> params) {
+        String sql = params.get("devId") + " in (SELECT REGEXP_SUBSTR (DEV_ID, '[^,]+', 1,rownum) from dual connect by rownum<=LENGTH (DEV_ID) - LENGTH (regexp_replace(DEV_ID, ',', ''))+1 ) ";
+        if (StringUtils.isNotEmpty((String) params.get("devType"))){
+            sql+=" and dev_type="+params.get("devType")+" ";
+        }
+        List<TApproveMaintenance> list = maintenanceMapper.selectList(new QueryWrapper<TApproveMaintenance>().apply(sql).orderByDesc("CREATTIME")
+        );
+        for (TApproveMaintenance t : list
+        ) {
+            SysUser userEntity = sysUserService.selectUserById(t.getUserId());
+            t.setUserName(userEntity.getNickName());
+        }
+        return AjaxResult.success(list);
+    }
 
     /**
      * 查询设备完整性维修申请列表
@@ -71,6 +87,44 @@ public class TApproveMaintenanceController extends BaseController
     {
         startPage();
         List<TApproveMaintenance> list = tApproveMaintenanceService.selectTApproveMaintenanceList(tApproveMaintenance);
+        for (TApproveMaintenance tApprove : list) {
+            String[] ids;
+            ids = tApprove.getDevId().split(",");
+            List<Object> devList = new ArrayList<>();
+            switch (Integer.parseInt(tApprove.getDevType().toString())) {
+                case 1:
+                    for (String i : ids
+                    ) {
+                        TIntactGyl gylEntity = gylService.getById(i);
+                        devList.add(gylEntity);
+                    }
+                    break;
+                case 2:
+                    for (String i : ids
+                    ) {
+                        TIntactYsj ysjEntity = ysjService.getById(i);
+                        devList.add(ysjEntity);
+                    }
+                    break;
+            case 3:
+                for (String i : ids
+                ) {
+                    TIntactGj gjEntity = gjService.getById(i);
+                    devList.add(gjEntity);
+                }
+                break;
+            case 4:
+                for (String i : ids
+                ) {
+                    TIntactPump pumpEntity = pumpService.getById(i);
+                    devList.add(pumpEntity);
+                }
+                break;
+                default:
+                    break;
+            }
+            tApprove.setDevList(devList);
+        }
         return getDataTable(list);
     }
 
@@ -122,20 +176,20 @@ public class TApproveMaintenanceController extends BaseController
                     devList.add(ysjEntity);
                 }
                 break;
-//            case 3:
-//                for (String i : ids
-//                ) {
-//                    TSpecdevDzsb dzsbEntity = tSpecdevDzsbService.getById(i);
-//                    devList.add(dzsbEntity);
-//                }
-//                break;
-//            case 4:
-//                for (String i : ids
-//                ) {
-//                    TSpecdevGl glEntity = tSpecdevGlService.getById(i);
-//                    devList.add(glEntity);
-//                }
-//                break;
+            case 3:
+                for (String i : ids
+                ) {
+                    TIntactGj gjEntity = gjService.getById(i);
+                    devList.add(gjEntity);
+                }
+                break;
+            case 4:
+                for (String i : ids
+                ) {
+                    TIntactPump pumpEntity = pumpService.getById(i);
+                    devList.add(pumpEntity);
+                }
+                break;
             default:
                 break;
         }
@@ -184,24 +238,24 @@ public class TApproveMaintenanceController extends BaseController
                     ysjService.updateById(ysjEntity);
                 }
                 break;
-//            case 3:
-//                for (String i : ids
-//                ) {
-//                    TSpecdevDzsb dzsbEntity = tSpecdevDzsbService.getById(i);
-//                    dzsbEntity.setApproveStatus(tApproveSpecModify.getApproveType()+ 19);
-//                    dzsbEntity.setApproveTime(new Date());
-//                    tSpecdevDzsbService.updateById(dzsbEntity);
-//                }
-//                break;
-//            case 4:
-//                for (String i : ids
-//                ) {
-//                    TSpecdevGl glEntity = tSpecdevGlService.getById(i);
-//                    glEntity.setApproveStatus(tApproveSpecModify.getApproveType()+ 19);
-//                    glEntity.setApproveTime(new Date());
-//                    tSpecdevGlService.updateById(glEntity);
-//                }
-//                break;
+            case 3:
+                for (String i : ids
+                ) {
+                    TIntactGj gjEntity = gjService.getById(i);
+//                    gjEntity.setApproveStatus(tApproveMaintenance.getApproveType()+ 19);
+                    gjEntity.setApproveTime(new Date());
+                    gjService.updateById(gjEntity);
+                }
+                break;
+            case 4:
+                for (String i : ids
+                ) {
+                    TIntactPump pumpEntity = pumpService.getById(i);
+//                    pumpEntity.setApproveStatus(t.getApproveType()+ 19);
+                    pumpEntity.setApproveTime(new Date());
+                    pumpService.updateById(pumpEntity);
+                }
+                break;
             default:
                 break;
         }
@@ -237,9 +291,11 @@ public class TApproveMaintenanceController extends BaseController
         if (devTask.getCondition().equals("1")) {
             devTask.setComment("通过" + symbol + devTask.getComment());
             tApproveMaintenance.setStatus(1L);
+            tApproveMaintenance.setEndtime(new Date());
         }else if (devTask.getCondition().equals("0")) {
             devTask.setComment("未通过" + symbol + devTask.getComment());
             tApproveMaintenance.setStatus(2L);
+            tApproveMaintenance.setEndtime(new Date());
         }
         String[] ids;
         ids = tApproveMaintenance.getDevId().split(",");
@@ -253,24 +309,33 @@ public class TApproveMaintenanceController extends BaseController
                     tApproveMaintenanceService.updateTApproveMaintenance(tApproveMaintenance);
                 }
                 break;
-//            case 2://修改压力管道台账
-//                for (String i : ids
-//                ) {
-//
-//                }
-//                break;
-//            case 3:
-//                for (String i : ids
-//                ) {
-//
-//                }
-//                break;
-//            case 4:
-//                for (String i : ids
-//                ) {
-//
-//                }
-//                break;
+            case 2://修改压缩机台账
+                for (String i : ids
+                ) {
+                    TIntactYsj ysjEntity = ysjService.getById(i);
+                    ysjEntity.setApproveStatus(0L);
+                    ysjService.updateById(ysjEntity);
+                    tApproveMaintenanceService.updateTApproveMaintenance(tApproveMaintenance);
+                }
+                break;
+            case 3:
+                for (String i : ids
+                ) {
+                    TIntactGj gjEntity = gjService.getById(i);
+                    gjEntity.setApproveStatus(0L);
+                    gjService.updateById(gjEntity);
+                    tApproveMaintenanceService.updateTApproveMaintenance(tApproveMaintenance);
+                }
+                break;
+            case 4:
+                for (String i : ids
+                ) {
+                    TIntactPump pumpEntity = pumpService.getById(i);
+                    pumpEntity.setApproveStatus(0L);
+                    pumpService.updateById(pumpEntity);
+                    tApproveMaintenanceService.updateTApproveMaintenance(tApproveMaintenance);
+                }
+                break;
             default:
                 break;
         }

+ 12 - 0
master/src/main/java/com/ruoyi/project/intact/domain/TApproveMaintenance.java

@@ -84,11 +84,23 @@ public class TApproveMaintenance extends BaseEntity
     @Excel(name = "部门id")
     private Long deptId;
 
+    @TableField(exist = false)
     private Long wxjl;
 
+    @TableField(exist = false)
+    private String  userName;
+
     @TableField(exist = false)
     private List<Object> devList;
 
+    public String getUserName() {
+        return userName;
+    }
+
+    public void setUserName(String userName) {
+        this.userName = userName;
+    }
+
     public List<Object> getDevList() {
         return devList;
     }

+ 4 - 1
master/src/main/java/com/ruoyi/project/intact/mapper/TApproveMaintenanceMapper.java

@@ -1,8 +1,11 @@
 package com.ruoyi.project.intact.mapper;
 
 import java.util.List;
+
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
 import com.ruoyi.framework.aspectj.lang.annotation.DataScope;
 import com.ruoyi.project.intact.domain.TApproveMaintenance;
+import com.ruoyi.project.sems.domain.TApprove;
 
 /**
  * 设备完整性维修申请Mapper接口
@@ -10,7 +13,7 @@ import com.ruoyi.project.intact.domain.TApproveMaintenance;
  * @author ruoyi
  * @date 2022-06-27
  */
-public interface TApproveMaintenanceMapper 
+public interface TApproveMaintenanceMapper extends BaseMapper<TApproveMaintenance>
 {
     /**
      * 查询设备完整性维修申请

+ 1 - 0
master/src/main/java/com/ruoyi/project/intact/mapper/TIntactGjMapper.java

@@ -7,6 +7,7 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper;
 import com.ruoyi.framework.aspectj.lang.annotation.DataScope;
 import com.ruoyi.project.intact.domain.TIntactApprove;
 import com.ruoyi.project.intact.domain.TIntactGj;
+import com.ruoyi.project.intact.domain.TIntactGyl;
 
 /**
  * 设备完整性管件台账Mapper接口

+ 9 - 0
ui/src/api/intact/approve.js

@@ -24,3 +24,12 @@ export function getApproveInfo(id) {
   })
 }
 
+// 设备维修申请处理
+export function handleApprove(data) {
+  return request({
+    url: '/intact/maintenance/handle',
+    data: data,
+    method: 'put'
+  })
+}
+

+ 61 - 0
ui/src/api/intact/maintenance.js

@@ -0,0 +1,61 @@
+import request from '@/utils/request'
+
+// 查询设备完整性维修申请列表
+export function listMaintenance(query) {
+  return request({
+    url: '/intact/maintenance/list',
+    method: 'get',
+    params: query
+  })
+}
+
+export function hisApprovelist(query) {
+  return request({
+    url: '/intact/maintenance/hisApprovelist',
+    method: 'get',
+    params: query
+  })
+}
+
+// 查询设备完整性维修申请详细
+export function getMaintenance(id) {
+  return request({
+    url: '/intact/maintenance/' + id,
+    method: 'get'
+  })
+}
+
+// 新增设备完整性维修申请
+export function addMaintenance(data) {
+  return request({
+    url: '/intact/maintenance',
+    method: 'post',
+    data: data
+  })
+}
+
+// 修改设备完整性维修申请
+export function updateMaintenance(data) {
+  return request({
+    url: '/intact/maintenance',
+    method: 'put',
+    data: data
+  })
+}
+
+// 删除设备完整性维修申请
+export function delMaintenance(id) {
+  return request({
+    url: '/intact/maintenance/' + id,
+    method: 'delete'
+  })
+}
+
+// 导出设备完整性维修申请
+export function exportMaintenance(query) {
+  return request({
+    url: '/intact/maintenance/export',
+    method: 'get',
+    params: query
+  })
+}

+ 18 - 13
ui/src/views/approve/approveDetail/specMaintenance-detail.vue

@@ -2,7 +2,8 @@
   <el-dialog
     :title="!this.taskForm.taskId == '' ? $t('处理') : $t('详情')"
     :close-on-click-modal="false"
-    :visible.sync="visible">
+    :visible.sync="visible"
+    :append-to-body="true">
     <el-form :model="taskForm" :rules="dataRule" ref="dataForm" @keyup.enter.native="" label-width="80px">
       <el-form-item :label="$t('设备')">
         <el-table
@@ -398,8 +399,11 @@
         <el-col :span="8">
           <el-form-item :label="$t('申请类型')" prop="approveType">
             <el-select v-model="dataForm.approveType" :placeholder="$t('message.select')" disabled>
-              <el-option>
-                维修
+              <el-option
+                v-for="dict in approveOption"
+                :key="dict.dictValue"
+                :label="dict.dictLabel"
+                :value="parseInt(dict.dictValue)">
               </el-option>
             </el-select>
           </el-form-item>
@@ -418,16 +422,16 @@
       <el-button v-if="!this.taskForm.taskId == ''" type="primary" @click="dataFormSubmit(1)" :disabled="submitDisabled">{{$t('通过')}}</el-button>
       <el-button v-if="!this.taskForm.taskId == ''" type="danger" @click="dataFormSubmit(0)" :disabled="submitDisabled">{{$t('拒绝')}}</el-button>
     </span>
-<!--    <div>-->
-<!--      <span>{{$t('流转详情')}}</span>-->
-<!--      <el-table :data="historyList" border v-loading="historyLoading" style="width: 100%;">-->
-<!--        <el-table-column prop="taskName" header-align="center" align="center" :label="$t('流程进度')"></el-table-column>-->
-<!--        <el-table-column prop="userName" header-align="center" align="center" :label="$t('姓名')"></el-table-column>-->
-<!--        <el-table-column prop="taskCreateTime" header-align="center" align="center" :label="$t('开始时间')"></el-table-column>-->
-<!--        <el-table-column prop="taskEndTime" header-align="center" align="center" :label="$t('结束时间')"></el-table-column>-->
-<!--        <el-table-column prop="comment" header-align="center" align="center" :label="$t('审批意见')"></el-table-column>-->
-<!--      </el-table>-->
-<!--    </div>-->
+    <div>
+      <span>{{$t('流转详情')}}</span>
+      <el-table :data="historyList" border v-loading="historyLoading" style="width: 100%;">
+        <el-table-column prop="taskName" header-align="center" align="center" :label="$t('流程进度')"></el-table-column>
+        <el-table-column prop="userName" header-align="center" align="center" :label="$t('姓名')"></el-table-column>
+        <el-table-column prop="taskCreateTime" header-align="center" align="center" :label="$t('开始时间')"></el-table-column>
+        <el-table-column prop="taskEndTime" header-align="center" align="center" :label="$t('结束时间')"></el-table-column>
+        <el-table-column prop="comment" header-align="center" align="center" :label="$t('审批意见')"></el-table-column>
+      </el-table>
+    </div>
     <record v-if="recordVisible" ref="recordDeal"></record>
   </el-dialog>
 </template>
@@ -555,6 +559,7 @@
       this.visible = true
       this.queryParams.processId = processId;
       getHistorylist(this.queryParams).then(response => {
+        console.log(response.rows)
         this.historyList = response.rows;
         this.historyLoading = false
       });

+ 670 - 0
ui/src/views/approve/pending/specMaintenance-deal.vue

@@ -0,0 +1,670 @@
+<template>
+  <el-dialog
+    :title="!this.taskForm.taskId == '' ? $t('处理') : $t('详情')"
+    :close-on-click-modal="false"
+    :visible.sync="visible">
+    <el-form :model="taskForm" :rules="dataRule" ref="dataForm" @keyup.enter.native="" label-width="80px">
+      <el-form-item :label="$t('设备')">
+        <el-table
+          v-show="dataForm.approveType != 7 && dataForm.devType == 1"
+          :data="devList"
+          border
+          style="width: 100%;  height: 95px">
+          <el-table-column
+            prop="plantCode"
+            header-align="center"
+            align="center"
+            :label="$t('装置名称')">
+          </el-table-column>
+          <el-table-column
+            prop="devno"
+            header-align="center"
+            align="center"
+            :label="$t('位号')">
+          </el-table-column>
+          <el-table-column
+            prop="devname"
+            header-align="center"
+            align="center"
+            :show-overflow-tooltip="true"
+            width="150"
+            :label="$t('设备名称')">
+          </el-table-column>
+          <el-table-column
+            prop="useno"
+            header-align="center"
+            align="center"
+            :show-overflow-tooltip="true"
+            :label="$t('使用证编号')">
+          </el-table-column>
+          <el-table-column
+            prop="medium"
+            header-align="center"
+            align="center"
+            :show-overflow-tooltip="true"
+            :label="$t('介质')">
+          </el-table-column>
+          <el-table-column
+            prop="desPressure"
+            header-align="center"
+            align="center"
+            :show-overflow-tooltip="true"
+            :label="$t('设计压力')+'(MPa)'">
+          </el-table-column>
+          <el-table-column
+            prop="desTemp"
+            header-align="center"
+            align="center"
+            :show-overflow-tooltip="true"
+            :label="$t('设计温度')+'(℃)'">
+          </el-table-column>
+        </el-table>
+        <el-table
+          v-show="dataForm.approveType != 7 && dataForm.devType == 2"
+          :data="devList"
+          border
+          style="width: 100%; height: 95px">
+          <el-table-column
+            prop="plantCode"
+            header-align="center"
+            align="center"
+            width="100"
+            :label="$t('装置名称')">
+          </el-table-column>
+          <el-table-column
+            prop="devno"
+            header-align="center"
+            align="center"
+            width="120"
+            :label="$t('位号')">
+          </el-table-column>
+<!--          <el-table-column-->
+<!--            prop="starting"-->
+<!--            header-align="center"-->
+<!--            align="center"-->
+<!--            width="100"-->
+<!--            :show-overflow-tooltip="true"-->
+<!--            :label="$t('起点')">-->
+<!--          </el-table-column>-->
+<!--          <el-table-column-->
+<!--            prop="ending"-->
+<!--            header-align="center"-->
+<!--            align="center"-->
+<!--            width="100"-->
+<!--            :show-overflow-tooltip="true"-->
+<!--            :label="$t('终点')">-->
+<!--          </el-table-column>-->
+          <el-table-column
+            prop="medium"
+            header-align="center"
+            align="center"
+            width="100"
+            :show-overflow-tooltip="true"
+            :label="$t('介质')">
+          </el-table-column>
+          <el-table-column
+            prop="desPressure"
+            header-align="center"
+            align="center"
+            :label="$t('设计压力')">
+          </el-table-column>
+          <el-table-column
+            prop="desTemp"
+            header-align="center"
+            align="center"
+            :label="$t('设计温度')">
+          </el-table-column>
+          <el-table-column
+            prop="optPressure"
+            header-align="center"
+            align="center"
+            :label="$t('工作压力')">
+          </el-table-column>
+          <el-table-column
+            prop="optTemp"
+            header-align="center"
+            align="center"
+            width="100"
+            :show-overflow-tooltip="true"
+            :label="$t('工作温度')">
+          </el-table-column>
+        </el-table>
+        <el-table
+          v-show="dataForm.devType == 3"
+          :data="devList"
+          border
+          style="width: 100%; height: 95px">
+          <el-table-column
+            prop="plantCode"
+            header-align="center"
+            align="center"
+            :label="$t('装置名称')">
+          </el-table-column>
+          <el-table-column
+            prop="docno"
+            header-align="center"
+            align="center"
+            :show-overflow-tooltip="true"
+            :label="$t('档案号')">
+          </el-table-column>
+          <el-table-column
+            prop="devname"
+            header-align="center"
+            align="center"
+            :show-overflow-tooltip="true"
+            width="150"
+            :label="$t('设备名称')">
+          </el-table-column>
+          <el-table-column
+            prop="capacity"
+            header-align="center"
+            align="center"
+            :show-overflow-tooltip="true"
+            :label="$t('起吊重量')+'(ton)'">
+          </el-table-column>
+          <el-table-column
+            prop="location"
+            header-align="center"
+            align="center"
+            :show-overflow-tooltip="true"
+            :label="$t('使用地点')">
+          </el-table-column>
+        </el-table>
+        <el-table
+          v-show="dataForm.devType == 4"
+          :data="devList"
+          border
+          style="width: 100%; height: 95px">
+          <el-table-column
+            prop="plantCode"
+            header-align="center"
+            align="center"
+            :show-overflow-tooltip="true"
+            :label="$t('装置名称')">
+          </el-table-column>
+          <el-table-column
+            prop="devno"
+            header-align="center"
+            align="center"
+            :show-overflow-tooltip="true"
+            :label="$t('位号')">
+          </el-table-column>
+          <el-table-column
+            prop="devname"
+            header-align="center"
+            align="center"
+            :show-overflow-tooltip="true"
+            width="120"
+            :label="$t('设备名称')">
+          </el-table-column>
+          <el-table-column
+            prop="useno"
+            header-align="center"
+            align="center"
+            :show-overflow-tooltip="true"
+            :label="$t('使用证编号')">
+          </el-table-column>
+          <el-table-column
+            prop="desTemp"
+            header-align="center"
+            align="center"
+            :label="$t('设计温度')+'(℃)'">
+          </el-table-column>
+          <el-table-column
+            prop="desPressure"
+            header-align="center"
+            align="center"
+            :label="$t('设计压力')+'(MPa)'">
+          </el-table-column>
+        </el-table>
+        <el-table
+          v-show="dataForm.devType == 5"
+          :data="devList"
+          border
+          style="width: 100%; height: 95px">
+          <el-table-column
+            prop="plantCode"
+            header-align="center"
+            align="center"
+            :label="$t('装置名称')">
+          </el-table-column>
+          <el-table-column
+            prop="docno"
+            header-align="center"
+            align="center"
+            :label="$t('docNo')">
+          </el-table-column>
+          <el-table-column
+            prop="devname"
+            header-align="center"
+            align="center"
+            :show-overflow-tooltip="true"
+            width="150"
+            :label="$t('设备名称')">
+          </el-table-column>
+          <el-table-column
+            prop="model"
+            header-align="center"
+            align="center"
+            :show-overflow-tooltip="true"
+            width="120"
+            :label="$t('型号')">
+          </el-table-column>
+          <el-table-column
+            prop="location"
+            header-align="center"
+            align="center"
+            :show-overflow-tooltip="true"
+            :label="$t('使用地点')">
+          </el-table-column>
+        </el-table>
+        <el-table
+          v-show="dataForm.devType == 6"
+          :data="devList"
+          border
+          style="width: 100%; height: 95px">
+          <el-table-column
+            prop="plantCode"
+            header-align="center"
+            align="center"
+            :label="$t('装置名称')">
+          </el-table-column>
+          <el-table-column
+            prop="useDept"
+            header-align="center"
+            align="center"
+            :label="$t('dept')">
+          </el-table-column>
+          <el-table-column
+            prop="carNo"
+            header-align="center"
+            align="center"
+            :label="$t('plateNo')">
+          </el-table-column>
+          <el-table-column
+            prop="docno"
+            header-align="center"
+            align="center"
+            :label="$t('docNo')">
+          </el-table-column>
+          <el-table-column
+            prop="model"
+            header-align="center"
+            align="center"
+            :show-overflow-tooltip="true"
+            width="120"
+            :label="$t('model')">
+          </el-table-column>
+        </el-table>
+        <el-table
+          v-show="dataForm.devType == 7"
+          :data="devList"
+          border
+          style="width: 100%; height: 95px">
+          <el-table-column
+            prop="plantCode"
+            header-align="center"
+            align="center"
+            :label="$t('装置名称')">
+          </el-table-column>
+          <el-table-column
+            prop="unit"
+            header-align="center"
+            align="center"
+            :label="$t('单元')">
+          </el-table-column>
+          <el-table-column
+            prop="devno"
+            header-align="center"
+            align="center"
+            :label="$t('位号')">
+          </el-table-column>
+          <el-table-column
+            prop="devname"
+            header-align="center"
+            align="center"
+            :label="$t('名称')">
+          </el-table-column>
+          <el-table-column
+            prop="createno"
+            header-align="center"
+            align="center"
+            :label="$t('制造编号')">
+          </el-table-column>
+          <el-table-column
+            prop="indiameter"
+            header-align="center"
+            align="center"
+            :show-overflow-tooltip="true"
+            width="120"
+            :label="$t('内径')+'mm'">
+          </el-table-column>
+          <el-table-column
+            prop="height"
+            header-align="center"
+            align="center"
+            :show-overflow-tooltip="true"
+            width="120"
+            :label="$t('高(长)')+' mm'">
+          </el-table-column>
+          <el-table-column
+            prop="chickness"
+            header-align="center"
+            align="center"
+            :show-overflow-tooltip="true"
+            width="120"
+            :label="$t('壁厚(mm)')">
+          </el-table-column>
+          <el-table-column
+            prop="volume"
+            header-align="center"
+            align="center"
+            :show-overflow-tooltip="true"
+            width="120"
+            :label="$t('容积mm³')">
+          </el-table-column>
+          <el-table-column
+            prop="medium"
+            header-align="center"
+            align="center"
+            :show-overflow-tooltip="true"
+            width="120"
+            :label="$t('介质')">
+          </el-table-column>
+          <el-table-column
+            prop="material"
+            header-align="center"
+            align="center"
+            :show-overflow-tooltip="true"
+            width="120"
+            :label="$t('材料')">
+          </el-table-column>
+        </el-table>
+        <el-button @click="recordHandle(devList,dataForm)" type="text" v-if="devList.length >1">{{$t('查看详细信息')}}</el-button>
+      </el-form-item>
+      <el-row>
+        <el-col :span="8" v-if="dataForm.approveType != 8">
+          <el-form-item :label="$t('设备类型')" prop="devType">
+            <el-select v-model="dataForm.devType" :placeholder="$t('message.select')" disabled>
+              <el-option
+                v-for="dict in devTypeOption"
+                :key="dict.dictValue"
+                :label="dict.dictLabel"
+                :value="parseInt(dict.dictValue)">
+              </el-option>
+            </el-select>
+          </el-form-item>
+        </el-col>
+        <el-col :span="8">
+          <el-form-item :label="$t('审批类型')" prop="approveType">
+            <el-select v-model="dataForm.approveType" :placeholder="$t('message.select')" disabled>
+              <el-option
+                v-for="dict in approveOption"
+                :key="dict.dictValue"
+                :label="dict.dictLabel"
+                :value="parseInt(dict.dictValue)">
+              </el-option>
+            </el-select>
+          </el-form-item>
+        </el-col>
+      </el-row>
+      <el-form-item :label="$t('申请时间')" prop="creattime">
+        <el-input v-model="dataForm.creattime" disabled></el-input>
+      </el-form-item>
+    </el-form>
+    <form ref="downloadForm" :action="downloadAction" target="FORMSUBMIT">
+      <input name="approveId" v-model="dataForm.id"  hidden  />
+      <input name="processId" v-model="dataForm.processId"  hidden  />
+    </form>
+    <span slot="footer" class="dialog-footer">
+      <el-button v-if="this.taskForm.taskId == ''" @click="visible = false">{{$t('message.return')}}</el-button>
+      <el-button v-if="!this.taskForm.taskId == ''" type="primary" @click="dataFormSubmit(1)" :disabled="submitDisabled">{{$t('批准')}}</el-button>
+      <el-button v-if="!this.taskForm.taskId == ''" type="danger" @click="dataFormSubmit(0)" :disabled="submitDisabled">{{$t('拒绝')}}</el-button>
+    </span>
+<!--    <div>-->
+<!--      <span>{{$t('流转详情')}}</span>-->
+<!--      <el-table :data="historyList" border v-loading="historyLoading" style="width: 100%;">-->
+<!--        <el-table-column prop="taskName" header-align="center" align="center" :label="$t('流程进度')"></el-table-column>-->
+<!--        <el-table-column prop="userName" header-align="center" align="center" :label="$t('姓名')"></el-table-column>-->
+<!--        <el-table-column prop="taskCreateTime" header-align="center" align="center" :label="$t('开始时间')"></el-table-column>-->
+<!--        <el-table-column prop="taskEndTime" header-align="center" align="center" :label="$t('结束时间')"></el-table-column>-->
+<!--        <el-table-column prop="comment" header-align="center" align="center" :label="$t('审批意见')"></el-table-column>-->
+<!--      </el-table>-->
+<!--    </div>-->
+    <record v-if="recordVisible" ref="recordDeal"></record>
+  </el-dialog>
+</template>
+
+<script>
+  import {getToken} from "@/utils/auth";
+
+  import {getApproveInfo, handleApprove} from "@/api/intact/approve";
+  import {getHistorylist} from "@/api/ehs/approvedanger";
+  import record from "../approveDetail/spec-itemDetail";
+
+  export default {
+  name: "spec-deal",
+  components: {record},
+  data() {
+    return {
+      loading: true,
+      // 总条数
+      total: 0,
+      approvedangerList: [],
+      recordVisible: false,
+      // 遮罩层
+      historyLoading: false,
+      //流转列表
+      historyList: [],
+      visible: false,
+      devList: [],
+      dataList: [],
+      fileTips: '',
+      showDelay: false,
+      submitDisabled: false,
+      dataListLoading:true,
+      taskName: '',
+      dataForm: {
+        id: 0,
+        userId: '',
+        devId: '',
+        devType: '',
+        approveType: '',
+        content: '',
+        fileUrls: '',
+        reUrls: '',
+        status: '',
+        creattime: '',
+        plantCode: '',
+        unit: '',
+        devname: '',
+        devno: '',
+        files: [],
+        delayDate: '',
+        delayReason: '',
+        delayMeasure: '',
+        delayNotice: ''
+      },
+      taskForm: {
+        comment: '',
+        taskId: '',
+        files: '',
+        govDate: '',
+        govFileList: []
+      },
+      // 查询参数
+      queryParams: {
+        processId: null,
+      },
+      doc: {
+        file: "",
+        // 是否显示弹出层(报告附件)
+        open: false,
+        // 弹出层标题(报告附件)
+        title: "",
+        // 是否禁用上传
+        isUploading: false,
+        // 是否更新已经存在的用户数据
+        updateSupport: 0,
+        // 报告附件上传位置编号
+        ids: 0,
+        // 设置上传的请求头部
+        headers: { Authorization: "Bearer " + getToken() },
+        // 上传的地址
+        url: process.env.VUE_APP_BASE_API + "/sems/specfile/uploadFile",
+        commonfileList: null,
+        pType: 'traning',
+        pId: null
+      },
+      dataRule: {
+        approveType: [
+          { required: true, message: this.$t('approveType') + this.$t('notEmpty'), trigger: 'blur' }
+        ],
+        content: [
+          { required: true, message: this.$t('content') + this.$t('notEmpty'), trigger: 'blur' }
+        ]
+      },
+      downloadAction: process.env.VUE_APP_BASE_API +'/sems/approve/exportPDF',
+      approveOption: [],
+      devTypeOption: [{dictValue:1,dictLabel:'工业炉'},{dictValue:2,dictLabel:'压缩机'},{},{}],
+      belong: '',
+      fileList: [],
+    };
+  },
+  watch: {
+    // 根据名称筛选部门树
+    deptName(val) {
+      this.$refs.tree.filter(val);
+    }
+  },
+  created() {
+
+  },
+  methods: {
+    init (id, taskId, processId,taskName) {
+      this.getDicts("spec_approve_modify_type").then(response => {
+        this.approveOption = response.data;
+      });
+      this.getDicts("spec_dev_type").then(response => {
+        // this.devTypeOption = response.data;
+      });
+      this.dataForm.processId = processId
+      this.taskName = taskName
+      this.taskForm.taskId = taskId
+      this.dataForm.id = id || 0
+      this.visible = true
+      this.queryParams.processId = processId;
+      getHistorylist(this.queryParams).then(response => {
+        this.historyList = response.rows;
+        this.historyLoading = false
+      });
+      getApproveInfo(id).then(response => {
+        this.taskForm.businessKey = response.data.id
+        this.dataForm.userId = response.data.userId
+        this.dataForm.devId = response.data.devId
+        this.dataForm.devType = response.data.devType
+        // this.dataForm.approveType = response.data.approveType
+        this.dataForm.approveType = '维修'
+        this.dataForm.content = response.data.content
+        this.dataForm.fileUrls = response.data.fileUrls
+        this.dataForm.reUrls = response.data.reUrls
+        this.dataForm.status = response.data.status
+        this.dataForm.creattime = response.data.creattime
+        this.dataForm.plantCode = response.data.plantCode
+        this.dataForm.unit = response.data.unit
+        this.dataForm.devname = response.data.devname
+        this.dataForm.devno = response.data.devno
+        this.dataForm.files = response.data.files
+        this.devList = response.data.devList
+        this.dataForm.delayDate = response.data.delayDate
+        this.dataForm.delayReason = response.data.delayReason
+        this.dataForm.delayMeasure = response.data.delayMeasure
+        this.dataForm.delayNotice = response.data.delayNotice
+      });
+
+    },
+    // 设备类型:字典翻译
+    devTypeFormat(row, column) {
+      // return this.selectDictLabel(this.devTypeOptions, row.devType);
+    },
+    // 审批类型字典翻译
+    approveTypeFormat(row, column) {
+      return this.selectDictLabel(this.approveTypeOptions, row.approveType);
+    },
+
+    // 取消按钮
+    cancel() {
+      this.visible = false;
+      this.reset();
+    },
+    // 表单重置
+    reset() {
+      this.form = {
+        id: null,
+        userId: null,
+        devId: null,
+        devType: null,
+        approveType: null,
+        content: null,
+        fileUrls: null,
+        reUrls: null,
+        status: 0,
+        creattime: null,
+        endtime: null,
+        processId: null,
+        govDate: null,
+        delayDate: null,
+        delayReason: null,
+        delayMeasure: null,
+        delayNotice: null,
+        apNo: null,
+        checkDate: null,
+        reportId: null,
+        monthId: null,
+        delFlag: null,
+        deptId: null
+      };
+      this.resetForm("form");
+    },
+
+    /** 提交按钮 */
+    // 表单提交
+    dataFormSubmit (val) {
+      this.submitDisabled = true
+      console.log(this.taskForm.govFileList)
+      this.dataForm.files = []
+      if (this.taskForm.govFileList.length > 0) {
+        for (let i = 0; i < this.taskForm.govFileList.length; i++) {
+          let obj = {}
+          obj.fileName = this.taskForm.govFileList[i].response.fileName
+          obj.fileUrl = this.taskForm.govFileList[i].response.url
+          this.dataForm.files.push(obj)
+        }
+      }
+      this.taskForm.condition = val
+      this.taskForm.govFiles = this.dataForm.files
+      handleApprove(this.taskForm).then(response => {
+        this.submitDisabled = false
+        this.msgSuccess(this.$t('处理成功'));
+        this.visible = false;
+        this.$emit('refreshDataList')
+      });
+      this.$nextTick(function () {
+        this.comment = ''
+      })
+    },
+    recordHandle(devList,dataForm){
+      this.recordVisible = true
+      this.$nextTick(() => {
+        this.$refs.recordDeal.init(devList,dataForm);
+      })
+    },
+}
+}
+
+
+</script>
+
+<style scoped>
+
+</style>

+ 10 - 1
ui/src/views/approve/taskdone/index.vue

@@ -54,6 +54,7 @@
     <add-or-update v-if="specDealVisible" ref="specDeal" @refreshDataList="getList"></add-or-update>
     <spec-modify v-if="specModifyDealVisible" ref="specModifyDeal" @refreshDataList="getList"></spec-modify>
     <spec-training-plan v-if="specTrainingPlanVisible" ref="specTrainingPlan" @refreshDataList="getList"></spec-training-plan>
+    <spec-maintenance v-if="specMaintenanceVisible" ref="specMaintenance" @refreshDataList="getList"></spec-maintenance>
   </div>
 </template>
 
@@ -67,10 +68,11 @@
   import ProcessImg from "../processImg/index";
   import SpecModify from '../approveDetail/specModify-detail';
   import SpecTrainingPlan from '../approveDetail/specTrainingPlan-detaill';
+  import SpecMaintenance from "@/views/approve/approveDetail/specMaintenance-detail";
   export default {
     name: "Taskdone",
     components: {
-      Treeselect, AddOrUpdate,ProcessImg,SpecModify,SpecTrainingPlan
+      Treeselect, AddOrUpdate,ProcessImg,SpecModify,SpecTrainingPlan,SpecMaintenance
     },
     data() {
       return {
@@ -80,6 +82,7 @@
         specDealVisible: false,
         specModifyDealVisible: false,
         specTrainingPlanVisible: false,
+        specMaintenanceVisible: false,
         // 选中数组
         ids: [],
         // 非单个禁用
@@ -191,6 +194,12 @@
             console.log(row.taskName)
             this.$refs.specTrainingPlan.init(row.approveObject.id, row.taskId, row.processId,row.taskName)
           })
+        }else if (row.processName == "设备维修审批流程") {
+          this.specMaintenanceVisible = true
+          this.$nextTick(() => {
+            console.log(row.taskName)
+            this.$refs.specMaintenance.init(row.approveObject.id, row.taskId, row.processId, row.taskName)
+          })
         }else {
           this.approveInfo = row;
           this.infoTaskName = row.taskName;

+ 347 - 0
ui/src/views/intact/approve/tapprove-maintenance-his.vue

@@ -0,0 +1,347 @@
+<template>
+  <el-dialog :title="$t('申请记录')" :visible.sync="visible" width="1200px" append-to-body>
+    <el-table v-loading="loading" :data="approveList" @selection-change="handleSelectionChange" :height="clientHeight" border>
+      <el-table-column :label="$t('申请人')" align="center" prop="userName" :show-overflow-tooltip="true"/>
+      <el-table-column :label="$t('设备类型')+':'" align="center" prop="devType" :formatter="devTypeFormat" />
+      <el-table-column :label="$t('审批类型')" align="center" prop="approveType"  :formatter="approveTypeFormat"/>
+      <el-table-column :label="$t('内容')" align="center" prop="content" :show-overflow-tooltip="true"/>
+      <el-table-column :label="$t('申请状态')" align="center" prop="status"  :formatter="statusFormat"/>
+      <el-table-column :label="$t('开始时间')" align="center" prop="creattime" width="100">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.creattime, '{y}-{m}-{d}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column :label="$t('结束时间')" align="center" prop="endtime" width="100">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.endtime, '{y}-{m}-{d}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column :label="$t('操作')" align="center"  width="120" class-name="small-padding fixed-width">
+        <template slot-scope="scope">
+          <el-button
+            size="mini"
+            type="text"
+            @click="detailHandle(scope.row)"
+          >{{ $t('查看') }}</el-button>
+        </template>
+      </el-table-column>
+    </el-table>
+<!--    <pagination-->
+<!--      v-show="total>0"-->
+<!--      :total="total"-->
+<!--      :page.sync="queryParams.pageNum"-->
+<!--      :limit.sync="queryParams.pageSize"-->
+<!--      @pagination="getList"-->
+<!--    />-->
+
+    <spec-maintenance v-if="specMaintenanceVisible" ref="specMaintenance" @refreshDataList="getList"></spec-maintenance>
+  </el-dialog>
+</template>
+
+<script>
+import { listMaintenance,hisApprovelist} from "@/api/intact/maintenance";
+import { treeselect } from "@/api/system/dept";
+import { getToken } from "@/utils/auth";
+import Treeselect from "@riophae/vue-treeselect";
+import "@riophae/vue-treeselect/dist/vue-treeselect.css";
+import AddOrUpdate from '../../approve/approveDetail/spec-detail';
+import Editor from '@/components/Editor';
+import SpecMaintenance from "@/views/approve/approveDetail/specMaintenance-detail";
+
+export default {
+  name: "Approve",
+  components: { Treeselect,SpecMaintenance },
+  // components: { Editor },
+  data() {
+    return {
+      // 遮罩层
+      loading: true,
+      visible: false,
+      specMaintenanceVisible: false,
+      // 选中数组
+      ids: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: false,
+      // 总条数
+      total: 0,
+      // 特种设备申请表格数据
+      approveList: [],
+      // 弹出层标题
+      title: "",
+      // 部门树选项
+      deptOptions: undefined,
+      clientHeight:300,
+      // 是否显示弹出层
+      open: false,
+      // 设备类型:字典
+      devTypeOptions: [{dictValue:1,dictLabel:'工业炉'},{dictValue:2,dictLabel:'压缩机'},{},{}],
+      // 审批类型字典
+      approveTypeOptions: [{dictValue:1,dictLabel:'维修'}],
+      statusOptions: [],
+        // 用户导入参数
+        upload: {
+            // 是否显示弹出层(用户导入)
+            open: false,
+            // 弹出层标题(用户导入)
+            title: "",
+            // 是否禁用上传
+            isUploading: false,
+            // 是否更新已经存在的用户数据
+            updateSupport: 0,
+            // 设置上传的请求头部
+            headers: { Authorization: "Bearer " + getToken() },
+            // 上传的地址
+            url: process.env.VUE_APP_BASE_API + "/sems/approve/importData"
+        },
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 20,
+        userId: null,
+        devId: null,
+        devType: null,
+        approveType: null,
+        content: null,
+        fileUrls: null,
+        reUrls: null,
+        status: null,
+        creattime: null,
+        endtime: null,
+        processId: null,
+        govDate: null,
+        delayDate: null,
+        delayReason: null,
+        delayMeasure: null,
+        delayNotice: null,
+        apNo: null,
+        checkDate: null,
+        reportId: null,
+        monthId: null,
+        deptId: null
+      },
+      // 表单参数
+      form: {},
+      // 表单校验
+      rules: {
+        userId: [
+          { required: true, message: this.$t('申请人')+this.$t('空格') +'id' + this.$t('不能为空'), trigger: "blur" }
+        ],
+      }
+    };
+  },
+  watch: {
+        // 根据名称筛选部门树
+        deptName(val) {
+            this.$refs.tree.filter(val);
+        }
+   },
+  created() {
+      //设置表格高度对应屏幕高度
+      this.$nextTick(() => {
+          this.clientHeight = document.body.clientHeight -250
+      })
+    this.getList();
+    this.getTreeselect();
+    this.getDicts("spec_dev_type").then(response => {
+      // this.devTypeOptions = response.data;
+    });
+    this.getDicts("spec_approve_type").then(response => {
+      // this.approveTypeOptions = response.data;
+    });
+    this.getDicts("spec_approve_res").then(response => {
+      this.statusOptions = response.data;
+    });
+  },
+  methods: {
+    init (row, type) {
+
+      this.visible = true
+      this.loading = true;
+      this.queryParams.devId = row.id
+      // this.queryParams.devType = row.devType
+      this.queryParams.devType = type
+      hisApprovelist(this.queryParams).then(response => {
+        console.log("aaa")
+        console.log(response.data)
+        this.approveList = response.data;
+        this.total = response.total;
+        this.loading = false;
+      });
+    },
+    /** 查询特种设备申请列表 */
+    getList() {
+
+    },
+     /** 查询部门下拉树结构 */
+     getTreeselect() {
+          treeselect().then(response => {
+              this.deptOptions = response.data;
+          });
+     },
+    // 设备类型:字典翻译
+    devTypeFormat(row, column) {
+      return this.selectDictLabel(this.devTypeOptions, row.devType);
+    },
+    // 审批类型字典翻译
+    approveTypeFormat(row, column) {
+      return this.selectDictLabel(this.approveTypeOptions, row.approveType);
+    },
+    // 审批类型字典翻译
+    statusFormat(row, column) {
+      return this.selectDictLabel(this.statusOptions, row.status);
+    },
+    // 取消按钮
+    cancel() {
+      this.open = false;
+      this.reset();
+    },
+    // 表单重置
+    reset() {
+      this.form = {
+        id: null,
+        userId: null,
+        devId: null,
+        devType: null,
+        approveType: null,
+        content: null,
+        fileUrls: null,
+        reUrls: null,
+        status: 0,
+        creattime: null,
+        endtime: null,
+        processId: null,
+        govDate: null,
+        delayDate: null,
+        delayReason: null,
+        delayMeasure: null,
+        delayNotice: null,
+        apNo: null,
+        checkDate: null,
+        reportId: null,
+        monthId: null,
+        delFlag: null,
+        deptId: null
+      };
+      this.resetForm("form");
+    },
+    /** 搜索按钮操作 */
+    handleQuery() {
+      this.queryParams.pageNum = 1;
+      this.getList();
+    },
+    /** 重置按钮操作 */
+    resetQuery() {
+      this.resetForm("queryForm");
+      this.handleQuery();
+    },
+    // 多选框选中数据
+    handleSelectionChange(selection) {
+      this.ids = selection.map(item => item.id)
+      this.single = selection.length!==1
+      this.multiple = !selection.length
+    },
+    /** 新增按钮操作 */
+    handleAdd() {
+      this.reset();
+      this.open = true;
+      this.title = this.$t('添加特种设备申请');
+    },
+    /** 修改按钮操作 */
+    handleUpdate(row) {
+      this.reset();
+      const id = row.id || this.ids
+      getApprove(id).then(response => {
+        this.form = response.data;
+        this.open = true;
+        this.title =this.$t('修改特种设备申请');
+      });
+    },
+    /** 提交按钮 */
+    submitForm() {
+      this.$refs["form"].validate(valid => {
+        if (valid) {
+          if (this.form.id != null) {
+            updateApprove(this.form).then(response => {
+              this.msgSuccess(this.$t('修改成功'));
+              this.open = false;
+              this.getList();
+            });
+          } else {
+            addApprove(this.form).then(response => {
+              this.msgSuccess(this.$t('新增成功'));
+              this.open = false;
+              this.getList();
+            });
+          }
+        }
+      });
+    },
+    /** 删除按钮操作 */
+    handleDelete(row) {
+      const ids = row.id || this.ids;
+      this.$confirm(this.$t('是否确认删除?'), this.$t('警告'), {
+        confirmButtonText: this.$t('确定'),
+        cancelButtonText: this.$t('取消'),
+          type: "warning"
+        }).then(function() {
+          return delApprove(ids);
+        }).then(() => {
+          this.getList();
+        this.msgSuccess(this.$t('删除成功'));
+        })
+    },
+    /** 导出按钮操作 */
+    handleExport() {
+      const queryParams = this.queryParams;
+      this.$confirm(this.$t('是否确认导出所有特种设备申请数据项?'), this.$t('警告'), {
+        confirmButtonText: this.$t('确定'),
+        cancelButtonText: this.$t('取消'),
+          type: "warning"
+        }).then(function() {
+          return exportApprove(queryParams);
+        }).then(response => {
+          this.download(response.msg);
+        })
+    },
+      /** 导入按钮操作 */
+      handleImport() {
+          this.upload.title = this.$t('用户导入');
+          this.upload.open = true;
+      },
+      /** 下载模板操作 */
+      importTemplate() {
+          importTemplate().then(response => {
+              this.download(response.msg);
+          });
+      },
+      // 文件上传中处理
+      handleFileUploadProgress(event, file, fileList) {
+          this.upload.isUploading = true;
+      },
+      // 文件上传成功处理
+      handleFileSuccess(response, file, fileList) {
+          this.upload.open = false;
+          this.upload.isUploading = false;
+          this.$refs.upload.clearFiles();
+          this.$alert(response.msg, this.$t('导入结果'), { dangerouslyUseHTMLString: true });
+          this.getList();
+      },
+      // 提交上传文件
+      submitFileForm() {
+          this.$refs.upload.submit();
+      },
+    //操作审批流程
+    detailHandle (row) {
+      this.specMaintenanceVisible = true
+      this.$nextTick(() => {
+        console.log(row.taskName)
+        this.$refs.specMaintenance.init(row.id, row.taskId, row.processId,row.taskName)
+      })
+    },
+  }
+};
+</script>

+ 2 - 3
ui/src/views/intact/gj/index.vue

@@ -574,8 +574,8 @@
       <el-table-column label="设备名称" align="center" prop="devname" :show-overflow-tooltip="true"/>
       <el-table-column label="设备位号" align="center" prop="devno" :show-overflow-tooltip="true"/>
           <el-table-column label="档案" align="center" prop="archives" :show-overflow-tooltip="true" >
-       <template slot-scope="scope">  
-      
+       <template slot-scope="scope">
+
          <el-button icon="el-icon-folder" style="color:#6e96fa;"  @click="handleDoc(scope.row)"  ></el-button>
        </template>
       </el-table-column>
@@ -1015,7 +1015,6 @@ export default {
   components: { Treeselect },
   data() {
     return {
-      devType: 2,
       // 遮罩层
       loading: true,
       // 选中数组

+ 0 - 1
ui/src/views/intact/gyl/index.vue

@@ -980,7 +980,6 @@ export default {
   components: {Treeselect, AddApprove, HisApprove},
   data() {
     return {
-      devType: 4,
       // 遮罩层
       loading: true,
       // 选中数组

+ 202 - 0
ui/src/views/intact/gyl/intactRecord.vue

@@ -0,0 +1,202 @@
+<template>
+  <el-dialog :title="$t('一机一档')" :visible.sync="visible" width="1200px" append-to-body>
+    <el-card>
+      <div slot="header" class="clearfix">
+        <span>基本资料</span>
+      </div>
+      <div class="el-descriptions">
+        <div class="el-descriptions__body">
+          <table class="el-descriptions__table is-bordered el-descriptions--big" style="table-layout: fixed;border: 1px solid #e6ebf5;">
+            <tr class="el-descriptions-row">
+              <th colspan="1" class="el-descriptions-item__cell el-descriptions-item__label is-bordered-label "> 装置</th>
+              <td colspan="1" class="el-descriptions-item__cell el-descriptions-item__content"> {{}}</td>
+              <th colspan="1" class="el-descriptions-item__cell el-descriptions-item__label is-bordered-label "> 单元</th>
+              <td colspan="1" class="el-descriptions-item__cell el-descriptions-item__content" > {{}}</td>
+              <th colspan="1" class="el-descriptions-item__cell el-descriptions-item__label is-bordered-label "> 位号</th>
+              <td colspan="1" class="el-descriptions-item__cell el-descriptions-item__content">{{}}</td>
+            </tr>
+            <tr class="el-descriptions-row">
+              <th colspan="1" class="el-descriptions-item__cell el-descriptions-item__label is-bordered-label "> 设备名称</th>
+              <td colspan="1" class="el-descriptions-item__cell el-descriptions-item__content">{{}}</td>
+              <th colspan="1" class="el-descriptions-item__cell el-descriptions-item__label is-bordered-label "> 设备类型</th>
+              <td colspan="1" class="el-descriptions-item__cell el-descriptions-item__content">{{}}</td>
+              <th colspan="1" class="el-descriptions-item__cell el-descriptions-item__label is-bordered-label "> 使用证编号</th>
+              <td colspan="1" class="el-descriptions-item__cell el-descriptions-item__content">{{}}</td>
+            </tr>
+          </table>
+        </div>
+      </div>
+    </el-card>
+
+    <el-card>
+      <div slot="header" class="clearfix">
+        <span>原始资料(厂家,产品编号等)</span>
+      </div>
+      <el-table v-loading="loading" :data="list" border>
+
+      </el-table>
+    </el-card>
+    <el-card>
+      <div slot="header" class="clearfix">
+        <span>安装资料、使用说明</span>
+      </div>
+      <el-table v-loading="loading" :data="list" border>
+
+      </el-table>
+    </el-card>
+    <el-card>
+      <div slot="header" class="clearfix">
+        <span> 巡检记录</span><div style="float: right;margin-bottom: -14px">
+        <el-form :model="queryDeviceParams" ref="queryRegularForm" label-width="68px" :inline="true">
+          <el-form-item :label="$t('年份')" prop="year">
+            <el-date-picker clearable size="small" style="width: 200px"
+                            v-model="queryDeviceParams.year"
+                            type="year"
+                            value-format="yyyy"
+                            :placeholder="$t('请选择') + $t('年份')">
+            </el-date-picker>
+          </el-form-item>
+          <el-button type="cyan" icon="el-icon-search" size="mini" @click="staffPlanQuery" style="margin-left: 20px;">
+            {{ $t('搜索') }}</el-button>
+        </el-form>
+      </div>
+      </div>
+
+      <el-table :data="list" v-loading="planLoading"  border>
+
+      </el-table>
+    </el-card>
+    <el-card>
+      <div slot="header" class="clearfix">
+        <span> 维修记录</span><div style="float: right;margin-bottom: -14px">
+        <el-form :model="queryDeviceParams" ref="queryRegularForm" label-width="68px" :inline="true">
+          <el-form-item :label="$t('年份')" prop="year">
+            <el-date-picker clearable size="small" style="width: 200px"
+                            v-model="queryDeviceParams.year"
+                            type="year"
+                            value-format="yyyy"
+                            :placeholder="$t('请选择') + $t('年份')">
+            </el-date-picker>
+          </el-form-item>
+          <el-button type="cyan" icon="el-icon-search" size="mini" @click="staffPlanQuery" style="margin-left: 20px;">
+            {{ $t('搜索') }}</el-button>
+        </el-form>
+      </div>
+      </div>
+
+      <el-table :data="list" v-loading="planLoading"  border>
+
+      </el-table>
+    </el-card>
+    <el-card>
+      <div slot="header" class="clearfix">
+        <span> 变更记录</span><div style="float: right;margin-bottom: -14px">
+        <el-form :model="queryDeviceParams" ref="queryRegularForm" label-width="68px" :inline="true">
+          <el-form-item :label="$t('年份')" prop="year">
+            <el-date-picker clearable size="small" style="width: 200px"
+                            v-model="queryDeviceParams.year"
+                            type="year"
+                            value-format="yyyy"
+                            :placeholder="$t('请选择') + $t('年份')">
+            </el-date-picker>
+          </el-form-item>
+          <el-button type="cyan" icon="el-icon-search" size="mini" @click="staffPlanQuery" style="margin-left: 20px;">
+            {{ $t('搜索') }}</el-button>
+        </el-form>
+      </div>
+      </div>
+      <el-table :data="list" v-loading="planLoading"  border>
+
+      </el-table>
+    </el-card>
+  </el-dialog>
+</template>
+
+<script>
+import Treeselect from "@riophae/vue-treeselect";
+import "@riophae/vue-treeselect/dist/vue-treeselect.css";
+import {listPlan} from "@/api/training/spec/plan";
+import {listParticipants} from "@/api/training/participants";
+import {listDevice} from "@/api/training/device";
+
+export default {
+  name: "Resume",
+  components: {Treeselect},
+  data() {
+    return {
+      list: [],
+      // 遮罩层
+      loading: false,
+      planLoading: false,
+      visible: false,
+      // 选中数组
+      ids: [],
+      photo: '',
+      dataListSelections: [],
+      // 装置名称字典
+      plantCodeOptions: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: false,
+      // 总条数
+      total: 0,
+      // 弹出层标题
+      title: "",
+      // 操作
+      operation: "",
+      // 部门树选项
+      deptOptions: undefined,
+      clientHeight: 300,
+      // 是否显示弹出层
+      open: false,
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 20,
+        staffId: null,
+        plantName: null,
+        startDate: null,
+        endDate: null,
+        classHour: null,
+        studyState: null
+      },
+      queryDeviceParams: {
+        staffId: null,
+        regularId: null,
+        year: this.getNowTime(),
+        trainingType: null
+      },
+      // 表单参数
+      form: {},
+      // 表单校验
+      rules: {}
+    };
+  },
+  watch: {},
+  created() {
+    this.getDicts("PLANT_DIVIDE").then(response => {
+      this.plantCodeOptions = response.data;
+    });
+  },
+  methods: {
+    init(row) {
+      this.visible = true
+    },
+    /** 获取当前年份 */
+    getNowTime() {
+      var now = new Date();
+      var year = now.getFullYear(); //得到年份
+      var defaultDate = `${year}`;
+      defaultDate = `${year}`
+      return defaultDate;
+    },
+    // 装置名称字典翻译
+    plantCodeFormat(row, column) {
+      return this.selectDictLabel(this.plantCodeOptions, row.plantCode);
+    },
+  }
+};
+</script>

+ 1 - 1
ui/src/views/intact/ysj/index.vue

@@ -567,7 +567,7 @@ import Treeselect from "@riophae/vue-treeselect";
 import "@riophae/vue-treeselect/dist/vue-treeselect.css";
 import {listRecord} from "@/api/inspection/record";
 import AddApprove from "../approve/tapprove-maintenance-add"
-import HisApprove from "@/views/sems/approve/tapprove-his";
+import HisApprove from "../approve/tapprove-maintenance-his";
 
 export default {
   name: "Ysj",