<commit_before><% arrow_dir = rtl? ? "◀" : "▶" %>
<ul id="main-menu">
  <li class="a"><%= link_to t('dashboard_text'), :controller => "user", :action => "dashboard" %></li>
  <% if permitted_to? :index, :student %>
    <li class="a"><%= link_to t('students'), :controller => "student", :action => "index" %></li>
  <% end %>
  <% if @current_user.admin? %>
    <li class="a"><%= link_to "#{t('attendance')} ▼", :controller => "student_attendance", :action => "index" %>
      <ul class="level-1">
        <li><%= link_to "#{t('attendance_register')}", :controller => 'attendances', :action => 'index'  %></li>
        <li><%= link_to "#{t('attendance_report')}", :controller => "attendance_reports", :action => "index" %></li>
      </ul>
    </li>
  <% elsif @current_user.employee? %>
    <% @employee= @current_user.employee_record  %>
    <% @employee_subjects= @employee.subject_ids  %>
    <% @employee_batches=Batch.find_all_by_employee_id(@employee.id) %>
    <% @attendance_type = Configuration.find_by_config_key('StudentAttendanceType') %>
    <% if @attendance_type.config_value == 'Daily' %>
      <% if permitted_to? :index, :student_attendance or @employee_batches.present? or @user.privileges.map{|p| p.name}.include?("StudentAttendanceView") or @user.privileges.map{|p| p.name}.include?("StudentAttendanceRegister") %>
        <li class="a"><%= link_to "#{t('attendance')} ▼", :controller => "student_attendance", :action => "index" %>
          <ul class="level-1">
            <% if @employee_batches.present? or @user.privileges.map{|p| p.name}.include?("StudentAttendanceRegister") %>
              <li><%= link_to "#{t('attendance_register')}", :controller => 'attendances', :action => 'index'  %></li>
            <% end %>
            <li><%= link_to "#{t('attendance_report')}", :controller => "attendance_reports", :action => "index" %></li>
          </ul>
        </li>
      <% end %>
    <% else %>
      <% if permitted_to? :index, :student_attendance or @employee_batches.present? or @employee_subjects.present? or @user.privileges.map{|p| p.name}.include?("StudentAttendanceView") or @user.privileges.map{|p| p.name}.include?("StudentAttendanceRegister") %>
        <li class="a"><%= link_to "#{t('attendance')} ▼", :controller => "student_attendance", :action => "index" %>
          <ul class="level-1">
            <% if @employee_batches.present? or @employee_subjects.present? or @user.privileges.map{|p| p.name}.include?("StudentAttendanceRegister") %>
              <li><%= link_to "#{t('attendance_register')}", :controller => 'attendances', :action => 'index'  %></li>
            <% end %>
            <li><%= link_to "#{t('attendance_report')}", :controller => "attendance_reports", :action => "index" %></li>
          </ul>
        </li>
      <% end %>
    <% end %>
  <% end %>
  <% if permitted_to? :index, :configuration %>
    <li class="a"><%= link_to "#{t('settings')} ▼", :controller => "configuration", :action => "index" %>
      <ul class="level-1">
        <% if permitted_to? :create, :courses %>
          <li><%= link_to "#{t('manage_course_batch')}", courses_path %></li>
        <% end %>
        <% if permitted_to? :settings, :configuration %>
          <li><%= link_to "#{t('manage_student_category')}", :controller => "student", :action => "categories" %></li>
        <% end %>
        <% if permitted_to? :index, :subjects %>
          <li><%= link_to "#{t('manage_subject')}", subjects_path %></li>
        <% end %>
        <% if permitted_to? :settings, :configuration %>
          <li><%= link_to "#{t('general_settings')}", :controller => "configuration", :action => "settings" %></li>
        <% end %>
        <% if permitted_to? :settings, :configuration %>
          <li><%= link_to "#{t('add_admission_additional_detail')}", :controller=>"student", :action => "add_additional_details" %></li>
        <% end %>
        <% if permitted_to? :index, :sms %>
          <li><%= link_to "#{t('sms_module')}", :controller=>"sms", :action => "index" %></li>
        <% end %>
      </ul>
    </li>
  <% end %>
  <!--
  <li><%= link_to t('news_text'), :controller => "news", :action => "index" \
    if @current_user.admin? %></li> -->
  <% if permitted_to? :index, :timetable %>
    <li class="a"><%= link_to "#{t('timetable_text')} <span class='down-arrow'>▼</span>", :controller => "timetable", :action => "index" %>
      <ul class="level-1">
        <%  if permitted_to? :new_timetable,:timetable%>
          <li><%= link_to "#{t('create_timetable')}", :controller => "timetable", :action => "new_timetable" %></li>
        <%  end%>
        <%if permitted_to? :edit_master,:timetable%>
          <li><%= link_to "#{t('edit_timetable')}", :controller => "timetable", :action => "edit_master" %></li>
        <%  end%>
        <%  if permitted_to? :index,:class_timings%>
          <li><%= link_to "#{t('set_class_timings')}", :controller => "class_timings", :action => "index"   %></li>
        <%  end%>
        <%  if permitted_to? :index,:weekdays%>
          <li><%= link_to "#{t('set_weekdays')}", :controller => "weekday", :action => "index"   %></li>
        <%  end%>
        <%  if permitted_to? :view,:timetable%>
          <li><%= link_to "#{t('view_timetable')}", :controller => "timetable", :action => "view" %></li>
        <%  end%>
        <%  if permitted_to? :view,:timetable%>
          <li><%= link_to "#{t('teacher_timetable')}", :controller => "timetable", :action => "teachers_timetable" %></li>
        <%  end%>
        <li><%= link_to "#{t('institutional')} #{t('timetable_text')}", :controller => "timetable", :action => "timetable" %></li>
        <%  if permitted_to? :edit,:timetable%>
          <li><%= link_to "#{t('create_text')} #{t('weekdays_text')}", :controller => "weekday", :action => "index" %></li>
        <% end %>
        <%if permitted_to? :work_allotment,:timetable%>
          <li><%= link_to "#{t('work_allotment')}", :controller => "timetable", :action => "work_allotment" %></li>
        <% end %>
      </ul>
    </li>
  <% end %>
  <% if @current_user.admin? %>
    <% FedenaPlugin::AVAILABLE_MODULES.each do |mod| %>
      <% unless mod[:top_bar].blank? %>
        <% if permitted_to? "#{mod[:top_bar][:action]}".to_sym,"#{mod[:top_bar][:controller]}".to_sym %>
          <%= link_to "#{t(mod[:top_bar][:title])}", {:controller => "#{mod[:top_bar][:controller]}", :action => "#{mod[:top_bar][:action]}"} %>
        <% end %>
      <% end %>
    <% end %>
  <% end %>
  <li class="a"><a href="#"><%= t('more') %> ▼</a>
    <ul class="level-1">
      <li><%= link_to "#{t('calendar_text')}" , :controller => "calendar", :action=>"index" %></li>
      <% if permitted_to? :index, :exam %>
        <li><%= link_to "#{t('examination')} <span class='right-arrow'>#{arrow_dir}</span>" , :controller => "exam", :action=>"index" %>
          <ul class="level-2">
            <% @employee_subjects=[] %>
            <% @employee_subjects= @current_user.employee_record.subjects.map { |n| n.id} if @current_user.employee?  %>
            <% if (@current_user.admin? or @current_user.privileges.collect(&:name).include?('ExaminationControl')) %>
              <%  if permitted_to? :settings,:exam %>
                <li><%= link_to "Settings" ,:controller=>'exam',:action=>'settings' %> </li>
              <% end %>
              <%  if permitted_to? :create_exam, :exam  %>
                <li><%= link_to "#{t('exam_management')}" , :controller => "exam",:action=>'create_exam' %>  </li>
              <% end %>
              <%  if permitted_to? :generate_reports,:exam %>
                <li><%= link_to "Generate Reports" ,:controller=>'exam',:action=>'generate_reports' %> </li>
              <% end %>
              <li><%= link_to "Report Center" , :controller => "exam",:action=>'report_center' %></li>
            <% elsif (@current_user.privileges.collect(&:name).include?('EnterResults') or !@employee_subjects.empty?) %>
              <%  if permitted_to? :create_exam, :exam  %>
                <li><%= link_to "#{t('exam_management')}" , :controller => "exam",:action=>'create_exam' %>  </li>
              <% end %>
              <li><%= link_to "Report Center" , :controller => "exam",:action=>'report_center' %></li>
            <% elsif (@current_user.privileges.collect(&:name).include?('ViewResults') or (Batch.all.collect(&:employee_id).include?(@current_user.employee_record.id.to_s) if @current_user.employee?)) %>
              <li><%= link_to "Report Center" , :controller => "exam",:action=>'report_center' %></li>
            <% end %>
            <% FedenaPlugin::ADDITIONAL_LINKS[:online_exam_index_link].each do |mod| %>
              <%  if permitted_to? "#{mod[:destination][:action]}".to_sym,"#{mod[:destination][:controller]}".to_sym %>
                <li><%= link_to "#{t("#{mod[:title]}")}",mod[:destination] %></li>
              <% end %>
            <% end %>
          </ul><commit_msg>cce reports link in main menu<commit_after><% arrow_dir = rtl? ? "◀" : "▶" %>
