Ver código fonte

-新增两项申请表

jiangbiao 2 anos atrás
pai
commit
1c485369da
19 arquivos alterados com 3875 adições e 29 exclusões
  1. 17 12
      master/src/main/java/com/ruoyi/framework/web/controller/BaseController.java
  2. 105 0
      master/src/main/java/com/ruoyi/project/apply/controller/TApplyOfflinevalveController.java
  3. 105 0
      master/src/main/java/com/ruoyi/project/apply/controller/TApplySafetychangeController.java
  4. 543 0
      master/src/main/java/com/ruoyi/project/apply/domain/TApplyOfflinevalve.java
  5. 596 0
      master/src/main/java/com/ruoyi/project/apply/domain/TApplySafetychange.java
  6. 63 0
      master/src/main/java/com/ruoyi/project/apply/mapper/TApplyOfflinevalveMapper.java
  7. 63 0
      master/src/main/java/com/ruoyi/project/apply/mapper/TApplySafetychangeMapper.java
  8. 61 0
      master/src/main/java/com/ruoyi/project/apply/service/ITApplyOfflinevalveService.java
  9. 61 0
      master/src/main/java/com/ruoyi/project/apply/service/ITApplySafetychangeService.java
  10. 93 0
      master/src/main/java/com/ruoyi/project/apply/service/impl/TApplyOfflinevalveServiceImpl.java
  11. 93 0
      master/src/main/java/com/ruoyi/project/apply/service/impl/TApplySafetychangeServiceImpl.java
  12. 24 17
      master/src/main/java/com/ruoyi/project/reliability/controller/TSafetyvavleController.java
  13. 247 0
      master/src/main/resources/mybatis/apply/TApplyOfflinevalveMapper.xml
  14. 257 0
      master/src/main/resources/mybatis/apply/TApplySafetychangeMapper.xml
  15. 53 0
      ui/src/api/apply/offlinevalve.js
  16. 53 0
      ui/src/api/apply/safetychange.js
  17. 7 0
      ui/src/api/reliability/safetyvavle.js
  18. 722 0
      ui/src/views/apply/offlinevalve/index.vue
  19. 712 0
      ui/src/views/apply/safetychange/index.vue

+ 17 - 12
master/src/main/java/com/ruoyi/framework/web/controller/BaseController.java

@@ -1,27 +1,27 @@
 package com.ruoyi.framework.web.controller;
 
-import java.beans.PropertyEditorSupport;
-import java.util.Date;
-import java.util.List;
-
-import com.ruoyi.common.utils.ServletUtils;
-import com.ruoyi.common.utils.spring.SpringUtils;
-import com.ruoyi.framework.security.LoginUser;
-import com.ruoyi.framework.security.service.TokenService;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-import org.springframework.web.bind.WebDataBinder;
-import org.springframework.web.bind.annotation.InitBinder;
 import com.github.pagehelper.PageHelper;
 import com.github.pagehelper.PageInfo;
 import com.ruoyi.common.constant.HttpStatus;
 import com.ruoyi.common.utils.DateUtils;
+import com.ruoyi.common.utils.ServletUtils;
 import com.ruoyi.common.utils.StringUtils;
+import com.ruoyi.common.utils.spring.SpringUtils;
 import com.ruoyi.common.utils.sql.SqlUtil;
+import com.ruoyi.framework.security.LoginUser;
+import com.ruoyi.framework.security.service.TokenService;
 import com.ruoyi.framework.web.domain.AjaxResult;
 import com.ruoyi.framework.web.page.PageDomain;
 import com.ruoyi.framework.web.page.TableDataInfo;
 import com.ruoyi.framework.web.page.TableSupport;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.web.bind.WebDataBinder;
+import org.springframework.web.bind.annotation.InitBinder;
+
+import java.beans.PropertyEditorSupport;
+import java.util.Date;
+import java.util.List;
 
 /**
  * web层通用数据处理
@@ -107,4 +107,9 @@ public class BaseController
         LoginUser loginUser = SpringUtils.getBean(TokenService.class).getLoginUser(ServletUtils.getRequest());
         return loginUser.getUser().getUserId();
     }
+
+    protected String getNickName () {
+        LoginUser loginUser = SpringUtils.getBean(TokenService.class).getLoginUser(ServletUtils.getRequest());
+        return loginUser.getUser().getNickName();
+    }
 }

+ 105 - 0
master/src/main/java/com/ruoyi/project/apply/controller/TApplyOfflinevalveController.java

@@ -0,0 +1,105 @@
+package com.ruoyi.project.apply.controller;
+
+import com.ruoyi.common.utils.poi.ExcelUtil;
+import com.ruoyi.framework.aspectj.lang.annotation.Log;
+import com.ruoyi.framework.aspectj.lang.enums.BusinessType;
+import com.ruoyi.framework.web.controller.BaseController;
+import com.ruoyi.framework.web.domain.AjaxResult;
+import com.ruoyi.framework.web.page.TableDataInfo;
+import com.ruoyi.project.apply.domain.TApplyOfflinevalve;
+import com.ruoyi.project.apply.service.ITApplyOfflinevalveService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.web.bind.annotation.*;
+
+import java.util.Date;
+import java.util.List;
+
+/**
+ * 安全阀离线切出申请Controller
+ *
+ * @author ruoyi
+ * @date 2023-02-08
+ */
+@RestController
+@RequestMapping("/apply/offlinevalve")
+public class TApplyOfflinevalveController extends BaseController
+{
+    @Autowired
+    private ITApplyOfflinevalveService tApplyOfflinevalveService;
+
+    /**
+     * 查询安全阀离线切出申请列表
+     */
+    @PreAuthorize("@ss.hasPermi('apply:offlinevalve:list')")
+    @GetMapping("/list")
+    public TableDataInfo list(TApplyOfflinevalve tApplyOfflinevalve)
+    {
+        startPage();
+        List<TApplyOfflinevalve> list = tApplyOfflinevalveService.selectTApplyOfflinevalveList(tApplyOfflinevalve);
+        return getDataTable(list);
+    }
+
+    /**
+     * 导出安全阀离线切出申请列表
+     */
+    @PreAuthorize("@ss.hasPermi('apply:offlinevalve:export')")
+    @Log(title = "安全阀离线切出申请", businessType = BusinessType.EXPORT)
+    @GetMapping("/export")
+    public AjaxResult export(TApplyOfflinevalve tApplyOfflinevalve)
+    {
+        List<TApplyOfflinevalve> list = tApplyOfflinevalveService.selectTApplyOfflinevalveList(tApplyOfflinevalve);
+        ExcelUtil<TApplyOfflinevalve> util = new ExcelUtil<TApplyOfflinevalve>(TApplyOfflinevalve.class);
+        return util.exportExcel(list, "offlinevalve");
+    }
+
+    /**
+     * 获取安全阀离线切出申请详细信息
+     */
+    @PreAuthorize("@ss.hasPermi('apply:offlinevalve:query')")
+    @GetMapping(value = "/{id}")
+    public AjaxResult getInfo(@PathVariable("id") Long id)
+    {
+        return AjaxResult.success(tApplyOfflinevalveService.selectTApplyOfflinevalveById(id));
+    }
+
+    /**
+     * 新增安全阀离线切出申请
+     */
+    @PreAuthorize("@ss.hasPermi('apply:offlinevalve:add')")
+    @Log(title = "安全阀离线切出申请", businessType = BusinessType.INSERT)
+    @PostMapping
+    public AjaxResult add(@RequestBody TApplyOfflinevalve tApplyOfflinevalve)
+    {
+        tApplyOfflinevalve.setApplicant(getUserId().toString());
+        tApplyOfflinevalve.setApplicantName(getNickName());
+        tApplyOfflinevalve.setApplicationTime(new Date());
+        tApplyOfflinevalve.setCreatedate(new Date());
+        tApplyOfflinevalve.setCreaterCode(getUserId().toString());
+        return toAjax(tApplyOfflinevalveService.insertTApplyOfflinevalve(tApplyOfflinevalve));
+    }
+
+    /**
+     * 修改安全阀离线切出申请
+     */
+    @PreAuthorize("@ss.hasPermi('apply:offlinevalve:edit')")
+    @Log(title = "安全阀离线切出申请", businessType = BusinessType.UPDATE)
+    @PutMapping
+    public AjaxResult edit(@RequestBody TApplyOfflinevalve tApplyOfflinevalve)
+    {
+        tApplyOfflinevalve.setUpdatedate(new Date());
+        tApplyOfflinevalve.setUpdaterCode(getUserId());
+        return toAjax(tApplyOfflinevalveService.updateTApplyOfflinevalve(tApplyOfflinevalve));
+    }
+
+    /**
+     * 删除安全阀离线切出申请
+     */
+    @PreAuthorize("@ss.hasPermi('apply:offlinevalve:remove')")
+    @Log(title = "安全阀离线切出申请", businessType = BusinessType.DELETE)
+	@DeleteMapping("/{ids}")
+    public AjaxResult remove(@PathVariable Long[] ids)
+    {
+        return toAjax(tApplyOfflinevalveService.deleteTApplyOfflinevalveByIds(ids));
+    }
+}

+ 105 - 0
master/src/main/java/com/ruoyi/project/apply/controller/TApplySafetychangeController.java

@@ -0,0 +1,105 @@
+package com.ruoyi.project.apply.controller;
+
+import com.ruoyi.common.utils.poi.ExcelUtil;
+import com.ruoyi.framework.aspectj.lang.annotation.Log;
+import com.ruoyi.framework.aspectj.lang.enums.BusinessType;
+import com.ruoyi.framework.web.controller.BaseController;
+import com.ruoyi.framework.web.domain.AjaxResult;
+import com.ruoyi.framework.web.page.TableDataInfo;
+import com.ruoyi.project.apply.domain.TApplySafetychange;
+import com.ruoyi.project.apply.service.ITApplySafetychangeService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.web.bind.annotation.*;
+
+import java.util.Date;
+import java.util.List;
+
+/**
+ * 组织保护措施状态变更申请Controller
+ *
+ * @author ruoyi
+ * @date 2023-02-09
+ */
+@RestController
+@RequestMapping("/apply/safetychange")
+public class TApplySafetychangeController extends BaseController
+{
+    @Autowired
+    private ITApplySafetychangeService tApplySafetychangeService;
+
+    /**
+     * 查询组织保护措施状态变更申请列表
+     */
+    @PreAuthorize("@ss.hasPermi('apply:safetychange:list')")
+    @GetMapping("/list")
+    public TableDataInfo list(TApplySafetychange tApplySafetychange)
+    {
+        startPage();
+        List<TApplySafetychange> list = tApplySafetychangeService.selectTApplySafetychangeList(tApplySafetychange);
+        return getDataTable(list);
+    }
+
+    /**
+     * 导出组织保护措施状态变更申请列表
+     */
+    @PreAuthorize("@ss.hasPermi('apply:safetychange:export')")
+    @Log(title = "组织保护措施状态变更申请", businessType = BusinessType.EXPORT)
+    @GetMapping("/export")
+    public AjaxResult export(TApplySafetychange tApplySafetychange)
+    {
+        List<TApplySafetychange> list = tApplySafetychangeService.selectTApplySafetychangeList(tApplySafetychange);
+        ExcelUtil<TApplySafetychange> util = new ExcelUtil<TApplySafetychange>(TApplySafetychange.class);
+        return util.exportExcel(list, "safetychange");
+    }
+
+    /**
+     * 获取组织保护措施状态变更申请详细信息
+     */
+    @PreAuthorize("@ss.hasPermi('apply:safetychange:query')")
+    @GetMapping(value = "/{id}")
+    public AjaxResult getInfo(@PathVariable("id") Long id)
+    {
+        return AjaxResult.success(tApplySafetychangeService.selectTApplySafetychangeById(id));
+    }
+
+    /**
+     * 新增组织保护措施状态变更申请
+     */
+    @PreAuthorize("@ss.hasPermi('apply:safetychange:add')")
+    @Log(title = "组织保护措施状态变更申请", businessType = BusinessType.INSERT)
+    @PostMapping
+    public AjaxResult add(@RequestBody TApplySafetychange tApplySafetychange)
+    {
+        tApplySafetychange.setApplicant(getUserId().toString());
+        tApplySafetychange.setApplicantName(getNickName());
+        tApplySafetychange.setApplicationTime(new Date());
+        tApplySafetychange.setCreatedate(new Date());
+        tApplySafetychange.setCreaterCode(getUserId().toString());
+        return toAjax(tApplySafetychangeService.insertTApplySafetychange(tApplySafetychange));
+    }
+
+    /**
+     * 修改组织保护措施状态变更申请
+     */
+    @PreAuthorize("@ss.hasPermi('apply:safetychange:edit')")
+    @Log(title = "组织保护措施状态变更申请", businessType = BusinessType.UPDATE)
+    @PutMapping
+    public AjaxResult edit(@RequestBody TApplySafetychange tApplySafetychange)
+    {
+        tApplySafetychange.setUpdatedate(new Date());
+        tApplySafetychange.setUpdaterCode(getUserId());
+        return toAjax(tApplySafetychangeService.updateTApplySafetychange(tApplySafetychange));
+    }
+
+    /**
+     * 删除组织保护措施状态变更申请
+     */
+    @PreAuthorize("@ss.hasPermi('apply:safetychange:remove')")
+    @Log(title = "组织保护措施状态变更申请", businessType = BusinessType.DELETE)
+	@DeleteMapping("/{ids}")
+    public AjaxResult remove(@PathVariable Long[] ids)
+    {
+        return toAjax(tApplySafetychangeService.deleteTApplySafetychangeByIds(ids));
+    }
+}

+ 543 - 0
master/src/main/java/com/ruoyi/project/apply/domain/TApplyOfflinevalve.java

