1、解决选中自定义页面的按钮导致全部选中的问题
This commit is contained in:
parent
b2a10eb187
commit
04decd7050
@ -24,7 +24,7 @@
|
||||
:content="appLink.path" placement="bottom" :show-after="300">
|
||||
|
||||
<el-button class="m-b-8px m-r-8px m-l-0px!"
|
||||
:type="isSameLink(appLink.path, activeAppLink.path) ? 'primary' : 'default'"
|
||||
:type="appLink.path == activeAppLink.path ? 'primary' : 'default'"
|
||||
@click="handleAppLinkSelected(appLink)">
|
||||
{{ appLink.name }}
|
||||
</el-button>
|
||||
@ -109,9 +109,14 @@
|
||||
|
||||
// 处理 APP 链接选中
|
||||
const handleAppLinkSelected = (appLink : AppLink) => {
|
||||
if (!isSameLink(appLink.path, activeAppLink.value.path)) {
|
||||
activeAppLink.value = appLink
|
||||
console.log(activeAppLink.value,activeAppLink.value.path,"activeAppLink.value")
|
||||
if(!appLink.path.includes('/pages/index/page')){
|
||||
if (!isSameLink(appLink.path, activeAppLink.value.path)) {
|
||||
activeAppLink.value = appLink
|
||||
// console.log(activeAppLink.value,activeAppLink.value.path,"activeAppLink.value")
|
||||
}
|
||||
}else{
|
||||
activeAppLink.value.path = appLink.path
|
||||
console.log(activeAppLink.value.path,"activeAppLink.value.path")
|
||||
}
|
||||
switch (appLink.type) {
|
||||
case APP_LINK_TYPE_ENUM.PRODUCT_CATEGORY_LIST:
|
||||
|
Loading…
Reference in New Issue
Block a user