<% define_admin_breadcrumbs do %>
  <% add_admin_breadcrumb('每日统计', admins_multiple_school_reports_path) %>
<% end %>

<div class="box search-form-container multiple-school-report-list-form">
 <%= form_tag(admins_multiple_school_reports_path, method: :get, class: 'form-inline search-form', remote:true) do %>
    <div class="time-select">
      <div class="form-group grow-date-container">
        <div class="input-group input-daterange">
          <%= text_field_tag :begin_at, params[:begin_at], class: 'form-control start-date mx-0',autocomplete: "off", placeholder: '开始日期' %>
            <div class="input-group-prepend"><span class="input-group-text">到</span></div>
            <%= text_field_tag :end_at, params[:end_at], class: 'form-control end-date mx-0', autocomplete: "off", placeholder: '结束日期' %>
        </div>
      </div>
    </div>

    <div class="form-group mr-5 ml-5">
      <label for="tag-choosed">学校名称：</label>
      <select id="school" name="school" class="form-control input-group" style="width:240px">
      </select>
    </div>

    <div class="form-group mr-2">
      <label>统计类型：</label>
      <%= select_tag(:search_type, options_for_select([['用户登录次数'],['教师上传资源数'], ['实训作业数'], ['发布实训作业数'],['评测次数']]), class: 'form-control') %>
    </div>
    <%= submit_tag('搜索', class: 'btn btn-primary ml-3', 'data-disable-with': '搜索中...') %>
    <%= javascript_void_link '导出Excel', class: 'btn btn-outline-primary export-action ml-5', 'data-url': admins_multiple_school_reports_path(format: :xlsx) %>
  <% end %>
</div>

  <div class="box admin-list-container daily-school-statistic-list-container">
    <%= render partial: 'admins/multiple_school_reports/shared/list', locals: { data: @data } %>
  </div>
</div>