fix(leave): 修复请假流程 waiting 与业务 draft 不同步导致无审批按钮
申请人提交后业务表可能仍停在 draft,办理页不显示审批按钮;在请假模块内补齐任务创建时状态对齐,禁止 waiting 被回写为 draft,并仅在暂存时写 draft。 Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
1 parent
65abe022c7
commit
a6a5b88f47
3 files changed
+50
-17
No files matched your search
@@ -1046,8 +1046,10 @@ const submitForm = (status: string) => {
|
||||
// 将附件ID添加到表单数据中,处理成逗号分隔的字符串
|
||||
form.attachmentOssIds = attachmentOssIds.join(',');
|
||||
|
||||
// 设置审批状态为草稿
|
||||
form.approvalStatus = 'draft';
|
||||
// 仅暂存时写入草稿;提交时不强制 draft,避免覆盖流程已同步的 waiting
|
||||
if (status === 'draft') {
|
||||
form.approvalStatus = 'draft';
|
||||
}
|
||||
|
||||
// 保存业务数据
|
||||
try {
|
||||
|
||||
Reference in new issue
Block a user