|
@@ -1,16 +1,21 @@
|
|
|
package com.fdkankan.fusion.controller;
|
|
|
|
|
|
|
|
|
+import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
|
|
import com.fdkankan.fusion.common.ResultCode;
|
|
|
import com.fdkankan.fusion.common.ResultData;
|
|
|
import com.fdkankan.fusion.common.util.Openai;
|
|
|
import com.fdkankan.fusion.common.util.UploadToOssUtil;
|
|
|
import com.fdkankan.fusion.config.FusionConfig;
|
|
|
+import com.fdkankan.fusion.entity.CaseFiles;
|
|
|
+import com.fdkankan.fusion.entity.CaseFilesType;
|
|
|
import com.fdkankan.fusion.entity.CaseInquestInfo;
|
|
|
import com.fdkankan.fusion.entity.CaseNumEntity;
|
|
|
import com.fdkankan.fusion.exception.BusinessException;
|
|
|
import com.fdkankan.fusion.request.AiParam;
|
|
|
import com.fdkankan.fusion.response.FloorPathVo;
|
|
|
+import com.fdkankan.fusion.service.ICaseFilesService;
|
|
|
+import com.fdkankan.fusion.service.ICaseFilesTypeService;
|
|
|
import com.fdkankan.fusion.service.ICaseInquestInfoService;
|
|
|
import com.fdkankan.fusion.service.ICaseNumService;
|
|
|
import lombok.extern.slf4j.Slf4j;
|
|
@@ -59,8 +64,8 @@ public class AiController {
|
|
|
@GetMapping("/getFloor/{caseId}")
|
|
|
public ResultData getFloor(@PathVariable Integer caseId){
|
|
|
String foorPath = "/oss/4dkankan/scene_view_data/%s/user";
|
|
|
- String fileName = "floor-cad";
|
|
|
- String extName = "png";
|
|
|
+ String fileName = "cad";
|
|
|
+ String extName = "jpg";
|
|
|
List<CaseNumEntity> byCaseId = caseNumService.getByCaseId(caseId);
|
|
|
List<FloorPathVo> pathVos = new ArrayList<>();
|
|
|
for (CaseNumEntity caseNumEntity : byCaseId) {
|
|
@@ -85,5 +90,28 @@ public class AiController {
|
|
|
|
|
|
return ResultData.ok(pathVos);
|
|
|
}
|
|
|
+
|
|
|
+// @Autowired
|
|
|
+// ICaseFilesService caseFilesService;
|
|
|
+// @Autowired
|
|
|
+// ICaseFilesTypeService caseFilesTypeService;
|
|
|
+//
|
|
|
+// @GetMapping("/getFloor/{caseId}")
|
|
|
+// public ResultData getFloor(@PathVariable Integer caseId){
|
|
|
+// List<FloorPathVo> pathVos = new ArrayList<>();
|
|
|
+// CaseFilesType caseFilesType = caseFilesTypeService.getByName("平面图");
|
|
|
+// if(caseFilesType == null){
|
|
|
+// return ResultData.ok(pathVos);
|
|
|
+// }
|
|
|
+// List<CaseFiles> list = caseFilesService.getByCaseIdAndTypeId(caseId,caseFilesType.getFilesTypeId());
|
|
|
+// for (CaseFiles caseFiles : list) {
|
|
|
+// FloorPathVo pathVo = new FloorPathVo();
|
|
|
+// pathVo.setNum(caseFiles.getFilesTitle());
|
|
|
+// pathVo.getUrls().add(caseFiles.getFilesUrl());
|
|
|
+// pathVos.add(pathVo);
|
|
|
+// }
|
|
|
+//
|
|
|
+// return ResultData.ok(pathVos);
|
|
|
+// }
|
|
|
}
|
|
|
|