fix(fulfillment): 历史任务冻结,快照不再触发自动状态迁移

This commit is contained in:
yml
2026-11-24 23:43:00 +08:00
parent aafac6e536
commit 1a02733cda
2 changed files with 21 additions and 0 deletions
@@ -21,6 +21,7 @@ from ..external_order_source import (
)
from .common import (
AUTO_SYNC_INTERVAL_SECONDS,
FLOW_VERSION_LEGACY,
SCOPE_ELITE,
TARGET_PLATFORM,
_flow_version_for_order,
@@ -158,6 +159,10 @@ def _upsert_order_snapshot(
.first()
)
created = task is None
if task is not None and task.flow_version == FLOW_VERSION_LEGACY:
# 历史任务冻结:只保留来源快照,不参与任何自动状态迁移。
task.source_snapshot_json = _jsonable(snapshot)
return task, created, False
if task is None:
task = PlatformFulfillmentTask(
source_system="order_site",