+ <%= list_index_no(@params_page.to_i, index) %> |
<%= link_to statistic[:name], "/colleges/#{statistic[:id]}/statistics",
target: '_blank', data: { toggle: 'tooltip', title: '点击查看学校统计概况' } %>
diff --git a/app/views/admins/school_statistics/shared/_list.html.erb b/app/views/admins/school_statistics/shared/_list.html.erb
index aa043f097..9d2a1c209 100644
--- a/app/views/admins/school_statistics/shared/_list.html.erb
+++ b/app/views/admins/school_statistics/shared/_list.html.erb
@@ -20,7 +20,8 @@
- 单位名称 |
+ 序号 |
+ 单位名称 |
<%= sort_tag('新增教师', name: 'teacher_increase_count', path: admins_school_statistics_path) %> |
<%= sort_tag('新增学生', name: 'student_increase_count', path: admins_school_statistics_path) %> |
<%= sort_tag('新增课堂', name: 'course_increase_count', path: admins_school_statistics_path) %> |
@@ -32,8 +33,9 @@
<% if statistics.present? %>
- <% statistics.each do |statistic| %>
+ <% statistics.each_with_index do |statistic, index| %>
+ <%= list_index_no(@params_page.to_i, index) %> |
<%= link_to statistic.school_name, "/colleges/#{statistic.school_id}/statistics",
target: '_blank', data: { toggle: 'tooltip', title: '点击查看学校统计概况' } %>
diff --git a/app/views/admins/shixun_settings/shared/_list.html.erb b/app/views/admins/shixun_settings/shared/_list.html.erb
index 7591fe323..aee4307b1 100644
--- a/app/views/admins/shixun_settings/shared/_list.html.erb
+++ b/app/views/admins/shixun_settings/shared/_list.html.erb
@@ -1,12 +1,13 @@
- ID |
+ 序号 |
+ ID |
实训名称 |
技术平台 |
权限 |
- 技术体系 |
- 上传图片 |
- 小程序封面 |
+ 技术体系 |
+ 上传图片 |
+ 小程序封面 |
创建者 |
关闭 |
复制 |
diff --git a/app/views/admins/shixun_settings/shared/_td.html.erb b/app/views/admins/shixun_settings/shared/_td.html.erb
index f4a05f178..905183873 100644
--- a/app/views/admins/shixun_settings/shared/_td.html.erb
+++ b/app/views/admins/shixun_settings/shared/_td.html.erb
@@ -1,3 +1,4 @@
+<%= page_no %> |
<%= shixun.identifier %> |
diff --git a/app/views/hack_user_lastest_codes/record_detail.json.jbuilder b/app/views/hack_user_lastest_codes/record_detail.json.jbuilder
index 4b77c2e00..8f72014fe 100644
--- a/app/views/hack_user_lastest_codes/record_detail.json.jbuilder
+++ b/app/views/hack_user_lastest_codes/record_detail.json.jbuilder
@@ -1,4 +1,8 @@
json.(@hack_user, :id, :status, :error_line, :error_msg, :expected_output,
:input, :output, :execute_time, :execute_memory, :created_at, :code)
json.language @hack_user.hack.language
-json.name @hack_user.hack.name
\ No newline at end of file
+json.name @hack_user.hack.name
+json.myproblem_identifier @my_hack.identifier
+json.user do
+ json.partial! 'users/user', user: current_user
+end
\ No newline at end of file
diff --git a/db/migrate/20191209111347_add_index_for_hack_codes.rb b/db/migrate/20191209111347_add_index_for_hack_codes.rb
new file mode 100644
index 000000000..f1e655e21
--- /dev/null
+++ b/db/migrate/20191209111347_add_index_for_hack_codes.rb
@@ -0,0 +1,6 @@
+class AddIndexForHackCodes < ActiveRecord::Migration[5.2]
+ def change
+ HackCode.destroy_all
+ add_index :hack_codes, [:hack_id, :language], unique: true
+ end
+end
diff --git a/public/images/educoder/index/shixun/shixun24.jpg b/public/images/educoder/index/shixun/shixun24.jpg
deleted file mode 100644
index 51d97e719..000000000
Binary files a/public/images/educoder/index/shixun/shixun24.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun25.jpg b/public/images/educoder/index/shixun/shixun25.jpg
deleted file mode 100644
index ceb1ff60a..000000000
Binary files a/public/images/educoder/index/shixun/shixun25.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun26.jpg b/public/images/educoder/index/shixun/shixun26.jpg
deleted file mode 100644
index 6180626a4..000000000
Binary files a/public/images/educoder/index/shixun/shixun26.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun27.jpg b/public/images/educoder/index/shixun/shixun27.jpg
deleted file mode 100644
index a998669c6..000000000
Binary files a/public/images/educoder/index/shixun/shixun27.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun28.jpg b/public/images/educoder/index/shixun/shixun28.jpg
deleted file mode 100644
index 8b9422b87..000000000
Binary files a/public/images/educoder/index/shixun/shixun28.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun29.jpg b/public/images/educoder/index/shixun/shixun29.jpg
deleted file mode 100644
index e9cda9129..000000000
Binary files a/public/images/educoder/index/shixun/shixun29.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun30.jpg b/public/images/educoder/index/shixun/shixun30.jpg
deleted file mode 100644
index df4df88a0..000000000
Binary files a/public/images/educoder/index/shixun/shixun30.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun31.jpg b/public/images/educoder/index/shixun/shixun31.jpg
deleted file mode 100644
index 131afcac2..000000000
Binary files a/public/images/educoder/index/shixun/shixun31.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun31.jpg~HEAD b/public/images/educoder/index/shixun/shixun31.jpg~HEAD
deleted file mode 100644
index 5d4218a45..000000000
Binary files a/public/images/educoder/index/shixun/shixun31.jpg~HEAD and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun32.jpg b/public/images/educoder/index/shixun/shixun32.jpg
deleted file mode 100644
index bb4fb7d31..000000000
Binary files a/public/images/educoder/index/shixun/shixun32.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun33.jpg b/public/images/educoder/index/shixun/shixun33.jpg
deleted file mode 100644
index b851ac0fc..000000000
Binary files a/public/images/educoder/index/shixun/shixun33.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun34.jpg b/public/images/educoder/index/shixun/shixun34.jpg
deleted file mode 100644
index 6eadbbe35..000000000
Binary files a/public/images/educoder/index/shixun/shixun34.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun35.jpg b/public/images/educoder/index/shixun/shixun35.jpg
deleted file mode 100644
index 87f8276ca..000000000
Binary files a/public/images/educoder/index/shixun/shixun35.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun36.jpg b/public/images/educoder/index/shixun/shixun36.jpg
deleted file mode 100644
index 149841c9a..000000000
Binary files a/public/images/educoder/index/shixun/shixun36.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun37.jpg b/public/images/educoder/index/shixun/shixun37.jpg
deleted file mode 100644
index 0ad960534..000000000
Binary files a/public/images/educoder/index/shixun/shixun37.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun38.jpg b/public/images/educoder/index/shixun/shixun38.jpg
deleted file mode 100644
index e1e64007e..000000000
Binary files a/public/images/educoder/index/shixun/shixun38.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun39.jpg b/public/images/educoder/index/shixun/shixun39.jpg
deleted file mode 100644
index 07a00b3a6..000000000
Binary files a/public/images/educoder/index/shixun/shixun39.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun40.jpg b/public/images/educoder/index/shixun/shixun40.jpg
deleted file mode 100644
index d4bf2fadf..000000000
Binary files a/public/images/educoder/index/shixun/shixun40.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun41.jpg b/public/images/educoder/index/shixun/shixun41.jpg
deleted file mode 100644
index c7a03198a..000000000
Binary files a/public/images/educoder/index/shixun/shixun41.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun42.jpg b/public/images/educoder/index/shixun/shixun42.jpg
deleted file mode 100644
index cbccb88c6..000000000
Binary files a/public/images/educoder/index/shixun/shixun42.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun43.jpg b/public/images/educoder/index/shixun/shixun43.jpg
deleted file mode 100644
index e3e3a41e2..000000000
Binary files a/public/images/educoder/index/shixun/shixun43.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun44.jpg b/public/images/educoder/index/shixun/shixun44.jpg
deleted file mode 100644
index 80e8b193a..000000000
Binary files a/public/images/educoder/index/shixun/shixun44.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun45.jpg b/public/images/educoder/index/shixun/shixun45.jpg
deleted file mode 100644
index d032aed71..000000000
Binary files a/public/images/educoder/index/shixun/shixun45.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun46.jpg b/public/images/educoder/index/shixun/shixun46.jpg
deleted file mode 100644
index 84b7cf6e0..000000000
Binary files a/public/images/educoder/index/shixun/shixun46.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun47.jpg b/public/images/educoder/index/shixun/shixun47.jpg
deleted file mode 100644
index cb99dc95d..000000000
Binary files a/public/images/educoder/index/shixun/shixun47.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun48.jpg b/public/images/educoder/index/shixun/shixun48.jpg
deleted file mode 100644
index c619abfa6..000000000
Binary files a/public/images/educoder/index/shixun/shixun48.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun49.jpg b/public/images/educoder/index/shixun/shixun49.jpg
deleted file mode 100644
index 398dfa1e1..000000000
Binary files a/public/images/educoder/index/shixun/shixun49.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun50.jpg b/public/images/educoder/index/shixun/shixun50.jpg
deleted file mode 100644
index 6a3a61dfd..000000000
Binary files a/public/images/educoder/index/shixun/shixun50.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun51.jpg b/public/images/educoder/index/shixun/shixun51.jpg
deleted file mode 100644
index 29262fba7..000000000
Binary files a/public/images/educoder/index/shixun/shixun51.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun52.jpg b/public/images/educoder/index/shixun/shixun52.jpg
deleted file mode 100644
index 766d7afd8..000000000
Binary files a/public/images/educoder/index/shixun/shixun52.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun53.jpg b/public/images/educoder/index/shixun/shixun53.jpg
deleted file mode 100644
index db81f7cff..000000000
Binary files a/public/images/educoder/index/shixun/shixun53.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun54.jpg b/public/images/educoder/index/shixun/shixun54.jpg
deleted file mode 100644
index e47fb239c..000000000
Binary files a/public/images/educoder/index/shixun/shixun54.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun55.jpg b/public/images/educoder/index/shixun/shixun55.jpg
deleted file mode 100644
index 556e59b33..000000000
Binary files a/public/images/educoder/index/shixun/shixun55.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun56.jpg b/public/images/educoder/index/shixun/shixun56.jpg
deleted file mode 100644
index 0048c81a5..000000000
Binary files a/public/images/educoder/index/shixun/shixun56.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun57.jpg b/public/images/educoder/index/shixun/shixun57.jpg
deleted file mode 100644
index caf3ad104..000000000
Binary files a/public/images/educoder/index/shixun/shixun57.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun58.jpg b/public/images/educoder/index/shixun/shixun58.jpg
deleted file mode 100644
index 610199dc5..000000000
Binary files a/public/images/educoder/index/shixun/shixun58.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun59.jpg b/public/images/educoder/index/shixun/shixun59.jpg
deleted file mode 100644
index 973cba886..000000000
Binary files a/public/images/educoder/index/shixun/shixun59.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun60.jpg b/public/images/educoder/index/shixun/shixun60.jpg
deleted file mode 100644
index 9d13e9c61..000000000
Binary files a/public/images/educoder/index/shixun/shixun60.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun61.jpg b/public/images/educoder/index/shixun/shixun61.jpg
deleted file mode 100644
index 54e283cd9..000000000
Binary files a/public/images/educoder/index/shixun/shixun61.jpg and /dev/null differ
diff --git a/public/images/educoder/index/shixun/shixun62.jpg b/public/images/educoder/index/shixun/shixun62.jpg
deleted file mode 100644
index 079c83926..000000000
Binary files a/public/images/educoder/index/shixun/shixun62.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject18.jpg b/public/images/educoder/index/subject/subject18.jpg
deleted file mode 100644
index 5bcdd8e21..000000000
Binary files a/public/images/educoder/index/subject/subject18.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject19.jpg b/public/images/educoder/index/subject/subject19.jpg
deleted file mode 100644
index 0c82077d2..000000000
Binary files a/public/images/educoder/index/subject/subject19.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject20.jpg b/public/images/educoder/index/subject/subject20.jpg
deleted file mode 100644
index 25c3896e0..000000000
Binary files a/public/images/educoder/index/subject/subject20.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject21.jpg b/public/images/educoder/index/subject/subject21.jpg
deleted file mode 100644
index ebe3df86d..000000000
Binary files a/public/images/educoder/index/subject/subject21.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject22.jpg b/public/images/educoder/index/subject/subject22.jpg
deleted file mode 100644
index b06cca4ab..000000000
Binary files a/public/images/educoder/index/subject/subject22.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject23.jpg b/public/images/educoder/index/subject/subject23.jpg
deleted file mode 100644
index bd6ea450c..000000000
Binary files a/public/images/educoder/index/subject/subject23.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject24.jpg b/public/images/educoder/index/subject/subject24.jpg
deleted file mode 100644
index e6fbb0ab0..000000000
Binary files a/public/images/educoder/index/subject/subject24.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject25.jpg b/public/images/educoder/index/subject/subject25.jpg
deleted file mode 100644
index bedeea999..000000000
Binary files a/public/images/educoder/index/subject/subject25.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject26.jpg b/public/images/educoder/index/subject/subject26.jpg
deleted file mode 100644
index 3c8040901..000000000
Binary files a/public/images/educoder/index/subject/subject26.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject27.jpg b/public/images/educoder/index/subject/subject27.jpg
deleted file mode 100644
index 59410bd62..000000000
Binary files a/public/images/educoder/index/subject/subject27.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject28.jpg b/public/images/educoder/index/subject/subject28.jpg
deleted file mode 100644
index 4799d28d8..000000000
Binary files a/public/images/educoder/index/subject/subject28.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject29.jpg b/public/images/educoder/index/subject/subject29.jpg
deleted file mode 100644
index 451053cf7..000000000
Binary files a/public/images/educoder/index/subject/subject29.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject30.jpg b/public/images/educoder/index/subject/subject30.jpg
deleted file mode 100644
index 2abd5a860..000000000
Binary files a/public/images/educoder/index/subject/subject30.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject31.jpg b/public/images/educoder/index/subject/subject31.jpg
deleted file mode 100644
index f84e0587a..000000000
Binary files a/public/images/educoder/index/subject/subject31.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject32.jpg b/public/images/educoder/index/subject/subject32.jpg
deleted file mode 100644
index 7ab3f038e..000000000
Binary files a/public/images/educoder/index/subject/subject32.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject33.jpg b/public/images/educoder/index/subject/subject33.jpg
deleted file mode 100644
index c3f1e57db..000000000
Binary files a/public/images/educoder/index/subject/subject33.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject34.jpg b/public/images/educoder/index/subject/subject34.jpg
deleted file mode 100644
index b5f4cb5f7..000000000
Binary files a/public/images/educoder/index/subject/subject34.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject35.jpg b/public/images/educoder/index/subject/subject35.jpg
deleted file mode 100644
index 6a9156340..000000000
Binary files a/public/images/educoder/index/subject/subject35.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject36.jpg b/public/images/educoder/index/subject/subject36.jpg
deleted file mode 100644
index f7c8757cc..000000000
Binary files a/public/images/educoder/index/subject/subject36.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject37.jpg b/public/images/educoder/index/subject/subject37.jpg
deleted file mode 100644
index b8b815f8b..000000000
Binary files a/public/images/educoder/index/subject/subject37.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject38.jpg b/public/images/educoder/index/subject/subject38.jpg
deleted file mode 100644
index 286a1e356..000000000
Binary files a/public/images/educoder/index/subject/subject38.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject39.jpg b/public/images/educoder/index/subject/subject39.jpg
deleted file mode 100644
index e901842c4..000000000
Binary files a/public/images/educoder/index/subject/subject39.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject4-o.jpg b/public/images/educoder/index/subject/subject4-o.jpg
deleted file mode 100644
index 7c6784cf1..000000000
Binary files a/public/images/educoder/index/subject/subject4-o.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject40.jpg b/public/images/educoder/index/subject/subject40.jpg
deleted file mode 100644
index ac5f581fd..000000000
Binary files a/public/images/educoder/index/subject/subject40.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject41.jpg b/public/images/educoder/index/subject/subject41.jpg
deleted file mode 100644
index f968870f0..000000000
Binary files a/public/images/educoder/index/subject/subject41.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject42.jpg b/public/images/educoder/index/subject/subject42.jpg
deleted file mode 100644
index b3251b7e4..000000000
Binary files a/public/images/educoder/index/subject/subject42.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject43.jpg b/public/images/educoder/index/subject/subject43.jpg
deleted file mode 100644
index 0dd42efaa..000000000
Binary files a/public/images/educoder/index/subject/subject43.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject44.jpg b/public/images/educoder/index/subject/subject44.jpg
deleted file mode 100644
index 21214a7d1..000000000
Binary files a/public/images/educoder/index/subject/subject44.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject45.jpg b/public/images/educoder/index/subject/subject45.jpg
deleted file mode 100644
index bd27e6ba0..000000000
Binary files a/public/images/educoder/index/subject/subject45.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject46.jpg b/public/images/educoder/index/subject/subject46.jpg
deleted file mode 100644
index 3d621652b..000000000
Binary files a/public/images/educoder/index/subject/subject46.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject47.jpg b/public/images/educoder/index/subject/subject47.jpg
deleted file mode 100644
index fcd318623..000000000
Binary files a/public/images/educoder/index/subject/subject47.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject48.jpg b/public/images/educoder/index/subject/subject48.jpg
deleted file mode 100644
index e7ee65970..000000000
Binary files a/public/images/educoder/index/subject/subject48.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject49.jpg b/public/images/educoder/index/subject/subject49.jpg
deleted file mode 100644
index 5adf9e274..000000000
Binary files a/public/images/educoder/index/subject/subject49.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject50.jpg b/public/images/educoder/index/subject/subject50.jpg
deleted file mode 100644
index 46ee0208c..000000000
Binary files a/public/images/educoder/index/subject/subject50.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject51.jpg b/public/images/educoder/index/subject/subject51.jpg
deleted file mode 100644
index 4c52ae48e..000000000
Binary files a/public/images/educoder/index/subject/subject51.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject52.jpg b/public/images/educoder/index/subject/subject52.jpg
deleted file mode 100644
index f959d9ed7..000000000
Binary files a/public/images/educoder/index/subject/subject52.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject53.jpg b/public/images/educoder/index/subject/subject53.jpg
deleted file mode 100644
index 3516fad82..000000000
Binary files a/public/images/educoder/index/subject/subject53.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject54.jpg b/public/images/educoder/index/subject/subject54.jpg
deleted file mode 100644
index d717562e7..000000000
Binary files a/public/images/educoder/index/subject/subject54.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject55.jpg b/public/images/educoder/index/subject/subject55.jpg
deleted file mode 100644
index 2cc6c0173..000000000
Binary files a/public/images/educoder/index/subject/subject55.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject56.jpg b/public/images/educoder/index/subject/subject56.jpg
deleted file mode 100644
index 2125dc132..000000000
Binary files a/public/images/educoder/index/subject/subject56.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject57.jpg b/public/images/educoder/index/subject/subject57.jpg
deleted file mode 100644
index eecf5b1c2..000000000
Binary files a/public/images/educoder/index/subject/subject57.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject58.jpg b/public/images/educoder/index/subject/subject58.jpg
deleted file mode 100644
index 89d26b0b0..000000000
Binary files a/public/images/educoder/index/subject/subject58.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject6-o.jpg b/public/images/educoder/index/subject/subject6-o.jpg
deleted file mode 100644
index f7cda83f2..000000000
Binary files a/public/images/educoder/index/subject/subject6-o.jpg and /dev/null differ
diff --git a/public/images/educoder/index/subject/subject8-o.jpg b/public/images/educoder/index/subject/subject8-o.jpg
deleted file mode 100644
index fbeebe4ee..000000000
Binary files a/public/images/educoder/index/subject/subject8-o.jpg and /dev/null differ
diff --git a/public/react/src/modules/courses/coursesPublic/SelectResource.js b/public/react/src/modules/courses/coursesPublic/SelectResource.js
index 31c6d2f52..e2454652b 100644
--- a/public/react/src/modules/courses/coursesPublic/SelectResource.js
+++ b/public/react/src/modules/courses/coursesPublic/SelectResource.js
@@ -42,12 +42,7 @@ class Selectresource extends Component{
getallfiles:false,
searchtype:'getallfiles',
Radiovalue:0,
- datatime:undefined,
- course_group_publish_times:[
- {
- group_id : [],
- publish_time :undefined,
- }],
+ datatime:undefined
}
}
componentDidMount() {
@@ -79,7 +74,7 @@ class Selectresource extends Component{
}
SenttotheSearch=(value)=>{
- let {searchtype}=this.state;
+ let {searchtype}=this.state;
if(searchtype==="getallfiles"){
this.getallfiles(value,1)
}else if(searchtype==="getmyfiles"){
@@ -91,32 +86,32 @@ class Selectresource extends Component{
setupdatalist=(url,newpage)=>{
let {Resourcelist,Searchvalue}=this.state;
if(Resourcelist!=undefined){
- let newResourcelist=Resourcelist.files;
- axios.get(url,{
- params:{
- page:newpage,
- page_size:15,
- search:Searchvalue,
- }
- }).then((result)=>{
+ let newResourcelist=Resourcelist.files;
+ axios.get(url,{
+ params:{
+ page:newpage,
+ page_size:15,
+ search:Searchvalue,
+ }
+ }).then((result)=>{
- var list=result.data.data.files;
+ var list=result.data.data.files;
for(var i=0;i{
- console.log(error)
- })
+ }).catch((error)=>{
+ console.log(error)
+ })
}
}
contentViewScroll=(e)=>{
@@ -152,7 +147,7 @@ class Selectresource extends Component{
// this.props.funshixunmodallist(Searchvalue,types,true,1)
// this.props.funpatheditarry([])
if(types==="all"){
- this.getallfiles(undefined,1)
+ this.getallfiles(undefined,1)
}else if(types==="my"){
this.getmyfiles(undefined,1)
}
@@ -168,12 +163,12 @@ class Selectresource extends Component{
search:value,
}
}).then((result)=>{
- this.setState({
- Resourcelist:result.data.data,
- hometypepvisible:false,
- getallfiles:true,
- searchtype:'getallfiles'
- })
+ this.setState({
+ Resourcelist:result.data.data,
+ hometypepvisible:false,
+ getallfiles:true,
+ searchtype:'getallfiles'
+ })
}).catch((error)=>{
console.log(error)
})
@@ -189,11 +184,11 @@ class Selectresource extends Component{
search:value,
}
}).then((result)=>{
- this.setState({
- Resourcelist: result.data.data,
- hometypepvisible:false,
- searchtype:'getmyfiles'
- })
+ this.setState({
+ Resourcelist: result.data.data,
+ hometypepvisible:false,
+ searchtype:'getmyfiles'
+ })
}).catch((error)=>{
console.log(error)
})
@@ -201,7 +196,7 @@ class Selectresource extends Component{
hidecouseShixunModal=()=>{
- this.props.hidecouseShixunModal()
+ this.props.hidecouseShixunModal()
}
ModalCancelModalCancel=()=>{
@@ -217,22 +212,22 @@ class Selectresource extends Component{
savecouseShixunModal=()=>{
- let {patheditarry,datatime,Radiovalue,course_group_publish_times}=this.state;
+ let {patheditarry,datatime,Radiovalue}=this.state;
let {coursesId,attachmentId}=this.props;
- let url="/files/import.json";
-
- if(patheditarry===undefined||patheditarry.length===0){
- this.setState({
- patheditarrytype:true
- })
- return
- }else{
- this.setState({
- patheditarrytype:false
- })
- }
-
- if(this.state.Radiovalue===1&&this.props.course_groups.length===0){
+ let url="/files/import.json";
+
+ if(patheditarry===undefined||patheditarry.length===0){
+ this.setState({
+ patheditarrytype:true
+ })
+ return
+ }else{
+ this.setState({
+ patheditarrytype:false
+ })
+ }
+
+ if(this.state.Radiovalue===1){
if(datatime===undefined||datatime===null||datatime=== ""){
this.setState({
Radiovaluetype:true
@@ -249,17 +244,16 @@ class Selectresource extends Component{
course_id:coursesId,
attachment_ids:patheditarry,
course_second_category_id:this.props.coursesidtype===undefined||this.props.coursesidtype==="node"?0:attachmentId,
- delay_publish:Radiovalue,
- publish_time:this.props.course_groups.length===0?Radiovalue===1?datatime===undefined? undefined:datatime:undefined:undefined,
- group_settings:this.props.course_groups.length===0?undefined:course_group_publish_times
+ delay_publish:Radiovalue,
+ publish_time:Radiovalue===1?datatime:undefined
}
).then((response) => {
- if(response.data.status===0){
- this.ModalCancelModalCancel();
- this.props.updataleftNavfun();
- this.props.showNotification("选用资源成功");
- this.props.setupdate(attachmentId)
- }
+ if(response.data.status===0){
+ this.ModalCancelModalCancel();
+ this.props.updataleftNavfun();
+ this.props.showNotification("选用资源成功");
+ this.props.setupdate(attachmentId)
+ }
}).catch((error) => {
console.log(error)
})
@@ -277,58 +271,15 @@ class Selectresource extends Component{
});
}
- onChangeTimepublish= (date, dateString,key,type) => {
- if(type===1){
- this.setState({
- datatime:handleDateString(dateString),
- })
- }else if(type===2){
- let {course_group_publish_times}=this.state;
- let newgroup_publish=course_group_publish_times;
- for(var i=0; i {
- addgrouppublish=()=>{
- let newlist=this.state.course_group_publish_times;
- newlist.push( {
- group_id : undefined,
- publish_time :undefined,
- })
- this.setState({
- course_group_publish_times:newlist
- })
- }
- deletegrouppublish=(key)=>{
- let newlist=this.state.course_group_publish_times;
- newlist.splice(key,1);
this.setState({
- course_group_publish_times:newlist
+ datatime:handleDateString(dateString),
})
- }
- selectassigngroups=(e,index,key)=>{
- debugger
- let {course_group_publish_times}=this.state;
- let newgroup_publish=course_group_publish_times;
- for(var i=0; i;
const radioStyle = {
@@ -336,8 +287,6 @@ class Selectresource extends Component{
height: '30px',
lineHeight: '30px',
};
-
- console.log(course_group_publish_times)
return(
{/*提示*/}
@@ -350,73 +299,73 @@ class Selectresource extends Component{
/>
{visible===true?
-
-
+ }
+
-
-
-
-
- this.changeTag("all")} className={ type==="all" ? "active edu-filter-cir-grey font-12":"edu-filter-cir-grey font-12"}>全部
- this.changeTag("my")} className={ type==="my" ? " active edu-filter-cir-grey font-12":"edu-filter-cir-grey font-12"}>我的资源
-
- this.SenttotheSearch(value)}
- style={{width: '100%'}}
- />
+
-
-
+
-
-
-
- {
- Resourcelist === undefined ?"":Resourcelist.files.length===0? :
-
-
- {
- Resourcelist.files.map((item,key)=>{
- return(
-
-
-
-
-
-
- {item.filesize}
- {item.author.name}
- {formatDate(item.created_on)}
-
- )
- })
- }
-
-
- }
-
+
-
- 发布设置:
-
-
- 立即发布
-
-
-
- 延期发布
- {this.props.course_groups.length>0?"":this.onChangeTimepublish(e,index,undefined,1)}
- disabledTime={disabledDateTime}
- disabledDate={disabledDate}
- disabled={this.state.Radiovalue===1?false:true}
- />}
-
-
- (按照设置的时间定时发布)
-
-
-
- {this.props.course_groups.length>0?this.props.isStudent()===true?"":
- {this.state.Radiovalue===1?:""}
{
- course_group_publish_times.map((item,key)=>{
- return(
-
-
-
- this.onChangeTimepublish(e,index,key,2)}
- // onChange={ this.onChangeTimepublish }
- disabledTime={disabledDateTime}
- disabledDate={disabledDate}
- />
- {key!=0?this.deletegrouppublish(key)}>:""}
- {key+1===this.props.course_groups.length?"":}
-
- )
- })
+ Resourcelist === undefined ?"":Resourcelist.files.length===0? :
+
+
+ {
+ Resourcelist.files.map((item,key)=>{
+ return(
+
+
+
+
+
+
+ {item.filesize}
+ {item.author.name}
+ {formatDate(item.created_on)}
+
+ )
+ })
+ }
+
}
- :""}
-
+
+
+
+ 发布设置:
+
+
+ 立即发布
+
+
+
+ 延期发布
+ this.onChangeTimepublish(e,index,undefined,1)}
+ disabledTime={disabledDateTime}
+ disabledDate={disabledDate}
+ disabled={this.state.Radiovalue===1?false:true}
+ />
+
+
+ (按照设置的时间定时发布)
+
+
- {this.state.patheditarrytype===true?请选择资源 :""}
- {this.state.Radiovaluetype===true?发布时间不能为空 :""}
-
+ {this.state.patheditarrytype===true? 请选择资源 :""}
+ {this.state.Radiovaluetype===true? 发布时间不能为空 :""}
+
-
-
- :""}
+
+ :""}
)
}
diff --git a/public/react/src/modules/courses/coursesPublic/sendResource.js b/public/react/src/modules/courses/coursesPublic/sendResource.js
index b0f4b1b69..7915e6674 100644
--- a/public/react/src/modules/courses/coursesPublic/sendResource.js
+++ b/public/react/src/modules/courses/coursesPublic/sendResource.js
@@ -14,12 +14,12 @@ function range(start, end) {
}
return result;
}
-
function disabledDateTime() {
return {
+ // disabledHours: () => range(0, 24).splice(4, 20),
disabledMinutes: () => range(1, 30).concat(range(31, 60)),
- // disabledSeconds: () => range(0,60)
- }
+ // disabledSeconds: () => [0, 60],
+ };
}
function disabledDate(current) {
@@ -45,8 +45,8 @@ class Sendresource extends Component{
// moment(new Date()).format('YYYY-MM-DD HH:mm:ss'),
course_group_publish_times:[
{
- group_id : undefined,
- publish_time :undefined,
+ course_group_id : undefined,
+ publish_time :""
}],
course_groups:undefined,
course_groups_count:undefined,
@@ -86,34 +86,34 @@ class Sendresource extends Component{
}
onAttachmentRemove = (file) => {
- if(!file.percent || file.percent == 100){
- const url = `/attachments/${file.response ? file.response.id : file.uid}.json`
- axios.delete(url, {
- })
- .then((response) => {
- if (response.data) {
- const { status } = response.data;
- if (status == 0) {
- this.setState({
- fileListtype:false,
- fileList:[]
- })
- }
-
- }
- })
- .catch(function (error) {
- console.log(error);
- });
- this.setState({
- fileListtype:false,
- })
- }else{
- this.setState({
- fileListtype:false,
- fileList:[]
- })
- }
+ if(!file.percent || file.percent == 100){
+ const url = `/attachments/${file.response ? file.response.id : file.uid}.json`
+ axios.delete(url, {
+ })
+ .then((response) => {
+ if (response.data) {
+ const { status } = response.data;
+ if (status == 0) {
+ this.setState({
+ fileListtype:false,
+ fileList:[]
+ })
+ }
+
+ }
+ })
+ .catch(function (error) {
+ console.log(error);
+ });
+ this.setState({
+ fileListtype:false,
+ })
+ }else{
+ this.setState({
+ fileListtype:false,
+ fileList:[]
+ })
+ }
}
ModalCancelModalCancel=()=>{
@@ -127,7 +127,7 @@ class Sendresource extends Component{
}
Saves=()=>{
- let {fileList,description,is_public,datatime,Radiovalue,course_group_publish_times} =this.state;
+ let {fileList,description,is_public,datatime,Radiovalue} =this.state;
let newfileList=[];
for(var list of fileList){
@@ -141,7 +141,7 @@ class Sendresource extends Component{
return
}
- if(this.state.Radiovalue===1&&this.props.course_groups.length===0){
+ if(this.state.Radiovalue===1){
if(datatime===undefined||datatime===null||datatime=== ""){
this.setState({
Radiovaluetype:true
@@ -156,7 +156,6 @@ class Sendresource extends Component{
-
if(description===undefined){
}else if(description.length>100){
@@ -177,10 +176,9 @@ class Sendresource extends Component{
course_second_category_id:this.props.coursesidtype===undefined||this.props.coursesidtype==="node"?0:attachmentId,
attachment_ids:newfileList,
is_public:is_public,
- publish_time:this.props.course_groups.length===0?Radiovalue===1?datatime===undefined? undefined:datatime:undefined:"",
+ publish_time:Radiovalue===1?datatime===undefined? undefined:datatime:undefined,
description:description,
delay_publish:Radiovalue,
- group_settings:this.props.course_groups.length===0?"":course_group_publish_times
}).then((result)=>{
if(result.data.status===0){
@@ -239,42 +237,10 @@ class Sendresource extends Component{
Radiovalue: e.target.value,
});
}
-
- addgrouppublish=()=>{
- let newlist=this.state.course_group_publish_times;
- newlist.push( {
- group_id : undefined,
- publish_time :undefined,
- })
- this.setState({
- course_group_publish_times:newlist
- })
- }
- deletegrouppublish=(key)=>{
- let newlist=this.state.course_group_publish_times;
- newlist.splice(key,1);
- this.setState({
- course_group_publish_times:newlist
- })
- }
- selectassigngroups=(e,index,key)=>{
- let {course_group_publish_times}=this.state;
- let newgroup_publish=course_group_publish_times;
- for(var i=0; i
{/*提示*/}
@@ -406,8 +372,8 @@ class Sendresource extends Component{
{this.props.course_is_public===true?
公开:
- 选中,所有用户可见,否则课堂成员可见
-
+ 选中,所有用户可见,否则课堂成员可见
+
:""}
- {this.props.course_groups.length>0?this.props.isStudent()===true?"":
- {this.state.Radiovalue===1?:""}
- {
- course_group_publish_times.map((item,key)=>{
- return(
-
-
-
- this.onChangeTimepublish(e,index,key,2)}
- // onChange={ this.onChangeTimepublish }
- disabledTime={disabledDateTime}
- disabledDate={disabledDate}
- />
- {key!=0?this.deletegrouppublish(key)}>:""}
- {key+1===this.props.course_groups.length?"":}
-
- )
- })
- }
- :""}
+
| | |