|
@@ -49,12 +49,18 @@ public class CompareMessageService extends ServiceImpl<CompareMessageMapper, Com
|
|
// 获取登录人信息
|
|
// 获取登录人信息
|
|
PersonnelVO personnelVO = cacheUtils.getLoginUser(StpUtil.getLoginIdAsInt());
|
|
PersonnelVO personnelVO = cacheUtils.getLoginUser(StpUtil.getLoginIdAsInt());
|
|
List<CompareMessage> compareMessages = new ArrayList<>();
|
|
List<CompareMessage> compareMessages = new ArrayList<>();
|
|
|
|
+ Features feature=new Features();
|
|
//根据登录人Id,报告Id,标的专利号查询特征
|
|
//根据登录人Id,报告Id,标的专利号查询特征
|
|
LambdaQueryWrapper<Features> wrapper = new LambdaQueryWrapper<>();
|
|
LambdaQueryWrapper<Features> wrapper = new LambdaQueryWrapper<>();
|
|
if (vos.get(0).getTaskId() != null && vos.get(0).getSignPatentNo() != null) {
|
|
if (vos.get(0).getTaskId() != null && vos.get(0).getSignPatentNo() != null) {
|
|
wrapper.eq(Features::getTaskId, vos.get(0).getTaskId())
|
|
wrapper.eq(Features::getTaskId, vos.get(0).getTaskId())
|
|
.eq(Features::getSignPatentNo, vos.get(0).getSignPatentNo());
|
|
.eq(Features::getSignPatentNo, vos.get(0).getSignPatentNo());
|
|
- Features feature = featureService.list(wrapper).get(0);
|
|
|
|
|
|
+ feature = featureService.list(wrapper).get(0);
|
|
|
|
+ }if(vos.get(0).getReportId()!=null && vos.get(0).getSignPatentNo() != null ){
|
|
|
|
+ wrapper.eq(Features::getReportId, vos.get(0).getReportId())
|
|
|
|
+ .eq(Features::getSignPatentNo, vos.get(0).getSignPatentNo());
|
|
|
|
+ feature = featureService.list(wrapper).get(0);
|
|
|
|
+ }
|
|
//根据特征Id删除对比记录
|
|
//根据特征Id删除对比记录
|
|
List<Features> features = featureService.list(wrapper);
|
|
List<Features> features = featureService.list(wrapper);
|
|
if (features != null && features.size() > 0) {
|
|
if (features != null && features.size() > 0) {
|
|
@@ -70,7 +76,9 @@ public class CompareMessageService extends ServiceImpl<CompareMessageMapper, Com
|
|
Features features1 = new Features();
|
|
Features features1 = new Features();
|
|
features1.setContent(vos.get(i).getContent());
|
|
features1.setContent(vos.get(i).getContent());
|
|
features1.setFeaturesOrder(order);
|
|
features1.setFeaturesOrder(order);
|
|
- features1.setTaskId(vos.get(i).getTaskId());
|
|
|
|
|
|
+ if(vos.get(i).getTaskId()!=null) {
|
|
|
|
+ features1.setTaskId(vos.get(i).getTaskId());
|
|
|
|
+ }
|
|
features1.setSplitType(feature.getSplitType());
|
|
features1.setSplitType(feature.getSplitType());
|
|
features1.setSplitBy(feature.getSplitBy());
|
|
features1.setSplitBy(feature.getSplitBy());
|
|
features1.setPartnerId(personnelVO.getId());
|
|
features1.setPartnerId(personnelVO.getId());
|
|
@@ -88,11 +96,13 @@ public class CompareMessageService extends ServiceImpl<CompareMessageMapper, Com
|
|
compareMessage.setTargetDescription(vos.get(i).getTargetDescription());
|
|
compareMessage.setTargetDescription(vos.get(i).getTargetDescription());
|
|
compareMessage.setCompareDescription(vos.get(i).getCompareDescription());
|
|
compareMessage.setCompareDescription(vos.get(i).getCompareDescription());
|
|
compareMessage.setReportId(feature.getReportId());
|
|
compareMessage.setReportId(feature.getReportId());
|
|
- compareMessage.setTaskId(feature.getTaskId());
|
|
|
|
|
|
+ if(feature.getTaskId()!=null) {
|
|
|
|
+ compareMessage.setTaskId(feature.getTaskId());
|
|
|
|
+ }
|
|
compareMessages.add(compareMessage);
|
|
compareMessages.add(compareMessage);
|
|
order += 1;
|
|
order += 1;
|
|
}
|
|
}
|
|
- }
|
|
|
|
|
|
+
|
|
return this.saveBatch(compareMessages);
|
|
return this.saveBatch(compareMessages);
|
|
}
|
|
}
|
|
|
|
|
|
@@ -192,7 +202,7 @@ public class CompareMessageService extends ServiceImpl<CompareMessageMapper, Com
|
|
patentRightVo.setSignPatentNo(patentNo);
|
|
patentRightVo.setSignPatentNo(patentNo);
|
|
patentRightVos.add(patentRightVo);
|
|
patentRightVos.add(patentRightVo);
|
|
}
|
|
}
|
|
- Map<String, Object> map1 = assoTaskPatentSplitService.getSplitMessage(taskId, patentNo);
|
|
|
|
|
|
+ Map<String, Object> map1 = assoTaskPatentSplitService.getSplitMessage(taskId, patentNo,reportId);
|
|
Map<String, Object> map = new HashMap<String, Object>();
|
|
Map<String, Object> map = new HashMap<String, Object>();
|
|
map.put("patentRightVos", patentRightVos);
|
|
map.put("patentRightVos", patentRightVos);
|
|
map.put("splitBy", map1.get("splitBy"));
|
|
map.put("splitBy", map1.get("splitBy"));
|
|
@@ -322,7 +332,7 @@ public class CompareMessageService extends ServiceImpl<CompareMessageMapper, Com
|
|
patentRightVo.setSignPatentNo(patentNo);
|
|
patentRightVo.setSignPatentNo(patentNo);
|
|
patentRightVos.add(patentRightVo);
|
|
patentRightVos.add(patentRightVo);
|
|
}
|
|
}
|
|
- Map<String, Object> map1 = assoTaskPatentSplitService.getSplitMessage(null, patentNo);
|
|
|
|
|
|
+ Map<String, Object> map1 = assoTaskPatentSplitService.getSplitMessage(null, patentNo,reportId);
|
|
Map<String, Object> map = new HashMap<String, Object>();
|
|
Map<String, Object> map = new HashMap<String, Object>();
|
|
map.put("patentRightVos", patentRightVos);
|
|
map.put("patentRightVos", patentRightVos);
|
|
map.put("splitBy", map1.get("splitBy"));
|
|
map.put("splitBy", map1.get("splitBy"));
|