feat(web): AI 工作台文件预览/附件关联任务与草稿分支
- 新增 WorkbenchAiFilePreviewDialog 附件预览对话框及 useWorkbenchAiFilePreview,附件支持点击预览 - 新增 attachmentAssociationJobs/linkedReimbursementDraftJobs 前端服务与对应 composable,接入后台任务轮询与状态展示 - 新增 travelReimbursementDraftBranchModel 草稿分支模型,报销关联门控支持跳过/选择草稿 - PersonalWorkbenchAiMode 及各 composable(expense/document/steward/application-preview/attachment-association)重构适配,WorkbenchAiComposer/FileStrip 样式与交互完善 - DocumentsCenter/ReceiptFolder/TravelReimbursementCreate 等视图及 scripts 重构,风险/差旅规划/审批等工具适配 - 新增/更新前端测试:application-result-card、reimbursement-list-preview-fetch、guided-flow、composer-components 等
This commit is contained in:
@@ -57,6 +57,9 @@ function testReceiptFolderViewSurface() {
|
||||
assert.match(view, /buildReceiptFile\(item\)/)
|
||||
assert.match(view, /source: selectedDraft \? 'detail' : 'receipt-folder'/)
|
||||
assert.match(view, /emit\('open-assistant'/)
|
||||
assert.match(view, /REIMBURSEMENT_LIST_PREVIEW_PARAMS/)
|
||||
assert.match(view, /fetchExpenseClaims\(REIMBURSEMENT_LIST_PREVIEW_PARAMS\)/)
|
||||
assert.doesNotMatch(view, /const claims = await fetchExpenseClaims\(\)/)
|
||||
}
|
||||
|
||||
function testReceiptFolderServiceContract() {
|
||||
@@ -160,18 +163,19 @@ function testReceiptFolderDetailLayoutAdjustments() {
|
||||
|
||||
function testAssistantUnlinkedReceiptPrompt() {
|
||||
const submitComposer = readProjectFile('web/src/views/scripts/useTravelReimbursementSubmitComposer.js')
|
||||
const assistantView = readProjectFile('web/src/views/scripts/TravelReimbursementCreateView.js')
|
||||
const attachmentFlow = readProjectFile('web/src/views/scripts/travelReimbursementSubmitAttachmentFlow.js')
|
||||
const suggestedActions = readProjectFile('web/src/views/scripts/useTravelReimbursementSuggestedActions.js')
|
||||
|
||||
assert.match(submitComposer, /fetchReceiptFolderItems/)
|
||||
assert.match(submitComposer, /promptUnlinkedReceiptFolderIfNeeded/)
|
||||
assert.match(submitComposer, /fetchReceiptFolderItems\('unlinked'\)/)
|
||||
assert.match(submitComposer, /skipReceiptFolderUnlinkedPrompt/)
|
||||
assert.match(submitComposer, /open_receipt_folder/)
|
||||
assert.match(submitComposer, /continue_upload_with_unlinked_receipts/)
|
||||
assert.match(assistantView, /actionType === 'open_receipt_folder'/)
|
||||
assert.match(assistantView, /router\.push\(\{ name: 'app-receiptFolder' \}\)/)
|
||||
assert.match(assistantView, /actionType === 'continue_upload_with_unlinked_receipts'/)
|
||||
assert.match(assistantView, /skipReceiptFolderUnlinkedPrompt: true/)
|
||||
assert.match(attachmentFlow, /fetchReceiptFolderItems\('unlinked'\)/)
|
||||
assert.match(attachmentFlow, /skipReceiptFolderUnlinkedPrompt/)
|
||||
assert.match(attachmentFlow, /open_receipt_folder/)
|
||||
assert.match(attachmentFlow, /continue_upload_with_unlinked_receipts/)
|
||||
assert.match(suggestedActions, /actionType === 'open_receipt_folder'/)
|
||||
assert.match(suggestedActions, /router\.push\(\{ name: 'app-receiptFolder' \}\)/)
|
||||
assert.match(suggestedActions, /actionType === 'continue_upload_with_unlinked_receipts'/)
|
||||
assert.match(suggestedActions, /skipReceiptFolderUnlinkedPrompt: true/)
|
||||
}
|
||||
|
||||
function run() {
|
||||
|
||||
Reference in New Issue
Block a user