feat: 新增归档中心页面并完善知识库与报销查询能力
新增前端归档中心视图及相关工具函数,扩充知识库文档分类和 提取器支持多种格式,增强编排器报销查询的多维度检索,优 化本体规则和用户代理审核消息,前端完善报销创建和审批详 情交互细节,补充单元测试覆盖。
This commit is contained in:
@@ -183,9 +183,9 @@ class UserAgentReviewMessageMixin:
|
||||
if draft_payload is not None and draft_payload.claim_no:
|
||||
return (
|
||||
f"已按您当前确认的信息保存为草稿 {draft_payload.claim_no}。"
|
||||
"后续您可以继续补充缺失项,或修改识别结果后再继续提交。"
|
||||
"后续上传附件或补充票据信息时,请关联这张草稿;补齐缺失项后再继续提交。"
|
||||
)
|
||||
return "已按您当前确认的信息保存为草稿。后续您可以继续补充缺失项,或修改识别结果后再继续提交。"
|
||||
return "已按您当前确认的信息保存为草稿。后续上传附件或补充票据信息时,请关联这张草稿;补齐缺失项后再继续提交。"
|
||||
if review_action == "link_to_existing_draft":
|
||||
document_count = self._resolve_review_document_count(payload)
|
||||
followup_copy = self._build_review_action_followup_copy(review_payload)
|
||||
@@ -214,6 +214,12 @@ class UserAgentReviewMessageMixin:
|
||||
reason_lines = "\n".join(
|
||||
f"{index}. {reason}" for index, reason in enumerate(reasons, start=1)
|
||||
)
|
||||
if all(self._is_submission_exception_explanation_reason(reason) for reason in reasons):
|
||||
return (
|
||||
"检测到当前单据存在需要说明的超标风险,但票据和费用明细会继续保留在单据中。\n"
|
||||
f"{reason_lines}\n"
|
||||
"如果确有特殊情况,请先在附加说明中补充原因;补充后可以继续提交给审批人重点复核。"
|
||||
)
|
||||
return (
|
||||
"AI预审暂未通过,所以还没有提交到审批人。\n"
|
||||
f"{reason_lines}\n"
|
||||
@@ -253,6 +259,12 @@ class UserAgentReviewMessageMixin:
|
||||
blocked_reasons = self._resolve_submission_blocked_reasons(payload)
|
||||
if blocked_reasons:
|
||||
reason_text = ";".join(dict.fromkeys(reason.strip("。;;") for reason in blocked_reasons if reason))
|
||||
if all(self._is_submission_exception_explanation_reason(reason) for reason in blocked_reasons):
|
||||
return (
|
||||
f"检测到当前单据存在需要说明的超标风险:{reason_text}。"
|
||||
"票据会先正常归集到单据中,并在费用明细前标记风险;"
|
||||
"如确有特殊情况,请在附加说明中补充原因后继续提交审批。"
|
||||
)
|
||||
return (
|
||||
f"AI预审未通过:{reason_text}。"
|
||||
"请先根据风险提示补充原因、调整金额或更换附件,整改后再继续提交。"
|
||||
@@ -670,4 +682,3 @@ class UserAgentReviewMessageMixin:
|
||||
if not claim_groups:
|
||||
return False
|
||||
return True
|
||||
|
||||
|
||||
Reference in New Issue
Block a user