Update:Only show podcast search page for admin or up #225

This commit is contained in:
advplyr 2022-12-08 17:56:58 -06:00
parent 379fa21571
commit b521f37ec1
2 changed files with 11 additions and 4 deletions

View file

@ -25,6 +25,9 @@ export default {
userHasPlaylists() {
return this.$store.state.libraries.numUserPlaylists
},
userIsAdminOrUp() {
return this.$store.getters['user/getIsAdminOrUp']
},
items() {
let items = []
if (this.isPodcast) {
@ -52,16 +55,19 @@ export default {
icon: this.currentLibraryIcon,
iconClass: 'text-lg',
text: 'Library'
},
{
}
]
if (this.userIsAdminOrUp) {
items.push({
to: '/bookshelf/search',
routeName: 'bookshelf-search',
iconPack: 'abs-icons',
icon: 'podcast',
iconClass: 'text-lg',
text: 'Search'
}
]
})
}
} else {
items = [
{