@@ -0,0 +1,543 @@
+package com.ruoyi.project.apply.domain;
+
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.ruoyi.framework.aspectj.lang.annotation.Excel;
+import com.ruoyi.framework.web.domain.BaseEntity;
+import org.apache.commons.lang3.builder.ToStringBuilder;
+import org.apache.commons.lang3.builder.ToStringStyle;
+
+import java.util.Date;
+
+/**
+ * 安全阀离线切出申请对象 t_apply_offlinevalve
+ *
+ * @author ruoyi
+ * @date 2023-02-08
+ */
+public class TApplyOfflinevalve extends BaseEntity
+{
+    private static final long serialVersionUID = 1L;
+
+    /** 唯一标识ID */
+    private Long id;
+
+    /** 安全阀位号 */
+    @Excel(name = "安全阀位号")
+    private String devNo;
+
+    /** 单元 */
+    @Excel(name = "单元")
+    private String unit;
+
+    /** 离线原因 */
+    @Excel(name = "离线原因")
+    private String offlineReason;
+
+    /** 安全评估以及临时措施执行 */
+    @Excel(name = "安全评估以及临时措施执行")
+    private String safa;
+
+    /** 安全阀锁开是否拆解 */
+    @Excel(name = "安全阀锁开是否拆解")
+    private Long disassembly;
+
+    /** 临时措施执行人 */
+    @Excel(name = "临时措施执行人")
+    private String executor;
+
+    /** 临时措施确认人 */
+    @Excel(name = "临时措施确认人")
+    private String confirmer;
+
+    /** 申请人 */
+    @Excel(name = "申请人")
+    private String applicant;
+
+    /** 申请时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm" , timezone = "GMT+8")
+    @Excel(name = "申请时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm")
+    private Date applicationTime;
+
+    /** 批准人 */
+    @Excel(name = "批准人")
+    private String approver;
+
+    /** 批准时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm" , timezone = "GMT+8")
+    @Excel(name = "批准时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm")
+    private Date approveTime;
+
+    /** 离线安全阀是否已经复位 */
+    @Excel(name = "离线安全阀是否已经复位")
+    private String resetConfirm;
+
+    /** 离线安全阀复位后现场是否存在泄漏 */
+    @Excel(name = "离线安全阀复位后现场是否存在泄漏")
+    private String leakConfirm;
+
+    /** 离线安全复位后,之前采取的安全措施是否已撤销 */
+    @Excel(name = "离线安全复位后,之前采取的安全措施是否已撤销")
+    private String revokeConfirm;
+
+    /** 离线安全复位后,是否已经重新上锁 */
+    @Excel(name = "离线安全复位后,是否已经重新上锁")
+    private String lockConfirm;
+
+    /** 是否上锁确认人1 */
+    @Excel(name = "是否上锁确认人1")
+    private String lockConfirmer1;
+
+    /** 是否上锁确认人2 */
+    @Excel(name = "是否上锁确认人2")
+    private String lockConfirmer2;
+
+    /** 信息确认人 */
+    @Excel(name = "信息确认人")
+    private String infoConfirmer;
+
+    /** 确认时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm" , timezone = "GMT+8")
+    @Excel(name = "确认时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm")
+    private Date confirmTime;
+
+    /** 备注 */
+    @Excel(name = "备注")
+    private String remarks;
+
+    /** 临时措施确认时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm" , timezone = "GMT+8")
+    @Excel(name = "临时措施确认时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm")
+    private Date temporaryTime;
+
+    /** 临时措施执行时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm" , timezone = "GMT+8")
+    @Excel(name = "临时措施执行时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm")
+    private Date executionTime;
+
+    /** 状态 */
+    @Excel(name = "状态")
+    private Long status;
+
+    /** 状态 1 :正常 ;0:删除 */
+    private Long delFlag;
+
+    /** 创建人 */
+    @Excel(name = "创建人")
+    private String createrCode;
+
+    /** 创建时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd" , timezone = "GMT+8")
+    @Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date createdate;
+
+    /** 修改人 */
+    @Excel(name = "修改人")
+    private Long updaterCode;
+
+    /** 修改时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd" , timezone = "GMT+8")
+    @Excel(name = "修改时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date updatedate;
+
+    /** 部门编号 */
+    @Excel(name = "部门编号")
+    private Long deptId;
+
+    /** 申请状态 */
+    @Excel(name = "申请状态")
+    private String approveStatus;
+
+    /**上锁确认人1姓名*/
+    private String lockConfirmer1Name;
+
+    /**上锁确认人2姓名*/
+    private String lockConfirmer2Name;
+
+    /**信息确认人姓名*/
+    private String infoConfirmerName;
+
+    /**执行人姓名*/
+    private String executorName;
+
+    /**确认人姓名*/
+    private String confirmerName;
+
+    /**批准人姓名*/
+    private String approverName;
+
+    /**申请人姓名*/
+    private String applicantName;
+
+    public String getLockConfirmer1Name() {
+        return lockConfirmer1Name;
+    }
+
+    public void setLockConfirmer1Name(String lockConfirmer1Name) {
+        this.lockConfirmer1Name = lockConfirmer1Name;
+    }
+
+    public String getLockConfirmer2Name() {
+        return lockConfirmer2Name;
+    }
+
+    public void setLockConfirmer2Name(String lockConfirmer2Name) {
+        this.lockConfirmer2Name = lockConfirmer2Name;
+    }
+
+    public String getInfoConfirmerName() {
+        return infoConfirmerName;
+    }
+
+    public void setInfoConfirmerName(String infoConfirmerName) {
+        this.infoConfirmerName = infoConfirmerName;
+    }
+
+    public String getExecutorName() {
+        return executorName;
+    }
+
+    public void setExecutorName(String executorName) {
+        this.executorName = executorName;
+    }
+
+    public String getConfirmerName() {
+        return confirmerName;
+    }
+
+    public void setConfirmerName(String confirmerName) {
+        this.confirmerName = confirmerName;
+    }
+
+    public String getApproverName() {
+        return approverName;
+    }
+
+    public void setApproverName(String approverName) {
+        this.approverName = approverName;
+    }
+
+    public String getApplicantName() {
+        return applicantName;
+    }
+
+    public void setApplicantName(String applicantName) {
+        this.applicantName = applicantName;
+    }
+
+    public void setId(Long id)
+    {
+        this.id = id;
+    }
+
+    public Long getId()
+    {
+        return id;
+    }
+    public void setDevNo(String devNo)
+    {
+        this.devNo = devNo;
+    }
+
+    public String getDevNo()
+    {
+        return devNo;
+    }
+    public void setUnit(String unit)
+    {
+        this.unit = unit;
+    }
+
+    public String getUnit()
+    {
+        return unit;
+    }
+    public void setOfflineReason(String offlineReason)
+    {
+        this.offlineReason = offlineReason;
+    }
+
+    public String getOfflineReason()
+    {
+        return offlineReason;
+    }
+    public void setSafa(String safa)
+    {
+        this.safa = safa;
+    }
+
+    public String getSafa()
+    {
+        return safa;
+    }
+    public void setDisassembly(Long disassembly)
+    {
+        this.disassembly = disassembly;
+    }
+
+    public Long getDisassembly()
+    {
+        return disassembly;
+    }
+    public void setExecutor(String executor)
+    {
+        this.executor = executor;
+    }
+
+    public String getExecutor()
+    {
+        return executor;
+    }
+    public void setConfirmer(String confirmer)
+    {
+        this.confirmer = confirmer;
+    }
+
+    public String getConfirmer()
+    {
+        return confirmer;
+    }
+    public void setApplicant(String applicant)
+    {
+        this.applicant = applicant;
+    }
+
+    public String getApplicant()
+    {
+        return applicant;
+    }
+    public void setApplicationTime(Date applicationTime)
+    {
+        this.applicationTime = applicationTime;
+    }
+
+    public Date getApplicationTime()
+    {
+        return applicationTime;
+    }
+    public void setApprover(String approver)
+    {
+        this.approver = approver;
+    }
+
+    public String getApprover()
+    {
+        return approver;
+    }
+    public void setApproveTime(Date approveTime)
+    {
+        this.approveTime = approveTime;
+    }
+
+    public Date getApproveTime()
+    {
+        return approveTime;
+    }
+    public void setResetConfirm(String resetConfirm)
+    {
+        this.resetConfirm = resetConfirm;
+    }
+
+    public String getResetConfirm()
+    {
+        return resetConfirm;
+    }
+    public void setLeakConfirm(String leakConfirm)
+    {
+        this.leakConfirm = leakConfirm;
+    }
+
+    public String getLeakConfirm()
+    {
+        return leakConfirm;
+    }
+    public void setRevokeConfirm(String revokeConfirm)
+    {
+        this.revokeConfirm = revokeConfirm;
+    }
+
+    public String getRevokeConfirm()
+    {
+        return revokeConfirm;
+    }
+    public void setLockConfirm(String lockConfirm)
+    {
+        this.lockConfirm = lockConfirm;
+    }
+
+    public String getLockConfirm()
+    {
+        return lockConfirm;
+    }
+    public void setLockConfirmer1(String lockConfirmer1)
+    {
+        this.lockConfirmer1 = lockConfirmer1;
+    }
+
+    public String getLockConfirmer1()
+    {
+        return lockConfirmer1;
+    }
+    public void setLockConfirmer2(String lockConfirmer2)
+    {
+        this.lockConfirmer2 = lockConfirmer2;
+    }
+
+    public String getLockConfirmer2()
+    {
+        return lockConfirmer2;
+    }
+    public void setInfoConfirmer(String infoConfirmer)
+    {
+        this.infoConfirmer = infoConfirmer;
+    }
+
+    public String getInfoConfirmer()
+    {
+        return infoConfirmer;
+    }
+    public void setConfirmTime(Date confirmTime)
+    {
+        this.confirmTime = confirmTime;
+    }
+
+    public Date getConfirmTime()
+    {
+        return confirmTime;
+    }
+    public void setRemarks(String remarks)
+    {
+        this.remarks = remarks;
+    }
+
+    public String getRemarks()
+    {
+        return remarks;
+    }
+    public void setTemporaryTime(Date temporaryTime)
+    {
+        this.temporaryTime = temporaryTime;
+    }
+
+    public Date getTemporaryTime()
+    {
+        return temporaryTime;
+    }
+    public void setExecutionTime(Date executionTime)
+    {
+        this.executionTime = executionTime;
+    }
+
+    public Date getExecutionTime()
+    {
+        return executionTime;
+    }
+    public void setStatus(Long status)
+    {
+        this.status = status;
+    }
+
+    public Long getStatus()
+    {
+        return status;
+    }
+    public void setDelFlag(Long delFlag)
+    {
+        this.delFlag = delFlag;
+    }
+
+    public Long getDelFlag()
+    {
+        return delFlag;
+    }
+    public void setCreaterCode(String createrCode)
+    {
+        this.createrCode = createrCode;
+    }
+
+    public String getCreaterCode()
+    {
+        return createrCode;
+    }
+    public void setCreatedate(Date createdate)
+    {
+        this.createdate = createdate;
+    }
+
+    public Date getCreatedate()
+    {
+        return createdate;
+    }
+    public void setUpdaterCode(Long updaterCode)
+    {
+        this.updaterCode = updaterCode;
+    }
+
+    public Long getUpdaterCode()
+    {
+        return updaterCode;
+    }
+    public void setUpdatedate(Date updatedate)
+    {
+        this.updatedate = updatedate;
+    }
+
+    public Date getUpdatedate()
+    {
+        return updatedate;
+    }
+    public void setDeptId(Long deptId)
+    {
+        this.deptId = deptId;
+    }
+
+    public Long getDeptId()
+    {
+        return deptId;
+    }
+    public void setApproveStatus(String approveStatus)
+    {
+        this.approveStatus = approveStatus;
+    }
+
+    public String getApproveStatus()
+    {
+        return approveStatus;
+    }
+
+    @Override
+    public String toString() {
+        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
+            .append("id", getId())
+            .append("devNo", getDevNo())
+            .append("unit", getUnit())
+            .append("offlineReason", getOfflineReason())
+            .append("safa", getSafa())
+            .append("disassembly", getDisassembly())
+            .append("executor", getExecutor())
+            .append("confirmer", getConfirmer())
+            .append("applicant", getApplicant())
+            .append("applicationTime", getApplicationTime())
+            .append("approver", getApprover())
+            .append("approveTime", getApproveTime())
+            .append("resetConfirm", getResetConfirm())
+            .append("leakConfirm", getLeakConfirm())
+            .append("revokeConfirm", getRevokeConfirm())
+            .append("lockConfirm", getLockConfirm())
+            .append("lockConfirmer1", getLockConfirmer1())
+            .append("lockConfirmer2", getLockConfirmer2())
+            .append("infoConfirmer", getInfoConfirmer())
+            .append("confirmTime", getConfirmTime())
+            .append("remarks", getRemarks())
+            .append("temporaryTime", getTemporaryTime())
+            .append("executionTime", getExecutionTime())
+            .append("status", getStatus())
+            .append("delFlag", getDelFlag())
+            .append("createrCode", getCreaterCode())
+            .append("createdate", getCreatedate())
+            .append("updaterCode", getUpdaterCode())
+            .append("updatedate", getUpdatedate())
+            .append("deptId", getDeptId())
+            .append("approveStatus", getApproveStatus())
+            .toString();
+    }
+}

+ 596 - 0
master/src/main/java/com/ruoyi/project/apply/domain/TApplySafetychange.java

@@ -0,0 +1,596 @@
+package com.ruoyi.project.apply.domain;
+
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.ruoyi.framework.aspectj.lang.annotation.Excel;
+import com.ruoyi.framework.web.domain.BaseEntity;
+import org.apache.commons.lang3.builder.ToStringBuilder;
+import org.apache.commons.lang3.builder.ToStringStyle;
+
+import java.util.Date;
+
+/**
+ * 组织保护措施状态变更申请对象 t_apply_safetychange
+ *
+ * @author ruoyi
+ * @date 2023-02-09
+ */
+public class TApplySafetychange extends BaseEntity
+{
+    private static final long serialVersionUID = 1L;
+
+    /** 唯一标识ID */
+    private Long id;
+
+    /** 组织保护措施变更描述 */
+    @Excel(name = "组织保护措施变更描述")
+    private String changeDescribe;
+
+    /** 状态变更原因 */
+    @Excel(name = "状态变更原因")
+    private String changeReason;
+
+    /** 申请人id */
+    @Excel(name = "申请人id")
+    private String applicant;
+
+    /** 申请人姓名 */
+    @Excel(name = "申请人姓名")
+    private String applicantName;
+
+    /** 申请时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm" , timezone = "GMT+8")
+    @Excel(name = "申请时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm")
+    private Date applicationTime;
+
+    /** 安全评估及临时的安全措施 */
+    @Excel(name = "安全评估及临时的安全措施")
+    private String safa;
+
+    /** 安全评估人id */
+    @Excel(name = "安全评估人id")
+    private String safaer;
+
+    /** 安全评估人姓名 */
+    @Excel(name = "安全评估人姓名")
+    private String safaerName;
+
+    /** 安全评估时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm" , timezone = "GMT+8")
+    @Excel(name = "安全评估时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm")
+    private Date safaTime;
+
+    /** 批准人id */
+    @Excel(name = "批准人id")
+    private String approver;
+
+    /** 批准人姓名 */
+    @Excel(name = "批准人姓名")
+    private String approverName;
+
+    /** 批准时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm" , timezone = "GMT+8")
+    @Excel(name = "批准时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm")
+    private Date approveTime;
+
+    /** 临时安全措施执行人id */
+    @Excel(name = "临时安全措施执行人id")
+    private String executor;
+
+    /** 临时安全措施执行人姓名 */
+    @Excel(name = "临时安全措施执行人姓名")
+    private String executorName;
+
+    /** 临时安全措施执行时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm" , timezone = "GMT+8")
+    @Excel(name = "临时安全措施执行时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm")
+    private Date executionTime;
+
+    /** 临时安全措施确认人id */
+    @Excel(name = "临时安全措施确认人id")
+    private String confirmer;
+
+    /** 临时安全措施确认人姓名 */
+    @Excel(name = "临时安全措施确认人姓名")
+    private String confirmerName;
+
+    /** 临时安全措施确认时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm" , timezone = "GMT+8")
+    @Excel(name = "临时安全措施确认时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm")
+    private Date confirmTime;
+
+    /** 组织保护措施状态变更执行 */
+    @Excel(name = "组织保护措施状态变更执行")
+    private String changeExecution;
+
+    /** 执行人id */
+    @Excel(name = "执行人id")
+    private String changeExecutor;
+
+    /** 执行人姓名 */
+    @Excel(name = "执行人姓名")
+    private String changeExecutorName;
+
+    /** 执行时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm" , timezone = "GMT+8")
+    @Excel(name = "执行时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm")
+    private Date changeExecutorTime;
+
+    /** 组织保护措施是否已经恢复至变更前的状态 */
+    @Excel(name = "组织保护措施是否已经恢复至变更前的状态")
+    private String resetConfirm;
+
+    /** 状态恢复,确认人1id */
+    @Excel(name = "状态恢复,确认人1id")
+    private String resetConfirmer1;
+
+    /** 状态恢复,确认人1姓名 */
+    @Excel(name = "状态恢复,确认人1姓名")
+    private String resetConfirmerName1;
+
+    /** 状态恢复,确认时间1 */
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm" , timezone = "GMT+8")
+    @Excel(name = "状态恢复,确认时间1", width = 30, dateFormat = "yyyy-MM-dd HH:mm")
+    private Date resetConfirmTime1;
+
+    /** 状态恢复,确认人2id */
+    @Excel(name = "状态恢复,确认人2id")
+    private String resetConfirmer2;
+
+    /** 状态恢复,确认人2姓名 */
+    @Excel(name = "状态恢复,确认人2姓名")
+    private String resetConfirmerName2;
+
+    /** 状态恢复,确认时间2 */
+    @JsonFormat(pattern = "yyyy-MM-dd HH:mm" , timezone = "GMT+8")
+    @Excel(name = "状态恢复,确认时间2", width = 30, dateFormat = "yyyy-MM-dd HH:mm")
+    private Date resetConfirmTime2;
+
+    /** 状态恢复后,之前采取的安全措施是否已撤销: */
+    @Excel(name = "状态恢复后,之前采取的安全措施是否已撤销:")
+    private String revokeConfirm;
+
+    /** 备注 */
+    @Excel(name = "备注")
+    private String remarks;
+
+    /** 状态 */
+    @Excel(name = "状态")
+    private Long status;
+
+    /** 状态 0 :正常 ;1:删除 */
+    private Long delFlag;
+
+    /** 创建人 */
+    @Excel(name = "创建人")
+    private String createrCode;
+
+    /** 创建时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd" , timezone = "GMT+8")
+    @Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date createdate;
+
+    /** 修改人 */
+    @Excel(name = "修改人")
+    private Long updaterCode;
+
+    /** 修改时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd" , timezone = "GMT+8")
+    @Excel(name = "修改时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date updatedate;
+
+    /** 部门编号 */
+    @Excel(name = "部门编号")
+    private Long deptId;
+
+    /**
+申请状态0:待申请,1:申请中,2:已通过,3:已驳回,4:已拒绝 */
+    @Excel(name = "申请状态")
+    private String approveStatus;
+
+    public void setId(Long id)
+    {
+        this.id = id;
+    }
+
+    public Long getId()
+    {
+        return id;
+    }
+    public void setChangeDescribe(String changeDescribe)
+    {
+        this.changeDescribe = changeDescribe;
+    }
+
+    public String getChangeDescribe()
+    {
+        return changeDescribe;
+    }
+    public void setChangeReason(String changeReason)
+    {
+        this.changeReason = changeReason;
+    }
+
+    public String getChangeReason()
+    {
+        return changeReason;
+    }
+    public void setApplicant(String applicant)
+    {
+        this.applicant = applicant;
+    }
+
+    public String getApplicant()
+    {
+        return applicant;
+    }
+    public void setApplicantName(String applicantName)
+    {
+        this.applicantName = applicantName;
+    }
+
+    public String getApplicantName()
+    {
+        return applicantName;
+    }
+    public void setApplicationTime(Date applicationTime)
+    {
+        this.applicationTime = applicationTime;
+    }
+
+    public Date getApplicationTime()
+    {
+        return applicationTime;
+    }
+    public void setSafa(String safa)
+    {
+        this.safa = safa;
+    }
+
+    public String getSafa()
+    {
+        return safa;
+    }
+    public void setSafaer(String safaer)
+    {
+        this.safaer = safaer;
+    }
+
+    public String getSafaer()
+    {
+        return safaer;
+    }
+    public void setSafaerName(String safaerName)
+    {
+        this.safaerName = safaerName;
+    }
+
+    public String getSafaerName()
+    {
+        return safaerName;
+    }
+    public void setSafaTime(Date safaTime)
+    {
+        this.safaTime = safaTime;
+    }
+
+    public Date getSafaTime()
+    {
+        return safaTime;
+    }
+    public void setApprover(String approver)
+    {
+        this.approver = approver;
+    }
+
+    public String getApprover()
+    {
+        return approver;
+    }
+    public void setApproverName(String approverName)
+    {
+        this.approverName = approverName;
+    }
+
+    public String getApproverName()
+    {
+        return approverName;
+    }
+    public void setApproveTime(Date approveTime)
+    {
+        this.approveTime = approveTime;
+    }
+
+    public Date getApproveTime()
+    {
+        return approveTime;
+    }
+    public void setExecutor(String executor)
+    {
+        this.executor = executor;
+    }
+
+    public String getExecutor()
+    {
+        return executor;
+    }
+    public void setExecutorName(String executorName)
+    {
+        this.executorName = executorName;
+    }
+
+    public String getExecutorName()
+    {
+        return executorName;
+    }
+    public void setExecutionTime(Date executionTime)
+    {
+        this.executionTime = executionTime;
+    }
+
+    public Date getExecutionTime()
+    {
+        return executionTime;
+    }
+    public void setConfirmer(String confirmer)
+    {
+        this.confirmer = confirmer;
+    }
+
+    public String getConfirmer()
+    {
+        return confirmer;
+    }
+    public void setConfirmerName(String confirmerName)
+    {
+        this.confirmerName = confirmerName;
+    }
+
+    public String getConfirmerName()
+    {
+        return confirmerName;
+    }
+    public void setConfirmTime(Date confirmTime)
+    {
+        this.confirmTime = confirmTime;
+    }
+
+    public Date getConfirmTime()
+    {
+        return confirmTime;
+    }
+    public void setChangeExecution(String changeExecution)
+    {
+        this.changeExecution = changeExecution;
+    }
+
+    public String getChangeExecution()
+    {
+        return changeExecution;
+    }
+    public void setChangeExecutor(String changeExecutor)
+    {
+        this.changeExecutor = changeExecutor;
+    }
+
+    public String getChangeExecutor()
+    {
+        return changeExecutor;
+    }
+    public void setChangeExecutorName(String changeExecutorName)
+    {
+        this.changeExecutorName = changeExecutorName;
+    }
+
+    public String getChangeExecutorName()
+    {
+        return changeExecutorName;
+    }
+    public void setChangeExecutorTime(Date changeExecutorTime)
+    {
+        this.changeExecutorTime = changeExecutorTime;
+    }
+
+    public Date getChangeExecutorTime()
+    {
+        return changeExecutorTime;
+    }
+    public void setResetConfirm(String resetConfirm)
+    {
+        this.resetConfirm = resetConfirm;
+    }
+
+    public String getResetConfirm()
+    {
+        return resetConfirm;
+    }
+    public void setResetConfirmer1(String resetConfirmer1)
+    {
+        this.resetConfirmer1 = resetConfirmer1;
+    }
+
+    public String getResetConfirmer1()
+    {
+        return resetConfirmer1;
+    }
+    public void setResetConfirmerName1(String resetConfirmerName1)
+    {
+        this.resetConfirmerName1 = resetConfirmerName1;
+    }
+
+    public String getResetConfirmerName1()
+    {
+        return resetConfirmerName1;
+    }
+    public void setResetConfirmTime1(Date resetConfirmTime1)
+    {
+        this.resetConfirmTime1 = resetConfirmTime1;
+    }
+
+    public Date getResetConfirmTime1()
+    {
+        return resetConfirmTime1;
+    }
+    public void setResetConfirmer2(String resetConfirmer2)
+    {
+        this.resetConfirmer2 = resetConfirmer2;
+    }
+
+    public String getResetConfirmer2()
+    {
+        return resetConfirmer2;
+    }
+    public void setResetConfirmerName2(String resetConfirmerName2)
+    {
+        this.resetConfirmerName2 = resetConfirmerName2;
+    }
+
+    public String getResetConfirmerName2()
+    {
+        return resetConfirmerName2;
+    }
+    public void setResetConfirmTime2(Date resetConfirmTime2)
+    {
+        this.resetConfirmTime2 = resetConfirmTime2;
+    }
+
+    public Date getResetConfirmTime2()
+    {
+        return resetConfirmTime2;
+    }
+    public void setRevokeConfirm(String revokeConfirm)
+    {
+        this.revokeConfirm = revokeConfirm;
+    }
+
+    public String getRevokeConfirm()
+    {
+        return revokeConfirm;
+    }
+    public void setRemarks(String remarks)
+    {
+        this.remarks = remarks;
+    }
+
+    public String getRemarks()
+    {
+        return remarks;
+    }
+    public void setStatus(Long status)
+    {
+        this.status = status;
+    }
+
+    public Long getStatus()
+    {
+        return status;
+    }
+    public void setDelFlag(Long delFlag)
+    {
+        this.delFlag = delFlag;
+    }
+
+    public Long getDelFlag()
+    {
+        return delFlag;
+    }
+    public void setCreaterCode(String createrCode)
+    {
+        this.createrCode = createrCode;
+    }
+
+    public String getCreaterCode()
+    {
+        return createrCode;
+    }
+    public void setCreatedate(Date createdate)
+    {
+        this.createdate = createdate;
+    }
+
+    public Date getCreatedate()
+    {
+        return createdate;
+    }
+    public void setUpdaterCode(Long updaterCode)
+    {
+        this.updaterCode = updaterCode;
+    }
+
+    public Long getUpdaterCode()
+    {
+        return updaterCode;
+    }
+    public void setUpdatedate(Date updatedate)
+    {
+        this.updatedate = updatedate;
+    }
+
+    public Date getUpdatedate()
+    {
+        return updatedate;
+    }
+    public void setDeptId(Long deptId)
+    {
+        this.deptId = deptId;
+    }
+
+    public Long getDeptId()
+    {
+        return deptId;
+    }
+    public void setApproveStatus(String approveStatus)
+    {
+        this.approveStatus = approveStatus;
+    }
+
+    public String getApproveStatus()
+    {
+        return approveStatus;
+    }
+
+    @Override
+    public String toString() {
+        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
+            .append("id", getId())
+            .append("changeDescribe", getChangeDescribe())
+            .append("changeReason", getChangeReason())
+            .append("applicant", getApplicant())
+            .append("applicantName", getApplicantName())
+            .append("applicationTime", getApplicationTime())
+            .append("safa", getSafa())
+            .append("safaer", getSafaer())
+            .append("safaerName", getSafaerName())
+            .append("safaTime", getSafaTime())
+            .append("approver", getApprover())
+            .append("approverName", getApproverName())
+            .append("approveTime", getApproveTime())
+            .append("executor", getExecutor())
+            .append("executorName", getExecutorName())
+            .append("executionTime", getExecutionTime())
+            .append("confirmer", getConfirmer())
+            .append("confirmerName", getConfirmerName())
+            .append("confirmTime", getConfirmTime())
+            .append("changeExecution", getChangeExecution())
+            .append("changeExecutor", getChangeExecutor())
+            .append("changeExecutorName", getChangeExecutorName())
+            .append("changeExecutorTime", getChangeExecutorTime())
+            .append("resetConfirm", getResetConfirm())
+            .append("resetConfirmer1", getResetConfirmer1())
+            .append("resetConfirmerName1", getResetConfirmerName1())
+            .append("resetConfirmTime1", getResetConfirmTime1())
+            .append("resetConfirmer2", getResetConfirmer2())
+            .append("resetConfirmerName2", getResetConfirmerName2())
+            .append("resetConfirmTime2", getResetConfirmTime2())
+            .append("revokeConfirm", getRevokeConfirm())
+            .append("remarks", getRemarks())
+            .append("status", getStatus())
+            .append("delFlag", getDelFlag())
+            .append("createrCode", getCreaterCode())
+            .append("createdate", getCreatedate())
+            .append("updaterCode", getUpdaterCode())
+            .append("updatedate", getUpdatedate())
+            .append("deptId", getDeptId())
+            .append("approveStatus", getApproveStatus())
+            .toString();
+    }
+}

