From 8b8f5812198ccecdd9ceb286f75005caf84326d9 Mon Sep 17 00:00:00 2001 From: daiao <358551898@qq.com> Date: Mon, 25 Jun 2018 14:21:54 +0800 Subject: [PATCH] =?UTF-8?q?=E9=87=8C=E7=A8=8B=E7=A2=91=E6=9C=AA=E5=AE=8C?= =?UTF-8?q?=E6=88=90=E5=B7=A5=E6=97=B6=E7=BB=9F=E8=AE=A1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/versions/_issue_statistics.html.erb | 7 + app/views/versions/show.html.erb | 2 + db/schema.rb | 808 ++---------------- public/stylesheets/css/project.css | 2 +- 4 files changed, 69 insertions(+), 750 deletions(-) diff --git a/app/views/versions/_issue_statistics.html.erb b/app/views/versions/_issue_statistics.html.erb index 4d3c4cdff..b337e76e4 100644 --- a/app/views/versions/_issue_statistics.html.erb +++ b/app/views/versions/_issue_statistics.html.erb @@ -6,6 +6,8 @@ 完成 关闭 待完成 + 总工时 + 工时债务 @@ -15,6 +17,8 @@ <%= Issue.where(:fixed_version_id => @version.id, :status_id => 3).count %> <%= Issue.where(:fixed_version_id => @version.id, :status_id => 5).count %> <%= Issue.where(fixed_version_id: @version.id, status_id: [1,2,4]).count %> + <%= l_hours(Issue.where(fixed_version_id: @version.id).sum(:estimated_hours)) %> + <%= l_hours(Issue.where(fixed_version_id: @version.id, status_id: [1,2,4]).sum(:estimated_hours)) %> <% @version_issue_assigned_name.each do | assigned | %> @@ -23,7 +27,10 @@ <%= Issue.where(:fixed_version_id => @version.id, :assigned_to_id => assigned[0], :status_id => 3).count %> <%= Issue.where(:fixed_version_id => @version.id, :assigned_to_id => assigned[0], :status_id => 5).count %> <%= Issue.where(fixed_version_id: @version.id, assigned_to_id: assigned[0], status_id: [1,2,4]).count %> + <%= l_hours(Issue.where(fixed_version_id: @version.id, assigned_to_id: assigned[0]).sum(:estimated_hours)) %> + <%= l_hours(Issue.where(fixed_version_id: @version.id, assigned_to_id: assigned[0], status_id: [1,2,4]).sum(:estimated_hours)) %> <% end %> + \ No newline at end of file diff --git a/app/views/versions/show.html.erb b/app/views/versions/show.html.erb index 7bd5d5867..07d07e520 100644 --- a/app/views/versions/show.html.erb +++ b/app/views/versions/show.html.erb @@ -58,6 +58,7 @@ ID 标题 + 工时 类型 指派给 更新时间 @@ -70,6 +71,7 @@ #<%= issue.id %> <%= issue.subject %> + <%= l_hours(issue.estimated_hours) %> <%= issue.tracker %> " class="new_roadmap_info_name" target="_blank"> <%= User.find(issue.try(:assigned_to_id)).nil? ? "" : User.find(issue.try(:assigned_to_id)).show_name %> diff --git a/db/schema.rb b/db/schema.rb index d7c06428c..6f24eed54 100644 --- a/db/schema.rb +++ b/db/schema.rb @@ -11,7 +11,7 @@ # # It's strongly recommended to check this file into your version control system. -ActiveRecord::Schema.define(:version => 20180607085243) do +ActiveRecord::Schema.define(:version => 20180610133055) do create_table "activities", :force => true do |t| t.integer "act_id", :null => false @@ -84,33 +84,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.integer "role", :default => 0 end - create_table "apply_actions", :force => true do |t| - t.integer "user_id" - t.string "reason" - t.integer "container_id" - t.string "container_type" - t.integer "dealer_id" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - t.integer "status", :limit => 1, :default => 0 - t.text "apply_reason" - end - - create_table "apply_add_departments", :force => true do |t| - t.string "name" - t.integer "department_id" - t.integer "school_id" - t.text "remarks" - t.integer "user_id" - t.integer "status" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - - add_index "apply_add_departments", ["department_id"], :name => "index_apply_add_departments_on_department_id" - add_index "apply_add_departments", ["school_id"], :name => "index_apply_add_departments_on_school_id" - add_index "apply_add_departments", ["user_id"], :name => "index_apply_add_departments_on_user_id" - create_table "apply_add_schools", :force => true do |t| t.string "name" t.string "province" @@ -156,19 +129,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.integer "apply_user_id" end - create_table "apply_user_authentications", :force => true do |t| - t.integer "user_id" - t.integer "status" - t.integer "auth_type" - t.string "remarks" - t.integer "dealer" - t.datetime "deal_time" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - - add_index "apply_user_authentications", ["user_id"], :name => "index_apply_user_authentications_on_user_id" - create_table "article_homepages", :force => true do |t| t.string "title" t.text "content" @@ -220,24 +180,23 @@ ActiveRecord::Schema.define(:version => 20180607085243) do create_table "attachments", :force => true do |t| t.integer "container_id" - t.string "container_type", :limit => 30 - t.string "filename", :default => "", :null => false - t.string "disk_filename", :default => "", :null => false - t.integer "filesize", :default => 0, :null => false - t.string "content_type", :default => "" - t.string "digest", :limit => 40, :default => "", :null => false - t.integer "downloads", :default => 0, :null => false - t.integer "author_id", :default => 0, :null => false + t.string "container_type", :limit => 30 + t.string "filename", :default => "", :null => false + t.string "disk_filename", :default => "", :null => false + t.integer "filesize", :default => 0, :null => false + t.string "content_type", :default => "" + t.string "digest", :limit => 40, :default => "", :null => false + t.integer "downloads", :default => 0, :null => false + t.integer "author_id", :default => 0, :null => false t.datetime "created_on" t.text "description" t.string "disk_directory" - t.integer "attachtype", :default => 1 - t.integer "is_public", :default => 1 + t.integer "attachtype", :default => 1 + t.integer "is_public", :default => 1 t.integer "copy_from" t.integer "quotes" - t.integer "is_publish", :default => 1 + t.integer "is_publish", :default => 1 t.datetime "publish_time" - t.integer "resource_bank_id" end add_index "attachments", ["author_id"], :name => "index_attachments_on_author_id" @@ -269,16 +228,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do add_index "auth_sources", ["id", "type"], :name => "index_auth_sources_on_id_and_type" - create_table "authentications", :force => true do |t| - t.integer "level", :limit => 1 - t.text "permissions" - end - - create_table "authentications_users", :force => true do |t| - t.integer "user_id" - t.integer "authentication_id" - end - create_table "biding_projects", :force => true do |t| t.integer "project_id" t.integer "bid_id" @@ -325,7 +274,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.datetime "created_at", :null => false t.datetime "updated_at", :null => false t.integer "root_id" - t.integer "visits", :default => 0 end add_index "blog_comments", ["root_id"], :name => "index_blog_comments_on_root_id" @@ -381,68 +329,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.datetime "updated_at", :null => false end - create_table "challenge_chooses", :force => true do |t| - t.text "subject" - t.integer "challenge_id" - t.string "standard_answer" - t.text "answer" - t.integer "score" - t.integer "difficult" - t.integer "category" - t.integer "position", :default => 1 - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - - create_table "challenge_questions", :force => true do |t| - t.text "option_name" - t.integer "challenge_choose_id" - t.boolean "right_key" - t.integer "position", :limit => 1 - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - - create_table "challenge_samples", :force => true do |t| - t.string "input" - t.string "output" - t.integer "challenge_id" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - t.integer "game_id" - end - - create_table "challenge_tags", :force => true do |t| - t.string "name" - t.integer "challenge_id" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - t.integer "challenge_choose_id" - end - - create_table "challenges", :force => true do |t| - t.integer "shixun_id" - t.string "subject" - t.text "description" - t.integer "user_id" - t.integer "status", :limit => 1, :default => 0 - t.integer "position", :limit => 1, :default => 1 - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - t.text "ready_knowledge", :limit => 2147483647 - t.text "task_pass", :limit => 2147483647 - t.text "answer", :limit => 2147483647 - t.integer "score", :default => 100 - t.integer "visits", :default => 0 - t.string "path" - t.integer "evaluation_way", :default => 0 - t.integer "difficulty", :default => 1 - t.text "pipeline_script" - t.string "exec_path" - t.integer "code_line" - t.integer "st", :limit => 1, :default => 0 - end - create_table "changes", :force => true do |t| t.integer "changeset_id", :null => false t.string "action", :limit => 1, :default => "", :null => false @@ -489,15 +375,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do add_index "changesets_issues", ["changeset_id", "issue_id"], :name => "changesets_issues_ids", :unique => true - create_table "choose_outputs", :force => true do |t| - t.integer "challenge_choose_id" - t.integer "user_id" - t.string "answer" - t.boolean "correct" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - create_table "code_review_assignments", :force => true do |t| t.integer "issue_id" t.integer "change_id" @@ -802,15 +679,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.datetime "updated_at", :null => false end - create_table "course_lists", :force => true do |t| - t.string "name" - t.datetime "created_at" - t.datetime "updated_at" - t.integer "user_id" - t.boolean "is_admin", :default => true - t.boolean "support_shixuns_search", :default => false - end - create_table "course_messages", :force => true do |t| t.integer "user_id" t.integer "course_id" @@ -828,15 +696,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do add_index "course_messages", ["course_message_type"], :name => "index_course_messages_on_course_message_type" add_index "course_messages", ["user_id", "course_id", "created_at"], :name => "index_course_messages_on_user_id_and_course_id_and_created_at" - create_table "course_modules", :force => true do |t| - t.integer "course_id" - t.string "module_type" - t.integer "position" - t.integer "hidden" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - create_table "course_statuses", :force => true do |t| t.integer "changesets_count" t.integer "watchers_count" @@ -854,8 +713,8 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.string "code" t.integer "time" t.string "extra" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false + t.datetime "created_at", :null => false + t.datetime "updated_at", :null => false t.string "location" t.string "term" t.string "string" @@ -865,34 +724,28 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.string "class_period" t.integer "school_id" t.text "description" - t.integer "status", :default => 1 - t.integer "attachmenttype", :default => 2 + t.integer "status", :default => 1 + t.integer "attachmenttype", :default => 2 t.integer "lft" t.integer "rgt" - t.integer "is_public", :limit => 1, :default => 1 - t.integer "inherit_members", :limit => 1, :default => 1 - t.integer "open_student", :default => 0 - t.integer "outline", :default => 0 - t.integer "publish_resource", :default => 0 - t.integer "is_delete", :default => 0 + t.integer "is_public", :limit => 1, :default => 1 + t.integer "inherit_members", :limit => 1, :default => 1 + t.integer "open_student", :default => 0 + t.integer "outline", :default => 0 + t.integer "publish_resource", :default => 0 + t.integer "is_delete", :default => 0 t.integer "end_time" t.string "end_term" - t.integer "is_excellent", :default => 0 - t.integer "excellent_option", :default => 0 - t.integer "is_copy", :default => 0 - t.integer "visits", :default => 0 + t.integer "is_excellent", :default => 0 + t.integer "excellent_option", :default => 0 + t.integer "is_copy", :default => 0 + t.integer "visits", :default => 0 t.integer "syllabus_id" t.string "invite_code" t.string "qrcode" - t.integer "qrcode_expiretime", :default => 0 - t.integer "invite_code_halt", :limit => 1, :default => 0 - t.integer "os_allow", :default => 0 - t.float "credit" - t.boolean "is_end", :default => false - t.date "end_date" - t.boolean "choose_group_allow", :default => false - t.boolean "homepage_show", :default => false - t.integer "course_list_id" + t.integer "qrcode_expiretime", :default => 0 + t.integer "invite_code_halt", :limit => 1, :default => 0 + t.integer "os_allow", :default => 0 end add_index "courses", ["invite_code"], :name => "index_courses_on_invite_code", :unique => true @@ -982,20 +835,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.datetime "updated_at" end - create_table "departments", :force => true do |t| - t.string "name" - t.integer "school_id" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - - add_index "departments", ["school_id"], :name => "index_departments_on_school_id" - - create_table "discipline_categories", :force => true do |t| - t.integer "major_level" - t.string "name" - end - create_table "discuss_demos", :force => true do |t| t.string "title" t.text "body" @@ -1003,21 +842,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.datetime "updated_at", :null => false end - create_table "discusses", :force => true do |t| - t.integer "user_id" - t.string "dis_type" - t.integer "dis_id" - t.text "content" - t.integer "parent_id" - t.integer "root_id" - t.integer "praise_count" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - t.integer "challenge_id" - end - - add_index "discusses", ["user_id"], :name => "index_discusses_on_user_id" - create_table "documents", :force => true do |t| t.integer "project_id", :default => 0, :null => false t.integer "category_id", :default => 0, :null => false @@ -1153,22 +977,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.integer "choice_random", :default => 0 end - create_table "experiences", :force => true do |t| - t.integer "user_id" - t.integer "container_id" - t.string "container_type" - t.integer "score" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - - create_table "first_level_disciplines", :force => true do |t| - t.integer "discipline_category_id" - t.string "name" - end - - add_index "first_level_disciplines", ["discipline_category_id"], :name => "index_first_level_disciplines_on_discipline_category_id" - create_table "first_pages", :force => true do |t| t.string "web_title" t.string "title" @@ -1233,49 +1041,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.datetime "created_at" end - create_table "game_codes", :force => true do |t| - t.integer "game_id" - t.text "original_code", :limit => 2147483647 - t.text "new_code", :limit => 2147483647 - t.string "path" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - - create_table "game_outputs", :force => true do |t| - t.integer "code" - t.integer "game_id" - t.text "msg" - t.text "out_put" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - - create_table "games", :force => true do |t| - t.integer "myshixun_id" - t.integer "user_id" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - t.integer "status", :default => 0 - t.integer "final_score", :default => 0 - t.integer "challenge_id" - t.datetime "open_time" - t.string "identifier" - t.boolean "answer_open" - t.datetime "end_time" - t.integer "retry_status", :default => 0 - t.string "resubmit_identifier" - end - - create_table "grades", :force => true do |t| - t.integer "user_id" - t.integer "container_id" - t.string "container_type" - t.integer "score" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - create_table "groups_users", :id => false, :force => true do |t| t.integer "group_id", :null => false t.integer "user_id", :null => false @@ -1309,26 +1074,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do add_index "homework_attaches", ["bid_id"], :name => "index_homework_attaches_on_bid_id" - create_table "homework_bank_samples", :force => true do |t| - t.text "input" - t.text "output" - t.integer "homework_bank_id" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - - add_index "homework_bank_samples", ["homework_bank_id"], :name => "index_homework_bank_samples_on_homework_bank_id" - - create_table "homework_bank_shixuns", :force => true do |t| - t.integer "homework_bank_id" - t.integer "shixun_id" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - - add_index "homework_bank_shixuns", ["homework_bank_id"], :name => "index_homework_bank_shixuns_on_homework_bank_id" - add_index "homework_bank_shixuns", ["shixun_id"], :name => "index_homework_bank_shixuns_on_shixun_id" - create_table "homework_bank_tests", :force => true do |t| t.text "input" t.text "output" @@ -1343,23 +1088,17 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.string "name" t.text "description" t.integer "homework_type" - t.integer "quotes", :default => 0 + t.integer "quotes", :default => 0 t.boolean "is_public" t.string "language" - t.text "standard_code", :limit => 2147483647 + t.text "standard_code", :limit => 2147483647 t.integer "min_num" t.integer "max_num" t.boolean "base_on_project" t.string "applicable_syllabus" t.integer "homework_common_id" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - t.text "reference_answer" - t.integer "syllabus_id" - t.text "major_level" - t.text "discipline_category_id" - t.text "first_level_discipline_id" - t.integer "course_list_id" + t.datetime "created_at", :null => false + t.datetime "updated_at", :null => false end create_table "homework_commons", :force => true do |t| @@ -1382,24 +1121,10 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.integer "anonymous_appeal", :default => 0 t.integer "homework_bank_id" t.boolean "is_update", :default => false - t.boolean "is_public", :default => false - t.text "reference_answer" - t.boolean "answer_public", :default => true - t.datetime "archive_time" - t.boolean "allow_late", :default => true - t.datetime "late_time" - t.boolean "work_public", :default => true end add_index "homework_commons", ["course_id", "id"], :name => "index_homework_commons_on_course_id_and_id" - create_table "homework_commons_shixuns", :force => true do |t| - t.integer "shixun_id" - t.integer "homework_common_id" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - create_table "homework_detail_groups", :force => true do |t| t.integer "homework_common_id" t.integer "min_num" @@ -1414,20 +1139,18 @@ ActiveRecord::Schema.define(:version => 20180607085243) do create_table "homework_detail_manuals", :force => true do |t| t.float "ta_proportion" t.integer "comment_status" - t.datetime "evaluation_start" - t.datetime "evaluation_end" + t.date "evaluation_start" + t.date "evaluation_end" t.integer "evaluation_num" - t.integer "absence_penalty", :default => 1 + t.integer "absence_penalty", :default => 1 t.integer "homework_common_id" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - t.integer "no_anon_penalty", :default => 1 - t.integer "appeal_penalty", :default => 0 - t.integer "ta_mode", :default => 1 - t.datetime "appeal_time" - t.float "te_proportion", :default => 1.0 - t.boolean "final_mode", :default => false - t.boolean "answer_open_evaluation", :default => false + t.datetime "created_at", :null => false + t.datetime "updated_at", :null => false + t.integer "no_anon_penalty", :default => 1 + t.integer "appeal_penalty", :default => 0 + t.integer "ta_mode", :default => 1 + t.float "te_proportion", :default => 1.0 + t.boolean "final_mode", :default => false end create_table "homework_detail_programings", :force => true do |t| @@ -1455,15 +1178,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do add_index "homework_for_courses", ["bid_id"], :name => "index_homework_for_courses_on_bid_id" add_index "homework_for_courses", ["course_id"], :name => "index_homework_for_courses_on_course_id" - create_table "homework_reference_answers", :force => true do |t| - t.text "answer" - t.integer "homework_common_id" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - - add_index "homework_reference_answers", ["homework_common_id"], :name => "index_homework_reference_answers_on_homework_common_id" - create_table "homework_samples", :force => true do |t| t.text "input" t.text "output" @@ -1491,16 +1205,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.datetime "updated_at", :null => false end - create_table "import_students", :force => true do |t| - t.string "name" - t.string "student_number" - t.integer "course_id" - t.integer "school_id" - t.integer "status", :default => 0 - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - create_table "innodb_monitor", :id => false, :force => true do |t| t.integer "a" end @@ -1671,34 +1375,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.datetime "updated_at", :null => false end - create_table "major_courses", :force => true do |t| - t.integer "course_list_id" - t.integer "major_id" - end - - add_index "major_courses", ["course_list_id"], :name => "index_major_courses_on_course_list_id" - add_index "major_courses", ["major_id"], :name => "index_major_courses_on_major_id" - - create_table "majors", :force => true do |t| - t.string "major_code" - t.string "name" - t.integer "first_level_discipline_id" - t.integer "discipline_category_id" - t.integer "major_level" - t.datetime "created_at" - t.datetime "updated_at" - t.boolean "support_shixuns", :default => false - end - - add_index "majors", ["discipline_category_id"], :name => "index_majors_on_discipline_category_id" - add_index "majors", ["first_level_discipline_id"], :name => "index_majors_on_first_level_discipline_id" - - create_table "mark_downs", :force => true do |t| - t.text "description" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - create_table "member_roles", :force => true do |t| t.integer "member_id", :null => false t.integer "role_id", :null => false @@ -1717,7 +1393,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.integer "course_id", :default => -1 t.integer "course_group_id", :default => 0 t.integer "is_collect", :default => 1 - t.integer "import_student_id" end add_index "members", ["course_id"], :name => "index_members_on_course_id" @@ -1783,7 +1458,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.integer "quotes" t.integer "status", :default => 0 t.integer "root_id" - t.integer "visits", :default => 0 end add_index "messages", ["author_id"], :name => "index_messages_on_author_id" @@ -1793,77 +1467,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do add_index "messages", ["parent_id"], :name => "messages_parent_id" add_index "messages", ["root_id"], :name => "index_messages_on_root_id" - create_table "mirror_repositories", :force => true do |t| - t.string "mirrorID" - t.string "name" - t.string "main_type" - t.string "tag" - t.text "description" - t.integer "status" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - - create_table "mirror_repository_types", :force => true do |t| - t.integer "mirror_type_id" - t.integer "mirror_repository_id" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - - add_index "mirror_repository_types", ["mirror_repository_id"], :name => "index_mirror_repository_types_on_mirror_repository_id" - add_index "mirror_repository_types", ["mirror_type_id"], :name => "index_mirror_repository_types_on_mirror_type_id" - - create_table "mirror_types", :force => true do |t| - t.string "name" - t.integer "user_id" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - - create_table "mirror_update_records", :force => true do |t| - t.integer "user_id" - t.integer "mirror_repository_id" - t.string "oldName" - t.string "newName" - t.string "oldType" - t.string "newType" - t.text "oldTag" - t.text "newTag" - t.text "oldDescription" - t.text "newDescription" - t.integer "oldStatus" - t.integer "newStatus" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - - add_index "mirror_update_records", ["mirror_repository_id"], :name => "index_mirror_update_records_on_mirror_repository_id" - add_index "mirror_update_records", ["user_id"], :name => "index_mirror_update_records_on_user_id" - - create_table "myshixun_members", :force => true do |t| - t.integer "myshixun_id" - t.integer "user_id" - t.integer "role" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - - create_table "myshixuns", :force => true do |t| - t.string "name" - t.text "description" - t.integer "shixun_id" - t.boolean "is_public", :default => true - t.integer "user_id" - t.integer "gpid" - t.integer "visits", :default => 0 - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - t.integer "status", :default => 0 - t.string "identifier" - t.string "commit_id" - end - create_table "news", :force => true do |t| t.integer "project_id" t.string "title", :limit => 60, :default => "", :null => false @@ -2059,21 +1662,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.integer "allow_teacher", :default => 0 end - create_table "outputs", :force => true do |t| - t.integer "code" - t.integer "game_id" - t.text "msg" - t.text "out_put", :limit => 2147483647 - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - t.integer "test_set_position" - t.text "actual_output" - t.boolean "result" - t.boolean "is_public" - t.integer "query_index", :default => 1 - t.integer "compile_success", :default => 1 - end - create_table "phone_app_versions", :force => true do |t| t.string "version" t.text "description" @@ -2131,14 +1719,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.integer "show_result", :default => 1 end - create_table "pr_paths", :force => true do |t| - t.integer "project_id" - t.integer "gitlab_project_id" - t.string "path" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - create_table "praise_tread_caches", :force => true do |t| t.integer "object_id", :null => false t.string "object_type" @@ -2247,6 +1827,7 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.integer "qrcode_expiretime", :default => 0 t.text "script" t.integer "training_status", :limit => 1, :default => 0 + t.string "language" end add_index "projects", ["lft"], :name => "index_projects_on_lft" @@ -2264,11 +1845,12 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.integer "pull_request_id" t.integer "gpid" t.integer "user_id" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - t.integer "status", :default => 0 + t.datetime "created_at", :null => false + t.datetime "updated_at", :null => false + t.integer "status", :default => 0 t.integer "project_id" t.string "title" + t.text "jenkins_output", :limit => 2147483647 end create_table "quality_analyses", :force => true do |t| @@ -2300,17 +1882,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do add_index "queries", ["project_id"], :name => "index_queries_on_project_id" add_index "queries", ["user_id"], :name => "index_queries_on_user_id" - create_table "reference_materials", :force => true do |t| - t.string "book" - t.string "editor" - t.string "press" - t.integer "syllabus_id" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - - add_index "reference_materials", ["syllabus_id"], :name => "index_reference_materials_on_syllabus_id" - create_table "relative_memo_to_open_source_projects", :force => true do |t| t.integer "osp_id" t.integer "relative_memo_id" @@ -2365,47 +1936,10 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.string "identifier" t.boolean "is_default", :default => false t.boolean "hidden", :default => false - t.integer "shixun_id" - t.integer "myshixun_id" end add_index "repositories", ["project_id"], :name => "index_repositories_on_project_id" - create_table "repository_paths", :force => true do |t| - t.string "path" - t.integer "myshixun_id" - t.integer "user_id" - t.integer "status" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - - create_table "resource_banks", :force => true do |t| - t.integer "course_id" - t.integer "attachment_id" - t.string "filename" - t.string "disk_filename" - t.integer "filesize" - t.string "digest" - t.integer "downloads" - t.integer "user_id" - t.text "description" - t.string "disk_directory" - t.boolean "is_public" - t.integer "copy_from" - t.integer "quotes" - t.string "applicable_syllabus" - t.integer "major_level" - t.integer "discipline_category_id" - t.integer "first_level_discipline_id" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - t.string "content_type" - end - - add_index "resource_banks", ["course_id"], :name => "index_resource_banks_on_course_id" - add_index "resource_banks", ["user_id"], :name => "index_resource_banks_on_user_id" - create_table "rich_rich_files", :force => true do |t| t.datetime "created_at", :null => false t.datetime "updated_at", :null => false @@ -2431,14 +1965,11 @@ ActiveRecord::Schema.define(:version => 20180607085243) do create_table "schools", :force => true do |t| t.string "name" t.string "province" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false + t.datetime "created_at", :null => false + t.datetime "updated_at", :null => false t.string "logo_link" t.string "pinyin" - t.integer "school_type", :default => 0 - t.string "city" - t.string "address" - t.boolean "auto_users_trial", :default => false + t.integer "school_type", :default => 0 end create_table "secdomains", :force => true do |t| @@ -2509,75 +2040,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.datetime "updated_at", :null => false end - create_table "shixun_major_courses", :force => true do |t| - t.integer "shixun_id" - t.integer "course_list_id" - t.integer "major_id" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - - add_index "shixun_major_courses", ["major_id"], :name => "index_shixun_major_courses_on_major_id" - add_index "shixun_major_courses", ["shixun_id"], :name => "index_shixun_major_courses_on_shixun_id" - - create_table "shixun_members", :force => true do |t| - t.integer "user_id" - t.integer "shixun_id" - t.integer "role" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - - create_table "shixun_modifies", :force => true do |t| - t.integer "shixun_id" - t.integer "myshixun_id" - t.integer "status", :limit => 1, :default => 0 - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - - create_table "shixun_ports", :force => true do |t| - t.integer "shixun_id" - t.integer "port" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - - create_table "shixun_tags", :force => true do |t| - t.string "name" - t.integer "challenge_id" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - - create_table "shixuns", :force => true do |t| - t.string "name" - t.text "description" - t.text "script" - t.boolean "is_public", :default => true - t.integer "user_id" - t.integer "gpid" - t.integer "visits", :default => 0 - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - t.integer "changeset_num" - t.integer "status", :default => 0 - t.string "language" - t.string "identifier" - t.boolean "authentication", :default => false - t.integer "myshixun_count", :default => 0 - t.string "exec_path" - t.text "propaedeutics", :limit => 2147483647 - t.integer "is_updated", :default => 0 - t.boolean "webssh", :default => false - t.integer "trainee", :default => 1 - t.integer "major_id" - t.boolean "homepage_show", :default => false - t.boolean "hidden", :default => false - t.integer "fork_from" - t.boolean "can_copy", :default => false - end - create_table "softapplications", :force => true do |t| t.string "name" t.text "description" @@ -2618,32 +2080,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do add_index "ssos", ["user_id"], :name => "index_ssos_on_user_id" - create_table "stage_shixuns", :force => true do |t| - t.integer "subject_id" - t.integer "stage_id" - t.integer "shixun_id" - t.integer "position" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - - add_index "stage_shixuns", ["shixun_id"], :name => "index_stage_shixuns_on_shixun_id" - add_index "stage_shixuns", ["stage_id"], :name => "index_stage_shixuns_on_stage_id" - add_index "stage_shixuns", ["subject_id"], :name => "index_stage_shixuns_on_subject_id" - - create_table "stages", :force => true do |t| - t.integer "subject_id" - t.string "name" - t.text "description" - t.integer "user_id" - t.integer "position" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - - add_index "stages", ["subject_id"], :name => "index_stages_on_subject_id" - add_index "stages", ["user_id"], :name => "index_stages_on_user_id" - create_table "statistics", :force => true do |t| t.string "name" t.text "description" @@ -2707,13 +2143,9 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.integer "is_delete", :default => 0 t.integer "appeal_penalty", :default => 0 t.boolean "re_commit", :default => false - t.text "late_reason" - t.integer "group_id", :default => 0 - t.integer "myshixun_id" end add_index "student_works", ["homework_common_id", "user_id"], :name => "index_student_works_on_homework_common_id_and_user_id" - add_index "student_works", ["myshixun_id"], :name => "myshixun_id" create_table "student_works_evaluation_distributions", :force => true do |t| t.integer "student_work_id" @@ -2795,25 +2227,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.datetime "updated_at", :null => false end - create_table "subjects", :force => true do |t| - t.string "name" - t.text "description" - t.integer "user_id" - t.integer "visits" - t.integer "status" - t.integer "course_list_id" - t.integer "major_id" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - t.boolean "hidden", :default => false - t.text "learning_notes" - t.string "introduction" - end - - add_index "subjects", ["course_list_id"], :name => "index_subjects_on_course_list_id" - add_index "subjects", ["major_id"], :name => "index_subjects_on_major_id" - add_index "subjects", ["user_id"], :name => "index_subjects_on_user_id" - create_table "syllabus_members", :force => true do |t| t.integer "rank" t.integer "syllabus_id" @@ -2826,23 +2239,12 @@ ActiveRecord::Schema.define(:version => 20180607085243) do add_index "syllabus_members", ["syllabus_id"], :name => "index_syllabus_members_on_syllabus_id" add_index "syllabus_members", ["user_id"], :name => "index_syllabus_members_on_user_id" - create_table "syllabus_update_records", :force => true do |t| - t.integer "user_id" - t.integer "syllabus_id" - t.integer "property" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - - add_index "syllabus_update_records", ["syllabus_id"], :name => "index_syllabus_update_records_on_syllabus_id" - add_index "syllabus_update_records", ["user_id"], :name => "index_syllabus_update_records_on_user_id" - create_table "syllabuses", :force => true do |t| t.string "title" t.text "description" t.integer "user_id" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false + t.datetime "created_at", :null => false + t.datetime "updated_at", :null => false t.string "eng_name" t.integer "syllabus_type" t.integer "credit" @@ -2851,12 +2253,8 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.integer "practice_hours" t.string "applicable_major" t.string "pre_course" - t.integer "visits", :default => 0 - t.integer "des_status", :default => 0 - t.integer "major_level" - t.integer "discipline_category_id" - t.integer "first_level_discipline_id" - t.integer "major_id" + t.integer "visits", :default => 0 + t.integer "des_status", :default => 0 end add_index "syllabuses", ["user_id"], :name => "index_syllabuses_on_user_id" @@ -2898,30 +2296,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.string "extra" end - create_table "test_sets", :force => true do |t| - t.string "input" - t.text "output" - t.integer "challenge_id" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - t.integer "game_id" - t.string "actual_output" - t.boolean "is_public", :default => true - t.boolean "result", :default => true - t.integer "position" - end - - create_table "tests", :force => true do |t| - t.integer "user_id" - t.string "username" - t.integer "change_id" - t.string "pr_path" - t.integer "project_id" - t.integer "gpid" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - create_table "time_entries", :force => true do |t| t.integer "project_id", :null => false t.integer "user_id", :null => false @@ -2970,7 +2344,7 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.datetime "updated_at", :null => false t.integer "author_id" t.integer "status", :limit => 1, :default => 0 - t.integer "position", :limit => 1 + t.integer "position", :limit => 1, :default => 0 t.integer "result", :default => 0 end @@ -3013,7 +2387,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.string "location_city" t.integer "school_id" t.string "description", :default => "" - t.integer "department_id" end add_index "user_extensions", ["user_id"], :name => "index_user_extensions_on_user_id" @@ -3116,47 +2489,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do end create_table "users", :force => true do |t| - t.string "login", :default => "", :null => false - t.string "hashed_password", :limit => 40, :default => "", :null => false - t.string "firstname", :limit => 30, :default => "", :null => false - t.string "lastname", :default => "", :null => false - t.string "mail", :limit => 60, :default => "", :null => false - t.boolean "admin", :default => false, :null => false - t.integer "status", :default => 1, :null => false - t.datetime "last_login_on" - t.string "language", :limit => 5, :default => "" - t.integer "auth_source_id" - t.datetime "created_on" - t.datetime "updated_on" - t.string "type" - t.string "identity_url" - t.string "mail_notification", :default => "", :null => false - t.string "salt", :limit => 64 - t.integer "gid" - t.integer "visits", :default => 0 - t.integer "excellent_teacher", :default => 0 - t.integer "excellent_student", :default => 0 - t.string "phone" - t.boolean "authentication", :default => false - t.integer "grade" - t.integer "experience", :default => 0 - t.string "nickname" - t.boolean "show_realname", :default => true - t.boolean "professional_certification", :default => false - t.string "ID_number" - t.integer "certification", :default => 0 - end - - add_index "users", ["auth_source_id"], :name => "index_users_on_auth_source_id" - add_index "users", ["id", "type"], :name => "index_users_on_id_and_type" - add_index "users", ["type"], :name => "index_users_on_type" - - create_table "users_authentications", :force => true do |t| - t.integer "user_id" - t.integer "authentication_id" - end - - create_table "users_copy", :force => true do |t| t.string "login", :default => "", :null => false t.string "hashed_password", :limit => 40, :default => "", :null => false t.string "firstname", :limit => 30, :default => "", :null => false @@ -3177,25 +2509,11 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.integer "visits", :default => 0 t.integer "excellent_teacher", :default => 0 t.integer "excellent_student", :default => 0 - t.string "phone" - t.boolean "authentication", :default => false - t.integer "grade" - t.integer "experience", :default => 0 end - add_index "users_copy", ["auth_source_id"], :name => "index_users_on_auth_source_id" - add_index "users_copy", ["id", "type"], :name => "index_users_on_id_and_type" - add_index "users_copy", ["type"], :name => "index_users_on_type" - - create_table "verification_codes", :force => true do |t| - t.string "code" - t.integer "code_type" - t.integer "status" - t.string "phone" - t.string "email" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end + add_index "users", ["auth_source_id"], :name => "index_users_on_auth_source_id" + add_index "users", ["id", "type"], :name => "index_users_on_id_and_type" + add_index "users", ["type"], :name => "index_users_on_type" create_table "versions", :force => true do |t| t.integer "project_id", :default => 0, :null => false @@ -3249,14 +2567,6 @@ ActiveRecord::Schema.define(:version => 20180607085243) do t.datetime "updated_at", :null => false end - create_table "websshes", :force => true do |t| - t.integer "myshixun_id" - t.string "host" - t.integer "port" - t.datetime "created_at", :null => false - t.datetime "updated_at", :null => false - end - create_table "wechat_logs", :force => true do |t| t.string "openid", :null => false t.text "request_raw" diff --git a/public/stylesheets/css/project.css b/public/stylesheets/css/project.css index 81ed4b700..ef6b2bd1d 100644 --- a/public/stylesheets/css/project.css +++ b/public/stylesheets/css/project.css @@ -511,7 +511,7 @@ select.new_roadmap_select{border:1px solid #dbdbdb; color: #666;} .new_roadmap_info_top{border-bottom:1px solid #dbdbdb; padding:10px 15px;} .new_roadmap_icons_back{ background: url(/images/new_project/icons_issue.png) 0 -247px no-repeat; display: inline-block; width: 16px; height: 12px;} .pd15box{ padding:0 15px;} -.new_roadmap_info_title{ display: block; margin-left: 10px; text-align: left;max-width:520px; overflow:hidden;white-space: nowrap; text-overflow:ellipsis;} +.new_roadmap_info_title{ display: block; margin-left: 10px; text-align: left;max-width:400px; overflow:hidden;white-space: nowrap; text-overflow:ellipsis;} .new_roadmap_info_name{ display: block; margin-left: 10px; text-align: left;max-width:80px; overflow:hidden;white-space: nowrap; text-overflow:ellipsis;} .pages{margin:10px auto 10px;} /*表格*/