ソースを参照

feat(issue): 装置问题滚动清单功能

- 新增装置问题滚动清单相关功能和接口- 修改问题清单和行动计划相关功能,改为装置问题滚动清单
- 优化数据结构和查询条件,增加年份筛选
- 修复导入模板和数据格式问题
jiangbiao 4 日 前
コミット
20611aa330
24 ファイル変更4618 行追加1364 行削除
  1. 1 1
      master/src/main/java/com/ruoyi/project/common/CommonController.java
  2. 31 62
      master/src/main/java/com/ruoyi/project/issue/controller/TPlantIssuelistController.java
  3. 21 10
      master/src/main/java/com/ruoyi/project/issue/controller/TPlantOperationlistController.java
  4. 36 5
      master/src/main/java/com/ruoyi/project/issue/domain/TPlantIssuelist.java
  5. 42 0
      master/src/main/java/com/ruoyi/project/issue/domain/TPlantOperationlist.java
  6. 14 14
      master/src/main/java/com/ruoyi/project/issue/mapper/TPlantIssuelistMapper.java
  7. 15 15
      master/src/main/java/com/ruoyi/project/issue/service/ITPlantIssuelistService.java
  8. 15 15
      master/src/main/java/com/ruoyi/project/issue/service/impl/TPlantIssuelistServiceImpl.java
  9. 9 2
      master/src/main/resources/mybatis/issue/TPlantIssuelistMapper.xml
  10. 12 1
      master/src/main/resources/mybatis/issue/TPlantOperationlistMapper.xml
  11. BIN
      master/src/main/resources/static/template/issue/OperationlistTmpl.xlsx
  12. BIN
      master/src/main/resources/static/template/issue/issuelistTmpl.xlsx
  13. BIN
      master/src/main/resources/static/word/issue/OperationlistTmpl.xlsx
  14. BIN
      master/src/main/resources/static/word/issue/issuelistTmpl.xlsx
  15. 7 7
      ui/src/api/issue/issuelist.js
  16. 791 0
      ui/src/views/issue/issuelist/bd.vue
  17. 805 0
      ui/src/views/issue/issuelist/ebsm.vue
  18. 791 0
      ui/src/views/issue/issuelist/ib.vue
  19. 34 644
      ui/src/views/issue/issuelist/index.vue
  20. 652 0
      ui/src/views/issue/operationlist/bd.vue
  21. 652 0
      ui/src/views/issue/operationlist/ebsm.vue
  22. 652 0
      ui/src/views/issue/operationlist/ib.vue
  23. 36 586
      ui/src/views/issue/operationlist/index.vue
  24. 2 2
      ui/src/views/login.vue

+ 1 - 1
master/src/main/java/com/ruoyi/project/common/CommonController.java