+ 63 - 0
master/src/main/java/com/ruoyi/project/apply/mapper/TApplyOfflinevalveMapper.java

@@ -0,0 +1,63 @@
+package com.ruoyi.project.apply.mapper;
+
+import java.util.List;
+import com.ruoyi.framework.aspectj.lang.annotation.DataScope;
+import com.ruoyi.project.apply.domain.TApplyOfflinevalve;
+
+/**
+ * 安全阀离线切出申请Mapper接口
+ * 
+ * @author ruoyi
+ * @date 2023-02-08
+ */
+public interface TApplyOfflinevalveMapper 
+{
+    /**
+     * 查询安全阀离线切出申请
+     * 
+     * @param id 安全阀离线切出申请ID
+     * @return 安全阀离线切出申请
+     */
+    public TApplyOfflinevalve selectTApplyOfflinevalveById(Long id);
+
+    /**
+     * 查询安全阀离线切出申请列表
+     * 
+     * @param tApplyOfflinevalve 安全阀离线切出申请
+     * @return 安全阀离线切出申请集合
+     */
+    @DataScope(deptAlias = "d")
+    public List<TApplyOfflinevalve> selectTApplyOfflinevalveList(TApplyOfflinevalve tApplyOfflinevalve);
+
+    /**
+     * 新增安全阀离线切出申请
+     * 
+     * @param tApplyOfflinevalve 安全阀离线切出申请
+     * @return 结果
+     */
+    public int insertTApplyOfflinevalve(TApplyOfflinevalve tApplyOfflinevalve);
+
+    /**
+     * 修改安全阀离线切出申请
+     * 
+     * @param tApplyOfflinevalve 安全阀离线切出申请
+     * @return 结果
+     */
+    public int updateTApplyOfflinevalve(TApplyOfflinevalve tApplyOfflinevalve);
+
+    /**
+     * 删除安全阀离线切出申请
+     * 
+     * @param id 安全阀离线切出申请ID
+     * @return 结果
+     */
+    public int deleteTApplyOfflinevalveById(Long id);
+
+    /**
+     * 批量删除安全阀离线切出申请
+     * 
+     * @param ids 需要删除的数据ID
+     * @return 结果
+     */
+    public int deleteTApplyOfflinevalveByIds(Long[] ids);
+}

+ 63 - 0
master/src/main/java/com/ruoyi/project/apply/mapper/TApplySafetychangeMapper.java

@@ -0,0 +1,63 @@
+package com.ruoyi.project.apply.mapper;
+
+import java.util.List;
+import com.ruoyi.framework.aspectj.lang.annotation.DataScope;
+import com.ruoyi.project.apply.domain.TApplySafetychange;
+
+/**
+ * 组织保护措施状态变更申请Mapper接口
+ * 
+ * @author ruoyi
+ * @date 2023-02-09
+ */
+public interface TApplySafetychangeMapper 
+{
+    /**
+     * 查询组织保护措施状态变更申请
+     * 
+     * @param id 组织保护措施状态变更申请ID
+     * @return 组织保护措施状态变更申请
+     */
+    public TApplySafetychange selectTApplySafetychangeById(Long id);
+
+    /**
+     * 查询组织保护措施状态变更申请列表
+     * 
+     * @param tApplySafetychange 组织保护措施状态变更申请
+     * @return 组织保护措施状态变更申请集合
+     */
+    @DataScope(deptAlias = "d")
+    public List<TApplySafetychange> selectTApplySafetychangeList(TApplySafetychange tApplySafetychange);
+
+    /**
+     * 新增组织保护措施状态变更申请
+     * 
+     * @param tApplySafetychange 组织保护措施状态变更申请
+     * @return 结果
+     */
+    public int insertTApplySafetychange(TApplySafetychange tApplySafetychange);
+
+    /**
+     * 修改组织保护措施状态变更申请
+     * 
+     * @param tApplySafetychange 组织保护措施状态变更申请
+     * @return 结果
+     */
+    public int updateTApplySafetychange(TApplySafetychange tApplySafetychange);
+
+    /**
+     * 删除组织保护措施状态变更申请
+     * 
+     * @param id 组织保护措施状态变更申请ID
+     * @return 结果
+     */
+    public int deleteTApplySafetychangeById(Long id);
+
+    /**
+     * 批量删除组织保护措施状态变更申请
+     * 
+     * @param ids 需要删除的数据ID
+     * @return 结果
+     */
+    public int deleteTApplySafetychangeByIds(Long[] ids);
+}

+ 61 - 0
master/src/main/java/com/ruoyi/project/apply/service/ITApplyOfflinevalveService.java

@@ -0,0 +1,61 @@
+package com.ruoyi.project.apply.service;
+
+import java.util.List;
+import com.ruoyi.project.apply.domain.TApplyOfflinevalve;
+
+/**
+ * 安全阀离线切出申请Service接口
+ * 
+ * @author ruoyi
+ * @date 2023-02-08
+ */
+public interface ITApplyOfflinevalveService 
+{
+    /**
+     * 查询安全阀离线切出申请
+     * 
+     * @param id 安全阀离线切出申请ID
+     * @return 安全阀离线切出申请
+     */
+    public TApplyOfflinevalve selectTApplyOfflinevalveById(Long id);
+
+    /**
+     * 查询安全阀离线切出申请列表
+     * 
+     * @param tApplyOfflinevalve 安全阀离线切出申请
+     * @return 安全阀离线切出申请集合
+     */
+    public List<TApplyOfflinevalve> selectTApplyOfflinevalveList(TApplyOfflinevalve tApplyOfflinevalve);
+
+    /**
+     * 新增安全阀离线切出申请
+     * 
+     * @param tApplyOfflinevalve 安全阀离线切出申请
+     * @return 结果
+     */
+    public int insertTApplyOfflinevalve(TApplyOfflinevalve tApplyOfflinevalve);
+
+    /**
+     * 修改安全阀离线切出申请
+     * 
+     * @param tApplyOfflinevalve 安全阀离线切出申请
+     * @return 结果
+     */
+    public int updateTApplyOfflinevalve(TApplyOfflinevalve tApplyOfflinevalve);
+
+    /**
+     * 批量删除安全阀离线切出申请
+     * 
+     * @param ids 需要删除的安全阀离线切出申请ID
+     * @return 结果
+     */
+    public int deleteTApplyOfflinevalveByIds(Long[] ids);
+
+    /**
+     * 删除安全阀离线切出申请信息
+     * 
+     * @param id 安全阀离线切出申请ID
+     * @return 结果
+     */
+    public int deleteTApplyOfflinevalveById(Long id);
+}

+ 61 - 0
master/src/main/java/com/ruoyi/project/apply/service/ITApplySafetychangeService.java

@@ -0,0 +1,61 @@
+package com.ruoyi.project.apply.service;
+
+import java.util.List;
+import com.ruoyi.project.apply.domain.TApplySafetychange;
+
+/**
+ * 组织保护措施状态变更申请Service接口
+ * 
+ * @author ruoyi
+ * @date 2023-02-09
+ */
+public interface ITApplySafetychangeService 
+{
+    /**
+     * 查询组织保护措施状态变更申请
+     * 
+     * @param id 组织保护措施状态变更申请ID
+     * @return 组织保护措施状态变更申请
+     */
+    public TApplySafetychange selectTApplySafetychangeById(Long id);
+
+    /**
+     * 查询组织保护措施状态变更申请列表
+     * 
+     * @param tApplySafetychange 组织保护措施状态变更申请
+     * @return 组织保护措施状态变更申请集合
+     */
+    public List<TApplySafetychange> selectTApplySafetychangeList(TApplySafetychange tApplySafetychange);
+
+    /**
+     * 新增组织保护措施状态变更申请
+     * 
+     * @param tApplySafetychange 组织保护措施状态变更申请
+     * @return 结果
+     */
+    public int insertTApplySafetychange(TApplySafetychange tApplySafetychange);
+
+    /**
+     * 修改组织保护措施状态变更申请
+     * 
+     * @param tApplySafetychange 组织保护措施状态变更申请
+     * @return 结果
+     */
+    public int updateTApplySafetychange(TApplySafetychange tApplySafetychange);
+
+    /**
+     * 批量删除组织保护措施状态变更申请
+     * 
+     * @param ids 需要删除的组织保护措施状态变更申请ID
+     * @return 结果
+     */
+    public int deleteTApplySafetychangeByIds(Long[] ids);
+
+    /**
+     * 删除组织保护措施状态变更申请信息
+     * 
+     * @param id 组织保护措施状态变更申请ID
+     * @return 结果
+     */
+    public int deleteTApplySafetychangeById(Long id);
+}

+ 93 - 0
master/src/main/java/com/ruoyi/project/apply/service/impl/TApplyOfflinevalveServiceImpl.java

