feat(shipping-notice): 完成货代发货通知全门禁恢复MVP收口
完成全门禁恢复MVP版本交付:调整自动上传与重试配置,重构正式执行链路;修复多处代码bug,新增测试与审计工具;更新全流程文档与契约规范。
This commit is contained in:
1 parent
8e0bbf7a81
commit
c94d173f92
181 files changed
+12947
-1724
No files matched your search
@@ -317,8 +317,12 @@ def resolve_task_export_download(task: ShippingNotice | None) -> tuple[Path, str
|
||||
if not task or not task.export_file_path:
|
||||
return None
|
||||
from app.models import ShippingExportArtifact
|
||||
artifact = ShippingExportArtifact.query.filter_by(
|
||||
task_id=task.id, status='ready', file_path=task.export_file_path,
|
||||
# 已人工/RPA 上传完成的 Artifact 仍是用户可下载的最终 Excel;
|
||||
# 不能因履约完成将 status=uploaded 排除在下载解析之外。
|
||||
artifact = ShippingExportArtifact.query.filter(
|
||||
ShippingExportArtifact.task_id == task.id,
|
||||
ShippingExportArtifact.status.in_({'ready', 'uploaded'}),
|
||||
ShippingExportArtifact.file_path == task.export_file_path,
|
||||
).order_by(
|
||||
ShippingExportArtifact.created_at.desc(), ShippingExportArtifact.id.desc(),
|
||||
).first()
|
||||
|
||||
Reference in new issue
Block a user