|
|
@@ -3,9 +3,7 @@ package com.zd.laboratory.controller;
|
|
|
import com.zd.common.core.annotation.Log;
|
|
|
import com.zd.common.core.annotation.PreAuthorize;
|
|
|
import com.zd.common.core.log.BusinessType;
|
|
|
-import com.zd.common.core.utils.DictUtils;
|
|
|
-import com.zd.common.core.utils.ExcelUtil;
|
|
|
-import com.zd.common.core.utils.SecurityUtils;
|
|
|
+import com.zd.common.core.utils.*;
|
|
|
import com.zd.common.core.web.controller.BaseController;
|
|
|
import com.zd.laboratory.domain.LabPhotoInspection;
|
|
|
import com.zd.laboratory.domain.LabSubject;
|
|
|
@@ -46,6 +44,9 @@ public class LabPhotoInspectionController extends BaseController {
|
|
|
@Autowired
|
|
|
private ILabSubjectService subjectService;
|
|
|
|
|
|
+ @Autowired
|
|
|
+ private FileConfigUtils fileConfigUtils;
|
|
|
+
|
|
|
/**
|
|
|
* 查询拍照检查附件列表
|
|
|
*/
|
|
|
@@ -110,7 +111,26 @@ public class LabPhotoInspectionController extends BaseController {
|
|
|
return ResultData.success(labPhotoInspectionService.selectLabPhotoInspectionById(id));
|
|
|
}
|
|
|
|
|
|
+ @GetMapping(value = "/detial/{id}")
|
|
|
+ public TableDataInfo getDetail(@PathVariable("id") Long id) {
|
|
|
+ LabPhotoInspection photoInspection = labPhotoInspectionService.selectLabPhotoInspectionById(id);
|
|
|
+ List<Map<String,String>> allList = new ArrayList <>();
|
|
|
+ imgList(allList,photoInspection.getSubUrl(),"实验室照片");
|
|
|
+ imgList(allList,photoInspection.getGarbageUrl(),"垃圾桶清理后照片");
|
|
|
+ imgList(allList,photoInspection.getDangerousUrl(),"使用危险设备照片");
|
|
|
+ imgList(allList,photoInspection.getSourceRiskUrl(),"危险源设备使用登记本照片");
|
|
|
+ return getDataTable(allList);
|
|
|
+ }
|
|
|
+
|
|
|
|
|
|
+ public void imgList(List<Map<String,String>> allList,String imgUrl,String imgName){
|
|
|
+ if(StringUtils.isNotNull(imgUrl) && !"".equals(imgUrl)){
|
|
|
+ Map<String,String> imgMap = new HashMap <>();
|
|
|
+ imgMap.put("imgName", imgName);
|
|
|
+ imgMap.put("imgUrl", fileConfigUtils.getFileDomainAdmin()+imgUrl);
|
|
|
+ allList.add(imgMap);
|
|
|
+ }
|
|
|
+ }
|
|
|
|
|
|
/**
|
|
|
* 获取离开实验室拍照附件列表
|