Quellcode durchsuchen

外部报验单同步到报送

wangming vor 15 Stunden
Ursprung
Commit
81225ceaac

+ 2 - 1
business-common/src/main/java/com/rongwei/bscommon/sys/feign/BsPlatformService.java

@@ -6,6 +6,7 @@ import org.springframework.cloud.openfeign.FeignClient;
 import org.springframework.web.bind.annotation.PathVariable;
 import org.springframework.web.bind.annotation.PostMapping;
 import org.springframework.web.bind.annotation.RequestBody;
+import org.springframework.web.bind.annotation.RequestParam;
 
 import java.util.List;
 
@@ -21,7 +22,7 @@ public interface BsPlatformService {
     @PostMapping("rw-business-server/sync/exterior-inspection")
     R syncOutsideInpection(
             @RequestBody List<OutsideInspactionSyncDto> list
-            , @PathVariable("companyName") String companyName  //路径参数
+            , @RequestParam("companyName") String companyName  //路径参数
     );
 
 }

+ 1 - 1
business-common/src/main/java/com/rongwei/bscommon/sys/service/ZhcxOutsideInspectionItpService.java

@@ -67,7 +67,7 @@ public interface ZhcxOutsideInspectionItpService extends IService<ZhcxOutsideIns
      *
      * @param req
      */
-    void sync2SubmissionPlatform(OutsideInspactionSyncReqquest req,String companyName);
+    void sync2SubmissionPlatform(OutsideInspactionSyncReqquest req);
 
     /**
      * 获取初始化报验点状态报验单

+ 2 - 3
business-common/src/main/java/com/rongwei/bscommon/sys/service/impl/ZhcxOutsideInspectionItpServiceImpl.java

@@ -1308,8 +1308,7 @@ public class ZhcxOutsideInspectionItpServiceImpl extends ServiceImpl<ZhcxOutside
      * @param req
      */
     @Override
-    public void sync2SubmissionPlatform(OutsideInspactionSyncReqquest req,String companyName) {
-        System.out.println(companyName+"公司名称===========");
+    public void sync2SubmissionPlatform(OutsideInspactionSyncReqquest req) {
         List<OutsideInspactionSyncDto> syncDtoList = dao.getInspection(req);
 
         if(ObjectUtil.isEmpty(syncDtoList)) {
@@ -1346,7 +1345,7 @@ public class ZhcxOutsideInspectionItpServiceImpl extends ServiceImpl<ZhcxOutside
             record.setDeleted("0");
             recordList.add(record);
         }
-        R result = bsPlatformService.syncOutsideInpection(syncDtoList,companyName);
+        R result = bsPlatformService.syncOutsideInpection(syncDtoList, req.getCompanyName());
 
         if(ObjectUtil.isNull(result) || !"200".equals(result.getCode())) {
             log.error("请求结果:{}", result);

+ 2 - 0
business-entity/src/main/java/com/rongwei/bsentity/dto/OutsideInspactionSyncReqquest.java

@@ -38,4 +38,6 @@ public class OutsideInspactionSyncReqquest {
      */
     @ApiModelProperty("外部报验单id")
     private List<String> outesideIdList;
+
+    private String companyName;
 }

+ 2 - 2
business-server/src/main/java/com/rongwei/bsserver/controller/ZhcxOutsideInspectionItpController.java

@@ -114,8 +114,8 @@ public class ZhcxOutsideInspectionItpController {
      */
     @ApiOperation("推送到报送平台")
     @PostMapping("/syncBsPlatform")
-    public R syncBsPlatform(@RequestBody OutsideInspactionSyncReqquest req,@RequestParam String companyName){
-        service.sync2SubmissionPlatform(req,companyName);
+    public R syncBsPlatform(@RequestBody OutsideInspactionSyncReqquest req){
+        service.sync2SubmissionPlatform(req);
         return R.ok();
     }