feat(freight-rpa): 增加出站报表配置与回调支持,重构相关服务
- 将 RPA 管理 API 扩展至出站报表配置,新增出站相关的回调接口。 - 重构 freight_rpa_report_config_service,支持入站与出站报表配置的管理。 - 更新 ORM 模型,增加出站报表相关的持久化模型。 - 统一命名规范,确保在手、入站与出站的概念一致性。
This commit is contained in:
1 parent
39fe3c05f2
commit
911afa0f73
152 files changed
+9861
-2984
No files matched your search
+10
-8
@@ -79,17 +79,19 @@ def create_app(config_name='default'):
|
||||
|
||||
_transfer_capabilities.register_transfer_capabilities()
|
||||
|
||||
# onhand/inbound RPA 回调 sink 注册(幂等):/api/freight-rpa/onhand-*、/api/freight-rpa/
|
||||
# inbound-* 端点经 callback_sinks.dispatch_sink 分发到业务处理器;文件/报表事实类
|
||||
# 回调(inbound-batch-ready / onhand 归档终态 commit 后)经 reports.dispatch.
|
||||
# dispatch_report_fact 分发到 register_report_handler 注册的处理函数
|
||||
# (Task 7:inbound→in_transit_transfer.handle_inbound_report、
|
||||
# onhand→shipping_notice.handle_onhand_report,均由 rpa_sinks 两个注册函数内注册);
|
||||
# 未注册的 kind 仍显式 404(FREIGHT_RPA.SINK_NOT_REGISTERED),不静默吞回调。
|
||||
from app.services.shipping_notice.rpa_sinks import register_inbound_sinks, register_onhand_sinks
|
||||
# onhand/inbound/outbound RPA 回调 sink 注册(幂等):按消费域分组合根——
|
||||
# onhand → shipping_notice.rpa_sinks;inbound/outbound → in_transit_transfer.rpa_sinks。
|
||||
# 进度类经 callback_sinks.dispatch_sink;文件事实经 reports.dispatch;
|
||||
# 未注册 kind 显式 404(FREIGHT_RPA.SINK_NOT_REGISTERED)。
|
||||
from app.services.in_transit_transfer.rpa_sinks import (
|
||||
register_inbound_sinks,
|
||||
register_outbound_sinks,
|
||||
)
|
||||
from app.services.shipping_notice.rpa_sinks import register_onhand_sinks
|
||||
|
||||
register_onhand_sinks()
|
||||
register_inbound_sinks()
|
||||
register_outbound_sinks()
|
||||
|
||||
# 启动时强制加载一次,避免 worker 冷启动到首个请求之间仍用镜像默认值。
|
||||
with app.app_context():
|
||||
|
||||
Reference in new issue
Block a user