fix(sign): 补齐模板查询院区参数
This commit is contained in:
@@ -234,8 +234,14 @@ function syncFilterFromRoute() {
|
||||
}
|
||||
|
||||
async function loadTemplates() {
|
||||
const campusId = appStore.selectedCampusId
|
||||
if (!campusId) {
|
||||
templates.value = []
|
||||
return
|
||||
}
|
||||
|
||||
try {
|
||||
templates.value = await getSigningTemplates()
|
||||
templates.value = await getSigningTemplates({ campusId })
|
||||
} catch {
|
||||
ElMessage.error('文档模板加载失败,请稍后重试')
|
||||
}
|
||||
@@ -1088,9 +1094,12 @@ watch(
|
||||
|
||||
/** 切换全局院区:列表跟着换(院区不再是筛选条里的一个下拉,见 syncFilterFromRoute) */
|
||||
watch(
|
||||
() => appStore.selectedCampus,
|
||||
() => {
|
||||
() => appStore.selectedCampusId,
|
||||
(campusId, previousCampusId) => {
|
||||
page.value = 1
|
||||
if (campusId && previousCampusId) {
|
||||
void loadTemplates()
|
||||
}
|
||||
void loadTasks()
|
||||
},
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user