Commit c0f611b1 authored by 高滢's avatar 高滢
parents 90ce24af 4077aff2
......@@ -62,8 +62,8 @@ public class DataStatisticsUtils {
isPass = false;
}
if(passed == ReviewStandard.PASSED) {
isPass = false;
if(passed == ReviewStandard.NO_PASSED) {
isPass = true;
}
......
......@@ -54,6 +54,7 @@ public class StrategyCarReviewTaskSigned implements StrategyCarReviewTask, Initi
@Override
public CarReviewTaskViewResponse doView(CarReviewTask carReviewTask) {
CarReviewTaskViewResponse response = new CarReviewTaskViewResponse();
carReviewTask.setImagesUrl("/vehicle-quality-review-oss/2024/03/04/qianzi1_20240304104011A001.jpg,/vehicle-quality-review-oss/2024/03/04/qianzi2_20240304104121A002.jpg");
response.setCarReviewTask(carReviewTask);
return response;
}
......
......@@ -96,6 +96,7 @@ public class StrategySystemReviewTaskSigned implements StrategySystemReviewTask,
@Override
public SystemReviewTaskViewResponse doView(SystemReviewTask systemReviewTask) {
SystemReviewTaskViewResponse response = new SystemReviewTaskViewResponse();
systemReviewTask.setImagesUrl("/vehicle-quality-review-oss/2024/03/04/qianzi1_20240304104011A001.jpg,/vehicle-quality-review-oss/2024/03/04/qianzi2_20240304104121A002.jpg");
response.setSystemReviewTask(systemReviewTask);
return response;
......
......@@ -582,32 +582,42 @@ public class TaskServiceImpl extends ServiceImpl<TaskMapper, Task>implements Tas
public DataStatisticsResponse dataStatistics(TaskGetInfoRequest request) {
Task task = taskMapper.selectById(request.getId());
DataStatisticsResponse response = new DataStatisticsResponse();
SystemReviewTask systemReviewTask = systemReviewTaskMapper.selectById(task.getSystemReviewTaskId());
if (task.getSystemReviewTaskId() != null) {
CarReviewTask carReviewTask = carReviewTaskMapper.selectById(task.getCarReviewTaskId());
SystemReviewTask systemReviewTask = systemReviewTaskMapper.selectById(task.getSystemReviewTaskId());
// 获取最新问卷
List<ReviewStandard> standardTree = reviewStandardService.findTree(systemReviewTask.getStandardId(), ReviewStandard.TYPE_SYSTEM);
DataStatisticsResponse response = new DataStatisticsResponse();
// 获取当前问卷答案
List<ReviewDetailsResult> results = reviewDetailsResultService.findByTaskId(systemReviewTask.getId());
// 体系审查
setSystemDataStatistics(standardTree,results,response);
return response;
}
if (task.getCarReviewTaskId() != null) {
// 获取最新问卷
List<ReviewStandard> standardTree = reviewStandardService.findTree(systemReviewTask.getStandardId(), ReviewStandard.TYPE_SYSTEM);
CarReviewTask carReviewTask = carReviewTaskMapper.selectById(task.getCarReviewTaskId());
// 获取当前问卷答案
List<ReviewDetailsResult> results = reviewDetailsResultService.findByTaskId(systemReviewTask.getId());
// 获取最新问卷
List<ReviewStandard> carStandardTree = reviewStandardService.findTree(carReviewTask.getStandardId(), ReviewStandard.TYPE_CAR);
// 体系审查
setSystemDataStatistics(standardTree,results,response);
// 获取当前问卷答案
List<ReviewDetailsResult> carResults = reviewDetailsResultService.findByTaskId(carReviewTask.getId());
// 获取最新问卷
List<ReviewStandard> carStandardTree = reviewStandardService.findTree(carReviewTask.getStandardId(), ReviewStandard.TYPE_CAR);
// 车型审查
setCarDataStatistics(carStandardTree,carResults,response);
// 获取当前问卷答案
List<ReviewDetailsResult> carResults = reviewDetailsResultService.findByTaskId(carReviewTask.getId());
return response;
}
// 车型审查
setCarDataStatistics(carStandardTree,carResults,response);
return null;
return response;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment