|
|
@@ -1,6 +1,7 @@
|
|
|
package com.goafanti.demand.service.impl;
|
|
|
|
|
|
import java.text.ParseException;
|
|
|
+import java.util.ArrayList;
|
|
|
import java.util.Calendar;
|
|
|
import java.util.Date;
|
|
|
import java.util.HashMap;
|
|
|
@@ -53,96 +54,11 @@ public class DemandServiceImpl extends BaseMybatisDao<DemandMapper> implements D
|
|
|
Integer serialNumber, String name, String keyword, Integer infoSources, Integer demandType,
|
|
|
String validityPeriodStartDate, String validityPeriodEndDate, String username, Integer status,
|
|
|
Integer releaseStatus, String releaseDateStartDate, String releaseDateEndDate, Integer pNo, Integer pSize) {
|
|
|
- Map<String, Object> params = new HashMap<>();
|
|
|
- Date vStart = null;
|
|
|
- Date vEnd = null;
|
|
|
- Date rStart = null;
|
|
|
- Date rEnd = null;
|
|
|
-
|
|
|
- if (!StringUtils.isBlank(validityPeriodStartDate)) {
|
|
|
- try {
|
|
|
- vStart = DateUtils.parseDate(validityPeriodStartDate, AFTConstants.YYYYMMDD);
|
|
|
- } catch (ParseException e) {
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
- if (!StringUtils.isBlank(validityPeriodEndDate)) {
|
|
|
- try {
|
|
|
- vEnd = DateUtils.parseDate(validityPeriodEndDate, AFTConstants.YYYYMMDD);
|
|
|
- } catch (ParseException e) {
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
- if (!StringUtils.isBlank(releaseDateStartDate)) {
|
|
|
- try {
|
|
|
- rStart = DateUtils.parseDate(releaseDateStartDate, AFTConstants.YYYYMMDD);
|
|
|
- } catch (ParseException e) {
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
- if (!StringUtils.isBlank(releaseDateEndDate)) {
|
|
|
- try {
|
|
|
- rEnd = DateUtils.parseDate(releaseDateEndDate, AFTConstants.YYYYMMDD);
|
|
|
- } catch (ParseException e) {
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
- if (null != vStart) {
|
|
|
- params.put("vStart", vStart);
|
|
|
- }
|
|
|
-
|
|
|
- if (null != vEnd) {
|
|
|
- params.put("vEnd", vEnd);
|
|
|
- }
|
|
|
-
|
|
|
- if (null != rStart) {
|
|
|
- params.put("rStart", rStart);
|
|
|
- }
|
|
|
-
|
|
|
- if (null != rEnd) {
|
|
|
- params.put("rEnd", rEnd);
|
|
|
- }
|
|
|
-
|
|
|
- if (null != auditStatus) {
|
|
|
- params.put("auditStatus", auditStatus);
|
|
|
- }
|
|
|
-
|
|
|
- if (!StringUtils.isBlank(province)) {
|
|
|
- params.put("province", province);
|
|
|
- }
|
|
|
-
|
|
|
- if (null != serialNumber) {
|
|
|
- params.put("serialNumber", serialNumber);
|
|
|
- }
|
|
|
-
|
|
|
- if (!StringUtils.isBlank(name)) {
|
|
|
- params.put("name", name);
|
|
|
- }
|
|
|
-
|
|
|
- if (!StringUtils.isBlank(keyword)) {
|
|
|
- params.put("keyword", keyword);
|
|
|
- }
|
|
|
-
|
|
|
- if (!StringUtils.isBlank(username)) {
|
|
|
- params.put("username", username);
|
|
|
- }
|
|
|
-
|
|
|
- if (null != infoSources) {
|
|
|
- params.put("infoSources", infoSources);
|
|
|
- }
|
|
|
-
|
|
|
- if (null != demandType) {
|
|
|
- params.put("demandType", demandType);
|
|
|
- }
|
|
|
-
|
|
|
- if (null != status) {
|
|
|
- params.put("status", status);
|
|
|
- }
|
|
|
-
|
|
|
- if (null != releaseStatus) {
|
|
|
- params.put("releaseStatus", releaseStatus);
|
|
|
- }
|
|
|
-
|
|
|
+
|
|
|
+ Map<String, Object> params = disposeParams(auditStatus, province, serialNumber, name, keyword, infoSources,
|
|
|
+ demandType, validityPeriodStartDate, validityPeriodEndDate, username, status, releaseStatus,
|
|
|
+ releaseDateStartDate, releaseDateEndDate);
|
|
|
+
|
|
|
if (pNo == null || pNo < 0) {
|
|
|
pNo = 1;
|
|
|
}
|
|
|
@@ -174,95 +90,9 @@ public class DemandServiceImpl extends BaseMybatisDao<DemandMapper> implements D
|
|
|
Integer serialNumber, String name, String keyword, Integer infoSources, Integer demandType,
|
|
|
String validityPeriodStartDate, String validityPeriodEndDate, String username, Integer status,
|
|
|
Integer releaseStatus, String releaseDateStartDate, String releaseDateEndDate, Integer pNo, Integer pSize) {
|
|
|
- Map<String, Object> params = new HashMap<>();
|
|
|
- Date vStart = null;
|
|
|
- Date vEnd = null;
|
|
|
- Date rStart = null;
|
|
|
- Date rEnd = null;
|
|
|
-
|
|
|
- if (!StringUtils.isBlank(validityPeriodStartDate)) {
|
|
|
- try {
|
|
|
- vStart = DateUtils.parseDate(validityPeriodStartDate, AFTConstants.YYYYMMDD);
|
|
|
- } catch (ParseException e) {
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
- if (!StringUtils.isBlank(validityPeriodEndDate)) {
|
|
|
- try {
|
|
|
- vEnd = DateUtils.parseDate(validityPeriodEndDate, AFTConstants.YYYYMMDD);
|
|
|
- } catch (ParseException e) {
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
- if (!StringUtils.isBlank(releaseDateStartDate)) {
|
|
|
- try {
|
|
|
- rStart = DateUtils.parseDate(releaseDateStartDate, AFTConstants.YYYYMMDD);
|
|
|
- } catch (ParseException e) {
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
- if (!StringUtils.isBlank(releaseDateEndDate)) {
|
|
|
- try {
|
|
|
- rEnd = DateUtils.parseDate(releaseDateEndDate, AFTConstants.YYYYMMDD);
|
|
|
- } catch (ParseException e) {
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
- if (null != vStart) {
|
|
|
- params.put("vStart", vStart);
|
|
|
- }
|
|
|
-
|
|
|
- if (null != vEnd) {
|
|
|
- params.put("vEnd", vEnd);
|
|
|
- }
|
|
|
-
|
|
|
- if (null != rStart) {
|
|
|
- params.put("rStart", rStart);
|
|
|
- }
|
|
|
-
|
|
|
- if (null != rEnd) {
|
|
|
- params.put("rEnd", rEnd);
|
|
|
- }
|
|
|
-
|
|
|
- if (null != auditStatus) {
|
|
|
- params.put("auditStatus", auditStatus);
|
|
|
- }
|
|
|
-
|
|
|
- if (!StringUtils.isBlank(province)) {
|
|
|
- params.put("province", province);
|
|
|
- }
|
|
|
-
|
|
|
- if (null != serialNumber) {
|
|
|
- params.put("serialNumber", serialNumber);
|
|
|
- }
|
|
|
-
|
|
|
- if (!StringUtils.isBlank(name)) {
|
|
|
- params.put("name", name);
|
|
|
- }
|
|
|
-
|
|
|
- if (!StringUtils.isBlank(keyword)) {
|
|
|
- params.put("keyword", keyword);
|
|
|
- }
|
|
|
-
|
|
|
- if (!StringUtils.isBlank(username)) {
|
|
|
- params.put("username", username);
|
|
|
- }
|
|
|
-
|
|
|
- if (null != infoSources) {
|
|
|
- params.put("infoSources", infoSources);
|
|
|
- }
|
|
|
-
|
|
|
- if (null != demandType) {
|
|
|
- params.put("demandType", demandType);
|
|
|
- }
|
|
|
-
|
|
|
- if (null != status) {
|
|
|
- params.put("status", status);
|
|
|
- }
|
|
|
-
|
|
|
- if (null != releaseStatus) {
|
|
|
- params.put("releaseStatus", releaseStatus);
|
|
|
- }
|
|
|
+ Map<String, Object> params = disposeParams(auditStatus, province, serialNumber, name, keyword, infoSources,
|
|
|
+ demandType, validityPeriodStartDate, validityPeriodEndDate, username, status, releaseStatus,
|
|
|
+ releaseDateStartDate, releaseDateEndDate);
|
|
|
|
|
|
if (pNo == null || pNo < 0) {
|
|
|
pNo = 1;
|
|
|
@@ -359,17 +189,93 @@ public class DemandServiceImpl extends BaseMybatisDao<DemandMapper> implements D
|
|
|
|
|
|
@SuppressWarnings("unchecked")
|
|
|
@Override
|
|
|
- public Pagination<DemandListBo> listDemand(Integer auditStatus, Integer serialNumber, String name, String keyword, Integer demandType,
|
|
|
- String validityPeriodStartDate, String validityPeriodEndDate, Integer status, Integer releaseStatus,
|
|
|
- String releaseDateStartDate, String releaseDateEndDate, Integer pNo, Integer pSize) {
|
|
|
+ public Pagination<DemandListBo> listDemand(Integer auditStatus, Integer serialNumber, String name, String keyword,
|
|
|
+ Integer demandType, String validityPeriodStartDate, String validityPeriodEndDate, Integer status,
|
|
|
+ Integer releaseStatus, String releaseDateStartDate, String releaseDateEndDate, Integer pNo, Integer pSize) {
|
|
|
+ Map<String, Object> params = disposeParams(auditStatus, null, serialNumber, name, keyword, null,
|
|
|
+ demandType, validityPeriodStartDate, validityPeriodEndDate, null, status, releaseStatus,
|
|
|
+ releaseDateStartDate, releaseDateEndDate);
|
|
|
+
|
|
|
+ params.put("employerId", TokenManager.getUserId());
|
|
|
+
|
|
|
+
|
|
|
+ if (pNo == null || pNo < 0) {
|
|
|
+ pNo = 1;
|
|
|
+ }
|
|
|
+
|
|
|
+ if (pSize == null || pSize < 0) {
|
|
|
+ pSize = 10;
|
|
|
+ }
|
|
|
+ return (Pagination<DemandListBo>) findPage("findDemandListByPage", "findDemandCount", params, pNo, pSize);
|
|
|
+ }
|
|
|
+
|
|
|
+ @Override
|
|
|
+ public int updateReleaseStatus(Demand d) {
|
|
|
+ d.setAuditStatus(DemandAuditStatus.CREATE.getCode());
|
|
|
+ d.setReleaseStatus(DemandReleaseStatus.UNRELEASE.getCode());
|
|
|
+ d.setStatus(DemandStatus.UNRESOLVED.getCode());
|
|
|
+ demandMapper.updateReleaseDate(d.getId());
|
|
|
+ return demandMapper.updateByPrimaryKeySelective(d);
|
|
|
+ }
|
|
|
+
|
|
|
+ @Override
|
|
|
+ public int updateAuditDemand(Demand d, String techBroderId, Integer auditStatus) {
|
|
|
+ d.setAuditStatus(auditStatus);
|
|
|
+ if (DemandAuditStatus.AUDITED.getCode().equals(auditStatus)) {
|
|
|
+ Calendar now = Calendar.getInstance();
|
|
|
+ now.set(Calendar.MILLISECOND, 0);
|
|
|
+ d.setReleaseDate(now.getTime());
|
|
|
+ d.setReleaseStatus(DemandReleaseStatus.RELEASED.getCode());
|
|
|
+ d.setTechBrokerId(techBroderId);
|
|
|
+ } else {
|
|
|
+ d.setReleaseStatus(DemandReleaseStatus.UNRELEASE.getCode());
|
|
|
+ }
|
|
|
+ createTechBorkerNotice(d);
|
|
|
+ return demandMapper.updateByPrimaryKeySelective(d);
|
|
|
+ }
|
|
|
+
|
|
|
+ @Override
|
|
|
+ public void saveDemand(Demand d, String validityPeriodFormattedDate) {
|
|
|
+ Date validityPeriod = null;
|
|
|
+ if (!StringUtils.isBlank(validityPeriodFormattedDate)) {
|
|
|
+ try {
|
|
|
+ validityPeriod = DateUtils.parseDate(validityPeriodFormattedDate, AFTConstants.YYYYMMDD);
|
|
|
+ } catch (ParseException e) {
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ d.setValidityPeriod(validityPeriod);
|
|
|
+ d.setId(UUID.randomUUID().toString());
|
|
|
+
|
|
|
+ d.setDeletedSign(DeleteStatus.UNDELETE.getCode());
|
|
|
+
|
|
|
+ Calendar now = Calendar.getInstance();
|
|
|
+ now.set(Calendar.MILLISECOND, 0);
|
|
|
+ d.setStatus(DemandStatus.UNRESOLVED.getCode());
|
|
|
+ d.setAuditStatus(DemandAuditStatus.CREATE.getCode());
|
|
|
+ d.setReleaseStatus(DemandReleaseStatus.UNRELEASE.getCode());
|
|
|
+
|
|
|
+ if (DemandAuditStatus.SUBMIT.getCode().equals(d.getAuditStatus())) {
|
|
|
+ d.setAuditStatus(DemandAuditStatus.INAUDIT.getCode());
|
|
|
+ d.setReleaseStatus(DemandReleaseStatus.RELEASED.getCode());
|
|
|
+ createAuditorNotice(d);
|
|
|
+ }
|
|
|
+
|
|
|
+ d.setCreateTime(now.getTime());
|
|
|
+ demandMapper.insert(d);
|
|
|
+
|
|
|
+ }
|
|
|
+
|
|
|
+ private Map<String, Object> disposeParams(Integer auditStatus, String province, Integer serialNumber, String name,
|
|
|
+ String keyword, Integer infoSources, Integer demandType, String validityPeriodStartDate,
|
|
|
+ String validityPeriodEndDate, String username, Integer status, Integer releaseStatus,
|
|
|
+ String releaseDateStartDate, String releaseDateEndDate) {
|
|
|
Map<String, Object> params = new HashMap<>();
|
|
|
Date vStart = null;
|
|
|
Date vEnd = null;
|
|
|
Date rStart = null;
|
|
|
Date rEnd = null;
|
|
|
|
|
|
- params.put("employerId", TokenManager.getUserId());
|
|
|
-
|
|
|
if (!StringUtils.isBlank(validityPeriodStartDate)) {
|
|
|
try {
|
|
|
vStart = DateUtils.parseDate(validityPeriodStartDate, AFTConstants.YYYYMMDD);
|
|
|
@@ -413,11 +319,15 @@ public class DemandServiceImpl extends BaseMybatisDao<DemandMapper> implements D
|
|
|
if (null != rEnd) {
|
|
|
params.put("rEnd", rEnd);
|
|
|
}
|
|
|
-
|
|
|
- if (null != auditStatus){
|
|
|
+
|
|
|
+ if (null != auditStatus) {
|
|
|
params.put("auditStatus", auditStatus);
|
|
|
}
|
|
|
|
|
|
+ if (!StringUtils.isBlank(province)) {
|
|
|
+ params.put("province", province);
|
|
|
+ }
|
|
|
+
|
|
|
if (null != serialNumber) {
|
|
|
params.put("serialNumber", serialNumber);
|
|
|
}
|
|
|
@@ -430,6 +340,14 @@ public class DemandServiceImpl extends BaseMybatisDao<DemandMapper> implements D
|
|
|
params.put("keyword", keyword);
|
|
|
}
|
|
|
|
|
|
+ if (!StringUtils.isBlank(username)) {
|
|
|
+ params.put("username", username);
|
|
|
+ }
|
|
|
+
|
|
|
+ if (null != infoSources) {
|
|
|
+ params.put("infoSources", infoSources);
|
|
|
+ }
|
|
|
+
|
|
|
if (null != demandType) {
|
|
|
params.put("demandType", demandType);
|
|
|
}
|
|
|
@@ -442,99 +360,62 @@ public class DemandServiceImpl extends BaseMybatisDao<DemandMapper> implements D
|
|
|
params.put("releaseStatus", releaseStatus);
|
|
|
}
|
|
|
|
|
|
- if (pNo == null || pNo < 0) {
|
|
|
- pNo = 1;
|
|
|
- }
|
|
|
-
|
|
|
- if (pSize == null || pSize < 0) {
|
|
|
- pSize = 10;
|
|
|
- }
|
|
|
- return (Pagination<DemandListBo>) findPage("findDemandListByPage", "findDemandCount", params, pNo, pSize);
|
|
|
+ return params;
|
|
|
}
|
|
|
|
|
|
- @Override
|
|
|
- public int updateReleaseStatus(Demand d) {
|
|
|
- d.setAuditStatus(DemandAuditStatus.CREATE.getCode());
|
|
|
- d.setReleaseStatus(DemandReleaseStatus.UNRELEASE.getCode());
|
|
|
- d.setStatus(DemandStatus.UNRESOLVED.getCode());
|
|
|
- demandMapper.updateReleaseDate(d.getId());
|
|
|
- return demandMapper.updateByPrimaryKeySelective(d);
|
|
|
- }
|
|
|
-
|
|
|
- @Override
|
|
|
- public int updateAuditDemand(Demand d, String techBroderId, Integer auditStatus) {
|
|
|
- d.setAuditStatus(auditStatus);
|
|
|
- if (DemandAuditStatus.AUDITED.getCode().equals(auditStatus)) {
|
|
|
- Calendar now = Calendar.getInstance();
|
|
|
- now.set(Calendar.MILLISECOND, 0);
|
|
|
- d.setReleaseDate(now.getTime());
|
|
|
- d.setReleaseStatus(DemandReleaseStatus.RELEASED.getCode());
|
|
|
- d.setTechBrokerId(techBroderId);
|
|
|
- } else {
|
|
|
- d.setReleaseStatus(DemandReleaseStatus.UNRELEASE.getCode());
|
|
|
- }
|
|
|
- return demandMapper.updateByPrimaryKeySelective(d);
|
|
|
- }
|
|
|
-
|
|
|
- @Override
|
|
|
- public void saveDemand(Demand d, String validityPeriodFormattedDate) {
|
|
|
- Date validityPeriod = null;
|
|
|
- if (!StringUtils.isBlank(validityPeriodFormattedDate)) {
|
|
|
- try {
|
|
|
- validityPeriod = DateUtils.parseDate(validityPeriodFormattedDate, AFTConstants.YYYYMMDD);
|
|
|
- } catch (ParseException e) {
|
|
|
+ // 给所有审核员发送审核通知
|
|
|
+ private void createAuditorNotice(Demand d) {
|
|
|
+ List<String> ids = userRoleMapper.listAuditor();
|
|
|
+ List<Notice> list = new ArrayList<>();
|
|
|
+ if (null != ids && ids.size() > 0) {
|
|
|
+ for (String s : ids) {
|
|
|
+ list.add(disposeNotice(d, s));
|
|
|
}
|
|
|
+ noticeMapper.insertBatch(list);
|
|
|
}
|
|
|
+ }
|
|
|
|
|
|
- d.setValidityPeriod(validityPeriod);
|
|
|
- d.setId(UUID.randomUUID().toString());
|
|
|
+ // 给指派技术经纪人发送审核结果通知
|
|
|
+ private void createTechBorkerNotice(Demand a) {
|
|
|
+ noticeMapper.insert(disposeNotice(a, null));
|
|
|
|
|
|
- d.setDeletedSign(DeleteStatus.UNDELETE.getCode());
|
|
|
+ }
|
|
|
|
|
|
+ private Notice disposeNotice(Demand d, String aid) {
|
|
|
+ Notice n = new Notice();
|
|
|
Calendar now = Calendar.getInstance();
|
|
|
now.set(Calendar.MILLISECOND, 0);
|
|
|
- d.setStatus(DemandStatus.UNRESOLVED.getCode());
|
|
|
- d.setAuditStatus(DemandAuditStatus.CREATE.getCode());
|
|
|
- d.setReleaseStatus(DemandReleaseStatus.UNRELEASE.getCode());
|
|
|
-
|
|
|
- if (DemandAuditStatus.SUBMIT.getCode().equals(d.getAuditStatus())) {
|
|
|
- d.setAuditStatus(DemandAuditStatus.INAUDIT.getCode());
|
|
|
- d.setReleaseStatus(DemandReleaseStatus.RELEASED.getCode());
|
|
|
- createAuditorNotice(d);
|
|
|
- }
|
|
|
-
|
|
|
- d.setCreateTime(now.getTime());
|
|
|
- demandMapper.insert(d);
|
|
|
-
|
|
|
- }
|
|
|
-
|
|
|
- // 给所有审核员发送审核通知
|
|
|
- private void createAuditorNotice(Demand d) {
|
|
|
- List<String> ids = userRoleMapper.listAuditor();
|
|
|
- if (null != ids && ids.size() > 0) {
|
|
|
- for (String s : ids) {
|
|
|
- Notice n = new Notice();
|
|
|
- Calendar now = Calendar.getInstance();
|
|
|
- now.set(Calendar.MILLISECOND, 0);
|
|
|
- n.setId(UUID.randomUUID().toString());
|
|
|
- n.setCreateTime(now.getTime());
|
|
|
- n.setReaded(NoticeReadStatus.UNREAD.getCode());
|
|
|
- User u = userMapper.selectByPrimaryKey(d.getEmployerId());
|
|
|
- n.setRid(d.getId());
|
|
|
- n.setUid(d.getEmployerId());
|
|
|
- n.setAid(s);
|
|
|
- if (null != u) {
|
|
|
- n.setPid(u.getAid());
|
|
|
- }
|
|
|
- if (UserType.PERSONAL.getCode().equals(d.getDataCategory())) {
|
|
|
- n.setContent(NoticeStatus.PERSONALDEMAND.getDesc() + " " + DemandAuditStatus.SUBMIT.getDesc());
|
|
|
- n.setNoticeType(NoticeStatus.PERSONALDEMAND.getCode());
|
|
|
- } else if (UserType.ORGANIZATION.getCode().equals(d.getDataCategory())) {
|
|
|
- n.setContent(NoticeStatus.ORGANIZATIONDEMAND.getDesc() + " " + DemandAuditStatus.SUBMIT.getDesc());
|
|
|
- n.setNoticeType(NoticeStatus.ORGANIZATIONDEMAND.getCode());
|
|
|
- }
|
|
|
- noticeMapper.insert(n);
|
|
|
+ n.setId(UUID.randomUUID().toString());
|
|
|
+ n.setCreateTime(now.getTime());
|
|
|
+ n.setReaded(NoticeReadStatus.UNREAD.getCode());
|
|
|
+ n.setRid(d.getId());
|
|
|
+ User u = userMapper.selectByPrimaryKey(d.getEmployerId());
|
|
|
+ if (null != u) {
|
|
|
+ n.setPid(u.getAid());
|
|
|
+ }
|
|
|
+ if (StringUtils.isBlank(aid)) {
|
|
|
+ n.setAid(d.getTechBrokerId());
|
|
|
+ if (UserType.PERSONAL.getCode().equals(d.getDataCategory())) {
|
|
|
+ n.setContent("编号" + d.getSerialNumber() + NoticeStatus.PERSONALDEMAND.getDesc() + " "
|
|
|
+ + (DemandAuditStatus.AUDITED.getCode().equals(d.getAuditStatus())
|
|
|
+ ? DemandAuditStatus.AUDITED.getDesc() : DemandAuditStatus.UNAUDITED.getDesc()));
|
|
|
+ n.setNoticeType(NoticeStatus.PERSONALDEMAND.getCode());
|
|
|
+ } else if (UserType.ORGANIZATION.getCode().equals(d.getDataCategory())) {
|
|
|
+ n.setContent("编号" + d.getSerialNumber() + NoticeStatus.ORGANIZATIONDEMAND.getDesc() + " "
|
|
|
+ + (DemandAuditStatus.AUDITED.getCode().equals(d.getAuditStatus())
|
|
|
+ ? DemandAuditStatus.AUDITED.getDesc() : DemandAuditStatus.UNAUDITED.getDesc()));
|
|
|
+ n.setNoticeType(NoticeStatus.ORGANIZATIONDEMAND.getCode());
|
|
|
+ }
|
|
|
+ } else {
|
|
|
+ n.setAid(aid);
|
|
|
+ if (UserType.PERSONAL.getCode().equals(d.getDataCategory())) {
|
|
|
+ n.setContent(NoticeStatus.PERSONALDEMAND.getDesc() + " " + DemandAuditStatus.SUBMIT.getDesc());
|
|
|
+ n.setNoticeType(NoticeStatus.PERSONALDEMAND.getCode());
|
|
|
+ } else if (UserType.ORGANIZATION.getCode().equals(d.getDataCategory())) {
|
|
|
+ n.setContent(NoticeStatus.ORGANIZATIONDEMAND.getDesc() + " " + DemandAuditStatus.SUBMIT.getDesc());
|
|
|
+ n.setNoticeType(NoticeStatus.ORGANIZATIONDEMAND.getCode());
|
|
|
}
|
|
|
}
|
|
|
+ return n;
|
|
|
}
|
|
|
}
|