<ul id="main-menu">
  <li class="a"><%= link_to t('dashboard_text'), :controller => "user", :action => "dashboard" %></li>
  <% if permitted_to? :index, :student %>
    <li class="a"><%= link_to t('students'), :controller => "student", :action => "index" %></li>
  <% end %>
  <% if @current_user.admin? %>
    <li class="a"><%= link_to "#{t('attendance')} ▼", :controller => "student_attendance", :action => "index" %>
      <ul class="level-1">
        <li><%= link_to "#{t('attendance_register')}", :controller => 'attendances', :action => 'index'  %></li>
        <li><%= link_to "#{t('attendance_report')}", :controller => "attendance_reports", :action => "index" %></li>
      </ul>
    </li>
  <% elsif @current_user.employee? %>
    <% @employee= @current_user.employee_record  %>
    <% @employee_subjects= @employee.subject_ids  %>
    <% @employee_batches=Batch.find_all_by_employee_id(@employee.id) %>
    <% @attendance_type = Configuration.find_by_config_key('StudentAttendanceType') %>
    <% if @attendance_type.config_value == 'Daily' %>
      <% if permitted_to? :index, :student_attendance or @employee_batches.present? or @user.privileges.map{|p| p.name}.include?("StudentAttendanceView") or @user.privileges.map{|p| p.name}.include?("StudentAttendanceRegister") %>
        <li class="a"><%= link_to "#{t('attendance')} ▼", :controller => "student_attendance", :action => "index" %>
          <ul class="level-1">
            <% if @employee_batches.present? or @user.privileges.map{|p| p.name}.include?("StudentAttendanceRegister") %>
              <li><%= link_to "#{t('attendance_register')}", :controller => 'attendances', :action => 'index'  %></li>
            <% end %>
            <li><%= link_to "#{t('attendance_report')}", :controller => "attendance_reports", :action => "index" %></li>
          </ul>
        </li>
      <% end %>
    <% else %>
      <% if permitted_to? :index, :student_attendance or @employee_batches.present? or @employee_subjects.present? or @user.privileges.map{|p| p.name}.include?("StudentAttendanceView") or @user.privileges.map{|p| p.name}.include?("StudentAttendanceRegister") %>
        <li class="a"><%= link_to "#{t('attendance')} ▼", :controller => "student_attendance", :action => "index" %>
          <ul class="level-1">
            <% if @employee_batches.present? or @employee_subjects.present? or @user.privileges.map{|p| p.name}.include?("StudentAttendanceRegister") %>
              <li><%= link_to "#{t('attendance_register')}", :controller => 'attendances', :action => 'index'  %></li>
            <% end %>
            <li><%= link_to "#{t('attendance_report')}", :controller => "attendance_reports", :action => "index" %></li>
          </ul>
        </li>
      <% end %>
    <% end %>
  <% end %>
  <% if permitted_to? :index, :configuration %>
    <li class="a"><%= link_to "#{t('settings')} ▼", :controller => "configuration", :action => "index" %>
      <ul class="level-1">
        <% if permitted_to? :create, :courses %>
          <li><%= link_to "#{t('manage_course_batch')}", courses_path %></li>
        <% end %>
        <% if permitted_to? :settings, :configuration %>
          <li><%= link_to "#{t('manage_student_category')}", :controller => "student", :action => "categories" %></li>
        <% end %>
        <% if permitted_to? :index, :subjects %>
          <li><%= link_to "#{t('manage_subject')}", subjects_path %></li>
        <% end %>
        <% if permitted_to? :settings, :configuration %>
          <li><%= link_to "#{t('general_settings')}", :controller => "configuration", :action => "settings" %></li>
        <% end %>
        <% if permitted_to? :settings, :configuration %>
          <li><%= link_to "#{t('add_admission_additional_detail')}", :controller=>"student", :action => "add_additional_details" %></li>
        <% end %>
        <% if permitted_to? :index, :sms %>
          <li><%= link_to "#{t('sms_module')}", :controller=>"sms", :action => "index" %></li>
        <% end %>
      </ul>
    </li>
  <% end %>
  <!--
  <li><%= link_to t('news_text'), :controller => "news", :action => "index" \
    if @current_user.admin? %></li> -->
  <% if permitted_to? :index, :timetable %>
    <li class="a"><%= link_to "#{t('timetable_text')} <span class='down-arrow'>▼</span>", :controller => "timetable", :action => "index" %>
      <ul class="level-1">
        <%  if permitted_to? :new_timetable,:timetable%>
          <li><%= link_to "#{t('create_timetable')}", :controller => "timetable", :action => "new_timetable" %></li>
        <%  end%>
        <%if permitted_to? :edit_master,:timetable%>
          <li><%= link_to "#{t('edit_timetable')}", :controller => "timetable", :action => "edit_master" %></li>
        <%  end%>
        <%  if permitted_to? :index,:class_timings%>
          <li><%= link_to "#{t('set_class_timings')}", :controller => "class_timings", :action => "index"   %></li>
        <%  end%>
        <%  if permitted_to? :index,:weekdays%>
          <li><%= link_to "#{t('set_weekdays')}", :controller => "weekday", :action => "index"   %></li>
        <%  end%>
        <%  if permitted_to? :view,:timetable%>
          <li><%= link_to "#{t('view_timetable')}", :controller => "timetable", :action => "view" %></li>
        <%  end%>
        <%  if permitted_to? :view,:timetable%>
          <li><%= link_to "#{t('teacher_timetable')}", :controller => "timetable", :action => "teachers_timetable" %></li>
        <%  end%>
        <li><%= link_to "#{t('institutional')} #{t('timetable_text')}", :controller => "timetable", :action => "timetable" %></li>
        <%  if permitted_to? :edit,:timetable%>
          <li><%= link_to "#{t('create_text')} #{t('weekdays_text')}", :controller => "weekday", :action => "index" %></li>
        <% end %>
        <%if permitted_to? :work_allotment,:timetable%>
          <li><%= link_to "#{t('work_allotment')}", :controller => "timetable", :action => "work_allotment" %></li>
        <% end %>
      </ul>
    </li>
  <% end %>
  <% if @current_user.admin? %>
    <% FedenaPlugin::AVAILABLE_MODULES.each do |mod| %>
      <% unless mod[:top_bar].blank? %>
        <% if permitted_to? "#{mod[:top_bar][:action]}".to_sym,"#{mod[:top_bar][:controller]}".to_sym %>
          <%= link_to "#{t(mod[:top_bar][:title])}", {:controller => "#{mod[:top_bar][:controller]}", :action => "#{mod[:top_bar][:action]}"} %>
        <% end %>
      <% end %>
    <% end %>
  <% end %>
  <li class="a"><a href="#"><%= t('more') %> ▼</a>
    <ul class="level-1">
      <li><%= link_to "#{t('calendar_text')}" , :controller => "calendar", :action=>"index" %></li>
      <% if permitted_to? :index, :exam %>
        <li><%= link_to "#{t('examination')} <span class='right-arrow'>#{arrow_dir}</span>" , :controller => "exam", :action=>"index" %>
          <ul class="level-2">
            <% @employee_subjects=[] %>
            <% @employee_subjects= @current_user.employee_record.subjects.map { |n| n.id} if @current_user.employee?  %>
            <% if (@current_user.admin? or @current_user.privileges.collect(&:name).include?('ExaminationControl')) %>
              <%  if permitted_to? :settings,:exam %>
                <li><%= link_to "Settings" ,:controller=>'exam',:action=>'settings' %> </li>
              <% end %>
              <%  if permitted_to? :create_exam, :exam  %>
                <li><%= link_to "#{t('exam_management')}" , :controller => "exam",:action=>'create_exam' %>  </li>
              <% end %>
              <%  if permitted_to? :generate_reports,:exam %>
                <li><%= link_to "Generate Reports" ,:controller=>'exam',:action=>'generate_reports' %> </li>
              <% end %>
              <li><%= link_to "Report Center" , :controller => "exam",:action=>'report_center' %></li>
            <% elsif (@current_user.privileges.collect(&:name).include?('EnterResults') or !@employee_subjects.empty?) %>
              <%  if permitted_to? :create_exam, :exam  %>
                <li><%= link_to "#{t('exam_management')}" , :controller => "exam",:action=>'create_exam' %>  </li>
              <% end %>
              <li><%= link_to "Report Center" , :controller => "exam",:action=>'report_center' %></li>
            <% elsif (@current_user.privileges.collect(&:name).include?('ViewResults') or (Batch.all.collect(&:employee_id).include?(@current_user.employee_record.id.to_s) if @current_user.employee?)) %>
              <li><%= link_to "Report Center" , :controller => "exam",:action=>'report_center' %></li>
            <% end %>
            <%  if permitted_to? :index, :cce_reports  %>
              <li><%= link_to "CCE Report" , :controller => "cce_reports" %>  </li>
            <% end %>
            <% FedenaPlugin::ADDITIONAL_LINKS[:online_exam_index_link].each do |mod| %>
              <%  if permitted_to? "#{mod[:destination][:action]}".to_sym,"#{mod[:destination][:controller]}".to_sym %>
                <li><%= link_to "#{t("#{mod[:title]}")}",mod[:destination] %></li>
              <% end %>
            <% end %>
          </ul>
{'fraction_non_alphanumeric': 0.23087991145545103, 'fraction_numerical': 0.000774764803541782, 'mean_word_length': 3.241023233982633, 'pattern_counts': {'":': 0, '<': 448, '<?xml version=': 0, '>': 597, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4875764', 'n_tokens_mistral': 6497, 'n_tokens_neox': 6081, 'n_words': 1104}