Skip to content
Snippets Groups Projects
Commit 3d4e9394 authored by Ilja's avatar Ilja Committed by Haelwenn
Browse files

Don't call reports count when not privileged

The sidebar shows the report count. Even when not privileged, the call was done to get the count.
parent 0f2388df
No related branches found
No related tags found
3 merge requests!326Mergeback: 2.5.0,!315Handle moderation privileges,!282Release/2.5.0
......@@ -27,6 +27,7 @@ export default {
...mapGetters([
'permission_routers',
'roles',
'privileges',
'sidebar',
'tabs'
]),
......@@ -38,7 +39,9 @@ export default {
}
},
mounted() {
this.$store.dispatch('FetchOpenReportsCount')
if (this.privileges?.indexOf('reports_manage_reports') !== -1) {
this.$store.dispatch('FetchOpenReportsCount')
}
},
methods: {
getMergedRoutes() {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment