fix: 解决资源库报错的问题;

This commit is contained in:
yangws 2024-09-18 13:55:30 +08:00
parent 5cfd5747a1
commit 3b9877e788
1 changed files with 2 additions and 0 deletions

View File

@ -91,6 +91,8 @@ const subjectList = ref([])
// //
const getSubject = () => { const getSubject = () => {
//
if(!userInfo.user.subject) return
listEvaluation({ itemkey: 'subject', pageSize: 500 }).then((res) => { listEvaluation({ itemkey: 'subject', pageSize: 500 }).then((res) => {
const arr = userStore.user.subject.split(',') const arr = userStore.user.subject.split(',')
subjectList.value = res.rows.filter(item => arr.includes(String(item.id))).map(items => items) subjectList.value = res.rows.filter(item => arr.includes(String(item.id))).map(items => items)