@@ -0,0 +1,93 @@
+package com.ruoyi.project.apply.service.impl;
+
+import java.util.List;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import com.ruoyi.project.apply.mapper.TApplyOfflinevalveMapper;
+import com.ruoyi.project.apply.domain.TApplyOfflinevalve;
+import com.ruoyi.project.apply.service.ITApplyOfflinevalveService;
+
+/**
+ * 安全阀离线切出申请Service业务层处理
+ *
+ * @author ruoyi
+ * @date 2023-02-08
+ */
+@Service
+public class TApplyOfflinevalveServiceImpl implements ITApplyOfflinevalveService
+{
+    @Autowired
+    private TApplyOfflinevalveMapper tApplyOfflinevalveMapper;
+
+    /**
+     * 查询安全阀离线切出申请
+     *
+     * @param id 安全阀离线切出申请ID
+     * @return 安全阀离线切出申请
+     */
+    @Override
+    public TApplyOfflinevalve selectTApplyOfflinevalveById(Long id)
+    {
+        return tApplyOfflinevalveMapper.selectTApplyOfflinevalveById(id);
+    }
+
+    /**
+     * 查询安全阀离线切出申请列表
+     *
+     * @param tApplyOfflinevalve 安全阀离线切出申请
+     * @return 安全阀离线切出申请
+     */
+    @Override
+    public List<TApplyOfflinevalve> selectTApplyOfflinevalveList(TApplyOfflinevalve tApplyOfflinevalve)
+    {
+        return tApplyOfflinevalveMapper.selectTApplyOfflinevalveList(tApplyOfflinevalve);
+    }
+
+    /**
+     * 新增安全阀离线切出申请
+     *
+     * @param tApplyOfflinevalve 安全阀离线切出申请
+     * @return 结果
+     */
+    @Override
+    public int insertTApplyOfflinevalve(TApplyOfflinevalve tApplyOfflinevalve)
+    {
+        return tApplyOfflinevalveMapper.insertTApplyOfflinevalve(tApplyOfflinevalve);
+    }
+
+    /**
+     * 修改安全阀离线切出申请
+     *
+     * @param tApplyOfflinevalve 安全阀离线切出申请
+     * @return 结果
+     */
+    @Override
+    public int updateTApplyOfflinevalve(TApplyOfflinevalve tApplyOfflinevalve)
+    {
+        return tApplyOfflinevalveMapper.updateTApplyOfflinevalve(tApplyOfflinevalve);
+    }
+
+    /**
+     * 批量删除安全阀离线切出申请
+     *
+     * @param ids 需要删除的安全阀离线切出申请ID
+     * @return 结果
+     */
+    @Override
+    public int deleteTApplyOfflinevalveByIds(Long[] ids)
+    {
+        return tApplyOfflinevalveMapper.deleteTApplyOfflinevalveByIds(ids);
+    }
+
+    /**
+     * 删除安全阀离线切出申请信息
+     *
+     * @param id 安全阀离线切出申请ID
+     * @return 结果
+     */
+    @Override
+    public int deleteTApplyOfflinevalveById(Long id)
+    {
+        return tApplyOfflinevalveMapper.deleteTApplyOfflinevalveById(id);
+    }
+}

+ 93 - 0
master/src/main/java/com/ruoyi/project/apply/service/impl/TApplySafetychangeServiceImpl.java

@@ -0,0 +1,93 @@
+package com.ruoyi.project.apply.service.impl;
+
+import java.util.List;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import com.ruoyi.project.apply.mapper.TApplySafetychangeMapper;
+import com.ruoyi.project.apply.domain.TApplySafetychange;
+import com.ruoyi.project.apply.service.ITApplySafetychangeService;
+
+/**
+ * 组织保护措施状态变更申请Service业务层处理
+ *
+ * @author ruoyi
+ * @date 2023-02-09
+ */
+@Service
+public class TApplySafetychangeServiceImpl implements ITApplySafetychangeService
+{
+    @Autowired
+    private TApplySafetychangeMapper tApplySafetychangeMapper;
+
+    /**
+     * 查询组织保护措施状态变更申请
+     *
+     * @param id 组织保护措施状态变更申请ID
+     * @return 组织保护措施状态变更申请
+     */
+    @Override
+    public TApplySafetychange selectTApplySafetychangeById(Long id)
+    {
+        return tApplySafetychangeMapper.selectTApplySafetychangeById(id);
+    }
+
+    /**
+     * 查询组织保护措施状态变更申请列表
+     *
+     * @param tApplySafetychange 组织保护措施状态变更申请
+     * @return 组织保护措施状态变更申请
+     */
+    @Override
+    public List<TApplySafetychange> selectTApplySafetychangeList(TApplySafetychange tApplySafetychange)
+    {
+        return tApplySafetychangeMapper.selectTApplySafetychangeList(tApplySafetychange);
+    }
+
+    /**
+     * 新增组织保护措施状态变更申请
+     *
+     * @param tApplySafetychange 组织保护措施状态变更申请
+     * @return 结果
+     */
+    @Override
+    public int insertTApplySafetychange(TApplySafetychange tApplySafetychange)
+    {
+        return tApplySafetychangeMapper.insertTApplySafetychange(tApplySafetychange);
+    }
+
+    /**
+     * 修改组织保护措施状态变更申请
+     *
+     * @param tApplySafetychange 组织保护措施状态变更申请
+     * @return 结果
+     */
+    @Override
+    public int updateTApplySafetychange(TApplySafetychange tApplySafetychange)
+    {
+        return tApplySafetychangeMapper.updateTApplySafetychange(tApplySafetychange);
+    }
+
+    /**
+     * 批量删除组织保护措施状态变更申请
+     *
+     * @param ids 需要删除的组织保护措施状态变更申请ID
+     * @return 结果
+     */
+    @Override
+    public int deleteTApplySafetychangeByIds(Long[] ids)
+    {
+        return tApplySafetychangeMapper.deleteTApplySafetychangeByIds(ids);
+    }
+
+    /**
+     * 删除组织保护措施状态变更申请信息
+     *
+     * @param id 组织保护措施状态变更申请ID
+     * @return 结果
+     */
+    @Override
+    public int deleteTApplySafetychangeById(Long id)
+    {
+        return tApplySafetychangeMapper.deleteTApplySafetychangeById(id);
+    }
+}

+ 24 - 17
master/src/main/java/com/ruoyi/project/reliability/controller/TSafetyvavleController.java

@@ -1,35 +1,37 @@
 package com.ruoyi.project.reliability.controller;
 
-import java.io.IOException;
-import java.text.SimpleDateFormat;
-import java.util.ArrayList;
-import java.util.Date;
-import java.util.List;
-import java.util.Map;
-
 import com.alibaba.fastjson.JSON;
 import com.ruoyi.common.utils.DateUtils;
 import com.ruoyi.common.utils.file.ExcelUtils;
+import com.ruoyi.common.utils.poi.ExcelUtil;
+import com.ruoyi.framework.aspectj.lang.annotation.Log;
+import com.ruoyi.framework.aspectj.lang.enums.BusinessType;
+import com.ruoyi.framework.web.controller.BaseController;
+import com.ruoyi.framework.web.domain.AjaxResult;
+import com.ruoyi.framework.web.page.TableDataInfo;
+import com.ruoyi.project.reliability.domain.TSafetyvavle;
+import com.ruoyi.project.reliability.service.ITSafetyvavleService;
 import com.ruoyi.project.system.domain.SysDept;
 import com.ruoyi.project.system.domain.SysDictData;
 import com.ruoyi.project.system.domain.TUploadhistory;
 import com.ruoyi.project.system.service.ISysDeptService;
 import com.ruoyi.project.system.service.ISysDictTypeService;
 import com.ruoyi.project.system.service.ITUploadhistoryService;
-import org.apache.poi.ss.usermodel.*;
-import org.springframework.security.access.prepost.PreAuthorize;
+import org.apache.poi.ss.usermodel.Cell;
+import org.apache.poi.ss.usermodel.Row;
+import org.apache.poi.ss.usermodel.Sheet;
+import org.apache.poi.ss.usermodel.Workbook;
 import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.security.access.prepost.PreAuthorize;
 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.reliability.domain.TSafetyvavle;
-import com.ruoyi.project.reliability.service.ITSafetyvavleService;
-import com.ruoyi.framework.web.controller.BaseController;
-import com.ruoyi.framework.web.domain.AjaxResult;
-import com.ruoyi.common.utils.poi.ExcelUtil;
-import com.ruoyi.framework.web.page.TableDataInfo;
 import org.springframework.web.multipart.MultipartFile;
 
