feat: 完善文档中心与报销申请交互及侧边栏重构
后端优化编排器报销查询和本体检测精度,增强报销单草稿保 存和附件回填逻辑,前端重构侧边栏组件支持折叠和图标导 航,完善文档中心状态筛选和详情提示,报销创建和审批详情 页优化会话管理和费用明细交互,新增助手应用服务和预设动 作工具函数,补充单元测试覆盖。
This commit is contained in:
@@ -34,6 +34,28 @@ test('composer formats date-picker expense text into readable structured fields'
|
||||
)
|
||||
})
|
||||
|
||||
test('composer extracts destination and reason from compact travel text', () => {
|
||||
const formatted = buildStructuredComposerSubmitText(
|
||||
'出差上海,支撑国网服务器上线部署',
|
||||
{
|
||||
mode: 'single',
|
||||
start_date: '2026-05-25',
|
||||
end_date: '2026-05-25',
|
||||
business_time: '2026-05-25'
|
||||
}
|
||||
)
|
||||
|
||||
assert.equal(
|
||||
formatted,
|
||||
[
|
||||
'发生时间:2026-05-25',
|
||||
'地点:上海',
|
||||
'事由:支撑国网服务器上线部署',
|
||||
'天数:1天'
|
||||
].join('\n')
|
||||
)
|
||||
})
|
||||
|
||||
test('composer keeps backend raw text but displays structured user message', () => {
|
||||
assert.match(submitComposerScript, /const rawText = resolveComposerSubmitText\(options\.rawText\)\.trim\(\)/)
|
||||
assert.match(submitComposerScript, /resolveComposerDisplaySubmitText\(rawText\)/)
|
||||
|
||||
Reference in New Issue
Block a user