优化(直播履约): 即时选号并收敛订单快照同步

This commit is contained in:
yml
2026-11-18 16:58:08 +08:00
parent b7b09c90bd
commit dc95d83b32
13 changed files with 933 additions and 70 deletions
+4 -1
View File
@@ -80,6 +80,10 @@ def sync_tasks(
current: User = Depends(require_permission("platform_fulfillment:use")),
) -> dict[str, Any]:
result = service.sync_pending_tasks(db, limit=limit)
if result.get("taskIds"):
from ..services.platform_fulfillment.auto_allocator import wake_auto_allocator
wake_auto_allocator(result["taskIds"])
record_audit(
db,
current,
@@ -98,7 +102,6 @@ def get_task(
current: User = Depends(require_permission("platform_fulfillment:view")),
) -> dict[str, Any]:
del current
service.refresh_binding(db, task_id=task_id)
return service.get_task_detail(db, task_id)