提交 f9edfc34 编写于 作者: X xjh22222228

fix: own visible

上级 33b519b0
......@@ -6,6 +6,7 @@ import { CdkDragDrop, moveItemInArray } from '@angular/cdk/drag-drop'
import { websiteList } from '../../store'
import { INavFourProp } from 'src/types'
import { setWebsiteList } from '../../utils'
import { isLogin } from '../../utils/user'
@Component({
selector: 'app-web-list',
......@@ -37,7 +38,7 @@ export class WebListComponent implements OnInit {
const item = nav[i]
if (item.url) {
if (item.top) {
if (item.top && (isLogin || !item.ownVisible)) {
dataList.push(item)
}
} else {
......
......@@ -87,10 +87,11 @@ export function totalWeb(): number {
if (!Array.isArray(nav)) return
for (let i = 0; i < nav.length; i++) {
if (nav[i].url) {
const item = nav[i]
if (item.url && (isLogin || !item.ownVisible)) {
total += 1
} else {
r(nav[i].nav)
r(item.nav)
}
}
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册