goods同步

This commit is contained in:
2026-05-30 08:26:47 +08:00
parent 246c5a7080
commit dbf408c51f
20 changed files with 1233 additions and 32 deletions

View File

@@ -24,7 +24,9 @@ public class LbOrderRowController {
@PostMapping("/add")
@Operation(summary = "新增")
public ResponseEntity<Map<String, Object>> add(
@Parameter(description = "实体(id 为订单 id需调用方指定", required = true) @RequestBody LbOrderRow entity) {
@Parameter(description = "实体(复合主键 tenantId + id需调用方指定", required = true)
@RequestBody
LbOrderRow entity) {
Map<String, Object> result = lbOrderRowService.add(entity);
Boolean success = (Boolean) result.get("success");
if (success != null && success) {
@@ -36,7 +38,7 @@ public class LbOrderRowController {
@PutMapping("/update")
@Operation(summary = "编辑")
public ResponseEntity<Map<String, Object>> update(
@Parameter(description = "实体", required = true) @RequestBody LbOrderRow entity) {
@Parameter(description = "实体(须含 tenantId 与 id", required = true) @RequestBody LbOrderRow entity) {
Map<String, Object> result = lbOrderRowService.update(entity);
Boolean success = (Boolean) result.get("success");
if (success != null && success) {
@@ -48,8 +50,11 @@ public class LbOrderRowController {
@DeleteMapping("/delete/{id}")
@Operation(summary = "删除")
public ResponseEntity<Map<String, Object>> delete(
@Parameter(description = "主键(订单 id", required = true) @PathVariable Long id) {
Map<String, Object> result = lbOrderRowService.deleteById(id);
@Parameter(description = "订单 id(复合主键之一", required = true) @PathVariable Long id,
@Parameter(description = "租户 id复合主键之一未传时使用 X-Tenant-Id / Token 租户)")
@RequestParam(required = false)
String tenantId) {
Map<String, Object> result = lbOrderRowService.deleteById(id, tenantId);
Boolean success = (Boolean) result.get("success");
if (success != null && success) {
return ResponseEntity.ok(result);
@@ -92,7 +97,7 @@ public class LbOrderRowController {
@PostMapping("/sync-order-from-third")
@Operation(
summary = "从 外部系统 同步订单",
description = "按购买时间区间、租户 id、转卖状态调用后台 order/select将结果写入 lb_order_row按订单 id upsert")
description = "按购买时间区间、租户 id、转卖状态调用后台 order/select将结果写入 lb_order_row tenant_id + 订单 id upsert")
public ResponseEntity<Map<String, Object>> syncFromHxr(
@Parameter(description = "同步条件", required = true) @RequestBody LbOrderRowSyncFromHxrRequest request) {
Map<String, Object> result =