|
@@ -673,18 +673,32 @@ public class UploadPatentBatchService {
|
|
|
patent.setName(patentCell.getTitle());
|
|
|
//设置公开日
|
|
|
SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy.MM.dd");
|
|
|
- Date date = simpleDateFormat.parse(patentCell.getPubilcDate());
|
|
|
- Integer ts = (int)date.getTime();
|
|
|
- patent.setPublicDate(ts);
|
|
|
+ if(patentCell.getPubilcDate()!=null) {
|
|
|
+ Date date = simpleDateFormat.parse(patentCell.getPubilcDate());
|
|
|
+ Integer ts = (int) date.getTime();
|
|
|
+ patent.setPublicDate(ts);
|
|
|
+ }
|
|
|
+ //设置申请号
|
|
|
+ patent.setApplicationNo(patentCell.getApplicationNo());
|
|
|
+ //设置申请日
|
|
|
+ if(patentCell.getApplicationDate()!=null) {
|
|
|
+ Date date = simpleDateFormat.parse(patentCell.getApplicationDate());
|
|
|
+ Integer ts = (int) date.getTime();
|
|
|
+ patent.setApplicationDate(ts);
|
|
|
+ }
|
|
|
//设置摘要附图
|
|
|
patent.setAbstractPath(patentCell.getPicUrl());
|
|
|
//设置pdf文档
|
|
|
patentInstructionService.edit( patentCell.getPatentNo(),patentCell.getPdf());
|
|
|
//设置公开号
|
|
|
- patent.setPublicNo(patentCell.getPublicAccreditNo());
|
|
|
+ patent.setPublicNo(patentCell.getPublicNo());
|
|
|
uploadParamsVO.setSimpleStatus(patentCell.getStatue());
|
|
|
uploadParamsVO.setPatent(patent);
|
|
|
getOneOrInsertOne(uploadParamsVO);
|
|
|
+ //装载代理机构
|
|
|
+ if (patentCell.getAgency() != null) {
|
|
|
+ uploadParamsVO.getPatent().setAgencyId(patentAgencyService.getAgencyStringIdByName(patentCell.getAgency()));
|
|
|
+ }
|
|
|
try {
|
|
|
//专利信息 OS_PATENT
|
|
|
if (uploadParamsVO.getPatent() != null) {
|
|
@@ -707,18 +721,36 @@ public class UploadPatentBatchService {
|
|
|
if (uploadParamsVO.getPatentInstructionText() != null) {
|
|
|
patentInstructionTextBusiness(uploadParamsVO);
|
|
|
}
|
|
|
- //简单同族 OS_PATENT_SIMPLEFAMILY
|
|
|
- patentSimplyFamilyBusiness(uploadParamsVO);
|
|
|
//发明人 OS_PATENT_INVENTOR
|
|
|
- patentInventorBusiness(uploadParamsVO);
|
|
|
+ if(patentCell.getInventors().size()!=0) {
|
|
|
+ PatentInventorParams patentInventorParams = new PatentInventorParams();
|
|
|
+ patentInventorParams.setPatentId(uploadParamsVO.getPatent().getId());
|
|
|
+ patentInventorParams.setNameList(patentCell.getInventors());
|
|
|
+ patentInventorParams.setAddressList(new ArrayList<>());
|
|
|
+ patentInventorService.updatePatentInventor(patentInventorParams);
|
|
|
+ }
|
|
|
//申请人(原始)/权利人(当前) OS_PATENT_APPLICATION || OS_APPLICATION_ATTR
|
|
|
+ uploadParamsVO.setPatentApplicantCurrentName(patentCell.getApplicationCurrents());
|
|
|
+ uploadParamsVO.setPatentApplicantOriginalName(patentCell.getApplicationPersons());
|
|
|
patentApplicationBusiness(uploadParamsVO);
|
|
|
//申请人地址 OS_PATENT_APPLICATION
|
|
|
+ uploadParamsVO.setPatentApplicantOriginalAddress(patentCell.getApplicationAddress());
|
|
|
patentApplicationAddressBusiness(uploadParamsVO);
|
|
|
//分类号关联 OS_PATENT_TYPENO
|
|
|
+ uploadParamsVO.setIpcList(patentCell.getIpc());
|
|
|
+ uploadParamsVO.setMainIpc(patentCell.getMainIpc());
|
|
|
patentTypeNoBusiness(uploadParamsVO);
|
|
|
+ //代理人 OS_PATENT_AGENT
|
|
|
+ if(patentCell.getAgencyPersons()!=null&&patentCell.getAgencyPersons().size()!=0) {
|
|
|
+ PatentAgentParams patentAgentParams = new PatentAgentParams();
|
|
|
+ patentAgentParams.setPatentId(uploadParamsVO.getPatent().getId());
|
|
|
+ patentAgentParams.setAgent(patentCell.getAgencyPersons());
|
|
|
+ patentAgentService.updatePatentAgent(patentAgentParams);
|
|
|
+ }
|
|
|
//事务信息 OS_PATENT_AFFAIR
|
|
|
- patentAffairBusiness(uploadParamsVO);
|
|
|
+ if(patentCell.getPatentAffairs()!=null&&patentCell.getPatentAffairs().size()>0) {
|
|
|
+ patentAffairService.updatePatientAffairs(patentCell.getPatentAffairs(), uploadParamsVO.getPatent().getId());
|
|
|
+ }
|
|
|
//当专题库id不为null时添加专利到专题库
|
|
|
if(patentCell.getProjectId()!=null){
|
|
|
projectPatentLinkService.updateProjectPatent(patentCell.getProjectId(),uploadParamsVO.getPatent().getId());
|