fix: 样式修改,以及第三方资源名称不对应的情况; #198

Merged
yangws merged 1 commits from yangws into main 2024-09-12 09:31:59 +08:00
3 changed files with 5 additions and 4 deletions

View File

@ -41,7 +41,9 @@ const getSubject = (value) => {
gradeName:gradeList[currentIndex].label
}
})
const nameIndex = subjectList.value.findIndex(item => item.subjectName === useStore.user.edusubject)
//
const nameIndex = subjectList.value.findIndex(item => item.subjectName === useStore.user.edusubject || item.subjectName.includes(useStore.user.edusubject))
if(nameIndex === -1) return;
getTagId({subjectId:subjectList.value[nameIndex].subjectId,subjectName:subjectList.value[nameIndex].subjectName})
if(textbookVersionId.value === 0){
getTagId(subjectList.value[0])

View File

@ -34,7 +34,6 @@ const emits = defineEmits(['handleSelect'])
//
const handleSelect = (itemDom,pathKey) => {
console.log(itemDom,pathKey)
const parts = pathKey[1].split("-")
const result = parts.slice(0, 2).join("-")
const index = props.menuItems.findIndex(item=>item.index===result)

View File

@ -2,8 +2,8 @@
<div class="common-layout">
<el-container>
<el-aside style="width: 200px;margin-top: 20px">
<el-card style="width: 200px" class="el-card-demo" :style="{'min-height': (viewportHeight - 164) + 'px'}">
<div :style="{'max-height': (viewportHeight - 164) + 'px','overflow-y': 'auto'}">
<el-card style="width: 200px" class="el-card-demo" :style="{'min-height': (viewportHeight - 164) + 'px','max-height': (viewportHeight - 164) + 'px'}">
<div >
<Aside :menuItems="menuItems" :classList="classList" @handleSelect="handleSelect"></Aside>
</div>
<!-- 隐藏操作按钮-->