|
|
@@ -27,6 +27,7 @@ import com.goafanti.common.enums.PatentInfoFields;
|
|
|
import com.goafanti.common.enums.PatentInfoStatus;
|
|
|
import com.goafanti.common.model.Admin;
|
|
|
import com.goafanti.common.model.AftFile;
|
|
|
+import com.goafanti.common.model.OrganizationIdentity;
|
|
|
import com.goafanti.common.model.PatentInfo;
|
|
|
import com.goafanti.common.model.PatentLog;
|
|
|
import com.goafanti.common.model.User;
|
|
|
@@ -62,6 +63,8 @@ public class PatentApiController extends CertifyApiController {
|
|
|
private UserService userService;
|
|
|
@Resource
|
|
|
private AftFileService aftFileService;
|
|
|
+ @Resource
|
|
|
+ private OrganizationIdentityService organizationIdentityService;
|
|
|
|
|
|
@Value(value = "${upload.private.path}")
|
|
|
private String uploadPrivatePath = null;
|
|
|
@@ -83,10 +86,12 @@ public class PatentApiController extends CertifyApiController {
|
|
|
}
|
|
|
|
|
|
AttachmentType attachmentType = AttachmentType.getField(sign);
|
|
|
- if (attachmentType == AttachmentType.PATENT_PRORY_STATEMENT || attachmentType == AttachmentType.PATENT_WRITING
|
|
|
+ if (attachmentType == AttachmentType.PATENT_WRITING
|
|
|
|| attachmentType == AttachmentType.AUTHORIZATION_NOTICE
|
|
|
|| attachmentType == AttachmentType.PATENT_CERTIFICATE) {
|
|
|
res.setData(handleFiles(res, "/patent/", true, req, sign, TokenManager.getUserId()));
|
|
|
+ } else if (attachmentType == AttachmentType.PATENT_PRORY_STATEMENT){
|
|
|
+ res.setData(handleFile(res, "/identity/", true, req, sign));
|
|
|
} else {
|
|
|
res.getError().add(buildError(ErrorConstants.PARAM_ERROR, "", "附件标示"));
|
|
|
}
|
|
|
@@ -122,7 +127,8 @@ public class PatentApiController extends CertifyApiController {
|
|
|
|| attachmentType == AttachmentType.AUTHORIZATION_NOTICE
|
|
|
|| attachmentType == AttachmentType.PATENT_CERTIFICATE) {
|
|
|
if (attachmentType == AttachmentType.PATENT_PRORY_STATEMENT) {
|
|
|
- downloadFile(response, pi.getPatentProryStatementDownloadFileName(), pi.getPatentProryStatementUrl());
|
|
|
+ OrganizationIdentity oi = organizationIdentityService.selectOrgIdentityByUserId(pi.getUid());
|
|
|
+ downloadFile(response, oi.getPatentProryStatementDownloadFileName(), oi.getPatentProryStatementUrl());
|
|
|
} else if (attachmentType == AttachmentType.PATENT_WRITING) {
|
|
|
downloadFile(response, pi.getPatentWritingDownloadFileName(), pi.getPatentWritingUrl());
|
|
|
} else if (attachmentType == AttachmentType.AUTHORIZATION_NOTICE) {
|
|
|
@@ -297,17 +303,14 @@ public class PatentApiController extends CertifyApiController {
|
|
|
/**
|
|
|
* 获取公司
|
|
|
*//*
|
|
|
- @RequestMapping(value = "/getUnitNames", method = RequestMethod.GET)
|
|
|
- public Result getUnitNames() {
|
|
|
- Result res = new Result();
|
|
|
- List<OrganizationIdentity> list = organizationIdentityServivce.selectAllOrgIndentity();
|
|
|
- Map<String, String> map = new TreeMap<String, String>();
|
|
|
- for (OrganizationIdentity o : list) {
|
|
|
- map.put(o.getUid(), o.getUnitName());
|
|
|
- }
|
|
|
- res.setData(map);
|
|
|
- return res;
|
|
|
- }*/
|
|
|
+ * @RequestMapping(value = "/getUnitNames", method = RequestMethod.GET)
|
|
|
+ * public Result getUnitNames() { Result res = new Result();
|
|
|
+ * List<OrganizationIdentity> list =
|
|
|
+ * organizationIdentityServivce.selectAllOrgIndentity(); Map<String,
|
|
|
+ * String> map = new TreeMap<String, String>(); for
|
|
|
+ * (OrganizationIdentity o : list) { map.put(o.getUid(),
|
|
|
+ * o.getUnitName()); } res.setData(map); return res; }
|
|
|
+ */
|
|
|
|
|
|
/**
|
|
|
* 获取管理员
|