@@ -452,7 +452,7 @@ public class CommonController extends BaseController
             downloadname = "PSSR支(吊)架模板数据维护.xlsx";
             url = "static/template/pssr/frameModel.xlsx";
         }else if( type.equals("issuelist") ) {
-            downloadname = "问题清单和行动计划导入模板.xlsx";
+            downloadname = "装置问题滚动清单导入模板.xlsx";
             url = "static/template/issue/issuelistTmpl.xlsx";
         }else if( type.equals("operationlist") ) {
             downloadname = "工艺事件清单导入模板.xlsx";

+ 31 - 62
master/src/main/java/com/ruoyi/project/issue/controller/TPlantIssuelistController.java

@@ -35,7 +35,7 @@ import java.util.List;
 import java.util.stream.Collectors;
 
 /**
- * 问题清单和行动计划Controller
+ * 装置问题滚动清单Controller
  *
  * @author ssy
  * @date 2025-08-20
@@ -47,7 +47,7 @@ public class TPlantIssuelistController extends BaseController {
     private ITPlantIssuelistService tPlantIssuelistService;
 
     /**
-     * 查询问题清单和行动计划列表
+     * 查询装置问题滚动清单列表
      */
     @PreAuthorize("@ss.hasPermi('issue:issuelist:list')")
     @GetMapping("/list")
@@ -58,10 +58,10 @@ public class TPlantIssuelistController extends BaseController {
     }
 
     /**
-     * 导出问题清单和行动计划列表
+     * 导出装置问题滚动清单列表
      */
     @PreAuthorize("@ss.hasPermi('issue:issuelist:export')")
-    @Log(title = "问题清单和行动计划", businessType = BusinessType.EXPORT)
+    @Log(title = "装置问题滚动清单", businessType = BusinessType.EXPORT)
     @GetMapping("/export")
     public AjaxResult export(TPlantIssuelist tPlantIssuelist) {
         List<TPlantIssuelist> list = tPlantIssuelistService.selectTPlantIssuelistList(tPlantIssuelist);
@@ -76,13 +76,6 @@ public class TPlantIssuelistController extends BaseController {
         OutputStream out;
         String filename = null;
         try {
-            List<TPlantIssuelist> bdList = list.stream()
-                    .filter(item -> "BD".equals(item.getPlant()))
-                    .collect(Collectors.toList());
-
-            List<TPlantIssuelist> ibList = list.stream()
-                    .filter(item -> "IB".equals(item.getPlant()))
-                    .collect(Collectors.toList());
             String tempUrl = "static/word/issue/issuelistTmpl.xlsx"; // 模板文件
             InputStream is;
             is = Thread.currentThread().getContextClassLoader().getResourceAsStream(tempUrl);
@@ -97,8 +90,14 @@ public class TPlantIssuelistController extends BaseController {
             Cell originalcell1 = originalRow1.getCell(0);
             // 获取单元格样式
             CellStyle originalStyle1 = originalcell1.getCellStyle();
+            if (!list.isEmpty()) {
+                Row line1 = sheet1.getRow(0);
+                line1.getCell(4).setCellValue(list.get(0).getPlant()+
+                        " Plant issue identified rolling list and action fowards plan\n"
+                        +list.get(0).getPlant()+"装置滚动问题清单和行动计划");
+            }
 
-            for (TPlantIssuelist t : bdList) {
+            for (TPlantIssuelist t : list) {
                 Row row = sheet1.createRow(rowIndex1);
                 row.setHeight((short) 800);
                 row.createCell(0).setCellValue(num1);
@@ -111,8 +110,8 @@ public class TPlantIssuelistController extends BaseController {
                 row.createCell(7).setCellValue(t.getResponsiblePerson());
                 row.createCell(8).setCellValue(t.getResponsibleUnit());
                 row.createCell(9).setCellValue(t.getCurrentStates());
-                row.createCell(10).setCellValue(t.getCompletionDate());
-                row.createCell(11).setCellValue(t.getAdditionalDeadline());
+                row.createCell(10).setCellValue(DateUtils.dateTime(t.getExpectedDate()));
+                row.createCell(11).setCellValue(DateUtils.dateTime(t.getCompletionDate()));
 
 
                 //渲染样式
@@ -122,43 +121,7 @@ public class TPlantIssuelistController extends BaseController {
                 num1++;
                 rowIndex1++;
             }
-
-            XSSFSheet sheet2 = wb.getSheetAt(1);
-
-            //填充数据
-            int rowIndex2 = 7;
-            int num2 = 1;
-
-            Row originalRow2 = sheet2.getRow(7);
-            Cell originalcell2 = originalRow2.getCell(0);
-            // 获取单元格样式
-            CellStyle originalStyle2 = originalcell2.getCellStyle();
-
-            for (TPlantIssuelist t : ibList) {
-                Row row = sheet2.createRow(rowIndex2);
-                row.setHeight((short) 800);
-                row.createCell(0).setCellValue(num2);
-                row.createCell(1).setCellValue(t.getArea());
-                row.createCell(2).setCellValue(DateUtils.dateTime(t.getIdentifiedDate()));
-                row.createCell(3).setCellValue(t.getIssueSource());
-                row.createCell(4).setCellValue(t.getIssueIdentified());
-                row.createCell(5).setCellValue(t.getActionsTaken());
-                row.createCell(6).setCellValue(t.getIssueClass());
-                row.createCell(7).setCellValue(t.getResponsiblePerson());
-                row.createCell(8).setCellValue(t.getResponsibleUnit());
-                row.createCell(9).setCellValue(t.getCurrentStates());
-                row.createCell(10).setCellValue(t.getCompletionDate());
-                row.createCell(11).setCellValue(t.getAdditionalDeadline());
-
-
-                //渲染样式
-                for (int i = 0; i < 12; i++) {
-                    row.getCell(i).setCellStyle(originalStyle2);
-                }
-                num2++;
-                rowIndex2++;
-            }
-            filename = "滚动问题清单和行动计划" + DateUtils.dateTimeNow() + ".xlsx";
+            filename = "装置问题滚动清单" + DateUtils.dateTimeNow() + ".xlsx";
             out = Files.newOutputStream(Paths.get(ExcelUtil.getAbsoluteFile(filename)));
             wb.write(out);
             wb.close();
@@ -170,7 +133,7 @@ public class TPlantIssuelistController extends BaseController {
     }
 
     /**
-     * 获取问题清单和行动计划详细信息
+     * 获取装置问题滚动清单详细信息
      */
     @PreAuthorize("@ss.hasPermi('issue:issuelist:query')")
     @GetMapping(value = "/{id}")
@@ -179,37 +142,41 @@ public class TPlantIssuelistController extends BaseController {
     }
 
     /**
-     * 新增问题清单和行动计划
+     * 新增装置问题滚动清单
      */
     @PreAuthorize("@ss.hasPermi('issue:issuelist:add')")
-    @Log(title = "问题清单和行动计划", businessType = BusinessType.INSERT)
+    @Log(title = "装置问题滚动清单", businessType = BusinessType.INSERT)
     @PostMapping
     public AjaxResult add(@RequestBody TPlantIssuelist tPlantIssuelist) {
+        tPlantIssuelist.setCreaterCode(getUserId().toString());
+        tPlantIssuelist.setCreatedate(new Date());
         return toAjax(tPlantIssuelistService.insertTPlantIssuelist(tPlantIssuelist));
     }
 
     /**
-     * 修改问题清单和行动计划
+     * 修改装置问题滚动清单
      */
     @PreAuthorize("@ss.hasPermi('issue:issuelist:edit')")
-    @Log(title = "问题清单和行动计划", businessType = BusinessType.UPDATE)
+    @Log(title = "装置问题滚动清单", businessType = BusinessType.UPDATE)
     @PutMapping
     public AjaxResult edit(@RequestBody TPlantIssuelist tPlantIssuelist) {
+        tPlantIssuelist.setUpdaterCode(getUserId().toString());
+        tPlantIssuelist.setUpdatedate(new Date());
         return toAjax(tPlantIssuelistService.updateTPlantIssuelist(tPlantIssuelist));
     }
 
     /**
-     * 删除问题清单和行动计划
+     * 删除装置问题滚动清单
      */
     @PreAuthorize("@ss.hasPermi('issue:issuelist:remove')")
-    @Log(title = "问题清单和行动计划", businessType = BusinessType.DELETE)
+    @Log(title = "装置问题滚动清单", businessType = BusinessType.DELETE)
     @DeleteMapping("/{ids}")
     public AjaxResult remove(@PathVariable Long[] ids) {
         return toAjax(tPlantIssuelistService.deleteTPlantIssuelistByIds(ids));
     }
 
     @PreAuthorize("@ss.hasPermi('issue:issuelist:add')")
-    @Log(title = "问题清单和行动计划", businessType = BusinessType.INSERT)
+    @Log(title = "装置问题滚动清单", businessType = BusinessType.INSERT)
     @PostMapping("/importData")
     public AjaxResult importData(@RequestParam("file") MultipartFile file) throws IOException {
         //获取操作人员ID
@@ -239,7 +206,7 @@ public class TPlantIssuelistController extends BaseController {
                     } else if (j == 1) {
                         entity.setArea(cellValue);
                     } else if (j == 2) {
-                        entity.setIdentifiedDate(DateUtils.parseDate(cellValue));//员工姓名
+                        entity.setIdentifiedDate(DateUtils.parseDate(cellValue));
                     } else if (j == 3) {
                         entity.setIssueSource(cellValue);
                     } else if (j == 4) {
@@ -255,8 +222,10 @@ public class TPlantIssuelistController extends BaseController {
                     } else if (j == 9) {
                         entity.setCurrentStates(cellValue);
                     } else if (j == 10) {
-                        entity.setCompletionDate(cellValue);
-                    } else if (j == 11) {
+                        entity.setExpectedDate(DateUtils.parseDate(cellValue));
+                    }else if (j == 11) {
+                        entity.setCompletionDate(DateUtils.parseDate(cellValue));
+                    } else if (j == 12) {
                         entity.setAdditionalDeadline(cellValue);
                     }
                 }

+ 21 - 10
master/src/main/java/com/ruoyi/project/issue/controller/TPlantOperationlistController.java

@@ -25,6 +25,7 @@ import java.io.OutputStream;
 import java.nio.file.Files;
 import java.nio.file.Paths;
 import java.util.ArrayList;
+import java.util.Date;
 import java.util.List;
 
 /**
@@ -88,15 +89,17 @@ public class TPlantOperationlistController extends BaseController {
                 Row row = sheet1.createRow(rowIndex1);
                 row.setHeight((short) 800);
                 row.createCell(0).setCellValue(num1);
-                row.createCell(1).setCellValue(t.getPlant());
-                row.createCell(2).setCellValue(t.getShiftClass());
-                row.createCell(3).setCellValue(t.getIncidentDescription());
-                row.createCell(4).setCellValue(t.getCauseRes());
-                row.createCell(5).setCellValue(t.getCoutermeasures());
+                row.createCell(1).setCellValue(t.getIdentifiedDate());
+                row.createCell(2).setCellValue(t.getPlant());
+                row.createCell(3).setCellValue(t.getShiftClass());
+                row.createCell(4).setCellValue(t.getIncidentType());
+                row.createCell(5).setCellValue(t.getIncidentDescription());
+                row.createCell(6).setCellValue(t.getCauseRes());
+                row.createCell(7).setCellValue(t.getCoutermeasures());
 
 
                 //渲染样式
-                for (int i = 0; i < 6; i++) {
+                for (int i = 0; i < 8; i++) {
                     row.getCell(i).setCellStyle(originalStyle1);
                 }
                 num1++;
@@ -129,6 +132,8 @@ public class TPlantOperationlistController extends BaseController {
     @Log(title = "CBPB工艺事件清单", businessType = BusinessType.INSERT)
     @PostMapping
     public AjaxResult add(@RequestBody TPlantOperationlist tPlantOperationlist) {
+        tPlantOperationlist.setCreatedate(new Date());
+        tPlantOperationlist.setCreaterCode(getUserId().toString());
         return toAjax(tPlantOperationlistService.insertTPlantOperationlist(tPlantOperationlist));
     }
 
@@ -139,6 +144,8 @@ public class TPlantOperationlistController extends BaseController {
     @Log(title = "CBPB工艺事件清单", businessType = BusinessType.UPDATE)
     @PutMapping
     public AjaxResult edit(@RequestBody TPlantOperationlist tPlantOperationlist) {
+        tPlantOperationlist.setUpdatedate(new Date());
+        tPlantOperationlist.setUpdaterCode(getUserId().toString());
         return toAjax(tPlantOperationlistService.updateTPlantOperationlist(tPlantOperationlist));
     }
 
@@ -180,13 +187,17 @@ public class TPlantOperationlistController extends BaseController {
                     logger.info("cellValue:" + cellValue);
                     if (j == 0) {
                         entity.setPlant(cellValue);
-                    } else if (j == 1) {
-                        entity.setShiftClass(cellValue);
+                    }else if (j == 1) {
+                        entity.setIdentifiedDate(DateUtils.parseDate(cellValue));
                     } else if (j == 2) {
+                        entity.setShiftClass(cellValue);
+                    }else if (j == 3) {
+                        entity.setIncidentType(cellValue);
+                    } else if (j == 4) {
                         entity.setIncidentDescription(cellValue);
-                    } else if (j == 3) {
+                    } else if (j == 5) {
                         entity.setCauseRes(cellValue);
-                    } else if (j == 4) {
+                    } else if (j == 6) {
                         entity.setCoutermeasures(cellValue);
                     }
                 }

+ 36 - 5
master/src/main/java/com/ruoyi/project/issue/domain/TPlantIssuelist.java

@@ -8,7 +8,7 @@ import org.apache.commons.lang3.builder.ToStringBuilder;
 import org.apache.commons.lang3.builder.ToStringStyle;
 
 /**
- * 问题清单和行动计划对象 t_plant_issuelist
+ * 装置问题滚动清单对象 t_plant_issuelist
  *
  * @author ssy
  * @date 2025-08-20
@@ -32,6 +32,7 @@ public class TPlantIssuelist extends BaseEntity
     @JsonFormat(pattern = "yyyy-MM-dd" , timezone = "GMT+8")
     @Excel(name = "提出日期", width = 30, dateFormat = "yyyy-MM-dd")
     private Date identifiedDate;
+    private String identifiedDateStr;
 
     /** 问题来源 */
     @Excel(name = "问题来源")
@@ -59,8 +60,13 @@ public class TPlantIssuelist extends BaseEntity
     private String currentStates;
 
     /** 完成日期 */
-    @Excel(name = "完成日期")
-    private String completionDate;
+    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
+    @Excel(name = "实际完成日期", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date completionDate;
+
+    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
+    @Excel(name = "预计完成日期", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date expectedDate;
 
     /** 未按期完成时,所要采取的额外(临时)安全措施 */
     @Excel(name = "未按期完成时,所要采取的额外", readConverterExp = "临=时")
@@ -94,6 +100,31 @@ public class TPlantIssuelist extends BaseEntity
     /** 备注 */
     @Excel(name = "备注")
     private String remarks;
+    private String deptName;
+
+    public Date getExpectedDate() {
+        return expectedDate;
+    }
+
+    public void setExpectedDate(Date expectedDate) {
+        this.expectedDate = expectedDate;
+    }
+
+    public String getIdentifiedDateStr() {
+        return identifiedDateStr;
+    }
+
+    public void setIdentifiedDateStr(String identifiedDateStr) {
+        this.identifiedDateStr = identifiedDateStr;
+    }
+
+    public String getDeptName() {
+        return deptName;
+    }
+
+    public void setDeptName(String deptName) {
+        this.deptName = deptName;
+    }
 
     public void setId(Long id)
     {
@@ -185,12 +216,12 @@ public class TPlantIssuelist extends BaseEntity
     {
         return currentStates;
     }
-    public void setCompletionDate(String completionDate)
+    public void setCompletionDate(Date completionDate)
     {
         this.completionDate = completionDate;
     }
 
-    public String getCompletionDate()
+    public Date getCompletionDate()
     {
         return completionDate;
     }

+ 42 - 0
master/src/main/java/com/ruoyi/project/issue/domain/TPlantOperationlist.java

@@ -20,6 +20,10 @@ public class TPlantOperationlist extends BaseEntity
     /** ID */
     private Long id;
 
+    /**时间*/
+    private Date identifiedDate;
+    private String identifiedDateStr;
+
     /** 装置 */
     @Excel(name = "装置")
     private String plant;
@@ -28,6 +32,10 @@ public class TPlantOperationlist extends BaseEntity
     @Excel(name = "班组")
     private String shiftClass;
 
+
+    /** 事件分类*/
+    private String incidentType;
+
     /** 事件描述 */
     @Excel(name = "事件描述")
     private String incidentDescription;
@@ -68,6 +76,40 @@ public class TPlantOperationlist extends BaseEntity
     /** 备注 */
     @Excel(name = "备注")
     private String remarks;
+    private String deptName;
+
+    public String getIdentifiedDateStr() {
+        return identifiedDateStr;
+    }
+
+    public void setIdentifiedDateStr(String identifiedDateStr) {
+        this.identifiedDateStr = identifiedDateStr;
+    }
+
+    public Date getIdentifiedDate() {
+        return identifiedDate;
+    }
+
+    public void setIdentifiedDate(Date identifiedDate) {
+        this.identifiedDate = identifiedDate;
+    }
+
+    public String getIncidentType() {
+        return incidentType;
+    }
+
+    public void setIncidentType(String incidentType) {
+        this.incidentType = incidentType;
+    }
+
+    public String getDeptName() {
+        return deptName;
+    }
+
+    public void setDeptName(String deptName) {
+        this.deptName = deptName;
+    }
+
 
     public void setId(Long id)
     {

+ 14 - 14
master/src/main/java/com/ruoyi/project/issue/mapper/TPlantIssuelistMapper.java

@@ -5,7 +5,7 @@ import com.ruoyi.framework.aspectj.lang.annotation.DataScope;
 import com.ruoyi.project.issue.domain.TPlantIssuelist;
 
 /**
- * 问题清单和行动计划Mapper接口
+ * 装置问题滚动清单Mapper接口
  * 
  * @author ssy
  * @date 2025-08-20
@@ -13,48 +13,48 @@ import com.ruoyi.project.issue.domain.TPlantIssuelist;
 public interface TPlantIssuelistMapper 
 {
     /**
-     * 查询问题清单和行动计划
+     * 查询装置问题滚动清单
      * 
-     * @param id 问题清单和行动计划ID
-     * @return 问题清单和行动计划
+     * @param id 装置问题滚动清单ID
+     * @return 装置问题滚动清单
      */
     public TPlantIssuelist selectTPlantIssuelistById(Long id);
 
     /**
-     * 查询问题清单和行动计划列表
+     * 查询装置问题滚动清单列表
      * 
-     * @param tPlantIssuelist 问题清单和行动计划
-     * @return 问题清单和行动计划集合
+     * @param tPlantIssuelist 装置问题滚动清单
+     * @return 装置问题滚动清单集合
      */
     @DataScope(deptAlias = "d")
     public List<TPlantIssuelist> selectTPlantIssuelistList(TPlantIssuelist tPlantIssuelist);
 
     /**
-     * 新增问题清单和行动计划
+     * 新增装置问题滚动清单
      * 
-     * @param tPlantIssuelist 问题清单和行动计划
+     * @param tPlantIssuelist 装置问题滚动清单
      * @return 结果
      */
     public int insertTPlantIssuelist(TPlantIssuelist tPlantIssuelist);
 
     /**
-     * 修改问题清单和行动计划
+     * 修改装置问题滚动清单
      * 
-     * @param tPlantIssuelist 问题清单和行动计划
+     * @param tPlantIssuelist 装置问题滚动清单
      * @return 结果
      */
     public int updateTPlantIssuelist(TPlantIssuelist tPlantIssuelist);
 
     /**
-     * 删除问题清单和行动计划
+     * 删除装置问题滚动清单
      * 
-     * @param id 问题清单和行动计划ID
+     * @param id 装置问题滚动清单ID
      * @return 结果
      */
     public int deleteTPlantIssuelistById(Long id);
 
     /**
-     * 批量删除问题清单和行动计划
+     * 批量删除装置问题滚动清单
      * 
      * @param ids 需要删除的数据ID
      * @return 结果

+ 15 - 15
master/src/main/java/com/ruoyi/project/issue/service/ITPlantIssuelistService.java

@@ -4,7 +4,7 @@ import java.util.List;
 import com.ruoyi.project.issue.domain.TPlantIssuelist;
 
 /**
- * 问题清单和行动计划Service接口
+ * 装置问题滚动清单Service接口
  * 
  * @author ssy
  * @date 2025-08-20
@@ -12,49 +12,49 @@ import com.ruoyi.project.issue.domain.TPlantIssuelist;
 public interface ITPlantIssuelistService 
 {
     /**
-     * 查询问题清单和行动计划
+     * 查询装置问题滚动清单
      * 
-     * @param id 问题清单和行动计划ID
-     * @return 问题清单和行动计划
+     * @param id 装置问题滚动清单ID
+     * @return 装置问题滚动清单
      */
     public TPlantIssuelist selectTPlantIssuelistById(Long id);
 
     /**
-     * 查询问题清单和行动计划列表
+     * 查询装置问题滚动清单列表
      * 
-     * @param tPlantIssuelist 问题清单和行动计划
-     * @return 问题清单和行动计划集合
+     * @param tPlantIssuelist 装置问题滚动清单
+     * @return 装置问题滚动清单集合
      */
     public List<TPlantIssuelist> selectTPlantIssuelistList(TPlantIssuelist tPlantIssuelist);
 
     /**
-     * 新增问题清单和行动计划
+     * 新增装置问题滚动清单
      * 
-     * @param tPlantIssuelist 问题清单和行动计划
+     * @param tPlantIssuelist 装置问题滚动清单
      * @return 结果
      */
     public int insertTPlantIssuelist(TPlantIssuelist tPlantIssuelist);
 
     /**
-     * 修改问题清单和行动计划
+     * 修改装置问题滚动清单
      * 
-     * @param tPlantIssuelist 问题清单和行动计划
+     * @param tPlantIssuelist 装置问题滚动清单
      * @return 结果
      */
     public int updateTPlantIssuelist(TPlantIssuelist tPlantIssuelist);
 
     /**
-     * 批量删除问题清单和行动计划
+     * 批量删除装置问题滚动清单
      * 
-     * @param ids 需要删除的问题清单和行动计划ID
+     * @param ids 需要删除的装置问题滚动清单ID
      * @return 结果
      */
     public int deleteTPlantIssuelistByIds(Long[] ids);
 
     /**
-     * 删除问题清单和行动计划信息
+     * 删除装置问题滚动清单信息
      * 
-     * @param id 问题清单和行动计划ID
+     * @param id 装置问题滚动清单ID
      * @return 结果
      */
     public int deleteTPlantIssuelistById(Long id);

+ 15 - 15
master/src/main/java/com/ruoyi/project/issue/service/impl/TPlantIssuelistServiceImpl.java

@@ -8,7 +8,7 @@ import com.ruoyi.project.issue.domain.TPlantIssuelist;
 import com.ruoyi.project.issue.service.ITPlantIssuelistService;
 
 /**
- * 问题清单和行动计划Service业务层处理
+ * 装置问题滚动清单Service业务层处理
  *
  * @author ssy
  * @date 2025-08-20
@@ -20,10 +20,10 @@ public class TPlantIssuelistServiceImpl implements ITPlantIssuelistService
     private TPlantIssuelistMapper tPlantIssuelistMapper;
 
     /**
-     * 查询问题清单和行动计划
+     * 查询装置问题滚动清单
      *
-     * @param id 问题清单和行动计划ID
-     * @return 问题清单和行动计划
+     * @param id 装置问题滚动清单ID
+     * @return 装置问题滚动清单
      */
     @Override
     public TPlantIssuelist selectTPlantIssuelistById(Long id)
@@ -32,10 +32,10 @@ public class TPlantIssuelistServiceImpl implements ITPlantIssuelistService
     }
 
     /**
-     * 查询问题清单和行动计划列表
+     * 查询装置问题滚动清单列表
      *
-     * @param tPlantIssuelist 问题清单和行动计划
-     * @return 问题清单和行动计划
+     * @param tPlantIssuelist 装置问题滚动清单
+     * @return 装置问题滚动清单
      */
     @Override
     public List<TPlantIssuelist> selectTPlantIssuelistList(TPlantIssuelist tPlantIssuelist)
@@ -44,9 +44,9 @@ public class TPlantIssuelistServiceImpl implements ITPlantIssuelistService
     }
 
     /**
-     * 新增问题清单和行动计划
+     * 新增装置问题滚动清单
      *
-     * @param tPlantIssuelist 问题清单和行动计划
+     * @param tPlantIssuelist 装置问题滚动清单
      * @return 结果
      */
     @Override
@@ -56,9 +56,9 @@ public class TPlantIssuelistServiceImpl implements ITPlantIssuelistService
     }
 
     /**
-     * 修改问题清单和行动计划
+     * 修改装置问题滚动清单
      *
-     * @param tPlantIssuelist 问题清单和行动计划
+     * @param tPlantIssuelist 装置问题滚动清单
      * @return 结果
      */
     @Override
@@ -68,9 +68,9 @@ public class TPlantIssuelistServiceImpl implements ITPlantIssuelistService
     }
 
     /**
-     * 批量删除问题清单和行动计划
+     * 批量删除装置问题滚动清单
      *
-     * @param ids 需要删除的问题清单和行动计划ID
+     * @param ids 需要删除的装置问题滚动清单ID
      * @return 结果
      */
     @Override
@@ -80,9 +80,9 @@ public class TPlantIssuelistServiceImpl implements ITPlantIssuelistService
     }
 
     /**
-     * 删除问题清单和行动计划信息
+     * 删除装置问题滚动清单信息
      *
-     * @param id 问题清单和行动计划ID
+     * @param id 装置问题滚动清单ID
      * @return 结果
      */
     @Override

+ 9 - 2
master/src/main/resources/mybatis/issue/TPlantIssuelistMapper.xml

@@ -17,6 +17,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         <result property="responsibleUnit"    column="responsible_unit"    />
         <result property="currentStates"    column="current_states"    />
         <result property="completionDate"    column="completion_date"    />
+        <result property="expectedDate"    column="expected_date"    />
         <result property="additionalDeadline"    column="additional_deadline"    />
         <result property="delFlag"    column="del_flag"    />
         <result property="createrCode"    column="creater_code"    />
@@ -29,7 +30,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
     </resultMap>
 
     <sql id="selectTPlantIssuelistVo">
-        select d.id, d.plant, d.area, d.identified_date, d.issue_source, d.issue_identified, d.actions_taken, d.issue_class, d.responsible_person,d.responsible_unit, d.current_states, d.completion_date, d.additional_deadline, d.del_flag, d.creater_code, d.createdate, d.updater_code, d.updatedate, d.dept_id, d.remarks ,s.dept_name from t_plant_issuelist d
+        select d.id, d.plant, d.area, d.identified_date, d.issue_source, d.issue_identified, d.actions_taken, d.issue_class, d.responsible_person,d.responsible_unit, d.current_states, d.completion_date, d.expected_date, d.additional_deadline, d.del_flag, d.creater_code, d.createdate, d.updater_code, d.updatedate, d.dept_id, d.remarks ,s.dept_name from t_plant_issuelist d
       left join sys_dept s on s.dept_id = d.dept_id
     </sql>
 
@@ -39,13 +40,15 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="plant != null  and plant != ''"> and plant = #{plant}</if>
             <if test="area != null  and area != ''"> and area = #{area}</if>
             <if test="identifiedDate != null "> and identified_date = #{identifiedDate}</if>
+            <if test="identifiedDateStr != null "> and to_char(identified_date,'YYYY') = #{identifiedDateStr}</if>
             <if test="issueSource != null  and issueSource != ''"> and issue_source = #{issueSource}</if>
-            <if test="issueIdentified != null  and issueIdentified != ''"> and issue_identified = #{issueIdentified}</if>
+            <if test="issueIdentified != null  and issueIdentified != ''"> and issue_identified like concat('%',concat(#{issueIdentified},'%'))</if>
             <if test="actionsTaken != null  and actionsTaken != ''"> and actions_taken = #{actionsTaken}</if>
             <if test="issueClass != null  and issueClass != ''"> and issue_class = #{issueClass}</if>
             <if test="responsiblePerson != null  and responsiblePerson != ''"> and responsible_person = #{responsiblePerson}</if>
             <if test="responsibleUnit != null  and responsibleUnit != ''"> and responsible_unit = #{responsibleUnit}</if>
             <if test="currentStates != null  and currentStates != ''"> and current_states = #{currentStates}</if>
+            <if test="expectedDate != null  and expectedDate != ''"> and expected_date = #{expectedDate}</if>
             <if test="completionDate != null  and completionDate != ''"> and completion_date = #{completionDate}</if>
             <if test="additionalDeadline != null  and additionalDeadline != ''"> and additional_deadline = #{additionalDeadline}</if>
             <if test="createrCode != null  and createrCode != ''"> and creater_code = #{createrCode}</if>
@@ -56,6 +59,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="remarks != null  and remarks != ''"> and remarks = #{remarks}</if>
             and d.del_flag = 0
         </where>
+        order by createdate desc
         <!-- 数据范围过滤 -->
         ${params.dataScope}
     </select>
@@ -83,6 +87,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="responsibleUnit != null">responsible_unit,</if>
             <if test="currentStates != null">current_states,</if>
             <if test="completionDate != null">completion_date,</if>
+            <if test="expectedDate != null">expected_date,</if>
             <if test="additionalDeadline != null">additional_deadline,</if>
             <if test="delFlag != null">del_flag,</if>
             <if test="createrCode != null">creater_code,</if>
@@ -105,6 +110,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="responsibleUnit != null">#{responsibleUnit},</if>
             <if test="currentStates != null">#{currentStates},</if>
             <if test="completionDate != null">#{completionDate},</if>
+            <if test="expectedDate != null">#{expectedDate},</if>
             <if test="additionalDeadline != null">#{additionalDeadline},</if>
             <if test="delFlag != null">#{delFlag},</if>
             <if test="createrCode != null">#{createrCode},</if>
@@ -130,6 +136,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="responsibleUnit != null">responsible_unit = #{responsibleUnit},</if>
             <if test="currentStates != null">current_states = #{currentStates},</if>
             <if test="completionDate != null">completion_date = #{completionDate},</if>
+            <if test="expectedDate != null">expected_date = #{expectedDate},</if>
             <if test="additionalDeadline != null">additional_deadline = #{additionalDeadline},</if>
             <if test="delFlag != null">del_flag = #{delFlag},</if>
             <if test="createrCode != null">creater_code = #{createrCode},</if>

+ 12 - 1
master/src/main/resources/mybatis/issue/TPlantOperationlistMapper.xml

@@ -19,19 +19,23 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         <result property="deptId"    column="dept_id"    />
         <result property="remarks"    column="remarks"    />
         <result property="deptName" column="dept_name" />
+        <result property="incidentType" column="incident_type" />
+        <result property="identifiedDate" column="identified_date" />
     </resultMap>
 
     <sql id="selectTPlantOperationlistVo">
-        select d.id, d.plant, d.shift_class, d.incident_description, d.cause_res, d.coutermeasures, d.del_flag, d.creater_code, d.createdate, d.updater_code, d.updatedate, d.dept_id, d.remarks ,s.dept_name from t_plant_operationlist d
+        select d.id, d.identified_date, d.plant, d.shift_class, d.incident_description, d.incident_type, d.cause_res, d.coutermeasures, d.del_flag, d.creater_code, d.createdate, d.updater_code, d.updatedate, d.dept_id, d.remarks ,s.dept_name from t_plant_operationlist d
       left join sys_dept s on s.dept_id = d.dept_id
     </sql>
 
     <select id="selectTPlantOperationlistList" parameterType="TPlantOperationlist" resultMap="TPlantOperationlistResult">
         <include refid="selectTPlantOperationlistVo"/>
         <where>  
+            <if test="identifiedDate != null  and identifiedDate != ''"> and identified_date = #{plant}</if>
             <if test="plant != null  and plant != ''"> and plant = #{plant}</if>
             <if test="shiftClass != null  and shiftClass != ''"> and shift_class = #{shiftClass}</if>
             <if test="incidentDescription != null  and incidentDescription != ''"> and incident_description = #{incidentDescription}</if>
+            <if test="incidentType != null  and incidentType != ''"> and incident_type = #{incidentType}</if>
             <if test="causeRes != null  and causeRes != ''"> and cause_res = #{causeRes}</if>
             <if test="coutermeasures != null  and coutermeasures != ''"> and coutermeasures = #{coutermeasures}</if>
             <if test="createrCode != null  and createrCode != ''"> and creater_code = #{createrCode}</if>
@@ -58,8 +62,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
         insert into t_plant_operationlist
         <trim prefix="(" suffix=")" suffixOverrides=",">
             <if test="id != null">id,</if>
+            <if test="identifiedDate != null">identified_date,</if>
             <if test="plant != null">plant,</if>
             <if test="shiftClass != null">shift_class,</if>
+            <if test="incidentType != null">incident_type,</if>
             <if test="incidentDescription != null">incident_description,</if>
             <if test="causeRes != null">cause_res,</if>
             <if test="coutermeasures != null">coutermeasures,</if>
@@ -73,8 +79,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
          </trim>
         <trim prefix="values (" suffix=")" suffixOverrides=",">
             <if test="id != null">#{id},</if>
+            <if test="identifiedDate != null">#{identifiedDate},</if>
             <if test="plant != null">#{plant},</if>
             <if test="shiftClass != null">#{shiftClass},</if>
+            <if test="incidentType != null">#{incidentType},</if>
             <if test="incidentDescription != null">#{incidentDescription},</if>
             <if test="causeRes != null">#{causeRes},</if>
             <if test="coutermeasures != null">#{coutermeasures},</if>
@@ -91,8 +99,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
     <update id="updateTPlantOperationlist" parameterType="TPlantOperationlist">
         update t_plant_operationlist
         <trim prefix="SET" suffixOverrides=",">
+            <if test="identifiedDate != null">identified_date = #{identifiedDate},</if>
+            <if test="identifiedDateStr != null "> and to_char(identified_date,'YYYY') = #{identifiedDateStr}</if>
             <if test="plant != null">plant = #{plant},</if>
             <if test="shiftClass != null">shift_class = #{shiftClass},</if>
+            <if test="incidentType != null">incident_type = #{incidentType},</if>
             <if test="incidentDescription != null">incident_description = #{incidentDescription},</if>
             <if test="causeRes != null">cause_res = #{causeRes},</if>
             <if test="coutermeasures != null">coutermeasures = #{coutermeasures},</if>

BIN
master/src/main/resources/static/template/issue/OperationlistTmpl.xlsx


BIN
master/src/main/resources/static/template/issue/issuelistTmpl.xlsx


BIN
master/src/main/resources/static/word/issue/OperationlistTmpl.xlsx


BIN
master/src/main/resources/static/word/issue/issuelistTmpl.xlsx


+ 7 - 7
ui/src/api/issue/issuelist.js

@@ -1,6 +1,6 @@
 import request from '@/utils/request'
 
-// 查询问题清单和行动计划列表
+// 查询装置问题滚动清单列表
 export function listIssuelist(query) {
   return request({
     url: '/issue/issuelist/list',
@@ -9,7 +9,7 @@ export function listIssuelist(query) {
   })
 }
 
-// 查询问题清单和行动计划详细
+// 查询装置问题滚动清单详细
 export function getIssuelist(id) {
   return request({
     url: '/issue/issuelist/' + id,
@@ -17,7 +17,7 @@ export function getIssuelist(id) {
   })
 }
 
-// 新增问题清单和行动计划
+// 新增装置问题滚动清单
 export function addIssuelist(data) {
   return request({
     url: '/issue/issuelist',
@@ -26,7 +26,7 @@ export function addIssuelist(data) {
   })
 }
 
-// 修改问题清单和行动计划
+// 修改装置问题滚动清单
 export function updateIssuelist(data) {
   return request({
     url: '/issue/issuelist',
@@ -35,7 +35,7 @@ export function updateIssuelist(data) {
   })
 }
 
-// 删除问题清单和行动计划
+// 删除装置问题滚动清单
 export function delIssuelist(id) {
   return request({
     url: '/issue/issuelist/' + id,
@@ -43,11 +43,11 @@ export function delIssuelist(id) {
   })
 }
 
-// 导出问题清单和行动计划
+// 导出装置问题滚动清单
 export function exportIssuelist(query) {
   return request({
     url: '/issue/issuelist/export',
     method: 'get',
     params: query
   })
-}
+}

+ 791 - 0
ui/src/views/issue/issuelist/bd.vue

@@ -0,0 +1,791 @@
+<template>
+  <div class="app-container">
+    <el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" label-width="68px">
+      <el-form-item label="区域" prop="area">
+        <el-select  v-model="queryParams.area" @change="handleQuery" placeholder="请选择区域" clearable>
+          <el-option value="第一萃取精馏单元" laabel="第一萃取精馏单元"></el-option>
+          <el-option value="第二萃取精馏单元" laabel="第二萃取精馏单元"></el-option>
+          <el-option value="丁二烯精馏单元" laabel="丁二烯精馏单元"></el-option>
+          <el-option value="溶剂精制单元" laabel="溶剂精制单元"></el-option>
+          <el-option value="辅助单元" laabel="辅助单元"></el-option>
+          <el-option value="公用工程单元" laabel="公用工程单元"></el-option>
+        </el-select>
+      </el-form-item>
+      <el-form-item label="提出日期" prop="identifiedDateStr">
+        <el-date-picker clearable size="small" style="width: 200px"
+                        v-model="queryParams.identifiedDateStr"
+                        type="year"
+                        @change="handleQuery"
+                        value-format="yyyy"
+                        placeholder="选择提出日期">
+        </el-date-picker>
+      </el-form-item>
+      <el-form-item label="当前状态" prop="currentStates">
+        <el-select  v-model="queryParams.currentStates" @change="handleQuery" placeholder="请选择当前状态" clearable>
+          <el-option value="已完成" laabel="已完成"></el-option>
+          <el-option value="未完成" laabel="未完成"></el-option>
+        </el-select>
+      </el-form-item>
+      <el-form-item label="识别出的问题" prop="issueIdentified" label-width="120">
+        <el-input
+          v-model="queryParams.issueIdentified"
+          placeholder="请输入识别出的问题"
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="负责部门" prop="responsibleUnit">
+        <el-input
+          v-model="queryParams.responsibleUnit"
+          placeholder="请输入负责部门"
+          @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="['issue:issuelist: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="['issue:issuelist: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="['issue:issuelist:remove']"
+        >删除
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="info"
+          icon="el-icon-upload2"
+          size="mini"
+          @click="handleImport"
+          v-hasPermi="['issue:issuelist:edit']"
+        >导入
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="warning"
+          icon="el-icon-download"
+          size="mini"
+          @click="handleExport"
+          v-hasPermi="['issue:issuelist:export']"
+        >导出
+        </el-button>
+      </el-col>
+      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+    </el-row>
+
+    <el-table v-loading="loading" :data="issuelistList" @selection-change="handleSelectionChange" :height="clientHeight" :row-class-name="tableRowClassName"
+              border >
+      <el-table-column type="selection" width="55" align="center"/>
+      <el-table-column type="index" label="序号"  width="55" align="center" :index="indexMethod"/>
+      <el-table-column label="区域" align="center" prop="area" :show-overflow-tooltip="true" width="150"/>
+      <el-table-column label="提出日期" align="center" prop="identifiedDate" width="100">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.identifiedDate, '{y}-{m}-{d}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="问题来源" align="center" prop="issueSource" :show-overflow-tooltip="true" width="150"/>
+      <el-table-column label="识别出的问题" align="center" prop="issueIdentified" :show-overflow-tooltip="true"
+                       width="150"/>
+      <el-table-column label="要采取的措施" align="center" prop="actionsTaken" :show-overflow-tooltip="true"
+                       width="150"/>
+      <el-table-column label="问题类别" align="center" prop="issueClass" :show-overflow-tooltip="true" width="150"/>
+      <el-table-column label="负责部门" align="center" prop="responsibleUnit" :show-overflow-tooltip="true"
+                       width="150"/>
+      <el-table-column label="负责人员" align="center" prop="responsiblePerson" :show-overflow-tooltip="true"
+                       width="150"/>
+      <el-table-column label="当前状态" align="center" prop="currentStates" :show-overflow-tooltip="true" width="150"/>
+      <el-table-column label="预计完成日期" align="center" prop="expectedDate" :show-overflow-tooltip="true" width="100">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.expectedDate, '{y}-{m}-{d}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="实际完成日期" align="center" prop="completionDate" :show-overflow-tooltip="true" width="100">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.completionDate, '{y}-{m}-{d}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="备注" align="center" prop="remarks" :show-overflow-tooltip="true" width="150"/>
+      <el-table-column label="操作" align="center" fixed="right" width="160" class-name="small-padding fixed-width">
+        <template slot-scope="scope">
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-edit"
+            @click="handleUpdate(scope.row)"
+            v-hasPermi="['issue:issuelist:edit']"
+          >修改
+          </el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-delete"
+            @click="handleDelete(scope.row)"
+            v-hasPermi="['issue:issuelist:remove']"
+          >删除
+          </el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-document"
+            @click="handleDoc(scope.row)"
+            v-hasPermi="['issue:issuelist:edit']"
+          >{{ $t('附件') }}</el-button>
+        </template>
+      </el-table-column>
+    </el-table>
+
+    <pagination
+      v-show="total>0"
+      :total="total"
+      :page.sync="queryParams.pageNum"
+      :limit.sync="queryParams.pageSize"
+      @pagination="getList"
+    />
+
+    <!-- 添加或修改装置问题滚动清单对话框 -->
+    <el-dialog :title="title" :visible.sync="open" width="60%" append-to-body :close-on-click-modal="false">
+      <el-form ref="form" :model="form" :rules="rules" label-width="180px">
+        <el-form-item label="区域" prop="area">
+          <el-select  v-model="form.area" placeholder="请选择区域" clearable style="width: 100%">
+            <el-option value="第一萃取精馏单元" laabel="第一萃取精馏单元"></el-option>
+            <el-option value="第二萃取精馏单元" laabel="第二萃取精馏单元"></el-option>
+            <el-option value="丁二烯精馏单元" laabel="丁二烯精馏单元"></el-option>
+            <el-option value="溶剂精制单元" laabel="溶剂精制单元"></el-option>
+            <el-option value="辅助单元" laabel="辅助单元"></el-option>
+            <el-option value="公用工程单元" laabel="公用工程单元"></el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item label="提出日期" prop="identifiedDate">
+          <el-date-picker clearable size="small" style="width: 100%"
+                          v-model="form.identifiedDate"
+                          type="date"
+                          value-format="yyyy-MM-dd"
+                          placeholder="选择提出日期">
+          </el-date-picker>
+        </el-form-item>
+        <el-form-item label="问题来源" prop="issueSource">
+          <el-select  v-model="form.issueSource"  placeholder="请选择问题来源" clearable style="width: 100%">
+            <el-option value="日常巡检" laabel="日常巡检"></el-option>
+            <el-option value="政府检查" laabel="政府检查"></el-option>
+            <el-option value="审计检查" laabel="审计检查"></el-option>
+            <el-option value="运行故障" laabel="运行故障"></el-option>
+            <el-option value="其他" laabel="其他"></el-option>
+          </el-select></el-form-item>
+        <el-form-item label="识别出的问题" prop="issueIdentified">
+          <el-input type="textarea" v-model="form.issueIdentified" placeholder="请输入识别出的问题"/>
+        </el-form-item>
+        <el-form-item label="要采取的措施" prop="actionsTaken">
+          <el-input type="textarea"  v-model="form.actionsTaken" placeholder="请输入要采取的措施"/>
+        </el-form-item>
+        <el-form-item label="问题类别" prop="issueClass">
+          <el-select  v-model="form.issueClass"  placeholder="请选择问题来源" clearable style="width: 100%">
+            <el-option value="设备" laabel="设备"></el-option>
+            <el-option value="电仪" laabel="电仪"></el-option>
+            <el-option value="安全措施" laabel="安全措施"></el-option>
+            <el-option value="其他" laabel="其他"></el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item label="负责部门 " prop="responsibleUnit">
+          <el-input v-model="form.responsibleUnit" placeholder="请输入负责人员"/>
+        </el-form-item>
+        <el-form-item label="负责人员" prop="responsiblePerson">
+          <el-input v-model="form.responsiblePerson" placeholder="请输入负责人员"/>
+        </el-form-item>
+        <el-form-item label="当前状态" prop="currentStates">
+          <el-select  v-model="form.currentStates" placeholder="请选择当前状态" clearable style="width: 100%">
+            <el-option value="已完成" laabel="已完成"></el-option>
+            <el-option value="未完成" laabel="未完成"></el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item label="预计完成日期" prop="expectedDate">
+          <el-date-picker clearable size="small"  style="width: 100%"
+                          v-model="form.expectedDate"
+                          type="date"
+                          value-format="yyyy-MM-dd"
+                          placeholder="选择预计完成日期">
+          </el-date-picker>
+        </el-form-item>
+        <el-form-item label="实际完成日期" prop="completionDate">
+          <el-date-picker clearable size="small"  style="width: 100%"
+                          v-model="form.completionDate"
+                          type="date"
+                          value-format="yyyy-MM-dd"
+                          placeholder="选择实际完成日期">
+          </el-date-picker>
+        </el-form-item>
+        <el-form-item label="备注" prop="remarks">
+          <el-input 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 :close-on-click-modal="false" v-dialogDrag :title="doc.title" :visible.sync="doc.open" width="700px"
+               append-to-body>
+      <el-upload
+        ref="doc"
+        :limit="50"
+        :headers="doc.headers"
+        :action="doc.url + '?pType=' + doc.pType + '&pId=' + doc.pId"
+        :disabled="doc.isUploading"
+        :on-progress="handleFileDocProgress"
+        :on-success="handleFileDocSuccess"
+        :auto-upload="true"
+        drag
+      >
+        <i class="el-icon-upload"></i>
+        <div class="el-upload__text">
+          {{ $t('将文件拖到此处,或') }}
+          <em>{{ $t('点击上传') }}</em>
+        </div>
+      </el-upload>
+      <el-table :data="doc.commonfileList" border>
+        <el-table-column :label="$t('文件名')" align="center" prop="fileName" :show-overflow-tooltip="true">
+          <template slot-scope="scope">
+            <a class="link-type" @click="handleDownload(scope.row)">
+              <span>{{ scope.row.fileName }}</span>
+            </a>
+          </template>
+        </el-table-column>
+        <el-table-column :label="$t('大小(Kb)')" align="center" prop="fileSize" :show-overflow-tooltip="true"
+                         width="80"/>
+        <el-table-column :label="$t('上传人')" align="center" prop="creator" :show-overflow-tooltip="true" width="120"/>
+        <el-table-column :label="$t('操作')" align="center" width="120" class-name="small-padding fixed-width">
+          <template slot-scope="scope">
+            <el-button
+              v-if="scope.row.fileName.endsWith('pdf')"
+              size="mini"
+              type="text"
+              icon="el-icon-view"
+              @click="handleSee(scope.row)"
+            >{{ $t('预览') }}
+            </el-button>
+            <el-button
+              size="mini"
+              type="text"
+              icon="el-icon-download"
+              @click="handleDownload(scope.row)"
+            >{{ $t('下载') }}
+            </el-button>
+            <el-button
+              size="mini"
+              type="text"
+              icon="el-icon-delete"
+              @click="handleDeleteDoc(scope.row)"
+            >{{ $t('删除') }}
+            </el-button>
+          </template>
+        </el-table-column>
+      </el-table>
+      <el-dialog :close-on-click-modal="false" v-dialogDrag :title="pdf.title" :visible.sync="pdf.open" width="1300px"
+                 append-to-body>
+        <div style="margin-top: -60px;float: right;margin-right: 40px;">
+          <el-button size="mini" type="text" @click="openPdf">{{ $t('新页面打开PDF') }}</el-button>
+        </div>
+        <div style="margin-top: -30px">
+          <iframe :src="pdf.pdfUrl" frameborder="0" width="100%" height="700px"></iframe>
+        </div>
+      </el-dialog>
+      <div slot="footer" class="dialog-footer">
+        <!--        <el-button type="primary" @click="submitFileForm">{{ $t('确 定') }}</el-button>-->
+        <el-button @click="doc.open = false">{{ $t('返 回') }}</el-button>
+      </div>
+    </el-dialog>
+    <!-- 用户导入对话框 -->
+    <el-dialog :close-on-click-modal="false" v-dialogDrag :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"
+        :disabled="upload.isUploading"
+        :on-progress="handleFileUploadProgress"
+        :on-success="handleFileSuccess"
+        :auto-upload="false"
+        drag
+      >
+        <i class="el-icon-upload"></i>
+        <div class="el-upload__text">
+          {{ $t('将文件拖到此处,或') }}
+          <em>{{ $t('点击上传') }}</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">{{ $t('下载模板') }}</el-link>
+        </div>
+        <form ref="downloadFileForm" :action="upload.downloadAction" target="FORMSUBMIT">
+          <input name="type" :value="upload.type" hidden/>
+        </form>
+        <div class="el-upload__tip" style="color:red" slot="tip">{{ $t('提示:仅允许导入“xls”或“xlsx”格式文件!') }}</div>
+      </el-upload>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitFileForm">{{ $t('确 定') }}</el-button>
+        <el-button @click="upload.open = false">{{ $t('取 消') }}</el-button>
+      </div>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import {
+  addIssuelist,
+  delIssuelist,
+  exportIssuelist,
+  getIssuelist,
+  listIssuelist,
+  updateIssuelist
+} from "@/api/issue/issuelist";
+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 {allFileList, delCommonfile} from "@/api/common/commonfile";
+
+export default {
+  name: "IssuelistBD",
+  components: {Treeselect},
+  data() {
+    return {
+      // 遮罩层
+      loading: true,
+      // 选中数组
+      ids: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: false,
+      // 总条数
+      total: 0,
+      // 装置问题滚动清单表格数据
+      issuelistList: [],
+      // 弹出层标题
+      title: "",
+      // 部门树选项
+      deptOptions: undefined,
+      clientHeight: 300,
+      // 是否显示弹出层
+      open: false,
+      // 用户导入参数
+      upload: {
+        downloadAction: process.env.VUE_APP_BASE_API + '/common/template',
+        //下载模板类型
+        type: "issuelist",
+        // 是否显示弹出层(用户导入)
+        open: false,
+        // 弹出层标题(用户导入)
+        title: "",
+        // 是否禁用上传
+        isUploading: false,
+        // 是否更新已经存在的用户数据
+        updateSupport: 0,
+        // 设置上传的请求头部
+        headers: {Authorization: "Bearer " + getToken()},
+        // 上传的地址
+        url: process.env.VUE_APP_BASE_API + "/issue/issuelist/importData"
+      },
+      // 报告附件参数
+      doc: {
+        file: "",
+        // 是否显示弹出层(报告附件)
+        open: false,
+        // 弹出层标题(报告附件)
+        title: "",
+        // 是否禁用上传
+        isUploading: false,
+        // 是否更新已经存在的用户数据
+        updateSupport: 0,
+        // 报告附件上传位置编号
+        ids: 0,
+        // 设置上传的请求头部
+        headers: {Authorization: "Bearer " + getToken()},
+        // 上传的地址
+        url: process.env.VUE_APP_BASE_API + "/common/commonfile/uploadFile",
+        commonfileList: null,
+        queryParams: {
+          pId: null,
+          pType: 'issuelist'
+        },
+        pType: 'issuelist',
+        pId: null
+      },
+      pdf : {
+        title: '',
+        pdfUrl: '',
+        numPages: null,
+        open: false,
+        pageNum: 1,
+        pageTotalNum: 1,
+        loadedRatio: 0,
+      },
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 20,
+        plant: 'BD',
+        area: null,
+        identifiedDate: null,
+        identifiedDateStr: new Date().getFullYear().toString(),
+        issueSource: null,
+        issueIdentified: null,
+        actionsTaken: null,
+        issueClass: null,
+        responsiblePerson: null,
+        responsibleUnit: null,
+        currentStates: null,
+        completionDate: null,
+        additionalDeadline: null,
+        createrCode: null,
+        createdate: null,
+        updaterCode: null,
+        updatedate: null,
+        deptId: null,
+        remarks: null
+      },
+      // 表单参数
+      form: {},
+      // 表单校验
+      rules: {
+        area: [
+          {required: true, message: "请选择区域", trigger: "blur"}
+        ],
+        identifiedDate: [
+          {required: true, message: "请选择提出时间", trigger: "blur"}
+        ],
+        issueSource: [
+          {required: true, message: "请选择问题来源", trigger: "blur"}
+        ],
+        issueIdentified: [
+          {required: true, message: "识别出的问题不能为空", trigger: "blur"}
+        ],
+        actionsTaken: [
+          {required: true, message: "要采取的措施不能为空", trigger: "blur"}
+        ],
+        issueClass: [
+          {required: true, message: "请选择问题类别", trigger: "blur"}
+        ],
+        responsiblePerson: [
+          {required: true, message: "负责人员不能为空", trigger: "blur"}
+        ],
+        responsibleUnit: [
+          {required: true, message: "负责部门不能为空", trigger: "blur"}
+        ],
+        currentStates: [
+          {required: true, message: "请选择当前状态", trigger: "blur"}
+        ],
+        expectedDate: [
+          {required: true, message: "请选择预计完成日期", trigger: "blur"}
+        ],
+      }
+    };
+  },
+  watch: {
+    // 根据名称筛选部门树
+    deptName(val) {
+      this.$refs.tree.filter(val);
+    }
+  },
+  created() {
+    //设置表格高度对应屏幕高度
+    this.$nextTick(() => {
+      this.clientHeight = document.body.clientHeight - 330
+    })
+    this.getList();
+    this.getTreeselect();
+  },
+  methods: {
+    /** 查询装置问题滚动清单列表 */
+    getList() {
+      this.loading = true;
+      listIssuelist(this.queryParams).then(response => {
+        this.issuelistList = 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,
+        plant: 'BD',
+        area: null,
+        identifiedDate: null,
+        issueSource: null,
+        issueIdentified: null,
+        actionsTaken: null,
+        issueClass: null,
+        responsiblePerson: null,
+        responsibleUnit: null,
+        currentStates: null,
+        completionDate: null,
+        expectedDate: null,
+        additionalDeadline: null,
+        delFlag: null,
+        createrCode: null,
+        createdate: null,
+        updaterCode: null,
+        updatedate: null,
+        deptId: null,
+        remarks: 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
+      getIssuelist(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) {
+            updateIssuelist(this.form).then(response => {
+              this.msgSuccess("修改成功");
+              this.open = false;
+              this.getList();
+            });
+          } else {
+            addIssuelist(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 delIssuelist(ids);
+      }).then(() => {
+        this.getList();
+        this.msgSuccess("删除成功");
+      })
+    },
+    /** 导出按钮操作 */
+    handleExport() {
+      const queryParams = this.queryParams;
+      this.$confirm('是否确认导出所有装置问题滚动清单数据项?', "警告", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning"
+      }).then(function () {
+        return exportIssuelist(queryParams);
+      }).then(response => {
+        this.download(response.msg);
+      })
+    },
+    /** 导入按钮操作 */
+    handleImport() {
+      this.upload.title = "用户导入";
+      this.upload.open = true;
+    },
+    /** 下载模板操作 */
+    importTemplate() {
+      this.$refs['downloadFileForm'].submit()
+    },
+    // 文件上传中处理
+    handleFileUploadProgress(event, file, fileList) {
+      this.upload.isUploading = true;
+    },
+    // 文件上传成功处理
+    handleFileSuccess(response, file, fileList) {
+      this.upload.open = false;
+      this.upload.isUploading = false;
+      this.$refs.upload.clearFiles();
+      if (response.data[0] != null) {
+        this.$alert(this.$t('成功导入') + response.msg + this.$t('条数据') + "," + this.$t('第') + response.data + this.$t('行数据出现错误导入失败') + "。", this.$t('导入结果'), {dangerouslyUseHTMLString: true});
+      } else {
+        this.$alert(this.$t('成功导入') + response.msg + this.$t('条数据'), this.$t('导入结果'), {dangerouslyUseHTMLString: true});
+      }
+      this.getList();
+    },
+    // 提交上传文件
+    submitFileForm() {
+      this.$refs.upload.submit();
+    },
+    /** 报告附件按钮操作 */
+    handleDoc(row) {
+      this.doc.id = row.id;
+      this.doc.title = this.$t('附件');
+      this.doc.open = true;
+      this.doc.queryParams.pId = row.id
+      this.doc.pId = row.id
+      this.getFileList()
+      this.$nextTick(() => {
+        this.$refs.doc.clearFiles()
+      })
+    },
+    getFileList() {
+      allFileList(this.doc.queryParams).then(response => {
+        this.doc.commonfileList = response;
+      });
+    },
+    //附件上传中处理
+    handleFileDocProgress(event, file, fileList) {
+      this.doc.file = file;
+      this.doc.isUploading = true;
+    },
+    //附件上传成功处理
+    handleFileDocSuccess(response, file, fileList) {
+      this.doc.isUploading = false;
+      this.$alert(response.msg, this.$t('导入结果'), {dangerouslyUseHTMLString: true});
+      this.getFileList()
+    },
+    /** 删除按钮操作 */
+    handleDeleteDoc(row) {
+      const ids = row.id || this.ids;
+      this.$confirm(this.$t('是否确认删除?'), this.$t('警告'), {
+        confirmButtonText: this.$t('确定'),
+        cancelButtonText: this.$t('取消'),
+        type: "warning"
+      }).then(function () {
+        return delCommonfile(ids);
+      }).then(() => {
+        this.getFileList()
+        this.msgSuccess(this.$t('删除成功'));
+      })
+    },
+    // 文件下载处理
+    handleDownload(row) {
+      var name = row.fileName;
+      var url = row.fileUrl;
+      var suffix = url.substring(url.lastIndexOf("."), url.length);
+      const a = document.createElement('a')
+      a.setAttribute('download', name)
+      a.setAttribute('target', '_blank')
+      a.setAttribute('href', process.env.VUE_APP_BASE_API + url)
+      a.click()
+    },
+    openPdf() {
+      window.open(this.pdf.pdfUrl);//path是文件的全路径地址
+    },
+    handleSee(row) {
+      this.pdf.open = true
+      this.pdf.title = row.fileName
+      this.pdf.pdfUrl = process.env.VUE_APP_BASE_API + '/pdf/web/viewer.html?file=' + process.env.VUE_APP_BASE_API + row.fileUrl
+    },
+
+    // 计算日期差(天数)
+    getDateDiff(date) {
+      const today = new Date();
+      today.setHours(0, 0, 0, 0);
+
+      const targetDate = new Date(date);
+      targetDate.setHours(0, 0, 0, 0);
+
+      const diffTime = targetDate.getTime() - today.getTime();
+      return Math.ceil(diffTime / (1000 * 60 * 60 * 24));
+    },
+
+    // 设置行样式
+    tableRowClassName({ row,rowIndex }) {
+      if (!row.expectedDate||row.currentStates!=='未完成'){
+        return '';
+      }
+      const diffDays = this.getDateDiff(row.expectedDate);
+      console.log(diffDays)
+      if (diffDays <= 0) {
+        return 'danger-row';
+      } else if (diffDays < 15) {
+        return 'warning-row';
+      }
+      return '';
+    },
+    //翻页后继续计算序列值
+    indexMethod(index) {
+      return (this.queryParams.pageNum-1)*this.queryParams.pageSize+index+1;
+    }
+  }
+};
+</script>
+
+<style>
+
+.el-table .warning-row {
+  background: #ffff00 ;
+}
+.el-table .danger-row {
+  background: #ff0000 ;
+}
+</style>

+ 805 - 0
ui/src/views/issue/issuelist/ebsm.vue

@@ -0,0 +1,805 @@
+<template>
+  <div class="app-container">
+    <el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" label-width="68px">
+      <el-form-item label="区域" prop="area">
+        <el-select  v-model="form.area" placeholder="请选择区域" clearable style="width: 100%">
+          <el-option value="装置主管廊区" laabel="装置主管廊区"></el-option>
+          <el-option value="构一" laabel="构一"></el-option>
+          <el-option value="构二" laabel="构二"></el-option>
+          <el-option value="构三" laabel="构三"></el-option>
+          <el-option value="构四" laabel="构四"></el-option>
+          <el-option value="构五" laabel="构五"></el-option>
+          <el-option value="构六" laabel="构六"></el-option>
+          <el-option value="构七" laabel="构七"></el-option>
+          <el-option value="构八" laabel="构八"></el-option>
+          <el-option value="8200#空调制冷区" laabel="8200#空调制冷区"></el-option>
+          <el-option value="8500#污水处理区" laabel="8500#污水处理区"></el-option>
+          <el-option value="8900#火炬区" laabel="8900#火炬区"></el-option>
+          <el-option value="9000#罐区" laabel="9000#罐区"></el-option>
+        </el-select>
+      </el-form-item>
+      <el-form-item label="提出日期" prop="identifiedDateStr">
+        <el-date-picker clearable size="small" style="width: 200px"
+                        v-model="queryParams.identifiedDateStr"
+                        type="year"
+                        @change="handleQuery"
+                        value-format="yyyy"
+                        placeholder="选择提出日期">
+        </el-date-picker>
+      </el-form-item>
+      <el-form-item label="当前状态" prop="currentStates">
+        <el-select  v-model="queryParams.currentStates" @change="handleQuery" placeholder="请选择当前状态" clearable>
+          <el-option value="已完成" laabel="已完成"></el-option>
+          <el-option value="未完成" laabel="未完成"></el-option>
+        </el-select>
+      </el-form-item>
+      <el-form-item label="识别出的问题" prop="issueIdentified" label-width="120">
+        <el-input
+          v-model="queryParams.issueIdentified"
+          placeholder="请输入识别出的问题"
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="负责部门" prop="responsibleUnit">
+        <el-input
+          v-model="queryParams.responsibleUnit"
+          placeholder="请输入负责部门"
+          @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="['issue:issuelist: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="['issue:issuelist: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="['issue:issuelist:remove']"
+        >删除
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="info"
+          icon="el-icon-upload2"
+          size="mini"
+          @click="handleImport"
+          v-hasPermi="['issue:issuelist:edit']"
+        >导入
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="warning"
+          icon="el-icon-download"
+          size="mini"
+          @click="handleExport"
+          v-hasPermi="['issue:issuelist:export']"
+        >导出
+        </el-button>
+      </el-col>
+      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+    </el-row>
+
+    <el-table v-loading="loading" :data="issuelistList" @selection-change="handleSelectionChange" :height="clientHeight" :row-class-name="tableRowClassName"
+              border >
+      <el-table-column type="selection" width="55" align="center"/>
+      <el-table-column type="index" label="序号"  width="55" align="center" :index="indexMethod"/>
+      <el-table-column label="区域" align="center" prop="area" :show-overflow-tooltip="true" width="150"/>
+      <el-table-column label="提出日期" align="center" prop="identifiedDate" width="100">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.identifiedDate, '{y}-{m}-{d}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="问题来源" align="center" prop="issueSource" :show-overflow-tooltip="true" width="150"/>
+      <el-table-column label="识别出的问题" align="center" prop="issueIdentified" :show-overflow-tooltip="true"
+                       width="150"/>
+      <el-table-column label="要采取的措施" align="center" prop="actionsTaken" :show-overflow-tooltip="true"
+                       width="150"/>
+      <el-table-column label="问题类别" align="center" prop="issueClass" :show-overflow-tooltip="true" width="150"/>
+      <el-table-column label="负责部门" align="center" prop="responsibleUnit" :show-overflow-tooltip="true"
+                       width="150"/>
+      <el-table-column label="负责人员" align="center" prop="responsiblePerson" :show-overflow-tooltip="true"
+                       width="150"/>
+      <el-table-column label="当前状态" align="center" prop="currentStates" :show-overflow-tooltip="true" width="150"/>
+      <el-table-column label="预计完成日期" align="center" prop="expectedDate" :show-overflow-tooltip="true" width="100">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.expectedDate, '{y}-{m}-{d}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="实际完成日期" align="center" prop="completionDate" :show-overflow-tooltip="true" width="100">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.completionDate, '{y}-{m}-{d}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="备注" align="center" prop="remarks" :show-overflow-tooltip="true" width="150"/>
+      <el-table-column label="操作" align="center" fixed="right" width="160" class-name="small-padding fixed-width">
+        <template slot-scope="scope">
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-edit"
+            @click="handleUpdate(scope.row)"
+            v-hasPermi="['issue:issuelist:edit']"
+          >修改
+          </el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-delete"
+            @click="handleDelete(scope.row)"
+            v-hasPermi="['issue:issuelist:remove']"
+          >删除
+          </el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-document"
+            @click="handleDoc(scope.row)"
+            v-hasPermi="['issue:issuelist:edit']"
+          >{{ $t('附件') }}</el-button>
+        </template>
+      </el-table-column>
+    </el-table>
+
+    <pagination
+      v-show="total>0"
+      :total="total"
+      :page.sync="queryParams.pageNum"
+      :limit.sync="queryParams.pageSize"
+      @pagination="getList"
+    />
+
+    <!-- 添加或修改装置问题滚动清单对话框 -->
+    <el-dialog :title="title" :visible.sync="open" width="60%" append-to-body :close-on-click-modal="false">
+      <el-form ref="form" :model="form" :rules="rules" label-width="180px">
+        <el-form-item label="区域" prop="area">
+          <el-select  v-model="form.area" placeholder="请选择区域" clearable style="width: 100%">
+            <el-option value="装置主管廊区" laabel="装置主管廊区"></el-option>
+            <el-option value="构一" laabel="构一"></el-option>
+            <el-option value="构二" laabel="构二"></el-option>
+            <el-option value="构三" laabel="构三"></el-option>
+            <el-option value="构四" laabel="构四"></el-option>
+            <el-option value="构五" laabel="构五"></el-option>
+            <el-option value="构六" laabel="构六"></el-option>
+            <el-option value="构七" laabel="构七"></el-option>
+            <el-option value="构八" laabel="构八"></el-option>
+            <el-option value="8200#空调制冷区" laabel="8200#空调制冷区"></el-option>
+            <el-option value="8500#污水处理区" laabel="8500#污水处理区"></el-option>
+            <el-option value="8900#火炬区" laabel="8900#火炬区"></el-option>
+            <el-option value="9000#罐区" laabel="9000#罐区"></el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item label="提出日期" prop="identifiedDate">
+          <el-date-picker clearable size="small" style="width: 100%"
+                          v-model="form.identifiedDate"
+                          type="date"
+                          value-format="yyyy-MM-dd"
+                          placeholder="选择提出日期">
+          </el-date-picker>
+        </el-form-item>
+        <el-form-item label="问题来源" prop="issueSource">
+          <el-select  v-model="form.issueSource"  placeholder="请选择问题来源" clearable style="width: 100%">
+            <el-option value="日常巡检" laabel="日常巡检"></el-option>
+            <el-option value="政府检查" laabel="政府检查"></el-option>
+            <el-option value="审计检查" laabel="审计检查"></el-option>
+            <el-option value="运行故障" laabel="运行故障"></el-option>
+            <el-option value="其他" laabel="其他"></el-option>
+          </el-select></el-form-item>
+        <el-form-item label="识别出的问题" prop="issueIdentified">
+          <el-input type="textarea" v-model="form.issueIdentified" placeholder="请输入识别出的问题"/>
+        </el-form-item>
+        <el-form-item label="要采取的措施" prop="actionsTaken">
+          <el-input type="textarea"  v-model="form.actionsTaken" placeholder="请输入要采取的措施"/>
+        </el-form-item>
+        <el-form-item label="问题类别" prop="issueClass">
+          <el-select  v-model="form.issueClass"  placeholder="请选择问题来源" clearable style="width: 100%">
+            <el-option value="设备" laabel="设备"></el-option>
+            <el-option value="电仪" laabel="电仪"></el-option>
+            <el-option value="安全措施" laabel="安全措施"></el-option>
+            <el-option value="其他" laabel="其他"></el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item label="负责部门 " prop="responsibleUnit">
+          <el-input v-model="form.responsibleUnit" placeholder="请输入负责人员"/>
+        </el-form-item>
+        <el-form-item label="负责人员" prop="responsiblePerson">
+          <el-input v-model="form.responsiblePerson" placeholder="请输入负责人员"/>
+        </el-form-item>
+        <el-form-item label="当前状态" prop="currentStates">
+          <el-select  v-model="form.currentStates" placeholder="请选择当前状态" clearable style="width: 100%">
+            <el-option value="已完成" laabel="已完成"></el-option>
+            <el-option value="未完成" laabel="未完成"></el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item label="预计完成日期" prop="expectedDate">
+          <el-date-picker clearable size="small"  style="width: 100%"
+                          v-model="form.expectedDate"
+                          type="date"
+                          value-format="yyyy-MM-dd"
+                          placeholder="选择预计完成日期">
+          </el-date-picker>
+        </el-form-item>
+        <el-form-item label="实际完成日期" prop="completionDate">
+          <el-date-picker clearable size="small"  style="width: 100%"
+                          v-model="form.completionDate"
+                          type="date"
+                          value-format="yyyy-MM-dd"
+                          placeholder="选择实际完成日期">
+          </el-date-picker>
+        </el-form-item>
+        <el-form-item label="备注" prop="remarks">
+          <el-input 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 :close-on-click-modal="false" v-dialogDrag :title="doc.title" :visible.sync="doc.open" width="700px"
+               append-to-body>
+      <el-upload
+        ref="doc"
+        :limit="50"
+        :headers="doc.headers"
+        :action="doc.url + '?pType=' + doc.pType + '&pId=' + doc.pId"
+        :disabled="doc.isUploading"
+        :on-progress="handleFileDocProgress"
+        :on-success="handleFileDocSuccess"
+        :auto-upload="true"
+        drag
+      >
+        <i class="el-icon-upload"></i>
+        <div class="el-upload__text">
+          {{ $t('将文件拖到此处,或') }}
+          <em>{{ $t('点击上传') }}</em>
+        </div>
+      </el-upload>
+      <el-table :data="doc.commonfileList" border>
+        <el-table-column :label="$t('文件名')" align="center" prop="fileName" :show-overflow-tooltip="true">
+          <template slot-scope="scope">
+            <a class="link-type" @click="handleDownload(scope.row)">
+              <span>{{ scope.row.fileName }}</span>
+            </a>
+          </template>
+        </el-table-column>
+        <el-table-column :label="$t('大小(Kb)')" align="center" prop="fileSize" :show-overflow-tooltip="true"
+                         width="80"/>
+        <el-table-column :label="$t('上传人')" align="center" prop="creator" :show-overflow-tooltip="true" width="120"/>
+        <el-table-column :label="$t('操作')" align="center" width="120" class-name="small-padding fixed-width">
+          <template slot-scope="scope">
+            <el-button
+              v-if="scope.row.fileName.endsWith('pdf')"
+              size="mini"
+              type="text"
+              icon="el-icon-view"
+              @click="handleSee(scope.row)"
+            >{{ $t('预览') }}
+            </el-button>
+            <el-button
+              size="mini"
+              type="text"
+              icon="el-icon-download"
+              @click="handleDownload(scope.row)"
+            >{{ $t('下载') }}
+            </el-button>
+            <el-button
+              size="mini"
+              type="text"
+              icon="el-icon-delete"
+              @click="handleDeleteDoc(scope.row)"
+            >{{ $t('删除') }}
+            </el-button>
+          </template>
+        </el-table-column>
+      </el-table>
+      <el-dialog :close-on-click-modal="false" v-dialogDrag :title="pdf.title" :visible.sync="pdf.open" width="1300px"
+                 append-to-body>
+        <div style="margin-top: -60px;float: right;margin-right: 40px;">
+          <el-button size="mini" type="text" @click="openPdf">{{ $t('新页面打开PDF') }}</el-button>
+        </div>
+        <div style="margin-top: -30px">
+          <iframe :src="pdf.pdfUrl" frameborder="0" width="100%" height="700px"></iframe>
+        </div>
+      </el-dialog>
+      <div slot="footer" class="dialog-footer">
+        <!--        <el-button type="primary" @click="submitFileForm">{{ $t('确 定') }}</el-button>-->
+        <el-button @click="doc.open = false">{{ $t('返 回') }}</el-button>
+      </div>
+    </el-dialog>
+    <!-- 用户导入对话框 -->
+    <el-dialog :close-on-click-modal="false" v-dialogDrag :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"
+        :disabled="upload.isUploading"
+        :on-progress="handleFileUploadProgress"
+        :on-success="handleFileSuccess"
+        :auto-upload="false"
+        drag
+      >
+        <i class="el-icon-upload"></i>
+        <div class="el-upload__text">
+          {{ $t('将文件拖到此处,或') }}
+          <em>{{ $t('点击上传') }}</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">{{ $t('下载模板') }}</el-link>
+        </div>
+        <form ref="downloadFileForm" :action="upload.downloadAction" target="FORMSUBMIT">
+          <input name="type" :value="upload.type" hidden/>
+        </form>
+        <div class="el-upload__tip" style="color:red" slot="tip">{{ $t('提示:仅允许导入“xls”或“xlsx”格式文件!') }}</div>
+      </el-upload>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitFileForm">{{ $t('确 定') }}</el-button>
+        <el-button @click="upload.open = false">{{ $t('取 消') }}</el-button>
+      </div>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import {
+  addIssuelist,
+  delIssuelist,
+  exportIssuelist,
+  getIssuelist,
+  listIssuelist,
+  updateIssuelist
+} from "@/api/issue/issuelist";
+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 {allFileList, delCommonfile} from "@/api/common/commonfile";
+
+export default {
+  name: "IssuelistEBSM",
+  components: {Treeselect},
+  data() {
+    return {
+      // 遮罩层
+      loading: true,
+      // 选中数组
+      ids: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: false,
+      // 总条数
+      total: 0,
+      // 装置问题滚动清单表格数据
+      issuelistList: [],
+      // 弹出层标题
+      title: "",
+      // 部门树选项
+      deptOptions: undefined,
+      clientHeight: 300,
+      // 是否显示弹出层
+      open: false,
+      // 用户导入参数
+      upload: {
+        downloadAction: process.env.VUE_APP_BASE_API + '/common/template',
+        //下载模板类型
+        type: "issuelist",
+        // 是否显示弹出层(用户导入)
+        open: false,
+        // 弹出层标题(用户导入)
+        title: "",
+        // 是否禁用上传
+        isUploading: false,
+        // 是否更新已经存在的用户数据
+        updateSupport: 0,
+        // 设置上传的请求头部
+        headers: {Authorization: "Bearer " + getToken()},
+        // 上传的地址
+        url: process.env.VUE_APP_BASE_API + "/issue/issuelist/importData"
+      },
+      // 报告附件参数
+      doc: {
+        file: "",
+        // 是否显示弹出层(报告附件)
+        open: false,
+        // 弹出层标题(报告附件)
+        title: "",
+        // 是否禁用上传
+        isUploading: false,
+        // 是否更新已经存在的用户数据
+        updateSupport: 0,
+        // 报告附件上传位置编号
+        ids: 0,
+        // 设置上传的请求头部
+        headers: {Authorization: "Bearer " + getToken()},
+        // 上传的地址
+        url: process.env.VUE_APP_BASE_API + "/common/commonfile/uploadFile",
+        commonfileList: null,
+        queryParams: {
+          pId: null,
+          pType: 'issuelist'
+        },
+        pType: 'issuelist',
+        pId: null
+      },
+      pdf : {
+        title: '',
+        pdfUrl: '',
+        numPages: null,
+        open: false,
+        pageNum: 1,
+        pageTotalNum: 1,
+        loadedRatio: 0,
+      },
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 20,
+        plant: 'EBSM',
+        area: null,
+        identifiedDate: null,
+        identifiedDateStr: new Date().getFullYear().toString(),
+        issueSource: null,
+        issueIdentified: null,
+        actionsTaken: null,
+        issueClass: null,
+        responsiblePerson: null,
+        responsibleUnit: null,
+        currentStates: null,
+        completionDate: null,
+        additionalDeadline: null,
+        createrCode: null,
+        createdate: null,
+        updaterCode: null,
+        updatedate: null,
+        deptId: null,
+        remarks: null
+      },
+      // 表单参数
+      form: {},
+      // 表单校验
+      rules: {
+        area: [
+          {required: true, message: "请选择区域", trigger: "blur"}
+        ],
+        identifiedDate: [
+          {required: true, message: "请选择提出时间", trigger: "blur"}
+        ],
+        issueSource: [
+          {required: true, message: "请选择问题来源", trigger: "blur"}
+        ],
+        issueIdentified: [
+          {required: true, message: "识别出的问题不能为空", trigger: "blur"}
+        ],
+        actionsTaken: [
+          {required: true, message: "要采取的措施不能为空", trigger: "blur"}
+        ],
+        issueClass: [
+          {required: true, message: "请选择问题类别", trigger: "blur"}
+        ],
+        responsiblePerson: [
+          {required: true, message: "负责人员不能为空", trigger: "blur"}
+        ],
+        responsibleUnit: [
+          {required: true, message: "负责部门不能为空", trigger: "blur"}
+        ],
+        currentStates: [
+          {required: true, message: "请选择当前状态", trigger: "blur"}
+        ],
+        expectedDate: [
+          {required: true, message: "请选择预计完成日期", trigger: "blur"}
+        ],
+      }
+    };
+  },
+  watch: {
+    // 根据名称筛选部门树
+    deptName(val) {
+      this.$refs.tree.filter(val);
+    }
+  },
+  created() {
+    //设置表格高度对应屏幕高度
+    this.$nextTick(() => {
+      this.clientHeight = document.body.clientHeight - 330
+    })
+    this.getList();
+    this.getTreeselect();
+  },
+  methods: {
+    /** 查询装置问题滚动清单列表 */
+    getList() {
+      this.loading = true;
+      listIssuelist(this.queryParams).then(response => {
+        this.issuelistList = 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,
+        plant: 'EBSM',
+        area: null,
+        identifiedDate: null,
+        issueSource: null,
+        issueIdentified: null,
+        actionsTaken: null,
+        issueClass: null,
+        responsiblePerson: null,
+        responsibleUnit: null,
+        currentStates: null,
+        completionDate: null,
+        expectedDate: null,
+        additionalDeadline: null,
+        delFlag: null,
+        createrCode: null,
+        createdate: null,
+        updaterCode: null,
+        updatedate: null,
+        deptId: null,
+        remarks: 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
+      getIssuelist(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) {
+            updateIssuelist(this.form).then(response => {
+              this.msgSuccess("修改成功");
+              this.open = false;
+              this.getList();
+            });
+          } else {
+            addIssuelist(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 delIssuelist(ids);
+      }).then(() => {
+        this.getList();
+        this.msgSuccess("删除成功");
+      })
+    },
+    /** 导出按钮操作 */
+    handleExport() {
+      const queryParams = this.queryParams;
+      this.$confirm('是否确认导出所有装置问题滚动清单数据项?', "警告", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning"
+      }).then(function () {
+        return exportIssuelist(queryParams);
+      }).then(response => {
+        this.download(response.msg);
+      })
+    },
+    /** 导入按钮操作 */
+    handleImport() {
+      this.upload.title = "用户导入";
+      this.upload.open = true;
+    },
+    /** 下载模板操作 */
+    importTemplate() {
+      this.$refs['downloadFileForm'].submit()
+    },
+    // 文件上传中处理
+    handleFileUploadProgress(event, file, fileList) {
+      this.upload.isUploading = true;
+    },
+    // 文件上传成功处理
+    handleFileSuccess(response, file, fileList) {
+      this.upload.open = false;
+      this.upload.isUploading = false;
+      this.$refs.upload.clearFiles();
+      if (response.data[0] != null) {
+        this.$alert(this.$t('成功导入') + response.msg + this.$t('条数据') + "," + this.$t('第') + response.data + this.$t('行数据出现错误导入失败') + "。", this.$t('导入结果'), {dangerouslyUseHTMLString: true});
+      } else {
+        this.$alert(this.$t('成功导入') + response.msg + this.$t('条数据'), this.$t('导入结果'), {dangerouslyUseHTMLString: true});
+      }
+      this.getList();
+    },
+    // 提交上传文件
+    submitFileForm() {
+      this.$refs.upload.submit();
+    },
+    /** 报告附件按钮操作 */
+    handleDoc(row) {
+      this.doc.id = row.id;
+      this.doc.title = this.$t('附件');
+      this.doc.open = true;
+      this.doc.queryParams.pId = row.id
+      this.doc.pId = row.id
+      this.getFileList()
+      this.$nextTick(() => {
+        this.$refs.doc.clearFiles()
+      })
+    },
+    getFileList() {
+      allFileList(this.doc.queryParams).then(response => {
+        this.doc.commonfileList = response;
+      });
+    },
+    //附件上传中处理
+    handleFileDocProgress(event, file, fileList) {
+      this.doc.file = file;
+      this.doc.isUploading = true;
+    },
+    //附件上传成功处理
+    handleFileDocSuccess(response, file, fileList) {
+      this.doc.isUploading = false;
+      this.$alert(response.msg, this.$t('导入结果'), {dangerouslyUseHTMLString: true});
+      this.getFileList()
+    },
+    /** 删除按钮操作 */
+    handleDeleteDoc(row) {
+      const ids = row.id || this.ids;
+      this.$confirm(this.$t('是否确认删除?'), this.$t('警告'), {
+        confirmButtonText: this.$t('确定'),
+        cancelButtonText: this.$t('取消'),
+        type: "warning"
+      }).then(function () {
+        return delCommonfile(ids);
+      }).then(() => {
+        this.getFileList()
+        this.msgSuccess(this.$t('删除成功'));
+      })
+    },
+    // 文件下载处理
+    handleDownload(row) {
+      var name = row.fileName;
+      var url = row.fileUrl;
+      var suffix = url.substring(url.lastIndexOf("."), url.length);
+      const a = document.createElement('a')
+      a.setAttribute('download', name)
+      a.setAttribute('target', '_blank')
+      a.setAttribute('href', process.env.VUE_APP_BASE_API + url)
+      a.click()
+    },
+    openPdf() {
+      window.open(this.pdf.pdfUrl);//path是文件的全路径地址
+    },
+    handleSee(row) {
+      this.pdf.open = true
+      this.pdf.title = row.fileName
+      this.pdf.pdfUrl = process.env.VUE_APP_BASE_API + '/pdf/web/viewer.html?file=' + process.env.VUE_APP_BASE_API + row.fileUrl
+    },
+
+    // 计算日期差(天数)
+    getDateDiff(date) {
+      const today = new Date();
+      today.setHours(0, 0, 0, 0);
+
+      const targetDate = new Date(date);
+      targetDate.setHours(0, 0, 0, 0);
+
+      const diffTime = targetDate.getTime() - today.getTime();
+      return Math.ceil(diffTime / (1000 * 60 * 60 * 24));
+    },
+
+    // 设置行样式
+    tableRowClassName({ row,rowIndex }) {
+      if (!row.expectedDate||row.currentStates!=='未完成'){
+        return '';
+      }
+      const diffDays = this.getDateDiff(row.expectedDate);
+      console.log(diffDays)
+      if (diffDays <= 0) {
+        return 'danger-row';
+      } else if (diffDays < 15) {
+        return 'warning-row';
+      }
+      return '';
+    },
+    //翻页后继续计算序列值
+    indexMethod(index) {
+      return (this.queryParams.pageNum-1)*this.queryParams.pageSize+index+1;
+    }
+  }
+};
+</script>
+
+<style>
+
+.el-table .warning-row {
+  background: #ffff00 ;
+}
+.el-table .danger-row {
+  background: #ff0000 ;
+}
+</style>

+ 791 - 0
ui/src/views/issue/issuelist/ib.vue

@@ -0,0 +1,791 @@
+<template>
+  <div class="app-container">
+    <el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" label-width="68px">
+      <el-form-item label="区域" prop="area">
+        <el-select  v-model="queryParams.area" @change="handleQuery" placeholder="请选择区域" clearable>
+          <el-option value="醚合成单元" laabel="醚合成单元"></el-option>
+          <el-option value="抽余液2分离单元" laabel="抽余液2分离单元"></el-option>
+          <el-option value="抽余液2净化单元" laabel="抽余液2净化单元"></el-option>
+          <el-option value="醚裂化单元" laabel="醚裂化单元"></el-option>
+          <el-option value="异丁烯分离单元" laabel="异丁烯分离单元"></el-option>
+          <el-option value="副产品分离单元" laabel="副产品分离单元"></el-option>
+        </el-select>
+      </el-form-item>
+      <el-form-item label="提出日期" prop="identifiedDateStr">
+        <el-date-picker clearable size="small" style="width: 200px"
+                        v-model="queryParams.identifiedDateStr"
+                        type="year"
+                        @change="handleQuery"
+                        value-format="yyyy"
+                        placeholder="选择提出日期">
+        </el-date-picker>
+      </el-form-item>
+      <el-form-item label="当前状态" prop="currentStates">
+        <el-select  v-model="queryParams.currentStates" @change="handleQuery" placeholder="请选择当前状态" clearable>
+          <el-option value="已完成" laabel="已完成"></el-option>
+          <el-option value="未完成" laabel="未完成"></el-option>
+        </el-select>
+      </el-form-item>
+      <el-form-item label="识别出的问题" prop="issueIdentified" label-width="120">
+        <el-input
+          v-model="queryParams.issueIdentified"
+          placeholder="请输入识别出的问题"
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="负责部门" prop="responsibleUnit">
+        <el-input
+          v-model="queryParams.responsibleUnit"
+          placeholder="请输入负责部门"
+          @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="['issue:issuelist: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="['issue:issuelist: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="['issue:issuelist:remove']"
+        >删除
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="info"
+          icon="el-icon-upload2"
+          size="mini"
+          @click="handleImport"
+          v-hasPermi="['issue:issuelist:edit']"
+        >导入
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="warning"
+          icon="el-icon-download"
+          size="mini"
+          @click="handleExport"
+          v-hasPermi="['issue:issuelist:export']"
+        >导出
+        </el-button>
+      </el-col>
+      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+    </el-row>
+
+    <el-table v-loading="loading" :data="issuelistList" @selection-change="handleSelectionChange" :height="clientHeight" :row-class-name="tableRowClassName"
+              border >
+      <el-table-column type="selection" width="55" align="center"/>
+      <el-table-column type="index" label="序号"  width="55" align="center" :index="indexMethod"/>
+      <el-table-column label="区域" align="center" prop="area" :show-overflow-tooltip="true" width="150"/>
+      <el-table-column label="提出日期" align="center" prop="identifiedDate" width="100">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.identifiedDate, '{y}-{m}-{d}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="问题来源" align="center" prop="issueSource" :show-overflow-tooltip="true" width="150"/>
+      <el-table-column label="识别出的问题" align="center" prop="issueIdentified" :show-overflow-tooltip="true"
+                       width="150"/>
+      <el-table-column label="要采取的措施" align="center" prop="actionsTaken" :show-overflow-tooltip="true"
+                       width="150"/>
+      <el-table-column label="问题类别" align="center" prop="issueClass" :show-overflow-tooltip="true" width="150"/>
+      <el-table-column label="负责部门" align="center" prop="responsibleUnit" :show-overflow-tooltip="true"
+                       width="150"/>
+      <el-table-column label="负责人员" align="center" prop="responsiblePerson" :show-overflow-tooltip="true"
+                       width="150"/>
+      <el-table-column label="当前状态" align="center" prop="currentStates" :show-overflow-tooltip="true" width="150"/>
+      <el-table-column label="预计完成日期" align="center" prop="expectedDate" :show-overflow-tooltip="true" width="100">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.expectedDate, '{y}-{m}-{d}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="实际完成日期" align="center" prop="completionDate" :show-overflow-tooltip="true" width="100">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.completionDate, '{y}-{m}-{d}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="备注" align="center" prop="remarks" :show-overflow-tooltip="true" width="150"/>
+      <el-table-column label="操作" align="center" fixed="right" width="160" class-name="small-padding fixed-width">
+        <template slot-scope="scope">
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-edit"
+            @click="handleUpdate(scope.row)"
+            v-hasPermi="['issue:issuelist:edit']"
+          >修改
+          </el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-delete"
+            @click="handleDelete(scope.row)"
+            v-hasPermi="['issue:issuelist:remove']"
+          >删除
+          </el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-document"
+            @click="handleDoc(scope.row)"
+            v-hasPermi="['issue:issuelist:edit']"
+          >{{ $t('附件') }}</el-button>
+        </template>
+      </el-table-column>
+    </el-table>
+
+    <pagination
+      v-show="total>0"
+      :total="total"
+      :page.sync="queryParams.pageNum"
+      :limit.sync="queryParams.pageSize"
+      @pagination="getList"
+    />
+
+    <!-- 添加或修改装置问题滚动清单对话框 -->
+    <el-dialog :title="title" :visible.sync="open" width="60%" append-to-body :close-on-click-modal="false">
+      <el-form ref="form" :model="form" :rules="rules" label-width="180px">
+        <el-form-item label="区域" prop="area">
+          <el-select  v-model="form.area" placeholder="请选择区域" clearable style="width: 100%">
+            <el-option value="醚合成单元" laabel="醚合成单元"></el-option>
+            <el-option value="抽余液2分离单元" laabel="抽余液2分离单元"></el-option>
+            <el-option value="抽余液2净化单元" laabel="抽余液2净化单元"></el-option>
+            <el-option value="醚裂化单元" laabel="醚裂化单元"></el-option>
+            <el-option value="异丁烯分离单元" laabel="异丁烯分离单元"></el-option>
+            <el-option value="副产品分离单元" laabel="副产品分离单元"></el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item label="提出日期" prop="identifiedDate">
+          <el-date-picker clearable size="small" style="width: 100%"
+                          v-model="form.identifiedDate"
+                          type="date"
+                          value-format="yyyy-MM-dd"
+                          placeholder="选择提出日期">
+          </el-date-picker>
+        </el-form-item>
+        <el-form-item label="问题来源" prop="issueSource">
+          <el-select  v-model="form.issueSource"  placeholder="请选择问题来源" clearable style="width: 100%">
+            <el-option value="日常巡检" laabel="日常巡检"></el-option>
+            <el-option value="政府检查" laabel="政府检查"></el-option>
+            <el-option value="审计检查" laabel="审计检查"></el-option>
+            <el-option value="运行故障" laabel="运行故障"></el-option>
+            <el-option value="其他" laabel="其他"></el-option>
+          </el-select></el-form-item>
+        <el-form-item label="识别出的问题" prop="issueIdentified">
+          <el-input type="textarea" v-model="form.issueIdentified" placeholder="请输入识别出的问题"/>
+        </el-form-item>
+        <el-form-item label="要采取的措施" prop="actionsTaken">
+          <el-input type="textarea"  v-model="form.actionsTaken" placeholder="请输入要采取的措施"/>
+        </el-form-item>
+        <el-form-item label="问题类别" prop="issueClass">
+          <el-select  v-model="form.issueClass"  placeholder="请选择问题来源" clearable style="width: 100%">
+            <el-option value="设备" laabel="设备"></el-option>
+            <el-option value="电仪" laabel="电仪"></el-option>
+            <el-option value="安全措施" laabel="安全措施"></el-option>
+            <el-option value="其他" laabel="其他"></el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item label="负责部门 " prop="responsibleUnit">
+          <el-input v-model="form.responsibleUnit" placeholder="请输入负责人员"/>
+        </el-form-item>
+        <el-form-item label="负责人员" prop="responsiblePerson">
+          <el-input v-model="form.responsiblePerson" placeholder="请输入负责人员"/>
+        </el-form-item>
+        <el-form-item label="当前状态" prop="currentStates">
+          <el-select  v-model="form.currentStates" placeholder="请选择当前状态" clearable style="width: 100%">
+            <el-option value="已完成" laabel="已完成"></el-option>
+            <el-option value="未完成" laabel="未完成"></el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item label="预计完成日期" prop="expectedDate">
+          <el-date-picker clearable size="small"  style="width: 100%"
+                          v-model="form.expectedDate"
+                          type="date"
+                          value-format="yyyy-MM-dd"
+                          placeholder="选择预计完成日期">
+          </el-date-picker>
+        </el-form-item>
+        <el-form-item label="实际完成日期" prop="completionDate">
+          <el-date-picker clearable size="small"  style="width: 100%"
+                          v-model="form.completionDate"
+                          type="date"
+                          value-format="yyyy-MM-dd"
+                          placeholder="选择实际完成日期">
+          </el-date-picker>
+        </el-form-item>
+        <el-form-item label="备注" prop="remarks">
+          <el-input 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 :close-on-click-modal="false" v-dialogDrag :title="doc.title" :visible.sync="doc.open" width="700px"
+               append-to-body>
+      <el-upload
+        ref="doc"
+        :limit="50"
+        :headers="doc.headers"
+        :action="doc.url + '?pType=' + doc.pType + '&pId=' + doc.pId"
+        :disabled="doc.isUploading"
+        :on-progress="handleFileDocProgress"
+        :on-success="handleFileDocSuccess"
+        :auto-upload="true"
+        drag
+      >
+        <i class="el-icon-upload"></i>
+        <div class="el-upload__text">
+          {{ $t('将文件拖到此处,或') }}
+          <em>{{ $t('点击上传') }}</em>
+        </div>
+      </el-upload>
+      <el-table :data="doc.commonfileList" border>
+        <el-table-column :label="$t('文件名')" align="center" prop="fileName" :show-overflow-tooltip="true">
+          <template slot-scope="scope">
+            <a class="link-type" @click="handleDownload(scope.row)">
+              <span>{{ scope.row.fileName }}</span>
+            </a>
+          </template>
+        </el-table-column>
+        <el-table-column :label="$t('大小(Kb)')" align="center" prop="fileSize" :show-overflow-tooltip="true"
+                         width="80"/>
+        <el-table-column :label="$t('上传人')" align="center" prop="creator" :show-overflow-tooltip="true" width="120"/>
+        <el-table-column :label="$t('操作')" align="center" width="120" class-name="small-padding fixed-width">
+          <template slot-scope="scope">
+            <el-button
+              v-if="scope.row.fileName.endsWith('pdf')"
+              size="mini"
+              type="text"
+              icon="el-icon-view"
+              @click="handleSee(scope.row)"
+            >{{ $t('预览') }}
+            </el-button>
+            <el-button
+              size="mini"
+              type="text"
+              icon="el-icon-download"
+              @click="handleDownload(scope.row)"
+            >{{ $t('下载') }}
+            </el-button>
+            <el-button
+              size="mini"
+              type="text"
+              icon="el-icon-delete"
+              @click="handleDeleteDoc(scope.row)"
+            >{{ $t('删除') }}
+            </el-button>
+          </template>
+        </el-table-column>
+      </el-table>
+      <el-dialog :close-on-click-modal="false" v-dialogDrag :title="pdf.title" :visible.sync="pdf.open" width="1300px"
+                 append-to-body>
+        <div style="margin-top: -60px;float: right;margin-right: 40px;">
+          <el-button size="mini" type="text" @click="openPdf">{{ $t('新页面打开PDF') }}</el-button>
+        </div>
+        <div style="margin-top: -30px">
+          <iframe :src="pdf.pdfUrl" frameborder="0" width="100%" height="700px"></iframe>
+        </div>
+      </el-dialog>
+      <div slot="footer" class="dialog-footer">
+        <!--        <el-button type="primary" @click="submitFileForm">{{ $t('确 定') }}</el-button>-->
+        <el-button @click="doc.open = false">{{ $t('返 回') }}</el-button>
+      </div>
+    </el-dialog>
+    <!-- 用户导入对话框 -->
+    <el-dialog :close-on-click-modal="false" v-dialogDrag :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"
+        :disabled="upload.isUploading"
+        :on-progress="handleFileUploadProgress"
+        :on-success="handleFileSuccess"
+        :auto-upload="false"
+        drag
+      >
+        <i class="el-icon-upload"></i>
+        <div class="el-upload__text">
+          {{ $t('将文件拖到此处,或') }}
+          <em>{{ $t('点击上传') }}</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">{{ $t('下载模板') }}</el-link>
+        </div>
+        <form ref="downloadFileForm" :action="upload.downloadAction" target="FORMSUBMIT">
+          <input name="type" :value="upload.type" hidden/>
+        </form>
+        <div class="el-upload__tip" style="color:red" slot="tip">{{ $t('提示:仅允许导入“xls”或“xlsx”格式文件!') }}</div>
+      </el-upload>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitFileForm">{{ $t('确 定') }}</el-button>
+        <el-button @click="upload.open = false">{{ $t('取 消') }}</el-button>
+      </div>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import {
+  addIssuelist,
+  delIssuelist,
+  exportIssuelist,
+  getIssuelist,
+  listIssuelist,
+  updateIssuelist
+} from "@/api/issue/issuelist";
+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 {allFileList, delCommonfile} from "@/api/common/commonfile";
+
+export default {
+  name: "IssuelistIB",
+  components: {Treeselect},
+  data() {
+    return {
+      // 遮罩层
+      loading: true,
+      // 选中数组
+      ids: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: false,
+      // 总条数
+      total: 0,
+      // 装置问题滚动清单表格数据
+      issuelistList: [],
+      // 弹出层标题
+      title: "",
+      // 部门树选项
+      deptOptions: undefined,
+      clientHeight: 300,
+      // 是否显示弹出层
+      open: false,
+      // 用户导入参数
+      upload: {
+        downloadAction: process.env.VUE_APP_BASE_API + '/common/template',
+        //下载模板类型
+        type: "issuelist",
+        // 是否显示弹出层(用户导入)
+        open: false,
+        // 弹出层标题(用户导入)
+        title: "",
+        // 是否禁用上传
+        isUploading: false,
+        // 是否更新已经存在的用户数据
+        updateSupport: 0,
+        // 设置上传的请求头部
+        headers: {Authorization: "Bearer " + getToken()},
+        // 上传的地址
+        url: process.env.VUE_APP_BASE_API + "/issue/issuelist/importData"
+      },
+      // 报告附件参数
+      doc: {
+        file: "",
+        // 是否显示弹出层(报告附件)
+        open: false,
+        // 弹出层标题(报告附件)
+        title: "",
+        // 是否禁用上传
+        isUploading: false,
+        // 是否更新已经存在的用户数据
+        updateSupport: 0,
+        // 报告附件上传位置编号
+        ids: 0,
+        // 设置上传的请求头部
+        headers: {Authorization: "Bearer " + getToken()},
+        // 上传的地址
+        url: process.env.VUE_APP_BASE_API + "/common/commonfile/uploadFile",
+        commonfileList: null,
+        queryParams: {
+          pId: null,
+          pType: 'issuelist'
+        },
+        pType: 'issuelist',
+        pId: null
+      },
+      pdf : {
+        title: '',
+        pdfUrl: '',
+        numPages: null,
+        open: false,
+        pageNum: 1,
+        pageTotalNum: 1,
+        loadedRatio: 0,
+      },
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 20,
+        plant: 'IB',
+        area: null,
+        identifiedDate: null,
+        identifiedDateStr: new Date().getFullYear().toString(),
+        issueSource: null,
+        issueIdentified: null,
+        actionsTaken: null,
+        issueClass: null,
+        responsiblePerson: null,
+        responsibleUnit: null,
+        currentStates: null,
+        completionDate: null,
+        additionalDeadline: null,
+        createrCode: null,
+        createdate: null,
+        updaterCode: null,
+        updatedate: null,
+        deptId: null,
+        remarks: null
+      },
+      // 表单参数
+      form: {},
+      // 表单校验
+      rules: {
+        area: [
+          {required: true, message: "请选择区域", trigger: "blur"}
+        ],
+        identifiedDate: [
+          {required: true, message: "请选择提出时间", trigger: "blur"}
+        ],
+        issueSource: [
+          {required: true, message: "请选择问题来源", trigger: "blur"}
+        ],
+        issueIdentified: [
+          {required: true, message: "识别出的问题不能为空", trigger: "blur"}
+        ],
+        actionsTaken: [
+          {required: true, message: "要采取的措施不能为空", trigger: "blur"}
+        ],
+        issueClass: [
+          {required: true, message: "请选择问题类别", trigger: "blur"}
+        ],
+        responsiblePerson: [
+          {required: true, message: "负责人员不能为空", trigger: "blur"}
+        ],
+        responsibleUnit: [
+          {required: true, message: "负责部门不能为空", trigger: "blur"}
+        ],
+        currentStates: [
+          {required: true, message: "请选择当前状态", trigger: "blur"}
+        ],
+        expectedDate: [
+          {required: true, message: "请选择预计完成日期", trigger: "blur"}
+        ],
+      }
+    };
+  },
+  watch: {
+    // 根据名称筛选部门树
+    deptName(val) {
+      this.$refs.tree.filter(val);
+    }
+  },
+  created() {
+    //设置表格高度对应屏幕高度
+    this.$nextTick(() => {
+      this.clientHeight = document.body.clientHeight - 330
+    })
+    this.getList();
+    this.getTreeselect();
+  },
+  methods: {
+    /** 查询装置问题滚动清单列表 */
+    getList() {
+      this.loading = true;
+      listIssuelist(this.queryParams).then(response => {
+        this.issuelistList = 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,
+        plant: 'IB',
+        area: null,
+        identifiedDate: null,
+        issueSource: null,
+        issueIdentified: null,
+        actionsTaken: null,
+        issueClass: null,
+        responsiblePerson: null,
+        responsibleUnit: null,
+        currentStates: null,
+        completionDate: null,
+        expectedDate: null,
+        additionalDeadline: null,
+        delFlag: null,
+        createrCode: null,
+        createdate: null,
+        updaterCode: null,
+        updatedate: null,
+        deptId: null,
+        remarks: 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
+      getIssuelist(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) {
+            updateIssuelist(this.form).then(response => {
+              this.msgSuccess("修改成功");
+              this.open = false;
+              this.getList();
+            });
+          } else {
+            addIssuelist(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 delIssuelist(ids);
+      }).then(() => {
+        this.getList();
+        this.msgSuccess("删除成功");
+      })
+    },
+    /** 导出按钮操作 */
+    handleExport() {
+      const queryParams = this.queryParams;
+      this.$confirm('是否确认导出所有装置问题滚动清单数据项?', "警告", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning"
+      }).then(function () {
+        return exportIssuelist(queryParams);
+      }).then(response => {
+        this.download(response.msg);
+      })
+    },
+    /** 导入按钮操作 */
+    handleImport() {
+      this.upload.title = "用户导入";
+      this.upload.open = true;
+    },
+    /** 下载模板操作 */
+    importTemplate() {
+      this.$refs['downloadFileForm'].submit()
+    },
+    // 文件上传中处理
+    handleFileUploadProgress(event, file, fileList) {
+      this.upload.isUploading = true;
+    },
+    // 文件上传成功处理
+    handleFileSuccess(response, file, fileList) {
+      this.upload.open = false;
+      this.upload.isUploading = false;
+      this.$refs.upload.clearFiles();
+      if (response.data[0] != null) {
+        this.$alert(this.$t('成功导入') + response.msg + this.$t('条数据') + "," + this.$t('第') + response.data + this.$t('行数据出现错误导入失败') + "。", this.$t('导入结果'), {dangerouslyUseHTMLString: true});
+      } else {
+        this.$alert(this.$t('成功导入') + response.msg + this.$t('条数据'), this.$t('导入结果'), {dangerouslyUseHTMLString: true});
+      }
+      this.getList();
+    },
+    // 提交上传文件
+    submitFileForm() {
+      this.$refs.upload.submit();
+    },
+    /** 报告附件按钮操作 */
+    handleDoc(row) {
+      this.doc.id = row.id;
+      this.doc.title = this.$t('附件');
+      this.doc.open = true;
+      this.doc.queryParams.pId = row.id
+      this.doc.pId = row.id
+      this.getFileList()
+      this.$nextTick(() => {
+        this.$refs.doc.clearFiles()
+      })
+    },
+    getFileList() {
+      allFileList(this.doc.queryParams).then(response => {
+        this.doc.commonfileList = response;
+      });
+    },
+    //附件上传中处理
+    handleFileDocProgress(event, file, fileList) {
+      this.doc.file = file;
+      this.doc.isUploading = true;
+    },
+    //附件上传成功处理
+    handleFileDocSuccess(response, file, fileList) {
+      this.doc.isUploading = false;
+      this.$alert(response.msg, this.$t('导入结果'), {dangerouslyUseHTMLString: true});
+      this.getFileList()
+    },
+    /** 删除按钮操作 */
+    handleDeleteDoc(row) {
+      const ids = row.id || this.ids;
+      this.$confirm(this.$t('是否确认删除?'), this.$t('警告'), {
+        confirmButtonText: this.$t('确定'),
+        cancelButtonText: this.$t('取消'),
+        type: "warning"
+      }).then(function () {
+        return delCommonfile(ids);
+      }).then(() => {
+        this.getFileList()
+        this.msgSuccess(this.$t('删除成功'));
+      })
+    },
+    // 文件下载处理
+    handleDownload(row) {
+      var name = row.fileName;
+      var url = row.fileUrl;
+      var suffix = url.substring(url.lastIndexOf("."), url.length);
+      const a = document.createElement('a')
+      a.setAttribute('download', name)
+      a.setAttribute('target', '_blank')
+      a.setAttribute('href', process.env.VUE_APP_BASE_API + url)
+      a.click()
+    },
+    openPdf() {
+      window.open(this.pdf.pdfUrl);//path是文件的全路径地址
+    },
+    handleSee(row) {
+      this.pdf.open = true
+      this.pdf.title = row.fileName
+      this.pdf.pdfUrl = process.env.VUE_APP_BASE_API + '/pdf/web/viewer.html?file=' + process.env.VUE_APP_BASE_API + row.fileUrl
+    },
+
+    // 计算日期差(天数)
+    getDateDiff(date) {
+      const today = new Date();
+      today.setHours(0, 0, 0, 0);
+
+      const targetDate = new Date(date);
+      targetDate.setHours(0, 0, 0, 0);
+
+      const diffTime = targetDate.getTime() - today.getTime();
+      return Math.ceil(diffTime / (1000 * 60 * 60 * 24));
+    },
+
+    // 设置行样式
+    tableRowClassName({ row,rowIndex }) {
+      if (!row.expectedDate||row.currentStates!=='未完成'){
+        return '';
+      }
+      const diffDays = this.getDateDiff(row.expectedDate);
+      console.log(diffDays)
+      if (diffDays <= 0) {
+        return 'danger-row';
+      } else if (diffDays < 15) {
+        return 'warning-row';
+      }
+      return '';
+    },
+    //翻页后继续计算序列值
+    indexMethod(index) {
+      return (this.queryParams.pageNum-1)*this.queryParams.pageSize+index+1;
+    }
+  }
+};
+</script>
+
+<style>
+
+.el-table .warning-row {
+  background: #ffff00 ;
+}
+.el-table .danger-row {
+  background: #ff0000 ;
+}
+</style>

+ 34 - 644
ui/src/views/issue/issuelist/index.vue

@@ -1,662 +1,52 @@
 <template>
   <div class="app-container">
-    <el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" label-width="68px">
-      <el-form-item label="归属装置" prop="plant">
-        <el-select v-model="queryParams.plant" placeholder="请选择装置" clearable size="small" style="width: 240px">
-          <el-option value="BD">BD</el-option>
-          <el-option value="IB">IB</el-option>
-        </el-select>
-      </el-form-item>
-      <el-form-item label="区域" prop="area">
-        <el-input
-          v-model="queryParams.area"
-          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="['issue:issuelist: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="['issue:issuelist: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="['issue:issuelist:remove']"
-        >删除
-        </el-button>
-      </el-col>
-      <el-col :span="1.5">
-        <el-button
-          type="info"
-          icon="el-icon-upload2"
-          size="mini"
-          @click="handleImport"
-          v-hasPermi="['issue:issuelist:edit']"
-        >导入
-        </el-button>
-      </el-col>
-      <el-col :span="1.5">
-        <el-button
-          type="warning"
-          icon="el-icon-download"
-          size="mini"
-          @click="handleExport"
-          v-hasPermi="['issue:issuelist:export']"
-        >导出
-        </el-button>
-      </el-col>
-      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
-    </el-row>
-
-    <el-table v-loading="loading" :data="issuelistList" @selection-change="handleSelectionChange" :height="clientHeight"
-              border >
-      <el-table-column type="selection" width="55" align="center"/>
-      <el-table-column label="归属装置" align="center" prop="plant" :show-overflow-tooltip="true" width="150"/>
-      <el-table-column label="区域" align="center" prop="area" :show-overflow-tooltip="true" width="150"/>
-      <el-table-column label="提出日期" align="center" prop="identifiedDate" width="100">
-        <template slot-scope="scope">
-          <span>{{ parseTime(scope.row.identifiedDate, '{y}-{m}-{d}') }}</span>
-        </template>
-      </el-table-column>
-      <el-table-column label="问题来源" align="center" prop="issueSource" :show-overflow-tooltip="true" width="150"/>
-      <el-table-column label="识别出的问题" align="center" prop="issueIdentified" :show-overflow-tooltip="true"
-                       width="150"/>
-      <el-table-column label="要采取的措施" align="center" prop="actionsTaken" :show-overflow-tooltip="true"
-                       width="150"/>
-      <el-table-column label="问题类别" align="center" prop="issueClass" :show-overflow-tooltip="true" width="150"/>
-      <el-table-column label="负责部门" align="center" prop="responsibleUnit" :show-overflow-tooltip="true"
-                       width="150"/>
-      <el-table-column label="负责人员" align="center" prop="responsiblePerson" :show-overflow-tooltip="true"
-                       width="150"/>
-      <el-table-column label="当前状态" align="center" prop="currentStates" :show-overflow-tooltip="true" width="150"/>
-      <el-table-column label="完成日期" align="center" prop="completionDate" :show-overflow-tooltip="true" width="150"/>
-      <el-table-column label="未按期完成时,所要采取的额外" align="center" prop="additionalDeadline"
-                       :show-overflow-tooltip="true"/>
-      <el-table-column label="备注" align="center" prop="remarks" :show-overflow-tooltip="true" width="150"/>
-      <el-table-column label="操作" align="center" fixed="right" width="160" class-name="small-padding fixed-width">
-        <template slot-scope="scope">
-          <el-button
-            size="mini"
-            type="text"
-            icon="el-icon-edit"
-            @click="handleUpdate(scope.row)"
-            v-hasPermi="['issue:issuelist:edit']"
-          >修改
-          </el-button>
-          <el-button
-            size="mini"
-            type="text"
-            icon="el-icon-delete"
-            @click="handleDelete(scope.row)"
-            v-hasPermi="['issue:issuelist:remove']"
-          >删除
-          </el-button>
-          <el-button
-            size="mini"
-            type="text"
-            icon="el-icon-document"
-            @click="handleDoc(scope.row)"
-            v-hasPermi="['issue:issuelist:edit']"
-          >{{ $t('附件') }}</el-button>
-        </template>
-      </el-table-column>
-    </el-table>
-
-    <pagination
-      v-show="total>0"
-      :total="total"
-      :page.sync="queryParams.pageNum"
-      :limit.sync="queryParams.pageSize"
-      @pagination="getList"
-    />
-
-    <!-- 添加或修改问题清单和行动计划对话框 -->
-    <el-dialog :title="title" :visible.sync="open" width="600px" append-to-body :close-on-click-modal="false">
-      <el-form ref="form" :model="form" :rules="rules" label-width="180px">
-        <el-form-item label="归属装置" prop="plant">
-          <el-select v-model="form.plant" placeholder="请选择装置" clearable size="small" style="width: 240px">
-            <el-option value="BD">BD</el-option>
-            <el-option value="IB">IB</el-option>
-          </el-select>
-        </el-form-item>
-        <el-form-item label="区域" prop="area">
-          <el-input v-model="form.area" placeholder="请输入区域"/>
-        </el-form-item>
-        <el-form-item label="提出日期" prop="identifiedDate">
-          <el-date-picker clearable size="small" style="width: 200px"
-                          v-model="form.identifiedDate"
-                          type="date"
-                          value-format="yyyy-MM-dd"
-                          placeholder="选择提出日期">
-          </el-date-picker>
-        </el-form-item>
-        <el-form-item label="问题来源" prop="issueSource">
-          <el-input v-model="form.issueSource" placeholder="请输入问题来源"/>
-        </el-form-item>
-        <el-form-item label="识别出的问题" prop="issueIdentified">
-          <el-input v-model="form.issueIdentified" placeholder="请输入识别出的问题"/>
-        </el-form-item>
-        <el-form-item label="要采取的措施" prop="actionsTaken">
-          <el-input v-model="form.actionsTaken" placeholder="请输入要采取的措施"/>
-        </el-form-item>
-        <el-form-item label="问题类别" prop="issueClass">
-          <el-input v-model="form.issueClass" placeholder="请输入问题类别"/>
-        </el-form-item>
-        <el-form-item label="负责部门 " prop="responsibleUnit">
-          <el-input v-model="form.responsibleUnit" placeholder="请输入负责人员"/>
-        </el-form-item>
-        <el-form-item label="负责人员" prop="responsiblePerson">
-          <el-input v-model="form.responsiblePerson" placeholder="请输入负责人员"/>
-        </el-form-item>
-        <el-form-item label="当前状态" prop="currentStates">
-          <el-input v-model="form.currentStates" placeholder="请输入当前状态"/>
-        </el-form-item>
-        <el-form-item label="完成日期" prop="completionDate">
-          <el-input v-model="form.completionDate" placeholder="请输入完成日期"/>
-        </el-form-item>
-        <el-form-item label="未按期完成时,所要采取的额外" prop="additionalDeadline">
-          <el-input v-model="form.additionalDeadline" placeholder="请输入未按期完成时,所要采取的额外"/>
-        </el-form-item>
-        <el-form-item label="备注" prop="remarks">
-          <el-input 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 :close-on-click-modal="false" v-dialogDrag :title="doc.title" :visible.sync="doc.open" width="700px"
-               append-to-body>
-      <el-upload
-        ref="doc"
-        :limit="50"
-        :headers="doc.headers"
-        :action="doc.url + '?pType=' + doc.pType + '&pId=' + doc.pId"
-        :disabled="doc.isUploading"
-        :on-progress="handleFileDocProgress"
-        :on-success="handleFileDocSuccess"
-        :auto-upload="true"
-        drag
-      >
-        <i class="el-icon-upload"></i>
-        <div class="el-upload__text">
-          {{ $t('将文件拖到此处,或') }}
-          <em>{{ $t('点击上传') }}</em>
-        </div>
-      </el-upload>
-      <el-table :data="doc.commonfileList" border>
-        <el-table-column :label="$t('文件名')" align="center" prop="fileName" :show-overflow-tooltip="true">
-          <template slot-scope="scope">
-            <a class="link-type" @click="handleDownload(scope.row)">
-              <span>{{ scope.row.fileName }}</span>
-            </a>
-          </template>
-        </el-table-column>
-        <el-table-column :label="$t('大小(Kb)')" align="center" prop="fileSize" :show-overflow-tooltip="true"
-                         width="80"/>
-        <el-table-column :label="$t('上传人')" align="center" prop="creator" :show-overflow-tooltip="true" width="120"/>
-        <el-table-column :label="$t('操作')" align="center" width="120" class-name="small-padding fixed-width">
-          <template slot-scope="scope">
-            <el-button
-              v-if="scope.row.fileName.endsWith('pdf')"
-              size="mini"
-              type="text"
-              icon="el-icon-view"
-              @click="handleSee(scope.row)"
-            >{{ $t('预览') }}
-            </el-button>
-            <el-button
-              size="mini"
-              type="text"
-              icon="el-icon-download"
-              @click="handleDownload(scope.row)"
-            >{{ $t('下载') }}
-            </el-button>
-            <el-button
-              size="mini"
-              type="text"
-              icon="el-icon-delete"
-              @click="handleDeleteDoc(scope.row)"
-            >{{ $t('删除') }}
-            </el-button>
-          </template>
-        </el-table-column>
-      </el-table>
-      <el-dialog :close-on-click-modal="false" v-dialogDrag :title="pdf.title" :visible.sync="pdf.open" width="1300px"
-                 append-to-body>
-        <div style="margin-top: -60px;float: right;margin-right: 40px;">
-          <el-button size="mini" type="text" @click="openPdf">{{ $t('新页面打开PDF') }}</el-button>
-        </div>
-        <div style="margin-top: -30px">
-          <iframe :src="pdf.pdfUrl" frameborder="0" width="100%" height="700px"></iframe>
-        </div>
-      </el-dialog>
-      <div slot="footer" class="dialog-footer">
-        <!--        <el-button type="primary" @click="submitFileForm">{{ $t('确 定') }}</el-button>-->
-        <el-button @click="doc.open = false">{{ $t('返 回') }}</el-button>
-      </div>
-    </el-dialog>
-    <!-- 用户导入对话框 -->
-    <el-dialog :close-on-click-modal="false" v-dialogDrag :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"
-        :disabled="upload.isUploading"
-        :on-progress="handleFileUploadProgress"
-        :on-success="handleFileSuccess"
-        :auto-upload="false"
-        drag
-      >
-        <i class="el-icon-upload"></i>
-        <div class="el-upload__text">
-          {{ $t('将文件拖到此处,或') }}
-          <em>{{ $t('点击上传') }}</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">{{ $t('下载模板') }}</el-link>
-        </div>
-        <form ref="downloadFileForm" :action="upload.downloadAction" target="FORMSUBMIT">
-          <input name="type" :value="upload.type" hidden/>
-        </form>
-        <div class="el-upload__tip" style="color:red" slot="tip">{{ $t('提示:仅允许导入“xls”或“xlsx”格式文件!') }}</div>
-      </el-upload>
-      <div slot="footer" class="dialog-footer">
-        <el-button type="primary" @click="submitFileForm">{{ $t('确 定') }}</el-button>
-        <el-button @click="upload.open = false">{{ $t('取 消') }}</el-button>
-      </div>
-    </el-dialog>
+    <el-tabs v-model="activeName" type="card" @tab-click="handleClick">
+      <el-tab-pane label="BD" name="first">
+        <IssuelistBD v-if="isFirst"></IssuelistBD>
+      </el-tab-pane>
+      <el-tab-pane label="IB" name="second">
+        <IssuelistIB v-if="isSecond"></IssuelistIB>
+      </el-tab-pane>
+      <el-tab-pane label="EBSM" name="third">
+        <IssuelistEBSM v-if="isThird"></IssuelistEBSM>
+      </el-tab-pane>
+    </el-tabs>
   </div>
 </template>
 
 <script>
-import {
-  addIssuelist,
-  delIssuelist,
-  exportIssuelist,
-  getIssuelist,
-  listIssuelist,
-  updateIssuelist
-} from "@/api/issue/issuelist";
-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 {allFileList, delCommonfile} from "@/api/common/commonfile";
+
+import IssuelistBD from "./bd.vue";
+import IssuelistEBSM from "./ebsm.vue";
+import IssuelistIB from "./ib.vue";
 
 export default {
   name: "Issuelist",
-  components: {Treeselect},
+  components: {IssuelistIB, IssuelistEBSM, IssuelistBD},
   data() {
     return {
-      // 遮罩层
-      loading: true,
-      // 选中数组
-      ids: [],
-      // 非单个禁用
-      single: true,
-      // 非多个禁用
-      multiple: true,
-      // 显示搜索条件
-      showSearch: false,
-      // 总条数
-      total: 0,
-      // 问题清单和行动计划表格数据
-      issuelistList: [],
-      // 弹出层标题
-      title: "",
-      // 部门树选项
-      deptOptions: undefined,
-      clientHeight: 300,
-      // 是否显示弹出层
-      open: false,
-      // 用户导入参数
-      upload: {
-        downloadAction: process.env.VUE_APP_BASE_API + '/common/template',
-        //下载模板类型
-        type: "issuelist",
-        // 是否显示弹出层(用户导入)
-        open: false,
-        // 弹出层标题(用户导入)
-        title: "",
-        // 是否禁用上传
-        isUploading: false,
-        // 是否更新已经存在的用户数据
-        updateSupport: 0,
-        // 设置上传的请求头部
-        headers: {Authorization: "Bearer " + getToken()},
-        // 上传的地址
-        url: process.env.VUE_APP_BASE_API + "/issue/issuelist/importData"
-      },
-      // 报告附件参数
-      doc: {
-        file: "",
-        // 是否显示弹出层(报告附件)
-        open: false,
-        // 弹出层标题(报告附件)
-        title: "",
-        // 是否禁用上传
-        isUploading: false,
-        // 是否更新已经存在的用户数据
-        updateSupport: 0,
-        // 报告附件上传位置编号
-        ids: 0,
-        // 设置上传的请求头部
-        headers: {Authorization: "Bearer " + getToken()},
-        // 上传的地址
-        url: process.env.VUE_APP_BASE_API + "/common/commonfile/uploadFile",
-        commonfileList: null,
-        queryParams: {
-          pId: null,
-          pType: 'issuelist'
-        },
-        pType: 'issuelist',
-        pId: null
-      },
-      pdf : {
-        title: '',
-        pdfUrl: '',
-        numPages: null,
-        open: false,
-        pageNum: 1,
-        pageTotalNum: 1,
-        loadedRatio: 0,
-      },
-      // 查询参数
-      queryParams: {
-        pageNum: 1,
-        pageSize: 20,
-        plant: null,
-        area: null,
-        identifiedDate: null,
-        issueSource: null,
-        issueIdentified: null,
-        actionsTaken: null,
-        issueClass: null,
-        responsiblePerson: null,
-        responsibleUnit: null,
-        currentStates: null,
-        completionDate: null,
-        additionalDeadline: null,
-        createrCode: null,
-        createdate: null,
-        updaterCode: null,
-        updatedate: null,
-        deptId: null,
-        remarks: null
-      },
-      // 表单参数
-      form: {},
-      // 表单校验
-      rules: {}
+      activeName: 'first',
+      isFirst: true,
+      isSecond: false,
+      isThird: false
     };
   },
-  watch: {
-    // 根据名称筛选部门树
-    deptName(val) {
-      this.$refs.tree.filter(val);
-    }
-  },
-  created() {
-    //设置表格高度对应屏幕高度
-    this.$nextTick(() => {
-      this.clientHeight = document.body.clientHeight - 250
-    })
-    this.getList();
-    this.getTreeselect();
-  },
   methods: {
-    /** 查询问题清单和行动计划列表 */
-    getList() {
-      this.loading = true;
-      listIssuelist(this.queryParams).then(response => {
-        this.issuelistList = 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,
-        plant: null,
-        area: null,
-        identifiedDate: null,
-        issueSource: null,
-        issueIdentified: null,
-        actionsTaken: null,
-        issueClass: null,
-        responsiblePerson: null,
-        responsibleUnit: null,
-        currentStates: null,
-        completionDate: null,
-        additionalDeadline: null,
-        delFlag: null,
-        createrCode: null,
-        createdate: null,
-        updaterCode: null,
-        updatedate: null,
-        deptId: null,
-        remarks: 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
-      getIssuelist(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) {
-            updateIssuelist(this.form).then(response => {
-              this.msgSuccess("修改成功");
-              this.open = false;
-              this.getList();
-            });
-          } else {
-            addIssuelist(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 delIssuelist(ids);
-      }).then(() => {
-        this.getList();
-        this.msgSuccess("删除成功");
-      })
-    },
-    /** 导出按钮操作 */
-    handleExport() {
-      const queryParams = this.queryParams;
-      this.$confirm('是否确认导出所有问题清单和行动计划数据项?', "警告", {
-        confirmButtonText: "确定",
-        cancelButtonText: "取消",
-        type: "warning"
-      }).then(function () {
-        return exportIssuelist(queryParams);
-      }).then(response => {
-        this.download(response.msg);
-      })
-    },
-    /** 导入按钮操作 */
-    handleImport() {
-      this.upload.title = "用户导入";
-      this.upload.open = true;
-    },
-    /** 下载模板操作 */
-    importTemplate() {
-      this.$refs['downloadFileForm'].submit()
-    },
-    // 文件上传中处理
-    handleFileUploadProgress(event, file, fileList) {
-      this.upload.isUploading = true;
-    },
-    // 文件上传成功处理
-    handleFileSuccess(response, file, fileList) {
-      this.upload.open = false;
-      this.upload.isUploading = false;
-      this.$refs.upload.clearFiles();
-      if (response.data[0] != null) {
-        this.$alert(this.$t('成功导入') + response.msg + this.$t('条数据') + "," + this.$t('第') + response.data + this.$t('行数据出现错误导入失败') + "。", this.$t('导入结果'), {dangerouslyUseHTMLString: true});
-      } else {
-        this.$alert(this.$t('成功导入') + response.msg + this.$t('条数据'), this.$t('导入结果'), {dangerouslyUseHTMLString: true});
+    handleClick(tab){
+      if(tab.name == 'first'){
+        this.isFirst = true;
+        this.isSecond = false;
+        this.isThird = false;
+      }else if(tab.name == 'second'){
+        this.isFirst = false;
+        this.isSecond = true;
+        this.isThird = false;
+      }else if(tab.name == 'third'){
+        this.isFirst = false;
+        this.isSecond = false;
+        this.isThird = true;
       }
-      this.getList();
-    },
-    // 提交上传文件
-    submitFileForm() {
-      this.$refs.upload.submit();
-    },
-    /** 报告附件按钮操作 */
-    handleDoc(row) {
-      this.doc.id = row.id;
-      this.doc.title = this.$t('附件');
-      this.doc.open = true;
-      this.doc.queryParams.pId = row.id
-      this.doc.pId = row.id
-      this.getFileList()
-      this.$nextTick(() => {
-        this.$refs.doc.clearFiles()
-      })
-    },
-    getFileList() {
-      allFileList(this.doc.queryParams).then(response => {
-        this.doc.commonfileList = response;
-      });
-    },
-    //附件上传中处理
-    handleFileDocProgress(event, file, fileList) {
-      this.doc.file = file;
-      this.doc.isUploading = true;
-    },
-    //附件上传成功处理
-    handleFileDocSuccess(response, file, fileList) {
-      this.doc.isUploading = false;
-      this.$alert(response.msg, this.$t('导入结果'), {dangerouslyUseHTMLString: true});
-      this.getFileList()
-    },
-    /** 删除按钮操作 */
-    handleDeleteDoc(row) {
-      const ids = row.id || this.ids;
-      this.$confirm(this.$t('是否确认删除?'), this.$t('警告'), {
-        confirmButtonText: this.$t('确定'),
-        cancelButtonText: this.$t('取消'),
-        type: "warning"
-      }).then(function () {
-        return delCommonfile(ids);
-      }).then(() => {
-        this.getFileList()
-        this.msgSuccess(this.$t('删除成功'));
-      })
-    },
-    // 文件下载处理
-    handleDownload(row) {
-      var name = row.fileName;
-      var url = row.fileUrl;
-      var suffix = url.substring(url.lastIndexOf("."), url.length);
-      const a = document.createElement('a')
-      a.setAttribute('download', name)
-      a.setAttribute('target', '_blank')
-      a.setAttribute('href', process.env.VUE_APP_BASE_API + url)
-      a.click()
-    },
-    openPdf() {
-      window.open(this.pdf.pdfUrl);//path是文件的全路径地址
-    },
-    handleSee(row) {
-      this.pdf.open = true
-      this.pdf.title = row.fileName
-      this.pdf.pdfUrl = process.env.VUE_APP_BASE_API + '/pdf/web/viewer.html?file=' + process.env.VUE_APP_BASE_API + row.fileUrl
-    },
+    }
   }
 };
 </script>

+ 652 - 0
ui/src/views/issue/operationlist/bd.vue

@@ -0,0 +1,652 @@
+<template>
+  <div class="app-container">
+    <el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" label-width="68px">
+      <el-form-item label="时间" prop="identifiedDateStr">
+        <el-date-picker clearable size="small" style="width: 200px"
+                        v-model="queryParams.identifiedDateStr"
+                        type="year"
+                        @change="handleQuery"
+                        value-format="yyyy"
+                        placeholder="选择提出日期">
+        </el-date-picker>
+      </el-form-item>
+      <el-form-item label="事件描述" prop="incidentDescription">
+        <el-input
+          v-model="queryParams.incidentDescription"
+          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="['issue:operationlist: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="['issue:operationlist: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="['issue:operationlist:remove']"
+        >删除
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="info"
+          icon="el-icon-upload2"
+          size="mini"
+          @click="handleImport"
+          v-hasPermi="['issue:operationlist:edit']"
+        >导入
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="warning"
+          icon="el-icon-download"
+          size="mini"
+          @click="handleExport"
+          v-hasPermi="['issue:operationlist:export']"
+        >导出
+        </el-button>
+      </el-col>
+      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+    </el-row>
+
+    <el-table v-loading="loading" :data="operationlistList" @selection-change="handleSelectionChange"
+              :height="clientHeight" border>
+      <el-table-column type="selection" width="55" align="center"/>
+      <el-table-column type="index" label="序号"  width="55" align="center" :index="indexMethod"/>
+      <el-table-column label="时间" align="center" prop="identifiedDate" :show-overflow-tooltip="true"/>
+      <el-table-column label="班组" align="center" prop="shiftClass" :show-overflow-tooltip="true"/>
+      <el-table-column label="事件分类" align="center" prop="incidentType" :show-overflow-tooltip="true"/>
+      <el-table-column label="事件描述" align="center" prop="incidentDescription" :show-overflow-tooltip="true"/>
+      <el-table-column label="原因" align="center" prop="causeRes" :show-overflow-tooltip="true"/>
+      <el-table-column label="措施" align="center" prop="coutermeasures" :show-overflow-tooltip="true"/>
+      <el-table-column label="备注" align="center" prop="remarks" :show-overflow-tooltip="true"/>
+      <el-table-column label="操作" align="center" fixed="right" width="160" class-name="small-padding fixed-width">
+        <template slot-scope="scope">
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-edit"
+            @click="handleUpdate(scope.row)"
+            v-hasPermi="['issue:operationlist:edit']"
+          >修改
+          </el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-delete"
+            @click="handleDelete(scope.row)"
+            v-hasPermi="['issue:operationlist:remove']"
+          >删除
+          </el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-document"
+            @click="handleDoc(scope.row)"
+            v-hasPermi="['issue:operationlist:edit']"
+          >{{ $t('附件') }}
+          </el-button>
+        </template>
+      </el-table-column>
+    </el-table>
+
+    <pagination
+      v-show="total>0"
+      :total="total"
+      :page.sync="queryParams.pageNum"
+      :limit.sync="queryParams.pageSize"
+      @pagination="getList"
+    />
+
+    <!-- 添加或修改CBPB工艺事件清单对话框 -->
+    <el-dialog :title="title" :visible.sync="open" width="60%" append-to-body :close-on-click-modal="false">
+      <el-form ref="form" :model="form" :rules="rules" label-width="80px">
+        <el-form-item label="时间" prop="identifiedDate">
+          <el-date-picker clearable size="small" style="width: 100%"
+                          v-model="form.identifiedDate"
+                          type="date"
+                          value-format="yyyy-MM-dd"
+                          placeholder="选择时间">
+          </el-date-picker>
+        </el-form-item>
+        <el-form-item label="班组" prop="shiftClass">
+          <el-select v-model="form.shiftClass" placeholder="请选择班组" clearable style="width: 100%">
+            <el-option value="A" laabel="A"></el-option>
+            <el-option value="B" laabel="B"></el-option>
+            <el-option value="C" laabel="C"></el-option>
+            <el-option value="D" laabel="D"></el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item label="事件分类" prop="incidentType">
+          <el-select v-model="form.incidentType" placeholder="请选择事件分类" clearable style="width: 100%">
+            <el-option value="工艺" laabel="工艺"></el-option>
+            <el-option value="仪表" laabel="仪表"></el-option>
+            <el-option value="其他" laabel="其他"></el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item label="事件描述" prop="incidentDescription">
+          <el-input v-model="form.incidentDescription" type="textarea" placeholder="请输入事件描述"/>
+        </el-form-item>
+        <el-form-item label="原因" prop="causeRes">
+          <el-input v-model="form.causeRes" type="textarea" placeholder="请输入原因"/>
+        </el-form-item>
+        <el-form-item label="措施" prop="coutermeasures">
+          <el-input v-model="form.coutermeasures" type="textarea" placeholder="请输入措施"/>
+        </el-form-item>
+        <el-form-item label="备注" prop="remarks">
+          <el-input 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 :close-on-click-modal="false" v-dialogDrag :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"
+        :disabled="upload.isUploading"
+        :on-progress="handleFileUploadProgress"
+        :on-success="handleFileSuccess"
+        :auto-upload="false"
+        drag
+      >
+        <i class="el-icon-upload"></i>
+        <div class="el-upload__text">
+          {{ $t('将文件拖到此处,或') }}
+          <em>{{ $t('点击上传') }}</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">{{ $t('下载模板') }}</el-link>
+        </div>
+        <form ref="downloadFileForm" :action="upload.downloadAction" target="FORMSUBMIT">
+          <input name="type" :value="upload.type" hidden/>
+        </form>
+        <div class="el-upload__tip" style="color:red" slot="tip">{{ $t('提示:仅允许导入“xls”或“xlsx”格式文件!') }}</div>
+      </el-upload>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitFileForm">{{ $t('确 定') }}</el-button>
+        <el-button @click="upload.open = false">{{ $t('取 消') }}</el-button>
+      </div>
+    </el-dialog><!-- 报告附件对话框 -->
+    <el-dialog :close-on-click-modal="false" v-dialogDrag :title="doc.title" :visible.sync="doc.open" width="700px"
+               append-to-body>
+      <el-upload
+        ref="doc"
+        :limit="50"
+        :headers="doc.headers"
+        :action="doc.url + '?pType=' + doc.pType + '&pId=' + doc.pId"
+        :disabled="doc.isUploading"
+        :on-progress="handleFileDocProgress"
+        :on-success="handleFileDocSuccess"
+        :auto-upload="true"
+        drag
+      >
+        <i class="el-icon-upload"></i>
+        <div class="el-upload__text">
+          {{ $t('将文件拖到此处,或') }}
+          <em>{{ $t('点击上传') }}</em>
+        </div>
+      </el-upload>
+      <el-table :data="doc.commonfileList" border>
+        <el-table-column :label="$t('文件名')" align="center" prop="fileName" :show-overflow-tooltip="true">
+          <template slot-scope="scope">
+            <a class="link-type" @click="handleDownload(scope.row)">
+              <span>{{ scope.row.fileName }}</span>
+            </a>
+          </template>
+        </el-table-column>
+        <el-table-column :label="$t('大小(Kb)')" align="center" prop="fileSize" :show-overflow-tooltip="true"
+                         width="80"/>
+        <el-table-column :label="$t('上传人')" align="center" prop="creator" :show-overflow-tooltip="true" width="120"/>
+        <el-table-column :label="$t('操作')" align="center" width="120" class-name="small-padding fixed-width">
+          <template slot-scope="scope">
+            <el-button
+              v-if="scope.row.fileName.endsWith('pdf')"
+              size="mini"
+              type="text"
+              icon="el-icon-view"
+              @click="handleSee(scope.row)"
+            >{{ $t('预览') }}
+            </el-button>
+            <el-button
+              size="mini"
+              type="text"
+              icon="el-icon-download"
+              @click="handleDownload(scope.row)"
+            >{{ $t('下载') }}
+            </el-button>
+            <el-button
+              size="mini"
+              type="text"
+              icon="el-icon-delete"
+              @click="handleDeleteDoc(scope.row)"
+            >{{ $t('删除') }}
+            </el-button>
+          </template>
+        </el-table-column>
+      </el-table>
+      <el-dialog :close-on-click-modal="false" v-dialogDrag :title="pdf.title" :visible.sync="pdf.open" width="1300px"
+                 append-to-body>
+        <div style="margin-top: -60px;float: right;margin-right: 40px;">
+          <el-button size="mini" type="text" @click="openPdf">{{ $t('新页面打开PDF') }}</el-button>
+        </div>
+        <div style="margin-top: -30px">
+          <iframe :src="pdf.pdfUrl" frameborder="0" width="100%" height="700px"></iframe>
+        </div>
+      </el-dialog>
+      <div slot="footer" class="dialog-footer">
+        <!--        <el-button type="primary" @click="submitFileForm">{{ $t('确 定') }}</el-button>-->
+        <el-button @click="doc.open = false">{{ $t('返 回') }}</el-button>
+      </div>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import {
+  addOperationlist,
+  delOperationlist,
+  exportOperationlist,
+  getOperationlist,
+  listOperationlist,
+  updateOperationlist
+} from "@/api/issue/operationlist";
+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 {allFileList, delCommonfile} from "@/api/common/commonfile";
+
+export default {
+  name: "OperationlistBd",
+  components: {Treeselect},
+  data() {
+    return {
+      // 遮罩层
+      loading: true,
+      // 选中数组
+      ids: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: false,
+      // 总条数
+      total: 0,
+      // CBPB工艺事件清单表格数据
+      operationlistList: [],
+      // 弹出层标题
+      title: "",
+      // 部门树选项
+      deptOptions: undefined,
+      clientHeight: 300,
+      // 是否显示弹出层
+      open: false,
+      // 用户导入参数
+      upload: {
+        downloadAction: process.env.VUE_APP_BASE_API + '/common/template',
+        //下载模板类型
+        type: "operationlist",
+        // 是否显示弹出层(用户导入)
+        open: false,
+        // 弹出层标题(用户导入)
+        title: "",
+        // 是否禁用上传
+        isUploading: false,
+        // 是否更新已经存在的用户数据
+        updateSupport: 0,
+        // 设置上传的请求头部
+        headers: {Authorization: "Bearer " + getToken()},
+        // 上传的地址
+        url: process.env.VUE_APP_BASE_API + "/issue/operationlist/importData"
+      },
+      // 报告附件参数
+      doc: {
+        file: "",
+        // 是否显示弹出层(报告附件)
+        open: false,
+        // 弹出层标题(报告附件)
+        title: "",
+        // 是否禁用上传
+        isUploading: false,
+        // 是否更新已经存在的用户数据
+        updateSupport: 0,
+        // 报告附件上传位置编号
+        ids: 0,
+        // 设置上传的请求头部
+        headers: {Authorization: "Bearer " + getToken()},
+        // 上传的地址
+        url: process.env.VUE_APP_BASE_API + "/common/commonfile/uploadFile",
+        commonfileList: null,
+        queryParams: {
+          pId: null,
+          pType: 'operationlist'
+        },
+        pType: 'operationlist',
+        pId: null
+      },
+      pdf: {
+        title: '',
+        pdfUrl: '',
+        numPages: null,
+        open: false,
+        pageNum: 1,
+        pageTotalNum: 1,
+        loadedRatio: 0,
+      },
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 20,
+        plant: 'BD',
+        shiftClass: null,
+        incidentDescription: null,
+        causeRes: null,
+        identifiedDate: null,
+        identifiedDateStr: null,
+        incidentType: null,
+        coutermeasures: null,
+        createrCode: null,
+        createdate: null,
+        updaterCode: null,
+        updatedate: null,
+        deptId: null,
+        remarks: null
+      },
+      // 表单参数
+      form: {},
+      // 表单校验
+      rules: {
+        coutermeasures: [
+          {required: true, message: "措施不能为空", trigger: "blur"}
+        ],
+        causeRes: [
+          {required: true, message: "原因不能为空", trigger: "blur"}
+        ],
+        incidentDescription: [
+          {required: true, message: "事件描述不能为空", trigger: "blur"}
+        ],
+        incidentType: [
+          {required: true, message: "请选择事件分类", trigger: "blur"}
+        ],
+        shiftClass: [
+          {required: true, message: "请选择班组", trigger: "blur"}
+        ],
+        identifiedDate: [
+          {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();
+  },
+  methods: {
+    /** 查询CBPB工艺事件清单列表 */
+    getList() {
+      this.loading = true;
+      listOperationlist(this.queryParams).then(response => {
+        this.operationlistList = 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,
+        plant: 'BD',
+        shiftClass: null,
+        incidentDescription: null,
+        causeRes: null,
+        coutermeasures: null,
+        identifiedDate: null,
+        incidentType: null,
+        delFlag: null,
+        createrCode: null,
+        createdate: null,
+        updaterCode: null,
+        updatedate: null,
+        deptId: null,
+        remarks: 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 = "添加CBPB工艺事件清单";
+    },
+    /** 修改按钮操作 */
+    handleUpdate(row) {
+      this.reset();
+      const id = row.id || this.ids
+      getOperationlist(id).then(response => {
+        this.form = response.data;
+        this.open = true;
+        this.title = "修改CBPB工艺事件清单";
+      });
+    },
+    /** 提交按钮 */
+    submitForm() {
+      this.$refs["form"].validate(valid => {
+        if (valid) {
+          if (this.form.id != null) {
+            updateOperationlist(this.form).then(response => {
+              this.msgSuccess("修改成功");
+              this.open = false;
+              this.getList();
+            });
+          } else {
+            addOperationlist(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 delOperationlist(ids);
+      }).then(() => {
+        this.getList();
+        this.msgSuccess("删除成功");
+      })
+    },
+    /** 导出按钮操作 */
+    handleExport() {
+      const queryParams = this.queryParams;
+      this.$confirm('是否确认导出所有CBPB工艺事件清单数据项?', "警告", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning"
+      }).then(function () {
+        return exportOperationlist(queryParams);
+      }).then(response => {
+        this.download(response.msg);
+      })
+    },
+    /** 导入按钮操作 */
+    handleImport() {
+      this.upload.title = "用户导入";
+      this.upload.open = true;
+    },
+    /** 下载模板操作 */
+    importTemplate() {
+      this.$refs['downloadFileForm'].submit()
+    },
+    // 文件上传中处理
+    handleFileUploadProgress(event, file, fileList) {
+      this.upload.isUploading = true;
+    },
+    // 文件上传成功处理
+    handleFileSuccess(response, file, fileList) {
+      this.upload.open = false;
+      this.upload.isUploading = false;
+      this.$refs.upload.clearFiles();
+      if (response.data[0] != null) {
+        this.$alert(this.$t('成功导入') + response.msg + this.$t('条数据') + "," + this.$t('第') + response.data + this.$t('行数据出现错误导入失败') + "。", this.$t('导入结果'), {dangerouslyUseHTMLString: true});
+      } else {
+        this.$alert(this.$t('成功导入') + response.msg + this.$t('条数据'), this.$t('导入结果'), {dangerouslyUseHTMLString: true});
+      }
+      this.getList();
+    },
+    // 提交上传文件
+    submitFileForm() {
+      this.$refs.upload.submit();
+    }, /** 报告附件按钮操作 */
+    handleDoc(row) {
+      this.doc.id = row.id;
+      this.doc.title = this.$t('附件');
+      this.doc.open = true;
+      this.doc.queryParams.pId = row.id
+      this.doc.pId = row.id
+      this.getFileList()
+      this.$nextTick(() => {
+        this.$refs.doc.clearFiles()
+      })
+    },
+    getFileList() {
+      allFileList(this.doc.queryParams).then(response => {
+        this.doc.commonfileList = response;
+      });
+    },
+    //附件上传中处理
+    handleFileDocProgress(event, file, fileList) {
+      this.doc.file = file;
+      this.doc.isUploading = true;
+    },
+    //附件上传成功处理
+    handleFileDocSuccess(response, file, fileList) {
+      this.doc.isUploading = false;
+      this.$alert(response.msg, this.$t('导入结果'), {dangerouslyUseHTMLString: true});
+      this.getFileList()
+    },
+    /** 删除按钮操作 */
+    handleDeleteDoc(row) {
+      const ids = row.id || this.ids;
+      this.$confirm(this.$t('是否确认删除?'), this.$t('警告'), {
+        confirmButtonText: this.$t('确定'),
+        cancelButtonText: this.$t('取消'),
+        type: "warning"
+      }).then(function () {
+        return delCommonfile(ids);
+      }).then(() => {
+        this.getFileList()
+        this.msgSuccess(this.$t('删除成功'));
+      })
+    },
+    // 文件下载处理
+    handleDownload(row) {
+      var name = row.fileName;
+      var url = row.fileUrl;
+      var suffix = url.substring(url.lastIndexOf("."), url.length);
+      const a = document.createElement('a')
+      a.setAttribute('download', name)
+      a.setAttribute('target', '_blank')
+      a.setAttribute('href', process.env.VUE_APP_BASE_API + url)
+      a.click()
+    },
+    openPdf() {
+      window.open(this.pdf.pdfUrl);//path是文件的全路径地址
+    },
+    handleSee(row) {
+      this.pdf.open = true
+      this.pdf.title = row.fileName
+      this.pdf.pdfUrl = process.env.VUE_APP_BASE_API + '/pdf/web/viewer.html?file=' + process.env.VUE_APP_BASE_API + row.fileUrl
+    },
+    //翻页后继续计算序列值
+    indexMethod(index) {
+      return (this.queryParams.pageNum-1)*this.queryParams.pageSize+index+1;
+    }
+  }
+};
+</script>

+ 652 - 0
ui/src/views/issue/operationlist/ebsm.vue

@@ -0,0 +1,652 @@
+<template>
+  <div class="app-container">
+    <el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" label-width="68px">
+      <el-form-item label="时间" prop="identifiedDateStr">
+        <el-date-picker clearable size="small" style="width: 200px"
+                        v-model="queryParams.identifiedDateStr"
+                        type="year"
+                        @change="handleQuery"
+                        value-format="yyyy"
+                        placeholder="选择提出日期">
+        </el-date-picker>
+      </el-form-item>
+      <el-form-item label="事件描述" prop="incidentDescription">
+        <el-input
+          v-model="queryParams.incidentDescription"
+          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="['issue:operationlist: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="['issue:operationlist: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="['issue:operationlist:remove']"
+        >删除
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="info"
+          icon="el-icon-upload2"
+          size="mini"
+          @click="handleImport"
+          v-hasPermi="['issue:operationlist:edit']"
+        >导入
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="warning"
+          icon="el-icon-download"
+          size="mini"
+          @click="handleExport"
+          v-hasPermi="['issue:operationlist:export']"
+        >导出
+        </el-button>
+      </el-col>
+      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+    </el-row>
+
+    <el-table v-loading="loading" :data="operationlistList" @selection-change="handleSelectionChange"
+              :height="clientHeight" border>
+      <el-table-column type="selection" width="55" align="center"/>
+      <el-table-column type="index" label="序号"  width="55" align="center" :index="indexMethod"/>
+      <el-table-column label="时间" align="center" prop="identifiedDate" :show-overflow-tooltip="true"/>
+      <el-table-column label="班组" align="center" prop="shiftClass" :show-overflow-tooltip="true"/>
+      <el-table-column label="事件分类" align="center" prop="incidentType" :show-overflow-tooltip="true"/>
+      <el-table-column label="事件描述" align="center" prop="incidentDescription" :show-overflow-tooltip="true"/>
+      <el-table-column label="原因" align="center" prop="causeRes" :show-overflow-tooltip="true"/>
+      <el-table-column label="措施" align="center" prop="coutermeasures" :show-overflow-tooltip="true"/>
+      <el-table-column label="备注" align="center" prop="remarks" :show-overflow-tooltip="true"/>
+      <el-table-column label="操作" align="center" fixed="right" width="160" class-name="small-padding fixed-width">
+        <template slot-scope="scope">
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-edit"
+            @click="handleUpdate(scope.row)"
+            v-hasPermi="['issue:operationlist:edit']"
+          >修改
+          </el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-delete"
+            @click="handleDelete(scope.row)"
+            v-hasPermi="['issue:operationlist:remove']"
+          >删除
+          </el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-document"
+            @click="handleDoc(scope.row)"
+            v-hasPermi="['issue:operationlist:edit']"
+          >{{ $t('附件') }}
+          </el-button>
+        </template>
+      </el-table-column>
+    </el-table>
+
+    <pagination
+      v-show="total>0"
+      :total="total"
+      :page.sync="queryParams.pageNum"
+      :limit.sync="queryParams.pageSize"
+      @pagination="getList"
+    />
+
+    <!-- 添加或修改CBPB工艺事件清单对话框 -->
+    <el-dialog :title="title" :visible.sync="open" width="60%" append-to-body :close-on-click-modal="false">
+      <el-form ref="form" :model="form" :rules="rules" label-width="80px">
+        <el-form-item label="时间" prop="identifiedDate">
+          <el-date-picker clearable size="small" style="width: 100%"
+                          v-model="form.identifiedDate"
+                          type="date"
+                          value-format="yyyy-MM-dd"
+                          placeholder="选择时间">
+          </el-date-picker>
+        </el-form-item>
+        <el-form-item label="班组" prop="shiftClass">
+          <el-select v-model="form.shiftClass" placeholder="请选择班组" clearable style="width: 100%">
+            <el-option value="A" laabel="A"></el-option>
+            <el-option value="B" laabel="B"></el-option>
+            <el-option value="C" laabel="C"></el-option>
+            <el-option value="D" laabel="D"></el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item label="事件分类" prop="incidentType">
+          <el-select v-model="form.incidentType" placeholder="请选择事件分类" clearable style="width: 100%">
+            <el-option value="工艺" laabel="工艺"></el-option>
+            <el-option value="仪表" laabel="仪表"></el-option>
+            <el-option value="其他" laabel="其他"></el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item label="事件描述" prop="incidentDescription">
+          <el-input v-model="form.incidentDescription" type="textarea" placeholder="请输入事件描述"/>
+        </el-form-item>
+        <el-form-item label="原因" prop="causeRes">
+          <el-input v-model="form.causeRes" type="textarea" placeholder="请输入原因"/>
+        </el-form-item>
+        <el-form-item label="措施" prop="coutermeasures">
+          <el-input v-model="form.coutermeasures" type="textarea" placeholder="请输入措施"/>
+        </el-form-item>
+        <el-form-item label="备注" prop="remarks">
+          <el-input 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 :close-on-click-modal="false" v-dialogDrag :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"
+        :disabled="upload.isUploading"
+        :on-progress="handleFileUploadProgress"
+        :on-success="handleFileSuccess"
+        :auto-upload="false"
+        drag
+      >
+        <i class="el-icon-upload"></i>
+        <div class="el-upload__text">
+          {{ $t('将文件拖到此处,或') }}
+          <em>{{ $t('点击上传') }}</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">{{ $t('下载模板') }}</el-link>
+        </div>
+        <form ref="downloadFileForm" :action="upload.downloadAction" target="FORMSUBMIT">
+          <input name="type" :value="upload.type" hidden/>
+        </form>
+        <div class="el-upload__tip" style="color:red" slot="tip">{{ $t('提示:仅允许导入“xls”或“xlsx”格式文件!') }}</div>
+      </el-upload>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitFileForm">{{ $t('确 定') }}</el-button>
+        <el-button @click="upload.open = false">{{ $t('取 消') }}</el-button>
+      </div>
+    </el-dialog><!-- 报告附件对话框 -->
+    <el-dialog :close-on-click-modal="false" v-dialogDrag :title="doc.title" :visible.sync="doc.open" width="700px"
+               append-to-body>
+      <el-upload
+        ref="doc"
+        :limit="50"
+        :headers="doc.headers"
+        :action="doc.url + '?pType=' + doc.pType + '&pId=' + doc.pId"
+        :disabled="doc.isUploading"
+        :on-progress="handleFileDocProgress"
+        :on-success="handleFileDocSuccess"
+        :auto-upload="true"
+        drag
+      >
+        <i class="el-icon-upload"></i>
+        <div class="el-upload__text">
+          {{ $t('将文件拖到此处,或') }}
+          <em>{{ $t('点击上传') }}</em>
+        </div>
+      </el-upload>
+      <el-table :data="doc.commonfileList" border>
+        <el-table-column :label="$t('文件名')" align="center" prop="fileName" :show-overflow-tooltip="true">
+          <template slot-scope="scope">
+            <a class="link-type" @click="handleDownload(scope.row)">
+              <span>{{ scope.row.fileName }}</span>
+            </a>
+          </template>
+        </el-table-column>
+        <el-table-column :label="$t('大小(Kb)')" align="center" prop="fileSize" :show-overflow-tooltip="true"
+                         width="80"/>
+        <el-table-column :label="$t('上传人')" align="center" prop="creator" :show-overflow-tooltip="true" width="120"/>
+        <el-table-column :label="$t('操作')" align="center" width="120" class-name="small-padding fixed-width">
+          <template slot-scope="scope">
+            <el-button
+              v-if="scope.row.fileName.endsWith('pdf')"
+              size="mini"
+              type="text"
+              icon="el-icon-view"
+              @click="handleSee(scope.row)"
+            >{{ $t('预览') }}
+            </el-button>
+            <el-button
+              size="mini"
+              type="text"
+              icon="el-icon-download"
+              @click="handleDownload(scope.row)"
+            >{{ $t('下载') }}
+            </el-button>
+            <el-button
+              size="mini"
+              type="text"
+              icon="el-icon-delete"
+              @click="handleDeleteDoc(scope.row)"
+            >{{ $t('删除') }}
+            </el-button>
+          </template>
+        </el-table-column>
+      </el-table>
+      <el-dialog :close-on-click-modal="false" v-dialogDrag :title="pdf.title" :visible.sync="pdf.open" width="1300px"
+                 append-to-body>
+        <div style="margin-top: -60px;float: right;margin-right: 40px;">
+          <el-button size="mini" type="text" @click="openPdf">{{ $t('新页面打开PDF') }}</el-button>
+        </div>
+        <div style="margin-top: -30px">
+          <iframe :src="pdf.pdfUrl" frameborder="0" width="100%" height="700px"></iframe>
+        </div>
+      </el-dialog>
+      <div slot="footer" class="dialog-footer">
+        <!--        <el-button type="primary" @click="submitFileForm">{{ $t('确 定') }}</el-button>-->
+        <el-button @click="doc.open = false">{{ $t('返 回') }}</el-button>
+      </div>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import {
+  addOperationlist,
+  delOperationlist,
+  exportOperationlist,
+  getOperationlist,
+  listOperationlist,
+  updateOperationlist
+} from "@/api/issue/operationlist";
+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 {allFileList, delCommonfile} from "@/api/common/commonfile";
+
+export default {
+  name: "OperationlistEbsm",
+  components: {Treeselect},
+  data() {
+    return {
+      // 遮罩层
+      loading: true,
+      // 选中数组
+      ids: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: false,
+      // 总条数
+      total: 0,
+      // CBPB工艺事件清单表格数据
+      operationlistList: [],
+      // 弹出层标题
+      title: "",
+      // 部门树选项
+      deptOptions: undefined,
+      clientHeight: 300,
+      // 是否显示弹出层
+      open: false,
+      // 用户导入参数
+      upload: {
+        downloadAction: process.env.VUE_APP_BASE_API + '/common/template',
+        //下载模板类型
+        type: "operationlist",
+        // 是否显示弹出层(用户导入)
+        open: false,
+        // 弹出层标题(用户导入)
+        title: "",
+        // 是否禁用上传
+        isUploading: false,
+        // 是否更新已经存在的用户数据
+        updateSupport: 0,
+        // 设置上传的请求头部
+        headers: {Authorization: "Bearer " + getToken()},
+        // 上传的地址
+        url: process.env.VUE_APP_BASE_API + "/issue/operationlist/importData"
+      },
+      // 报告附件参数
+      doc: {
+        file: "",
+        // 是否显示弹出层(报告附件)
+        open: false,
+        // 弹出层标题(报告附件)
+        title: "",
+        // 是否禁用上传
+        isUploading: false,
+        // 是否更新已经存在的用户数据
+        updateSupport: 0,
+        // 报告附件上传位置编号
+        ids: 0,
+        // 设置上传的请求头部
+        headers: {Authorization: "Bearer " + getToken()},
+        // 上传的地址
+        url: process.env.VUE_APP_BASE_API + "/common/commonfile/uploadFile",
+        commonfileList: null,
+        queryParams: {
+          pId: null,
+          pType: 'operationlist'
+        },
+        pType: 'operationlist',
+        pId: null
+      },
+      pdf: {
+        title: '',
+        pdfUrl: '',
+        numPages: null,
+        open: false,
+        pageNum: 1,
+        pageTotalNum: 1,
+        loadedRatio: 0,
+      },
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 20,
+        plant: 'EBSM',
+        shiftClass: null,
+        incidentDescription: null,
+        causeRes: null,
+        identifiedDate: null,
+        identifiedDateStr: null,
+        incidentType: null,
+        coutermeasures: null,
+        createrCode: null,
+        createdate: null,
+        updaterCode: null,
+        updatedate: null,
+        deptId: null,
+        remarks: null
+      },
+      // 表单参数
+      form: {},
+      // 表单校验
+      rules: {
+        coutermeasures: [
+          {required: true, message: "措施不能为空", trigger: "blur"}
+        ],
+        causeRes: [
+          {required: true, message: "原因不能为空", trigger: "blur"}
+        ],
+        incidentDescription: [
+          {required: true, message: "事件描述不能为空", trigger: "blur"}
+        ],
+        incidentType: [
+          {required: true, message: "请选择事件分类", trigger: "blur"}
+        ],
+        shiftClass: [
+          {required: true, message: "请选择班组", trigger: "blur"}
+        ],
+        identifiedDate: [
+          {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();
+  },
+  methods: {
+    /** 查询CBPB工艺事件清单列表 */
+    getList() {
+      this.loading = true;
+      listOperationlist(this.queryParams).then(response => {
+        this.operationlistList = 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,
+        plant: 'EBSM',
+        shiftClass: null,
+        incidentDescription: null,
+        causeRes: null,
+        coutermeasures: null,
+        identifiedDate: null,
+        incidentType: null,
+        delFlag: null,
+        createrCode: null,
+        createdate: null,
+        updaterCode: null,
+        updatedate: null,
+        deptId: null,
+        remarks: 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 = "添加CBPB工艺事件清单";
+    },
+    /** 修改按钮操作 */
+    handleUpdate(row) {
+      this.reset();
+      const id = row.id || this.ids
+      getOperationlist(id).then(response => {
+        this.form = response.data;
+        this.open = true;
+        this.title = "修改CBPB工艺事件清单";
+      });
+    },
+    /** 提交按钮 */
+    submitForm() {
+      this.$refs["form"].validate(valid => {
+        if (valid) {
+          if (this.form.id != null) {
+            updateOperationlist(this.form).then(response => {
+              this.msgSuccess("修改成功");
+              this.open = false;
+              this.getList();
+            });
+          } else {
+            addOperationlist(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 delOperationlist(ids);
+      }).then(() => {
+        this.getList();
+        this.msgSuccess("删除成功");
+      })
+    },
+    /** 导出按钮操作 */
+    handleExport() {
+      const queryParams = this.queryParams;
+      this.$confirm('是否确认导出所有CBPB工艺事件清单数据项?', "警告", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning"
+      }).then(function () {
+        return exportOperationlist(queryParams);
+      }).then(response => {
+        this.download(response.msg);
+      })
+    },
+    /** 导入按钮操作 */
+    handleImport() {
+      this.upload.title = "用户导入";
+      this.upload.open = true;
+    },
+    /** 下载模板操作 */
+    importTemplate() {
+      this.$refs['downloadFileForm'].submit()
+    },
+    // 文件上传中处理
+    handleFileUploadProgress(event, file, fileList) {
+      this.upload.isUploading = true;
+    },
+    // 文件上传成功处理
+    handleFileSuccess(response, file, fileList) {
+      this.upload.open = false;
+      this.upload.isUploading = false;
+      this.$refs.upload.clearFiles();
+      if (response.data[0] != null) {
+        this.$alert(this.$t('成功导入') + response.msg + this.$t('条数据') + "," + this.$t('第') + response.data + this.$t('行数据出现错误导入失败') + "。", this.$t('导入结果'), {dangerouslyUseHTMLString: true});
+      } else {
+        this.$alert(this.$t('成功导入') + response.msg + this.$t('条数据'), this.$t('导入结果'), {dangerouslyUseHTMLString: true});
+      }
+      this.getList();
+    },
+    // 提交上传文件
+    submitFileForm() {
+      this.$refs.upload.submit();
+    }, /** 报告附件按钮操作 */
+    handleDoc(row) {
+      this.doc.id = row.id;
+      this.doc.title = this.$t('附件');
+      this.doc.open = true;
+      this.doc.queryParams.pId = row.id
+      this.doc.pId = row.id
+      this.getFileList()
+      this.$nextTick(() => {
+        this.$refs.doc.clearFiles()
+      })
+    },
+    getFileList() {
+      allFileList(this.doc.queryParams).then(response => {
+        this.doc.commonfileList = response;
+      });
+    },
+    //附件上传中处理
+    handleFileDocProgress(event, file, fileList) {
+      this.doc.file = file;
+      this.doc.isUploading = true;
+    },
+    //附件上传成功处理
+    handleFileDocSuccess(response, file, fileList) {
+      this.doc.isUploading = false;
+      this.$alert(response.msg, this.$t('导入结果'), {dangerouslyUseHTMLString: true});
+      this.getFileList()
+    },
+    /** 删除按钮操作 */
+    handleDeleteDoc(row) {
+      const ids = row.id || this.ids;
+      this.$confirm(this.$t('是否确认删除?'), this.$t('警告'), {
+        confirmButtonText: this.$t('确定'),
+        cancelButtonText: this.$t('取消'),
+        type: "warning"
+      }).then(function () {
+        return delCommonfile(ids);
+      }).then(() => {
+        this.getFileList()
+        this.msgSuccess(this.$t('删除成功'));
+      })
+    },
+    // 文件下载处理
+    handleDownload(row) {
+      var name = row.fileName;
+      var url = row.fileUrl;
+      var suffix = url.substring(url.lastIndexOf("."), url.length);
+      const a = document.createElement('a')
+      a.setAttribute('download', name)
+      a.setAttribute('target', '_blank')
+      a.setAttribute('href', process.env.VUE_APP_BASE_API + url)
+      a.click()
+    },
+    openPdf() {
+      window.open(this.pdf.pdfUrl);//path是文件的全路径地址
+    },
+    handleSee(row) {
+      this.pdf.open = true
+      this.pdf.title = row.fileName
+      this.pdf.pdfUrl = process.env.VUE_APP_BASE_API + '/pdf/web/viewer.html?file=' + process.env.VUE_APP_BASE_API + row.fileUrl
+    },
+    //翻页后继续计算序列值
+    indexMethod(index) {
+      return (this.queryParams.pageNum-1)*this.queryParams.pageSize+index+1;
+    }
+  }
+};
+</script>

+ 652 - 0
ui/src/views/issue/operationlist/ib.vue

@@ -0,0 +1,652 @@
+<template>
+  <div class="app-container">
+    <el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" label-width="68px">
+      <el-form-item label="时间" prop="identifiedDateStr">
+        <el-date-picker clearable size="small" style="width: 200px"
+                        v-model="queryParams.identifiedDateStr"
+                        type="year"
+                        @change="handleQuery"
+                        value-format="yyyy"
+                        placeholder="选择提出日期">
+        </el-date-picker>
+      </el-form-item>
+      <el-form-item label="事件描述" prop="incidentDescription">
+        <el-input
+          v-model="queryParams.incidentDescription"
+          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="['issue:operationlist: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="['issue:operationlist: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="['issue:operationlist:remove']"
+        >删除
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="info"
+          icon="el-icon-upload2"
+          size="mini"
+          @click="handleImport"
+          v-hasPermi="['issue:operationlist:edit']"
+        >导入
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="warning"
+          icon="el-icon-download"
+          size="mini"
+          @click="handleExport"
+          v-hasPermi="['issue:operationlist:export']"
+        >导出
+        </el-button>
+      </el-col>
+      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+    </el-row>
+
+    <el-table v-loading="loading" :data="operationlistList" @selection-change="handleSelectionChange"
+              :height="clientHeight" border>
+      <el-table-column type="selection" width="55" align="center"/>
+      <el-table-column type="index" label="序号"  width="55" align="center" :index="indexMethod"/>
+      <el-table-column label="时间" align="center" prop="identifiedDate" :show-overflow-tooltip="true"/>
+      <el-table-column label="班组" align="center" prop="shiftClass" :show-overflow-tooltip="true"/>
+      <el-table-column label="事件分类" align="center" prop="incidentType" :show-overflow-tooltip="true"/>
+      <el-table-column label="事件描述" align="center" prop="incidentDescription" :show-overflow-tooltip="true"/>
+      <el-table-column label="原因" align="center" prop="causeRes" :show-overflow-tooltip="true"/>
+      <el-table-column label="措施" align="center" prop="coutermeasures" :show-overflow-tooltip="true"/>
+      <el-table-column label="备注" align="center" prop="remarks" :show-overflow-tooltip="true"/>
+      <el-table-column label="操作" align="center" fixed="right" width="160" class-name="small-padding fixed-width">
+        <template slot-scope="scope">
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-edit"
+            @click="handleUpdate(scope.row)"
+            v-hasPermi="['issue:operationlist:edit']"
+          >修改
+          </el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-delete"
+            @click="handleDelete(scope.row)"
+            v-hasPermi="['issue:operationlist:remove']"
+          >删除
+          </el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-document"
+            @click="handleDoc(scope.row)"
+            v-hasPermi="['issue:operationlist:edit']"
+          >{{ $t('附件') }}
+          </el-button>
+        </template>
+      </el-table-column>
+    </el-table>
+
+    <pagination
+      v-show="total>0"
+      :total="total"
+      :page.sync="queryParams.pageNum"
+      :limit.sync="queryParams.pageSize"
+      @pagination="getList"
+    />
+
+    <!-- 添加或修改CBPB工艺事件清单对话框 -->
+    <el-dialog :title="title" :visible.sync="open" width="60%" append-to-body :close-on-click-modal="false">
+      <el-form ref="form" :model="form" :rules="rules" label-width="80px">
+        <el-form-item label="时间" prop="identifiedDate">
+          <el-date-picker clearable size="small" style="width: 100%"
+                          v-model="form.identifiedDate"
+                          type="date"
+                          value-format="yyyy-MM-dd"
+                          placeholder="选择时间">
+          </el-date-picker>
+        </el-form-item>
+        <el-form-item label="班组" prop="shiftClass">
+          <el-select v-model="form.shiftClass" placeholder="请选择班组" clearable style="width: 100%">
+            <el-option value="A" laabel="A"></el-option>
+            <el-option value="B" laabel="B"></el-option>
+            <el-option value="C" laabel="C"></el-option>
+            <el-option value="D" laabel="D"></el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item label="事件分类" prop="incidentType">
+          <el-select v-model="form.incidentType" placeholder="请选择事件分类" clearable style="width: 100%">
+            <el-option value="工艺" laabel="工艺"></el-option>
+            <el-option value="仪表" laabel="仪表"></el-option>
+            <el-option value="其他" laabel="其他"></el-option>
+          </el-select>
+        </el-form-item>
+        <el-form-item label="事件描述" prop="incidentDescription">
+          <el-input v-model="form.incidentDescription" type="textarea" placeholder="请输入事件描述"/>
+        </el-form-item>
+        <el-form-item label="原因" prop="causeRes">
+          <el-input v-model="form.causeRes" type="textarea" placeholder="请输入原因"/>
+        </el-form-item>
+        <el-form-item label="措施" prop="coutermeasures">
+          <el-input v-model="form.coutermeasures" type="textarea" placeholder="请输入措施"/>
+        </el-form-item>
+        <el-form-item label="备注" prop="remarks">
+          <el-input 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 :close-on-click-modal="false" v-dialogDrag :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"
+        :disabled="upload.isUploading"
+        :on-progress="handleFileUploadProgress"
+        :on-success="handleFileSuccess"
+        :auto-upload="false"
+        drag
+      >
+        <i class="el-icon-upload"></i>
+        <div class="el-upload__text">
+          {{ $t('将文件拖到此处,或') }}
+          <em>{{ $t('点击上传') }}</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">{{ $t('下载模板') }}</el-link>
+        </div>
+        <form ref="downloadFileForm" :action="upload.downloadAction" target="FORMSUBMIT">
+          <input name="type" :value="upload.type" hidden/>
+        </form>
+        <div class="el-upload__tip" style="color:red" slot="tip">{{ $t('提示:仅允许导入“xls”或“xlsx”格式文件!') }}</div>
+      </el-upload>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitFileForm">{{ $t('确 定') }}</el-button>
+        <el-button @click="upload.open = false">{{ $t('取 消') }}</el-button>
+      </div>
+    </el-dialog><!-- 报告附件对话框 -->
+    <el-dialog :close-on-click-modal="false" v-dialogDrag :title="doc.title" :visible.sync="doc.open" width="700px"
+               append-to-body>
+      <el-upload
+        ref="doc"
+        :limit="50"
+        :headers="doc.headers"
+        :action="doc.url + '?pType=' + doc.pType + '&pId=' + doc.pId"
+        :disabled="doc.isUploading"
+        :on-progress="handleFileDocProgress"
+        :on-success="handleFileDocSuccess"
+        :auto-upload="true"
+        drag
+      >
+        <i class="el-icon-upload"></i>
+        <div class="el-upload__text">
+          {{ $t('将文件拖到此处,或') }}
+          <em>{{ $t('点击上传') }}</em>
+        </div>
+      </el-upload>
+      <el-table :data="doc.commonfileList" border>
+        <el-table-column :label="$t('文件名')" align="center" prop="fileName" :show-overflow-tooltip="true">
+          <template slot-scope="scope">
+            <a class="link-type" @click="handleDownload(scope.row)">
+              <span>{{ scope.row.fileName }}</span>
+            </a>
+          </template>
+        </el-table-column>
+        <el-table-column :label="$t('大小(Kb)')" align="center" prop="fileSize" :show-overflow-tooltip="true"
+                         width="80"/>
+        <el-table-column :label="$t('上传人')" align="center" prop="creator" :show-overflow-tooltip="true" width="120"/>
+        <el-table-column :label="$t('操作')" align="center" width="120" class-name="small-padding fixed-width">
+          <template slot-scope="scope">
+            <el-button
+              v-if="scope.row.fileName.endsWith('pdf')"
+              size="mini"
+              type="text"
+              icon="el-icon-view"
+              @click="handleSee(scope.row)"
+            >{{ $t('预览') }}
+            </el-button>
+            <el-button
+              size="mini"
+              type="text"
+              icon="el-icon-download"
+              @click="handleDownload(scope.row)"
+            >{{ $t('下载') }}
+            </el-button>
+            <el-button
+              size="mini"
+              type="text"
+              icon="el-icon-delete"
+              @click="handleDeleteDoc(scope.row)"
+            >{{ $t('删除') }}
+            </el-button>
+          </template>
+        </el-table-column>
+      </el-table>
+      <el-dialog :close-on-click-modal="false" v-dialogDrag :title="pdf.title" :visible.sync="pdf.open" width="1300px"
+                 append-to-body>
+        <div style="margin-top: -60px;float: right;margin-right: 40px;">
+          <el-button size="mini" type="text" @click="openPdf">{{ $t('新页面打开PDF') }}</el-button>
+        </div>
+        <div style="margin-top: -30px">
+          <iframe :src="pdf.pdfUrl" frameborder="0" width="100%" height="700px"></iframe>
+        </div>
+      </el-dialog>
+      <div slot="footer" class="dialog-footer">
+        <!--        <el-button type="primary" @click="submitFileForm">{{ $t('确 定') }}</el-button>-->
+        <el-button @click="doc.open = false">{{ $t('返 回') }}</el-button>
+      </div>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import {
+  addOperationlist,
+  delOperationlist,
+  exportOperationlist,
+  getOperationlist,
+  listOperationlist,
+  updateOperationlist
+} from "@/api/issue/operationlist";
+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 {allFileList, delCommonfile} from "@/api/common/commonfile";
+
+export default {
+  name: "OperationlistIb",
+  components: {Treeselect},
+  data() {
+    return {
+      // 遮罩层
+      loading: true,
+      // 选中数组
+      ids: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: false,
+      // 总条数
+      total: 0,
+      // CBPB工艺事件清单表格数据
+      operationlistList: [],
+      // 弹出层标题
+      title: "",
+      // 部门树选项
+      deptOptions: undefined,
+      clientHeight: 300,
+      // 是否显示弹出层
+      open: false,
+      // 用户导入参数
+      upload: {
+        downloadAction: process.env.VUE_APP_BASE_API + '/common/template',
+        //下载模板类型
+        type: "operationlist",
+        // 是否显示弹出层(用户导入)
+        open: false,
+        // 弹出层标题(用户导入)
+        title: "",
+        // 是否禁用上传
+        isUploading: false,
+        // 是否更新已经存在的用户数据
+        updateSupport: 0,
+        // 设置上传的请求头部
+        headers: {Authorization: "Bearer " + getToken()},
+        // 上传的地址
+        url: process.env.VUE_APP_BASE_API + "/issue/operationlist/importData"
+      },
+      // 报告附件参数
+      doc: {
+        file: "",
+        // 是否显示弹出层(报告附件)
+        open: false,
+        // 弹出层标题(报告附件)
+        title: "",
+        // 是否禁用上传
+        isUploading: false,
+        // 是否更新已经存在的用户数据
+        updateSupport: 0,
+        // 报告附件上传位置编号
+        ids: 0,
+        // 设置上传的请求头部
+        headers: {Authorization: "Bearer " + getToken()},
+        // 上传的地址
+        url: process.env.VUE_APP_BASE_API + "/common/commonfile/uploadFile",
+        commonfileList: null,
+        queryParams: {
+          pId: null,
+          pType: 'operationlist'
+        },
+        pType: 'operationlist',
+        pId: null
+      },
+      pdf: {
+        title: '',
+        pdfUrl: '',
+        numPages: null,
+        open: false,
+        pageNum: 1,
+        pageTotalNum: 1,
+        loadedRatio: 0,
+      },
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 20,
+        plant: 'IB',
+        shiftClass: null,
+        incidentDescription: null,
+        causeRes: null,
+        identifiedDate: null,
+        identifiedDateStr: null,
+        incidentType: null,
+        coutermeasures: null,
+        createrCode: null,
+        createdate: null,
+        updaterCode: null,
+        updatedate: null,
+        deptId: null,
+        remarks: null
+      },
+      // 表单参数
+      form: {},
+      // 表单校验
+      rules: {
+        coutermeasures: [
+          {required: true, message: "措施不能为空", trigger: "blur"}
+        ],
+        causeRes: [
+          {required: true, message: "原因不能为空", trigger: "blur"}
+        ],
+        incidentDescription: [
+          {required: true, message: "事件描述不能为空", trigger: "blur"}
+        ],
+        incidentType: [
+          {required: true, message: "请选择事件分类", trigger: "blur"}
+        ],
+        shiftClass: [
+          {required: true, message: "请选择班组", trigger: "blur"}
+        ],
+        identifiedDate: [
+          {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();
+  },
+  methods: {
+    /** 查询CBPB工艺事件清单列表 */
+    getList() {
+      this.loading = true;
+      listOperationlist(this.queryParams).then(response => {
+        this.operationlistList = response.rows;
+        this.total = response.total;
+        this.loading = false;
+      });
+    },
+    /** 查询部门下拉树结构 */
+    getTreeselect() {
+      treeselect().then(response => {
+        this.deptOptions = response.data;
+      });z
+    },
+    // 取消按钮
+    cancel() {
+      this.open = false;
+      this.reset();
+    },
+    // 表单重置
+    reset() {
+      this.form = {
+        id: null,
+        plant: 'IB',
+        shiftClass: null,
+        incidentDescription: null,
+        causeRes: null,
+        coutermeasures: null,
+        identifiedDate: null,
+        incidentType: null,
+        delFlag: null,
+        createrCode: null,
+        createdate: null,
+        updaterCode: null,
+        updatedate: null,
+        deptId: null,
+        remarks: 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 = "添加CBPB工艺事件清单";
+    },
+    /** 修改按钮操作 */
+    handleUpdate(row) {
+      this.reset();
+      const id = row.id || this.ids
+      getOperationlist(id).then(response => {
+        this.form = response.data;
+        this.open = true;
+        this.title = "修改CBPB工艺事件清单";
+      });
+    },
+    /** 提交按钮 */
+    submitForm() {
+      this.$refs["form"].validate(valid => {
+        if (valid) {
+          if (this.form.id != null) {
+            updateOperationlist(this.form).then(response => {
+              this.msgSuccess("修改成功");
+              this.open = false;
+              this.getList();
+            });
+          } else {
+            addOperationlist(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 delOperationlist(ids);
+      }).then(() => {
+        this.getList();
+        this.msgSuccess("删除成功");
+      })
+    },
+    /** 导出按钮操作 */
+    handleExport() {
+      const queryParams = this.queryParams;
+      this.$confirm('是否确认导出所有CBPB工艺事件清单数据项?', "警告", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning"
+      }).then(function () {
+        return exportOperationlist(queryParams);
+      }).then(response => {
+        this.download(response.msg);
+      })
+    },
+    /** 导入按钮操作 */
+    handleImport() {
+      this.upload.title = "用户导入";
+      this.upload.open = true;
+    },
+    /** 下载模板操作 */
+    importTemplate() {
+      this.$refs['downloadFileForm'].submit()
+    },
+    // 文件上传中处理
+    handleFileUploadProgress(event, file, fileList) {
+      this.upload.isUploading = true;
+    },
+    // 文件上传成功处理
+    handleFileSuccess(response, file, fileList) {
+      this.upload.open = false;
+      this.upload.isUploading = false;
+      this.$refs.upload.clearFiles();
+      if (response.data[0] != null) {
+        this.$alert(this.$t('成功导入') + response.msg + this.$t('条数据') + "," + this.$t('第') + response.data + this.$t('行数据出现错误导入失败') + "。", this.$t('导入结果'), {dangerouslyUseHTMLString: true});
+      } else {
+        this.$alert(this.$t('成功导入') + response.msg + this.$t('条数据'), this.$t('导入结果'), {dangerouslyUseHTMLString: true});
+      }
+      this.getList();
+    },
+    // 提交上传文件
+    submitFileForm() {
+      this.$refs.upload.submit();
+    }, /** 报告附件按钮操作 */
+    handleDoc(row) {
+      this.doc.id = row.id;
+      this.doc.title = this.$t('附件');
+      this.doc.open = true;
+      this.doc.queryParams.pId = row.id
+      this.doc.pId = row.id
+      this.getFileList()
+      this.$nextTick(() => {
+        this.$refs.doc.clearFiles()
+      })
+    },
+    getFileList() {
+      allFileList(this.doc.queryParams).then(response => {
+        this.doc.commonfileList = response;
+      });
+    },
+    //附件上传中处理
+    handleFileDocProgress(event, file, fileList) {
+      this.doc.file = file;
+      this.doc.isUploading = true;
+    },
+    //附件上传成功处理
+    handleFileDocSuccess(response, file, fileList) {
+      this.doc.isUploading = false;
+      this.$alert(response.msg, this.$t('导入结果'), {dangerouslyUseHTMLString: true});
+      this.getFileList()
+    },
+    /** 删除按钮操作 */
+    handleDeleteDoc(row) {
+      const ids = row.id || this.ids;
+      this.$confirm(this.$t('是否确认删除?'), this.$t('警告'), {
+        confirmButtonText: this.$t('确定'),
+        cancelButtonText: this.$t('取消'),
+        type: "warning"
+      }).then(function () {
+        return delCommonfile(ids);
+      }).then(() => {
+        this.getFileList()
+        this.msgSuccess(this.$t('删除成功'));
+      })
+    },
+    // 文件下载处理
+    handleDownload(row) {
+      var name = row.fileName;
+      var url = row.fileUrl;
+      var suffix = url.substring(url.lastIndexOf("."), url.length);
+      const a = document.createElement('a')
+      a.setAttribute('download', name)
+      a.setAttribute('target', '_blank')
+      a.setAttribute('href', process.env.VUE_APP_BASE_API + url)
+      a.click()
+    },
+    openPdf() {
+      window.open(this.pdf.pdfUrl);//path是文件的全路径地址
+    },
+    handleSee(row) {
+      this.pdf.open = true
+      this.pdf.title = row.fileName
+      this.pdf.pdfUrl = process.env.VUE_APP_BASE_API + '/pdf/web/viewer.html?file=' + process.env.VUE_APP_BASE_API + row.fileUrl
+    },
+    //翻页后继续计算序列值
+    indexMethod(index) {
+      return (this.queryParams.pageNum-1)*this.queryParams.pageSize+index+1;
+    }
+  }
+};
+</script>

+ 36 - 586
ui/src/views/issue/operationlist/index.vue

@@ -1,603 +1,53 @@
 <template>
   <div class="app-container">
-    <el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" label-width="68px">
-      <el-form-item label="装置" prop="plant">
-        <el-input
-          v-model="queryParams.plant"
-          placeholder="请输入装置"
-          clearable
-          size="small"
-          @keyup.enter.native="handleQuery"
-        />
-      </el-form-item>
-      <el-form-item label="班组" prop="shiftClass">
-        <el-input
-          v-model="queryParams.shiftClass"
-          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="['issue:operationlist: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="['issue:operationlist: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="['issue:operationlist:remove']"
-        >删除
-        </el-button>
-      </el-col>
-      <el-col :span="1.5">
-        <el-button
-          type="info"
-          icon="el-icon-upload2"
-          size="mini"
-          @click="handleImport"
-          v-hasPermi="['issue:operationlist:edit']"
-        >导入
-        </el-button>
-      </el-col>
-      <el-col :span="1.5">
-        <el-button
-          type="warning"
-          icon="el-icon-download"
-          size="mini"
-          @click="handleExport"
-          v-hasPermi="['issue:operationlist:export']"
-        >导出
-        </el-button>
-      </el-col>
-      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
-    </el-row>
-
-    <el-table v-loading="loading" :data="operationlistList" @selection-change="handleSelectionChange"
-              :height="clientHeight" border>
-      <el-table-column type="selection" width="55" align="center"/>
-      <el-table-column label="装置" align="center" prop="plant" :show-overflow-tooltip="true"/>
-      <el-table-column label="班组" align="center" prop="shiftClass" :show-overflow-tooltip="true"/>
-      <el-table-column label="事件描述" align="center" prop="incidentDescription" :show-overflow-tooltip="true"/>
-      <el-table-column label="原因" align="center" prop="causeRes" :show-overflow-tooltip="true"/>
-      <el-table-column label="措施" align="center" prop="coutermeasures" :show-overflow-tooltip="true"/>
-      <el-table-column label="备注" align="center" prop="remarks" :show-overflow-tooltip="true"/>
-      <el-table-column label="操作" align="center" fixed="right" width="160" class-name="small-padding fixed-width">
-        <template slot-scope="scope">
-          <el-button
-            size="mini"
-            type="text"
-            icon="el-icon-edit"
-            @click="handleUpdate(scope.row)"
-            v-hasPermi="['issue:operationlist:edit']"
-          >修改
-          </el-button>
-          <el-button
-            size="mini"
-            type="text"
-            icon="el-icon-delete"
-            @click="handleDelete(scope.row)"
-            v-hasPermi="['issue:operationlist:remove']"
-          >删除
-          </el-button>
-          <el-button
-            size="mini"
-            type="text"
-            icon="el-icon-document"
-            @click="handleDoc(scope.row)"
-            v-hasPermi="['issue:operationlist:edit']"
-          >{{ $t('附件') }}</el-button>
-        </template>
-      </el-table-column>
-    </el-table>
-
-    <pagination
-      v-show="total>0"
-      :total="total"
-      :page.sync="queryParams.pageNum"
-      :limit.sync="queryParams.pageSize"
-      @pagination="getList"
-    />
-
-    <!-- 添加或修改CBPB工艺事件清单对话框 -->
-    <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body :close-on-click-modal="false">
-      <el-form ref="form" :model="form" :rules="rules" label-width="80px">
-        <el-form-item label="装置" prop="plant">
-          <el-input v-model="form.plant" placeholder="请输入装置"/>
-        </el-form-item>
-        <el-form-item label="班组" prop="shiftClass">
-          <el-input v-model="form.shiftClass" placeholder="请输入班组"/>
-        </el-form-item>
-        <el-form-item label="事件描述" prop="incidentDescription">
-          <el-input v-model="form.incidentDescription" placeholder="请输入事件描述"/>
-        </el-form-item>
-        <el-form-item label="原因" prop="causeRes">
-          <el-input v-model="form.causeRes" placeholder="请输入原因"/>
-        </el-form-item>
-        <el-form-item label="措施" prop="coutermeasures">
-          <el-input v-model="form.coutermeasures" placeholder="请输入措施"/>
-        </el-form-item>
-        <el-form-item label="备注" prop="remarks">
-          <el-input 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  :close-on-click-modal="false" v-dialogDrag :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"
-        :disabled="upload.isUploading"
-        :on-progress="handleFileUploadProgress"
-        :on-success="handleFileSuccess"
-        :auto-upload="false"
-        drag
-      >
-        <i class="el-icon-upload"></i>
-        <div class="el-upload__text">
-          {{ $t('将文件拖到此处,或') }}
-          <em>{{ $t('点击上传') }}</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">{{ $t('下载模板') }}</el-link>
-        </div>
-        <form ref="downloadFileForm" :action="upload.downloadAction" target="FORMSUBMIT">
-          <input name="type" :value="upload.type" hidden />
-        </form>
-        <div class="el-upload__tip" style="color:red" slot="tip">{{ $t('提示:仅允许导入“xls”或“xlsx”格式文件!') }}</div>
-      </el-upload>
-      <div slot="footer" class="dialog-footer">
-        <el-button type="primary" @click="submitFileForm">{{ $t('确 定') }}</el-button>
-        <el-button @click="upload.open = false">{{ $t('取 消') }}</el-button>
-      </div>
-    </el-dialog><!-- 报告附件对话框 -->
-    <el-dialog :close-on-click-modal="false" v-dialogDrag :title="doc.title" :visible.sync="doc.open" width="700px"
-               append-to-body>
-      <el-upload
-        ref="doc"
-        :limit="50"
-        :headers="doc.headers"
-        :action="doc.url + '?pType=' + doc.pType + '&pId=' + doc.pId"
-        :disabled="doc.isUploading"
-        :on-progress="handleFileDocProgress"
-        :on-success="handleFileDocSuccess"
-        :auto-upload="true"
-        drag
-      >
-        <i class="el-icon-upload"></i>
-        <div class="el-upload__text">
-          {{ $t('将文件拖到此处,或') }}
-          <em>{{ $t('点击上传') }}</em>
-        </div>
-      </el-upload>
-      <el-table :data="doc.commonfileList" border>
-        <el-table-column :label="$t('文件名')" align="center" prop="fileName" :show-overflow-tooltip="true">
-          <template slot-scope="scope">
-            <a class="link-type" @click="handleDownload(scope.row)">
-              <span>{{ scope.row.fileName }}</span>
-            </a>
-          </template>
-        </el-table-column>
-        <el-table-column :label="$t('大小(Kb)')" align="center" prop="fileSize" :show-overflow-tooltip="true"
-                         width="80"/>
-        <el-table-column :label="$t('上传人')" align="center" prop="creator" :show-overflow-tooltip="true" width="120"/>
-        <el-table-column :label="$t('操作')" align="center" width="120" class-name="small-padding fixed-width">
-          <template slot-scope="scope">
-            <el-button
-              v-if="scope.row.fileName.endsWith('pdf')"
-              size="mini"
-              type="text"
-              icon="el-icon-view"
-              @click="handleSee(scope.row)"
-            >{{ $t('预览') }}
-            </el-button>
-            <el-button
-              size="mini"
-              type="text"
-              icon="el-icon-download"
-              @click="handleDownload(scope.row)"
-            >{{ $t('下载') }}
-            </el-button>
-            <el-button
-              size="mini"
-              type="text"
-              icon="el-icon-delete"
-              @click="handleDeleteDoc(scope.row)"
-            >{{ $t('删除') }}
-            </el-button>
-          </template>
-        </el-table-column>
-      </el-table>
-      <el-dialog :close-on-click-modal="false" v-dialogDrag :title="pdf.title" :visible.sync="pdf.open" width="1300px"
-                 append-to-body>
-        <div style="margin-top: -60px;float: right;margin-right: 40px;">
-          <el-button size="mini" type="text" @click="openPdf">{{ $t('新页面打开PDF') }}</el-button>
-        </div>
-        <div style="margin-top: -30px">
-          <iframe :src="pdf.pdfUrl" frameborder="0" width="100%" height="700px"></iframe>
-        </div>
-      </el-dialog>
-      <div slot="footer" class="dialog-footer">
-        <!--        <el-button type="primary" @click="submitFileForm">{{ $t('确 定') }}</el-button>-->
-        <el-button @click="doc.open = false">{{ $t('返 回') }}</el-button>
-      </div>
-    </el-dialog>
+    <el-tabs v-model="activeName" type="card" @tab-click="handleClick">
+      <el-tab-pane label="BD" name="first">
+        <OperationlistBd v-if="isFirst"></OperationlistBd>
+      </el-tab-pane>
+      <el-tab-pane label="IB" name="second">
+        <IssuelistIB v-if="isSecond"></IssuelistIB>
+      </el-tab-pane>
+      <el-tab-pane label="EBSM" name="third">
+        <IssuelistEBSM v-if="isThird"></IssuelistEBSM>
+      </el-tab-pane>
+    </el-tabs>
   </div>
 </template>
 
 <script>
-import {
-  addOperationlist,
-  delOperationlist,
-  exportOperationlist,
-  getOperationlist,
-  listOperationlist,
-  updateOperationlist
-} from "@/api/issue/operationlist";
-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 {allFileList, delCommonfile} from "@/api/common/commonfile";
+
+import IssuelistBD from "./bd.vue";
+import IssuelistEBSM from "./ebsm.vue";
+import IssuelistIB from "./ib.vue";
+import OperationlistBd from "./bd.vue";
 
 export default {
-  name: "Operationlist",
-  components: {Treeselect},
+  name: "Issuelist",
+  components: {OperationlistBd, IssuelistIB, IssuelistEBSM, IssuelistBD},
   data() {
     return {
-      // 遮罩层
-      loading: true,
-      // 选中数组
-      ids: [],
-      // 非单个禁用
-      single: true,
-      // 非多个禁用
-      multiple: true,
-      // 显示搜索条件
-      showSearch: false,
-      // 总条数
-      total: 0,
-      // CBPB工艺事件清单表格数据
-      operationlistList: [],
-      // 弹出层标题
-      title: "",
-      // 部门树选项
-      deptOptions: undefined,
-      clientHeight: 300,
-      // 是否显示弹出层
-      open: false,
-      // 用户导入参数
-      upload: {
-        downloadAction: process.env.VUE_APP_BASE_API + '/common/template',
-        //下载模板类型
-        type: "operationlist",
-        // 是否显示弹出层(用户导入)
-        open: false,
-        // 弹出层标题(用户导入)
-        title: "",
-        // 是否禁用上传
-        isUploading: false,
-        // 是否更新已经存在的用户数据
-        updateSupport: 0,
-        // 设置上传的请求头部
-        headers: {Authorization: "Bearer " + getToken()},
-        // 上传的地址
-        url: process.env.VUE_APP_BASE_API + "/issue/operationlist/importData"
-      },
-      // 报告附件参数
-      doc: {
-        file: "",
-        // 是否显示弹出层(报告附件)
-        open: false,
-        // 弹出层标题(报告附件)
-        title: "",
-        // 是否禁用上传
-        isUploading: false,
-        // 是否更新已经存在的用户数据
-        updateSupport: 0,
-        // 报告附件上传位置编号
-        ids: 0,
-        // 设置上传的请求头部
-        headers: {Authorization: "Bearer " + getToken()},
-        // 上传的地址
-        url: process.env.VUE_APP_BASE_API + "/common/commonfile/uploadFile",
-        commonfileList: null,
-        queryParams: {
-          pId: null,
-          pType: 'operationlist'
-        },
-        pType: 'operationlist',
-        pId: null
-      },
-      pdf : {
-        title: '',
-        pdfUrl: '',
-        numPages: null,
-        open: false,
-        pageNum: 1,
-        pageTotalNum: 1,
-        loadedRatio: 0,
-      },
-      // 查询参数
-      queryParams: {
-        pageNum: 1,
-        pageSize: 20,
-        plant: null,
-        shiftClass: null,
-        incidentDescription: null,
-        causeRes: null,
-        coutermeasures: null,
-        createrCode: null,
-        createdate: null,
-        updaterCode: null,
-        updatedate: null,
-        deptId: null,
-        remarks: null
-      },
-      // 表单参数
-      form: {},
-      // 表单校验
-      rules: {}
+      activeName: 'first',
+      isFirst: true,
+      isSecond: false,
+      isThird: false
     };
   },
-  watch: {
-    // 根据名称筛选部门树
-    deptName(val) {
-      this.$refs.tree.filter(val);
-    }
-  },
-  created() {
-    //设置表格高度对应屏幕高度
-    this.$nextTick(() => {
-      this.clientHeight = document.body.clientHeight - 250
-    })
-    this.getList();
-    this.getTreeselect();
-  },
   methods: {
-    /** 查询CBPB工艺事件清单列表 */
-    getList() {
-      this.loading = true;
-      listOperationlist(this.queryParams).then(response => {
-        this.operationlistList = 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,
-        plant: null,
-        shiftClass: null,
-        incidentDescription: null,
-        causeRes: null,
-        coutermeasures: null,
-        delFlag: null,
-        createrCode: null,
-        createdate: null,
-        updaterCode: null,
-        updatedate: null,
-        deptId: null,
-        remarks: 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 = "添加CBPB工艺事件清单";
-    },
-    /** 修改按钮操作 */
-    handleUpdate(row) {
-      this.reset();
-      const id = row.id || this.ids
-      getOperationlist(id).then(response => {
-        this.form = response.data;
-        this.open = true;
-        this.title = "修改CBPB工艺事件清单";
-      });
-    },
-    /** 提交按钮 */
-    submitForm() {
-      this.$refs["form"].validate(valid => {
-        if (valid) {
-          if (this.form.id != null) {
-            updateOperationlist(this.form).then(response => {
-              this.msgSuccess("修改成功");
-              this.open = false;
-              this.getList();
-            });
-          } else {
-            addOperationlist(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 delOperationlist(ids);
-      }).then(() => {
-        this.getList();
-        this.msgSuccess("删除成功");
-      })
-    },
-    /** 导出按钮操作 */
-    handleExport() {
-      const queryParams = this.queryParams;
-      this.$confirm('是否确认导出所有CBPB工艺事件清单数据项?', "警告", {
-        confirmButtonText: "确定",
-        cancelButtonText: "取消",
-        type: "warning"
-      }).then(function () {
-        return exportOperationlist(queryParams);
-      }).then(response => {
-        this.download(response.msg);
-      })
-    },
-    /** 导入按钮操作 */
-    handleImport() {
-      this.upload.title = "用户导入";
-      this.upload.open = true;
-    },
-    /** 下载模板操作 */
-    importTemplate() {
-      this.$refs['downloadFileForm'].submit()
-    },
-    // 文件上传中处理
-    handleFileUploadProgress(event, file, fileList) {
-      this.upload.isUploading = true;
-    },
-    // 文件上传成功处理
-    handleFileSuccess(response, file, fileList) {
-      this.upload.open = false;
-      this.upload.isUploading = false;
-      this.$refs.upload.clearFiles();
-      if (response.data[0] != null) {
-        this.$alert(this.$t('成功导入') + response.msg + this.$t('条数据') + "," + this.$t('第') + response.data + this.$t('行数据出现错误导入失败') + "。", this.$t('导入结果'), {dangerouslyUseHTMLString: true});
-      } else {
-        this.$alert(this.$t('成功导入') + response.msg + this.$t('条数据'), this.$t('导入结果'), {dangerouslyUseHTMLString: true});
+    handleClick(tab){
+      if(tab.name == 'first'){
+        this.isFirst = true;
+        this.isSecond = false;
+        this.isThird = false;
+      }else if(tab.name == 'second'){
+        this.isFirst = false;
+        this.isSecond = true;
+        this.isThird = false;
+      }else if(tab.name == 'third'){
+        this.isFirst = false;
+        this.isSecond = false;
+        this.isThird = true;
       }
-      this.getList();
-    },
-    // 提交上传文件
-    submitFileForm() {
-      this.$refs.upload.submit();
-    },/** 报告附件按钮操作 */
-    handleDoc(row) {
-      this.doc.id = row.id;
-      this.doc.title = this.$t('附件');
-      this.doc.open = true;
-      this.doc.queryParams.pId = row.id
-      this.doc.pId = row.id
-      this.getFileList()
-      this.$nextTick(() => {
-        this.$refs.doc.clearFiles()
-      })
-    },
-    getFileList() {
-      allFileList(this.doc.queryParams).then(response => {
-        this.doc.commonfileList = response;
-      });
-    },
-    //附件上传中处理
-    handleFileDocProgress(event, file, fileList) {
-      this.doc.file = file;
-      this.doc.isUploading = true;
-    },
-    //附件上传成功处理
-    handleFileDocSuccess(response, file, fileList) {
-      this.doc.isUploading = false;
-      this.$alert(response.msg, this.$t('导入结果'), {dangerouslyUseHTMLString: true});
-      this.getFileList()
-    },
-    /** 删除按钮操作 */
-    handleDeleteDoc(row) {
-      const ids = row.id || this.ids;
-      this.$confirm(this.$t('是否确认删除?'), this.$t('警告'), {
-        confirmButtonText: this.$t('确定'),
-        cancelButtonText: this.$t('取消'),
-        type: "warning"
-      }).then(function () {
-        return delCommonfile(ids);
-      }).then(() => {
-        this.getFileList()
-        this.msgSuccess(this.$t('删除成功'));
-      })
-    },
-    // 文件下载处理
-    handleDownload(row) {
-      var name = row.fileName;
-      var url = row.fileUrl;
-      var suffix = url.substring(url.lastIndexOf("."), url.length);
-      const a = document.createElement('a')
-      a.setAttribute('download', name)
-      a.setAttribute('target', '_blank')
-      a.setAttribute('href', process.env.VUE_APP_BASE_API + url)
-      a.click()
-    },
-    openPdf() {
-      window.open(this.pdf.pdfUrl);//path是文件的全路径地址
-    },
-    handleSee(row) {
-      this.pdf.open = true
-      this.pdf.title = row.fileName
-      this.pdf.pdfUrl = process.env.VUE_APP_BASE_API + '/pdf/web/viewer.html?file=' + process.env.VUE_APP_BASE_API + row.fileUrl
-    },
+    }
   }
 };
 </script>

+ 2 - 2
ui/src/views/login.vue

@@ -261,8 +261,8 @@ export default {
   justify-content: center;
   align-items: center;
   height: 100%;
-  background-image: url("../assets/image/CPMS20210107.jpg");
-  //background-image: url("../assets/image/cpms-test.jpg");
+  //background-image: url("../assets/image/CPMS20210107.jpg");
+  background-image: url("../assets/image/cpms-test.jpg");
   background-size: cover;
 }