+import java.io.IOException;
+import java.text.SimpleDateFormat;
+import java.util.ArrayList;
+import java.util.Date;
+import java.util.List;
+
 /**
  * 安全阀清单Controller
  *
@@ -297,4 +299,9 @@ public class TSafetyvavleController extends BaseController
         logger.info("failRow:" +String.valueOf(failRow));
         return AjaxResult.success(String.valueOf(successNumber), failRow);
     }
+
+    @GetMapping("/allSafetyvavle")
+    public AjaxResult allSafetyvavle() {
+        return AjaxResult.success(tSafetyvavleService.selectList(new TSafetyvavle()));
+    }
 }

+ 247 - 0
master/src/main/resources/mybatis/apply/TApplyOfflinevalveMapper.xml

@@ -0,0 +1,247 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper
+        PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+        "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.ruoyi.project.apply.mapper.TApplyOfflinevalveMapper">
+
+    <resultMap type="TApplyOfflinevalve" id="TApplyOfflinevalveResult">
+        <result property="id"    column="id"    />
+        <result property="devNo"    column="dev_no"    />
+        <result property="unit"    column="unit"    />
+        <result property="offlineReason"    column="offline_reason"    />
+        <result property="safa"    column="safa"    />
+        <result property="disassembly"    column="disassembly"    />
+        <result property="executor"    column="executor"    />
+        <result property="confirmer"    column="confirmer"    />
+        <result property="applicant"    column="applicant"    />
+        <result property="applicationTime"    column="application_time"    />
+        <result property="approver"    column="approver"    />
+        <result property="approveTime"    column="approve_time"    />
+        <result property="resetConfirm"    column="reset_confirm"    />
+        <result property="leakConfirm"    column="leak_confirm"    />
+        <result property="revokeConfirm"    column="revoke_confirm"    />
+        <result property="lockConfirm"    column="lock_confirm"    />
+        <result property="lockConfirmer1"    column="lock_confirmer1"    />
+        <result property="lockConfirmer2"    column="lock_confirmer2"    />
+        <result property="infoConfirmer"    column="info_confirmer"    />
+        <result property="confirmTime"    column="confirm_time"    />
+        <result property="remarks"    column="remarks"    />
+        <result property="temporaryTime"    column="temporary_time"    />
+        <result property="executionTime"    column="execution_time"    />
+        <result property="status"    column="status"    />
+        <result property="delFlag"    column="del_flag"    />
+        <result property="createrCode"    column="creater_code"    />
+        <result property="createdate"    column="createdate"    />
+        <result property="updaterCode"    column="updater_code"    />
+        <result property="updatedate"    column="updatedate"    />
+        <result property="deptId"    column="dept_id"    />
+        <result property="approveStatus"    column="approve_status"    />
+        <result property="lockConfirmer1Name"    column="lock_confirmer1_name"    />
+        <result property="lockConfirmer2Name"    column="lock_confirmer2_name"    />
+        <result property="infoConfirmerName"    column="info_confirmer_name"    />
+        <result property="executorName"    column="executor_name"    />
+        <result property="confirmerName"    column="confirmer_name"    />
+        <result property="approverName"    column="approver_name"    />
+        <result property="applicantName"    column="applicant_name"    />
+        <result property="deptName" column="dept_name" />
+    </resultMap>
+
+    <sql id="selectTApplyOfflinevalveVo">
+        select d.id, d.dev_no, d.unit, d.offline_reason, d.safa, d.disassembly, d.executor, d.confirmer, d.applicant, d.application_time, d.approver, d.approve_time, d.reset_confirm, d.leak_confirm, d.revoke_confirm, d.lock_confirm, d.lock_confirmer1, d.lock_confirmer2, d.info_confirmer, d.confirm_time, d.remarks, d.temporary_time, d.execution_time, d.status, d.del_flag, d.creater_code, d.createdate, d.updater_code, d.updatedate, d.dept_id, d.approve_status, d.lock_confirmer1_name, d.lock_confirmer2_name, d.info_confirmer_name, d.executor_name, d.confirmer_name, d.approver_name, d.applicant_name ,s.dept_name from t_apply_offlinevalve d
+                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 left join sys_dept s on s.dept_id = d.dept_id
+    </sql>
+
+    <select id="selectTApplyOfflinevalveList" parameterType="TApplyOfflinevalve" resultMap="TApplyOfflinevalveResult">
+        <include refid="selectTApplyOfflinevalveVo"/>
+        <where>
+            <if test="devNo != null  and devNo != ''"> and dev_no like concat(concat('%', #{devNo}), '%')</if>
+            <if test="unit != null  and unit != ''"> and unit = #{unit}</if>
+            <if test="offlineReason != null  and offlineReason != ''"> and offline_reason like concat(concat('%', #{offlineReason}), '%')</if>
+            <if test="safa != null  and safa != ''"> and safa = #{safa}</if>
+            <if test="disassembly != null "> and disassembly = #{disassembly}</if>
+            <if test="executor != null  and executor != ''"> and executor = #{executor}</if>
+            <if test="confirmer != null  and confirmer != ''"> and confirmer = #{confirmer}</if>
+            <if test="applicant != null  and applicant != ''"> and applicant = #{applicant}</if>
+            <if test="applicationTime != null "> and application_time = #{applicationTime}</if>
+            <if test="approver != null  and approver != ''"> and approver = #{approver}</if>
+            <if test="approveTime != null "> and approve_time = #{approveTime}</if>
+            <if test="resetConfirm != null "> and reset_confirm = #{resetConfirm}</if>
+            <if test="leakConfirm != null "> and leak_confirm = #{leakConfirm}</if>
+            <if test="revokeConfirm != null "> and revoke_confirm = #{revokeConfirm}</if>
+            <if test="lockConfirm != null "> and lock_confirm = #{lockConfirm}</if>
+            <if test="lockConfirmer1 != null  and lockConfirmer1 != ''"> and lock_confirmer1 = #{lockConfirmer1}</if>
+            <if test="lockConfirmer2 != null  and lockConfirmer2 != ''"> and lock_confirmer2 = #{lockConfirmer2}</if>
+            <if test="infoConfirmer != null  and infoConfirmer != ''"> and info_confirmer = #{infoConfirmer}</if>
+            <if test="confirmTime != null "> and confirm_time = #{confirmTime}</if>
+            <if test="remarks != null  and remarks != ''"> and remarks = #{remarks}</if>
+            <if test="temporaryTime != null "> and temporary_time = #{temporaryTime}</if>
+            <if test="executionTime != null "> and execution_time = #{executionTime}</if>
+            <if test="status != null "> and status = #{status}</if>
+            <if test="createrCode != null  and createrCode != ''"> and creater_code = #{createrCode}</if>
+            <if test="createdate != null "> and createdate = #{createdate}</if>
+            <if test="updaterCode != null "> and updater_code = #{updaterCode}</if>
+            <if test="updatedate != null "> and updatedate = #{updatedate}</if>
+            <if test="deptId != null "> and dept_id = #{deptId}</if>
+            <if test="approveStatus != null  and approveStatus != ''"> and approve_status = #{approveStatus}</if>
+            <if test="lockConfirmer1Name != null  and lockConfirmer1Name != ''"> and lock_confirmer1_name like concat(concat('%', #{lockConfirmer1Name}), '%')</if>
+            <if test="lockConfirmer2Name != null  and lockConfirmer2Name != ''"> and lock_confirmer2_name like concat(concat('%', #{lockConfirmer2Name}), '%')</if>
+            <if test="infoConfirmerName != null  and infoConfirmerName != ''"> and info_confirmer_name like concat(concat('%', #{infoConfirmerName}), '%')</if>
+            <if test="executorName != null  and executorName != ''"> and executor_name like concat(concat('%', #{executorName}), '%')</if>
+            <if test="confirmerName != null  and confirmerName != ''"> and confirmer_name like concat(concat('%', #{confirmerName}), '%')</if>
+            <if test="approverName != null  and approverName != ''"> and approver_name like concat(concat('%', #{approverName}), '%')</if>
+            <if test="applicantName != null  and applicantName != ''"> and applicant_name like concat(concat('%', #{applicantName}), '%')</if>
+            and d.del_flag = 0
+        </where>
+        <!-- 数据范围过滤 -->
+        ${params.dataScope}
+        order by createdate desc
+    </select>
+
+    <select id="selectTApplyOfflinevalveById" parameterType="Long" resultMap="TApplyOfflinevalveResult">
+        <include refid="selectTApplyOfflinevalveVo"/>
+        where id = #{id}
+    </select>
+
+    <insert id="insertTApplyOfflinevalve" parameterType="TApplyOfflinevalve">
+        <selectKey keyProperty="id" resultType="long" order="BEFORE">
+            SELECT seq_t_apply_offlinevalve.NEXTVAL as id FROM DUAL
+        </selectKey>
+        insert into t_apply_offlinevalve
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="id != null">id,</if>
+            <if test="devNo != null">dev_no,</if>
+            <if test="unit != null">unit,</if>
+            <if test="offlineReason != null">offline_reason,</if>
+            <if test="safa != null">safa,</if>
+            <if test="disassembly != null">disassembly,</if>
+            <if test="executor != null">executor,</if>
+            <if test="confirmer != null">confirmer,</if>
+            <if test="applicant != null">applicant,</if>
+            <if test="applicationTime != null">application_time,</if>
+            <if test="approver != null">approver,</if>
+            <if test="approveTime != null">approve_time,</if>
+            <if test="resetConfirm != null">reset_confirm,</if>
+            <if test="leakConfirm != null">leak_confirm,</if>
+            <if test="revokeConfirm != null">revoke_confirm,</if>
+            <if test="lockConfirm != null">lock_confirm,</if>
+            <if test="lockConfirmer1 != null">lock_confirmer1,</if>
+            <if test="lockConfirmer2 != null">lock_confirmer2,</if>
+            <if test="infoConfirmer != null">info_confirmer,</if>
+            <if test="confirmTime != null">confirm_time,</if>
+            <if test="remarks != null">remarks,</if>
+            <if test="temporaryTime != null">temporary_time,</if>
+            <if test="executionTime != null">execution_time,</if>
+            <if test="status != null">status,</if>
+            <if test="delFlag != null">del_flag,</if>
+            <if test="createrCode != null">creater_code,</if>
+            <if test="createdate != null">createdate,</if>
+            <if test="updaterCode != null">updater_code,</if>
+            <if test="updatedate != null">updatedate,</if>
+            <if test="deptId != null">dept_id,</if>
+            <if test="approveStatus != null">approve_status,</if>
+            <if test="lockConfirmer1Name != null">lock_confirmer1_name,</if>
+            <if test="lockConfirmer2Name != null">lock_confirmer2_name,</if>
+            <if test="infoConfirmerName != null">info_confirmer_name,</if>
+            <if test="executorName != null">executor_name,</if>
+            <if test="confirmerName != null">confirmer_name,</if>
+            <if test="approverName != null">approver_name,</if>
+            <if test="applicantName != null">applicant_name,</if>
+        </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="id != null">#{id},</if>
+            <if test="devNo != null">#{devNo},</if>
+            <if test="unit != null">#{unit},</if>
+            <if test="offlineReason != null">#{offlineReason},</if>
+            <if test="safa != null">#{safa},</if>
+            <if test="disassembly != null">#{disassembly},</if>
+            <if test="executor != null">#{executor},</if>
+            <if test="confirmer != null">#{confirmer},</if>
+            <if test="applicant != null">#{applicant},</if>
+            <if test="applicationTime != null">#{applicationTime},</if>
+            <if test="approver != null">#{approver},</if>
+            <if test="approveTime != null">#{approveTime},</if>
+            <if test="resetConfirm != null">#{resetConfirm},</if>
+            <if test="leakConfirm != null">#{leakConfirm},</if>
+            <if test="revokeConfirm != null">#{revokeConfirm},</if>
+            <if test="lockConfirm != null">#{lockConfirm},</if>
+            <if test="lockConfirmer1 != null">#{lockConfirmer1},</if>
+            <if test="lockConfirmer2 != null">#{lockConfirmer2},</if>
+            <if test="infoConfirmer != null">#{infoConfirmer},</if>
+            <if test="confirmTime != null">#{confirmTime},</if>
+            <if test="remarks != null">#{remarks},</if>
+            <if test="temporaryTime != null">#{temporaryTime},</if>
+            <if test="executionTime != null">#{executionTime},</if>
+            <if test="status != null">#{status},</if>
+            <if test="delFlag != null">#{delFlag},</if>
+            <if test="createrCode != null">#{createrCode},</if>
+            <if test="createdate != null">#{createdate},</if>
+            <if test="updaterCode != null">#{updaterCode},</if>
+            <if test="updatedate != null">#{updatedate},</if>
+            <if test="deptId != null">#{deptId},</if>
+            <if test="approveStatus != null">#{approveStatus},</if>
+            <if test="lockConfirmer1Name != null">#{lockConfirmer1Name},</if>
+            <if test="lockConfirmer2Name != null">#{lockConfirmer2Name},</if>
+            <if test="infoConfirmerName != null">#{infoConfirmerName},</if>
+            <if test="executorName != null">#{executorName},</if>
+            <if test="confirmerName != null">#{confirmerName},</if>
+            <if test="approverName != null">#{approverName},</if>
+            <if test="applicantName != null">#{applicantName},</if>
+        </trim>
+    </insert>
+
+    <update id="updateTApplyOfflinevalve" parameterType="TApplyOfflinevalve">
+        update t_apply_offlinevalve
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="devNo != null">dev_no = #{devNo},</if>
+            <if test="unit != null">unit = #{unit},</if>
+            <if test="offlineReason != null">offline_reason = #{offlineReason},</if>
+            <if test="safa != null">safa = #{safa},</if>
+            <if test="disassembly != null">disassembly = #{disassembly},</if>
+            <if test="executor != null">executor = #{executor},</if>
+            <if test="confirmer != null">confirmer = #{confirmer},</if>
+            <if test="applicant != null">applicant = #{applicant},</if>
+            <if test="applicationTime != null">application_time = #{applicationTime},</if>
+            <if test="approver != null">approver = #{approver},</if>
+            <if test="approveTime != null">approve_time = #{approveTime},</if>
+            <if test="resetConfirm != null">reset_confirm = #{resetConfirm},</if>
+            <if test="leakConfirm != null">leak_confirm = #{leakConfirm},</if>
+            <if test="revokeConfirm != null">revoke_confirm = #{revokeConfirm},</if>
+            <if test="lockConfirm != null">lock_confirm = #{lockConfirm},</if>
+            <if test="lockConfirmer1 != null">lock_confirmer1 = #{lockConfirmer1},</if>
+            <if test="lockConfirmer2 != null">lock_confirmer2 = #{lockConfirmer2},</if>
+            <if test="infoConfirmer != null">info_confirmer = #{infoConfirmer},</if>
+            <if test="confirmTime != null">confirm_time = #{confirmTime},</if>
+            <if test="remarks != null">remarks = #{remarks},</if>
+            <if test="temporaryTime != null">temporary_time = #{temporaryTime},</if>
+            <if test="executionTime != null">execution_time = #{executionTime},</if>
+            <if test="status != null">status = #{status},</if>
+            <if test="delFlag != null">del_flag = #{delFlag},</if>
+            <if test="createrCode != null">creater_code = #{createrCode},</if>
+            <if test="createdate != null">createdate = #{createdate},</if>
+            <if test="updaterCode != null">updater_code = #{updaterCode},</if>
+            <if test="updatedate != null">updatedate = #{updatedate},</if>
+            <if test="deptId != null">dept_id = #{deptId},</if>
+            <if test="approveStatus != null">approve_status = #{approveStatus},</if>
+            <if test="lockConfirmer1Name != null">lock_confirmer1_name = #{lockConfirmer1Name},</if>
+            <if test="lockConfirmer2Name != null">lock_confirmer2_name = #{lockConfirmer2Name},</if>
+            <if test="infoConfirmerName != null">info_confirmer_name = #{infoConfirmerName},</if>
+            <if test="executorName != null">executor_name = #{executorName},</if>
+            <if test="confirmerName != null">confirmer_name = #{confirmerName},</if>
+            <if test="approverName != null">approver_name = #{approverName},</if>
+            <if test="applicantName != null">applicant_name = #{applicantName},</if>
+        </trim>
+        where id = #{id}
+    </update>
+
+    <update id="deleteTApplyOfflinevalveById" parameterType="Long">
+        update t_apply_offlinevalve set del_flag = 2 where id = #{id}
+    </update>
+
+    <update id="deleteTApplyOfflinevalveByIds" parameterType="String">
+        update t_apply_offlinevalve set del_flag = 2 where id in
+        <foreach item="id" collection="array" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </update>
+
+</mapper>

+ 257 - 0
master/src/main/resources/mybatis/apply/TApplySafetychangeMapper.xml

@@ -0,0 +1,257 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper
+PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.ruoyi.project.apply.mapper.TApplySafetychangeMapper">
+
+    <resultMap type="TApplySafetychange" id="TApplySafetychangeResult">
+        <result property="id"    column="id"    />
+        <result property="changeDescribe"    column="change_describe"    />
+        <result property="changeReason"    column="change_reason"    />
+        <result property="applicant"    column="applicant"    />
+        <result property="applicantName"    column="applicant_name"    />
+        <result property="applicationTime"    column="application_time"    />
+        <result property="safa"    column="safa"    />
+        <result property="safaer"    column="safaer"    />
+        <result property="safaerName"    column="safaer_name"    />
+        <result property="safaTime"    column="safa_time"    />
+        <result property="approver"    column="approver"    />
+        <result property="approverName"    column="approver_name"    />
+        <result property="approveTime"    column="approve_time"    />
+        <result property="executor"    column="executor"    />
+        <result property="executorName"    column="executor_name"    />
+        <result property="executionTime"    column="execution_time"    />
+        <result property="confirmer"    column="confirmer"    />
+        <result property="confirmerName"    column="confirmer_name"    />
+        <result property="confirmTime"    column="confirm_time"    />
+        <result property="changeExecution"    column="change_execution"    />
+        <result property="changeExecutor"    column="change_executor"    />
+        <result property="changeExecutorName"    column="change_executor_name"    />
+        <result property="changeExecutorTime"    column="change_executor_time"    />
+        <result property="resetConfirm"    column="reset_confirm"    />
+        <result property="resetConfirmer1"    column="reset_confirmer1"    />
+        <result property="resetConfirmerName1"    column="reset_confirmer_name1"    />
+        <result property="resetConfirmTime1"    column="reset_confirm_time1"    />
+        <result property="resetConfirmer2"    column="reset_confirmer2"    />
+        <result property="resetConfirmerName2"    column="reset_confirmer_name2"    />
+        <result property="resetConfirmTime2"    column="reset_confirm_time2"    />
+        <result property="revokeConfirm"    column="revoke_confirm"    />
+        <result property="remarks"    column="remarks"    />
+        <result property="status"    column="status"    />
+        <result property="delFlag"    column="del_flag"    />
+        <result property="createrCode"    column="creater_code"    />
+        <result property="createdate"    column="createdate"    />
+        <result property="updaterCode"    column="updater_code"    />
+        <result property="updatedate"    column="updatedate"    />
+        <result property="deptId"    column="dept_id"    />
+        <result property="approveStatus"    column="approve_status"    />
+        <result property="deptName" column="dept_name" />
+    </resultMap>
+
+    <sql id="selectTApplySafetychangeVo">
+        select d.id, d.change_describe, d.change_reason, d.applicant, d.applicant_name, d.application_time, d.safa, d.safaer, d.safaer_name, d.safa_time, d.approver, d.approver_name, d.approve_time, d.executor, d.executor_name, d.execution_time, d.confirmer, d.confirmer_name, d.confirm_time, d.change_execution, d.change_executor, d.change_executor_name, d.change_executor_time, d.reset_confirm, d.reset_confirmer1, d.reset_confirmer_name1, d.reset_confirm_time1, d.reset_confirmer2, d.reset_confirmer_name2, d.reset_confirm_time2, d.revoke_confirm, d.remarks, d.status, d.del_flag, d.creater_code, d.createdate, d.updater_code, d.updatedate, d.dept_id, d.approve_status ,s.dept_name from t_apply_safetychange d
+      left join sys_dept s on s.dept_id = d.dept_id
+    </sql>
+
+    <select id="selectTApplySafetychangeList" parameterType="TApplySafetychange" resultMap="TApplySafetychangeResult">
+        <include refid="selectTApplySafetychangeVo"/>
+        <where>
+            <if test="changeDescribe != null  and changeDescribe != ''"> and change_describe = #{changeDescribe}</if>
+            <if test="changeReason != null  and changeReason != ''"> and change_reason = #{changeReason}</if>
+            <if test="applicant != null  and applicant != ''"> and applicant = #{applicant}</if>
+            <if test="applicantName != null  and applicantName != ''"> and applicant_name like concat(concat('%', #{applicantName}), '%')</if>
+            <if test="applicationTime != null "> and application_time = #{applicationTime}</if>
+            <if test="safa != null  and safa != ''"> and safa = #{safa}</if>
+            <if test="safaer != null  and safaer != ''"> and safaer = #{safaer}</if>
+            <if test="safaerName != null  and safaerName != ''"> and safaer_name like concat(concat('%', #{safaerName}), '%')</if>
+            <if test="safaTime != null "> and safa_time = #{safaTime}</if>
+            <if test="approver != null  and approver != ''"> and approver = #{approver}</if>
+            <if test="approverName != null  and approverName != ''"> and approver_name like concat(concat('%', #{approverName}), '%')</if>
+            <if test="approveTime != null "> and approve_time = #{approveTime}</if>
+            <if test="executor != null  and executor != ''"> and executor = #{executor}</if>
+            <if test="executorName != null  and executorName != ''"> and executor_name like concat(concat('%', #{executorName}), '%')</if>
+            <if test="executionTime != null "> and execution_time = #{executionTime}</if>
+            <if test="confirmer != null  and confirmer != ''"> and confirmer = #{confirmer}</if>
+            <if test="confirmerName != null  and confirmerName != ''"> and confirmer_name like concat(concat('%', #{confirmerName}), '%')</if>
+            <if test="confirmTime != null "> and confirm_time = #{confirmTime}</if>
+            <if test="changeExecution != null  and changeExecution != ''"> and change_execution = #{changeExecution}</if>
+            <if test="changeExecutor != null  and changeExecutor != ''"> and change_executor = #{changeExecutor}</if>
+            <if test="changeExecutorName != null  and changeExecutorName != ''"> and change_executor_name like concat(concat('%', #{changeExecutorName}), '%')</if>
+            <if test="changeExecutorTime != null "> and change_executor_time = #{changeExecutorTime}</if>
+            <if test="resetConfirm != null  and resetConfirm != ''"> and reset_confirm = #{resetConfirm}</if>
+            <if test="resetConfirmer1 != null  and resetConfirmer1 != ''"> and reset_confirmer1 = #{resetConfirmer1}</if>
+            <if test="resetConfirmerName1 != null  and resetConfirmerName1 != ''"> and reset_confirmer_name1 = #{resetConfirmerName1}</if>
+            <if test="resetConfirmTime1 != null "> and reset_confirm_time1 = #{resetConfirmTime1}</if>
+            <if test="resetConfirmer2 != null  and resetConfirmer2 != ''"> and reset_confirmer2 = #{resetConfirmer2}</if>
+            <if test="resetConfirmerName2 != null  and resetConfirmerName2 != ''"> and reset_confirmer_name2 = #{resetConfirmerName2}</if>
+            <if test="resetConfirmTime2 != null "> and reset_confirm_time2 = #{resetConfirmTime2}</if>
+            <if test="revokeConfirm != null  and revokeConfirm != ''"> and revoke_confirm = #{revokeConfirm}</if>
+            <if test="remarks != null  and remarks != ''"> and remarks = #{remarks}</if>
+            <if test="status != null "> and status = #{status}</if>
+            <if test="createrCode != null  and createrCode != ''"> and creater_code = #{createrCode}</if>
+            <if test="createdate != null "> and createdate = #{createdate}</if>
+            <if test="updaterCode != null "> and updater_code = #{updaterCode}</if>
+            <if test="updatedate != null "> and updatedate = #{updatedate}</if>
+            <if test="deptId != null "> and dept_id = #{deptId}</if>
+            <if test="approveStatus != null  and approveStatus != ''"> and approve_status = #{approveStatus}</if>
+            and d.del_flag = 0
+        </where>
+        <!-- 数据范围过滤 -->
+        ${params.dataScope}
+        order by createdate desc
+    </select>
+
+    <select id="selectTApplySafetychangeById" parameterType="Long" resultMap="TApplySafetychangeResult">
+        <include refid="selectTApplySafetychangeVo"/>
+        where id = #{id}
+    </select>
+
+    <insert id="insertTApplySafetychange" parameterType="TApplySafetychange">
+        <selectKey keyProperty="id" resultType="long" order="BEFORE">
+            SELECT seq_t_apply_safetychange.NEXTVAL as id FROM DUAL
+        </selectKey>
+        insert into t_apply_safetychange
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="id != null">id,</if>
+            <if test="changeDescribe != null">change_describe,</if>
+            <if test="changeReason != null">change_reason,</if>
+            <if test="applicant != null">applicant,</if>
+            <if test="applicantName != null">applicant_name,</if>
+            <if test="applicationTime != null">application_time,</if>
+            <if test="safa != null">safa,</if>
+            <if test="safaer != null">safaer,</if>
+            <if test="safaerName != null">safaer_name,</if>
+            <if test="safaTime != null">safa_time,</if>
+            <if test="approver != null">approver,</if>
+            <if test="approverName != null">approver_name,</if>
+            <if test="approveTime != null">approve_time,</if>
+            <if test="executor != null">executor,</if>
+            <if test="executorName != null">executor_name,</if>
+            <if test="executionTime != null">execution_time,</if>
+            <if test="confirmer != null">confirmer,</if>
+            <if test="confirmerName != null">confirmer_name,</if>
+            <if test="confirmTime != null">confirm_time,</if>
+            <if test="changeExecution != null">change_execution,</if>
+            <if test="changeExecutor != null">change_executor,</if>
+            <if test="changeExecutorName != null">change_executor_name,</if>
+            <if test="changeExecutorTime != null">change_executor_time,</if>
+            <if test="resetConfirm != null">reset_confirm,</if>
+            <if test="resetConfirmer1 != null">reset_confirmer1,</if>
+            <if test="resetConfirmerName1 != null">reset_confirmer_name1,</if>
+            <if test="resetConfirmTime1 != null">reset_confirm_time1,</if>
+            <if test="resetConfirmer2 != null">reset_confirmer2,</if>
+            <if test="resetConfirmerName2 != null">reset_confirmer_name2,</if>
+            <if test="resetConfirmTime2 != null">reset_confirm_time2,</if>
+            <if test="revokeConfirm != null">revoke_confirm,</if>
+            <if test="remarks != null">remarks,</if>
+            <if test="status != null">status,</if>
+            <if test="delFlag != null">del_flag,</if>
+            <if test="createrCode != null">creater_code,</if>
+            <if test="createdate != null">createdate,</if>
+            <if test="updaterCode != null">updater_code,</if>
+            <if test="updatedate != null">updatedate,</if>
+            <if test="deptId != null">dept_id,</if>
+            <if test="approveStatus != null">approve_status,</if>
+         </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="id != null">#{id},</if>
+            <if test="changeDescribe != null">#{changeDescribe},</if>
+            <if test="changeReason != null">#{changeReason},</if>
+            <if test="applicant != null">#{applicant},</if>
+            <if test="applicantName != null">#{applicantName},</if>
+            <if test="applicationTime != null">#{applicationTime},</if>
+            <if test="safa != null">#{safa},</if>
+            <if test="safaer != null">#{safaer},</if>
+            <if test="safaerName != null">#{safaerName},</if>
+            <if test="safaTime != null">#{safaTime},</if>
+            <if test="approver != null">#{approver},</if>
+            <if test="approverName != null">#{approverName},</if>
+            <if test="approveTime != null">#{approveTime},</if>
+            <if test="executor != null">#{executor},</if>
+            <if test="executorName != null">#{executorName},</if>
+            <if test="executionTime != null">#{executionTime},</if>
+            <if test="confirmer != null">#{confirmer},</if>
+            <if test="confirmerName != null">#{confirmerName},</if>
+            <if test="confirmTime != null">#{confirmTime},</if>
+            <if test="changeExecution != null">#{changeExecution},</if>
+            <if test="changeExecutor != null">#{changeExecutor},</if>
+            <if test="changeExecutorName != null">#{changeExecutorName},</if>
+            <if test="changeExecutorTime != null">#{changeExecutorTime},</if>
+            <if test="resetConfirm != null">#{resetConfirm},</if>
+            <if test="resetConfirmer1 != null">#{resetConfirmer1},</if>
+            <if test="resetConfirmerName1 != null">#{resetConfirmerName1},</if>
+            <if test="resetConfirmTime1 != null">#{resetConfirmTime1},</if>
+            <if test="resetConfirmer2 != null">#{resetConfirmer2},</if>
+            <if test="resetConfirmerName2 != null">#{resetConfirmerName2},</if>
+            <if test="resetConfirmTime2 != null">#{resetConfirmTime2},</if>
+            <if test="revokeConfirm != null">#{revokeConfirm},</if>
+            <if test="remarks != null">#{remarks},</if>
+            <if test="status != null">#{status},</if>
+            <if test="delFlag != null">#{delFlag},</if>
+            <if test="createrCode != null">#{createrCode},</if>
+            <if test="createdate != null">#{createdate},</if>
+            <if test="updaterCode != null">#{updaterCode},</if>
+            <if test="updatedate != null">#{updatedate},</if>
+            <if test="deptId != null">#{deptId},</if>
+            <if test="approveStatus != null">#{approveStatus},</if>
+         </trim>
+    </insert>
+
+    <update id="updateTApplySafetychange" parameterType="TApplySafetychange">
+        update t_apply_safetychange
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="changeDescribe != null">change_describe = #{changeDescribe},</if>
+            <if test="changeReason != null">change_reason = #{changeReason},</if>
+            <if test="applicant != null">applicant = #{applicant},</if>
+            <if test="applicantName != null">applicant_name = #{applicantName},</if>
+            <if test="applicationTime != null">application_time = #{applicationTime},</if>
+            <if test="safa != null">safa = #{safa},</if>
+            <if test="safaer != null">safaer = #{safaer},</if>
+            <if test="safaerName != null">safaer_name = #{safaerName},</if>
+            <if test="safaTime != null">safa_time = #{safaTime},</if>
+            <if test="approver != null">approver = #{approver},</if>
+            <if test="approverName != null">approver_name = #{approverName},</if>
+            <if test="approveTime != null">approve_time = #{approveTime},</if>
+            <if test="executor != null">executor = #{executor},</if>
+            <if test="executorName != null">executor_name = #{executorName},</if>
+            <if test="executionTime != null">execution_time = #{executionTime},</if>
+            <if test="confirmer != null">confirmer = #{confirmer},</if>
+            <if test="confirmerName != null">confirmer_name = #{confirmerName},</if>
+            <if test="confirmTime != null">confirm_time = #{confirmTime},</if>
+            <if test="changeExecution != null">change_execution = #{changeExecution},</if>
+            <if test="changeExecutor != null">change_executor = #{changeExecutor},</if>
+            <if test="changeExecutorName != null">change_executor_name = #{changeExecutorName},</if>
+            <if test="changeExecutorTime != null">change_executor_time = #{changeExecutorTime},</if>
+            <if test="resetConfirm != null">reset_confirm = #{resetConfirm},</if>
+            <if test="resetConfirmer1 != null">reset_confirmer1 = #{resetConfirmer1},</if>
+            <if test="resetConfirmerName1 != null">reset_confirmer_name1 = #{resetConfirmerName1},</if>
+            <if test="resetConfirmTime1 != null">reset_confirm_time1 = #{resetConfirmTime1},</if>
+            <if test="resetConfirmer2 != null">reset_confirmer2 = #{resetConfirmer2},</if>
+            <if test="resetConfirmerName2 != null">reset_confirmer_name2 = #{resetConfirmerName2},</if>
+            <if test="resetConfirmTime2 != null">reset_confirm_time2 = #{resetConfirmTime2},</if>
+            <if test="revokeConfirm != null">revoke_confirm = #{revokeConfirm},</if>
+            <if test="remarks != null">remarks = #{remarks},</if>
+            <if test="status != null">status = #{status},</if>
+            <if test="delFlag != null">del_flag = #{delFlag},</if>
+            <if test="createrCode != null">creater_code = #{createrCode},</if>
+            <if test="createdate != null">createdate = #{createdate},</if>
+            <if test="updaterCode != null">updater_code = #{updaterCode},</if>
+            <if test="updatedate != null">updatedate = #{updatedate},</if>
+            <if test="deptId != null">dept_id = #{deptId},</if>
+            <if test="approveStatus != null">approve_status = #{approveStatus},</if>
+        </trim>
+        where id = #{id}
+    </update>
+
+    <update id="deleteTApplySafetychangeById" parameterType="Long">
+        update t_apply_safetychange set del_flag = 2 where id = #{id}
+    </update>
+
+    <update id="deleteTApplySafetychangeByIds" parameterType="String">
+        update t_apply_safetychange set del_flag = 2 where id in
+        <foreach item="id" collection="array" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </update>
+
+</mapper>

+ 53 - 0
ui/src/api/apply/offlinevalve.js

@@ -0,0 +1,53 @@
+import request from '@/utils/request'
+
+// 查询安全阀离线切出申请列表
+export function listOfflinevalve(query) {
+  return request({
+    url: '/apply/offlinevalve/list',
+    method: 'get',
+    params: query
+  })
+}
+
+// 查询安全阀离线切出申请详细
+export function getOfflinevalve(id) {
+  return request({
+    url: '/apply/offlinevalve/' + id,
+    method: 'get'
+  })
+}
+
+// 新增安全阀离线切出申请
+export function addOfflinevalve(data) {
+  return request({
+    url: '/apply/offlinevalve',
+    method: 'post',
+    data: data
+  })
+}
+
+// 修改安全阀离线切出申请
+export function updateOfflinevalve(data) {
+  return request({
+    url: '/apply/offlinevalve',
+    method: 'put',
+    data: data
+  })
+}
+
+// 删除安全阀离线切出申请
+export function delOfflinevalve(id) {
+  return request({
+    url: '/apply/offlinevalve/' + id,
+    method: 'delete'
+  })
+}
+
+// 导出安全阀离线切出申请
+export function exportOfflinevalve(query) {
+  return request({
+    url: '/apply/offlinevalve/export',
+    method: 'get',
+    params: query
+  })
+}

+ 53 - 0
ui/src/api/apply/safetychange.js

@@ -0,0 +1,53 @@
+import request from '@/utils/request'
+
+// 查询组织保护措施状态变更申请列表
+export function listSafetychange(query) {
+  return request({
+    url: '/apply/safetychange/list',
+    method: 'get',
+    params: query
+  })
+}
+
+// 查询组织保护措施状态变更申请详细
+export function getSafetychange(id) {
+  return request({
+    url: '/apply/safetychange/' + id,
+    method: 'get'
+  })
+}
+
+// 新增组织保护措施状态变更申请
+export function addSafetychange(data) {
+  return request({
+    url: '/apply/safetychange',
+    method: 'post',
+    data: data
+  })
+}
+
+// 修改组织保护措施状态变更申请
+export function updateSafetychange(data) {
+  return request({
+    url: '/apply/safetychange',
+    method: 'put',
+    data: data
+  })
+}
+
+// 删除组织保护措施状态变更申请
+export function delSafetychange(id) {
+  return request({
+    url: '/apply/safetychange/' + id,
+    method: 'delete'
+  })
+}
+
+// 导出组织保护措施状态变更申请
+export function exportSafetychange(query) {
+  return request({
+    url: '/apply/safetychange/export',
+    method: 'get',
+    params: query
+  })
+}

+ 7 - 0
ui/src/api/reliability/safetyvavle.js

@@ -9,6 +9,13 @@ export function listSafetyvavle(query) {
   })
 }
 
+export function allSafetyvavle() {
+  return request({
+    url: '/reliability/safetyvavle/allSafetyvavle',
+    method: 'get'
+  })
+}
+
 // 查询安全阀清单详细
 export function getSafetyvavle(id) {
   return request({

+ 722 - 0
ui/src/views/apply/offlinevalve/index.vue

@@ -0,0 +1,722 @@
+<template>
+  <div class="app-container">
+    <el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" label-width="68px">
+      <el-form-item label="安全阀位号" prop="devNo" label-width="90px">
+        <el-select v-model="queryParams.devNo" placeholder="请选择或输入安全阀位号" clearable size="small"
+                   @change="handleQuery" filterable allow-create>
+          <el-option
+            v-for="item in safetyvavleList"
+            :key="item.tagno"
+            :label="item.tagno"
+            :value="item.tagno"
+          ></el-option>
+        </el-select>
+      </el-form-item>
+      <el-form-item label="单元" prop="unit">
+        <el-select v-model="queryParams.unit" placeholder="请选择单元" clearable size="small" @change="handleQuery"
+                   filterable>
+          <el-option
+            v-for="dict in unitOptions"
+            :key="dict.dictLabel"
+            :label="dict.dictLabel"
+            :value="dict.dictLabel"
+          ></el-option>
+        </el-select>
+      </el-form-item>
+      <el-form-item label="离线原因" prop="offlineReason">
+        <el-input
+          v-model="queryParams.offlineReason"
+          placeholder="请输入离线原因"
+          clearable
+          size="small"
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="临时措施确认人" prop="confirmerName" label-width="130px">
+        <el-input
+          v-model="queryParams.confirmerName"
+          placeholder="请输入临时措施确认人"
+          clearable
+          size="small"
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item>
+        <el-button type="cyan" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
+        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
+      </el-form-item>
+    </el-form>
+
+    <el-row :gutter="10" class="mb8">
+      <el-col :span="1.5">
+        <el-button
+          type="primary"
+          icon="el-icon-plus"
+          size="mini"
+          @click="handleAdd"
+          v-hasPermi="['apply:offlinevalve:add']"
+        >新增
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="success"
+          icon="el-icon-edit"
+          size="mini"
+          :disabled="single"
+          @click="handleUpdate"
+          v-hasPermi="['apply:offlinevalve:edit']"
+        >修改
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="danger"
+          icon="el-icon-delete"
+          size="mini"
+          :disabled="multiple"
+          @click="handleDelete"
+          v-hasPermi="['apply:offlinevalve:remove']"
+        >删除
+        </el-button>
+      </el-col>
+<!--      <el-col :span="1.5">
+        <el-button
+          type="info"
+          icon="el-icon-upload2"
+          size="mini"
+          @click="handleImport"
+          v-hasPermi="['apply:offlinevalve:edit']"
+        >导入
+        </el-button>
+      </el-col>-->
+      <el-col :span="1.5">
+        <el-button
+          type="warning"
+          icon="el-icon-download"
+          size="mini"
+          @click="handleExport"
+          v-hasPermi="['apply:offlinevalve:export']"
+        >导出
+        </el-button>
+      </el-col>
+      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+    </el-row>
+
+    <el-table v-loading="loading" :data="offlinevalveList" @selection-change="handleSelectionChange"
+              :height="clientHeight" border>
+      <el-table-column type="selection" width="55" align="center" fixed="left"/>
+      <el-table-column label="安全阀位号" align="center" prop="devNo" :show-overflow-tooltip="true" width="125"
+                       fixed="left"/>
+      <el-table-column label="单元" align="center" prop="unit" :show-overflow-tooltip="true" width="85" fixed="left"/>
+      <el-table-column label="申请状态" align="center" prop="approveStatus" :show-overflow-tooltip="true" width="85"
+                       fixed="left" :formatter="approveStatusFormat"/>
+      <el-table-column label="状态" align="center" prop="status" :show-overflow-tooltip="true" width="90" fixed="left" :formatter="statusFormat"/>
+      <el-table-column label="离线原因" align="center" prop="offlineReason" :show-overflow-tooltip="true" width="185"/>
+      <el-table-column label="安全阀锁开是否拆解" align="center" prop="disassembly" :show-overflow-tooltip="true"
+                       width="185"/>
+      <el-table-column label="临时措施执行人" align="center" prop="executorName" :show-overflow-tooltip="true" width="130"/>
+      <el-table-column label="临时措施执行时间" align="center" prop="executionTime" width="140">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.executionTime, '{y}-{m}-{d} {h}:{i}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="临时措施确认人" align="center" prop="confirmerName" :show-overflow-tooltip="true"
+                       width="130"/>
+      <el-table-column label="临时措施确认时间" align="center" prop="temporaryTime" width="140">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.temporaryTime, '{y}-{m}-{d} {h}:{i}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="申请人" align="center" prop="applicantName" :show-overflow-tooltip="true" width="90"/>
+      <el-table-column label="申请时间" align="center" prop="applicationTime" width="140">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.applicationTime, '{y}-{m}-{d} {h}:{i}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="批准人" align="center" prop="approverName" :show-overflow-tooltip="true" width="90"/>
+      <el-table-column label="批准时间" align="center" prop="approveTime" width="100">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.approveTime, '{y}-{m}-{d} {h}:{i}') }}</span>
+        </template>
+      </el-table-column>
+      />
+      <el-table-column label="备注" align="center" prop="remarks" :show-overflow-tooltip="true" width="140"/>
+      <el-table-column label="操作" align="center" fixed="right" width="150" class-name="small-padding fixed-width">
+        <template slot-scope="scope">
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-document"
+            @click="openDetail(scope.row)"
+          >申请单详情
+          </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"
+    />
+
+    <!-- 添加或修改安全阀离线切出申请对话框 -->
+    <el-dialog :title="title" :visible.sync="open" width="30%" append-to-body>
+      <el-form ref="form" :model="form" :rules="rules" label-width="120px">
+        <el-form-item label="安全阀位号" prop="devNo">
+          <el-select v-model="form.devNo" placeholder="请选择或输入安全阀位号" clearable size="small" filterable
+                     allow-create style="width: 100%">
+            <el-option
+              v-for="item in safetyvavleList"
+              :key="item.tagno"
+              :label="item.tagno"
+              :value="item.tagno"
+            ></el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item label="单元" prop="unit">
+          <el-select v-model="form.unit" placeholder="请选择单元" clearable size="small" filterable style="width: 100%">
+            <el-option
+              v-for="dict in unitOptions"
+              :key="dict.dictLabel"
+              :label="dict.dictLabel"
+              :value="dict.dictLabel"
+            ></el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item label="离线原因" prop="offlineReason">
+          <el-input type="textarea" v-model="form.offlineReason" placeholder="请输入离线原因"/>
+        </el-form-item>
+        <el-form-item label="临时措施执行人" prop="executor">
+          <el-select v-model="form.executor" placeholder="请选择临时措施执行人" clearable size="small" filterable style="width: 100%" @change="getExecutorName(form.executor)">
+            <el-option
+              v-for="item in executorList"
+              :key="item.userId"
+              :label="item.nickName"
+              :value="item.userId"
+            ></el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item label="临时措施确认人" prop="confirmer">
+          <el-select v-model="form.confirmer" placeholder="请选择临时措施确认人" clearable size="small" filterable style="width: 100%" @change="getConfirmerName(form.confirmer)">
+            <el-option
+              v-for="item in confirmerList"
+              :key="item.userId"
+              :label="item.nickName"
+              :value="item.userId"
+            ></el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item label="备注" prop="remarks">
+          <el-input type="textarea" v-model="form.remarks" placeholder="请输入备注"/>
+        </el-form-item>
+      </el-form>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitForm">确 定</el-button>
+        <el-button @click="cancel">取 消</el-button>
+      </div>
+    </el-dialog>
+    <!-- 用户导入对话框 -->
+    <el-dialog :title="upload.title" :visible.sync="upload.open" width="400px" append-to-body>
+      <el-upload
+        ref="upload"
+        :limit="1"
+        accept=".xlsx, .xls"
+        :headers="upload.headers"
+        :action="upload.url + '?updateSupport=' + upload.updateSupport"
+        :disabled="upload.isUploading"
+        :on-progress="handleFileUploadProgress"
+        :on-success="handleFileSuccess"
+        :auto-upload="false"
+        drag
+      >
+        <i class="el-icon-upload"></i>
+        <div class="el-upload__text">
+          将文件拖到此处,或
+          <em>点击上传</em>
+        </div>
+        <div class="el-upload__tip" slot="tip">
+          <el-checkbox v-model="upload.updateSupport"/>
+          是否更新已经存在的用户数据
+          <el-link type="info" style="font-size:12px" @click="importTemplate">下载模板</el-link>
+        </div>
+        <div class="el-upload__tip" style="color:red" slot="tip">提示:仅允许导入“xls”或“xlsx”格式文件!</div>
+      </el-upload>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitFileForm">确 定</el-button>
+        <el-button @click="upload.open = false">取 消</el-button>
+      </div>
+    </el-dialog>
+
+    <el-dialog title="申请单详情" :visible.sync="detail.open" width="50%" append-to-body>
+      <el-descriptions :column="2" border size="medium">
+        <el-descriptions-item label="安全阀位号" :label-style="labelStyle">{{ this.detail.data.devNo }}
+        </el-descriptions-item>
+        <el-descriptions-item label="单元" :label-style="labelStyle">{{ this.detail.data.unit }}</el-descriptions-item>
+        <el-descriptions-item label="离线原因" :span="2">{{ this.detail.data.offlineReason }}</el-descriptions-item>
+        <el-descriptions-item label="状态" :label-style="labelStyle">
+          <el-tag size="small" :type="statusFlag">{{ status[this.detail.data.status] }}</el-tag>
+        </el-descriptions-item>
+        <el-descriptions-item label="申请状态">
+          <el-tag size="small" :type="approveStatusFlag">{{ approveStatus[this.detail.data.approveStatus] }}</el-tag>
+        </el-descriptions-item>
+        <el-descriptions-item label="安全评估以及临时措施执行" :span="2" :label-style="labelStyle">
+          {{ this.detail.data.safa }}
+        </el-descriptions-item>
+        <el-descriptions-item label="安全阀锁开是否拆解" :span="2" :label-style="labelStyle">
+          {{ this.detail.data.disassembly }}
+        </el-descriptions-item>
+        <el-descriptions-item label="临时措施执行人" :label-style="labelStyle">
+          {{ this.detail.data.executorName }}
+        </el-descriptions-item>
+        <el-descriptions-item label="临时措施执行时间" :label-style="labelStyle">
+          <template>
+            <span>{{ parseTime(this.detail.data.executionTime, '{y}-{m}-{d} {h}:{i}') }}</span>
+          </template>
+        </el-descriptions-item>
+        <el-descriptions-item label="临时措施确认人" :label-style="labelStyle">
+          {{ this.detail.data.confirmerName }}
+        </el-descriptions-item>
+        <el-descriptions-item label="临时措施确认时间" :label-style="labelStyle">
+          <template>
+            <span>{{ parseTime(this.detail.data.temporaryTime, '{y}-{m}-{d} {h}:{i}') }}</span>
+          </template>
+        </el-descriptions-item>
+        <el-descriptions-item label="申请人" :label-style="labelStyle">
+          {{ this.detail.data.applicantName }}
+        </el-descriptions-item>
+        <el-descriptions-item label="申请时间" :label-style="labelStyle">
+          <template>
+            <span>{{ parseTime(this.detail.data.applicationTime, '{y}-{m}-{d} {h}:{i}') }}</span>
+          </template>
+        </el-descriptions-item>
+        <el-descriptions-item label="批准人" :label-style="labelStyle">
+          {{ this.detail.data.approverName }}
+        </el-descriptions-item>
+        <el-descriptions-item label="批准时间" :label-style="labelStyle">
+          <template>
+            <span>{{ parseTime(this.detail.data.approveTime, '{y}-{m}-{d} {h}:{i}') }}</span>
+          </template>
+        </el-descriptions-item>
+        <el-descriptions-item label="离线安全阀是否已经复位" :label-style="labelStyle">
+          {{ this.detail.data.resetConfirm }}
+        </el-descriptions-item>
+        <el-descriptions-item label="离线安全阀复位后现场是否存在泄漏" :label-style="labelStyle">
+          {{ this.detail.data.leakConfirm }}
+        </el-descriptions-item>
+        <el-descriptions-item label="离线安全复位后,之前采取的安全措施是否已撤销" :label-style="labelStyle">
+          {{ this.detail.data.revokeConfirm }}
+        </el-descriptions-item>
+        <el-descriptions-item label="离线安全复位后,是否已经重新上锁" :label-style="labelStyle">
+          {{ this.detail.data.lockConfirm }}
+        </el-descriptions-item>
+        <el-descriptions-item label="确认上锁人员" :label-style="labelStyle" :span="2">
+          {{ this.detail.data.lockConfirmer1Name }} {{ this.detail.data.lockConfirmer2Name }}
+        </el-descriptions-item>
+        <el-descriptions-item label="上述信息确认人" :label-style="labelStyle">
+          {{ this.detail.data.infoConfirmerName }}
+        </el-descriptions-item>
+        <el-descriptions-item label="确认时间" :label-style="labelStyle">
+          {{ this.detail.data.confirmTime }}
+        </el-descriptions-item>
+        <el-descriptions-item label="备注" :span="2" :label-style="labelStyle">
+          {{ this.detail.data.remarks }}
+        </el-descriptions-item>
+      </el-descriptions>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import {
+  listOfflinevalve,
+  getOfflinevalve,
+  delOfflinevalve,
+  addOfflinevalve,
+  updateOfflinevalve,
+  exportOfflinevalve,
+  importTemplate
+} from "@/api/apply/offlinevalve";
+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 {allSafetyvavle} from "@/api/reliability/safetyvavle";
+import {listPostUser} from "@/api/system/user";
+
+export default {
+  name: "Offlinevalve",
+  components: {Treeselect},
+  data() {
+    return {
+      executorList:[],
+      confirmerList:[],
+      status: {0: "未完成", 1: "已完成"},
+      approveStatus: {0: "待申请", 1: "申请中", 2: "已通过", 3: "已驳回", 4: "已拒绝"},
+      statusFlag: '',
+      approveStatusFlag: '',
+      //label样式
+      labelStyle: {'width': '200px'},
+      // 遮罩层
+      loading: true,
+      // 选中数组
+      ids: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: false,
+      // 总条数
+      total: 0,
+      // 安全阀离线切出申请表格数据
+      offlinevalveList: [],
+      // 安全阀清单
+      safetyvavleList: [],
+      // 字典
+      unitOptions: [],
+      statusList: [],
+      approveStatusList: [],
+      // 弹出层标题
+      title: "",
+      // 部门树选项
+      deptOptions: undefined,
+      clientHeight: 300,
+      // 是否显示弹出层
+      open: false,
+      // 用户导入参数
+      upload: {
+        // 是否显示弹出层(用户导入)
+        open: false,
+        // 弹出层标题(用户导入)
+        title: "",
+        // 是否禁用上传
+        isUploading: false,
+        // 是否更新已经存在的用户数据
+        updateSupport: 0,
+        // 设置上传的请求头部
+        headers: {Authorization: "Bearer " + getToken()},
+        // 上传的地址
+        url: process.env.VUE_APP_BASE_API + "/apply/offlinevalve/importData"
+      },
+      // 详情对象
+      detail: {
+        open: false,
+        data: {}
+      },
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 20,
+        devNo: null,
+        unit: null,
+        offlineReason: null,
+        safa: null,
+        disassembly: null,
+        executor: null,
+        confirmer: null,
+        applicant: null,
+        applicationTime: null,
+        approver: null,
+        approveTime: null,
+        resetConfirm: null,
+        leakConfirm: null,
+        revokeConfirm: null,
+        lockConfirm: null,
+        lockConfirmer1: null,
+        lockConfirmer2: null,
+        infoConfirmer: null,
+        confirmTime: null,
+        remarks: null,
+        temporaryTime: null,
+        executionTime: null,
+        status: null,
+        createrCode: null,
+        createdate: null,
+        updaterCode: null,
+        updatedate: null,
+        deptId: null,
+        approveStatus: null,
+        lockConfirmer1Name: null,
+        lockConfirmer2Name: null,
+        infoConfirmerName: null,
+        executorName: null,
+        confirmerName: null,
+        approverName: null,
+        applicantName: null
+      },
+      // 表单参数
+      form: {},
+      // 表单校验
+      rules: {
+        devNo: [
+          {required: true, message: "请选择或输入安全阀位号", trigger: "blur"}
+        ],
+        unit: [
+          {required: true, message: "请选择单元", trigger: "blur"}
+        ],
+        offlineReason: [
+          {required: true, message: "请输入离线原因", trigger: "blur"}
+        ],
+        executor: [
+          {required: true, message: "请选择临时措施执行人", trigger: "blur"}
+        ],
+        confirmer: [
+          {required: true, message: "请选择临时措施确认人", trigger: "blur"}
+        ],
+      }
+    };
+  },
+  watch: {
+    // 根据名称筛选部门树
+    deptName(val) {
+      this.$refs.tree.filter(val);
+    }
+  },
+  created() {
+    //设置表格高度对应屏幕高度
+    this.$nextTick(() => {
+      this.clientHeight = document.body.clientHeight - 250
+    })
+    this.getList();
+    this.getTreeselect();
+    allSafetyvavle().then(res => {
+      this.safetyvavleList = res.data
+    });
+    this.getDicts("UNIT").then(response => {
+      this.unitOptions = response.data;
+    });
+    this.getDicts("apply_status").then(response => {
+      this.statusList = response.data;
+    });
+    this.getDicts("apply_approve_status").then(response => {
+      this.approveStatusList = response.data;
+    });
+    listPostUser({
+      // postCode: 'gyzj'
+    }).then(response => {
+      this.executorList = response;
+      this.confirmerList = response;
+    });
+  },
+  methods: {
+    // 字典翻译
+    statusFormat(row, column) {
+      return this.selectDictLabel(this.statusList, row.status);
+    },
+    // 字典翻译
+    approveStatusFormat(row, column) {
+      return this.selectDictLabel(this.approveStatusList, row.approveStatus);
+    },
+    getExecutorName(userId){
+      for (let item of this.executorList) {
+        if (userId===item.userId){
+          this.form.executorName=item.nickName;
+          break;
+        }
+      }
+      console.log(this.form.executorName)
+    },
+    getConfirmerName(userId){
+      for (const item of this.confirmerList) {
+        if (userId===item.userId){
+          this.form.confirmerName=item.nickName;
+          break;
+        }
+      }
+      console.log(this.form.confirmerName)
+    },
+    openDetail(row) {
+      this.statusFlag = '';
+      this.approveStatusFlag = '';
+      this.detail.open = true;
+      this.detail.data = row;
+      if (row.status === 1) {
+        this.statusFlag = 'success';
+      }
+      if (row.approveStatus === '0') {
+        this.approveStatusFlag = 'info';
+      } else if (row.approveStatus === '2') {
+        this.approveStatusFlag = 'success';
+      } else if (row.approveStatus === '3') {
+        this.approveStatusFlag = 'warning';
+      } else if (row.approveStatus === '4') {
+        this.approveStatusFlag = 'danger';
+      }
+    },
+    /** 查询安全阀离线切出申请列表 */
+    getList() {
+      this.loading = true;
+      listOfflinevalve(this.queryParams).then(response => {
+        this.offlinevalveList = response.rows;
+        this.total = response.total;
+        this.loading = false;
+      });
+    },
+    /** 查询部门下拉树结构 */
+    getTreeselect() {
+      treeselect().then(response => {
+        this.deptOptions = response.data;
+      });
+    },
+    // 取消按钮
+    cancel() {
+      this.open = false;
+      this.reset();
+    },
+    // 表单重置
+    reset() {
+      this.form = {
+        id: null,
+        devNo: null,
+        unit: null,
+        offlineReason: null,
+        safa: null,
+        disassembly: null,
+        executor: null,
+        confirmer: null,
+        applicant: null,
+        applicationTime: null,
+        approver: null,
+        approveTime: null,
+        resetConfirm: null,
+        leakConfirm: null,
+        revokeConfirm: null,
+        lockConfirm: null,
+        lockConfirmer1: null,
+        lockConfirmer2: null,
+        infoConfirmer: null,
+        confirmTime: null,
+        remarks: null,
+        temporaryTime: null,
+        executionTime: null,
+        status: 0,
+        delFlag: null,
+        createrCode: null,
+        createdate: null,
+        updaterCode: null,
+        updatedate: null,
+        deptId: null,
+        approveStatus: "0",
+        lockConfirmer1Name: null,
+        lockConfirmer2Name: null,
+        infoConfirmerName: null,
+        executorName: null,
+        confirmerName: null,
+        approverName: null,
+        applicantName: 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 = "添加安全阀离线切出申请表";
+    },
+    /** 修改按钮操作 */
+    handleUpdate(row) {
+      this.reset();
+      const id = row.id || this.ids
+      getOfflinevalve(id).then(response => {
+        this.form = response.data;
+        this.open = true;
+        this.title = "修改安全阀离线切出申请表";
+      });
+    },
+    /** 提交按钮 */
+    submitForm() {
+      this.$refs["form"].validate(valid => {
+        if (valid) {
+          if (this.form.id != null) {
+            updateOfflinevalve(this.form).then(response => {
+              this.msgSuccess("修改成功");
+              this.open = false;
+              this.getList();
+            });
+          } else {
+            addOfflinevalve(this.form).then(response => {
+              this.msgSuccess("新增成功");
+              this.open = false;
+              this.getList();
+            });
+          }
+        }
+      });
+    },
+    /** 删除按钮操作 */
+    handleDelete(row) {
+      const ids = row.id || this.ids;
+      this.$confirm('是否确认删除?', "警告", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning"
+      }).then(function () {
+        return delOfflinevalve(ids);
+      }).then(() => {
+        this.getList();
+        this.msgSuccess("删除成功");
+      })
+    },
+    /** 导出按钮操作 */
+    handleExport() {
+      const queryParams = this.queryParams;
+      this.$confirm('是否确认导出所有安全阀离线切出申请表数据项?', "警告", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning"
+      }).then(function () {
+        return exportOfflinevalve(queryParams);
+      }).then(response => {
+        this.download(response.msg);
+      })
+    },
+    /** 导入按钮操作 */
+    handleImport() {
+      this.upload.title = "用户导入";
+      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, "导入结果", {dangerouslyUseHTMLString: true});
+      this.getList();
+    },
+    // 提交上传文件
+    submitFileForm() {
+      this.$refs.upload.submit();
+    }
+  }
+};
+</script>

