|
|
@@ -27,6 +27,7 @@ import com.goafanti.common.model.OrgActivity;
|
|
|
import com.goafanti.common.model.OrgActivityCost;
|
|
|
import com.goafanti.common.model.OrgAnnualReport;
|
|
|
import com.goafanti.common.model.OrgCognizance;
|
|
|
+import com.goafanti.common.model.OrgCognizanceLog;
|
|
|
import com.goafanti.common.model.OrgFinance;
|
|
|
import com.goafanti.common.model.OrgHonorDatum;
|
|
|
import com.goafanti.common.model.OrgIntellectualProperty;
|
|
|
@@ -54,6 +55,7 @@ import com.goafanti.techservice.cognizance.bo.CognizanceResearchCostBo;
|
|
|
import com.goafanti.techservice.cognizance.service.OrgActivityCostService;
|
|
|
import com.goafanti.techservice.cognizance.service.OrgActivityService;
|
|
|
import com.goafanti.techservice.cognizance.service.OrgAnnualReportService;
|
|
|
+import com.goafanti.techservice.cognizance.service.OrgCognizanceLogService;
|
|
|
import com.goafanti.techservice.cognizance.service.OrgCognizanceService;
|
|
|
import com.goafanti.techservice.cognizance.service.OrgFinanceService;
|
|
|
import com.goafanti.techservice.cognizance.service.OrgHonorDatumService;
|
|
|
@@ -100,6 +102,8 @@ public class CognizanceApiController extends BaseApiController {
|
|
|
private OrgCognizanceService orgCognizanceService;
|
|
|
@Resource
|
|
|
private OrgAnnualReportService orgAnnualReportService;
|
|
|
+ @Resource
|
|
|
+ private OrgCognizanceLogService orgCognizanceLogService;
|
|
|
|
|
|
/**
|
|
|
* 企业研究开发活动情况表入口
|
|
|
@@ -616,7 +620,7 @@ public class CognizanceApiController extends BaseApiController {
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
- * 高企相关材料上传(技术协议除外)
|
|
|
+ * 高企相关材料上传
|
|
|
*
|
|
|
* @param req
|
|
|
* @param sign
|
|
|
@@ -629,19 +633,6 @@ public class CognizanceApiController extends BaseApiController {
|
|
|
return res;
|
|
|
}
|
|
|
|
|
|
- /**
|
|
|
- * 技术协议上传
|
|
|
- * @param req
|
|
|
- * @param uid
|
|
|
- * @param id
|
|
|
- * @return
|
|
|
- */
|
|
|
- /*@RequestMapping(value = "/uploadProtocol", method = RequestMethod.POST)
|
|
|
- public Result uploadProtocolFile(HttpServletRequest req, String uid, String id){
|
|
|
- Result res = new Result();
|
|
|
- res.setData(handleProtocolFile(res, "/cognizance/", true , req, uid));
|
|
|
- return res;
|
|
|
- }*/
|
|
|
|
|
|
/**
|
|
|
* 科技成果转化情况列表入口
|
|
|
@@ -927,7 +918,7 @@ public class CognizanceApiController extends BaseApiController {
|
|
|
* @return
|
|
|
*/
|
|
|
@RequestMapping(value = "/applyCognizance", method = RequestMethod.POST)
|
|
|
- public Result applyCognizance(String contacts, String comment, String consultant, Integer year){
|
|
|
+ public Result applyCognizance(String contacts, String comment, Integer year, Integer state){
|
|
|
Result res = new Result();
|
|
|
if (null == year){
|
|
|
res.getError().add(buildError(ErrorConstants.DUPLICATE_DATA_ERROR, "申请认定年份不能为空!"));
|
|
|
@@ -937,10 +928,20 @@ public class CognizanceApiController extends BaseApiController {
|
|
|
c.setUid(TokenManager.getUserId());
|
|
|
c.setContacts(contacts);
|
|
|
c.setComment(comment);
|
|
|
- c.setConsultant(consultant);
|
|
|
c.setDeletedSign(0);
|
|
|
c.setYear(year);
|
|
|
orgCognizanceService.insert(c);
|
|
|
+
|
|
|
+ OrgCognizanceLog log = new OrgCognizanceLog();
|
|
|
+ log.setId(UUID.randomUUID().toString());
|
|
|
+ log.setCid(c.getId());
|
|
|
+ Calendar now = Calendar.getInstance();
|
|
|
+ now.set(Calendar.MILLISECOND, 0);
|
|
|
+ log.setRecordTime(now.getTime());
|
|
|
+ log.setState(state);
|
|
|
+ log.setComment(comment);
|
|
|
+ log.setPrincipal(userService.selectByPrimaryKey(TokenManager.getUserId()).getAid());
|
|
|
+ orgCognizanceLogService.insert(log);
|
|
|
return res;
|
|
|
}
|
|
|
|
|
|
@@ -1100,7 +1101,8 @@ public class CognizanceApiController extends BaseApiController {
|
|
|
String uid) {
|
|
|
List<MultipartFile> files = getFiles(req);
|
|
|
MultipartFile mf = files.get(0);
|
|
|
- String fileName = FileUtils.mosaicFileName(mf, isPrivate, sign, path, StringUtils.isBlank(uid) ? TokenManager.getUserId() : uid);
|
|
|
+
|
|
|
+ String fileName = FileUtils.mosaicFileName(mf, isPrivate, sign, path, StringUtils.isBlank(uid) ? TokenManager.getUserId() : uid);
|
|
|
if (!files.isEmpty()) {
|
|
|
try {
|
|
|
mf.transferTo(toPrivateFile(fileName));
|