
const { v4: uuid } = require("uuid");

module.exports = {
  /**
   * @param{import("sequelize").QueryInterface} queryInterface
   * @return {Promise<void>}
   */
  async up(queryInterface) {
    const createdAt = new Date();
    const updatedAt = new Date();

    /** @type {Map<string, string>} */
    const idMap = new Map();

    /**
     * @param {string} key
     * @return {string}
     */
    function getId(key) {
      if (idMap.has(key)) {
        return idMap.get(key);
      }
      const id = uuid();
      idMap.set(key, id);
      return id;
    }

    await queryInterface.bulkInsert("roles", [
      
      
      { id: getId("Administrator"), name: "Administrator", createdAt, updatedAt },
      
      
        
          { id: getId("SchoolDirector"), name: "School Director", createdAt, updatedAt },
        
          { id: getId("AcademicCoordinator"), name: "Academic Coordinator", createdAt, updatedAt },
        
          { id: getId("RegistrarOfficer"), name: "Registrar Officer", createdAt, updatedAt },
        
          { id: getId("Teacher"), name: "Teacher", createdAt, updatedAt },
        
          { id: getId("Student"), name: "Student", createdAt, updatedAt },
        
      
      
      { id: getId("Public"), name: "Public", createdAt, updatedAt },
    ]);

    /**
     * @param {string} name
     */
    function createPermissions(name) {
      return [
        { id: getId(`CREATE_${name.toUpperCase()}`), createdAt, updatedAt, name: `CREATE_${name.toUpperCase()}` },
        { id: getId(`READ_${name.toUpperCase()}`), createdAt, updatedAt, name: `READ_${name.toUpperCase()}` },
        { id: getId(`UPDATE_${name.toUpperCase()}`), createdAt, updatedAt, name: `UPDATE_${name.toUpperCase()}` },
        { id: getId(`DELETE_${name.toUpperCase()}`), createdAt, updatedAt, name: `DELETE_${name.toUpperCase()}` }
      ];
    }

    const entities = [
      "users","roles","permissions","school_settings","pages","school_years","grades","streams","subjects","subject_offerings","staff_members","students","class_sections","enrollments","terms","events","announcements","news_posts","galleries","study_materials","exams","exam_results","attendance_sessions","attendance_records","class_schedules","assignments","assignment_submissions","lesson_plans","messages","admission_applications","contact_messages","alumni","school_statistics","exam_performance_summaries","top_student_features",,
    ];
await queryInterface.bulkInsert("permissions", entities.flatMap(createPermissions));
await queryInterface.bulkInsert("permissions", [{ id: getId(`READ_API_DOCS`), createdAt, updatedAt, name: `READ_API_DOCS` }]);
await queryInterface.bulkInsert("permissions", [{ id: getId(`CREATE_SEARCH`), createdAt, updatedAt, name: `CREATE_SEARCH`}]);


await queryInterface.sequelize.query(`create table "rolesPermissionsPermissions"
(
"createdAt"           timestamp with time zone not null,
"updatedAt"           timestamp with time zone not null,
"roles_permissionsId" uuid                     not null,
"permissionId"        uuid                     not null,
primary key ("roles_permissionsId", "permissionId")
);`);


await queryInterface.bulkInsert("rolesPermissionsPermissions", [
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_USERS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_USERS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_USERS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_USERS') },
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_USERS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_USERS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_USERS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('UPDATE_USERS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_USERS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_USERS') },
                    
                  
                    
                  
                    
                  
                  
             
          
    
  
    
    
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_SCHOOL_SETTINGS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_SCHOOL_SETTINGS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_SCHOOL_SETTINGS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_SCHOOL_SETTINGS') },
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_SCHOOL_SETTINGS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_SCHOOL_SETTINGS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_SCHOOL_SETTINGS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_SCHOOL_SETTINGS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_SCHOOL_SETTINGS') },
                    
                  
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_PAGES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_PAGES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_PAGES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_PAGES') },
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('CREATE_PAGES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_PAGES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_PAGES') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_PAGES') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_PAGES') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_PAGES') },
                    
                  
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_SCHOOL_YEARS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_SCHOOL_YEARS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_SCHOOL_YEARS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_SCHOOL_YEARS') },
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('CREATE_SCHOOL_YEARS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_SCHOOL_YEARS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_SCHOOL_YEARS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_SCHOOL_YEARS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('UPDATE_SCHOOL_YEARS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_SCHOOL_YEARS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_SCHOOL_YEARS') },
                    
                  
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_GRADES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_GRADES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_GRADES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_GRADES') },
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_GRADES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_GRADES') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_GRADES') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_GRADES') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_GRADES') },
                    
                  
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_STREAMS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_STREAMS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_STREAMS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_STREAMS') },
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_STREAMS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_STREAMS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_STREAMS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_STREAMS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_STREAMS') },
                    
                  
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_SUBJECTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_SUBJECTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_SUBJECTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_SUBJECTS') },
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('CREATE_SUBJECTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_SUBJECTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_SUBJECTS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_SUBJECTS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_SUBJECTS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_SUBJECTS') },
                    
                  
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_SUBJECT_OFFERINGS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_SUBJECT_OFFERINGS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_SUBJECT_OFFERINGS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_SUBJECT_OFFERINGS') },
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('CREATE_SUBJECT_OFFERINGS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_SUBJECT_OFFERINGS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_SUBJECT_OFFERINGS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_SUBJECT_OFFERINGS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_SUBJECT_OFFERINGS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_SUBJECT_OFFERINGS') },
                    
                  
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_STAFF_MEMBERS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_STAFF_MEMBERS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_STAFF_MEMBERS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_STAFF_MEMBERS') },
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_STAFF_MEMBERS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_STAFF_MEMBERS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_STAFF_MEMBERS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_STAFF_MEMBERS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_STAFF_MEMBERS') },
                    
                  
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_STUDENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_STUDENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_STUDENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_STUDENTS') },
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_STUDENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_STUDENTS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('CREATE_STUDENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_STUDENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('UPDATE_STUDENTS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_STUDENTS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_STUDENTS') },
                    
                  
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_CLASS_SECTIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_CLASS_SECTIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_CLASS_SECTIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_CLASS_SECTIONS') },
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('CREATE_CLASS_SECTIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_CLASS_SECTIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_CLASS_SECTIONS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('CREATE_CLASS_SECTIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_CLASS_SECTIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('UPDATE_CLASS_SECTIONS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_CLASS_SECTIONS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_CLASS_SECTIONS') },
                    
                  
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_ENROLLMENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_ENROLLMENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_ENROLLMENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_ENROLLMENTS') },
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_ENROLLMENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_ENROLLMENTS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('CREATE_ENROLLMENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_ENROLLMENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('UPDATE_ENROLLMENTS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_ENROLLMENTS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_ENROLLMENTS') },
                    
                  
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_TERMS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_TERMS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_TERMS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_TERMS') },
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('CREATE_TERMS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_TERMS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_TERMS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_TERMS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('UPDATE_TERMS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_TERMS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_TERMS') },
                    
                  
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_EVENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_EVENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_EVENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_EVENTS') },
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('CREATE_EVENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_EVENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_EVENTS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_EVENTS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_EVENTS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_EVENTS') },
                    
                  
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_ANNOUNCEMENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_ANNOUNCEMENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_ANNOUNCEMENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_ANNOUNCEMENTS') },
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('CREATE_ANNOUNCEMENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_ANNOUNCEMENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_ANNOUNCEMENTS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_ANNOUNCEMENTS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_ANNOUNCEMENTS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_ANNOUNCEMENTS') },
                    
                  
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_NEWS_POSTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_NEWS_POSTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_NEWS_POSTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_NEWS_POSTS') },
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('CREATE_NEWS_POSTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_NEWS_POSTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_NEWS_POSTS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_NEWS_POSTS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_NEWS_POSTS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_NEWS_POSTS') },
                    
                  
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_GALLERIES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_GALLERIES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_GALLERIES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_GALLERIES') },
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('CREATE_GALLERIES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_GALLERIES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_GALLERIES') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_GALLERIES') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_GALLERIES') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_GALLERIES') },
                    
                  
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_STUDY_MATERIALS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_STUDY_MATERIALS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_STUDY_MATERIALS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_STUDY_MATERIALS') },
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('CREATE_STUDY_MATERIALS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_STUDY_MATERIALS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_STUDY_MATERIALS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_STUDY_MATERIALS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('CREATE_STUDY_MATERIALS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_STUDY_MATERIALS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('UPDATE_STUDY_MATERIALS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_STUDY_MATERIALS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('UPDATE_STUDY_MATERIALS') },
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_EXAMS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_EXAMS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_EXAMS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_EXAMS') },
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('CREATE_EXAMS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_EXAMS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_EXAMS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_EXAMS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('UPDATE_EXAMS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_EXAMS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_EXAMS') },
                    
                  
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_EXAM_RESULTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_EXAM_RESULTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_EXAM_RESULTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_EXAM_RESULTS') },
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('CREATE_EXAM_RESULTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_EXAM_RESULTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_EXAM_RESULTS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_EXAM_RESULTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('UPDATE_EXAM_RESULTS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('CREATE_EXAM_RESULTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_EXAM_RESULTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('UPDATE_EXAM_RESULTS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_EXAM_RESULTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('UPDATE_EXAM_RESULTS') },
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_ATTENDANCE_SESSIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_ATTENDANCE_SESSIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_ATTENDANCE_SESSIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_ATTENDANCE_SESSIONS') },
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('CREATE_ATTENDANCE_SESSIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_ATTENDANCE_SESSIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_ATTENDANCE_SESSIONS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_ATTENDANCE_SESSIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('UPDATE_ATTENDANCE_SESSIONS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('CREATE_ATTENDANCE_SESSIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_ATTENDANCE_SESSIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('UPDATE_ATTENDANCE_SESSIONS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_ATTENDANCE_SESSIONS') },
                    
                  
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_ATTENDANCE_RECORDS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_ATTENDANCE_RECORDS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_ATTENDANCE_RECORDS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_ATTENDANCE_RECORDS') },
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('CREATE_ATTENDANCE_RECORDS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_ATTENDANCE_RECORDS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_ATTENDANCE_RECORDS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_ATTENDANCE_RECORDS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('UPDATE_ATTENDANCE_RECORDS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('CREATE_ATTENDANCE_RECORDS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_ATTENDANCE_RECORDS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('UPDATE_ATTENDANCE_RECORDS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_ATTENDANCE_RECORDS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('UPDATE_ATTENDANCE_RECORDS') },
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_CLASS_SCHEDULES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_CLASS_SCHEDULES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_CLASS_SCHEDULES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_CLASS_SCHEDULES') },
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('CREATE_CLASS_SCHEDULES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_CLASS_SCHEDULES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_CLASS_SCHEDULES') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_CLASS_SCHEDULES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('UPDATE_CLASS_SCHEDULES') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_CLASS_SCHEDULES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('UPDATE_CLASS_SCHEDULES') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_CLASS_SCHEDULES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('UPDATE_CLASS_SCHEDULES') },
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_ASSIGNMENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_ASSIGNMENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_ASSIGNMENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_ASSIGNMENTS') },
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('CREATE_ASSIGNMENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_ASSIGNMENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_ASSIGNMENTS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_ASSIGNMENTS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('CREATE_ASSIGNMENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_ASSIGNMENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('UPDATE_ASSIGNMENTS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_ASSIGNMENTS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('UPDATE_ASSIGNMENTS') },
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_ASSIGNMENT_SUBMISSIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_ASSIGNMENT_SUBMISSIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_ASSIGNMENT_SUBMISSIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_ASSIGNMENT_SUBMISSIONS') },
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('CREATE_ASSIGNMENT_SUBMISSIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_ASSIGNMENT_SUBMISSIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_ASSIGNMENT_SUBMISSIONS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_ASSIGNMENT_SUBMISSIONS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_ASSIGNMENT_SUBMISSIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('UPDATE_ASSIGNMENT_SUBMISSIONS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('CREATE_ASSIGNMENT_SUBMISSIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_ASSIGNMENT_SUBMISSIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('UPDATE_ASSIGNMENT_SUBMISSIONS') },
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_LESSON_PLANS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_LESSON_PLANS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_LESSON_PLANS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_LESSON_PLANS') },
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('CREATE_LESSON_PLANS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_LESSON_PLANS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_LESSON_PLANS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_LESSON_PLANS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('CREATE_LESSON_PLANS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_LESSON_PLANS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('UPDATE_LESSON_PLANS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_LESSON_PLANS') },
                    
                  
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_MESSAGES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_MESSAGES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_MESSAGES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_MESSAGES') },
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('CREATE_MESSAGES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_MESSAGES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_MESSAGES') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('CREATE_MESSAGES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_MESSAGES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('UPDATE_MESSAGES') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('CREATE_MESSAGES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_MESSAGES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('UPDATE_MESSAGES') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('CREATE_MESSAGES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_MESSAGES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('UPDATE_MESSAGES') },
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_ADMISSION_APPLICATIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_ADMISSION_APPLICATIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_ADMISSION_APPLICATIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_ADMISSION_APPLICATIONS') },
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_ADMISSION_APPLICATIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_ADMISSION_APPLICATIONS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('CREATE_ADMISSION_APPLICATIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_ADMISSION_APPLICATIONS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('UPDATE_ADMISSION_APPLICATIONS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_ADMISSION_APPLICATIONS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                  
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_CONTACT_MESSAGES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_CONTACT_MESSAGES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_CONTACT_MESSAGES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_CONTACT_MESSAGES') },
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_CONTACT_MESSAGES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_CONTACT_MESSAGES') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_CONTACT_MESSAGES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('UPDATE_CONTACT_MESSAGES') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_CONTACT_MESSAGES') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                  
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_ALUMNI') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_ALUMNI') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_ALUMNI') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_ALUMNI') },
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('CREATE_ALUMNI') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_ALUMNI') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_ALUMNI') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_ALUMNI') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_ALUMNI') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_ALUMNI') },
                    
                  
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_SCHOOL_STATISTICS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_SCHOOL_STATISTICS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_SCHOOL_STATISTICS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_SCHOOL_STATISTICS') },
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('CREATE_SCHOOL_STATISTICS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_SCHOOL_STATISTICS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_SCHOOL_STATISTICS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_SCHOOL_STATISTICS') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('UPDATE_SCHOOL_STATISTICS') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_SCHOOL_STATISTICS') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_SCHOOL_STATISTICS') },
                    
                  
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_EXAM_PERFORMANCE_SUMMARIES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_EXAM_PERFORMANCE_SUMMARIES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_EXAM_PERFORMANCE_SUMMARIES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_EXAM_PERFORMANCE_SUMMARIES') },
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('CREATE_EXAM_PERFORMANCE_SUMMARIES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_EXAM_PERFORMANCE_SUMMARIES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_EXAM_PERFORMANCE_SUMMARIES') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_EXAM_PERFORMANCE_SUMMARIES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('UPDATE_EXAM_PERFORMANCE_SUMMARIES') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_EXAM_PERFORMANCE_SUMMARIES') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_EXAM_PERFORMANCE_SUMMARIES') },
                    
                  
                    
                  
                    
                  
                  
             
          
    
  
    
    
      
      
          
                
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_TOP_STUDENT_FEATURES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('READ_TOP_STUDENT_FEATURES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('UPDATE_TOP_STUDENT_FEATURES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('DELETE_TOP_STUDENT_FEATURES') },
                    
                  
                  
                
               
                
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('CREATE_TOP_STUDENT_FEATURES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('READ_TOP_STUDENT_FEATURES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('UPDATE_TOP_STUDENT_FEATURES') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('READ_TOP_STUDENT_FEATURES') },
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('UPDATE_TOP_STUDENT_FEATURES') },
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('READ_TOP_STUDENT_FEATURES') },
                    
                  
                    
                  
                    
                  
                  
                
               
                
                  
                    
                  
                    
                      { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('READ_TOP_STUDENT_FEATURES') },
                    
                  
                    
                  
                    
                  
                  
             
          
    
  
    
     
  
      
      
        
            { createdAt, updatedAt, roles_permissionsId: getId("SchoolDirector"), permissionId: getId('CREATE_SEARCH') },
        
            { createdAt, updatedAt, roles_permissionsId: getId("AcademicCoordinator"), permissionId: getId('CREATE_SEARCH') },
        
            { createdAt, updatedAt, roles_permissionsId: getId("RegistrarOfficer"), permissionId: getId('CREATE_SEARCH') },
        
            { createdAt, updatedAt, roles_permissionsId: getId("Teacher"), permissionId: getId('CREATE_SEARCH') },
        
            { createdAt, updatedAt, roles_permissionsId: getId("Student"), permissionId: getId('CREATE_SEARCH') },
        
      
      
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_USERS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_USERS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_USERS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_USERS') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_ROLES') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_ROLES') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_ROLES') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_ROLES') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_PERMISSIONS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_PERMISSIONS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_PERMISSIONS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_PERMISSIONS') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_SCHOOL_SETTINGS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_SCHOOL_SETTINGS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_SCHOOL_SETTINGS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_SCHOOL_SETTINGS') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_PAGES') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_PAGES') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_PAGES') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_PAGES') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_SCHOOL_YEARS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_SCHOOL_YEARS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_SCHOOL_YEARS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_SCHOOL_YEARS') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_GRADES') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_GRADES') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_GRADES') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_GRADES') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_STREAMS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_STREAMS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_STREAMS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_STREAMS') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_SUBJECTS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_SUBJECTS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_SUBJECTS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_SUBJECTS') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_SUBJECT_OFFERINGS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_SUBJECT_OFFERINGS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_SUBJECT_OFFERINGS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_SUBJECT_OFFERINGS') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_STAFF_MEMBERS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_STAFF_MEMBERS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_STAFF_MEMBERS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_STAFF_MEMBERS') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_STUDENTS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_STUDENTS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_STUDENTS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_STUDENTS') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_CLASS_SECTIONS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_CLASS_SECTIONS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_CLASS_SECTIONS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_CLASS_SECTIONS') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_ENROLLMENTS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_ENROLLMENTS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_ENROLLMENTS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_ENROLLMENTS') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_TERMS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_TERMS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_TERMS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_TERMS') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_EVENTS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_EVENTS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_EVENTS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_EVENTS') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_ANNOUNCEMENTS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_ANNOUNCEMENTS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_ANNOUNCEMENTS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_ANNOUNCEMENTS') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_NEWS_POSTS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_NEWS_POSTS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_NEWS_POSTS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_NEWS_POSTS') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_GALLERIES') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_GALLERIES') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_GALLERIES') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_GALLERIES') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_STUDY_MATERIALS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_STUDY_MATERIALS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_STUDY_MATERIALS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_STUDY_MATERIALS') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_EXAMS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_EXAMS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_EXAMS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_EXAMS') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_EXAM_RESULTS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_EXAM_RESULTS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_EXAM_RESULTS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_EXAM_RESULTS') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_ATTENDANCE_SESSIONS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_ATTENDANCE_SESSIONS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_ATTENDANCE_SESSIONS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_ATTENDANCE_SESSIONS') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_ATTENDANCE_RECORDS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_ATTENDANCE_RECORDS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_ATTENDANCE_RECORDS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_ATTENDANCE_RECORDS') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_CLASS_SCHEDULES') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_CLASS_SCHEDULES') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_CLASS_SCHEDULES') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_CLASS_SCHEDULES') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_ASSIGNMENTS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_ASSIGNMENTS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_ASSIGNMENTS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_ASSIGNMENTS') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_ASSIGNMENT_SUBMISSIONS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_ASSIGNMENT_SUBMISSIONS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_ASSIGNMENT_SUBMISSIONS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_ASSIGNMENT_SUBMISSIONS') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_LESSON_PLANS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_LESSON_PLANS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_LESSON_PLANS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_LESSON_PLANS') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_MESSAGES') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_MESSAGES') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_MESSAGES') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_MESSAGES') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_ADMISSION_APPLICATIONS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_ADMISSION_APPLICATIONS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_ADMISSION_APPLICATIONS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_ADMISSION_APPLICATIONS') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_CONTACT_MESSAGES') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_CONTACT_MESSAGES') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_CONTACT_MESSAGES') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_CONTACT_MESSAGES') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_ALUMNI') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_ALUMNI') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_ALUMNI') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_ALUMNI') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_SCHOOL_STATISTICS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_SCHOOL_STATISTICS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_SCHOOL_STATISTICS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_SCHOOL_STATISTICS') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_EXAM_PERFORMANCE_SUMMARIES') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_EXAM_PERFORMANCE_SUMMARIES') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_EXAM_PERFORMANCE_SUMMARIES') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_EXAM_PERFORMANCE_SUMMARIES') },
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_TOP_STUDENT_FEATURES') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_TOP_STUDENT_FEATURES') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('UPDATE_TOP_STUDENT_FEATURES') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('DELETE_TOP_STUDENT_FEATURES') },
    
    
    
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('READ_API_DOCS') },
    { createdAt, updatedAt, roles_permissionsId: getId("Administrator"), permissionId: getId('CREATE_SEARCH') },
    ]);


  await queryInterface.sequelize.query(`UPDATE "users" SET "app_roleId"='${getId("SuperAdmin")}' WHERE "email"='super_admin@flatlogic.com'`);
  await queryInterface.sequelize.query(`UPDATE "users" SET "app_roleId"='${getId("Administrator")}' WHERE "email"='admin@flatlogic.com'`);
  
   
      
      
        
        
           await queryInterface.sequelize.query(`UPDATE "users" SET "app_roleId"='${getId("SchoolDirector")}' WHERE "email"='client@hello.com'`);
        await queryInterface.sequelize.query(`UPDATE "users" SET "app_roleId"='${getId("AcademicCoordinator")}' WHERE "email"='john@doe.com'`);
       
      
      

}
};