+ 712 - 0
ui/src/views/apply/safetychange/index.vue

@@ -0,0 +1,712 @@
+<template>
+  <div class="app-container">
+    <el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" label-width="68px">
+      <el-form-item label="组织保护措施变更描述" prop="changeDescribe" label-width="160px">
+        <el-input
+          v-model="queryParams.changeDescribe"
+          placeholder="请输入组织保护措施变更描述"
+          clearable
+          size="small"
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="安全评估人" prop="safaerName" label-width="90px">
+        <el-input
+          v-model="queryParams.safaerName"
+          placeholder="请输入安全评估人"
+          clearable
+          size="small"
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="状态" prop="status">
+        <el-select v-model="queryParams.status" placeholder="请选择状态" clearable size="small">
+          <el-option label="请选择字典生成" value=""/>
+        </el-select>
+      </el-form-item>
+      <el-form-item>
+        <el-button type="cyan" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
+        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
+      </el-form-item>
+    </el-form>
+
+    <el-row :gutter="10" class="mb8">
+      <el-col :span="1.5">
+        <el-button
+          type="primary"
+          icon="el-icon-plus"
+          size="mini"
+          @click="handleAdd"
+          v-hasPermi="['apply:safetychange:add']"
+        >新增
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="success"
+          icon="el-icon-edit"
+          size="mini"
+          :disabled="single"
+          @click="handleUpdate"
+          v-hasPermi="['apply:safetychange:edit']"
+        >修改
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="danger"
+          icon="el-icon-delete"
+          size="mini"
+          :disabled="multiple"
+          @click="handleDelete"
+          v-hasPermi="['apply:safetychange:remove']"
+        >删除
+        </el-button>
+      </el-col>
+      <!--        <el-col :span="1.5">
+                  <el-button
+                          type="info"
+                          icon="el-icon-upload2"
+                          size="mini"
+                          @click="handleImport"
+                          v-hasPermi="['apply:safetychange:edit']"
+                  >导入</el-button>
+              </el-col>-->
+      <el-col :span="1.5">
+        <el-button
+          type="warning"
+          icon="el-icon-download"
+          size="mini"
+          @click="handleExport"
+          v-hasPermi="['apply:safetychange:export']"
+        >导出
+        </el-button>
+      </el-col>
+      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+    </el-row>
+
+    <el-table v-loading="loading" :data="safetychangeList" @selection-change="handleSelectionChange"
+              :height="clientHeight" border>
+      <el-table-column type="selection" width="55" align="center"/>
+      <el-table-column label="组织保护措施变更描述" align="center" prop="changeDescribe" :show-overflow-tooltip="true"
+                       fixed="left" width="160"/>
+      <el-table-column label="状态变更的原因" align="center" prop="changeReason" :show-overflow-tooltip="true"
+                       width="160"/>
+      <el-table-column label="申请人" align="center" prop="applicantName" :show-overflow-tooltip="true" width="160"/>
+      <el-table-column label="申请时间" align="center" prop="applicationTime" width="140">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.applicationTime, '{y}-{m}-{d} {h}:{i}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="安全评估及临时的安全措施" align="center" prop="safa" :show-overflow-tooltip="true"
+                       width="190"/>
+      <el-table-column label="安全评估人" align="center" prop="safaerName" :show-overflow-tooltip="true" width="160"/>
+      <el-table-column label="安全评估时间" align="center" prop="safaTime" width="140">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.safaTime, '{y}-{m}-{d} {h}:{i}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="批准人" align="center" prop="approverName" :show-overflow-tooltip="true" width="160"/>
+      <el-table-column label="批准时间" align="center" prop="approveTime" width="140">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.approveTime, '{y}-{m}-{d} {h}:{i}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="临时安全措施执行人" align="center" prop="executorName" :show-overflow-tooltip="true"
+                       width="160"/>
+      <el-table-column label="临时安全措施执行时间" align="center" prop="executionTime" width="160">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.executionTime, '{y}-{m}-{d} {h}:{i}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="临时安全措施确认人" align="center" prop="confirmerName" :show-overflow-tooltip="true"
+                       width="160"/>
+      <el-table-column label="临时安全措施确认时间" align="center" prop="confirmTime" width="160">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.confirmTime, '{y}-{m}-{d} {h}:{i}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="组织保护措施状态变更执行" align="center" prop="changeExecution"
+                       :show-overflow-tooltip="true" width="200"/>
+      <el-table-column label="执行人" align="center" prop="changeExecutorName" :show-overflow-tooltip="true"
+                       width="160"/>
+      <el-table-column label="执行时间" align="center" prop="changeExecutorTime" width="140">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.changeExecutorTime, '{y}-{m}-{d} {h}:{i}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="备注" align="center" prop="remarks" :show-overflow-tooltip="true" width="200"/>
+      <el-table-column label="申请状态" align="center" prop="approveStatus" :show-overflow-tooltip="true" fixed="left"
+                       width="85" :formatter="approveStatusFormat"/>
+      <el-table-column label="状态" align="center" prop="status" :show-overflow-tooltip="true" fixed="left"
+                       width="85" :formatter="statusFormat"/>
+      <el-table-column label="操作" align="center" fixed="right" width="140" class-name="small-padding fixed-width">
+        <template slot-scope="scope">
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-document"
+            @click="openDetail(scope.row)"
+          >申请单详情
+          </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"
+    />
+
+    <!-- 添加或修改组织保护措施状态变更申请对话框 -->
+    <el-dialog :title="title" :visible.sync="open" width="40%" append-to-body>
+      <el-form ref="form" :model="form" :rules="rules" label-width="170px">
+        <el-form-item label="组织保护措施变更描述" prop="changeDescribe">
+          <el-input type="textarea" v-model="form.changeDescribe" placeholder="请输入组织保护措施变更描述"/>
+        </el-form-item>
+        <el-form-item label="状态变更的原因" prop="changeReason">
+          <el-input type="textarea" v-model="form.changeReason" placeholder="请输入状态变更的原因"/>
+        </el-form-item>
+        <el-form-item label="安全评估人" prop="safaer">
+          <el-select v-model="form.safaer" placeholder="请选择临时措施执行人" clearable size="small" filterable
+                     style="width: 100%" @change="getSafaerName(form.safaer)">
+            <el-option
+              v-for="item in safaerList"
+              :key="item.userId"
+              :label="item.nickName"
+              :value="item.userId"
+            ></el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item label="临时安全措施执行人" prop="executor">
+          <el-select v-model="form.executor" placeholder="请选择临时措施执行人" clearable size="small" filterable
+                     style="width: 100%" @change="getExecutorName(form.executor)">
+            <el-option
+              v-for="item in executorList"
+              :key="item.userId"
+              :label="item.nickName"
+              :value="item.userId"
+            ></el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item label="备注" prop="remarks">
+          <el-input type="textarea" v-model="form.remarks" placeholder="请输入备注"/>
+        </el-form-item>
+      </el-form>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitForm">确 定</el-button>
+        <el-button @click="cancel">取 消</el-button>
+      </div>
+    </el-dialog>
+    <!-- 用户导入对话框 -->
+    <el-dialog :title="upload.title" :visible.sync="upload.open" width="400px" append-to-body>
+      <el-upload
+        ref="upload"
+        :limit="1"
+        accept=".xlsx, .xls"
+        :headers="upload.headers"
+        :action="upload.url + '?updateSupport=' + upload.updateSupport"
+        :disabled="upload.isUploading"
+        :on-progress="handleFileUploadProgress"
+        :on-success="handleFileSuccess"
+        :auto-upload="false"
+        drag
+      >
+        <i class="el-icon-upload"></i>
+        <div class="el-upload__text">
+          将文件拖到此处,或
+          <em>点击上传</em>
+        </div>
+        <div class="el-upload__tip" slot="tip">
+          <el-checkbox v-model="upload.updateSupport"/>
+          是否更新已经存在的用户数据
+          <el-link type="info" style="font-size:12px" @click="importTemplate">下载模板</el-link>
+        </div>
+        <div class="el-upload__tip" style="color:red" slot="tip">提示:仅允许导入“xls”或“xlsx”格式文件!</div>
+      </el-upload>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitFileForm">确 定</el-button>
+        <el-button @click="upload.open = false">取 消</el-button>
+      </div>
+    </el-dialog>
+
+    <el-dialog title="申请单详情" :visible.sync="detail.open" width="50%" append-to-body>
+      <el-descriptions :column="2" border size="medium">
+        <el-descriptions-item label="组织保护措施变更播述" :span="2" :label-style="labelStyle">
+          {{ this.detail.data.changeDescribe }}
+        </el-descriptions-item>
+        <el-descriptions-item label="状态变更的原因" span="2" :label-style="labelStyle">
+          {{ this.detail.data.changeReason }}
+        </el-descriptions-item>
+        <el-descriptions-item label="申请人" :label-style="labelStyle">
+          {{ this.detail.data.applicantName }}
+        </el-descriptions-item>
+        <el-descriptions-item label="申请时间" :label-style="labelStyle">
+          <template>
+            <span>{{ parseTime(this.detail.data.applicationTime, '{y}-{m}-{d} {h}:{i}') }}</span>
+          </template>
+        </el-descriptions-item>
+        <el-descriptions-item label="状态" :label-style="labelStyle">
+          <el-tag size="small" :type="statusFlag">{{ status[this.detail.data.status] }}</el-tag>
+        </el-descriptions-item>
+        <el-descriptions-item label="申请状态">
+          <el-tag size="small" :type="approveStatusFlag">{{ approveStatus[this.detail.data.approveStatus] }}</el-tag>
+        </el-descriptions-item>
+        <el-descriptions-item label="安全评估及临时的安全措施" :span="2" :label-style="labelStyle">
+          {{ this.detail.data.safa }}
+        </el-descriptions-item>
+        <el-descriptions-item label="安全评估人" :label-style="labelStyle">
+          {{ this.detail.data.safaerName }}
+        </el-descriptions-item>
+        <el-descriptions-item label="安全评估时间" :label-style="labelStyle">
+          <template>
+            <span>{{ parseTime(this.detail.data.safaTime, '{y}-{m}-{d} {h}:{i}') }}</span>
+          </template>
+        </el-descriptions-item>
+        <el-descriptions-item label="批准人" :label-style="labelStyle">
+          {{ this.detail.data.approverName }}
+        </el-descriptions-item>
+        <el-descriptions-item label="批准时间" :label-style="labelStyle">
+          <template>
+            <span>{{ parseTime(this.detail.data.approveTime, '{y}-{m}-{d} {h}:{i}') }}</span>
+          </template>
+        </el-descriptions-item>
+        <el-descriptions-item label="临时措施执行人" :label-style="labelStyle">
+          {{ this.detail.data.executorName }}
+        </el-descriptions-item>
+        <el-descriptions-item label="临时措施执行时间" :label-style="labelStyle">
+          <template>
+            <span>{{ parseTime(this.detail.data.executionTime, '{y}-{m}-{d} {h}:{i}') }}</span>
+          </template>
+        </el-descriptions-item>
+        <el-descriptions-item label="临时措施确认人" :label-style="labelStyle">
+          {{ this.detail.data.confirmerName }}
+        </el-descriptions-item>
+        <el-descriptions-item label="临时措施确认时间" :label-style="labelStyle">
+          <template>
+            <span>{{ parseTime(this.detail.data.temporaryTime, '{y}-{m}-{d} {h}:{i}') }}</span>
+          </template>
+        </el-descriptions-item>
+        <el-descriptions-item label="组织保护措施状态变更执行" :span="2" :label-style="labelStyle">
+          {{ this.detail.data.confirmerName }}
+        </el-descriptions-item>
+        <el-descriptions-item label="执行人" :label-style="labelStyle">
+          {{ this.detail.data.changeExecutorName }}
+        </el-descriptions-item>
+        <el-descriptions-item label="执行时间" :label-style="labelStyle">
+          <template>
+            <span>{{ parseTime(this.detail.data.changeExecutorTime, '{y}-{m}-{d} {h}:{i}') }}</span>
+          </template>
+        </el-descriptions-item>
+        <el-descriptions-item label="组织保护措施是否已经恢复至变更前的状态" :span="2" :label-style="labelStyle">
+          {{ this.detail.data.resetConfirm }}
+        </el-descriptions-item>
+        <el-descriptions-item label="状态恢复,确认人1" :label-style="labelStyle">
+          {{ this.detail.data.infoConfirmerName }}
+        </el-descriptions-item>
+        <el-descriptions-item label="确认时间" :label-style="labelStyle">
+          {{ this.detail.data.confirmTime }}
+        </el-descriptions-item>
+        <el-descriptions-item label="状态恢复,确认人2" :label-style="labelStyle">
+          {{ this.detail.data.infoConfirmerName }}
+        </el-descriptions-item>
+        <el-descriptions-item label="确认时间" :label-style="labelStyle">
+          {{ this.detail.data.confirmTime }}
+        </el-descriptions-item>
+        <el-descriptions-item label="状态恢复后,之前采取的安全措施是否已撤销" :span="2" :label-style="labelStyle">
+          {{ this.detail.data.leakConfirm }}
+        </el-descriptions-item>
+        <el-descriptions-item label="备注" :span="2" :label-style="labelStyle">
+          {{ this.detail.data.remarks }}
+        </el-descriptions-item>
+      </el-descriptions>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import {
+  listSafetychange,
+  getSafetychange,
+  delSafetychange,
+  addSafetychange,
+  updateSafetychange,
+  exportSafetychange,
+  importTemplate
+} from "@/api/apply/safetychange";
+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 {listPostUser} from "@/api/system/user";
+
+export default {
+  name: "Safetychange",
+  components: {Treeselect},
+  data() {
+    return {
+      detail: {
+        open: false,
+        data: {}
+      },
+      //label样式
+      labelStyle: {'width': '200px'},
+      executorList: [],
+      safaerList: [],
+      statusFlag: '',
+      approveStatusFlag: '',
+      status: {0: "未完成", 1: "已完成"},
+      approveStatus: {0: "待申请", 1: "申请中", 2: "已通过", 3: "已驳回", 4: "已拒绝"},
+      // 字典
+      statusList: [],
+      approveStatusList: [],
+      // 遮罩层
+      loading: true,
+      // 选中数组
+      ids: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: false,
+      // 总条数
+      total: 0,
+      // 组织保护措施状态变更申请表格数据
+      safetychangeList: [],
+      // 弹出层标题
+      title: "",
+      // 部门树选项
+      deptOptions: undefined,
+      clientHeight: 300,
+      // 是否显示弹出层
+      open: false,
+      // 用户导入参数
+      upload: {
+        // 是否显示弹出层(用户导入)
+        open: false,
+        // 弹出层标题(用户导入)
+        title: "",
+        // 是否禁用上传
+        isUploading: false,
+        // 是否更新已经存在的用户数据
+        updateSupport: 0,
+        // 设置上传的请求头部
+        headers: {Authorization: "Bearer " + getToken()},
+        // 上传的地址
+        url: process.env.VUE_APP_BASE_API + "/apply/safetychange/importData"
+      },
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 20,
+        changeDescribe: null,
+        changeReason: null,
+        applicant: null,
+        applicantName: null,
+        applicationTime: null,
+        safa: null,
+        safaer: null,
+        safaerName: null,
+        safaTime: null,
+        approver: null,
+        approverName: null,
+        approveTime: null,
+        executor: null,
+        executorName: null,
+        executionTime: null,
+        confirmer: null,
+        confirmerName: null,
+        confirmTime: null,
+        changeExecution: null,
+        changeExecutor: null,
+        changeExecutorName: null,
+        changeExecutorTime: null,
+        resetConfirm: null,
+        resetConfirmer1: null,
+        resetConfirmerName1: null,
+        resetConfirmTime1: null,
+        resetConfirmer2: null,
+        resetConfirmerName2: null,
+        resetConfirmTime2: null,
+        revokeConfirm: null,
+        remarks: null,
+        status: null,
+        createrCode: null,
+        createdate: null,
+        updaterCode: null,
+        updatedate: null,
+        deptId: null,
+        approveStatus: null
+      },
+      // 表单参数
+      form: {},
+      // 表单校验
+      rules: {
+        changeDescribe: [
+          {required: true, message: "请输入组织保护措施变更描述", trigger: "blur"}
+        ],
+        changeReason: [
+          {required: true, message: "请输入状态变更的原因", trigger: "blur"}
+        ],
+        safaer: [
+          {required: true, message: "请选择安全评估人", trigger: "blur"}
+        ],
+        executor: [
+          {required: true, message: "请选择临时措施执行人", 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("apply_status").then(response => {
+      this.statusList = response.data;
+    });
+    this.getDicts("apply_approve_status").then(response => {
+      this.approveStatusList = response.data;
+    });
+    listPostUser({
+      // postCode: 'gyzj'
+    }).then(response => {
+      this.executorList = response;
+      this.safaerList = response;
+    });
+  },
+  methods: {
+    openDetail(row) {
+      this.statusFlag = '';
+      this.approveStatusFlag = '';
+      this.detail.open = true;
+      this.detail.data = row;
+      if (row.status === 1) {
+        this.statusFlag = 'success';
+      }
+      if (row.approveStatus === '0') {
+        this.approveStatusFlag = 'info';
+      } else if (row.approveStatus === '2') {
+        this.approveStatusFlag = 'success';
+      } else if (row.approveStatus === '3') {
+        this.approveStatusFlag = 'warning';
+      } else if (row.approveStatus === '4') {
+        this.approveStatusFlag = 'danger';
+      }
+    },
+    getExecutorName(userId) {
+      for (let item of this.executorList) {
+        if (userId === item.userId) {
+          this.form.executorName = item.nickName;
+          break;
+        }
+      }
+      console.log(this.form.executorName)
+    },
+    getSafaerName(userId) {
+      for (const item of this.safaerList) {
+        if (userId === item.userId) {
+          this.form.safaerName = item.nickName;
+          break;
+        }
+      }
+      console.log(this.form.safaerName)
+    },
+    // 字典翻译
+    statusFormat(row, column) {
+      return this.selectDictLabel(this.statusList, row.status);
+    },
+    // 字典翻译
+    approveStatusFormat(row, column) {
+      return this.selectDictLabel(this.approveStatusList, row.approveStatus);
+    },
+    /** 查询组织保护措施状态变更申请列表 */
+    getList() {
+      this.loading = true;
+      listSafetychange(this.queryParams).then(response => {
+        this.safetychangeList = response.rows;
+        this.total = response.total;
+        this.loading = false;
+      });
+    },
+    /** 查询部门下拉树结构 */
+    getTreeselect() {
+      treeselect().then(response => {
+        this.deptOptions = response.data;
+      });
+    },
+    // 取消按钮
+    cancel() {
+      this.open = false;
+      this.reset();
+    },
+    // 表单重置
+    reset() {
+      this.form = {
+        id: null,
+        changeDescribe: null,
+        changeReason: null,
+        applicant: null,
+        applicantName: null,
+        applicationTime: null,
+        safa: null,
+        safaer: null,
+        safaerName: null,
+        safaTime: null,
+        approver: null,
+        approverName: null,
+        approveTime: null,
+        executor: null,
+        executorName: null,
+        executionTime: null,
+        confirmer: null,
+        confirmerName: null,
+        confirmTime: null,
+        changeExecution: null,
+        changeExecutor: null,
+        changeExecutorName: null,
+        changeExecutorTime: null,
+        resetConfirm: null,
+        resetConfirmer1: null,
+        resetConfirmerName1: null,
+        resetConfirmTime1: null,
+        resetConfirmer2: null,
+        resetConfirmerName2: null,
+        resetConfirmTime2: null,
+        revokeConfirm: null,
+        remarks: null,
+        status: 0,
+        delFlag: null,
+        createrCode: null,
+        createdate: null,
+        updaterCode: null,
+        updatedate: null,
+        deptId: null,
+        approveStatus: "0"
+      };
+      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 = "添加组织保护措施状态变更申请";
+    },
+    /** 修改按钮操作 */
+    handleUpdate(row) {
+      this.reset();
+      const id = row.id || this.ids
+      getSafetychange(id).then(response => {
+        this.form = response.data;
+        this.form.safaer = parseInt(this.form.safaer);
+        this.form.executor = parseInt(this.form.executor);
+        this.open = true;
+        this.title = "修改组织保护措施状态变更申请";
+      });
+    },
+    /** 提交按钮 */
+    submitForm() {
+      this.$refs["form"].validate(valid => {
+        if (valid) {
+          if (this.form.id != null) {
+            updateSafetychange(this.form).then(response => {
+              this.msgSuccess("修改成功");
+              this.open = false;
+              this.getList();
+            });
+          } else {
+            addSafetychange(this.form).then(response => {
+              this.msgSuccess("新增成功");
+              this.open = false;
+              this.getList();
+            });
+          }
+        }
+      });
+    },
+    /** 删除按钮操作 */
+    handleDelete(row) {
+      const ids = row.id || this.ids;
+      this.$confirm('是否确认删除?', "警告", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning"
+      }).then(function () {
+        return delSafetychange(ids);
+      }).then(() => {
+        this.getList();
+        this.msgSuccess("删除成功");
+      })
+    },
+    /** 导出按钮操作 */
+    handleExport() {
+      const queryParams = this.queryParams;
+      this.$confirm('是否确认导出所有组织保护措施状态变更申请数据项?', "警告", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning"
+      }).then(function () {
+        return exportSafetychange(queryParams);
+      }).then(response => {
+        this.download(response.msg);
+      })
+    },
+    /** 导入按钮操作 */
+    handleImport() {
+      this.upload.title = "用户导入";
+      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, "导入结果", {dangerouslyUseHTMLString: true});
+      this.getList();
+    },
+    // 提交上传文件
+    submitFileForm() {
+      this.$refs.upload.submit();
+    }
+  }
+};
+</script>