feat(sign): 补齐医护端与患者端签署流程

This commit is contained in:
xy
2026-09-28 19:57:57 +08:00
parent a25716c861
commit 8024075439
22 changed files with 1082 additions and 163 deletions
@@ -183,8 +183,7 @@ const filteredTemplates = computed(() => {
return allTemplates.value.filter((template) => {
const matchesDepartment = !filters.department || template.departmentKey === filters.department
const matchesStatus =
filters.status === 'all' || readLibraryStatus(template) === filters.status
const matchesStatus = filters.status === 'all' || readLibraryStatus(template) === filters.status
// 搜索范围照原型:模板名 / 编号 / 科室 / 分类,外加检查类型与关联项目编码。
// 后两者是卡片上看得见的字段,搜不到会让人以为这份文书不存在。
const matchesKeyword =
@@ -710,6 +709,7 @@ function updateLocalContent(form: DocumentContentForm) {
}
located.document.contentHtml = form.contentHtml
located.document.needConfirm = form.needConfirm
located.document.updatedAt = new Date().toISOString()
}
@@ -739,7 +739,10 @@ async function handleContentSubmit(form: DocumentContentForm) {
// 新建的文书还没有任何版本:第一个版本用 createTemplateWithContent 的版本那一步等价路径,
// 这里统一走 createTemplateVersion(见 updateTemplateContent),
// 后端会把它当成该模板的第一个版本
await updateTemplateContent(form.id, { contentHtml: form.contentHtml })
await updateTemplateContent(form.id, {
contentHtml: form.contentHtml,
needConfirm: form.needConfirm,
})
closeContentDialog()
await loadLibrary()
ElMessage.success('正文已保存为新版本')