lwhhszx 2 年 前
コミット
708ef976fb
25 ファイル変更429 行追加150 行削除
  1. 1 0
      RMS/src/main/java/cn/cslg/report/common/model/vo/TaskReportVO.java
  2. 3 2
      RMS/src/main/java/cn/cslg/report/common/model/vo/TaskVO.java
  3. 1 5
      RMS/src/main/java/cn/cslg/report/controller/BaseController.java
  4. 2 3
      RMS/src/main/java/cn/cslg/report/controller/OutSidersController.java
  5. 0 1
      RMS/src/main/java/cn/cslg/report/controller/ReportDocumentController.java
  6. 2 8
      RMS/src/main/java/cn/cslg/report/controller/TaskController.java
  7. 40 0
      RMS/src/main/java/cn/cslg/report/entity/TemplateConfig.java
  8. 10 0
      RMS/src/main/java/cn/cslg/report/mapper/TemplateConfigMapper.java
  9. 164 110
      RMS/src/main/java/cn/cslg/report/service/business/ReportDocumentService.java
  10. 16 2
      RMS/src/main/java/cn/cslg/report/service/business/ReportFieldPatentLinkService.java
  11. 72 1
      RMS/src/main/java/cn/cslg/report/service/business/ReportFieldService.java
  12. 93 12
      RMS/src/main/java/cn/cslg/report/service/business/TaskService.java
  13. 15 0
      RMS/src/main/java/cn/cslg/report/service/business/TemplateConfigService.java
  14. 5 3
      RMS/src/main/resources/mapper/TaskMapper.xml
  15. BIN
      RMS/target/classes/cn/cslg/report/common/model/vo/TaskReportVO.class
  16. BIN
      RMS/target/classes/cn/cslg/report/common/model/vo/TaskVO$personPatents.class
  17. BIN
      RMS/target/classes/cn/cslg/report/common/model/vo/TaskVO.class
  18. BIN
      RMS/target/classes/cn/cslg/report/controller/BaseController.class
  19. BIN
      RMS/target/classes/cn/cslg/report/controller/ReportDocumentController.class
  20. BIN
      RMS/target/classes/cn/cslg/report/controller/TaskController.class
  21. BIN
      RMS/target/classes/cn/cslg/report/service/business/ReportDocumentService.class
  22. BIN
      RMS/target/classes/cn/cslg/report/service/business/ReportFieldPatentLinkService.class
  23. BIN
      RMS/target/classes/cn/cslg/report/service/business/ReportFieldService.class
  24. BIN
      RMS/target/classes/cn/cslg/report/service/business/TaskService.class
  25. 5 3
      RMS/target/classes/mapper/TaskMapper.xml

+ 1 - 0
RMS/src/main/java/cn/cslg/report/common/model/vo/TaskReportVO.java

