员工岗位可重新启用;调价认空运航线;会话存档跳号补拉;陆运报价按车型列回填
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -603,10 +603,27 @@ def _staff_rows(book: Any, seg: Segment) -> list[dict[str, Any]]:
|
||||
return []
|
||||
return [dict(x) for x in (lister(role_code="land") or []) if isinstance(x, dict)]
|
||||
if seg.mode == "AIR":
|
||||
from agent.policy.deal_followup import air_staff_route_matches
|
||||
|
||||
lister = getattr(book, "list_staff_by_role", None)
|
||||
if not callable(lister):
|
||||
return []
|
||||
return [dict(x) for x in (lister(role_code="air") or []) if isinstance(x, dict)]
|
||||
rows = [dict(x) for x in (lister(role_code="air") or []) if isinstance(x, dict)]
|
||||
hits = [
|
||||
r
|
||||
for r in rows
|
||||
if air_staff_route_matches(routes=str(r.get("routes") or ""), facts=seg.facts)
|
||||
]
|
||||
if not hits:
|
||||
hits = [
|
||||
r
|
||||
for r in rows
|
||||
if any(
|
||||
t.strip() in {"空运全线", "全线"}
|
||||
for t in str(r.get("routes") or "").replace(",", ",").split(",")
|
||||
)
|
||||
]
|
||||
return hits
|
||||
except Exception:
|
||||
logger.exception("多段激活匹配产品失败 mode=%s", seg.mode)
|
||||
return []
|
||||
|
||||
Reference in New Issue
Block a user