Explorar el Código

应急手机端代码提交

Memory_LG hace 5 meses
padre
commit
0ccb241851

+ 7 - 4
src/main/java/com/sooka/sponest/mobile/data/emergency/controller/AppEnterpriseController.java

@@ -6,10 +6,7 @@ import com.ruoyi.common.core.web.page.TableSupport;
 import com.sooka.sponest.mobile.data.emergency.domain.AppEnterpriseVO;
 import com.sooka.sponest.mobile.data.emergency.feign.service.RemoteEnterpriseService;
 import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.web.bind.annotation.GetMapping;
-import org.springframework.web.bind.annotation.RequestBody;
-import org.springframework.web.bind.annotation.RequestMapping;
-import org.springframework.web.bind.annotation.RestController;
+import org.springframework.web.bind.annotation.*;
 
 import java.util.ArrayList;
 import java.util.HashMap;
@@ -26,6 +23,7 @@ public class AppEnterpriseController {
 
     /**
      * 获取企业列表
+     *
      * @param vo
      * @return
      */
@@ -42,4 +40,9 @@ public class AppEnterpriseController {
     public AjaxResult getEnterpriseDetails(@RequestBody AppEnterpriseVO vo) {
         return enterpriseService.getEnterpriseDetails(vo.getBusEnterpriseId());
     }
+
+    @PostMapping("/addEnterprise")
+    public AjaxResult addEnterprise(@RequestBody AppEnterpriseVO vo) {
+        return enterpriseService.addEnterprise(vo);
+    }
 }

+ 6 - 0
src/main/java/com/sooka/sponest/mobile/data/emergency/controller/AppXunjianController.java

@@ -60,4 +60,10 @@ public class AppXunjianController {
     public AjaxResult getItems(AppXunjianVO vo) {
         return xunjianService.getItems(vo);
     }
+
+
+    @PostMapping("/submitXunjian")
+    public AjaxResult submitXunjian(@RequestBody AppXunjianVO vo) {
+        return xunjianService.submitXunjian(vo);
+    }
 }

+ 1 - 14
src/main/java/com/sooka/sponest/mobile/data/emergency/feign/factory/RemoteEnterpriseServiceFallbackFactory.java

@@ -19,19 +19,6 @@ public class RemoteEnterpriseServiceFallbackFactory implements FallbackFactory<R
     @Override
     public RemoteEnterpriseService create(Throwable cause) {
 
-        log.error("应急-企业报错:{}", cause.getMessage());
-        return  new RemoteEnterpriseService() {
-            @Override
-            public TableDataInfo getEnterpriseList(Integer pageNum, Integer pageSize, String searchValue) {
-                log.error("getEnterpriseList 方法调用失败:{}", cause.getMessage());
-                return null;
-            }
-
-            @Override
-            public AjaxResult getEnterpriseDetails(String busEnterpriseId) {
-                return null;
-            }
-
-        };
+        return null;
     }
 }

+ 3 - 0
src/main/java/com/sooka/sponest/mobile/data/emergency/feign/service/RemoteEnterpriseService.java

@@ -24,4 +24,7 @@ public interface RemoteEnterpriseService {
 
     @GetMapping("/AppEnterpriseController/getEnterpriseDetails")
     AjaxResult getEnterpriseDetails(@RequestParam("busEnterpriseId") String busEnterpriseId);
+
+    @PostMapping("/AppEnterpriseController/addEnterprise")
+    AjaxResult addEnterprise(@RequestBody AppEnterpriseVO vo);
 }

+ 3 - 0
src/main/java/com/sooka/sponest/mobile/data/emergency/feign/service/RemoteXunjianService.java

@@ -42,4 +42,7 @@ public interface RemoteXunjianService {
 
     @PostMapping("/AppXunjianController/getItems")
     AjaxResult getItems(@RequestBody AppXunjianVO vo);
+
+    @PostMapping("/AppXunjianController/submitXunjian")
+    AjaxResult submitXunjian(@RequestBody AppXunjianVO vo);
 }