package com.vincent.rsf.server.api.feign; import com.vincent.rsf.server.api.controller.erp.params.DapIlcwmsCompletionRequest; import com.vincent.rsf.server.api.feign.fallback.CloudWmsErpFeignClientFallbackFactory; import org.springframework.cloud.openfeign.FeignClient; import org.springframework.http.MediaType; import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.RequestBody; import java.util.Map; /** * 立库侧通过 OpenFeign 调用云仓:9.1 鼎捷 ilcwmsplus 入/出库完成反馈(两 URL);9.2 仍为 /api/report/inventoryAdjust,请求体与 9.1 相同 {data:[]}(由 Service 从 InventoryAdjustReportParam 组装)。 * 使用 platform.erp.base-url 作为根地址;失败时走 Fallback,统一返回错误响应(不抛异常)。 */ @FeignClient( name = "cloudWmsErp", url = "${platform.erp.base-url:http://127.0.0.1:8080}", fallbackFactory = CloudWmsErpFeignClientFallbackFactory.class ) public interface CloudWmsErpFeignClient { /**9.1.1 立库入库任务完成反馈 */ @PostMapping(value = "/dapilc/restful/service/ilcwmsplus/IKWebService/cusInventoryCompletionReport", consumes = MediaType.APPLICATION_JSON_VALUE) Map cusInventoryCompletionReport(@RequestBody DapIlcwmsCompletionRequest body); /**9.1.2 立库出库任务完成反馈 */ @PostMapping(value = "/dapilc/restful/service/ilcwmsplus/IKWebService/cusOutboundCompletionReport", consumes = MediaType.APPLICATION_JSON_VALUE) Map cusOutboundCompletionReport(@RequestBody DapIlcwmsCompletionRequest body); /** 9.2 库存调整主动上报(路径不变;body 与入出库一致的 data 数组结构) */ @PostMapping(value = "/api/report/inventoryAdjust", consumes = MediaType.APPLICATION_JSON_VALUE) Map reportInventoryAdjust(@RequestBody DapIlcwmsCompletionRequest body); /** 物料基础信息同步 */ @PostMapping(value = "/api/mat/sync", consumes = MediaType.APPLICATION_JSON_VALUE) Map syncMatnrs(@RequestBody Object body); }