my_schedule_page:
  action: 'display'
  conditions:
    - { function: accessIsAdminAccount, expectedResult: false }

attendance_bookings_page:
  action: 'display'
  conditions:
    - { function: organizationHasAnyModule, parameters: ['Attendances'] }
    # TODO: l'action write existe-t-elle?
    - {
        function: accessHasAnyRoleAbility,
        parameters: [{ action: 'write', subject: 'attendances' }],
      }
    - { function: accessIsAdminAccount, expectedResult: false }

my_attendance_page:
  action: 'display'
  conditions:
    - { function: accessIsAdminAccount, expectedResult: false }

my_invitation_page:
  action: 'display'
  conditions:
    - { function: accessIsAdminAccount, expectedResult: false }

my_students_page:
  action: 'display'
  conditions:
    - { function: accessHasAnyProfile, parameters: ['teacher'] }

my_students_education_students_page:
  action: 'display'
  conditions:
    - { function: accessHasAnyProfile, parameters: ['teacher'] }

criteria_notations_page_from_account_menu:
  action: 'display'
  conditions:
    - {
        function: organizationHasAnyModule,
        parameters: ['PedagogicsAdministation'],
      }
    - {
        function: accessHasAnyRoleAbility,
        parameters: [{ action: 'read', subject: 'criterianotation' }],
      }

my_education_students_page:
  action: 'display'
  conditions:
    - { function: accessHasAnyProfile, parameters: ['student'] }

send_an_email_page:
  action: 'display'
  conditions:
    - { function: accessHasAnyProfile, parameters: ['admin', 'teacher'] }

my_documents_page:
  action: 'display'
  conditions:
    - { function: accessIsAdminAccount, expectedResult: false }

my_profile_page:
  action: 'display'
  conditions:
    - { function: accessIsAdminAccount, expectedResult: false }

adherent_list_page:
  action: 'display'
  conditions:
    - { function: organizationHasAnyModule, parameters: ['Users'] }
    - { function: organizationIsShowAdherentList }
    - { function: accessHasAnyProfile, parameters: ['member'] }

subscription_page:
  action: 'display'
  conditions:
    - { function: organizationHasAnyModule, parameters: ['GeneralConfig'] }
    - {
        function: accessHasAnyProfile,
        parameters:
          [
            'admin',
            'administratifManager',
            'pedagogicManager',
            'financialManager',
            'caMember',
          ],
      }

my_bills_page:
  action: 'display'
  conditions:
    - { function: accessHasAnyProfile, parameters: ['guardian', 'payor'] }

cmf_licence_person_page:
  action: 'display'
  conditions:
    - { function: organizationIsCmf }
    - { function: accessIsAdminAccount, expectedResult: false }
