| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566 |
- import AbstractMenuBuilder from '~/services/layout/menuBuilder/abstractMenuBuilder'
- import type { MenuGroup, MenuItems } from '~/types/layout'
- /**
- * Menu Paramètres
- */
- export default class ParametersMenuBuilder extends AbstractMenuBuilder {
- static readonly menuName = 'Parameters'
- /**
- * Construit le menu Header Configuration, ou null si aucune page accessible
- */
- build(): MenuGroup | null {
- const children: MenuItems = []
- this.addChildItemIfAllowed(children, 'parameters_general_page', {
- name: 'fas fa-gears',
- })
- this.addChildItemIfAllowed(children, 'parameters_website_page', {
- name: 'fas fa-globe-americas',
- })
- this.addChildItemIfAllowed(children, 'parameters_teaching_page', {
- name: 'fas fa-school',
- })
- this.addChildItemIfAllowed(children, 'parameters_intranet_page', {
- name: 'fas fa-arrows-down-to-people',
- })
- this.addChildItemIfAllowed(children, 'parameters_education_notation_page', {
- name: 'fas fa-graduation-cap',
- })
- this.addChildItemIfAllowed(children, 'parameters_bulletin_page', {
- name: 'fas fa-file-lines',
- })
- this.addChildItemIfAllowed(children, 'parameters_education_timings_page', {
- name: 'fas fa-clock',
- })
- this.addChildItemIfAllowed(children, 'parameters_residence_areas_page', {
- name: 'fas fa-location-dot',
- })
- this.addChildItemIfAllowed(children, 'parameters_attendances_page', {
- name: 'fas fa-user-times',
- })
- this.addChildItemIfAllowed(children, 'parameters_sms_page', {
- name: 'fas fa-mobile',
- })
- this.addChildItemIfAllowed(children, 'parameters_super_admin_page', {
- name: 'fas fa-user-gear',
- })
- if (children.length > 0) {
- return this.createGroup('parameters', undefined, children)
- }
- return null
- }
- }
|