+
<%= render(partial: 'admins/competition_prize_users/shared/list', locals: { prize_users: @prize_users }) %>
\ No newline at end of file
diff --git a/app/views/admins/competition_prize_users/index.xlsx.axlsx b/app/views/admins/competition_prize_users/index.xlsx.axlsx
new file mode 100644
index 000000000..63e23a214
--- /dev/null
+++ b/app/views/admins/competition_prize_users/index.xlsx.axlsx
@@ -0,0 +1,33 @@
+wb = xlsx_package.workbook
+
+wb.styles do |s|
+ blue_cell = s.add_style :bg_color => "FAEBDC", :sz => 10,:height => 25,:b => true, :border => { :style => :thin, :color =>"000000" },:alignment => {wrap_text: true,:horizontal => :center,:vertical => :center}
+ wb.add_worksheet(name: "#{@competition.name}证书审批列表") do |sheet|
+ sheet.add_row %w(序号 排名 奖项 战队ID 战队名称 姓名 职业 学号 学校名称 学院名称 地区 实名认证 职业认证 手机号码 队长 签领/开户行及银行卡号 审批时间 审批人), :height => 25,:style => blue_cell
+
+ @all_prize_users.each_with_index do |prize_user, index|
+ user = prize_user.user
+ data = [
+ index + 1,
+ prize_user.rank,
+ prize_user.competition_prize.name,
+ prize_user.competition_team_id,
+ prize_user.competition_team.name,
+ user.real_name,
+ user.identity,
+ user.student_id,
+ user.school_name,
+ user.department_name,
+ user.location,
+ user.auth_status,
+ user.pro_status,
+ user.phone,
+ prize_user.leader? ? "是" : "-",
+ [prize_user.extra&.[]('bank'), prize_user.extra&.[]('second_bank'), prize_user.extra&.[]('card_no')].compact.join('/'),
+ prize_user.approved_at&.strftime('%Y-%m-%d %H:%M'),
+ prize_user.approver&.real_name
+ ]
+ sheet.add_row(data)
+ end
+ end
+end
diff --git a/app/views/admins/competition_prize_users/shared/_tr.html.erb b/app/views/admins/competition_prize_users/shared/_tr.html.erb
index 18912c36a..679db2ad7 100644
--- a/app/views/admins/competition_prize_users/shared/_tr.html.erb
+++ b/app/views/admins/competition_prize_users/shared/_tr.html.erb
@@ -16,8 +16,12 @@
<% if prize_user.leader? && prize_user.competition_prize.category == 'bonus' %>
<% bank_content = [prize_user.extra&.[]('bank'), prize_user.extra&.[]('second_bank'), prize_user.extra&.[]('card_no')].compact.join(' ').presence || '无' %>
- <%= javascript_void_link('查看银行账户', data: { toggle: 'popover', title: '银行账号', content: bank_content.html_safe, html: true }) %>
- <% end %>
+ <%= javascript_void_link('查看银行账户', data: { toggle: 'tooltip', title: bank_content.html_safe, html: true, placement: 'left', trigger: 'click' }) %>
+ <% prize_module = prize_user.competition&.competition_modules.find_by(module_type: 'certificate') %>
+ <% if prize_module %>
+ <%= link_to('编辑', EduSetting.get("host_name").to_s + "/competitions/#{prize_user.competition&.identifier}?menu=#{prize_module&.id}&user_id=#{user.id}", target: "_blank") %>
+ <% end %>
+ <% end %>
<% if prize_user.pending? %>
<%= link_to('审批通过', approve_admins_competition_competition_prize_user_path(prize_user.competition, prize_user),
diff --git a/app/views/admins/competitions/index.html.erb b/app/views/admins/competitions/index.html.erb
index 41e061fc1..3af2a5d03 100644
--- a/app/views/admins/competitions/index.html.erb
+++ b/app/views/admins/competitions/index.html.erb
@@ -25,9 +25,10 @@
-
+
<%= render partial: 'admins/competitions/shared/list', locals: { competitions: @competitions } %>
<%= render 'admins/competitions/shared/create_competition_modal' %>
-<%= render partial: 'admins/shared/modal/upload_file_modal', locals: { title: '上传图片' } %>
\ No newline at end of file
+<%= render partial: 'admins/shared/modal/upload_file_modal', locals: { title: '上传图片' } %>
+<%= render partial: 'admins/competitions/shared/import_competition_score_modal' %>
\ No newline at end of file
diff --git a/app/views/admins/competitions/shared/_import_competition_score_modal.html.erb b/app/views/admins/competitions/shared/_import_competition_score_modal.html.erb
new file mode 100644
index 000000000..5b89c4c10
--- /dev/null
+++ b/app/views/admins/competitions/shared/_import_competition_score_modal.html.erb
@@ -0,0 +1,32 @@
+
\ No newline at end of file
diff --git a/app/views/admins/competitions/shared/_td.html.erb b/app/views/admins/competitions/shared/_td.html.erb
index 394a41d79..8d5a4afb3 100644
--- a/app/views/admins/competitions/shared/_td.html.erb
+++ b/app/views/admins/competitions/shared/_td.html.erb
@@ -24,4 +24,8 @@
<% end %>
<%= link_to competition.published? ? "下架" : "上架", online_switch_admins_competition_path(competition), class: 'action online-action', method: :post, remote: true %>
+
+ <% if competition.mode != 1 %>
+ <%= javascript_void_link '导入成绩', class: 'action', data: { competition_id: competition.id, toggle: 'modal', target: '.admin-import-competition-score-modal'} %>
+ <% end %>
\ No newline at end of file
diff --git a/app/views/admins/customers/index.html.erb b/app/views/admins/customers/index.html.erb
new file mode 100644
index 000000000..b93a5c1e8
--- /dev/null
+++ b/app/views/admins/customers/index.html.erb
@@ -0,0 +1,19 @@
+<% define_admin_breadcrumbs do %>
+ <% add_admin_breadcrumb('合作伙伴', admins_partners_path) %>
+ <% add_admin_breadcrumb(current_partner.school&.name || current_partner.name) %>
+<% end %>
+
+
+ <%= form_tag(admins_partner_customers_path(current_partner), method: :get, class: 'form-inline search-form', remote: true) do %>
+ <%= text_field_tag(:keyword, params[:keyword], class: 'form-control col-md-4 ml-3', placeholder: '客户名称检索') %>
+ <%= submit_tag('搜索', class: 'btn btn-primary ml-3', 'data-disable-with': '搜索中...') %>
+ <% end %>
+
+ <%= javascript_void_link('添加', class: 'btn btn-primary', data: { toggle: 'modal', target: '.admin-select-school-modal' }) %>
+
+
+
+ <%= render 'admins/customers/shared/list', customers: @customers %>
+
+
+<%= render partial: 'admins/shared/modal/select_school_modal', locals: { title: '添加客户', multiple: true, url: admins_partner_customers_path(current_partner) } %>
\ No newline at end of file
diff --git a/app/views/admins/customers/index.js.erb b/app/views/admins/customers/index.js.erb
new file mode 100644
index 000000000..8fa2e205d
--- /dev/null
+++ b/app/views/admins/customers/index.js.erb
@@ -0,0 +1 @@
+$('.customer-list-container').html("<%= j(render partial: 'admins/customers/shared/list', locals: { customers: @customers }) %>");
\ No newline at end of file
diff --git a/app/views/admins/customers/shared/_list.html.erb b/app/views/admins/customers/shared/_list.html.erb
new file mode 100644
index 000000000..0ba5638cb
--- /dev/null
+++ b/app/views/admins/customers/shared/_list.html.erb
@@ -0,0 +1,26 @@
+
+
+
+ 客户名称
+ <%= sort_tag('添加时间', name: 'created_at', path: admins_partner_customers_path(current_partner)) %>
+ 操作
+
+
+
+ <% if customers.present? %>
+ <% customers.each do |customer| %>
+
+ <%= customer.school&.name %>
+ <%= customer.created_at&.strftime('%Y-%m-%d %H:%M') %>
+
+ <%= delete_link '删除', admins_partner_customer_path(current_partner, customer, element: ".customer-item-#{customer.id}"), class: 'delete-customer-action' %>
+
+
+ <% end %>
+ <% else %>
+ <%= render 'admins/shared/no_data_for_table' %>
+ <% end %>
+
+
+
+<%= render partial: 'admins/shared/paginate', locals: { objects: customers } %>
\ No newline at end of file
diff --git a/app/views/admins/daily_school_statistics/index.html.erb b/app/views/admins/daily_school_statistics/index.html.erb
index 39dcba633..c3eb43691 100644
--- a/app/views/admins/daily_school_statistics/index.html.erb
+++ b/app/views/admins/daily_school_statistics/index.html.erb
@@ -24,6 +24,6 @@
其它作业总数
<%= @other_homework_total %> 个
-
+
<%= render(partial: 'admins/identity_authentications/shared/list', locals: { applies: @applies }) %>
diff --git a/app/views/admins/identity_authentications/shared/_list.html.erb b/app/views/admins/identity_authentications/shared/_list.html.erb
index c40d681ec..607feb93a 100644
--- a/app/views/admins/identity_authentications/shared/_list.html.erb
+++ b/app/views/admins/identity_authentications/shared/_list.html.erb
@@ -43,6 +43,9 @@
<%= link_to "/users/#{user.login}", class: 'identity-authentication-avatar', target: '_blank', data: { toggle: 'tooltip', title: '个人主页' } do %>
<% end %>
+ <% if user.from_sub_site? %>
+
合作
+ <% end %>
<%= user.real_name %>
<%= user.ID_number %>
@@ -51,8 +54,8 @@
<% unless is_processed %>
- <% if File.exists?(disk_real_name_auth_filename(user.id)) %>
- <%= image_tag(real_name_auth_file_url(user.id).to_s + "?#{Time.now.to_i}", width: 40, height: 40, class: 'preview-image auth-image', data: { toggle: 'tooltip', title: '点击预览' }) %>
+ <% if apply.attachment %>
+ <%= image_tag("/api/attachments/#{apply.attachment.id}", width: 40, height: 40, class: 'preview-image auth-image', data: { toggle: 'tooltip', title: '点击预览' }) %>
<% else %>
<%= content_tag(:span, '图片已删除', class: 'text-secondary') %>
<% end %>
diff --git a/app/views/admins/laboratories/index.html.erb b/app/views/admins/laboratories/index.html.erb
index 012eed792..397f50cbe 100644
--- a/app/views/admins/laboratories/index.html.erb
+++ b/app/views/admins/laboratories/index.html.erb
@@ -11,7 +11,7 @@
<%= javascript_void_link '新建', class: 'btn btn-primary', data: { toggle: 'modal', target: '.admin-create-laboratory-modal' } %>
-
+
<%= render(partial: 'admins/laboratories/shared/list', locals: { laboratories: @laboratories }) %>
diff --git a/app/views/admins/laboratories/shared/_laboratory_item.html.erb b/app/views/admins/laboratories/shared/_laboratory_item.html.erb
index 92b8ef9a9..abfcda349 100644
--- a/app/views/admins/laboratories/shared/_laboratory_item.html.erb
+++ b/app/views/admins/laboratories/shared/_laboratory_item.html.erb
@@ -41,6 +41,9 @@
+
+
导航设置
diff --git a/app/views/admins/laboratory_shixuns/index.html.erb b/app/views/admins/laboratory_shixuns/index.html.erb
new file mode 100644
index 000000000..c91ddc60b
--- /dev/null
+++ b/app/views/admins/laboratory_shixuns/index.html.erb
@@ -0,0 +1,45 @@
+<% define_admin_breadcrumbs do %>
+ <% add_admin_breadcrumb('云上实验室', admins_laboratories_path) %>
+ <% add_admin_breadcrumb("#{current_laboratory.name} - 实训项目") %>
+<% end %>
+
+
+
+ <%= form_tag(admins_laboratory_laboratory_shixuns_path(current_laboratory), method: :get, class: 'form-inline search-form', remote: true) do %>
+
+ 状态:
+ <% status_options = [['全部', ''], ['编辑中', 0], ['审核中', 1], ['已发布', 2], ['已关闭', 3]] %>
+ <%= select_tag(:status, options_for_select(status_options), class: 'form-control') %>
+
+
+
+ 技术平台:
+ <%= select_tag(:tag_id, options_for_select(MirrorRepository.pluck(:type_name,:id).unshift(['']), params[:tag_id]), class: 'form-control') %>
+
+
+ <%= text_field_tag(:keyword, params[:keyword], class: 'form-control col-12 col-md-2 mr-3', placeholder: '创建者/实训名称检索') %>
+
+
+ <%= hidden_field_tag(:homepage, false, id:'') %>
+ <%= check_box_tag(:homepage, true, params[:homepage].to_s == 'true', class: 'form-check-input') %>
+ 只看首页展示
+
+
+
+ <%= hidden_field_tag(:ownership, false, id:'') %>
+ <%= check_box_tag(:ownership, true, params[:ownership].to_s == 'true', class: 'form-check-input') %>
+ 只看自建
+
+
+ <%= submit_tag('搜索', class: 'btn btn-primary ml-3', 'data-disable-with': '搜索中...') %>
+ <%= link_to '清空', admins_laboratory_laboratory_shixuns_path(current_laboratory), class: 'btn btn-default','data-disable-with': '清空中...' %>
+ <% end %>
+
+ <%= javascript_void_link('添加实训', class: 'btn btn-primary', data: { toggle: 'modal', target: '.admin-add-laboratory-shixun-modal' }) %>
+
+
+
+ <%= render partial: 'admins/laboratory_shixuns/shared/list', locals: { laboratory_shixuns: @laboratory_shixuns } %>
+
+
+<%= render partial: 'admins/laboratory_shixuns/shared/add_laboratory_shixun_modal' %>
\ No newline at end of file
diff --git a/app/views/admins/laboratory_shixuns/index.js.erb b/app/views/admins/laboratory_shixuns/index.js.erb
new file mode 100644
index 000000000..0a51afa21
--- /dev/null
+++ b/app/views/admins/laboratory_shixuns/index.js.erb
@@ -0,0 +1 @@
+$('.laboratory-shixun-list-container').html("<%= j(render partial: 'admins/laboratory_shixuns/shared/list', locals: { laboratory_shixuns: @laboratory_shixuns }) %>");
\ No newline at end of file
diff --git a/app/views/admins/laboratory_shixuns/shared/_add_laboratory_shixun_modal.html.erb b/app/views/admins/laboratory_shixuns/shared/_add_laboratory_shixun_modal.html.erb
new file mode 100644
index 000000000..56d01d663
--- /dev/null
+++ b/app/views/admins/laboratory_shixuns/shared/_add_laboratory_shixun_modal.html.erb
@@ -0,0 +1,28 @@
+
\ No newline at end of file
diff --git a/app/views/admins/laboratory_shixuns/shared/_list.html.erb b/app/views/admins/laboratory_shixuns/shared/_list.html.erb
new file mode 100644
index 000000000..e1244c472
--- /dev/null
+++ b/app/views/admins/laboratory_shixuns/shared/_list.html.erb
@@ -0,0 +1,27 @@
+
+
+
+ 实训名称
+ 技术平台
+ 技术体系
+ 封面
+ 创建者
+ 状态
+ 执行时间
+ 操作
+
+
+
+ <% if laboratory_shixuns.present? %>
+ <% laboratory_shixuns.each do |laboratory_shixun| %>
+
+ <%= render partial: 'admins/laboratory_shixuns/shared/td', locals: { laboratory_shixun: laboratory_shixun } %>
+
+ <% end %>
+ <% else %>
+ <%= render 'admins/shared/no_data_for_table' %>
+ <% end %>
+
+
+
+<%= render partial: 'admins/shared/paginate', locals: { objects: laboratory_shixuns } %>
\ No newline at end of file
diff --git a/app/views/admins/laboratory_shixuns/shared/_td.html.erb b/app/views/admins/laboratory_shixuns/shared/_td.html.erb
new file mode 100644
index 000000000..dbdf0df75
--- /dev/null
+++ b/app/views/admins/laboratory_shixuns/shared/_td.html.erb
@@ -0,0 +1,32 @@
+<%- shixun = laboratory_shixun.shixun -%>
+
+
+ <%= link_to "/shixuns/#{shixun.identifier}", target: '_blank' do %>
+ <%= shixun.name %>
+ 首页
+ 自建
+ <% end %>
+
+
<%= shixun.shixun_main_name %>
+
+ <% shixun.tag_repertoires.each do |tag| %>
+ <%= tag.name %>
+ <% end %>
+
+
+ <% imageExists = Util::FileManage.exists?(shixun) %>
+ <% imageUrl = imageExists ? '/' + url_to_avatar(shixun) : '' %>
+ <%= image_tag(imageUrl, width: 60, height: 40, class: "preview-image shixun-image-#{shixun.id}", data: { toggle: 'tooltip', title: '点击预览' }, style: imageExists ? '' : 'display:none') %>
+
+
<%= link_to shixun.user&.real_name, "/users/#{shixun.user&.login}", target:'_blank' %>
+
<%= t("shixun.status.#{shixun.status}") %>
+
<%= shixun.excute_time %>
+
+ <%= link_to('去修改', admins_shixun_settings_path(id: laboratory_shixun.shixun_id)) %>
+ <%= javascript_void_link('首页展示', class: 'action homepage-show-action', data: { id: laboratory_shixun.id }, style: laboratory_shixun.homepage? ? 'display:none' : '') %>
+ <%= javascript_void_link('取消首页展示', class: 'action homepage-hide-action', data: { id: laboratory_shixun.id }, style: laboratory_shixun.homepage? ? '' : 'display:none') %>
+
+ <% unless laboratory_shixun.ownership? %>
+ <%= delete_link '删除', admins_laboratory_laboratory_shixun_path(current_laboratory, laboratory_shixun, element: ".laboratory-shixun-item-#{laboratory_shixun.id}") %>
+ <% end %>
+
\ No newline at end of file
diff --git a/app/views/admins/laboratory_subjects/index.html.erb b/app/views/admins/laboratory_subjects/index.html.erb
new file mode 100644
index 000000000..211bf24f3
--- /dev/null
+++ b/app/views/admins/laboratory_subjects/index.html.erb
@@ -0,0 +1,45 @@
+<% define_admin_breadcrumbs do %>
+ <% add_admin_breadcrumb('云上实验室', admins_laboratories_path) %>
+ <% add_admin_breadcrumb("#{current_laboratory.name} - 实践课程") %>
+<% end %>
+
+
+
+ <%= form_tag(admins_laboratory_laboratory_subjects_path(current_laboratory), method: :get, class: 'form-inline search-form', remote: true) do %>
+
+ 状态:
+ <% status_options = [['全部', ''], ['编辑中', 0], ['审核中', 1], ['已发布', 2]] %>
+ <%= select_tag(:status, options_for_select(status_options), class: 'form-control') %>
+
+
+
+ 单位:
+ <%= select_tag :school_id, options_for_select([''], params[:school_id]), class: 'form-control school-select flex-1' %>
+
+
+ <%= text_field_tag(:keyword, params[:keyword], class: 'form-control col-12 col-md-2 mr-3', placeholder: '创建者/课程名称检索') %>
+
+
+ <%= hidden_field_tag(:homepage, false, id:'') %>
+ <%= check_box_tag(:homepage, true, params[:homepage].to_s == 'true', class: 'form-check-input') %>
+ 只看首页展示
+
+
+
+ <%= hidden_field_tag(:ownership, false, id:'') %>
+ <%= check_box_tag(:ownership, true, params[:ownership].to_s == 'true', class: 'form-check-input') %>
+ 只看自建
+
+
+ <%= submit_tag('搜索', class: 'btn btn-primary ml-3', 'data-disable-with': '搜索中...') %>
+ <%= link_to '清空', admins_laboratory_laboratory_subjects_path(current_laboratory), class: 'btn btn-default','data-disable-with': '清空中...' %>
+ <% end %>
+
+ <%= javascript_void_link('添加课程', class: 'btn btn-primary', data: { toggle: 'modal', target: '.admin-add-laboratory-subject-modal' }) %>
+
+
+
+ <%= render partial: 'admins/laboratory_subjects/shared/list', locals: { laboratory_subjects: @laboratory_subjects } %>
+
+
+<%= render partial: 'admins/laboratory_subjects/shared/add_laboratory_subject_modal' %>
\ No newline at end of file
diff --git a/app/views/admins/laboratory_subjects/index.js.erb b/app/views/admins/laboratory_subjects/index.js.erb
new file mode 100644
index 000000000..3ebc1286c
--- /dev/null
+++ b/app/views/admins/laboratory_subjects/index.js.erb
@@ -0,0 +1 @@
+$('.laboratory-subject-list-container').html("<%= j(render partial: 'admins/laboratory_subjects/shared/list', locals: { laboratory_subjects: @laboratory_subjects }) %>");
\ No newline at end of file
diff --git a/app/views/admins/laboratory_subjects/shared/_add_laboratory_subject_modal.html.erb b/app/views/admins/laboratory_subjects/shared/_add_laboratory_subject_modal.html.erb
new file mode 100644
index 000000000..a6fb89186
--- /dev/null
+++ b/app/views/admins/laboratory_subjects/shared/_add_laboratory_subject_modal.html.erb
@@ -0,0 +1,28 @@
+
\ No newline at end of file
diff --git a/app/views/admins/laboratory_subjects/shared/_list.html.erb b/app/views/admins/laboratory_subjects/shared/_list.html.erb
new file mode 100644
index 000000000..55f67dea8
--- /dev/null
+++ b/app/views/admins/laboratory_subjects/shared/_list.html.erb
@@ -0,0 +1,52 @@
+
+
+
+ 课程名称
+ 技术体系
+ 等级体系
+ 封面
+ 创建者
+ 单位
+ 状态
+ 操作
+
+
+
+ <% if laboratory_subjects.present? %>
+ <% laboratory_subjects.each do |laboratory_subject| %>
+
+ <%- subject = laboratory_subject.subject -%>
+
+
+ <%= link_to(subject.name, "/paths/#{subject.id}", target: '_blank') %>
+ 首页
+ 自建
+
+ <%= display_text subject.repertoire&.name %>
+ <%= display_text subject.subject_level_system&.name %>
+
+ <% image_exists = Util::FileManage.exists?(subject) %>
+ <%= image_tag(image_exists ? Util::FileManage.source_disk_file_url(subject) : '', height: 40, class: "w-100 preview-image subject-image-#{subject.id}", style: image_exists ? '' : 'display:none') %>
+
+ <%= subject.user.real_name %>
+ <%= subject.user.school_name %>
+ <%= display_subject_status(subject) %>
+
+
+ <%= link_to('去修改', admins_subjects_path(id: laboratory_subject.subject_id)) %>
+ <%= javascript_void_link('首页展示', class: 'action homepage-show-action', data: { id: laboratory_subject.id }, style: laboratory_subject.homepage? ? 'display:none' : '') %>
+ <%= javascript_void_link('取消首页展示', class: 'action homepage-hide-action', data: { id: laboratory_subject.id }, style: laboratory_subject.homepage? ? '' : 'display:none') %>
+
+ <% unless laboratory_subject.ownership? %>
+ <%= delete_link '删除', admins_laboratory_laboratory_subject_path(current_laboratory, laboratory_subject, element: ".laboratory-subject-item-#{laboratory_subject.id}") %>
+ <% end %>
+
+
+ <% end %>
+ <% else %>
+ <%= render 'admins/shared/no_data_for_table' %>
+ <% end %>
+
+
+
+<%= render partial: 'admins/shared/paginate', locals: { objects: laboratory_subjects } %>
\ No newline at end of file
diff --git a/app/views/admins/library_applies/index.html.erb b/app/views/admins/library_applies/index.html.erb
index 55a7e9e09..9d2ae8e66 100644
--- a/app/views/admins/library_applies/index.html.erb
+++ b/app/views/admins/library_applies/index.html.erb
@@ -25,7 +25,7 @@
<% end %>
-
+
<%= render(partial: 'admins/library_applies/shared/list', locals: { applies: @library_applies }) %>
diff --git a/app/views/admins/major_informations/index.html.erb b/app/views/admins/major_informations/index.html.erb
index 41570ec06..6af1d7091 100644
--- a/app/views/admins/major_informations/index.html.erb
+++ b/app/views/admins/major_informations/index.html.erb
@@ -2,6 +2,6 @@
<% add_admin_breadcrumb('本科专业目录') %>
<% end %>
-
<% end %>
-
+
<%= render partial: 'admins/mirror_repositories/shared/list', locals: { mirrors: @mirrors } %>
diff --git a/app/views/admins/mirror_scripts/index.html.erb b/app/views/admins/mirror_scripts/index.html.erb
index f4fa398af..6a113a0ef 100644
--- a/app/views/admins/mirror_scripts/index.html.erb
+++ b/app/views/admins/mirror_scripts/index.html.erb
@@ -9,6 +9,6 @@
<%= link_to '新建', new_admins_mirror_repository_mirror_script_path(current_mirror), class: 'btn btn-primary' %>
-
+
<%= render partial: 'admins/mirror_scripts/shared/list', locals: { mirror: current_mirror, scripts: @scripts } %>
diff --git a/app/views/admins/myshixuns/index.html.erb b/app/views/admins/myshixuns/index.html.erb
index 311c1003f..0b34102c6 100644
--- a/app/views/admins/myshixuns/index.html.erb
+++ b/app/views/admins/myshixuns/index.html.erb
@@ -9,6 +9,6 @@
<% end %>
-
+
<%= render(partial: 'admins/myshixuns/shared/list', locals: { myshixuns: @myshixuns, finish_game_count: @finish_game_count, total_score: @total_score }) %>
\ No newline at end of file
diff --git a/app/views/admins/myshixuns/shared/_list.html.erb b/app/views/admins/myshixuns/shared/_list.html.erb
index 89ad535c5..440437320 100644
--- a/app/views/admins/myshixuns/shared/_list.html.erb
+++ b/app/views/admins/myshixuns/shared/_list.html.erb
@@ -20,7 +20,7 @@
<%= myshixun.identifier %>
<% current_task = myshixun.last_executable_task || myshixun.last_task %>
- <%= link_to "/myshixuns/#{myshixun.identifier}/stages/#{current_task.identifier}", target: '_blank' do %>
+ <%= link_to "/tasks/#{current_task.identifier}", target: '_blank' do %>
<%= overflow_hidden_span myshixun.shixun.name, width: 280 %>
<% end %>
diff --git a/app/views/admins/partners/index.html.erb b/app/views/admins/partners/index.html.erb
new file mode 100644
index 000000000..15f27669a
--- /dev/null
+++ b/app/views/admins/partners/index.html.erb
@@ -0,0 +1,18 @@
+<% define_admin_breadcrumbs do %>
+ <% add_admin_breadcrumb('合作伙伴') %>
+<% end %>
+
+
+ <%= form_tag(admins_partners_path, method: :get, class: 'form-inline search-form', remote: true) do %>
+ <%= text_field_tag(:keyword, params[:keyword], class: 'form-control col-md-4 ml-3', placeholder: '合作伙伴名称检索') %>
+ <%= submit_tag('搜索', class: 'btn btn-primary ml-3', 'data-disable-with': '搜索中...') %>
+ <% end %>
+
+ <%= javascript_void_link('添加', class: 'btn btn-primary', data: { toggle: 'modal', target: '.admin-select-school-modal' }) %>
+
+
+
+ <%= render 'admins/partners/shared/list', partners: @partners %>
+
+
+<%= render partial: 'admins/shared/modal/select_school_modal', locals: { title: '添加客户', multiple: true, url: admins_partners_path } %>
\ No newline at end of file
diff --git a/app/views/admins/partners/index.js.erb b/app/views/admins/partners/index.js.erb
new file mode 100644
index 000000000..6b1d0ec58
--- /dev/null
+++ b/app/views/admins/partners/index.js.erb
@@ -0,0 +1 @@
+$('.partner-list-container').html("<%= j(render partial: 'admins/partners/shared/list', locals: { partners: @partners }) %>");
\ No newline at end of file
diff --git a/app/views/admins/partners/shared/_list.html.erb b/app/views/admins/partners/shared/_list.html.erb
new file mode 100644
index 000000000..0bebc2a4b
--- /dev/null
+++ b/app/views/admins/partners/shared/_list.html.erb
@@ -0,0 +1,29 @@
+
+
+
+ 名称
+ <%= sort_tag('添加时间', name: 'created_at', path: admins_partners_path) %>
+ 操作
+
+
+
+ <% if partners.present? %>
+ <% partners.each do |partner| %>
+
+
+ <%= link_to partner.school&.name || partner.name, customers_partner_path(partner), target: '_blank' %>
+
+ <%= partner.created_at&.strftime('%Y-%m-%d %H:%M') %>
+
+ <%= link_to '查看', admins_partner_customers_path(partner), class: 'action' %>
+ <%= delete_link '删除', admins_partner_path(partner, element: ".partner-item-#{partner.id}"), class: 'delete-partner-action' %>
+
+
+ <% end %>
+ <% else %>
+ <%= render 'admins/shared/no_data_for_table' %>
+ <% end %>
+
+
+
+<%= render partial: 'admins/shared/paginate', locals: { objects: partners } %>
\ No newline at end of file
diff --git a/app/views/admins/professional_authentications/index.html.erb b/app/views/admins/professional_authentications/index.html.erb
index 436fc731f..08022567b 100644
--- a/app/views/admins/professional_authentications/index.html.erb
+++ b/app/views/admins/professional_authentications/index.html.erb
@@ -29,7 +29,7 @@
<%= javascript_void_link '批量同意', class: 'btn btn-outline-primary btn-sm batch-agree-btn' %>
-
+
<%= render(partial: 'admins/professional_authentications/shared/list', locals: { applies: @applies }) %>
diff --git a/app/views/admins/professional_authentications/shared/_list.html.erb b/app/views/admins/professional_authentications/shared/_list.html.erb
index 79cf31aad..6ec6355ba 100644
--- a/app/views/admins/professional_authentications/shared/_list.html.erb
+++ b/app/views/admins/professional_authentications/shared/_list.html.erb
@@ -41,6 +41,9 @@
<%= link_to "/users/#{user.login}", class: 'professional-authentication-avatar', target: '_blank', data: { toggle: 'tooltip', title: '个人主页' } do %>
<% end %>
+ <% if user.from_sub_site? %>
+
合作
+ <% end %>
<%= user.real_name %>
<%= raw [user.school_name.presence, user.department_name.presence].compact.join(' ') %>
@@ -48,8 +51,8 @@
<% unless is_processed %>
- <% if File.exists?(disk_professional_auth_filename(user.id)) %>
- <%= image_tag(professional_auth_file_url(user.id).to_s + "?#{Time.now.to_i}", width: 40, height: 40, class: 'preview-image auth-image', data: { toggle: 'tooltip', title: '点击预览' }) %>
+ <% if apply.attachment %>
+ <%= image_tag("/api/attachments/#{apply.attachment.id}", width: 40, height: 40, class: 'preview-image auth-image', data: { toggle: 'tooltip', title: '点击预览' }) %>
<% else %>
<%= content_tag(:span, '图片已删除', class: 'text-secondary') %>
<% end %>
diff --git a/app/views/admins/project_package_applies/index.html.erb b/app/views/admins/project_package_applies/index.html.erb
index 912ea3e59..aba0c88f4 100644
--- a/app/views/admins/project_package_applies/index.html.erb
+++ b/app/views/admins/project_package_applies/index.html.erb
@@ -25,7 +25,7 @@
<% end %>
-
+
<%= render(partial: 'admins/project_package_applies/shared/list', locals: { applies: @package_applies}) %>
diff --git a/app/views/admins/school_statistics/index.html.erb b/app/views/admins/school_statistics/index.html.erb
index 0453dfffa..d726adb22 100644
--- a/app/views/admins/school_statistics/index.html.erb
+++ b/app/views/admins/school_statistics/index.html.erb
@@ -44,6 +44,6 @@
-
+
<%= render partial: 'admins/school_statistics/shared/list', locals: { statistics: @statistics } %>
\ No newline at end of file
diff --git a/app/views/admins/schools/index.html.erb b/app/views/admins/schools/index.html.erb
index 0dd5b0bc5..9c41067ee 100644
--- a/app/views/admins/schools/index.html.erb
+++ b/app/views/admins/schools/index.html.erb
@@ -11,6 +11,6 @@
<%#= javascript_void_link '新建单位', class: 'btn btn-primary', data: { toggle: 'modal', target: '.admin-create-school-modal' } %>
-
+
<%= render partial: 'admins/schools/shared/list', locals: { schools: @schools } %>
\ No newline at end of file
diff --git a/app/views/admins/shared/_sidebar.html.erb b/app/views/admins/shared/_sidebar.html.erb
index 39adde303..f78b52ac7 100644
--- a/app/views/admins/shared/_sidebar.html.erb
+++ b/app/views/admins/shared/_sidebar.html.erb
@@ -1,10 +1,10 @@
<% sidebar_collapse = request.cookies['admin_sidebar_collapse'].to_s == 'true' %>