提交 a3beb44e 编写于 作者: Mr.奇淼('s avatar Mr.奇淼(

fixed: #1102

上级 ba98288a
......@@ -122,7 +122,7 @@ export const useUserStore = defineStore('user', () => {
return userInfo.activeColor
})
watch(token, () => {
watch(() => token.value, () => {
window.localStorage.setItem('token', token.value)
})
......
......@@ -140,7 +140,7 @@ const sliceFile = () => {
})
}
watch(waitNum, () => { percentage.value = Math.floor(((formDataList.value.length - waitNum.value) / formDataList.value.length) * 100) })
watch(() => waitNum.value, () => { percentage.value = Math.floor(((formDataList.value.length - waitNum.value) / formDataList.value.length) * 100) })
const upLoadFileSlice = async(item) => {
// 切片上传
......
......@@ -217,7 +217,7 @@ const removeTab = (tab) => {
const index = historys.value.findIndex(
(item) => getFmtString(item) === tab
)
if (getFmtString(route) === tab) {
if (getFmtString(route) === tab) {
if (historys.value.length === 1) {
router.push({ name: defaultRouter.value })
} else {
......@@ -239,7 +239,7 @@ const removeTab = (tab) => {
historys.value.splice(index, 1)
}
watch(contextMenuVisible, () => {
watch(() => contextMenuVisible.value, () => {
if (contextMenuVisible.value) {
document.body.addEventListener('click', () => {
contextMenuVisible.value = false
......@@ -251,7 +251,7 @@ watch(contextMenuVisible, () => {
}
})
watch(route, (to, now) => {
watch(() => route, (to, now) => {
if (to.name === 'Login' || to.name === 'Reload') {
return
}
......@@ -259,7 +259,7 @@ watch(route, (to, now) => {
setTab(to)
sessionStorage.setItem('historys', JSON.stringify(historys.value))
activeValue.value = window.sessionStorage.getItem('activeValue')
})
}, { deep: true })
watch(() => historys.value, () => {
sessionStorage.setItem('historys', JSON.stringify(historys.value))
......
......@@ -83,7 +83,7 @@ getTheme()
const active = ref('')
watch(() => route, () => {
active.value = route.name
})
}, { deep: true })
watch(() => userStore.sideMode, () => {
getTheme()
......
......@@ -193,7 +193,7 @@ const getTableData = async() => {
}
}
watch(tableData, () => {
watch(() => tableData.value, () => {
setAuthorityIds()
})
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册