Merge pull request #3886 from jumpserver/pr@v4@ticket

perf: remove ticket feature
This commit is contained in:
feng626
2024-04-28 18:11:47 +08:00
committed by GitHub

View File

@@ -14,6 +14,7 @@ import Ticket from './Ticket.vue'
import Ops from './Ops.vue'
import Chat from './Chat.vue'
import VirtualApp from './VirtualApp.vue'
import { mapGetters } from 'vuex'
export default {
name: 'Feature',
@@ -29,7 +30,7 @@ export default {
{
title: this.$t('Ticket'),
name: 'Ticket',
hidden: !this.$store.getters.hasValidLicense
hidden: !this.ticketsEnabled
},
{
title: this.$t('AppOps'),
@@ -52,6 +53,16 @@ export default {
}
]
}
},
computed: {
...mapGetters([
'publicSettings'
]),
ticketsEnabled() {
return this.publicSettings['TICKETS_ENABLED'] &&
this.$hasLicense() &&
this.$hasPerm('tickets.view_ticket')
}
}
}
</script>