瀏覽代碼

修复app bug,附件上传路径问题

Memory_LG 10 月之前
父節點
當前提交
320145c76f

+ 10 - 0
src/main/java/com/sooka/sponest/mobile/data/housingconstruction/HousingconstructionSafetyinspectionrecordsController.java

@@ -81,6 +81,16 @@ public class HousingconstructionSafetyinspectionrecordsController {
 
     @PostMapping("/safetyinspectionrecords/put")
     public AjaxResult putSafetyinspectionrecords(@RequestBody HousingconstructionSafetyinspectionrecords record) {
+        List<HousingconstructionSafetyinspectionrecordsdetail> detailList = record.getDetailList();
+        detailList.forEach(detail->{
+            List<HousingconstructionAttach> attachList = detail.getAttachList();
+            for (int i = 0; i < attachList.size(); i++) {
+                HousingconstructionAttach attach = attachList.get(i);
+                attach.setBusId(detail.getId());
+                attach.setAttachPath(attach.getRealUrl());
+                attach.setAttachSorts(Long.parseLong(String.valueOf(i)));
+            }
+        });
         return safetyinspectionrecordsService.putSafetyinspectionrecords(record);
     }
 

+ 29 - 0
src/main/java/com/sooka/sponest/mobile/data/housingconstruction/HousingconstructionSteelcylinderController.java

@@ -0,0 +1,29 @@
+package com.sooka.sponest.mobile.data.housingconstruction;
+
+import com.ruoyi.common.core.web.domain.AjaxResult;
+import com.sooka.sponest.data.api.housingconstruction.domain.HousingconstructionRealnameuser;
+import com.sooka.sponest.data.api.housingconstruction.service.RemoteHousingconstructionRealnameuserService;
+import com.sooka.sponest.data.api.housingconstruction.service.RemoteHousingconstructionSteelcylinderService;
+import org.springframework.web.bind.annotation.GetMapping;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+
+import javax.annotation.Resource;
+
+/**
+ * 钢瓶基础数据Controller
+ *
+ * @author 韩福成
+ * @date 2024-07-30
+ */
+@RestController
+@RequestMapping("/AppHousingconstructionSteelcylinderController")
+public class HousingconstructionSteelcylinderController{
+    @Resource
+    RemoteHousingconstructionSteelcylinderService steelcylinderService;
+
+    @GetMapping("/steelcylinder/getSteelcylinderList")
+    public AjaxResult getRealNameUserListAllByType(HousingconstructionRealnameuser realnameuser){
+        return steelcylinderService.getSteelcylinderList();
+    }
+}