Browse Source

重构问题核实代码

tags/v1.0.0^2
wanjing 1 year ago
parent
commit
5347c25d71
2 changed files with 18 additions and 8 deletions
  1. +2
    -7
      tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/service/inspectionfile/query/QueryInspectionFilePageListByInspectionIdService.java
  2. +16
    -1
      tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/vo/inspection/InspectionFilePageListByInspectionIdVo.java

+ 2
- 7
tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/service/inspectionfile/query/QueryInspectionFilePageListByInspectionIdService.java View File

@@ -113,15 +113,10 @@ public class QueryInspectionFilePageListByInspectionIdService {
Map<String, QuestionType> questionTypeMap = questionTypeList.stream().collect(Collectors.toMap(QuestionType::getId, Function.identity()));

List<InspectionFilePageListByInspectionIdVo> inspectionFilePageListVoList = InspectionFileConverMapper.INSTANCE.fromInspectionFileListToInspectionFilePageByInspectionIdListVoList(inspectionFileList);
QuestionType questionType;
Integer questionName;
for (InspectionFilePageListByInspectionIdVo inspectionFilePageListVo : inspectionFilePageListVoList) {
questionType = questionTypeMap.get(inspectionFilePageListVo.getQuestionId());
if (null != questionType) {
questionName = questionType.getName();
inspectionFilePageListVo.setQuestionName(Integer.toString(questionName));
}

inspectionFilePageListVo.setFileThumbnail(CommonConfig.imageURL + inspectionFilePageListVo.getFileThumbnail());
inspectionFilePageListVo.setFileOriginal(CommonConfig.imageURL + inspectionFilePageListVo.getFileOriginal());
}
return inspectionFilePageListVoList;
}

+ 16
- 1
tuoheng-service/tuoheng-admin/src/main/java/com/tuoheng/admin/vo/inspection/InspectionFilePageListByInspectionIdVo.java View File

@@ -20,18 +20,33 @@ public class InspectionFilePageListByInspectionIdVo {
/**
* 问题类型:1坑槽,2积水,3裂缝
*/
private String questionId;
private String questionCode;

/**
* 类型名称:1坑槽,2积水,3裂缝
*/
private String questionName;

/**
* 问题内容
*/
private String questionContent;

/**
* 文件名称
*/
private String fileName;

/**
* 缩略图
*/
private String fileThumbnail;

/**
* 原图
*/
private String fileOriginal;

/**
* 经度
*/

Loading…
Cancel
Save