Преглед на файлове

评审增加项目编号

master
WendyYang преди 1 година
родител
ревизия
d804645b45
променени са 11 файла, в които са добавени 41 реда и са изтрити 8 реда
  1. +4
    -4
      pmapi/src/main/java/com/ningdatech/pmapi/expert/controller/ExpertReviewController.java
  2. +4
    -3
      pmapi/src/main/java/com/ningdatech/pmapi/expert/manage/ExpertReviewManage.java
  3. +2
    -0
      pmapi/src/main/java/com/ningdatech/pmapi/expert/model/entity/ExpertReview.java
  4. +4
    -0
      pmapi/src/main/java/com/ningdatech/pmapi/expert/model/req/ExpertReviewDetailReq.java
  5. +3
    -0
      pmapi/src/main/java/com/ningdatech/pmapi/meeting/entity/domain/MeetingInnerProject.java
  6. +3
    -0
      pmapi/src/main/java/com/ningdatech/pmapi/meeting/entity/dto/ReviewProjectDTO.java
  7. +3
    -0
      pmapi/src/main/java/com/ningdatech/pmapi/meeting/entity/vo/MeetingReviewProjectVO.java
  8. +1
    -0
      pmapi/src/main/java/com/ningdatech/pmapi/meeting/manage/MeetingManage.java
  9. +1
    -1
      pmapi/src/main/java/com/ningdatech/pmapi/meeting/mapper/MeetingExpertMapper.xml
  10. +9
    -0
      pmapi/src/main/java/com/ningdatech/pmapi/meeting/service/IMeetingInnerProjectService.java
  11. +7
    -0
      pmapi/src/main/java/com/ningdatech/pmapi/meeting/service/impl/MeetingInnerProjectServiceImpl.java

+ 4
- 4
pmapi/src/main/java/com/ningdatech/pmapi/expert/controller/ExpertReviewController.java Целия файл

@@ -73,13 +73,13 @@ public class ExpertReviewController {
return expertReviewManage.listReviews(projectId, meetingId, false);
}

@GetMapping("/detail/{projectId}")
@GetMapping("/detail/{projectCode}")
@ApiImplicitParams({
@ApiImplicitParam(name = "projectId", value = "项目ID"),
@ApiImplicitParam(name = "projectCode", value = "项目编号"),
})
@ApiOperation("查看项目的所有评审意见")
public ProjectReviewDetailVO projectExpertReviewDetail(@PathVariable Long projectId) {
return expertReviewManage.projectExpertReviewDetail(projectId);
public ProjectReviewDetailVO projectExpertReviewDetail(@PathVariable String projectCode) {
return expertReviewManage.projectExpertReviewDetail(projectCode);
}

}

+ 4
- 3
pmapi/src/main/java/com/ningdatech/pmapi/expert/manage/ExpertReviewManage.java Целия файл

@@ -107,6 +107,7 @@ public class ExpertReviewManage {
review.setReviewResult(req.getReviewResult());
review.setContent(JSONUtil.toJsonStr(req.getReviewTemplateOptions()));
review.setProjectId(req.getProjectId());
review.setProjectCode(req.getProjectCode());
review.setTemplateId(req.getTemplateId());
review.setMeetingId(req.getMeetingId());
review.setOtherAdvice(req.getOtherAdvice());
@@ -151,9 +152,9 @@ public class ExpertReviewManage {
});
}

public ProjectReviewDetailVO projectExpertReviewDetail(Long projectId) {
public ProjectReviewDetailVO projectExpertReviewDetail(String projectCode) {
ProjectReviewDetailVO detail = new ProjectReviewDetailVO();
List<Long> meetingIds = meetingInnerProjectService.listMeetingIdByProjectId(projectId);
List<Long> meetingIds = meetingInnerProjectService.listMeetingIdByProjectCode(projectCode);
if (meetingIds.isEmpty()) {
return detail;
}
@@ -166,7 +167,7 @@ public class ExpertReviewManage {
}))).values();
LambdaQueryWrapper<ExpertReview> erQuery = Wrappers.lambdaQuery(ExpertReview.class)
.in(ExpertReview::getMeetingId, tmpMeetingIds)
.eq(ExpertReview::getProjectId, projectId)
.eq(ExpertReview::getProjectCode, projectCode)
.orderByDesc(ExpertReview::getCreateOn);
List<ExpertReview> expertReviews = expertReviewService.list(erQuery);
if (expertReviews.isEmpty()) {


+ 2
- 0
pmapi/src/main/java/com/ningdatech/pmapi/expert/model/entity/ExpertReview.java Целия файл

@@ -30,6 +30,8 @@ public class ExpertReview implements Serializable {
@ApiModelProperty("项目ID")
private Long projectId;

private String projectCode;

@ApiModelProperty("会议ID")
private Long meetingId;



+ 4
- 0
pmapi/src/main/java/com/ningdatech/pmapi/expert/model/req/ExpertReviewDetailReq.java Целия файл

@@ -28,6 +28,10 @@ public class ExpertReviewDetailReq {
@NotNull(message = "项目ID不能为空")
private Long projectId;

@ApiModelProperty("项目编号")
@NotNull(message = "项目编号不能为空")
private String projectCode;

@ApiModelProperty("会议ID")
@NotNull(message = "会议ID不能为空")
private Long meetingId;


+ 3
- 0
pmapi/src/main/java/com/ningdatech/pmapi/meeting/entity/domain/MeetingInnerProject.java Целия файл

@@ -34,4 +34,7 @@ public class MeetingInnerProject implements Serializable {
@ApiModelProperty("项目ID")
private Long projectId;

@ApiModelProperty("项目编号")
private String projectCode;

}

+ 3
- 0
pmapi/src/main/java/com/ningdatech/pmapi/meeting/entity/dto/ReviewProjectDTO.java Целия файл

@@ -28,6 +28,9 @@ public class ReviewProjectDTO {
@ApiModelProperty("项目名称")
private String projectName;

@ApiModelProperty("项目编号")
private String projectCode;

@ApiModelProperty("项目类型")
private Integer projectType;



+ 3
- 0
pmapi/src/main/java/com/ningdatech/pmapi/meeting/entity/vo/MeetingReviewProjectVO.java Целия файл

@@ -28,6 +28,9 @@ public class MeetingReviewProjectVO {
@ApiModelProperty("项目ID")
private Long id;

@ApiModelProperty("项目编号")
private String projectCode;

@ApiModelProperty("项目名称")
private String projectName;



+ 1
- 0
pmapi/src/main/java/com/ningdatech/pmapi/meeting/manage/MeetingManage.java Целия файл

@@ -897,6 +897,7 @@ public class MeetingManage {
return MeetingReviewProjectVO
.builder()
.id(project.getId())
.projectCode(project.getProjectCode())
.projectName(project.getProjectName())
.declaredAmount(project.getDeclareAmount())
.projectType(project.getProjectType())


+ 1
- 1
pmapi/src/main/java/com/ningdatech/pmapi/meeting/mapper/MeetingExpertMapper.xml Целия файл

@@ -104,7 +104,7 @@
</sql>

<select id="pageReviewProjectList" resultType="com.ningdatech.pmapi.meeting.entity.dto.ReviewProjectDTO">
select mip.project_id, np.project_name, np.project_type, np.project_year, np.build_org_name, m.type review_type,
select mip.project_id,np.project_code, np.project_name, np.project_type, np.project_year, np.build_org_name, m.type review_type,
np.biz_domain, np.declare_amount declared_amount, mip.meeting_id, m.type meetingType, m.start_time reviewTime,m.end_time endReviewTime,
m.connecter, m.contact, me.is_headman, (select count(1) from nd_expert_review ner where ner.meeting_id = m.id and ner.project_id = np.id
and ner.create_by = me.expert_id) reviewed


+ 9
- 0
pmapi/src/main/java/com/ningdatech/pmapi/meeting/service/IMeetingInnerProjectService.java Целия файл

@@ -33,4 +33,13 @@ public interface IMeetingInnerProjectService extends IService<MeetingInnerProjec
**/
List<Long> listMeetingIdByProjectId(Long projectId);

/**
* 查询项目关联的所有会议
*
* @param projectCode 项目编号
* @return 项目关联的会议ID
* @author WendyYang
**/
List<Long> listMeetingIdByProjectCode(String projectCode);

}

+ 7
- 0
pmapi/src/main/java/com/ningdatech/pmapi/meeting/service/impl/MeetingInnerProjectServiceImpl.java Целия файл

@@ -36,4 +36,11 @@ public class MeetingInnerProjectServiceImpl extends ServiceImpl<MeetingInnerProj
return CollUtils.fieldList(list(query), MeetingInnerProject::getMeetingId);
}

@Override
public List<Long> listMeetingIdByProjectCode(String projectCode) {
LambdaQueryWrapper<MeetingInnerProject> query = Wrappers
.lambdaQuery(MeetingInnerProject.class)
.eq(MeetingInnerProject::getProjectCode, projectCode);
return CollUtils.fieldList(list(query), MeetingInnerProject::getMeetingId);
}
}

Loading…
Отказ
Запис