@@ -24,6 +24,7 @@ import java.util.List;
 public class TaskReportVO extends BaseVO {
     private Integer id;
     private String createName;
+    private Integer createID;
    private Integer  reportType;
     @Schema(description = "报告信息")
     private Report report;

+ 3 - 2
RMS/src/main/java/cn/cslg/report/common/model/vo/TaskVO.java

@@ -59,9 +59,12 @@ public class TaskVO extends BaseVO {
 
     @Schema(description = "登录人Id")
     private Integer loginId;
+
    @Schema(description = "人员专题号对象列表")
   private List<personPatents> personPatents;
 
+    private List<Integer> taskStatuses;
+
     @Schema(description = "人员专题号对象")
     @Data
     public static class personPatents{
@@ -69,7 +72,5 @@ public class TaskVO extends BaseVO {
             private Integer personId;
         @Schema(description = "专题号列表")
         private List<String> patentNos;
-
-
     }
 }

+ 1 - 5
RMS/src/main/java/cn/cslg/report/controller/BaseController.java

@@ -131,11 +131,7 @@ public class BaseController {
     @GetMapping("/getPatentByPatentNo")
     @Operation(summary = "根据专利号获得专利")
     @Parameters(value = {
-            @Parameter(name = "patentNo",description = "专利号",required = true),
-
-
-
-    })
+            @Parameter(name = "patentNo",description = "专利号",required = true)})
     public String getPatentByPatentNo(String patentNo,Integer taskID) throws IOException {
          return  outInterfaceService.getPatentFromPAS(patentNo);
     }

+ 2 - 3
RMS/src/main/java/cn/cslg/report/controller/OutSidersController.java

@@ -61,11 +61,10 @@ public class OutSidersController {
         Pattern pattern = Pattern.compile(parStr);
         Matcher matcher = pattern.matcher(str);
         List<String> list =new ArrayList<>();
-        while (matcher.find()){
-      String a =     str .substring(0, matcher.start());list.add(matcher.group());
+        while(matcher.find()){
+       String a = str .substring(0, matcher.start());list.add(matcher.group());
             System.out.println(matcher.group()+":"+a);
         }
-
         return Response.error("code码输入错误");
     }
 }

+ 0 - 1
RMS/src/main/java/cn/cslg/report/controller/ReportDocumentController.java

@@ -29,7 +29,6 @@ public class ReportDocumentController {
         return reportDocumentService.exportReport(reportId,templeId);
     }
 
-
     @RequestMapping(value = "/getExportList", method = RequestMethod.POST)
     @Operation(summary = "获得导出记录")
     public  String getExportList(@RequestBody ReportDocument reportDocument) throws IOException {

+ 2 - 8
RMS/src/main/java/cn/cslg/report/controller/TaskController.java

@@ -47,7 +47,7 @@ public class TaskController {
 
     @RequestMapping(value = "/queryPageList", method = RequestMethod.POST)
     @Operation(summary = "分页查询任务列表")
-    public String queryPageList(@RequestBody TaskVO taskVO) {
+    public String queryPageList(@RequestBody TaskVO taskVO) throws IOException {
         return Response.success(taskService.queryPageList(taskVO));
     }
 
@@ -69,7 +69,6 @@ public class TaskController {
         return taskService.auditTask(auditTaskVO);
     }
 
-
     @RequestMapping(value = "/addAssTask", method = RequestMethod.POST)
     @Operation(summary = "添加分配任务")
     public String addAssTask(@RequestBody AssignTaskVO assignTaskVO) throws ParseException, IOException {
@@ -114,7 +113,7 @@ public class TaskController {
     }
     @RequestMapping(value = "/finish", method = RequestMethod.GET)
     @Operation(summary = "完成任务")
-    private String finish(Integer id){
+    private String finish(Integer id) throws IOException {
         return taskService.finishTask(id);
     }
     @RequestMapping(value = "/reviewTheTasks", method = RequestMethod.POST)
@@ -139,11 +138,6 @@ public class TaskController {
         return taskService.look(taskID,patentNo);
     }
 
-//    @RequestMapping(value = "/reTaskPatents", method = RequestMethod.POST)
-//    @Operation(summary = "返回任务专利清单")
-//    public String reTaskPatents(@RequestBody PatentVO patentVO) throws ParseException, IOException {
-//        return taskService.reTaskPatents1(patentVO);
-//    }
         @RequestMapping(value = "/addSyneryTask", method = RequestMethod.POST)
     @Operation(summary = "添加协同任务")
     public String addSyneryTask(@RequestBody SyneryVO syneryVO) throws ParseException, IOException {

+ 40 - 0
RMS/src/main/java/cn/cslg/report/entity/TemplateConfig.java

@@ -0,0 +1,40 @@
+package cn.cslg.report.entity;
+
+import cn.cslg.report.common.model.BaseEntity;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableName;
+import io.swagger.v3.oas.annotations.media.Schema;
+import lombok.Data;
+import lombok.EqualsAndHashCode;
+import lombok.experimental.Accessors;
+
+
+/**
+ * 模板配置表
+ */
+@Data
+@Accessors(chain = true)
+@EqualsAndHashCode(callSuper = true)
+@TableName(value = "TEMPLATE_CONFIG")
+public class TemplateConfig extends BaseEntity<TemplateConfig> {
+
+    @Schema(description = "模板Id")
+    @TableField(value = "TEMPLATE_ID")
+    private Integer templateId;
+
+
+    @Schema(description = "自定义字段值名称")
+    @TableField(value = "VALUE_NAME")
+    private String valueName;
+
+
+    @Schema(description = "映射名称")
+    @TableField(value = "MAP_NAME")
+    private String mapName;
+
+    @Schema(description = "顺序")
+    @TableField(value = "ORDER_NUM")
+    private Integer orderNum;
+
+
+}

+ 10 - 0
RMS/src/main/java/cn/cslg/report/mapper/TemplateConfigMapper.java

@@ -0,0 +1,10 @@
+package cn.cslg.report.mapper;
+
+import cn.cslg.report.entity.TemplateConfig;
+
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import org.apache.ibatis.annotations.Mapper;
+
+@Mapper
+public interface TemplateConfigMapper extends BaseMapper<TemplateConfig> {
+}

+ 164 - 110
RMS/src/main/java/cn/cslg/report/service/business/ReportDocumentService.java

@@ -25,6 +25,7 @@ import lombok.extern.slf4j.Slf4j;
 import org.apache.poi.poifs.filesystem.DirectoryEntry;
 import org.apache.poi.poifs.filesystem.DocumentEntry;
 import org.apache.poi.poifs.filesystem.POIFSFileSystem;
+import org.apache.poi.ss.formula.functions.T;
 import org.ddr.poi.html.HtmlRenderPolicy;
 import org.springframework.context.annotation.Lazy;
 import org.springframework.stereotype.Service;
@@ -53,62 +54,71 @@ public class ReportDocumentService extends ServiceImpl<ReportDocumentMapper, Rep
     private final FileUtils fileUtils;
     private final LoginUtils loginUtils;
     private final CacheUtils cacheUtils;
+    private final ReportFieldService reportFieldService;
+    private final TemplateConfigService templateConfigService;
+    private final ReportFieldPatentLinkService reportFieldPatentLinkService;
 
-     public String reportDocument(ReportDocument reportDocument) {
+    public String reportDocument(ReportDocument reportDocument) {
 
-       return  Response.success();
+        return Response.success();
 
-     }
+    }
 
     /**
-     * @function: 根据报告Id获得报告的导出记录
      * @param reportDocument
      * @return
+     * @function: 根据报告Id获得报告的导出记录
      */
-    public String getExportList(ReportDocument reportDocument){
-         LambdaQueryWrapper<ReportDocument> wrapper =new LambdaQueryWrapper<>();
-         wrapper.eq(ReportDocument::getReportId,reportDocument.getReportId());
-        IPage<ReportDocument> pages =this.page(new Page<>(reportDocument.getCurrent(),reportDocument.getSize()),wrapper);
-         return  Response.success(pages);
+    public String getExportList(ReportDocument reportDocument) {
+        LambdaQueryWrapper<ReportDocument> wrapper = new LambdaQueryWrapper<>();
+        wrapper.eq(ReportDocument::getReportId, reportDocument.getReportId());
+        IPage<ReportDocument> pages = this.page(new Page<>(reportDocument.getCurrent(), reportDocument.getSize()), wrapper);
+        return Response.success(pages);
     }
 
     public String deleteExport(Integer id) {
-         this.removeById(id);
-         return Response.success();
+        this.removeById(id);
+        return Response.success();
     }
 
 
     /**
-     * @function: 导出报告
      * @param reportId
      * @param templeId
      * @return
      * @throws IOException
+     * @function: 导出报告
      */
-    public String exportReport(Integer reportId,Integer templeId) throws IOException {
-          //根据模板ID获得模板
-        Template reportTemplate= templateService.getById(templeId);
+    public String exportReport(Integer reportId, Integer templeId) throws IOException {
+        //根据模板ID获得模板
+        Template reportTemplate = templateService.getById(templeId);
         //获得模板路径
-        String filePath =fileUtils.getPath(reportTemplate.getTemplatePath());
+        String filePath = fileUtils.getPath(reportTemplate.getTemplatePath());
         // 读取模板后保存生成word的地址
         String fileName = IdUtil.simpleUUID() + ".docx";
         String directoryName = fileUtils.createDirectory();
-        String outPath = fileUtils.getSavePath(directoryName)+fileName;
-
-        XWPFTemplate template =this.getstabilityMaps(reportId,filePath);
+        String outPath = fileUtils.getSavePath(directoryName) + fileName;
+        Report report = reportService.getById(reportId);
+        XWPFTemplate template =null;
+        if(report.getType()==0||report.getType()==2) {
+             template = this.getstabilityMaps(report, filePath);
+        }
+        else if(report.getType()==3){
+            template= this.FTOtemplate(reportId, filePath,templeId);
+        }
         // 读取模板、数据并渲染
 //         文件是否已存在,则删除
         File file = new File(outPath);
         if (file.exists()) {
             file.delete();
         }
-//         生成word保存在指定目录
+//      生成word保存在指定目录
         template.writeToFile(outPath);
         template.close();
         //导出成功后,导出报告记录入库
         String url = fileUtils.getDirectory2(directoryName) + fileName;
-        PersonnelVO personnelVO =cacheUtils.getLoginUser(loginUtils.getId());
-        ReportDocument reportDocument =new ReportDocument();
+        PersonnelVO personnelVO = cacheUtils.getLoginUser(loginUtils.getId());
+        ReportDocument reportDocument = new ReportDocument();
         reportDocument.setReportId(reportId);
         reportDocument.setFileName(fileName);
         reportDocument.setFilePath(url);
@@ -121,57 +131,59 @@ public class ReportDocumentService extends ServiceImpl<ReportDocumentMapper, Rep
     }
 
 
-  /**
-     * @autor
+    /**
      * @return
+     * @autor
      * @description 装载稳定和无效模板信息
      */
-    private XWPFTemplate getstabilityMaps(Integer reportId,String filePath) throws IOException {
- //根据报告Id获得报告信息
-        Report report = reportService.getById(reportId);
+    private XWPFTemplate getstabilityMaps(Report report, String filePath) throws IOException {
+        //根据报告Id获得报告信息
         // 根据拆分人(报告的创建人)Id和报告ID获得所有特征
         LambdaQueryWrapper<Features> allFeaturesWrapper = new LambdaQueryWrapper<>();
         allFeaturesWrapper.eq(Features::getReportId, report.getId());
-        allFeaturesWrapper.and(wrapper->wrapper.eq(Features::getPartnerId, report.getPersonId()).or().eq(Features::getPartnerId, report.getCreatePersonId()));
+        allFeaturesWrapper.and(wrapper -> wrapper.eq(Features::getPartnerId, report.getPersonId()).or().eq(Features::getPartnerId, report.getCreatePersonId()));
 
         List<Features> allFeatures = featureService.list(allFeaturesWrapper);
         //根据报告Id 查询出报告下所有的方案
         LambdaQueryWrapper<CompareScenarios> queryWrapper = new LambdaQueryWrapper<>();
-        queryWrapper.eq(CompareScenarios::getReportId, reportId);
+        queryWrapper.eq(CompareScenarios::getReportId, report.getId());
         List<CompareScenarios> compareScenarios = compareScenariosService.list(queryWrapper);
         List<Integer> scenarioIds = compareScenarios.stream().map(CompareScenarios::getId).collect(Collectors.toList());
         //根据对比方案Id 查询所有对比方案和(对比记录-特征)关联信息
-        List<AssoScenarIOS> scenariosRecords =new ArrayList<>();
-        if(scenarioIds!=null&&scenarioIds.size()!=0) {
+        List<AssoScenarIOS> scenariosRecords = new ArrayList<>();
+        if (scenarioIds != null && scenarioIds.size() != 0) {
             LambdaQueryWrapper<AssoScenarIOS> queryRecordsByIDs = new LambdaQueryWrapper<>();
             queryRecordsByIDs.in(AssoScenarIOS::getScenariosID, scenarioIds);
             scenariosRecords = scenariosRecordsService.list(queryRecordsByIDs);
         }
-       //获得对比记录-特征关联ID
+        //获得对比记录-特征关联ID
         List<Integer> recordfeatureRecordIds = scenariosRecords.stream().map(AssoScenarIOS::getFeatureRecordID).collect(Collectors.toList());
         //根据对比记录-特征关联ID查出对比记录-特征关联信息
-        List<AssoRecordsFeature>  assoRecordsFeatures =new ArrayList<>();
-        if(recordfeatureRecordIds!=null&&recordfeatureRecordIds.size()!=0){
-        LambdaQueryWrapper<AssoRecordsFeature> wrapper =new LambdaQueryWrapper<>();
-        wrapper.in(AssoRecordsFeature::getId,recordfeatureRecordIds);
-        assoRecordsFeatures =assoRecordsFeatureService.list(wrapper);}
-        List<AssoRecordsFeature> finalAsso =assoRecordsFeatures;
+        List<AssoRecordsFeature> assoRecordsFeatures = new ArrayList<>();
+        if (recordfeatureRecordIds != null && recordfeatureRecordIds.size() != 0) {
+            LambdaQueryWrapper<AssoRecordsFeature> wrapper = new LambdaQueryWrapper<>();
+            wrapper.in(AssoRecordsFeature::getId, recordfeatureRecordIds);
+            assoRecordsFeatures = assoRecordsFeatureService.list(wrapper);
+        }
+        List<AssoRecordsFeature> finalAsso = assoRecordsFeatures;
         //从对比记录-特征关联信息里剔出对比记录Id
-        List<Integer> recordIds =assoRecordsFeatures.stream().map(AssoRecordsFeature::getRecordsId).collect(Collectors.toList());
+        List<Integer> recordIds = assoRecordsFeatures.stream().map(AssoRecordsFeature::getRecordsId).collect(Collectors.toList());
         //从对比记录-特征关联信息里剔出特征Id
-        List<Integer>  sFeatureIds =assoRecordsFeatures.stream().map(AssoRecordsFeature::getFeatureId).collect(Collectors.toList());
+        List<Integer> sFeatureIds = assoRecordsFeatures.stream().map(AssoRecordsFeature::getFeatureId).collect(Collectors.toList());
         //根据特征ID查询出报告所有方案的特征
-        List<Features> sFeatures =new ArrayList<>();
+        List<Features> sFeatures = new ArrayList<>();
         LambdaQueryWrapper<Features> sFeaturesWrapper = new LambdaQueryWrapper<>();
         sFeaturesWrapper.eq(Features::getId, sFeatureIds);
-        if(sFeatures!=null&&sFeatures.size()!=0){
-       sFeatures = featureService.list(sFeaturesWrapper);}
+        if (sFeatures != null && sFeatures.size() != 0) {
+            sFeatures = featureService.list(sFeaturesWrapper);
+        }
         //根据对比记录ID查询出报告所有方案的对比记录
-        List<CompareRecords> compareRecords =new ArrayList<>();
-        if(recordIds!=null&&recordIds.size()!=0){
-        LambdaQueryWrapper<CompareRecords> queryPatentByIDs = new LambdaQueryWrapper<>();
-        queryPatentByIDs.in(CompareRecords::getId,recordIds);
-         compareRecords = compareRecordsService.list(queryPatentByIDs);}
+        List<CompareRecords> compareRecords = new ArrayList<>();
+        if (recordIds != null && recordIds.size() != 0) {
+            LambdaQueryWrapper<CompareRecords> queryPatentByIDs = new LambdaQueryWrapper<>();
+            queryPatentByIDs.in(CompareRecords::getId, recordIds);
+            compareRecords = compareRecordsService.list(queryPatentByIDs);
+        }
         //根据对比记录ID获得专利号
         List<String> PatentNos = compareRecords.stream().map(CompareRecords::getPatentNo).collect(Collectors.toList());
         PatentVO patentVO = new PatentVO();
@@ -194,21 +206,21 @@ public class ReportDocumentService extends ServiceImpl<ReportDocumentMapper, Rep
             applicantJSONs.forEach(tem -> {
                 applicants.append(tem.get("name") + "\r");
             });
-           //填充相关揭露(对比记录文字和特征组合)
-            StringBuffer disclosures =new StringBuffer("");
+            //填充相关揭露(对比记录文字和特征组合)
+            StringBuffer disclosures = new StringBuffer("");
             //根据专利号获得对比记录
-     List<CompareRecords> pantentRecords = compareRecords.stream().filter(tem->tem.getPatentNo().equals(item.get("publicNo"))).collect(Collectors.toList());
+            List<CompareRecords> pantentRecords = compareRecords.stream().filter(tem -> tem.getPatentNo().equals(item.get("publicNo"))).collect(Collectors.toList());
             //遍历对比记录根据对比记录获得对比记录-特征关联信息并获得特征ID
-            for (CompareRecords tem:pantentRecords) {
+            for (CompareRecords tem : pantentRecords) {
                 //填充对比记录文字
                 disclosures.append(tem.getContent());
                 disclosures.append("\r");
                 disclosures.append(tem.getFields());
-                disclosures.append("["+(tem.getPosition())+"]");
-                List<Integer> featuresIds= assoRecordsFeatures.stream().filter(te->te.getRecordsId().equals(tem.getId())).map(AssoRecordsFeature::getFeatureId).collect(Collectors.toList());
+                disclosures.append("[" + (tem.getPosition()) + "]");
+                List<Integer> featuresIds = assoRecordsFeatures.stream().filter(te -> te.getRecordsId().equals(tem.getId())).map(AssoRecordsFeature::getFeatureId).collect(Collectors.toList());
                 //根据特征Id获得特征内容
-                List<String>  feaListContent =sFeatures.stream().filter(te->featuresIds.contains(te.getId())).map(Features::getContent).collect(Collectors.toList());
-                feaListContent.forEach(te->disclosures.append("("+te+")"));
+                List<String> feaListContent = sFeatures.stream().filter(te -> featuresIds.contains(te.getId())).map(Features::getContent).collect(Collectors.toList());
+                feaListContent.forEach(te -> disclosures.append("(" + te + ")"));
                 disclosures.append("\n");
             }
             patentListMap.put("name", item.get("name"));
@@ -221,8 +233,8 @@ public class ReportDocumentService extends ServiceImpl<ReportDocumentMapper, Rep
             patentListMap.put("abstractStr", item.get("abstractStr"));
             patentListMap.put("compareFileName", "对比文件" + (i + 1));
             patentListMap.put("applicationDate", item.get("applicationDate"));
-            patentListMap.put("abstractPath", "http://139.224.24.90:8081"+item.get("abstractPath"));
-            patentListMap.put("disclosures",disclosures);
+            patentListMap.put("abstractPath", "http://139.224.24.90:8081" + item.get("abstractPath"));
+            patentListMap.put("disclosures", disclosures);
             patentListMaps.add(patentListMap);
             //给出现的专利添加别名
             OtherName.put(item.get("publicNo").toString(), ("D" + (i + 1)));
@@ -236,27 +248,27 @@ public class ReportDocumentService extends ServiceImpl<ReportDocumentMapper, Rep
             //获得单个对比方案的
             List<AssoScenarIOS> partScenariosRecords = scenariosRecords.stream().filter(item -> item.getScenariosID().equals(item1.getId())).collect(Collectors.toList());
             List<Integer> featureRecordsIds = partScenariosRecords.stream().map(AssoScenarIOS::getFeatureRecordID).collect(Collectors.toList());
-            List<AssoRecordsFeature> assoRecordsFeatures1 =   assoRecordsFeatures.stream().filter(item->featureRecordsIds.contains(item.getId())).collect(Collectors.toList());
-            List<Integer> partRecordIds= assoRecordsFeatures1.stream().map(AssoRecordsFeature::getRecordsId).collect(Collectors.toList());
+            List<AssoRecordsFeature> assoRecordsFeatures1 = assoRecordsFeatures.stream().filter(item -> featureRecordsIds.contains(item.getId())).collect(Collectors.toList());
+            List<Integer> partRecordIds = assoRecordsFeatures1.stream().map(AssoRecordsFeature::getRecordsId).collect(Collectors.toList());
             List<Integer> partFetIds = assoRecordsFeatures1.stream().map(AssoRecordsFeature::getFeatureId).collect(Collectors.toList());
             //获得共识特征的ID
-            List<Integer> comFetIds =partScenariosRecords.stream().map(AssoScenarIOS::getFeaturesID).collect(Collectors.toList());
+            List<Integer> comFetIds = partScenariosRecords.stream().map(AssoScenarIOS::getFeaturesID).collect(Collectors.toList());
             partFetIds.addAll(comFetIds);
             //获得单个对比方案的权要的所有特征
             List<Features> partFeatures = allFeatures.stream().filter(item -> partFetIds.contains(item.getId())).collect(Collectors.toList());
             List<CompareRecords> records = compareRecords.stream().filter(item -> partRecordIds.contains(item.getId())).collect(Collectors.toList());
             //获得单条权要所有的特征
-            List<Features> allRightFeatures =allFeatures.stream().filter(item ->item.getRightId().equals(item1.getRightId())).collect(Collectors.toList());
+            List<Features> allRightFeatures = allFeatures.stream().filter(item -> item.getRightId().equals(item1.getRightId())).collect(Collectors.toList());
             //存放单条对比结果的map
             Map<String, Object> temMap = new HashMap<>();
-            if (partFeatures.size()!=0&&partFeatures.get(0).getRightType().equals(1)) {
+            if (partFeatures.size() != 0 && partFeatures.get(0).getRightType().equals(1)) {
                 temMap.put("rightName", "独立" + partFeatures.get(0).getRightName());
             } else {
                 temMap.put("rightName", "附属" + partFeatures.get(0).getRightName());
             }
             temMap.put("rightId", item1.getRightId());
 
-          temMap.put("remark",item1.getContrastResult());
+            temMap.put("remark", item1.getContrastResult());
             // 从关联数据里获得特征id
             if (!rightIds.contains(item1.getRightId())) {
                 rightIds.add(item1.getRightId());
@@ -267,23 +279,23 @@ public class ReportDocumentService extends ServiceImpl<ReportDocumentMapper, Rep
                 Map<String, Object> map = new HashMap<>();
                 map.put("featureContent", tem.getContent());
                 AssoRecordsFeature assoRecordsFeature = finalAsso.stream().filter(item -> item.getFeatureId().equals(tem.getId())).findFirst().orElse(new AssoRecordsFeature());
-                map.put("compareResult", assoRecordsFeature.getComResult()!=null?assoRecordsFeature.getComResult():"");
+                map.put("compareResult", assoRecordsFeature.getComResult() != null ? assoRecordsFeature.getComResult() : "");
                 CompareRecords record = records.stream().filter(item -> item.getId().equals(assoRecordsFeature.getRecordsId())).findFirst().orElse(new CompareRecords());
-                String  compareContent ="";
+                String compareContent = "";
                 //获取对比内容
-             String content =  record.getContent()!=null?record.getContent():"";
-               //获得对比专利号
-                String patentNo =record.getPatentNo()!=null?record.getPatentNo():"";
+                String content = record.getContent() != null ? record.getContent() : "";
+                //获得对比专利号
+                String patentNo = record.getPatentNo() != null ? record.getPatentNo() : "";
                 if (OtherName.containsKey(patentNo)) {
                     patentNo = OtherName.get(patentNo).toString();
                 }
                 //获得解析过程
-                String paresingProcess =record.getParesingProcess()!=null?"("+record.getParesingProcess()+")":"";
-             compareContent =patentNo+":"+content+paresingProcess;
+                String paresingProcess = record.getParesingProcess() != null ? "(" + record.getParesingProcess() + ")" : "";
+                compareContent = patentNo + ":" + content + paresingProcess;
                 //获取对比专利号
                 map.put("compareContent", compareContent);
-                map.put("figure",fileUtils.getSystemPath()+record.getFilePath());
-                map.put("position",record.getFields()+"["+record.getPosition()+"]");
+                map.put("figure", fileUtils.getSystemPath() + record.getFilePath());
+                map.put("position", record.getFields() + "[" + record.getPosition() + "]");
                 maps.add(map);
             });
             //方案内容
@@ -320,16 +332,17 @@ public class ReportDocumentService extends ServiceImpl<ReportDocumentMapper, Rep
                         if (OtherName.containsKey(tmName)) {
                             tmName = OtherName.get(tmName).toString();
                         }
-                        if(!creativeFiles.contains(tmName)){
-                            creativeFiles.add(tmName);}
+                        if (!creativeFiles.contains(tmName)) {
+                            creativeFiles.add(tmName);
+                        }
                     }
             );
-            List<AssoScenarIOS> andRecords = partScenariosRecords.stream().filter(tm -> tm.getScenariosID().equals(item1.getId())&&tm.getFeaturesID()!=0).collect(Collectors.toList());
+            List<AssoScenarIOS> andRecords = partScenariosRecords.stream().filter(tm -> tm.getScenariosID().equals(item1.getId()) && tm.getFeaturesID() != 0).collect(Collectors.toList());
             if (andRecords.size() != 0) {
                 creativeFiles.add("C");
             }
-            String creative =creativeFiles.size()==0?"": StringUtils.join(creativeFiles, "+");
-            String novelty =noveltyFiles.size()==0?"": StringUtils.join(noveltyFiles, "-");
+            String creative = creativeFiles.size() == 0 ? "" : StringUtils.join(creativeFiles, "+");
+            String novelty = noveltyFiles.size() == 0 ? "" : StringUtils.join(noveltyFiles, "-");
             //新颖性
             temMap.put("novelty", novelty);
             //创造性
@@ -337,43 +350,44 @@ public class ReportDocumentService extends ServiceImpl<ReportDocumentMapper, Rep
             scenariosMaps.add(temMap);
 
         }
-        List<Map<String,Object>> allRightScenarios=new ArrayList<>();
-        List<Map<String,Object>> resultMaps =new ArrayList<>();
+        List<Map<String, Object>> allRightScenarios = new ArrayList<>();
+        List<Map<String, Object>> resultMaps = new ArrayList<>();
         rightIds.forEach(tem -> {
-            Map<String,Object> map =new HashMap<>();
-            Map<String,Object> resultMap =new HashMap<>();
+            Map<String, Object> map = new HashMap<>();
+            Map<String, Object> resultMap = new HashMap<>();
             List<Map<String, Object>> rightScenarios = new ArrayList<>();
             //存放新颖性信息
-            List<String> noveList=new ArrayList<>();
-            List<String> creaList=new ArrayList<>();
+            List<String> noveList = new ArrayList<>();
+            List<String> creaList = new ArrayList<>();
             //存放创造性信息
-            for (int t=0;t<scenariosMaps.size();t++){
-                Map<String,Object> item =scenariosMaps.get(t);
+            for (int t = 0; t < scenariosMaps.size(); t++) {
+                Map<String, Object> item = scenariosMaps.get(t);
                 if (item.get("rightId").equals(tem)) {
-                    item.put("scenariosName","对比组合"+(t+1));
+                    item.put("scenariosName", "对比组合" + (t + 1));
                     rightScenarios.add(item);
-                    if(item.get("novelty").toString()!="") {
-                        if(!noveList.contains(item.get("novelty").toString())){
-                            noveList.add(item.get("novelty").toString());}
+                    if (item.get("novelty").toString() != "") {
+                        if (!noveList.contains(item.get("novelty").toString())) {
+                            noveList.add(item.get("novelty").toString());
+                        }
                     }
-                    if(item.get("creative").toString()!=""){
-                        if(!creaList.contains(item.get("creative").toString())){
-                            creaList.add(item.get("creative").toString());}
+                    if (item.get("creative").toString() != "") {
+                        if (!creaList.contains(item.get("creative").toString())) {
+                            creaList.add(item.get("creative").toString());
+                        }
                     }
                 }
-
             }
-            map.put("rightScenrios",rightScenarios);
-            map.put("rightName",rightScenarios.get(0).get("rightName"));
-            String creative =creaList.size()==0?"": StringUtils.join(creaList, "、");
-            String novelty =noveList.size()==0?"": StringUtils.join(noveList, "-");
-            resultMap.put("rightName",rightScenarios.get(0).get("rightName"));
-            resultMap.put("rightNovelty",novelty);
-            resultMap.put("rightCreative",creative);
+            map.put("rightScenrios", rightScenarios);
+            map.put("rightName", rightScenarios.get(0).get("rightName"));
+            String creative = creaList.size() == 0 ? "" : StringUtils.join(creaList, "、");
+            String novelty = noveList.size() == 0 ? "" : StringUtils.join(noveList, "-");
+            resultMap.put("rightName", rightScenarios.get(0).get("rightName"));
+            resultMap.put("rightNovelty", novelty);
+            resultMap.put("rightCreative", creative);
             allRightScenarios.add(map);
             resultMaps.add(resultMap);
         });
-  //1.系统数据
+        //1.系统数据
         //存放单条对比结果的map
         Map<String, Object> map = new HashMap<>();
         String date = DateUtils.formatDate(new Date(), DateUtils.YYYY_MM_DD);
@@ -381,22 +395,62 @@ public class ReportDocumentService extends ServiceImpl<ReportDocumentMapper, Rep
         map.put("sys", new SystemMO(ds[0], ds[1], ds[2], "", "reportName"));
         map.put("patentList", patentListMaps);
         map.put("combinations", allRightScenarios);
-        map.put("allResults",resultMaps);
+        map.put("allResults", resultMaps);
         // 为表格的显示绑定行循环
         LoopRowTableRenderPolicy policy = new LoopRowTableRenderPolicy();
         HtmlRenderPolicy htmlRenderPolicy = new HtmlRenderPolicy();
         // 将bz设置为行循环绑定的数据源的key,即key是bz的value会在模板中的{{bz}}处进行解析
-        Configure configure = Configure.builder().bind("patentList", policy).bind("fileDetails", policy).bind("allResults", policy).bind("remark",htmlRenderPolicy).build();
+        Configure configure = Configure.builder().bind("patentList", policy).bind("fileDetails", policy).bind("allResults", policy).bind("remark", htmlRenderPolicy).build();
         // 读取模板、数据并渲染
         XWPFTemplate template = XWPFTemplate.compile(filePath, configure).render(map);
-return  template;
+        return template;
     }
-//
-//    private XWPFTemplate FTOtemplate(Integer reportId,String filePath){
-//
+
+
+    /**
+     * @param reportId
+     * @param filePath
+     * @return
+     * @description 装载FTO模板
+     */
+    private XWPFTemplate FTOtemplate(Integer reportId, String filePath, Integer templateId) throws IOException {
+        //根据报告ID获得自定义字段值的信息
+        List<Map<String, Object>> fieldMaps = reportFieldService.getFieldsMap(reportId);
+        //获得模板的配置信息
+        LambdaQueryWrapper<TemplateConfig> templateConfigWrapper = new LambdaQueryWrapper<TemplateConfig>();
+        templateConfigWrapper.eq(TemplateConfig::getTemplateId, templateId);
+        List<TemplateConfig> templateConfigs = templateConfigService.list(templateConfigWrapper);
+        List<Map<String, Object>> loadMaps = new ArrayList<>();
+        //根据配置信息装载
+        for (TemplateConfig item : templateConfigs) {
+            for (Map<String, Object> map : fieldMaps) {
+                //如果自定义字段的值映射到配置则装载
+                if (map.get("CName").toString().equals(item.getValueName())) {
+                    //装载
+                    map.put("CName", item.getMapName());
+                    map.put("order", item.getOrderNum());
+                    loadMaps.add(map);
+                }
+            }
+        }
+        List<Map<String, Object>> classifyMaps = new ArrayList<>();
+        //装载信息
+        for (Map<String, Object> map : loadMaps) {
+            Map<String, Object> classifyMap = new HashMap<>();
+            classifyMap.put("classify" + map.get("order"), map.get("CName"));
+            //根据自定义字段ID和值Id查询专利号
+            List<String> patentNos = reportFieldPatentLinkService.getPatentNos(Integer.parseInt(map.get("FId").toString()), Integer.parseInt(map.get("CId").toString()));
+            PatentVO patentVO = new PatentVO();
+            patentVO.setPatentNos(patentNos);
+            //根据专利号查询专利详细信息
+            String resBody = outInterfaceService.getPatentDTOListForRMS(patentVO);
+            JSONObject jsonObject = JSONObject.parseObject(resBody);
+            List<JSONObject> patentDTOS = JSON.parseArray(jsonObject.get("data").toString(), JSONObject.class);
+        }
+        XWPFTemplate template = null;
 //        XWPFTemplate template = XWPFTemplate.compile(filePath, configure).render(map);
-//        return template;
-//    }
+        return template;
+    }
 
 }
 

+ 16 - 2
RMS/src/main/java/cn/cslg/report/service/business/ReportFieldPatentLinkService.java

@@ -9,6 +9,7 @@ import cn.cslg.report.mapper.ReportFieldPatentLinkMapper;
 import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
 import com.baomidou.mybatisplus.core.toolkit.Wrappers;
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import io.swagger.v3.oas.models.security.SecurityScheme;
 import lombok.RequiredArgsConstructor;
 import org.springframework.context.annotation.Lazy;
 import org.springframework.stereotype.Service;
@@ -376,9 +377,22 @@ if(links.size()!=0){
         }
     }
 
+    /**
+     *
+     * @param FieldId
+     * @param valueId
+     * @return
+     */
+    public List<String> getPatentNos(Integer FieldId, Integer valueId){
+LambdaQueryWrapper<ReportFieldPatentLink> queryWrapper =new LambdaQueryWrapper<>();
+queryWrapper.select(ReportFieldPatentLink::getPatentNo);
+queryWrapper.eq(ReportFieldPatentLink::getFieldId,FieldId);
+queryWrapper.eq(ReportFieldPatentLink::getOptionId,valueId);
+List<ReportFieldPatentLink> reportFieldPatentLinks =this.list(queryWrapper);
+List<String> patentNos = reportFieldPatentLinks.stream().map(ReportFieldPatentLink::getPatentNo).collect(Collectors.toList());
+return  patentNos;
 
-
-
+}
 
 
 }

+ 72 - 1
RMS/src/main/java/cn/cslg/report/service/business/ReportFieldService.java

@@ -12,6 +12,7 @@ import cn.cslg.report.common.utils.SecurityUtils.LoginUtils;
 import cn.cslg.report.entity.*;
 import cn.cslg.report.entity.asso.AssoTaskPersonel;
 import cn.cslg.report.mapper.ReportFieldMapper;
+import com.baomidou.mybatisplus.core.conditions.Wrapper;
 import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
 import com.baomidou.mybatisplus.core.metadata.IPage;
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
@@ -800,7 +801,77 @@ public class ReportFieldService extends ServiceImpl<ReportFieldMapper, ReportFie
 
     }
 
-
+    /**
+     * @description 根据报告Id获得自定义字段信息
+     * @param reportId
+     * @return
+     */
+    public List<Map<String,Object>> getFieldsMap(Integer reportId) {
+        //根据reportId获得自定义字段
+         LambdaQueryWrapper<ReportField> reportFieldWrapper =new LambdaQueryWrapper<ReportField>();
+         reportFieldWrapper.eq(ReportField::getReportId,reportId);
+         List<ReportField> reportFields =this.list(reportFieldWrapper);
+         List<Map<String,Object>> lists =new ArrayList<Map<String,Object>>();
+         //根据自定义字段类型装载map
+         if(reportFields.size()!=0){
+             for (ReportField item :reportFields){
+                 int type1 = item.getType();
+                 switch (type1) {
+                     //数字
+                     case 0:
+                         //日期
+                     case 1:
+                         //文本
+                     case 2:
+                         LambdaQueryWrapper<ReportFieldText> queryWrapper = new LambdaQueryWrapper<>();
+                         queryWrapper.eq(ReportFieldText::getFieldId, item.getId());
+                         List<ReportFieldText> reportFieldTexts = reportFieldTextService.list(queryWrapper);
+                         reportFieldTexts.forEach(tem->{
+                             Map<String,Object> map =new HashMap<>();
+                             map.put("CId",tem.getId());
+                             map.put("FId",tem.getFieldId());
+                             map.put("CName",tem.getText());
+                             lists.add(map);
+                         }
+                         );
+                         break;
+
+                     //单选
+                     case 4:
+
+                         //多选
+                     case 5:
+                         LambdaQueryWrapper<ReportFieldOption> queryWrapper5 = new LambdaQueryWrapper<>();
+                         queryWrapper5.eq(ReportFieldOption::getFieldId,  item.getId());
+                         List<ReportFieldOption> reportFieldOption = reportFieldOptionService.list(queryWrapper5);
+                         reportFieldOption.forEach(tem -> {
+                             Map<String,Object> map =new HashMap<>();
+                             map.put("CId",tem.getId());
+                             map.put("FId",tem.getFieldId());
+                             map.put("CName",tem.getName());
+                             lists.add(map);
+                         });
+                         break;
+                     //树
+                     case 6:
+                         LambdaQueryWrapper<ReportFieldTree> queryWrapper6 = new LambdaQueryWrapper<>();
+                         queryWrapper6.eq(ReportFieldTree::getFieldId, item.getId());
+                         List<ReportFieldTree> reportFieldTrees = reportFieldTreeService.list(queryWrapper6);
+                         reportFieldTrees.forEach(tem -> {
+                             Map<String,Object> map =new HashMap<>();
+                             map.put("CId",tem.getId());
+                             map.put("FId",tem.getFieldId());
+                             map.put("CName",tem.getName());
+                             lists.add(map);
+                         });
+                         break;
+                 }
+
+
+             }
+         }
+        return lists;
+    }
 }
 
 

+ 93 - 12
RMS/src/main/java/cn/cslg/report/service/business/TaskService.java

@@ -1,16 +1,15 @@
 package cn.cslg.report.service.business;
 
 
+import cn.cslg.report.common.core.base.Constants;
 import cn.cslg.report.common.model.dto.TaskTDO;
 import cn.cslg.report.common.model.vo.*;
 import cn.cslg.report.common.model.vo.queryVo.QueryCMVO;
-import cn.cslg.report.common.utils.CacheUtils;
-import cn.cslg.report.common.utils.DataUtils;
-import cn.cslg.report.common.utils.LogExceptionUtil;
-import cn.cslg.report.common.utils.Response;
+import cn.cslg.report.common.utils.*;
 import cn.cslg.report.common.utils.SecurityUtils.LoginUtils;
 import cn.cslg.report.common.utils.message.MessageUtils;
 import cn.cslg.report.entity.*;
+import cn.cslg.report.entity.asso.AssoReportFile;
 import cn.cslg.report.entity.asso.AssoTaskPersonel;
 import cn.cslg.report.entity.asso.SyneryCode;
 import cn.cslg.report.entity.asso.Synery_CC;
@@ -126,12 +125,59 @@ public class TaskService extends ServiceImpl<TaskMapper, Task> {
      * @return
      * @function 查询任务
      */
-    public IPage<TaskReportVO> queryPageList(TaskVO taskVO) {
+    public IPage<TaskReportVO> queryPageList(TaskVO taskVO) throws IOException {
         taskVO.setLoginId(StpUtil.getLoginIdAsInt());
+        if(taskVO.getRoleInTask()==0&&taskVO.getTaskStatus()==0){
+            taskVO.setTaskStatuses(Arrays.asList(0,2));
+        }
+        else if(taskVO.getRoleInTask()==0&&taskVO.getTaskStatus()==1)
+        {
+            taskVO.setTaskStatuses(Arrays.asList(1));
+        }
+        else if(taskVO.getRoleInTask()==1&&taskVO.getTaskStatus()==0)
+        {
+            taskVO.setTaskStatuses(Arrays.asList(0));
+        }
+        else if(taskVO.getRoleInTask()==1&&taskVO.getTaskStatus()==1)
+        {
+            taskVO.setTaskStatuses(Arrays.asList(1,2));
+        }
         IPage<TaskReportVO> dataPage = baseMapper.queryTasks(new Page<>(taskVO.getCurrent(), taskVO.getSize()), taskVO);
+   List<TaskReportVO>  taskReportVOS =   dataPage.getRecords();
+   taskReportVOS =this.reTaskReportVOs(taskReportVOS);
+   dataPage.setRecords(taskReportVOS);
         return dataPage;
     }
 
+   public List<TaskReportVO> reTaskReportVOs(List<TaskReportVO>  taskReportVOS) throws IOException {
+        if(taskReportVOS.size()!=0){
+            //创建人Id
+            List<Integer> createIds = taskReportVOS.stream().map(TaskReportVO::getCreateID).collect(Collectors.toList());
+            //处理人Id
+            List<Integer> handleIds = taskReportVOS.stream().map(TaskReportVO::getHandlePersonId).collect(Collectors.toList());
+            createIds.addAll(handleIds);
+            String res1 = outInterfaceService.getPersonnelByIdsFromPCS(createIds);
+            JSONObject jsonObject1 = JSONObject.parseObject(res1);
+            //解析jason获得标的专利的权要
+            List<Personnel> personnels = JSON.parseArray(jsonObject1.getString("data"), Personnel.class);
+
+            for(TaskReportVO item :taskReportVOS){
+                //装载创建人名和负责人名
+                List<Personnel> mapCre = personnels.stream().filter(tem -> tem.getId().equals(item.getCreateID())).collect(Collectors.toList());
+                List<Personnel> mapDuty = personnels.stream().filter(tem -> tem.getId().equals(item.getHandlePersonId())).collect(Collectors.toList());
+                if(mapCre.size()!=0)
+                    item.setCreateName(mapCre.get(0).getPersonnelName());
+                if(mapDuty.size()!=0)
+                    item.setHandlePersonName(mapDuty.get(0).getPersonnelName());
+                //装载部门名
+
+            }
+        }
+        return taskReportVOS;
+   }
+
+
+
     /**
      * @function 获取对比任务
      */
@@ -491,7 +537,7 @@ public class TaskService extends ServiceImpl<TaskMapper, Task> {
      * @author :cj
      */
     @Transactional
-    public String finishTask(Integer id) {
+    public String finishTask(Integer id) throws IOException {
         LambdaQueryWrapper<Task> queryWrapper = new LambdaQueryWrapper<>();
         queryWrapper.eq(Task::getId, id);
         List<Task> list = this.list(queryWrapper);
@@ -502,12 +548,47 @@ public class TaskService extends ServiceImpl<TaskMapper, Task> {
         //增加完成时间
         simpleDateFormat.format(now);
         task.setFinishTime(now);
-        task.setTaskStatus(1);
-        //结果为已完成状态
-        task.setResult(1);
-        task.updateById();
-        return Response.success();
-    }
+        // 当是协同任务
+        if(task.getType()==1&&task.getTaskStatus()==0) {
+            task.setTaskStatus(2);
+            Map<String, Object> map = new LinkedHashMap<>();
+            map.put("title", "任务通知");
+            map.put("template", "mail/eTaskConfirm.html");
+            map.put("img", "\\src\\main\\resources\\mail\\logo.png");
+            if (task.getHandlePersonId() != null) {
+                String resBody = outInterfaceService.getPersonnelByIdsFromPCS(Arrays.asList(task.getHandlePersonId()));
+                JSONObject jsonObject = JSONObject.parseObject(resBody);
+                //解析jason获得标的专利的权要
+                List<Personnel> personnels = JSON.parseArray(jsonObject.getString("data"), Personnel.class);
+                map.put("value1", personnels.get(0).getPersonnelName());
+                map.put("value2", task.getTaskName());
+                map.put("email", personnels.get(0).getPersonnelEmail());
+                mailUtils.sendEmailMessage(map);
+            } else {
+                String orgin = task.getHandlePersonName();
+                String parStr = "\\<([^}]*)\\>";
+                Pattern pattern = Pattern.compile(parStr);
+                Matcher matcher = pattern.matcher(orgin);
+                if (matcher.find()) {
+                    String personName = orgin.substring(0, matcher.start());
+                    String email = matcher.group(0);
+                    email = email.replace("<", "");
+                    email = email.replace(">", "");
+                    map.put("value1", personName);
+                    map.put("value2", task.getTaskName());
+                    map.put("email", email);
+                    mailUtils.sendEmailMessage(map);
+                }
+            }
+        }
+            else {
+                    task.setTaskStatus(1);
+                }
+                //结果为已完成状态
+                task.setResult(1);
+                task.updateById();
+                return Response.success();
+            }
 
     /**
      * @param taskVO

+ 15 - 0
RMS/src/main/java/cn/cslg/report/service/business/TemplateConfigService.java

@@ -0,0 +1,15 @@
+package cn.cslg.report.service.business;
+
+import cn.cslg.report.entity.TemplateConfig;
+import cn.cslg.report.mapper.TemplateConfigMapper;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import lombok.RequiredArgsConstructor;
+import lombok.extern.slf4j.Slf4j;
+import org.springframework.context.annotation.Lazy;
+import org.springframework.stereotype.Service;
+
+@Service
+@Slf4j
+@RequiredArgsConstructor(onConstructor_ = {@Lazy})
+public class TemplateConfigService extends ServiceImpl<TemplateConfigMapper, TemplateConfig> {
+}

+ 5 - 3
RMS/src/main/resources/mapper/TaskMapper.xml

@@ -7,9 +7,11 @@
 <if test="param.type !=null">
  and a.TYPE =#{param.type}
 </if>
-        <if test="param.taskStatus !=null">
-and a.TASK_STATUS=#{param.taskStatus}
-
+        <if test="param.taskStatuses !=null and param.taskStatuses.size>0">
+and a.TASK_STATUS in
+            <foreach collection="param.taskStatuses" item="item" separator="," open="(" close=")">
+                #{item}
+            </foreach>
         </if>
         <if test="param.createName !=null and param.createName !='' ">
 and a.CREATE_NAME like concat('%', #{param.createName}, '%')

BIN
RMS/target/classes/cn/cslg/report/common/model/vo/TaskReportVO.class


BIN
RMS/target/classes/cn/cslg/report/common/model/vo/TaskVO$personPatents.class


BIN
RMS/target/classes/cn/cslg/report/common/model/vo/TaskVO.class


BIN
RMS/target/classes/cn/cslg/report/controller/BaseController.class


BIN
RMS/target/classes/cn/cslg/report/controller/ReportDocumentController.class


BIN
RMS/target/classes/cn/cslg/report/controller/TaskController.class


BIN
RMS/target/classes/cn/cslg/report/service/business/ReportDocumentService.class


BIN
RMS/target/classes/cn/cslg/report/service/business/ReportFieldPatentLinkService.class


BIN
RMS/target/classes/cn/cslg/report/service/business/ReportFieldService.class


BIN
RMS/target/classes/cn/cslg/report/service/business/TaskService.class


+ 5 - 3
RMS/target/classes/mapper/TaskMapper.xml

@@ -7,9 +7,11 @@
 <if test="param.type !=null">
  and a.TYPE =#{param.type}
 </if>
-        <if test="param.taskStatus !=null">
-and a.TASK_STATUS=#{param.taskStatus}
-
+        <if test="param.taskStatuses !=null and param.taskStatuses.size>0">
+and a.TASK_STATUS in
+            <foreach collection="param.taskStatuses" item="item" separator="," open="(" close=")">
+                #{item}
+            </foreach>
         </if>
         <if test="param.createName !=null and param.createName !='' ">
 and a.CREATE_NAME like concat('%', #{param.createName}, '%')