commit
00628a0c83
|
@ -8,7 +8,7 @@ class ContestsController < ApplicationController
|
|||
helper :files
|
||||
include AvatarHelper
|
||||
|
||||
before_filter :find_contest, :only => [:show, :settings, :update, :destroy, :contest_activities, :search_member, :private_or_public, :switch_role, :set_invite_code_halt, :renew,
|
||||
before_filter :find_contest, :only => [:show, :settings, :update, :destroy, :contest_activities, :private_or_public, :switch_role, :set_invite_code_halt, :renew,
|
||||
:member, :export_all_members, :feedback]
|
||||
before_filter :is_logged, :only => [:index, :new, :create]
|
||||
before_filter :is_admin?, :only => [:settings, :set_invite_code_halt, :destroy]
|
||||
|
@ -247,20 +247,6 @@ class ContestsController < ApplicationController
|
|||
redirect_to contest_path(@contest)
|
||||
end
|
||||
|
||||
def search_member
|
||||
if User.current.admin_of_contest?(@contest) || User.current.admin?
|
||||
q = "#{params[:name].strip}"
|
||||
@roles = Role.givable.all[11..13]
|
||||
if q.nil? || q == ""
|
||||
@members = @contest.member_principals.includes(:roles, :principal).all.sort
|
||||
else
|
||||
@members = searchmember_by_name(@contest.member_principals.includes(:roles, :principal).all.sort,q)
|
||||
end
|
||||
else
|
||||
render_403
|
||||
end
|
||||
end
|
||||
|
||||
# 邀请码停用/启用
|
||||
def set_invite_code_halt
|
||||
if User.current.admin_of_contest?(@contest) || User.current.admin?
|
||||
|
|
|
@ -630,11 +630,6 @@ class CoursesController < ApplicationController
|
|||
join_course_messages = CourseMessage.where("user_id =? and course_message_type =? and course_id =? and status = ? and viewed =?", User.current.id, 'JoinCourse', @course.id, 1, 0)
|
||||
join_course_messages.update_all(:viewed => true)
|
||||
|
||||
if params[:tab] && params[:tab] == 'boards'
|
||||
@tab = 4
|
||||
else
|
||||
@tab = 0
|
||||
end
|
||||
if User.current.allowed_to?(:as_teacher,@course)
|
||||
@select_tab = params[:tab]
|
||||
@issue_custom_fields = IssueCustomField.sorted.all
|
||||
|
@ -644,6 +639,14 @@ class CoursesController < ApplicationController
|
|||
|
||||
@roles = Role.givable.all[3..5]
|
||||
@members = @course.member_principals.includes(:roles, :principal).all.sort
|
||||
|
||||
course_org_ids = OrgCourse.find_by_sql("select distinct organization_id from org_courses where course_id = #{@course.id}").map(&:organization_id)
|
||||
if course_org_ids.empty?
|
||||
@orgs_not_in_course = User.current.organizations
|
||||
else
|
||||
course_org_ids = "(" + course_org_ids.join(',') + ")"
|
||||
@orgs_not_in_course = User.current.organizations.where("organizations.id not in #{course_org_ids}")
|
||||
end
|
||||
respond_to do |format|
|
||||
format.html { render :layout => 'base_courses' }
|
||||
format.api { render_validation_errors(@course) }
|
||||
|
@ -1160,6 +1163,7 @@ class CoursesController < ApplicationController
|
|||
page = params[:page]
|
||||
# Find the page of the requested reply
|
||||
@jours = @course.journals_for_messages.where('m_parent_id IS NULL').order('created_on DESC')
|
||||
@jour_count = @jours.count
|
||||
@limit = 10
|
||||
if params[:r] && page.nil?
|
||||
offset = @jours.count(:conditions => ["#{JournalsForMessage.table_name}.id > ?", params[:r].to_i])
|
||||
|
@ -1367,9 +1371,25 @@ class CoursesController < ApplicationController
|
|||
end
|
||||
|
||||
#统计
|
||||
def statistics_course
|
||||
def course_statistics
|
||||
@left_nav_type = 10
|
||||
# @order = params[:order] ? params[:order] : 'desc'
|
||||
# if !params[:tab] || params[:tab] == "activity"
|
||||
# @type = params[:type] ? params[:type] : 'act_score'
|
||||
# sql = "SELECT (message_num*2 + message_reply_num*1 + news_reply_num*1 + news_num*1 + resource_num*5 + journal_num*1 + homework_journal_num*1) AS act_score,
|
||||
# message_num, message_reply_num, news_reply_num, news_num, resource_num, journal_num, homework_journal_num, ccs.user_id FROM course_contributor_scores ccs
|
||||
# JOIN students_for_courses ON students_for_courses.course_id = ccs.course_id AND students_for_courses.student_id = ccs.user_id
|
||||
# WHERE ccs.course_id = #{@course.id} HAVING act_score != 0 ORDER BY #{@type} #{@order}, act_score #{@order}"
|
||||
# @members = CourseContributorScore.find_by_sql(sql)
|
||||
# end
|
||||
#
|
||||
# @limit = 20
|
||||
# @page = params[:page].nil? ? 1 : params['page'].to_i
|
||||
# @members_count = @members.count
|
||||
# @mem_pages = Paginator.new @members_count, @limit, @page
|
||||
# @members = paginateHelper @members, @limit
|
||||
respond_to do |format|
|
||||
format.js
|
||||
format.html {render :layout => 'base_courses'}
|
||||
end
|
||||
end
|
||||
|
|
|
@ -352,7 +352,9 @@ class MembersController < ApplicationController
|
|||
role_ids = attrs.delete(:role_ids)
|
||||
|
||||
if role_ids && role_ids.include?("10")
|
||||
StudentsForCourse.create(:student_id => @member.user_id, :course_id =>@course.id)
|
||||
if StudentsForCourse.where(:student_id => @member.user_id, :course_id =>@course.id).blank?
|
||||
StudentsForCourse.create(:student_id => @member.user_id, :course_id =>@course.id)
|
||||
end
|
||||
else
|
||||
joined = StudentsForCourse.where('student_id = ? and course_id = ?', @member.user_id,@course.id)
|
||||
joined.each do |join|
|
||||
|
|
|
@ -2023,31 +2023,28 @@ class UsersController < ApplicationController
|
|||
reorder("#{MessageAll.table_name}.created_at desc")
|
||||
|
||||
@unsolved_issues_count = Issue.where(:assigned_to_id => @user.id, :status_id => [1, 2, 4, 6]).includes(:author, :project).count
|
||||
# 用户待完成的作业
|
||||
|
||||
my_course_ids = StudentsForCourse.includes(:course).where("student_id = #{@user.id} and courses.is_delete = 0").blank? ? "(-1)" : "(" + StudentsForCourse.includes(:course).
|
||||
where("student_id = #{@user.id} and courses.is_delete = 0").map{|sc| sc.course_id}.join(",") + ")"
|
||||
# 用户待完成的作业
|
||||
homeworks = HomeworkCommon.where("course_id in #{my_course_ids} and publish_time <= '#{Date.today}'")
|
||||
homework_ids = homeworks.blank? ? "(-1)" : "(" + homeworks.map{|homework| homework.id}.join(",") + ")"
|
||||
student_works = StudentWork.where("user_id = #{@user.id} and homework_common_id in #{homework_ids} and work_status != 0")
|
||||
@unfinished_homework_count = homeworks.count - student_works.count
|
||||
# 用户待完成的测验
|
||||
exercises = Exercise.where("course_id in #{my_course_ids} and exercise_status = 2")
|
||||
exercise_ids = exercises.blank? ? "(-1)" : "(" + exercises.map{|ex| ex.id}.join(",") + ")"
|
||||
exercise_users = ExerciseUser.where("user_id = #{@user.id} and exercise_id in #{exercise_ids}")
|
||||
exercise_users = ExerciseUser.where(:user_id => @user.id, :exercise_id => exercises.map{|ex| ex.id})
|
||||
@unfinished_test_count = exercises.count - exercise_users.count
|
||||
# 用户待完成的问卷
|
||||
polls = Poll.where("polls_type = 'Course' and polls_group_id in #{my_course_ids} and polls_status = 2")
|
||||
poll_ids = polls.blank? ? "(-1)" : "(" + polls.map{|poll| poll.id}.join(",") + ")"
|
||||
poll_users = PollUser.where("user_id = #{@user.id} and poll_id in #{poll_ids}")
|
||||
poll_users = PollUser.where(:user_id => @user.id, :poll_id => polls.map{|poll| poll.id})
|
||||
@unfinished_poll_count = polls.count - poll_users.count
|
||||
# 用户待匿评的作品
|
||||
homeworks = HomeworkCommon.includes(:homework_detail_manual).where("homework_commons.course_id in #{my_course_ids} and homework_detail_manuals.comment_status in (1,2)")
|
||||
homework_ids = homeworks.blank? ? "(-1)" : "(" + homeworks.map{|homework| homework.id}.join(",") + ")"
|
||||
homeworks = HomeworkCommon.includes(:homework_detail_manual).where("homework_commons.course_id in #{my_course_ids} and homework_detail_manuals.comment_status = 2")
|
||||
student_work_scores = @user.student_works_scores.where("reviewer_role = 3")
|
||||
anonymous_evaluation_ids = student_work_scores.blank? ? "(-1)" : "(" + student_work_scores.map{|st| st.student_work_id}.join(",") + ")"
|
||||
unfinished_evaluations = @user.student_works_evaluation_distributions.where("student_work_id not in #{anonymous_evaluation_ids}")
|
||||
unfinished_evaluations_work_ids = unfinished_evaluations.blank? ? "(-1)" : "(" + unfinished_evaluations.map{|st| st.student_work_id}.join(",") + ")"
|
||||
@anonymous_evaluation_count = StudentWork.where("student_works.id in #{unfinished_evaluations_work_ids} and homework_common_id in #{homework_ids}").count
|
||||
@anonymous_evaluation_count = StudentWork.where(:id => unfinished_evaluations.map{|ev| ev.student_work_id}, :homework_common_id => homeworks.map{|hw| hw.id}).count
|
||||
# 待评阅的作业 暂不做
|
||||
# @unreview_homework = 1
|
||||
|
||||
|
|
|
@ -95,6 +95,14 @@ class WordsController < ApplicationController
|
|||
@jours_count = @course.journals_for_messages.where('m_parent_id IS NULL').count
|
||||
@user_activity_id = params[:user_activity_id] if params[:user_activity_id]
|
||||
@activity = JournalsForMessage.where("id = #{params[:activity_id].to_i}").first if params[:activity_id]
|
||||
unless @activity
|
||||
if params[:user_activity_id] == params[:activity_id]
|
||||
redirect_to course_feedback_path(@course)
|
||||
else
|
||||
redirect_to course_path(@course)
|
||||
end
|
||||
return
|
||||
end
|
||||
elsif @journal_destroyed.jour_type == "Principal"
|
||||
@user = User.find(@journal_destroyed.jour_id)
|
||||
@jours_count = @user.journals_for_messages.where('m_parent_id IS NULL').count
|
||||
|
@ -282,7 +290,7 @@ class WordsController < ApplicationController
|
|||
# add by nwb
|
||||
def leave_course_message
|
||||
user = User.current
|
||||
message = params[:new_form][:course_message]
|
||||
message = params[:new_form][:content]
|
||||
feedback = Course.add_new_jour(user, message, params[:id])
|
||||
if(feedback.errors.empty?)
|
||||
if params[:asset_id]
|
||||
|
|
|
@ -112,7 +112,7 @@ class WorksController < ApplicationController
|
|||
homework_end_time = Time.parse(@contestwork.end_time.to_s).strftime("%Y-%m-%d")
|
||||
work_detail_manual = @contestwork.work_detail_manual
|
||||
if homework_end_time != param_end_time
|
||||
eval_start = work_detail_manual.evaluation_start
|
||||
eval_start = Time.parse(work_detail_manual.evaluation_start.to_s).strftime("%Y-%m-%d")
|
||||
if eval_start.nil? || (eval_start <= param_end_time && @contestwork.work_status <= 2)
|
||||
work_detail_manual.evaluation_start = @contestwork.end_time + 7
|
||||
work_detail_manual.evaluation_end = work_detail_manual.evaluation_start + 7
|
||||
|
|
|
@ -56,13 +56,14 @@ class Comment < ActiveRecord::Base
|
|||
# end
|
||||
end
|
||||
elsif self.commented.contest
|
||||
if self.author_id != self.commented.author_id
|
||||
self.contest_messages << ContestMessage.new(:user_id => self.commented.author_id, :contest_id => self.commented.contest.id, :viewed => false)
|
||||
# count = ShieldWechatMessage.where("container_type='User' and container_id=#{self.commented.author_id} and shield_type='Course' and shield_id=#{self.commented.course.id}").count
|
||||
# if count == 0
|
||||
# content = strip_html self.comments.html_safe, 200
|
||||
# ws.comment_template self.commented.author_id, "course_notice", self.id, "#{l(:label_notice_comment_template)}", self.author.try(:realname), format_time(self.created_on), content
|
||||
# end
|
||||
if self.parent.nil?
|
||||
if self.author_id != self.commented.author_id
|
||||
self.contest_messages << ContestMessage.new(:user_id => self.commented.author_id, :contest_id => self.commented.contest.id, :viewed => false)
|
||||
end
|
||||
else
|
||||
if self.author_id != self.parent.author_id
|
||||
self.contest_messages << ContestMessage.new(:user_id => self.parent.author_id, :contest_id => self.commented.contest.id, :viewed => false)
|
||||
end
|
||||
end
|
||||
else # 项目相关
|
||||
# if self.author_id != self.commented.author_id
|
||||
|
|
|
@ -55,6 +55,7 @@ class Course < ActiveRecord::Base
|
|||
has_many :student_works, :through => :homework_commons, :dependent => :destroy
|
||||
|
||||
has_many :course_groups, :dependent => :destroy
|
||||
#has_many :course_homework_statistics, :dependent => :destroy
|
||||
# 课程动态
|
||||
has_many :course_acts, :class_name => 'CourseActivity',:as =>:course_act ,:dependent => :destroy
|
||||
|
||||
|
|
|
@ -78,7 +78,7 @@ class JournalsForMessage < ActiveRecord::Base
|
|||
validates :notes, presence: true, if: :is_homework_jour?
|
||||
after_create :act_as_course_activity, :act_as_course_message, :act_as_contest_activity,
|
||||
act_as_at_message(:notes, :user_id), :act_as_user_feedback_message,
|
||||
:act_as_principal_activity
|
||||
:act_as_principal_activity, :act_as_contest_message
|
||||
# after_create :reset_counters!
|
||||
#after_update :update_activity
|
||||
# after_destroy :reset_counters!
|
||||
|
@ -325,6 +325,23 @@ class JournalsForMessage < ActiveRecord::Base
|
|||
end
|
||||
end
|
||||
|
||||
# 竞赛留言消息通知
|
||||
def act_as_contest_message
|
||||
# 主留言
|
||||
if self.jour_type == 'Contest'
|
||||
if self.m_parent_id.nil?
|
||||
receivers = self.jour.contest_members.select{|cm| cm.roles.to_s.include?("ContestManager") && cm.user_id != self.user_id}
|
||||
receivers.each do |r|
|
||||
self.contest_messages << ContestMessage.new(:user_id => r.user_id, :contest_id => self.jour.id, :viewed => false)
|
||||
end
|
||||
else # 留言回复
|
||||
if self.user_id != self.reply_id # 添加我回复的那个人
|
||||
self.contest_messages << ContestMessage.new(:user_id => self.reply_id, :contest_id => self.jour.id, :viewed => false)
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
# 课程成员得分(活跃度)
|
||||
def act_as_student_score
|
||||
if self.jour_type == "Course"
|
||||
|
|
|
@ -55,6 +55,9 @@ class Member < ActiveRecord::Base
|
|||
if (new_role_ids.include?(7) || new_role_ids.include?(9)) && role_ids.include?(10)
|
||||
member_roles.where("role_id = 10").first.update_column('is_current', 0)
|
||||
end
|
||||
if ids.include?(10) && !ids.include?(7) && !ids.include?(9) && role_ids.include?(10)
|
||||
member_roles.where("role_id = 10").first.update_column('is_current', 1)
|
||||
end
|
||||
# Add new roles
|
||||
if new_role_ids.include?(7) && new_role_ids.include?(10)
|
||||
member_roles << MemberRole.new(:role_id => 7)
|
||||
|
|
|
@ -9,8 +9,8 @@ class StudentsForCourse < ActiveRecord::Base
|
|||
validates_presence_of :course_id, :student_id
|
||||
validates_uniqueness_of :student_id, :scope => :course_id
|
||||
|
||||
after_destroy :delete_student_works
|
||||
after_create :recovery_student_works, :create_student_works
|
||||
after_destroy :delete_student_works, :delete_course_homework_statistic
|
||||
after_create :recovery_student_works, :create_student_works, :create_course_homework_statistic
|
||||
|
||||
#退出班级或删除学生时隐藏学生的作品
|
||||
def delete_student_works
|
||||
|
@ -37,4 +37,41 @@ class StudentsForCourse < ActiveRecord::Base
|
|||
end
|
||||
end
|
||||
end
|
||||
|
||||
#加入班级时创建一条记录
|
||||
def create_course_homework_statistic
|
||||
# if CourseHomeworkStatistic.where(:user_id => self.student_id, :course_id => self.course_id).count == 0
|
||||
# course = self.course
|
||||
# user = self.student
|
||||
# hw_count = course.homework_commons.count
|
||||
# homework_ids = course.homework_commons.empty? ? "(-1)" : "(" + course.homework_commons.map{|hw| hw.id}.join(",") + ")"
|
||||
# student_works = StudentWork.where("homework_common_id in #{homework_ids}")
|
||||
# is_eva_homeworks = course.homework_commons.includes(:homework_detail_manual).where("homework_commons.anonymous_comment = 0 and homework_detail_manuals.comment_status = 2")
|
||||
# is_eva_student_works = StudentWork.where(:homework_common_id => is_eva_homeworks.map{|hw| hw.id})
|
||||
# has_eva_homeworks = course.homework_commons.includes(:homework_detail_manual).where("homework_commons.anonymous_comment = 0 and homework_detail_manuals.comment_status = 3")
|
||||
# has_eva_student_works = StudentWork.where(:homework_common_id => has_eva_homeworks.map{|hw| hw.id})
|
||||
# course.student.each do |student|
|
||||
# user = student.student
|
||||
# if user
|
||||
# committed_work_num = user.student_works.where("homework_common_id in #{homework_ids} and work_status != 0").count
|
||||
# un_commit_work_num = hw_count - committed_work_num
|
||||
# late_commit_work_num = user.student_works.where("homework_common_id in #{homework_ids} and work_status = 2").count
|
||||
# absence_evaluation_work_num = user.student_works_evaluation_distributions.where(:student_work_id => has_eva_student_works.map(&:id)).count -
|
||||
# user.student_works_scores.where(:reviewer_role => 3, :student_work_id => has_eva_student_works.map(&:id)).group_by(&:student_work_id).count
|
||||
# un_evaluation_work_num = user.student_works_evaluation_distributions.where(:student_work_id => is_eva_student_works.map(&:id)).count -
|
||||
# user.student_works_scores.where(:reviewer_role => 3, :student_work_id => is_eva_student_works.map(&:id)).group_by(&:student_work_id).count
|
||||
# appeal_num = user.student_works_scores.where(:student_work_id => student_works.map(&:id), :appeal_status => 3).count
|
||||
# average_score = user.student_works.where(:id => student_works.map(&:id)).select("AVG(student_works.work_score) as score").first ? user.student_works.where(:id => student_works.map(&:id)).select("SUM(student_works.work_score) as score").first.score : 0
|
||||
# total_score = user.student_works.where(:id => student_works.map(&:id)).select("SUM(student_works.work_score) as score").first ? user.student_works.where(:id => student_works.map(&:id)).select("SUM(student_works.work_score) as score").first.score : 0
|
||||
# CourseHomeworkStatistic.create(:course_id => course.id, :user_id => user.id, :committed_work_num => committed_work_num, :un_commit_work_num => un_commit_work_num,
|
||||
# :late_commit_work_num => late_commit_work_num, :absence_evaluation_work_num => absence_evaluation_work_num, :un_evaluation_work_num => un_evaluation_work_num,
|
||||
# :appeal_num => appeal_num, :average_score => average_score, :total_score => total_score)
|
||||
# end
|
||||
# end
|
||||
# end
|
||||
end
|
||||
|
||||
def delete_course_homework_statistic
|
||||
#CourseHomeworkStatistic.where(:user_id => self.student_id, :course_id => self.course_id).destroy_all
|
||||
end
|
||||
end
|
||||
|
|
|
@ -183,6 +183,8 @@ class User < Principal
|
|||
# 课程贡献榜
|
||||
has_many :course_contributor_scores, :dependent => :destroy
|
||||
|
||||
#has_many :course_homework_statistics, :dependent => :destroy
|
||||
|
||||
######added by nie
|
||||
has_many :project_infos, :dependent => :destroy
|
||||
has_one :user_status, :dependent => :destroy
|
||||
|
|
|
@ -1,8 +1,9 @@
|
|||
<a href="javascript:void(0)">
|
||||
<%= image_tag(url_to_avatar(source), id: "avatar_image", :width =>"60", :height =>"60",:alt=>"上传图片", :class => "fl ml5 pro_new_upimg")%>
|
||||
</a>
|
||||
<%#= link_to l(:button_delete_file),{:controller => :avatar,:action => :delete_image,:remote=>true,:source_type=> source.class,:source_id=>source.id},:confirm => l(:text_are_you_sure), :method => :post, :class => "upbtn fl" %>
|
||||
<a href="javascript:void(0)" class="sub_btn fl mt35 ml5" style="line-height: 1.5" onclick="$('#upload_course_logo').click();"><%= l(:button_upload_photo) %></a>
|
||||
<div class="banner-course-avatar fl">
|
||||
<%= image_tag(url_to_avatar(source), id: "avatar_image", :width =>"60", :height =>"60",:alt=>"上传图片", :class => "fl pro_new_upimg")%>
|
||||
<a class="banner-course-inner" href="javascript:void(0)" onclick="$('#upload_course_logo').click();"></a>
|
||||
<a class="banner-course-notice" href="javascript:void(0)" onclick="$('#upload_course_logo').click();">更换图片</a>
|
||||
</div>
|
||||
<a href="javascript:void(0)" class="fl mt45 ml5" style="line-height: 1.5" onclick="$('#upload_course_logo').click();">点击更换</a>
|
||||
<%= file_field_tag 'avatar[image]',
|
||||
:id => 'upload_course_logo',
|
||||
:class => 'undis upload_file',
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
<% if @course %>
|
||||
hideModal();
|
||||
$("#tbc_04").html("<%=escape_javascript(render :partial => 'courses/settings/boards_setting') %>");
|
||||
<% course_board = @course.boards.where("parent_id is NULL").first %>
|
||||
$("#board_children_list").html("<%= escape_javascript(render :partial => 'layouts/board_children_list', :locals => {:course_board => course_board})%>");
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
<% if @course %>
|
||||
hideModal();
|
||||
$("#tbc_04").html("<%=escape_javascript(render :partial => 'courses/settings/boards_setting') %>");
|
||||
<% course_board = @course.boards.where("parent_id is NULL").first %>
|
||||
$("#board_children_list").html("<%= escape_javascript(render :partial => 'layouts/board_children_list', :locals => {:course_board => course_board})%>");
|
||||
|
|
|
@ -1 +1,8 @@
|
|||
$("#contest_message_join_<%=@msg.id %>").html('<%= escape_javascript(render :partial => 'users/join_contest_applied_message', :locals => {:ma => @msg}) %>');
|
||||
$("#contest_message_join_<%=@msg.id %>").html('<%= escape_javascript(render :partial => 'users/join_contest_applied_message', :locals => {:ma => @msg}) %>');
|
||||
$(".messageInformationContents").each(function(){
|
||||
var parentWidth = $(this).parent().width();
|
||||
var eq0Width = $(this).parent().children().eq(0).width();
|
||||
var eq1Width = $(this).parent().children().eq(1).width();
|
||||
var classWidth = parentWidth - eq0Width - eq1Width - 20;
|
||||
$(this).css("max-width",classWidth + "px");
|
||||
});
|
|
@ -1 +0,0 @@
|
|||
$('#course_members_setting').html('<%= escape_javascript(render :partial => 'courses/course_members') %>');
|
|
@ -0,0 +1,137 @@
|
|||
<% if @members.count != 0 %>
|
||||
<table class="muban_table clearfix mb15 t-center" cellpadding="0" cellspacing="0">
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="table-td-w20" >姓名</th>
|
||||
<th class="table-td-w10">
|
||||
<%= link_to '发布资源', course_statistics_course_path(@course, :type => 'resource_num', :order => (@order == "desc" ? "asc" : "desc")), method: 'get', remote: true, :style => 'color:#000000;'%>
|
||||
<% if @type == "resource_num" && @order == 'desc' %>
|
||||
<a href="javascript:" class= "sy_sortupbtn"></a>
|
||||
<% elsif @type == "resource_num" && @order == 'asc' %>
|
||||
<a href="javascript:" class= "sy_sortdownbtn"></a>
|
||||
<% end %>
|
||||
</th>
|
||||
<th class="table-td-w10">
|
||||
<%= link_to '发布帖子', course_statistics_course_path(@course, :type => 'message_num', :order => (@order == "desc" ? "asc" : "desc")), method: 'get', remote: true, :style => 'color:#000000;'%>
|
||||
<% if @type == "message_num" && @order == 'desc' %>
|
||||
<a href="javascript:" class= "sy_sortupbtn"></a>
|
||||
<% elsif @type == "message_num" && @order == 'asc' %>
|
||||
<a href="javascript:" class= "sy_sortdownbtn"></a>
|
||||
<% end %>
|
||||
</th>
|
||||
<th class="table-td-w10">
|
||||
<%= link_to '帖子回复', course_statistics_course_path(@course, :type => 'message_reply_num', :order => (@order == "desc" ? "asc" : "desc")), method: 'get', remote: true, :style => 'color:#000000;'%>
|
||||
<% if @type == "message_reply_num" && @order == 'desc' %>
|
||||
<a href="javascript:" class= "sy_sortupbtn"></a>
|
||||
<% elsif @type == "message_reply_num" && @order == 'asc' %>
|
||||
<a href="javascript:" class= "sy_sortdownbtn"></a>
|
||||
<% end %>
|
||||
</th>
|
||||
<th class="table-td-w10">
|
||||
<%= link_to '发布通知', course_statistics_course_path(@course, :type => 'news_num', :order => (@order == "desc" ? "asc" : "desc")), method: 'get', remote: true, :style => 'color:#000000;'%>
|
||||
<% if @type == "news_num" && @order == 'desc' %>
|
||||
<a href="javascript:" class= "sy_sortupbtn"></a>
|
||||
<% elsif @type == "news_num" && @order == 'asc' %>
|
||||
<a href="javascript:" class= "sy_sortdownbtn"></a>
|
||||
<% end %>
|
||||
</th>
|
||||
<th class="table-td-w10">
|
||||
<%= link_to '通知回复', course_statistics_course_path(@course, :type => 'news_reply_num', :order => (@order == "desc" ? "asc" : "desc")), method: 'get', remote: true, :style => 'color:#000000;'%>
|
||||
<% if @type == "news_reply_num" && @order == 'desc' %>
|
||||
<a href="javascript:" class= "sy_sortupbtn"></a>
|
||||
<% elsif @type == "news_reply_num" && @order == 'asc' %>
|
||||
<a href="javascript:" class= "sy_sortdownbtn"></a>
|
||||
<% end %>
|
||||
</th>
|
||||
<th class="table-td-w10">
|
||||
<%= link_to '作业回复', course_statistics_course_path(@course, :type => 'homework_journal_num', :order => (@order == "desc" ? "asc" : "desc")), method: 'get', remote: true, :style => 'color:#000000;'%>
|
||||
<% if @type == "homework_journal_num" && @order == 'desc' %>
|
||||
<a href="javascript:" class= "sy_sortupbtn"></a>
|
||||
<% elsif @type == "homework_journal_num" && @order == 'asc' %>
|
||||
<a href="javascript:" class= "sy_sortdownbtn"></a>
|
||||
<% end %>
|
||||
</th>
|
||||
<th class="table-td-w10">
|
||||
<%= link_to '班级留言', course_statistics_course_path(@course, :type => 'journal_num', :order => (@order == "desc" ? "asc" : "desc")), method: 'get', remote: true, :style => 'color:#000000;'%>
|
||||
<% if @type == "journal_num" && @order == 'desc' %>
|
||||
<a href="javascript:" class= "sy_sortupbtn"></a>
|
||||
<% elsif @type == "journal_num" && @order == 'asc' %>
|
||||
<a href="javascript:" class= "sy_sortdownbtn"></a>
|
||||
<% end %>
|
||||
</th>
|
||||
<th class="table-td-w10">
|
||||
<%= link_to '活跃度', course_statistics_course_path(@course, :type => 'act_score', :order => (@order == "desc" ? "asc" : "desc")), method: 'get', remote: true, :style => 'color:#000000;'%>
|
||||
<% if @type == "act_score" && @order == 'desc' %>
|
||||
<a href="javascript:" class= "sy_sortupbtn"></a>
|
||||
<% elsif @type == "act_score" && @order == 'asc' %>
|
||||
<a href="javascript:" class= "sy_sortdownbtn"></a>
|
||||
<% end %>
|
||||
</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<% @members.each do |member| %>
|
||||
<tr>
|
||||
<td><%= link_to member.user.show_name, user_path(member.user), :class => 'course_class_users_st_name' %></td>
|
||||
<td><%= member.resource_num %></td>
|
||||
<td><%= member.message_num %></td>
|
||||
<td><%= member.message_reply_num %></td>
|
||||
<td><%= member.news_num %></td>
|
||||
<td><%= member.news_reply_num %></td>
|
||||
<td><%= member.homework_journal_num %></td>
|
||||
<td><%= member.journal_num %></td>
|
||||
<td class="pr">
|
||||
<span><%= member.act_score %></span>
|
||||
<div class="st_tips_box_inner undis" style="text-align:left;">
|
||||
<em></em>
|
||||
<span></span>
|
||||
<p>资源发布数*5=<%= member.resource_num %>*5=<%= member.resource_num.to_i * 5 %><br/>
|
||||
帖子发布数*2=<%= member.message_num %>*2=<%= member.message_num.to_i * 2 %><br/>
|
||||
帖子回复数*1=<%= member.message_reply_num %>*1=<%= member.message_reply_num.to_i * 1 %><br/>
|
||||
通知发布数*1=<%= member.news_num %>*1=<%= member.news_num.to_i * 1 %><br/>
|
||||
通知回复数*1=<%= member.news_reply_num %>*1=<%= member.news_reply_num.to_i * 1 %><br/>
|
||||
作业留言数*1=<%= member.homework_journal_num %>*1=<%= member.homework_journal_num.to_i * 1 %><br/>
|
||||
班级留言数*1=<%= member.journal_num %>*1=<%= member.journal_num.to_i * 1 %><br/>
|
||||
总得分:<%= member.act_score %>
|
||||
</p>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<% end %>
|
||||
</tbody>
|
||||
</table>
|
||||
<div style="text-align:center;">
|
||||
<div class="pages" style="width:auto; display:inline-block;">
|
||||
<ul id="homework_pository_ref_pages">
|
||||
<%= pagination_links_full @mem_pages, @members_count, :per_page_links => false, :remote => @is_remote, :flag => true, :is_new => true%>
|
||||
</ul>
|
||||
<div class="cl"></div>
|
||||
</div>
|
||||
</div>
|
||||
<% else%>
|
||||
<div class="icons_tishi"><img src="/images/sy/icons_smile.png" width="110" height="110" alt="" ></div>
|
||||
<p class="sy_tab_con_p">没有数据可以显示!</p>
|
||||
<% end %>
|
||||
|
||||
<script>
|
||||
$(".muban_table tbody tr").each(function(){
|
||||
$(this).mouseenter(function(){
|
||||
$(".st_tips_box_inner").hide();
|
||||
$(this).children().eq(8).children().eq(1).stop();
|
||||
$(this).children().eq(8).children().eq(1).show();
|
||||
});
|
||||
$(this).mouseleave(function(){
|
||||
$(this).children().eq(8).children().eq(1).delay(500).hide(0);
|
||||
});
|
||||
});
|
||||
|
||||
$(".st_tips_box_inner").each(function(){
|
||||
$(this).mouseover(function(){
|
||||
$(this).stop();
|
||||
$(this).show();
|
||||
});
|
||||
$(this).mouseout(function(){
|
||||
$(this).delay(500).hide(0);
|
||||
});
|
||||
});
|
||||
</script>
|
|
@ -0,0 +1,17 @@
|
|||
<%= content_for(:header_tags) do %>
|
||||
<%= import_ke(enable_at: true, prettify: false, init_activity: true) %>
|
||||
<% end %>
|
||||
|
||||
<%if jours %>
|
||||
<% jours.each do |jour|%>
|
||||
<script type="text/javascript">
|
||||
$(function(){
|
||||
sd_create_editor_from_data(<%= jour.id%>, null, "100%", "<%=jour.class.to_s%>");
|
||||
});
|
||||
</script>
|
||||
<%= render :partial => 'users/course_journalsformessage', :locals => {:activity => jour,:user_activity_id =>jour.id, :is_course => 1} %>
|
||||
<%end%>
|
||||
<% end%>
|
||||
<% if (jours.count + page * 10) < count %>
|
||||
<%= link_to "点击展开更多",course_feedback_path(@course.id, :page => page),:id => "show_more_jours",:remote => "true",:class => "loadMore mt10 f_grey"%>
|
||||
<% end %>
|
|
@ -1,118 +0,0 @@
|
|||
|
||||
<div style="margin-left: 15px">
|
||||
<% if User.current.logged? && User.current.member_of_course?(@course) && @group %>
|
||||
<%= join_in_course_group(@course.course_groups,@group, User.current) unless @canShowCode %>
|
||||
<span style="font-size: 12px; float: left; margin-right: 5px">
|
||||
<%= l(:label_current_group)%>:
|
||||
<%= @group.name %>
|
||||
</span>
|
||||
<% end %>
|
||||
|
||||
|
||||
</div>
|
||||
<div class="cl"></div>
|
||||
<% if members.any? %>
|
||||
<% if @result_count %>
|
||||
<p style="font-size: 18px;">
|
||||
<%= l(:label_search_member_count) %>
|
||||
<%= @result_count %>
|
||||
<%= l(:label_member_people) %>
|
||||
</p>
|
||||
<% end %>
|
||||
<div class="cl"></div>
|
||||
<div class="st_box">
|
||||
<ul class="st_box_top" style="margin-left: 17px;">
|
||||
<% if @subPage_title == l(:label_student_list) %>
|
||||
<li class="ml358">
|
||||
<%= link_to '作业积分', member_score_sort_course_path(:sort_by => (@score_sort_by == "desc" ? "asc" : "desc"), :group_id => (@group ? @group.id : 0),:search_name => (@search_name ? @search_name : nil)) ,:result => members,method: 'get', remote: true%>
|
||||
<% if @score_sort_by == 'desc' %>
|
||||
<a id="pic" href="javascript:void(0)" class= "st_down"></a>
|
||||
<% else %>
|
||||
<a id="pic" href="javascript:void(0)" class= "st_up"></a>
|
||||
<% end %>
|
||||
</li>
|
||||
<li class="ml50">
|
||||
<a href="javascript:" >加入时间</a>
|
||||
</li>
|
||||
<% else %>
|
||||
<li class="ml50">
|
||||
</li>
|
||||
<li class="ml50" style="margin-left: 470px">
|
||||
</li>
|
||||
<li class="ml50" style="margin-left: 80%">
|
||||
<a href="javascript:" >加入时间</a>
|
||||
</li>
|
||||
<% end %>
|
||||
|
||||
</ul>
|
||||
<div id="list_detail" style="margin-left: 17px">
|
||||
<% members.each do |member| %>
|
||||
<div class="cl"></div><!--st_box_top end-->
|
||||
<div class="st_boxlist">
|
||||
|
||||
<a href="javascript:" class="st_img" style="float:left;">
|
||||
<%= member.user.nil? ? '' : (image_tag(url_to_avatar(member.user), :width => 40, :height => 40)) %>
|
||||
</a>
|
||||
<ul style="margin-left: 15px">
|
||||
<% if @canShowCode %>
|
||||
<% if member.user.show_name == '' && member.user.user_extensions.student_id == '' %>
|
||||
<li>
|
||||
<%= l(:label_username)%>
|
||||
<%= link_to(member.user.name, user_path(member.user)) %>
|
||||
</li>
|
||||
<% else %>
|
||||
<% unless member.user.show_name == ''%>
|
||||
<li>
|
||||
<%= l(:label_bidding_user_studentname) %> :
|
||||
<%= link_to member.user.show_name, user_path(member.user) %>
|
||||
</li>
|
||||
</br>
|
||||
<% end %>
|
||||
<% unless member.user.user_extensions.student_id == '' %>
|
||||
<li>
|
||||
<%= l(:label_bidding_user_studentcode) %> :
|
||||
<%= link_to member.user.user_extensions.student_id, user_path(member.user) %>
|
||||
</li>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<%#= content_tag "li", "#{l(:label_bidding_user_studentname)}#{' : '}"link_to(member.user.show_name, user_path(member.user)) %>
|
||||
<% else %>
|
||||
<li>
|
||||
<%= l(:label_username)%>
|
||||
<%= link_to(member.user.name, user_path(member.user)) %>
|
||||
</li>
|
||||
<% end %>
|
||||
<!--teacher's code disapeared moified by huang-->
|
||||
|
||||
|
||||
</ul>
|
||||
<% if @subPage_title == l(:label_student_list) %>
|
||||
<%= link_to format("%0.2f",member.score.nil? ? 0 : member.score.to_s), {
|
||||
:action => 'show_member_score',
|
||||
:member_id => member.id,
|
||||
:remote => true},
|
||||
:class => 'ml258 c_red', :style => "color:red;" %>
|
||||
|
||||
<% unless member.created_on.nil? %>
|
||||
<%= content_tag "span", "#{format_date(member.created_on)}#{l(:label_member_since)}", :class => "ml65 c_grey" %>
|
||||
<% end %>
|
||||
<% else %>
|
||||
<% unless member.created_on.nil? %>
|
||||
<%= content_tag "span", "#{format_date(member.created_on)}#{l(:label_member_since)}", :class => "ml65 c_grey", :style=>"margin-left:195px" %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
|
||||
|
||||
<%= call_hook(:view_projects_settings_members_table_row, { :course => @course, :member => member}) %>
|
||||
</div>
|
||||
<% end; reset_cycle %>
|
||||
</div>
|
||||
</div>
|
||||
<div class="pagination">
|
||||
<%= pagination_links_full @obj_pages, @obj_count,:per_page_links => false, :remote =>@is_remote %>
|
||||
</div>
|
||||
<% else %>
|
||||
<p class="nodata">
|
||||
<%= l(:label_no_data) %>
|
||||
</p>
|
||||
<% end %>
|
|
@ -1,60 +0,0 @@
|
|||
<% members.each do |member| %>
|
||||
|
||||
<div class="cl"></div><!--st_box_top end-->
|
||||
<div class="st_boxlist">
|
||||
<% next if member.new_record? %>
|
||||
|
||||
<a href="javascript:void(0)" class="st_img" style="float:left;"> <%= member.user.nil? ? '' : (image_tag(url_to_avatar(member.user), :width => 40, :height => 40)) %></a>
|
||||
<ul style="margin-left: 15px">
|
||||
<% if @canShowCode %>
|
||||
<% if member.user.show_name == '' && member.user.user_extensions.student_id == '' %>
|
||||
<li>
|
||||
<%= l(:label_username)%>
|
||||
<%= link_to(member.user.name, user_path(member.user)) %>
|
||||
</li>
|
||||
<% else %>
|
||||
<% unless member.user.show_name == ''%>
|
||||
<li>
|
||||
<%= l(:label_bidding_user_studentname) %> :
|
||||
<%= link_to member.user.show_name, user_path(member.user) %>
|
||||
</li>
|
||||
</br>
|
||||
<% end %>
|
||||
<% unless member.user.user_extensions.student_id == '' %>
|
||||
<li>
|
||||
<%= l(:label_bidding_user_studentcode) %> :
|
||||
<%= link_to member.user.user_extensions.student_id, user_path(member.user) %>
|
||||
</li>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<%#= content_tag "li", "#{l(:label_bidding_user_studentname)}#{' : '}"link_to(member.user.show_name, user_path(member.user)) %>
|
||||
<% else %>
|
||||
<li>
|
||||
<%= l(:label_username)%>
|
||||
<%= link_to(member.user.name, user_path(member.user)) %>
|
||||
</li>
|
||||
<% end %>
|
||||
<!--teacher's code disapeared moified by huang-->
|
||||
|
||||
|
||||
</ul>
|
||||
<% if @subPage_title == l(:label_student_list) %>
|
||||
<%= link_to format("%0.2f",member.score.to_s), {
|
||||
:action => 'show_member_score',
|
||||
:member_id => member.id,
|
||||
:remote => true},
|
||||
:class => 'ml258 c_red', :style => "color:red;" %>
|
||||
|
||||
<% unless member.created_on.nil? %>
|
||||
<%= content_tag "span", "#{format_date(member.created_on)}#{l(:label_member_since)}", :class => "ml65 c_grey" %>
|
||||
<% end %>
|
||||
<% else %>
|
||||
<% unless member.created_on.nil? %>
|
||||
<%= content_tag "span", "#{format_date(member.created_on)}#{l(:label_member_since)}", :class => "ml65 c_grey", :style=>"margin-left:195px" %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
|
||||
|
||||
<%= call_hook(:view_projects_settings_members_table_row, { :course => @course, :member => member}) %>
|
||||
</div>
|
||||
<% end; reset_cycle %>
|
|
@ -162,9 +162,8 @@
|
|||
</div>
|
||||
</div>
|
||||
<% else%>
|
||||
<p class="nodata">
|
||||
<%= l(:label_no_data) %>
|
||||
</p>
|
||||
<div class="icons_tishi"><img src="/images/sy/icons_smile.png" width="110" height="110" alt="" ></div>
|
||||
<p class="sy_tab_con_p">没有数据可以显示!</p>
|
||||
<% end %>
|
||||
|
||||
<script>
|
||||
|
|
|
@ -67,6 +67,6 @@
|
|||
<% end %>
|
||||
<% if show_nav?(0) %>
|
||||
<li>
|
||||
<a href="<%=statistics_course_course_path(@course) %>">统计</a>
|
||||
<a href="<%=course_statistics_course_path(@course) %>">统计</a>
|
||||
</li>
|
||||
<% end %>
|
|
@ -0,0 +1,5 @@
|
|||
<div class="sy_class_r ml10">
|
||||
<div class="icons_tishi"><img src="../../images/sy/icons_smile.png" width="110" height="110" alt="" ></div>
|
||||
<p class="sy_tab_con_p">统计功能即将上线,届时我们一起享受教育大数据的红利吧!</p>
|
||||
<div style="height:400px;"></div>
|
||||
</div><!--sy_class_r end-->
|
|
@ -0,0 +1,5 @@
|
|||
<% if !params[:tab] || params[:tab] == "activity" %>
|
||||
$("#act_table_<%=@course.id %>").html("<%= escape_javascript(render :partial => 'act_table')%>");
|
||||
<% else %>
|
||||
|
||||
<% end %>
|
|
@ -1,15 +1,28 @@
|
|||
<% reply_allow = JournalsForMessage.create_by_user? User.current %>
|
||||
<!-- <#%= stylesheet_link_tag 'css', :media => 'all' %> -->
|
||||
<div class="courseRSide fl">
|
||||
<div class="homepageRight mt0 ml10">
|
||||
<div class="homepageRightBanner mb10">
|
||||
<div class="NewsBannerName pr"><span id="mesLabel">班级留言</span></div>
|
||||
</div>
|
||||
<div class="cl"></div>
|
||||
|
||||
<div class="project_r_h" style="width:730px;">
|
||||
<h2 class="project_h2"><%= l(:label_contest_userresponse) %></h2>
|
||||
<div id="messageContent">
|
||||
<div class="resources"><%= link_to image_tag(url_to_avatar(User.current),:class=>"fl mr10", :width => "50", :height => "50"), :alt => "用户头像" %>
|
||||
<div class="fl" style="width:658px;">
|
||||
<%= form_for('new_form',:url => leave_course_message_path(@course.id), :html =>{:id => "course_feedback_new"}, :method => "post") do |f|%>
|
||||
<%= render :partial => "users/jour_form", :locals => {:f => f, :object => @course} %>
|
||||
<input id="private_flag" name="private" type="hidden" value="0"/>
|
||||
<a href="javascript:void(0);" class="blue_n_btn fr mt5" id="submit_feedback_user" >留言</a>
|
||||
<a href="javascript:void(0);" onclick="cancel_jour_submit()" class="greyBtn2 postReplySubmit mt5 mr15">取消</a>
|
||||
<% end %>
|
||||
</div>
|
||||
</div>
|
||||
<%=render :partial => "course_jours_list", :locals => {:jours =>@jours, :page => 0, :count => @jour_count} %>
|
||||
<div class="cl"></div>
|
||||
</div><!--message_box end-->
|
||||
</div>
|
||||
|
||||
|
||||
<%= render :partial => 'courses_jours',
|
||||
:locals => { :contest => @contest, :journals => @jour, :state => false}
|
||||
%>
|
||||
|
||||
<% html_title(l(:label_course_feedback)) -%>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
$(function(){
|
||||
$("#submit_feedback_user").one('click',function() {
|
||||
course_jour_submit();
|
||||
});
|
||||
});
|
||||
</script>
|
|
@ -1 +1 @@
|
|||
$('#course_members_setting').html('<%= escape_javascript(render :partial => 'courses/course_members') %>');
|
||||
$('#tbc_02').html('<%= escape_javascript(render :partial => 'courses/settings/member') %>');
|
||||
|
|
|
@ -5,9 +5,9 @@
|
|||
}
|
||||
<% end %>
|
||||
$("#search_orgs_result_list").html("");
|
||||
$("#search_orgs_result_list").append('<ul class="ml20">');
|
||||
$("#search_orgs_result_list").append('<ul class="sy_new_tchlist ml20">');
|
||||
<% @orgs_not_in_course.each do |org|%>
|
||||
link = "<li><label><input type='checkbox'class='mr5 fl mt3' name='orgNames[]' value='<%=org.id%>'/><span class='relateOrgName fl'> <%=org.name %> </span></label></li><div class='cl mt5'></div>";
|
||||
link = "<li><label><input type='checkbox'class='mr5 fl' name='orgNames[]' style='height:28px' value='<%=org.id%>'/><span class='relateOrgName fl' style='line-height: 28px;'> <%=org.name %> </span></label></li><div class='cl mt5'></div>";
|
||||
$("#search_orgs_result_list").append(link );
|
||||
<%end %>
|
||||
$("#search_orgs_result_list").append('</ul>')
|
||||
|
|
|
@ -1,151 +1,63 @@
|
|||
<div class="courseRSide fl" id="homework_page_right">
|
||||
<div class="project_r_h" style="width:730px;">
|
||||
<h2 class="project_h2"><%= l(:label_course_modify_settings)%></h2>
|
||||
<div class="sy_class_r fr mb10 ml10" id="homework_page_right">
|
||||
<h3 class="game-setting-h3 "><span class="ml15"></span>班级配置</h3>
|
||||
<div class="game-setting-tab">
|
||||
<ul id="game-setting-tab-nav">
|
||||
<li id="tb_1" class="game-setting-nav-hover" onclick="HoverLi(1);">
|
||||
<a href="javascript:void(0);">基本信息</a>
|
||||
</li>
|
||||
<li id="tb_2" onclick="HoverLi(2);">
|
||||
<a href="javascript:void(0);">成员</a>
|
||||
</li>
|
||||
<li id="tb_3" onclick="HoverLi(3);">
|
||||
<a href="javascript:void(0);">组织</a>
|
||||
</li>
|
||||
<li id="tb_4" onclick="HoverLi(4);">
|
||||
<a href="javascript:void(0);">讨论区设置</a>
|
||||
</li>
|
||||
<div class="cl"></div>
|
||||
</ul>
|
||||
|
||||
<div class="hwork_dis" id="tbc_01" style="padding-top: 10px;">
|
||||
<%= render :partial => 'courses/settings/edit' %>
|
||||
</div>
|
||||
|
||||
<div class="hwork_undis" id="tbc_02">
|
||||
<%= render :partial => 'courses/settings/member'%>
|
||||
</div><!---成员结束-->
|
||||
|
||||
<div class="hwork_undis" id="tbc_03">
|
||||
<%= render :partial => 'courses/settings/join_org' %>
|
||||
</div>
|
||||
|
||||
<div class="hwork_undis" id="tbc_04">
|
||||
<%= render :partial => 'courses/settings/boards_setting' %>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
$(function(){
|
||||
var tab = <%= @tab %>;
|
||||
if(tab != 0){
|
||||
course_setting(tab);
|
||||
}
|
||||
<% if @select_tab == 'member'%>
|
||||
$("#tb_2").click();
|
||||
<% elsif @select_tab == 'boards'%>
|
||||
$("#tb_4").click();
|
||||
<% end %>
|
||||
$("#homework_page_right").css("min-height",$("#courseLSide").height()+45);
|
||||
})
|
||||
</script>
|
||||
<div class="hwork_new">
|
||||
<div id="tb_" class="hwork_tb_">
|
||||
<ul>
|
||||
<li id="tb_1" class="hwork_hovertab" onclick="course_setting(1);" >
|
||||
基本信息
|
||||
</li>
|
||||
<li id="tb_2" class="hwork_normaltab" onclick="course_setting(2);">
|
||||
成员
|
||||
</li>
|
||||
<li id="tb_3" class="hwork_normaltab" onclick="course_setting(3);">
|
||||
组织
|
||||
</li>
|
||||
<li id="tb_4" class="hwork_normaltab" onclick="course_setting(4);">
|
||||
讨论区设置
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="hwork_dis" id="tbc_01" style="padding-top: 10px;">
|
||||
<ul>
|
||||
<%= labelled_form_for @course do |f| %>
|
||||
<li class="ml45 mb10" id="course_avatar_form">
|
||||
<%= render :partial => "avatar/new_avatar_form", :locals => {source: @course} %>
|
||||
</li>
|
||||
<li class="ml45 mb10">
|
||||
<label><span class="c_red">*</span> <%= l(:label_tags_syllabus_name)%> :</label>
|
||||
<span id="edit_syllabus_id"><%=@course.syllabus.title %></span>
|
||||
<%#= select_tag :syllabus_id,options_for_select(course_syllabus_option,@course.syllabus_id), {:id=>"edit_syllabus_id", :class=>"syllabus_input", :style=>'width:210px'} %>
|
||||
<!--<span class="c_red" id="edit_syllabus_notice">如果列表中没有对应的课程,请您先<%#=link_to '创建课程', new_syllabus_path(),:target => '_blank', :class => 'ml5 green_btn_share c_white'%>,然后【刷新】</span>-->
|
||||
</li>
|
||||
<li class="ml45">
|
||||
<label><span class="c_red">*</span> <%= l(:label_tags_course_name)%> :</label>
|
||||
<input type="text" name="course[name]" id="edit_course_name" autocomplete="off" class="courses_input" maxlength="100" onkeyup="regex_course_name('edit');" value="<%= @course.name%>">
|
||||
<div class="cl"></div>
|
||||
<span class="c_red ml80" id="edit_course_name_notice" style="display: none;">班级名称不能为空</span>
|
||||
</li>
|
||||
<div class="cl"></div>
|
||||
<li class="ml45">
|
||||
<label><span class="c_red">*</span> <%= l(:label_class_period)%> :</label>
|
||||
<input type="text" name="class_period" id="edit_class_period" class="hwork_input02" onkeyup="regex_course_class_period('edit');" maxlength="6" value="<%= @course.class_period%>">
|
||||
<span class="c_red" id="edit_course_class_period_notice" style="display: none;"></span>
|
||||
</li>
|
||||
<div class="cl"></div>
|
||||
<li class="ml45 mb10">
|
||||
<label><span class="c_red">*</span> <%= l(:label_course_term)%> :</label>
|
||||
<%= select_tag :time,options_for_select(course_time_option(@course.time),@course.time), {:id=>"edit_time"} %>
|
||||
<%= select_tag :term,options_for_select(course_term_option,@course.term || cur_course_term),{:id=>"edit_term"} %>
|
||||
</li>
|
||||
<div class="cl"></div>
|
||||
<li class="ml45 mb10">
|
||||
<label><span class="c_red">*</span> 结束学期 :</label>
|
||||
<%= select_tag :end_time,options_for_select(course_time_option(@course.end_time),@course.end_time), {:id=>"edit_end_time"} %>
|
||||
<%= select_tag :end_term,options_for_select(course_term_option,@course.end_term || cur_course_term),{:id=>"edit_end_term"} %>
|
||||
<span class="c_red" id="edit_course_time_term_notice"></span>
|
||||
</li>
|
||||
<div class="cl"></div>
|
||||
<!--<li class="ml45 mb10">
|
||||
<label><span class="c_red">*</span> <%#= l(:label_new_course_password)%> :</label>
|
||||
<input type="password" name="course[password]" id="edit_course_course_password" class="hwork_input02" value="<%#= @course.password%>" onkeyup="regex_course_password('edit');">
|
||||
<a id="psw_btn" href="javascript:void(0)">显示明码</a>
|
||||
<span class="c_red" id="edit_course_course_password_notice"></span>
|
||||
<div class="cl"></div>
|
||||
<span class=" ml80 c_orange">学生或其他成员申请加入课程时候需要使用该口令,该口令可以由老师在课堂上公布。</span>
|
||||
</li>-->
|
||||
<!--<li class="ml45">-->
|
||||
<!--<label class="fl" > <%#= l(:label_new_course_description)%> :</label>-->
|
||||
<!--<textarea name="course[description]" placeholder="最多3000个汉字(或6000个英文字符)" class="courses_text fl" maxlength="6000"><%#= @course.description%></textarea>-->
|
||||
<!--<div class="cl"></div>-->
|
||||
<!--</li>-->
|
||||
<li class=" mb5 ml80">
|
||||
<label >公开 :</label>
|
||||
<input <%= @course.is_public == 1 ? 'checked' : ''%> id="course_is_public" name="course[is_public]" type="checkbox">
|
||||
<span class="c_grey">(选中后对所有用户可见,否则仅对本班级成员可见)</span>
|
||||
<div class="cl"></div>
|
||||
</li>
|
||||
<li class=" mb5 ml30">
|
||||
<label >学生列表公开 :</label>
|
||||
<input <%= @course.open_student == 1 ? 'checked' : ''%> id="course_open_student" name="course[open_student]" type="checkbox" style="margin-left: 1px;"/>
|
||||
<span class="c_grey">(选中后对所有用户可见,否则仅对本班级成员可见)</span>
|
||||
<div class="cl"></div>
|
||||
</li>
|
||||
<li class=" mb5 ml30">
|
||||
<label >学生上传资源 :</label>
|
||||
<input <%= @course.publish_resource == 1 ? 'checked' : ''%> id="course_publish_resource" name="course[publish_resource]" type="checkbox" style="margin-left: 1px;"/>
|
||||
<span class="c_grey">(选中后允许学生上传班级资源,否则不允许)</span>
|
||||
<div class="cl"></div>
|
||||
</li>
|
||||
<li class="mt10 ml90" >
|
||||
<a href="javascript:void(0)" class="blue_btn fl c_white" onclick="submit_edit_course(<%= @course.id%>);" >提交</a>
|
||||
<%= link_to l(:button_cancel), course_path(@course), :class => "grey_btn fl c_white ml10" %>
|
||||
<div class="cl"></div>
|
||||
</li>
|
||||
<% end %>
|
||||
</ul>
|
||||
<% if @course.is_delete == 1 %>
|
||||
<div class="mt30"><%=link_to "恢复该班级", renew_course_path(@course) %></div>
|
||||
<% else %>
|
||||
<div class="mt30">
|
||||
<img src="/images/pic_del.gif" class="mr5"><%=link_to "删除该班级", course_path(@course), :method => :delete, :confirm=>"确认要删除该班级吗?" %>
|
||||
<span>(友情提示:删除该班级后如果您想恢复该班级,请联系系统管理员!)</span>
|
||||
</div>
|
||||
<% end %>
|
||||
});
|
||||
|
||||
</div>
|
||||
function g(o){
|
||||
return document.getElementById(o);
|
||||
}
|
||||
function HoverLi(n){
|
||||
//如果有N个标签,就将i<=N;
|
||||
for(var i=1;i<=4;i++){
|
||||
g('tb_'+i).className='game-setting-nav-nomall';
|
||||
g('tbc_0'+i).className='undis';
|
||||
}
|
||||
g('tb_'+n).className='game-setting-nav-hover';
|
||||
g('tbc_0'+n).className='game-dis';
|
||||
}
|
||||
|
||||
<div class="hwork_undis" id="tbc_02">
|
||||
<div class="search_course fl">
|
||||
<%= form_tag(search_member_course_path,:id => "course_member_search_form", :method => :get, :class => "search_form_course",:remote => true) do %>
|
||||
<!-- , :onkeyup => "regexQ('#{l(:label_search_conditions_not_null)}');" -->
|
||||
<%= text_field_tag 'name', params[:name], :placeholder => "登录名、学号、姓名搜索", :class => "search_text fl" %>
|
||||
<a href="javascript:void(0)" onclick="submitMemberSerch('<%= l(:label_search_conditions_not_null) %>');" class="search_btn fl f14 c_white ml10" >
|
||||
<%= l(:label_search)%>
|
||||
</a>
|
||||
<br />
|
||||
<span id="course_member_name_span" style="float: left"></span>
|
||||
<% end %>
|
||||
</div>
|
||||
|
||||
<div id="course_members_setting">
|
||||
<%= render :partial => "course_members" %>
|
||||
</div>
|
||||
</div><!---成员结束-->
|
||||
|
||||
<div class="hwork_undis" id="tbc_03">
|
||||
<%= render :partial => 'courses/settings/join_org' %>
|
||||
</div>
|
||||
|
||||
<div class="hwork_undis" id="tbc_04">
|
||||
<%= render :partial => 'courses/settings/boards_setting' %>
|
||||
</div>
|
||||
</div><!--talknew end-->
|
||||
<div class="cl"></div>
|
||||
<script type="text/javascript">
|
||||
function select() {
|
||||
$('#ajax-modal').html('<%= escape_javascript(render :partial => 'courses/term_select') %>');
|
||||
showModal('ajax-modal', '500px');
|
||||
|
@ -155,7 +67,4 @@
|
|||
$('#ajax-modal').parent().css("top","").css("left","").css("border","3px solid #269ac9");
|
||||
$('#ajax-modal').parent().addClass("anonymos");
|
||||
}
|
||||
//$("#time").click(select);
|
||||
//$("#term").click(select);
|
||||
</script>
|
||||
</div>
|
||||
</script>
|
|
@ -1,12 +1,8 @@
|
|||
<ul>
|
||||
<li><span class="relatedListName fb fl">名称</span><span class="relatedListOption fb fl">操作</span></li>
|
||||
<% orgs.each do |org| %>
|
||||
<li>
|
||||
<a href="<%= organization_path(org) %>" class="relatedListName linkBlue fl"><%= org.name %></a>
|
||||
<a href="javascript:void(0);" onclick="cancel_org_course_relation(<%= OrgCourse.where(:organization_id => org.id, :course_id => course_id).first.id %>, '<%= course_id %>');"
|
||||
class = "relatedListOption fl linkGrey3">取消关联</a>
|
||||
<%#= link_to "取消关联", org_course_path(:id => OrgCourse.where(:organization_id => org.id, :course_id => course_id).first.id, :course_id => course_id),
|
||||
:method => 'delete',:remote => true, :class => "relatedListOption fl linkGrey3" %>
|
||||
<li class="clear mb5">
|
||||
<a href="<%= organization_path(org) %>" title="<%= org.name %>" style="max-width: 250px;" class="hidden fl"><%= org.name %></a>
|
||||
<a href = "javascript:void(0);" onclick="delete_confirm_box_2('<%= org_course_path(OrgCourse.where(:organization_id => org.id, :course_id => course_id).first.id, :course_id => course_id) %>', '确定取消关联吗?')" class="fr sy_btn_grey_mini ml5" >取消关联</a>
|
||||
</li>
|
||||
<% end %>
|
||||
</ul>
|
|
@ -1,67 +1,59 @@
|
|||
<% board = @course.boards.where("parent_id is NULL").first %>
|
||||
<div class="w730 mt10" id="org_subfield_list">
|
||||
<ul class="orgListRow borderBottomNone orgListBg">
|
||||
<li class="w270 fb fl"><span class="ml15">名称</span></li>
|
||||
<li class="w140 fb fl">状态</li>
|
||||
<li class="w170 fb fl">类型</li>
|
||||
<li class="w150 fb fl"><span class="mr15 fr">操作</span></li>
|
||||
<div class="cl"></div>
|
||||
</ul>
|
||||
<ul class="orgListRow">
|
||||
<li class="w270 fl"> <span class="ml15">班级讨论区</span> </li>
|
||||
<li class="w140 fl">默认</li>
|
||||
<li class="w170 fl">帖子</li>
|
||||
<li class="w150 fl"> <a href="javascript:void(0)" class="link-blue fr mr15" id="addSubMenu">添加子栏目</a> </li>
|
||||
<div class="cl"></div>
|
||||
<% count = board.children.count %>
|
||||
<% board.children.reorder("position asc").each_with_index do |board, i|%>
|
||||
<ul class="orgSubList" style="border-top: 1px solid rgb(228, 228, 228);">
|
||||
<li class="<%= i == count - 1 ? 'orgSubTree2' : 'orgSubTree' %>"></li>
|
||||
<li class="w210 mr10 fl">
|
||||
<div id="board_sub_show_<%= board.id %>" class="w210 hidden" title="<%=board.name %>"><%=board.name %></div>
|
||||
<div id="board_sub_edit_<%= board.id %>" style="display:none;">
|
||||
<input type="text" name="name" onblur="update_sub_board_name('#board_sub_show_<%= board.id %>','#board_sub_edit_<%= board.id %>','<%= board.id %>','<%= @course.id %>',$(this).val());" value="<%= board.name %>" style="width:140px;"/>
|
||||
</div>
|
||||
</li>
|
||||
<li class="w140 fl">新增</li>
|
||||
<li class="w170 fl">帖子</li>
|
||||
<li class="w150 fl">
|
||||
<a href="javascript:void(0);" class="linkGrey fr ml5 mr15" onclick="edit('#board_sub_show_<%= board.id %>','#board_sub_edit_<%= board.id %>');">编辑</a>
|
||||
<%= link_to('删除', {:controller => 'boards', :action => 'destroy', :id => board.id, :course_id => @course.id},:remote => true, :method => 'delete', :confirm => l(:text_are_you_sure), :class => "linkGrey fr ml5 mr5", :title => l(:button_delete)) %>
|
||||
<% if i < count - 1 %>
|
||||
<%= link_to('下移', {:controller => 'boards', :action => 'update_position', :id => board.id, :course_id => @course.id, :opr => 'down'},:remote => true, :method => 'post', :class => "linkGrey fr ml5 mr5", :title => '下移') %>
|
||||
<% end %>
|
||||
<% unless i == 0 %>
|
||||
<%= link_to('上移', {:controller => 'boards', :action => 'update_position', :id => board.id, :course_id => @course.id, :opr => 'up'},:remote => true, :method => 'post', :class => "linkGrey fr ml5 mr5", :title => '上移') %>
|
||||
<% end %>
|
||||
<div class="pro_new_setting_conbox" style="width:100%; border:none;">
|
||||
<div class="sy_new_tchbox clear undis" style="margin-left:10px; margin-right:10px;" id="add_sub_board">
|
||||
<%= form_tag url_for(:controller => 'boards', :action => 'create', :course_id => @course.id, :board_id => board.id), :id=> 'add_board_form_subboard',:remote => true do %>
|
||||
<ul class="pro_newsetting_con mb15">
|
||||
<li>
|
||||
<label class="fl">新增子栏目名称 : </label>
|
||||
<input id="subfield_name" name="name" placeholder="请输入子栏目名称" maxlength="30" class="fl h28" style="width: 420px" type="text">
|
||||
<a href="javascript:void(0);" class="fr sy_btn_grey" onclick="$('#add_sub_board').toggle();">取消</a>
|
||||
<a href="javascript:void(0);" class="fr sy_btn_blue mr5" id="subMenuSubmit">保存</a>
|
||||
</li>
|
||||
<div class="cl"></div>
|
||||
<span id="new_notice" class="undis fl c_red">名称不能为空</span>
|
||||
</ul>
|
||||
|
||||
<% end %>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="clear ml10 mr10">
|
||||
<table class="sy_new_table clearfix mb15" cellpadding="0" cellspacing="0">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>名称</th>
|
||||
<th style="width:280px;">操作</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td class="game-text-left"><span class="ml20"></span>班级讨论区</td>
|
||||
<td class="game-text-right"><a href="javascript:void(0);" class="sy_btn_green mr5" onclick="$('#add_sub_board').toggle();">添加子栏目</a></td>
|
||||
</tr>
|
||||
<% count = board.children.count %>
|
||||
<% board.children.reorder("position asc").each_with_index do |board, i|%>
|
||||
<tr>
|
||||
<td class="game-text-left">
|
||||
<div id="board_sub_show_<%= board.id %>" class="ml40 w350 hidden" title="<%=board.name %>"><%=board.name %></div>
|
||||
<div id="board_sub_edit_<%= board.id %>" style="display:none;" class="ml40">
|
||||
<input type="text" name="name" class="h28 w300" id="board_sub_name_<%=board.id %>" maxlength="30"
|
||||
onblur="update_sub_board_name('#board_sub_show_<%= board.id %>','#board_sub_edit_<%= board.id %>','<%= board.id %>','<%= @course.id %>',$(this).val());" value="<%= board.name %>"/>
|
||||
</div>
|
||||
</td>
|
||||
<td class="game-text-right">
|
||||
<% unless i == 0 %>
|
||||
<%= link_to('上移', {:controller => 'boards', :action => 'update_position', :id => board.id, :course_id => @course.id, :opr => 'up'},:remote => true, :method => 'post', :class => "sy_btn_blue mr5", :title => '上移') %>
|
||||
<% end %>
|
||||
<% if i < count - 1 %>
|
||||
<%= link_to('下移', {:controller => 'boards', :action => 'update_position', :id => board.id, :course_id => @course.id, :opr => 'down'},:remote => true, :method => 'post', :class => "sy_btn_blue mr5", :title => '下移') %>
|
||||
<% end %>
|
||||
<a href="javascript:void(0);" class="sy_btn_blue mr5" onclick="edit('#board_sub_show_<%= board.id %>','#board_sub_edit_<%= board.id %>');">编辑</a>
|
||||
<a href="javascript:void(0);" class="sy_btn_blue mr5" onclick="delete_confirm_box_2('<%=course_board_path(board, :course_id => @course.id) %>', '确定要删除<%=board.name %>吗?')">删除</a>
|
||||
</td>
|
||||
</tr>
|
||||
<% end %>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<!--新增二级栏目-->
|
||||
<div class="mt10 fl orgListBg w730 undis" id="subMenuContent">
|
||||
<%= form_tag url_for(:controller => 'boards', :action => 'create', :course_id => @course.id, :board_id => board.id), :id=> 'add_board_form_subboard',:remote => true do %>
|
||||
<div class="ml15 mt10">
|
||||
<span class="fontGrey3 mb5 mr10">新增子栏目名称 :</span>
|
||||
<input id="subfield_name" name="name" placeholder="请输入子栏目名称" maxlength="30" class="orgAddSearch mb10" type="text">
|
||||
<span id="new_notice" class="undis ml10">名称不能为空</span>
|
||||
</div>
|
||||
<div class="mb10">
|
||||
<span class="fontGrey3 ml50 mr15 fl">栏目类型 :</span>
|
||||
<input class="mr5" id="orgMng" value="Post" name="field_type" checked="checked" type="radio">
|
||||
<label for="orgMng">帖子</label>
|
||||
</div>
|
||||
<div class="mb10">
|
||||
<a href="javascript:void(0);" class="grey_btn_cir fr c_white mr15 ml15" id="subMenuCancel">取消</a>
|
||||
<a href="javascript:void(0);" class="blue_btn_cir fr c_white" id="subMenuSubmit">确定</a>
|
||||
<div class="cl"></div>
|
||||
</div>
|
||||
</form>
|
||||
<% end %>
|
||||
</div>
|
||||
<!--over-->
|
||||
|
||||
<script>
|
||||
$(function(){
|
||||
|
@ -80,28 +72,31 @@
|
|||
});
|
||||
}
|
||||
}
|
||||
$("#addSubMenu").click(function(){
|
||||
$("#subMenuContent").toggle();
|
||||
});
|
||||
$("#subMenuCancel").click(function(){
|
||||
$("#subMenuContent").hide();
|
||||
});
|
||||
|
||||
function update_sub_board_name(show_id, edit_id, field_id, domain_id, input_value) {
|
||||
if (input_value.trim() != "" && $(show_id).html().trim() != input_value.trim()) {
|
||||
if (confirm('确定修改为' + input_value + "?"))
|
||||
$.ajax({
|
||||
url: "/boards/" + field_id + "/update_name?course_id=" + domain_id + "&name=" + input_value,
|
||||
type: 'put'
|
||||
});
|
||||
else{
|
||||
$(edit_id).children("input").val($(show_id).html().trim());
|
||||
}
|
||||
var htmlvalue = '<div id="muban_popup_box" style="width:300px;"><div class="muban_popup_top"><h3 class="fl">提示</h3><a href="javascript:void(0);" class="muban_icons_close fr"></a></div>'+
|
||||
'<div class="clear mt15"><p class="text_c f16 fontGrey7">确定修改为' + input_value + '?</p><div class="cl"></div><a href="javascript:void(0)" class="fr sy_btn_blue mt10"' +
|
||||
' style="margin-right: 92px;" onclick="update_confirm(1,' + field_id + ',' + domain_id + ');">确定</a>'+
|
||||
'<a href="javascript:void(0);" class="fr sy_btn_grey mt10 mr10" onclick="update_confirm(2,' + field_id + ',' + domain_id + ');">取消</a></div></div>';
|
||||
pop_box_new(htmlvalue, 300, 140);
|
||||
}
|
||||
$(show_id).show();
|
||||
$(edit_id).hide();
|
||||
}
|
||||
|
||||
function update_confirm(type, field_id, domain_id){
|
||||
if(type == 1){
|
||||
$.ajax({
|
||||
url: "/boards/" + field_id + "/update_name?course_id=" + domain_id + "&name=" + $("#board_sub_name_"+field_id).val(),
|
||||
type: 'put'
|
||||
});
|
||||
} else {
|
||||
hideModal();
|
||||
$("#board_sub_edit_"+field_id).children("input").val($("#board_sub_show_"+field_id).html().trim());
|
||||
}
|
||||
}
|
||||
|
||||
function edit(show_id, edit_id) {
|
||||
$(show_id).toggle();
|
||||
$(edit_id).toggle();
|
||||
|
|
|
@ -0,0 +1,90 @@
|
|||
<table class="sy_new_table clearfix mb15" cellpadding="0" cellspacing="0">
|
||||
<thead>
|
||||
<tr>
|
||||
<th style="width: 35px;">序号</th>
|
||||
<th style="width:180px;">姓名</th>
|
||||
<th style="width:140px;">学号</th>
|
||||
<th>角色</th>
|
||||
<th class="sy_new_namebox">操作</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<% @members.each_with_index do |member, index| %>
|
||||
<tr>
|
||||
<td><%= index + 1 %></td>
|
||||
<td>
|
||||
<%= link_to member.user.show_name, user_path(member.user), :class => "pro_new_idname ml10 mr10", :title => "#{member.user.show_name}" %>
|
||||
</td>
|
||||
<td>
|
||||
<span class="pro_new_school_name ml5 mr5"><%=member.user.user_extensions.student_id %></span>
|
||||
</td>
|
||||
<td style="width: 200px">
|
||||
<span id="member_role_<%=member.id %>"><%= zh_course_role(h member.roles.sort.collect(&:to_s).join(', ')) %></span>
|
||||
<%= form_for(member, {:as => :membership, :remote => true, :url => membership_path(member),
|
||||
:method => :put,
|
||||
:html => {:id => "member-#{member.id}-roles-form", :class => 'hol'}}
|
||||
) do |f| %>
|
||||
<ul class="clear ml15">
|
||||
<script>
|
||||
$(function() {
|
||||
$("#edit_member_role_<%=member.id %>_7").on('click', function(){
|
||||
if($("#edit_member_role_<%=member.id %>_7").is(":checked")) {
|
||||
$("#edit_member_role_<%=member.id %>_9").attr("checked",false);
|
||||
$("#edit_member_role_<%=member.id %>_9").attr('disabled', 'disabled');
|
||||
} else {
|
||||
$("#edit_member_role_<%=member.id %>_9").removeAttr('disabled');
|
||||
}
|
||||
});
|
||||
$("#edit_member_role_<%=member.id %>_9").on('click', function(){
|
||||
if($("#edit_member_role_<%=member.id %>_9").is(":checked")) {
|
||||
$("#edit_member_role_<%=member.id %>_7").attr('disabled', 'disabled');
|
||||
$("#edit_member_role_<%=member.id %>_7").attr("checked",false);
|
||||
} else {
|
||||
$("#edit_member_role_<%=member.id %>_7").removeAttr('disabled');
|
||||
}
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<% @roles.each do |role| %>
|
||||
<li class="fl mr5">
|
||||
<!--<label style="width: 54px;">-->
|
||||
<%= check_box_tag 'membership[role_ids][]', role.id, member.roles.include?(role), :id => "edit_member_role_#{member.id}_#{role.id}",
|
||||
:disabled => member.member_roles.detect {|mr| mr.role_id == role.id && !mr.inherited_from.nil?}, :class => "mt6 fl h28" %>
|
||||
<p class="fl ml5"><%= zh_course_role(h role) %></p>
|
||||
<!--</label>-->
|
||||
</li>
|
||||
<% end %>
|
||||
<%= hidden_field_tag 'membership[role_ids][]', '' %>
|
||||
</ul>
|
||||
<% end %>
|
||||
</td>
|
||||
<td>
|
||||
<% unless member.user == @course.teacher %>
|
||||
<a href="javascript:void(0)" class="sy_btn_blue mr5" onclick="edit_member($(this), <%=member.id %>);">编辑</a>
|
||||
<a href="javascript:void(0)" class="sy_btn_blue mr5" style="display: none;" onclick="$('#member-<%= member.id%>-roles-form').submit();">保存</a>
|
||||
<a href="javascript:void(0)" class="sy_btn_grey mr5" style="display: none;" onclick="cancel_edit($(this), <%=member.id %>);">取消</a>
|
||||
<a href="javascript:void(0)" class="sy_btn_grey mr5" id="delete_member_<%=member.id %>" onclick="delete_confirm_box_2('<%=membership_path(member) %>', '<%= l(:label_delete_confirm)%>')">删除</a>
|
||||
<% end %>
|
||||
</td>
|
||||
</tr>
|
||||
<% end %>
|
||||
</tbody>
|
||||
</table>
|
||||
<script>
|
||||
function edit_member(div, id){
|
||||
$('#member_role_' + id).hide();
|
||||
$('#member-' + id + '-roles-form').show();
|
||||
$(div).next().show();
|
||||
$(div).next().next().show();
|
||||
$('#delete_member_' + id).hide();
|
||||
$(div).hide();
|
||||
}
|
||||
function cancel_edit(div, id){
|
||||
$('#member_role_' + id).show();
|
||||
$('#member-' + id + '-roles-form').hide();
|
||||
$(div).prev().hide();
|
||||
$(div).prev().prev().show();
|
||||
$('#delete_member_' + id).show();
|
||||
$(div).hide();
|
||||
}
|
||||
</script>
|
|
@ -0,0 +1,72 @@
|
|||
<ul>
|
||||
<%= labelled_form_for @course do |f| %>
|
||||
<li class="ml45 mb10" id="course_avatar_form">
|
||||
<%= render :partial => "avatar/new_avatar_form", :locals => {source: @course} %>
|
||||
</li>
|
||||
<li class="ml45 mb10">
|
||||
<label><span class="c_red">*</span> <%= l(:label_tags_syllabus_name)%> :</label>
|
||||
<span id="edit_syllabus_id"><%=@course.syllabus.title %></span>
|
||||
<%#= select_tag :syllabus_id,options_for_select(course_syllabus_option,@course.syllabus_id), {:id=>"edit_syllabus_id", :class=>"syllabus_input", :style=>'width:210px'} %>
|
||||
<!--<span class="c_red" id="edit_syllabus_notice">如果列表中没有对应的课程,请您先<%#=link_to '创建课程', new_syllabus_path(),:target => '_blank', :class => 'ml5 green_btn_share c_white'%>,然后【刷新】</span>-->
|
||||
</li>
|
||||
<li class="ml45">
|
||||
<label><span class="c_red">*</span> <%= l(:label_tags_course_name)%> :</label>
|
||||
<input type="text" name="course[name]" id="edit_course_name" autocomplete="off" class="courses_input" maxlength="100" onkeyup="regex_course_name('edit');" value="<%= @course.name%>">
|
||||
<div class="cl"></div>
|
||||
<span class="c_red ml80" id="edit_course_name_notice" style="display: none;">班级名称不能为空</span>
|
||||
</li>
|
||||
<div class="cl"></div>
|
||||
<li class="mb5 fontGrey3" style="margin-left: 125px;"><span class="success-icon mr25">正确示例:软件工程计算机系2016秋季A班</span></li>
|
||||
<li class="mb10 fontGrey3" style="margin-left: 125px;"><span class="error-icon">错误示例:计算机系2016秋季A班</span></li>
|
||||
<li class="ml45">
|
||||
<label><span class="c_red">*</span> <%= l(:label_class_period)%> :</label>
|
||||
<input type="text" name="class_period" id="edit_class_period" class="hwork_input02 w290" onkeyup="regex_course_class_period('edit');" maxlength="6" value="<%= @course.class_period%>">
|
||||
<span class="c_red" id="edit_course_class_period_notice" style="display: none;"></span>
|
||||
</li>
|
||||
<div class="cl"></div>
|
||||
<li class="ml45 mb10">
|
||||
<label><span class="c_red">*</span> <%= l(:label_course_term)%> :</label>
|
||||
<%= select_tag :time,options_for_select(course_time_option(@course.time),@course.time), {:id=>"edit_time", :class => "h28 w145 mr8"} %>
|
||||
<%= select_tag :term,options_for_select(course_term_option,@course.term || cur_course_term),{:id=>"edit_term", :class => "h28 w145"} %>
|
||||
</li>
|
||||
<div class="cl"></div>
|
||||
<li class="ml45 mb10">
|
||||
<label><span class="c_red">*</span> 结束学期 :</label>
|
||||
<%= select_tag :end_time,options_for_select(course_time_option(@course.end_time),@course.end_time), {:id=>"edit_end_time", :class => "h28 w145 mr8"} %>
|
||||
<%= select_tag :end_term,options_for_select(course_term_option,@course.end_term || cur_course_term),{:id=>"edit_end_term", :class => "h28 w145"} %>
|
||||
<span class="c_red" id="edit_course_time_term_notice"></span>
|
||||
</li>
|
||||
<div class="cl"></div>
|
||||
<li class=" mb5 ml80">
|
||||
<label >公开 :</label>
|
||||
<input <%= @course.is_public == 1 ? 'checked' : ''%> id="course_is_public" name="course[is_public]" type="checkbox">
|
||||
<span class="c_grey">(选中后对所有用户可见,否则仅对本班级成员可见)</span>
|
||||
<div class="cl"></div>
|
||||
</li>
|
||||
<li class=" mb5 ml30">
|
||||
<label >学生列表公开 :</label>
|
||||
<input <%= @course.open_student == 1 ? 'checked' : ''%> id="course_open_student" name="course[open_student]" type="checkbox" style="margin-left: 1px;"/>
|
||||
<span class="c_grey">(选中后对所有用户可见,否则仅对本班级成员可见)</span>
|
||||
<div class="cl"></div>
|
||||
</li>
|
||||
<li class=" mb5 ml30">
|
||||
<label >学生上传资源 :</label>
|
||||
<input <%= @course.publish_resource == 1 ? 'checked' : ''%> id="course_publish_resource" name="course[publish_resource]" type="checkbox" style="margin-left: 1px;"/>
|
||||
<span class="c_grey">(选中后允许学生上传班级资源,否则不允许)</span>
|
||||
<div class="cl"></div>
|
||||
</li>
|
||||
<li class="mt10" style="margin-left: 125px;">
|
||||
<a href="javascript:void(0)" class="blue_btn fl c_white" onclick="submit_edit_course(<%= @course.id%>);" >提交</a>
|
||||
<%= link_to l(:button_cancel), course_path(@course), :class => "grey_btn fl c_white ml10" %>
|
||||
<div class="cl"></div>
|
||||
</li>
|
||||
<% end %>
|
||||
</ul>
|
||||
<% if @course.is_delete == 1 %>
|
||||
<div class="mt30 ml30"><%=link_to "恢复该班级", renew_course_path(@course) %></div>
|
||||
<% else %>
|
||||
<div class="mt30 ml30">
|
||||
<img src="/images/pic_del.gif" class="mr5"><%=link_to "删除该班级", course_path(@course), :method => :delete, :confirm=>"确认要删除该班级吗?" %>
|
||||
<span>(友情提示:删除该班级后如果您想恢复该班级,请联系系统管理员!)</span>
|
||||
</div>
|
||||
<% end %>
|
|
@ -1,85 +1,84 @@
|
|||
<!--<div class="members_left">-->
|
||||
<!--<input type="text" id="orgs_not_course_member_search" name="orgAddSearch" placeholder="支持姓名、邮箱、昵称搜索" class="orgAddSearch mb20" />-->
|
||||
<!--<%#= javascript_tag "observeSearchfield('orgs_not_course_member_search', null, '#{ escape_javascript autocomplete_search_organizations_path(:course_id=> @course.id, :format => 'js') }')" %>-->
|
||||
<!--<div id="new_orgs_for_course">-->
|
||||
|
||||
<!--</div>-->
|
||||
<!--</div>-->
|
||||
<%= stylesheet_link_tag 'css/org' %>
|
||||
|
||||
<div>
|
||||
<div class="relateOrg fl">
|
||||
<span class="pic_add fl mr5 mt3"></span><span class="f14 fontBlue fl">关联组织</span>
|
||||
<div class="cl mb5"></div>
|
||||
<%= form_tag url_for(:controller => 'org_courses', :action => 'create', :course_id => @course.id), :id => 'join_orgs_for_course', :remote => true do %>
|
||||
<input type="text" name="orgs" class="searchOrg mb5 ml20" placeholder="请输入组织名称" />
|
||||
<div id="search_orgs_result_list" class="ml20"></div>
|
||||
<ul id="paginator" class="wlist ml20" style="float:none;"></ul>
|
||||
<a href="javascript:void(0);" class="saveBtn db fl ml20 mr15 mt5" onclick="course_join_org(<%= @course.id %>);">关联</a>
|
||||
<a href="javascript:void(0);" class="org-cancel-btn db fl mt5" onclick="cancel_join_orgs();">取消</a>
|
||||
<% end %>
|
||||
</div>
|
||||
<div class="relatedList fr">
|
||||
<div class="fr mr15">
|
||||
<span class="f14 fontBlue">已关联组织</span>
|
||||
<div id="added_orgs">
|
||||
<%= render :partial => 'courses/settings/added_orgs', :locals => {:orgs => @course.organizations, :course_id => params[:id]} %>
|
||||
</div>
|
||||
<div>
|
||||
</div>
|
||||
<% if @orgs_not_in_course.empty? && @course.organizations.empty? %>
|
||||
<div class="icons_tishi"><img src="/images/new_project/icons_smile.png" width="110" height="110" alt="" ></div>
|
||||
<p class="sy_tab_con_p">您没有创建组织,请先 <%=link_to '新建组织', new_organization_path, :class => 'sy_btn_green', :target => '_blank' %>,再关联</p>
|
||||
<% else %>
|
||||
<div class="sy_new_tchbox clear mt10">
|
||||
<div class="course_setting_org_fl fl">
|
||||
<h3 class="mb10 fl" style="color: #8f8f8f;">关联组织</h3>
|
||||
<div class="cl mb5"></div>
|
||||
<%= form_tag url_for(:controller => 'org_courses', :action => 'create', :course_id => @course.id), :id => 'join_orgs_for_course', :remote => true do %>
|
||||
<input type="text" name="orgs" class="sy_new_search" style="height: 28px; width: 300px;" placeholder="请输入组织名称" />
|
||||
<div class="cl mb5"></div>
|
||||
<div id="search_orgs_result_list" ></div>
|
||||
<ul id="paginator" class="wlist ml20" style="float:none;"></ul>
|
||||
<a href="javascript:void(0);" class="fl sy_btn_blue mr5" onclick="course_join_org(<%= @course.id %>);">关联</a>
|
||||
<a href="javascript:void(0);" class="fl sy_btn_grey mr5" onclick="cancel_join_orgs();">取消</a>
|
||||
|
||||
<% end %>
|
||||
</div>
|
||||
<div class="course_setting_org_fr fr">
|
||||
<h3 class="mb20" style="color: #8f8f8f;">已关联组织</h3>
|
||||
<ul>
|
||||
<div id="added_orgs">
|
||||
<%= render :partial => 'courses/settings/added_orgs', :locals => {:orgs => @course.organizations, :course_id => @course.id} %>
|
||||
</div>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script type="text/javascript">
|
||||
var lastSearchCondition = '';
|
||||
var page = 1;
|
||||
var count = 0;
|
||||
var maxPage = 0;
|
||||
function search_orgs(e){
|
||||
if($(e.target).val().trim() == lastSearchCondition && lastSearchCondition != '')
|
||||
{
|
||||
return;
|
||||
}
|
||||
lastSearchCondition = $(e.target).val().trim();
|
||||
page = 1;
|
||||
$.ajax({
|
||||
url: '<%= url_for(:controller => 'courses', :action => 'search_public_orgs_not_in_course') %>'+'?name='+ e.target.value+'&page='+page,
|
||||
type:'get'
|
||||
});
|
||||
}
|
||||
|
||||
function throttle(method,context,e){
|
||||
clearTimeout(method.tId);
|
||||
method.tId=setTimeout(function(){
|
||||
method.call(context,e);
|
||||
},500);
|
||||
}
|
||||
|
||||
//查询组织
|
||||
$("input[name='orgs']").on('input', function (e) {
|
||||
throttle(search_orgs,window,e);
|
||||
});
|
||||
|
||||
$(document).ready(function(){
|
||||
$.ajax({
|
||||
url: '<%= url_for(:controller => 'courses', :action => 'search_public_orgs_not_in_course') %>'+'?page=1',
|
||||
type:'get'
|
||||
});
|
||||
});
|
||||
function cancel_join_orgs() {
|
||||
$("#join_orgs_for_course input:checked").attr("checked", false);
|
||||
}
|
||||
function course_join_org(courseId) {
|
||||
$.ajax({
|
||||
url: "/org_courses?" + $("#join_orgs_for_course").serialize() + "&course_id=" + courseId,
|
||||
type: "post",
|
||||
success: function (data) {
|
||||
$.ajax({
|
||||
url: "/courses/" + courseId + "/search_public_orgs_not_in_course?hint_flag=true&name=" + $("input[name='orgs']").val().trim(),
|
||||
type: "get"
|
||||
});
|
||||
<script type="text/javascript">
|
||||
var lastSearchCondition = '';
|
||||
var page = 1;
|
||||
var count = 0;
|
||||
var maxPage = 0;
|
||||
function search_orgs(e){
|
||||
if($(e.target).val().trim() == lastSearchCondition && lastSearchCondition != '')
|
||||
{
|
||||
return;
|
||||
}
|
||||
lastSearchCondition = $(e.target).val().trim();
|
||||
page = 1;
|
||||
$.ajax({
|
||||
url: '<%= url_for(:controller => 'courses', :action => 'search_public_orgs_not_in_course') %>'+'?name='+ e.target.value+'&page='+page,
|
||||
type:'get'
|
||||
});
|
||||
}
|
||||
|
||||
function throttle(method,context,e){
|
||||
clearTimeout(method.tId);
|
||||
method.tId=setTimeout(function(){
|
||||
method.call(context,e);
|
||||
},500);
|
||||
}
|
||||
|
||||
//查询组织
|
||||
$("input[name='orgs']").on('input', function (e) {
|
||||
throttle(search_orgs,window,e);
|
||||
});
|
||||
}
|
||||
</script>
|
||||
|
||||
$(document).ready(function(){
|
||||
$.ajax({
|
||||
url: '<%= url_for(:controller => 'courses', :action => 'search_public_orgs_not_in_course') %>'+'?page=1',
|
||||
type:'get'
|
||||
});
|
||||
});
|
||||
function cancel_join_orgs() {
|
||||
$("#join_orgs_for_course input:checked").attr("checked", false);
|
||||
}
|
||||
function course_join_org(courseId) {
|
||||
$.ajax({
|
||||
url: "/org_courses?" + $("#join_orgs_for_course").serialize() + "&course_id=" + courseId,
|
||||
type: "post",
|
||||
success: function (data) {
|
||||
$.ajax({
|
||||
url: "/courses/" + courseId + "/search_public_orgs_not_in_course?hint_flag=true&name=" + $("input[name='orgs']").val().trim(),
|
||||
type: "get"
|
||||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
</script>
|
||||
|
||||
<% end %>
|
|
@ -0,0 +1,67 @@
|
|||
<div class="pro_new_setting_conbox fl " style="width:100%; border:none;">
|
||||
<a href="javascript:void(0);" class="fl sy_btn_green mb10 ml15" onclick="add_course_member();">添加成员</a>
|
||||
<div class="cl"></div>
|
||||
<div class=" sy_new_tchbox clear undis" style="margin-left:10px; margin-right:10px" id="add_course_member">
|
||||
<%= form_for(@member, {:as => :membership, :url => course_memberships_path(@course), :remote => true, :method => :post}) do |f| %>
|
||||
<div class="hw_search_box mb10">
|
||||
<input class="sy_new_search" placeholder="支持姓名、邮箱、登录名搜索" id="principal_search" type="text">
|
||||
<%= javascript_tag "observeSearchfield('principal_search', null, '#{ escape_javascript autocomplete_course_memberships_path(@course, :format => 'js',:flag => true) }')" %>
|
||||
<%#= javascript_tag "observeSearchfield('principal_search', null, '#{escape_javascript "/contest_members/contest_member_autocomplete?" + {:contest => @contest.id}.to_query }')" %>
|
||||
</div>
|
||||
<div class="fl mb10 pro_new_idlist" id="principals_for_new_member">
|
||||
<%= render_principals_for_new_course_members(@course) %>
|
||||
</div>
|
||||
<div class="fl">
|
||||
<ul class="fl pro_new_idbox">
|
||||
<li class="clear ">
|
||||
<label>
|
||||
<input type="checkbox" class="mt2 fl h28" name="membership[role_ids][]" value="9" id="add_member_checkbox_9">
|
||||
<p class="fl ml5"> 教师</p>
|
||||
</label>
|
||||
</li>
|
||||
<li class="clear ">
|
||||
<label>
|
||||
<input type="checkbox" class="mt2 fl h28" name="membership[role_ids][]" value="7" id="add_member_checkbox_7">
|
||||
<p class="fl ml5"> 助教</p>
|
||||
</label>
|
||||
</li>
|
||||
<li class="clear ">
|
||||
<label>
|
||||
<input type="checkbox" class="mt2 fl h28" name="membership[role_ids][]" value="10" id="add_member_checkbox_10">
|
||||
<p class="fl ml5"> 学生</p>
|
||||
</label>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="cl"></div>
|
||||
<a href="javascript:void(0);" class="fr sy_btn_grey" onclick='$("#add_course_member").hide();'>取消</a>
|
||||
<a href="javascript:void(0);" class="fr sy_btn_blue mr5" onclick="$('#new_membership').submit();">保存</a>
|
||||
<% end %>
|
||||
</div>
|
||||
|
||||
<div class="clear ml10 mr10">
|
||||
<%= render :partial => 'courses/settings/course_member' %>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
function add_course_member(){
|
||||
$("#add_course_member").toggle();
|
||||
}
|
||||
$(function() {
|
||||
$("#add_member_checkbox_7").on('click', function(){
|
||||
if($("#add_member_checkbox_7").is(":checked")) {
|
||||
$("#add_member_checkbox_9").attr('disabled', 'disabled');
|
||||
} else {
|
||||
$("#add_member_checkbox_9").removeAttr('disabled');
|
||||
}
|
||||
});
|
||||
$("#add_member_checkbox_9").on('click', function(){
|
||||
if($("#add_member_checkbox_9").is(":checked")) {
|
||||
$("#add_member_checkbox_7").attr('disabled', 'disabled');
|
||||
} else {
|
||||
$("#add_member_checkbox_7").removeAttr('disabled');
|
||||
}
|
||||
});
|
||||
});
|
||||
</script>
|
|
@ -70,9 +70,8 @@
|
|||
</tbody>
|
||||
</table>
|
||||
<% else %>
|
||||
<p class="nodata">
|
||||
<%= l(:label_no_data) %>
|
||||
</p>
|
||||
<div class="icons_tishi"><img src="/images/sy/icons_smile.png" width="110" height="110" alt="" ></div>
|
||||
<p class="sy_tab_con_p">没有数据可以显示!</p>
|
||||
<% end %>
|
||||
</div>
|
||||
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
<%= javascript_heads %>
|
||||
<%= heads_for_theme %>
|
||||
<%= call_hook :view_layouts_base_html_head %>
|
||||
<%= stylesheet_link_tag 'jquery/jquery-ui-1.9.2','css/common','css/public', 'css/structure','prettify', 'css/courses','css/popup','sy_public','syllabus', 'css/moduel'%>
|
||||
<%= stylesheet_link_tag 'jquery/jquery-ui-1.9.2','css/common','css/public', 'css/structure','prettify', 'css/courses','css/popup','sy_public','syllabus', 'css/moduel','css/contest'%>
|
||||
<%= javascript_include_tag "course","avatars","header","attachments",'prettify' %>
|
||||
<!-- page specific tags -->
|
||||
<%= yield :header_tags -%>
|
||||
|
@ -127,7 +127,7 @@
|
|||
<% statistics_count = 0 %>
|
||||
<% unless show_nav?(statistics_count) %>
|
||||
<li id="sy_10" class="sy_icons_st">
|
||||
<a href="<%=statistics_course_course_path(@course) %>">统计<span></span></a>
|
||||
<a href="<%=course_statistics_course_path(@course) %>">统计<span></span></a>
|
||||
<!--<a href="javascript:void(0);" class="sy_class_add"></a>-->
|
||||
</li>
|
||||
<% end %>
|
||||
|
|
|
@ -9,12 +9,12 @@
|
|||
<% end%>
|
||||
<%elsif @course%>
|
||||
<% if @create_member_error_messages%>
|
||||
alert("<%= @create_member_error_messages%>");
|
||||
notice_box("<%= @create_member_error_messages%>");
|
||||
<% else%>
|
||||
$('#course_members_setting').html('<%= escape_javascript(render :partial => 'courses/course_members') %>');
|
||||
$('#tbc_02').html('<%= escape_javascript(render :partial => 'courses/settings/member') %>');
|
||||
$("#teacher_number").html("<%= searchTeacherAndAssistant(@course).count %>");
|
||||
$("#student_number").html("<%= studentCount(@course) %>");
|
||||
alert("添加成功");
|
||||
notice_box("添加成功");
|
||||
<% end%>
|
||||
hideOnLoad();
|
||||
<%end%>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
$("#project_members_number").html("<%= @project.members.count %>");
|
||||
// $('#tab-content-members').html('<%#= escape_javascript(render :partial => 'projects/settings/members') %>');
|
||||
<%elsif @course%>
|
||||
$('#course_members_setting').html('<%= escape_javascript(render :partial => 'courses/course_members') %>');
|
||||
$('#tbc_02').html('<%= escape_javascript(render :partial => 'courses/settings/member') %>');
|
||||
$("#teacher_number").html("<%= searchTeacherAndAssistant(@course).count %>")
|
||||
$("#student_number").html("<%= studentCount(@course) %>");
|
||||
<%end%>
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<%if @project%>
|
||||
$('#pro_st_tbc_03').html('<%= escape_javascript(render :partial => 'projects/settings/new_members') %>');
|
||||
<%elsif @course%>
|
||||
$('#course_members_setting').html('<%= escape_javascript(render :partial => 'courses/course_members') %>');
|
||||
$('#tbc_02').html('<%= escape_javascript(render :partial => 'courses/settings/member') %>');
|
||||
$("#teacher_number").html("<%= searchTeacherAndAssistant(@course).count %>")
|
||||
$("#student_number").html("<%= studentCount(@course) %>");
|
||||
<%end%>
|
||||
|
|
|
@ -1,8 +1,7 @@
|
|||
<div>
|
||||
<% if newss.empty? %>
|
||||
<p class="nodata">
|
||||
<%= l(:label_no_data) %>
|
||||
</p>
|
||||
<div class="icons_tishi"><img src="/images/sy/icons_smile.png" width="110" height="110" alt="" ></div>
|
||||
<p class="sy_tab_con_p">没有数据可以显示!</p>
|
||||
<% else %>
|
||||
<% newss.each do |news| %>
|
||||
<div class="problem_main upload_img">
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
$("#added_orgs").html("");
|
||||
$("#added_orgs").html('<%= escape_javascript(render :partial => "courses/settings/added_orgs", :locals => {:orgs => @course.organizations, :course_id => @course.id}) %>');
|
||||
hideModal();
|
||||
$("#tbc_03").html('<%= escape_javascript(render :partial => "courses/settings/join_org") %>');
|
||||
|
||||
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
<% elsif @homework.homework_type == 3 && @homework.homework_detail_group.base_on_project == 0 %>
|
||||
<th class="hworkList390" style="text-align:left;">组长</th>
|
||||
<% end %>
|
||||
<th class="hworkList130 pl10">
|
||||
<th class="hworkList90 pl10">
|
||||
状态
|
||||
</th>
|
||||
<% if @homework.homework_type == 2%>
|
||||
|
@ -28,6 +28,8 @@
|
|||
<th class="hworkList70 pr10 pl10" style="font-size:12px;">
|
||||
我的评分
|
||||
</th>
|
||||
<th class="hworkList40 pl10">
|
||||
</th>
|
||||
</tr>
|
||||
<% @stundet_works.each_with_index do |student_work, i|%>
|
||||
<% score_open = @homework.score_open == 1 || student_work.user == User.current %>
|
||||
|
|
|
@ -26,9 +26,21 @@
|
|||
</span>
|
||||
</div>
|
||||
<div class="flex-cell student_work_<%= st.id%>">
|
||||
<span class="<%= score_color (!score_open || st.teaching_asistant_score.nil? ? nil : st.teaching_asistant_score) %>">
|
||||
<%= st.teaching_asistant_score.nil? ? "--" : (!score_open ? "**" : format("%.1f",st.teaching_asistant_score))%>
|
||||
</span>
|
||||
<div class="<%= score_color (!score_open || st.teaching_asistant_score.nil? ? nil : st.teaching_asistant_score) %> student_score_info pr">
|
||||
<% if st.teaching_asistant_score.nil? || !score_open %>
|
||||
<span title=""><%=st.teaching_asistant_score.nil? ? "--" : "**" %></span>
|
||||
<% else %>
|
||||
<%= format("%.1f",st.teaching_asistant_score) %>
|
||||
<div class="anonymous-tip none" style="line-height: 18px; top:-5px; <%= @homework.anonymous_comment == 0 ? 'right:-373px;' : 'right:-317px;' %>">
|
||||
<em></em>
|
||||
<font></font>
|
||||
现共有
|
||||
<span class="c_red"> <%= st.student_works_scores.where(:reviewer_role => 2).group_by(&:user_id).count%> </span>
|
||||
名助教进行了评分,<%=@homework.homework_detail_manual.ta_mode == 1 ? "平均" : "复审" %>分为
|
||||
<span class="c_red"> <%= format("%.1f",st.teaching_asistant_score)%> </span>分。
|
||||
</div>
|
||||
<% end %>
|
||||
</div>
|
||||
</div>
|
||||
<% if @homework.anonymous_comment == 0 %>
|
||||
<div class="flex-cell student_work_<%= st.id%>">
|
||||
|
@ -57,12 +69,14 @@
|
|||
<span class="linkBlue">
|
||||
(<%= anon_count %>)
|
||||
</span>
|
||||
<div class="g_infoNi none">
|
||||
现共有
|
||||
<span class="c_red"> <%= anon_count %> </span>
|
||||
名学生进行了匿评,平均分为
|
||||
<span class="c_red"> <%= format("%.1f", st.student_score) %> </span>分。
|
||||
</div>
|
||||
<div class="anonymous-tip none" style="line-height: 18px; top:-5px; right:-288px;">
|
||||
<em></em>
|
||||
<font></font>
|
||||
现共有
|
||||
<span class="c_red"> <%= anon_count%> </span>
|
||||
名学生进行了匿评,平均分为
|
||||
<span class="c_red"> <%= format("%.1f",st.student_score)%> </span>分。
|
||||
</div>
|
||||
<% end %>
|
||||
<% end %>
|
||||
</div>
|
||||
|
@ -73,7 +87,7 @@
|
|||
<div class="<%= score_color (!score_open || score.nil? ? nil : score)%> student_final_scor_info pr" style="display: inline">
|
||||
<%= score.nil? ? "--" : (!score_open ? "**" : format("%.1f",score<0 ? 0 : score))%>
|
||||
<% unless !score_open || score.nil?%>
|
||||
<div class="score-tip none tl" style="line-height: 18px; top:-32px; right:-273px;">
|
||||
<div class="score-tip none tl" style="line-height: 18px; <%=@homework.anonymous_comment == 0 ? 'top:-50px; right:-273px;' : 'top:-13px; right:-288px;' %>">
|
||||
<em></em>
|
||||
<font></font>
|
||||
作品最终评分为
|
||||
|
@ -102,20 +116,13 @@
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<% if User.current.allowed_to?(:as_teacher, st.homework_common.course) %>
|
||||
<% if @is_teacher %>
|
||||
<div class="fr ml5" style="width:25px; color: #3b94d6; white-space:nowrap; text-align:right; margin-right:5px; cursor: pointer;" onclick="show_student_work('<%= student_work_path(st)%>')">评分</div>
|
||||
<% end %>
|
||||
<div class="hworkTip" style="display: none; left:710px; top:20px; white-space:nowrap; right:auto;" id="work_click_<%= st.id%>"><em></em><span></span><font class="fontGrey2">点击进行评分</font></div>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<script type="text/javascript">
|
||||
$(".student_work_<%= st.id%>").mouseenter(function(){
|
||||
$("#work_click_<%= st.id%>").show();
|
||||
}).mouseleave(function(){
|
||||
$("#work_click_<%= st.id%>").hide();
|
||||
}).mouse;
|
||||
|
||||
$(".syllabus_class_list").mouseenter(function(){
|
||||
$(this).css("background-color","#f6fafd");
|
||||
});
|
||||
|
|
|
@ -24,7 +24,7 @@
|
|||
</th>
|
||||
<% else %>
|
||||
<% if @homework.homework_detail_group.base_on_project == 1 %>
|
||||
<th class="hworkList130 pl5 pr5" style="text-align:left;">组长</th>
|
||||
<th class="hworkList130 pl5 pr5" style="text-align:left;">组长</th>
|
||||
<th class="<%= @homework.anonymous_comment == 1 ? 'hworkList140' : 'hworkList70' %>">
|
||||
<span class="c_dark f14 fb">关联项目</span>
|
||||
</th>
|
||||
|
@ -32,7 +32,7 @@
|
|||
<th class="<%= @homework.anonymous_comment == 1 ? 'hworkList270' : 'hworkList200' %> pl5 pr5" style="text-align:left;">组长</th>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<th class="<%= @homework.homework_type ==2 ? 'hworkList110' : 'hworkList130' %>">
|
||||
<th class="<%= @homework.homework_type ==2 ? 'hworkList70' : 'hworkList90' %>">
|
||||
<%= link_to "状态", @show_all ? student_work_index_path(:homework => @homework.id, :order => "work_status", :sort => @score, :name => @name, :group => @group) : "javascript:void(0)", :class => "c_dark f14 fb", :remote => true %>
|
||||
<% if @show_all && @order == "work_status" %>
|
||||
<%= link_to "", student_work_index_path(:homework => @homework.id, :order => "work_status", :sort => @score, :name => @name, :group => @group), :class => "#{@score == 'desc' ? 'sort_up' : 'sort_down'} float-none", :style => "line-height:30px; vertical-align:middle;", :remote => true %>
|
||||
|
@ -72,6 +72,8 @@
|
|||
<%= link_to "", student_work_index_path(:homework => @homework.id, :order => "score", :sort => @score, :name => @name, :group => @group), :class => "#{@score == 'desc' ? 'sort_up' : 'sort_down'} float-none", :style => "line-height:30px; vertical-align:middle;", :remote => true %>
|
||||
<% end %>
|
||||
</th>
|
||||
<th class="hworkList40">
|
||||
</th>
|
||||
</tr>
|
||||
<%# end %>
|
||||
<% @stundet_works.each_with_index do |student_work, i| %>
|
||||
|
|
|
@ -55,7 +55,21 @@
|
|||
<%= student_work.teacher_score.nil? ? "--" : (!score_open ? "**" : format("%.1f",student_work.teacher_score))%>
|
||||
</td>
|
||||
<td class="hworkList70 <%= score_color (!score_open || student_work.teaching_asistant_score.nil? ? nil : student_work.teaching_asistant_score)%>">
|
||||
<%= student_work.teaching_asistant_score.nil? ? "--" : (!score_open ? "**" : format("%.1f",student_work.teaching_asistant_score)) %>
|
||||
<div class="<%= score_color (!score_open || student_work.teaching_asistant_score.nil? ? nil : student_work.teaching_asistant_score) %> student_score_info pr">
|
||||
<% if student_work.teaching_asistant_score.nil? || !score_open %>
|
||||
<span title=""><%=student_work.teaching_asistant_score.nil? ? "--" : "**" %></span>
|
||||
<% else %>
|
||||
<%= format("%.1f",student_work.teaching_asistant_score) %>
|
||||
<div class="anonymous-tip none" style="line-height: 18px; top:5px; <%= @homework.anonymous_comment == 0 ? (@homework.homework_type == 1 ? 'right:-322px;' : 'right:-392px;') : (@homework.homework_type == 1 ? 'right:-253px;' : 'right:-323px;') %>">
|
||||
<em></em>
|
||||
<font></font>
|
||||
现共有
|
||||
<span class="c_red"> <%= student_work.student_works_scores.where(:reviewer_role => 2).group_by(&:user_id).count%> </span>
|
||||
名助教进行了评分,<%=@homework.homework_detail_manual.ta_mode == 1 ? "平均" : "复审" %>分为
|
||||
<span class="c_red"> <%= format("%.1f",student_work.teaching_asistant_score)%> </span>分。
|
||||
</div>
|
||||
<% end %>
|
||||
</div>
|
||||
</td>
|
||||
|
||||
<% if @homework.homework_type == 2%>
|
||||
|
@ -110,7 +124,7 @@
|
|||
<td class="hworkList70 <%= score_color (!score_open || score.nil? ? nil : score)%> student_final_scor_info pr">
|
||||
<%= score.nil? ? "--" : (!score_open ? "**" : format("%.1f",score<0 ? 0 : score))%>
|
||||
<% unless !score_open || score.nil?%>
|
||||
<div class="score-tip none tl" style="line-height: 18px;">
|
||||
<div class="score-tip none tl" style="line-height: 18px; <%= @homework.anonymous_comment == 0 ? '' : 'top: 10px;' %>">
|
||||
<em></em>
|
||||
<font></font>
|
||||
作品最终评分为
|
||||
|
@ -136,7 +150,16 @@
|
|||
</div>
|
||||
<% end%>
|
||||
</td>
|
||||
<td><div style="position:relative;"><div class="hworkTip" style="display: none" id="work_click_<%= student_work.id%>"><em></em><span></span><font class="fontGrey2">点击查看详情</font></div></div></td>
|
||||
<td>
|
||||
<% if @is_teacher %>
|
||||
<div class="fr ml5" style="width:25px; color: #3b94d6; white-space:nowrap; text-align:right; margin-right:5px; cursor: pointer;" onclick="show_student_work('<%= student_work_path(student_work)%>')">评分</div>
|
||||
<% end %>
|
||||
</td>
|
||||
<td>
|
||||
<div style="position:relative;">
|
||||
<div class="hworkTip" style="display: none" id="work_click_<%= student_work.id%>"><em></em><span></span><font class="fontGrey2">点击查看详情</font></div>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<%# end %>
|
||||
<script type="text/javascript">
|
||||
|
|
|
@ -88,6 +88,9 @@
|
|||
<td class="hworkList70 <%= my_score.nil? ? 'c_grey' : score_color(my_score.score)%> mr10 ml10">
|
||||
<%= my_score.nil? ? "--" : format("%.1f",my_score.score)%>
|
||||
</td>
|
||||
<td>
|
||||
<div class="fr ml5" style="width:25px; color: #3b94d6; text-align:right; margin-right:5px; cursor: pointer;" onclick="show_student_work('<%= student_work_path(student_work)%>')">评分</div>
|
||||
</td>
|
||||
<td><div style="position:relative;"><div class="hworkTip" style="display: none" id="work_click_<%= student_work.id%>"><em></em><span></span><font class="fontGrey2">点击查看详情</font></div></div></td>
|
||||
</tr>
|
||||
<script type="text/javascript">
|
||||
|
|
|
@ -5,11 +5,10 @@
|
|||
<div class="homepagePostTo break_word mt-4">
|
||||
<%= link_to homework.user.show_name, user_activities_path(homework.user_id), :class => "newsBlue mr15"%>
|
||||
</div>
|
||||
<div class="homepagePostTitle hidden fl m_w505">
|
||||
<div class="homepagePostTitle break_full_word fl">
|
||||
<% index = get_hw_index(homework, is_teacher) %>
|
||||
<%= link_to "<span class='fontBlue2'>作业#{index + 1}:</span>".html_safe + homework.name,student_work_index_path(:homework => homework.id),:class => "postGrey"%>
|
||||
<span class='postGrey fl'><font class="fontBlue2">作业<%= index + 1 %>:</font><%= homework.name%> <%=get_hw_status(homework).html_safe %></span>
|
||||
</div>
|
||||
<%=get_hw_status(homework).html_safe %>
|
||||
<div class="cl"></div>
|
||||
<% if homework.homework_type == 3 && homework.homework_detail_group.base_on_project == 1%>
|
||||
<span class="c_red">系统提示:该作业要求各组长<%=link_to "创建项目", new_project_path(:host=>Setting.host_name),:class=>"linkBlue",:title=>"新建项目",:style=>"text-decoration:underline;"%>,组成员加入项目,然后由组长关联项目。谢谢配合!</span>
|
||||
|
|
|
@ -36,6 +36,20 @@
|
|||
更新时间:<%= format_time(CourseActivity.where("course_act_type='#{activity.class}' and course_act_id =#{activity.id}").first.updated_at) %>
|
||||
</div>
|
||||
<div class="cl"></div>
|
||||
<% if defined?(is_course) && is_course == 1 && (activity.user == User.current || User.current.admin? || User.current.allowed_to?(:as_teacher, course))%>
|
||||
<div class="homepagePostSetting">
|
||||
<ul>
|
||||
<li class="homepagePostSettingIcon">
|
||||
<ul class="homepagePostSettiongText">
|
||||
<li>
|
||||
<a href="javascript:void(0)" class="postOptionLink" title="删除"
|
||||
onclick="delete_confirm_box_3('<%= words_destroy_path(:object_id => activity, :user_id => activity.user.id,:user_activity_id => user_activity_id, :activity_id => activity.id)%>', '确定要删除该留言吗?')">删除</a>
|
||||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<% end%>
|
||||
</div>
|
||||
<div class="cl"></div>
|
||||
</div>
|
||||
|
|
|
@ -18,7 +18,7 @@
|
|||
</span>
|
||||
</li>
|
||||
<li class="messageInformationContents">
|
||||
<% content = message_user.show_name + "申请成为班级\"" + "#{contest.name}" + "\"的" + get_role_str(ma.role) %>
|
||||
<% content = message_user.show_name + "申请成为竞赛\"" + "#{contest.name}" + "\"的" + get_role_str(ma.role) %>
|
||||
<%= link_to contest.name, contest_path(contest.id),
|
||||
:class => "#{ma.viewed==0 ? "newsBlack" : "newsGrey"}", :target => '_blank', :title => "#{content}" %>
|
||||
</li>
|
||||
|
|
|
@ -31,7 +31,7 @@
|
|||
</li>
|
||||
<li class="messageInformationContents">
|
||||
<%= link_to Contest.find(ma.contest_id).name, contest_path(ma.contest_id),
|
||||
:class => "#{ma.viewed==0 ? "newsBlack" : "newsGrey"}", :target => '_blank' %>
|
||||
:class => "#{!ma.viewed ? "newsBlack" : "newsGrey"}", :target => '_blank' %>
|
||||
</li>
|
||||
</div>
|
||||
<li class="messageOperateContents fl">
|
||||
|
@ -58,7 +58,7 @@
|
|||
<span class="homepageNewsType fl">将您加入了竞赛:</span>
|
||||
</li>
|
||||
<li class="messageInformationContents">
|
||||
<%= link_to ma.contest.name, contest_path(ma.contest), :class => "#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}", :target => '_blank' %>
|
||||
<%= link_to ma.contest.name, contest_path(ma.contest), :class => "#{!ma.viewed ? "newsBlack" : "newsGrey"}", :target => '_blank' %>
|
||||
</li>
|
||||
</div>
|
||||
<li class="homepageNewsTime fr"><%= time_tag(ma.created_at).html_safe %> </li>
|
||||
|
@ -78,7 +78,7 @@
|
|||
<li class="messageInformationContents">
|
||||
<%= link_to User.find(ma.contest_message_id).login+"("+(User.find(ma.contest_message_id).realname ? User.find(ma.contest_message_id).realname : User.find(ma.contest_message_id).login) +")",
|
||||
{:controller => 'contests', :action => 'settings', :id => ma.contest_id, :tab=>'member'},
|
||||
:class => "#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}",
|
||||
:class => "#{!ma.viewed ? "newsBlack" : "newsGrey"}",
|
||||
:target => '_blank' %>
|
||||
</li>
|
||||
</div>
|
||||
|
@ -97,7 +97,7 @@
|
|||
<span class="homepageNewsType fl">将您移出了竞赛:</span>
|
||||
</li>
|
||||
<li class="messageInformationContents">
|
||||
<%= link_to ma.contest.name, contest_path(ma.contest), :class => "#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}", :target => '_blank' %>
|
||||
<%= link_to ma.contest.name, contest_path(ma.contest), :class => "#{!ma.viewed ? "newsBlack" : "newsGrey"}", :target => '_blank' %>
|
||||
</li>
|
||||
</div>
|
||||
<li class="homepageNewsTime fr"><%= time_tag(ma.created_at).html_safe %> </li>
|
||||
|
@ -117,13 +117,13 @@
|
|||
<li class="messageInformationContents">
|
||||
<% if User.current.contestant_of_contest?(ma.contest_message.contest) && cur_user_works_for_work(ma.contest_message).nil? && ma.contest_message.work_status == 1 %>
|
||||
<%= link_to ma.contest_message.name, new_contestant_work_path(:work => ma.contest_message.id),
|
||||
:class =>"#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}",
|
||||
:class =>"#{!ma.viewed ? "newsBlack" : "newsGrey"}",
|
||||
:target => '_blank',
|
||||
:title => "竞赛题:#{ma.contest_message.name}"
|
||||
%>
|
||||
<% else %>
|
||||
<%= link_to ma.contest_message.name, contestant_works_path(:work => ma.contest_message.id),
|
||||
:class => "#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}",
|
||||
:class => "#{!ma.viewed ? "newsBlack" : "newsGrey"}",
|
||||
:target => '_blank',
|
||||
:title => "竞赛题:#{ma.contest_message.name}"
|
||||
%>
|
||||
|
@ -148,7 +148,7 @@
|
|||
<span class="homepageNewsType fl">发布的竞赛题:</span></li>
|
||||
<li class="messageInformationContents">
|
||||
<%= link_to ma.contest_message.name, contestant_works_path(:work => ma.contest_message.id),
|
||||
:class => "#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}",
|
||||
:class => "#{!ma.viewed ? "newsBlack" : "newsGrey"}",
|
||||
:target => '_blank',
|
||||
:title => "竞赛题:#{ma.contest_message.name}"
|
||||
%>
|
||||
|
@ -170,7 +170,7 @@
|
|||
<span class="homepageNewsType fl">启动了在线评审:</span>
|
||||
</li>
|
||||
<li class="messageInformationContents">
|
||||
<%= link_to ma.contest_message.name, contestant_works_path(:work => ma.contest_message.id), :class => "#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}"%>
|
||||
<%= link_to ma.contest_message.name, contestant_works_path(:work => ma.contest_message.id), :class => "#{!ma.viewed ? "newsBlack" : "newsGrey"}"%>
|
||||
</li>
|
||||
</div>
|
||||
<li class="homepageNewsTime fr"><%= time_tag(ma.created_at).html_safe %> </li>
|
||||
|
@ -188,7 +188,7 @@
|
|||
<span class="homepageNewsType fl">在线评审启动失败<font class="c_red">(评委数为0或作品数为0):</font></span>
|
||||
</li>
|
||||
<li class="messageInformationContents">
|
||||
<%= link_to ma.contest_message.name, contestant_works_path(:work => ma.contest_message.id), :class => "#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}"%>
|
||||
<%= link_to ma.contest_message.name, contestant_works_path(:work => ma.contest_message.id), :class => "#{!ma.viewed ? "newsBlack" : "newsGrey"}"%>
|
||||
</li>
|
||||
</div>
|
||||
<li class="homepageNewsTime fr"><%= time_tag(ma.created_at).html_safe %> </li>
|
||||
|
@ -209,7 +209,7 @@
|
|||
<span class="homepageNewsType fl">启动的在线评审:</span></li>
|
||||
<li class="messageInformationContents">
|
||||
<%= link_to ma.contest_message.name, contestant_works_path(:work => ma.contest_message.id),
|
||||
:class => "#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}",
|
||||
:class => "#{!ma.viewed ? "newsBlack" : "newsGrey"}",
|
||||
:target => '_blank',
|
||||
:title => "竞赛题:#{ma.contest_message.name}"
|
||||
%>
|
||||
|
@ -232,7 +232,7 @@
|
|||
</li>
|
||||
<li class="messageInformationContents">
|
||||
<%= link_to ma.contest_message.title, {:controller => 'news', :action => 'show', :id => ma.contest_message.id },
|
||||
:class =>"#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}",
|
||||
:class =>"#{!ma.viewed ? "newsBlack" : "newsGrey"}",
|
||||
:target => '_blank',
|
||||
:title => "#{ma.contest_message.title}"
|
||||
%>
|
||||
|
@ -254,7 +254,7 @@
|
|||
</li>
|
||||
<li class="messageInformationContents">
|
||||
<%= link_to ma.contest_message.commented.title, {:controller => 'news', :action => 'show', :id => ma.contest_message.commented.id },
|
||||
:class =>"#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}" ,
|
||||
:class =>"#{!ma.viewed ? "newsBlack" : "newsGrey"}" ,
|
||||
:target => '_blank',
|
||||
:title => "#{ma.contest_message.commented.title}"
|
||||
%>
|
||||
|
@ -277,7 +277,7 @@
|
|||
<% if ma.contest_message.parent_id.nil? %>
|
||||
<li class="messageInformationContents">
|
||||
<%= link_to ma.contest_message.subject, board_message_path(ma.contest_message.board_id, ma.contest_message.id),
|
||||
:class => "#{ma.viewed==0 ? "newsBlack" : "newsGrey"}",
|
||||
:class => "#{!ma.viewed ? "newsBlack" : "newsGrey"}",
|
||||
:target => '_blank',
|
||||
:title => "#{ma.contest_message.subject}"
|
||||
%>
|
||||
|
@ -285,7 +285,7 @@
|
|||
<% else %>
|
||||
<li class="messageInformationContents">
|
||||
<%= link_to message_content(ma.contest_message.content), board_message_path(ma.contest_message.board_id, ma.contest_message.parent_id),
|
||||
:class => "#{ma.viewed==0 ? "newsBlack" : "newsGrey"}", :target => '_blank' %>
|
||||
:class => "#{!ma.viewed ? "newsBlack" : "newsGrey"}", :target => '_blank' %>
|
||||
</li>
|
||||
<% end %>
|
||||
</div>
|
||||
|
@ -304,8 +304,8 @@
|
|||
<span class="homepageNewsType fl"><%= ma.contest_message.m_parent_id.nil? ? "发布了竞赛留言:" : "回复了竞赛留言:" %></span>
|
||||
</li>
|
||||
<li class="messageInformationContents">
|
||||
<%= link_to message_content(ma.contest_message.notes), contest_feedback_path(:id => ma.contest_id),
|
||||
:class => "#{ma.viewed == 0 ? "newsBlack" : "newsGrey"}", :target => '_blank' %>
|
||||
<%= link_to message_content(ma.contest_message.notes), feedback_contest_path(:id => ma.contest_id),
|
||||
:class => "#{!ma.viewed ? "newsBlack" : "newsGrey"}", :target => '_blank' %>
|
||||
</li>
|
||||
</div>
|
||||
<li class="homepageNewsTime fr"><%= time_tag(ma.created_at).html_safe %> </li>
|
||||
|
|
|
@ -28,12 +28,12 @@
|
|||
<% else %>
|
||||
$('#course_jour_count').html("<%= @jours_count %>");
|
||||
<% end %>
|
||||
<% elsif @contest && @jours_count%>
|
||||
<% if @user_activity_id %>
|
||||
$("#activity_post_reply_<%= @user_activity_id%>").html("<%= escape_javascript(render :partial => 'users/user_journal_post_reply', :locals => {:activity => @activity,:user_activity_id =>@user_activity_id}) %>");
|
||||
sd_create_editor_from_data('<%= @user_activity_id%>', "", "100%", "UserActivity");
|
||||
<% end %>
|
||||
<% elsif @user && @jours_count%>
|
||||
<% elsif @contest && @jours_count%>
|
||||
<% if @user_activity_id %>
|
||||
$("#activity_post_reply_<%= @user_activity_id%>").html("<%= escape_javascript(render :partial => 'users/user_journal_post_reply', :locals => {:activity => @activity,:user_activity_id =>@user_activity_id}) %>");
|
||||
sd_create_editor_from_data('<%= @user_activity_id%>', "", "100%", "UserActivity");
|
||||
<% end %>
|
||||
<% elsif @user && @jours_count%>
|
||||
$('#jour_count').html("<%= @jours_count %>");
|
||||
<% elsif @homework%>
|
||||
$("#homework_post_reply_<%= @user_activity_id%>").replaceWith("<%= escape_javascript(render :partial => 'users/homework_post_reply', :locals => {:activity => @homework, :user_activity_id => @user_activity_id, :is_teacher => @is_teacher}) %>");
|
||||
|
|
|
@ -1353,7 +1353,7 @@ RedmineApp::Application.routes.draw do
|
|||
get 'search_public_orgs_not_in_course'
|
||||
get "homework_search"
|
||||
get "show_comparecode"
|
||||
get "statistics_course"
|
||||
get "course_statistics"
|
||||
get "switch_role"
|
||||
get 'search_not_group_member'
|
||||
post 'add_members'
|
||||
|
@ -1407,7 +1407,7 @@ RedmineApp::Application.routes.draw do
|
|||
end # end of resources :courses
|
||||
match 'courses/:id/feedback', :to => 'courses#feedback', :via => :get, :as => 'course_feedback'
|
||||
match '/courses/search', :via => [:get, :post]
|
||||
match 'words/:id/leave_course_message', :to => 'words#leave_course_message'
|
||||
match 'words/:id/leave_course_message', :to => 'words#leave_course_message', :as => "leave_course_message"
|
||||
|
||||
|
||||
match 'workflows', :to => 'workflows#index', :via => :get
|
||||
|
|
114
db/schema.rb
114
db/schema.rb
|
@ -11,7 +11,7 @@
|
|||
#
|
||||
# It's strongly recommended to check this file into your version control system.
|
||||
|
||||
ActiveRecord::Schema.define(:version => 20170120021457) do
|
||||
ActiveRecord::Schema.define(:version => 20170119084333) do
|
||||
|
||||
create_table "activities", :force => true do |t|
|
||||
t.integer "act_id", :null => false
|
||||
|
@ -280,7 +280,7 @@ ActiveRecord::Schema.define(:version => 20170120021457) do
|
|||
|
||||
create_table "blog_messages", :force => true do |t|
|
||||
t.integer "user_id"
|
||||
t.integer "blog_message_id"
|
||||
t.integer "blog_commont_id"
|
||||
t.integer "blog_id"
|
||||
t.string "blog_message_type"
|
||||
t.boolean "viewed", :default => false
|
||||
|
@ -350,16 +350,14 @@ ActiveRecord::Schema.define(:version => 20170120021457) do
|
|||
add_index "changeset_parents", ["parent_id"], :name => "changeset_parents_parent_ids"
|
||||
|
||||
create_table "changesets", :force => true do |t|
|
||||
t.integer "repository_id", :null => false
|
||||
t.string "revision", :null => false
|
||||
t.integer "repository_id", :null => false
|
||||
t.string "revision", :null => false
|
||||
t.string "committer"
|
||||
t.datetime "committed_on", :null => false
|
||||
t.datetime "committed_on", :null => false
|
||||
t.text "comments"
|
||||
t.date "commit_date"
|
||||
t.string "scmid"
|
||||
t.integer "user_id"
|
||||
t.integer "project_id"
|
||||
t.integer "type", :default => 0
|
||||
end
|
||||
|
||||
add_index "changesets", ["committed_on"], :name => "index_changesets_on_committed_on"
|
||||
|
@ -630,6 +628,20 @@ ActiveRecord::Schema.define(:version => 20170120021457) do
|
|||
t.integer "container_id", :default => 0
|
||||
end
|
||||
|
||||
create_table "course_class_post", :id => false, :force => true do |t|
|
||||
t.integer "班级id", :default => 0, :null => false
|
||||
t.string "班级名"
|
||||
t.integer "帖子id", :default => 0, :null => false
|
||||
t.integer "主贴id"
|
||||
t.string "帖子标题", :default => "", :null => false
|
||||
t.text "帖子内容"
|
||||
t.integer "帖子用户id"
|
||||
t.integer "帖子回复数", :default => 0, :null => false
|
||||
t.integer "最后回帖id"
|
||||
t.datetime "发帖时间", :null => false
|
||||
t.datetime "帖子更新时间", :null => false
|
||||
end
|
||||
|
||||
create_table "course_contributor_scores", :force => true do |t|
|
||||
t.integer "course_id"
|
||||
t.integer "user_id"
|
||||
|
@ -657,6 +669,21 @@ ActiveRecord::Schema.define(:version => 20170120021457) do
|
|||
|
||||
add_index "course_groups", ["course_id"], :name => "index_course_groups_on_course_id"
|
||||
|
||||
create_table "course_homework_statistics", :force => true do |t|
|
||||
t.integer "user_id"
|
||||
t.integer "course_id"
|
||||
t.integer "committed_work_num", :default => 0
|
||||
t.integer "un_commit_work_num", :default => 0
|
||||
t.integer "late_commit_work_num", :default => 0
|
||||
t.integer "absence_evaluation_work_num", :default => 0
|
||||
t.integer "un_evaluation_work_num", :default => 0
|
||||
t.integer "appeal_num", :default => 0
|
||||
t.float "average_score", :default => 0.0
|
||||
t.float "total_score", :default => 0.0
|
||||
t.datetime "created_at", :null => false
|
||||
t.datetime "updated_at", :null => false
|
||||
end
|
||||
|
||||
create_table "course_infos", :force => true do |t|
|
||||
t.integer "course_id"
|
||||
t.integer "user_id"
|
||||
|
@ -698,8 +725,8 @@ ActiveRecord::Schema.define(:version => 20170120021457) 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"
|
||||
|
@ -709,29 +736,27 @@ ActiveRecord::Schema.define(:version => 20170120021457) 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 "professional_level_id", :limit => 1
|
||||
t.integer "invite_code_halt", :limit => 1, :default => 0
|
||||
t.integer "os_allow", :default => 0
|
||||
t.integer "qrcode_expiretime", :default => 0
|
||||
t.integer "invite_code_halt", :limit => 1, :default => 0
|
||||
end
|
||||
|
||||
add_index "courses", ["invite_code"], :name => "index_courses_on_invite_code", :unique => true
|
||||
|
@ -806,11 +831,6 @@ ActiveRecord::Schema.define(:version => 20170120021457) do
|
|||
|
||||
add_index "delayed_jobs", ["priority", "run_at"], :name => "delayed_jobs_priority"
|
||||
|
||||
create_table "disciplines", :force => true do |t|
|
||||
t.string "name"
|
||||
t.integer "professional_level_id", :limit => 1
|
||||
end
|
||||
|
||||
create_table "discuss_demos", :force => true do |t|
|
||||
t.string "title"
|
||||
t.text "body"
|
||||
|
@ -936,11 +956,13 @@ ActiveRecord::Schema.define(:version => 20170120021457) do
|
|||
t.integer "exercise_status"
|
||||
t.integer "user_id"
|
||||
t.integer "time"
|
||||
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.datetime "publish_time"
|
||||
t.datetime "end_time"
|
||||
t.integer "show_result"
|
||||
t.integer "question_random", :default => 0
|
||||
t.integer "choice_random", :default => 0
|
||||
end
|
||||
|
||||
create_table "first_pages", :force => true do |t|
|
||||
|
@ -1130,10 +1152,6 @@ ActiveRecord::Schema.define(:version => 20170120021457) do
|
|||
t.datetime "updated_at", :null => false
|
||||
end
|
||||
|
||||
create_table "innodb_monitor", :id => false, :force => true do |t|
|
||||
t.integer "a"
|
||||
end
|
||||
|
||||
create_table "invite_lists", :force => true do |t|
|
||||
t.integer "project_id"
|
||||
t.integer "user_id"
|
||||
|
@ -1666,12 +1684,9 @@ ActiveRecord::Schema.define(:version => 20170120021457) do
|
|||
end
|
||||
|
||||
create_table "professional_levels", :force => true do |t|
|
||||
t.integer "level"
|
||||
end
|
||||
|
||||
create_table "professions", :force => true do |t|
|
||||
t.string "name"
|
||||
t.integer "discipline_id", :limit => 1
|
||||
t.string "level"
|
||||
t.datetime "created_at", :null => false
|
||||
t.datetime "updated_at", :null => false
|
||||
end
|
||||
|
||||
create_table "project_infos", :force => true do |t|
|
||||
|
@ -1734,6 +1749,7 @@ ActiveRecord::Schema.define(:version => 20170120021457) do
|
|||
t.boolean "hidden_repo", :default => false, :null => false
|
||||
t.integer "attachmenttype", :default => 1
|
||||
t.integer "user_id"
|
||||
t.integer "dts_test", :default => 0
|
||||
t.string "enterprise_name"
|
||||
t.integer "organization_id"
|
||||
t.integer "project_new_type"
|
||||
|
@ -1741,11 +1757,6 @@ ActiveRecord::Schema.define(:version => 20170120021457) do
|
|||
t.integer "forked_from_project_id"
|
||||
t.integer "forked_count"
|
||||
t.integer "publish_resource", :default => 0
|
||||
t.integer "boards_count", :default => 0
|
||||
t.integer "news_count", :default => 0
|
||||
t.integer "acts_count", :default => 0
|
||||
t.integer "journals_count", :default => 0
|
||||
t.integer "boards_reply_count", :default => 0
|
||||
t.integer "visits", :default => 0
|
||||
t.integer "hot", :default => 0
|
||||
t.string "invite_code"
|
||||
|
@ -2144,8 +2155,8 @@ ActiveRecord::Schema.define(:version => 20170120021457) do
|
|||
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"
|
||||
|
@ -2154,9 +2165,8 @@ ActiveRecord::Schema.define(:version => 20170120021457) 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 "professional_level_id", :limit => 1
|
||||
t.integer "visits", :default => 0
|
||||
t.integer "des_status", :default => 0
|
||||
end
|
||||
|
||||
add_index "syllabuses", ["user_id"], :name => "index_syllabuses_on_user_id"
|
||||
|
|
|
@ -158,6 +158,7 @@ function jourReplyVerify() {
|
|||
if (jour_content_editor.isEmpty()) {
|
||||
$("#jour_content_span").text("留言不能为空");
|
||||
$("#jour_content_span").css('color', '#ff0000');
|
||||
$("#jour_content_span").show();
|
||||
$("#submit_feedback_user").one('click',function() {
|
||||
contest_jour_submit();
|
||||
});
|
||||
|
|
|
@ -1606,3 +1606,35 @@ function submit_course_feedback() {
|
|||
function show_more_tool(){
|
||||
$('#navContentCourse').css('display', 'block');
|
||||
}
|
||||
|
||||
//留言
|
||||
function course_jour_submit(){
|
||||
if(jourReplyVerify()){
|
||||
jour_content_editor.sync();//提交内容之前要sync,不然服务器端取不到值
|
||||
$("#course_feedback_new").submit();
|
||||
}
|
||||
}
|
||||
|
||||
function jourReplyVerify() {
|
||||
var content = jour_content_editor.html();//$.trim($("#message_content").val());
|
||||
if (jour_content_editor.isEmpty()) {
|
||||
$("#jour_content_span").text("留言不能为空");
|
||||
$("#jour_content_span").show();
|
||||
$("#jour_content_span").css('color', '#ff0000');
|
||||
$("#submit_feedback_user").one('click',function() {
|
||||
course_jour_submit();
|
||||
});
|
||||
return false;
|
||||
}
|
||||
else {
|
||||
$("#jour_content_span").text("填写正确");
|
||||
$("#jour_content_span").css('color', '#008000');
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
function cancel_jour_submit(){
|
||||
jour_content_editor.html("");
|
||||
$("#jour_content_span").text("");
|
||||
$("#jour_content_span").hide();
|
||||
}
|
|
@ -103,7 +103,7 @@ h4{ font-size:14px;}/*color:#3b3b3b;*/
|
|||
.mt1{margin-top: 1px;}.mt2{ margin-top:2px;}.mt3{ margin-top:3px;}.mt4{ margin-top:4px;}.mt5{ margin-top:5px;}.mt6{ margin-top:6px;}.mt7 {margin-top:7px;}
|
||||
.mt8{ margin-top:8px !important;}.mt9{ margin-top:9px !important;}.mt10{ margin-top:10px !important;}.mt12 { margin-top:12px !important;}
|
||||
.mt15 {margin-top:15px;}.mt16{ margin-top:16px !important;}.mt19 {margin-top:19px !important;}.mt20{margin-top: 20px;}.mt28 {margin-top:28px;}.mt30{ margin-top: 30px;}
|
||||
.mt35 {margin-top:35px;}.mt40{ margin-top: 40px;}.mt50{ margin-top:50px;}.mt100{ margin-top:100px;}.mb0 {margin-bottom: 0px !important;}.mb4{ margin-bottom:4px;}
|
||||
.mt35 {margin-top:35px;}.mt40{ margin-top: 40px;}.mt45{ margin-top: 45px;}.mt50{ margin-top:50px;}.mt100{ margin-top:100px;}.mb0 {margin-bottom: 0px !important;}.mb4{ margin-bottom:4px;}
|
||||
.mb5{ margin-bottom:5px;}.mb8 {margin-bottom:8px !important;}.pb5{ padding-bottom: 5px;}.mb10{ margin-bottom:10px !important;}.mb12 {margin-bottom:12px !important;}
|
||||
.mb15{margin-bottom: 15px;}.mb20{ margin-bottom:20px;}.mb25{ margin-bottom:25px;}.mb30 {margin-bottom:30px;}.mb40 {margin-bottom:40px;}.pl5{ padding-left:5px;}
|
||||
.pl10 {padding-left:10px;}.pr5 {padding-right:5px;}.pr10{padding-right: 10px;}.pl62 {padding-left: 62px;}.pl15{ padding-left:15px;}.pt5{ padding-top:5px;}
|
||||
|
@ -111,7 +111,7 @@ h4{ font-size:14px;}/*color:#3b3b3b;*/
|
|||
.w56 {width:56px;}.w60{ width:60px;}.w61{ width:61px;}.w65{ width:65px;}.w70{ width:70px;}.w80{ width:80px;}.w90{ width:90px;}.w100 {width: 100px;}.w110{width:110px !important;}
|
||||
.w108 {width:108px;}.w125{width:125px;}.w128{ width:128px;}.w130{ width:130px;}.w140{ width:140px;}.w145{ width:145px;}.w150{ width:150px;}
|
||||
.w160{width:160px !important;}.w170{width:170px;}.w180{width:180px;}.w186{ width:186px;}.w190{width: 190px;}.w196{ width:196px;}.w200{width: 200px;}.w210{ width:210px;}
|
||||
.w230{width:230px !important;}.w235{ width:235px !important;}.w265{ width: 265px;}.w270{ width: 270px;}.w280{ width:280px;}.w289{ width:289px !important;}
|
||||
.w230{width:230px !important;}.w235{ width:235px !important;}.w265{ width: 265px;}.w270{ width: 270px;}.w280{ width:280px;}.w289{ width:289px !important;}.w290{ width:290px !important;}
|
||||
.w300{ width:300px !important;}.w305{ width:305px;}.w350 {width:350px;}.w362 {width:362px;}.h400{height:400px !important;}.w430{ width:430px;}
|
||||
.W440{ width:440px;}.w450 {width:450px;}.w455{width:455px !important;}.w459{ width:459px;}.w460{ width:460px;}.w465{width:465px !important;}
|
||||
.w490{width:490px;}.w536{ width:536px;}.w543{ width:543px;}.w557{ width:557px;}.w570 {width:570px !important;}.w576{ width:576px;}.w590{ width:590px !important;}
|
||||
|
|
|
@ -188,10 +188,10 @@ a.hworkSearchIcon:hover {background:url(../images/nav_icon.png) -49px -1px no-re
|
|||
.HomeworkNameTitle{width: 285px;text-align: left;margin-left: 50px;}
|
||||
.HomeworkStuTitle{width: 80px;text-align: center;}
|
||||
.StudentName{display: table-cell;width: 115px;vertical-align: middle;text-align: left;height: 40px;}
|
||||
.score-tip {width:140px; color:#666; position:absolute; padding:3px 5px; border:1px solid #eaeaea; right:-183px; top:-8px; background-color:#ffffff; line-height:20px; box-shadow:0px 2px 8px rgba(146, 153, 169, 0.5); white-space:nowrap;}
|
||||
.score-tip {width:140px; color:#666; position:absolute; padding:3px 5px; border:1px solid #eaeaea; right:-223px; top:-30px; background-color:#ffffff; line-height:20px; box-shadow:0px 2px 8px rgba(146, 153, 169, 0.5); white-space:nowrap;}
|
||||
.score-tip em {display:block; border-width:8px; position:absolute; bottom:32px; left:-16px; border-style:dashed solid dashed dashed; border-color:transparent #eaeaea transparent transparent; font-size:0; line-height:0;}
|
||||
.score-tip font {display:block; border-width:8px; position:absolute; bottom:31px; left:-15px; border-style:dashed solid dashed dashed; border-color:transparent #FFF transparent transparent; font-size:0; line-height:0;}
|
||||
.anonymous-tip {width:100px;color:#666; position:absolute; padding:3px 5px; border:1px solid #eaeaea; right:-213px; top:-1px; background-color:#ffffff; line-height:20px; box-shadow:0px 2px 8px rgba(146, 153, 169, 0.5);}
|
||||
.anonymous-tip {width:100px;color:#666; position:absolute; padding:3px 5px; border:1px solid #eaeaea; right:-253px; top:-1px; background-color:#ffffff; line-height:20px; box-shadow:0px 2px 8px rgba(146, 153, 169, 0.5);}
|
||||
.anonymous-tip em {display:block; border-width:8px; position:absolute; bottom:25px; left:-16px; border-style:dashed solid dashed dashed; border-color:transparent #eaeaea transparent transparent; font-size:0; line-height:0;}
|
||||
.anonymous-tip font {display:block; border-width:8px; position:absolute; bottom:26px; left:-15px; border-style:dashed solid dashed dashed; border-color:transparent #FFF transparent transparent; font-size:0; line-height:0;}
|
||||
/*作业信息*/
|
||||
|
@ -494,4 +494,42 @@ a:hover.ex_icon_edit{ background:url(/images/course/icons.png) -21px -276px no-
|
|||
.archive_course_notice {width:220px; position:absolute; padding:5px 10px; white-space:nowrap; background-color:#fff; right:-265px; top:-15px; box-shadow:0px 2px 8px rgba(146, 153, 169, 0.5);}
|
||||
.archive_course_notice em {display:block; border-width:10px; position:absolute;top:26px; left:-20px; border-style:dashed solid dashed dashed; border-color:transparent #eaeaea transparent transparent; font-size:0; line-height:0;}
|
||||
.archive_course_notice span {display:block; border-width:10px; position:absolute;top:26px; left:-18px; border-style:dashed solid dashed dashed; border-color:transparent #fff transparent transparent; font-size:0; line-height:0;}
|
||||
.teacher_member_img{width:50px; height:50px; border: 1px solid #fff;-webkit-border-radius:50px;-moz-border-radius:50px;-o-border-radius:50px;border-radius:50px;}
|
||||
.teacher_member_img{width:50px; height:50px; border: 1px solid #fff;-webkit-border-radius:50px;-moz-border-radius:50px;-o-border-radius:50px;border-radius:50px;}
|
||||
|
||||
/* 设置页的头像更换 */
|
||||
.banner-course-avatar { width: 64px; height: 62px; position: relative; overflow: hidden;}
|
||||
.banner-course-inner {
|
||||
display: block;
|
||||
position: absolute;
|
||||
left: 0;
|
||||
top: 100%;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
background: #000;
|
||||
text-align: center;
|
||||
opacity: 0.3;
|
||||
-moz-transition: top ease 200ms;
|
||||
-o-transition: top ease 200ms;
|
||||
-webkit-transition: top ease 200ms;
|
||||
transition: top ease 200ms;
|
||||
}
|
||||
a.banner-course-notice {position: absolute; font-size: 12px; line-height: 20px; top: 102px; left: 10px; color: #fff;}
|
||||
.banner-course-avatar:hover .banner-course-inner { top: 0;}
|
||||
.banner-course-avatar:hover .banner-course-notice { top: 20px;}
|
||||
|
||||
.course_setting_org_fl {width: 49%; border-right: 1px solid #e5e5e5;}
|
||||
.course_setting_org_fr {width: 49%;}
|
||||
|
||||
/*20161222班级统计*/
|
||||
.game-setting-h3{ width: 100%; height: 40px; line-height: 40px; font-size: 14px; color: #666; font-weight: normal; background: #fff; border-bottom: 10px solid #eaebec;}
|
||||
.t-center{ text-align: center;}
|
||||
.table-td-w20{ width: 18%;}
|
||||
.table-td-w10{ width: 10%;}
|
||||
.table-td-w30{ width: 30%;}
|
||||
.new_project_title_width {font-size: 14px;color: #666; max-width: 180px;font-weight: normal;white-space: nowrap;overflow: hidden; text-overflow: ellipsis;}
|
||||
.syllabus_class_property { font-size: 12px; padding: 0 5px;border-radius: 3px;line-height: 14px;}
|
||||
.syllabus_class_private {color: #ff4a1b;border: 1px solid #ff4a1b;}
|
||||
.syllabus_class_open { color: #7dd26c; border: 1px solid #7dd26c;}
|
||||
.st_tips_box_inner{ position: absolute;line-height: 2.0;padding: 5px 10px; white-space: nowrap; background-color: #fff; left:100px; top: -5px; box-shadow: 0px 2px 8px rgba(146, 153, 169, 0.5);}
|
||||
.st_tips_box_inner span { display: block; border-width: 10px;position: absolute;top: 15px; left: -18px; border-style: dashed solid dashed dashed;border-color: transparent #fff transparent transparent;font-size: 0;line-height: 0;}
|
||||
.course_class_users_st_name{ display: inline-block;width:120px; overflow:hidden;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
|
||||
|
|
|
@ -14,7 +14,7 @@ input.radio-width90{ width: 90px; }
|
|||
.muban_table thead tr{ height:40px; line-height:40px;}
|
||||
.muban_table thead tr th{ border-bottom:1px solid #e5e5e5;}
|
||||
.muban_table tbody tr:hover{ background:#f5f5f5;}
|
||||
.muban_table tbody tr th{ height:40px; line-height:40px; border-bottom:1px solid #e5e5e5; font-weight:normal; color:#888;}
|
||||
.muban_table tbody tr td{ height:40px; border-bottom:1px solid #e5e5e5; font-weight:normal; color:#888;}
|
||||
/*模板icons 20161013byLB*/
|
||||
.muban_icons_orange{font-size: 12px;padding: 0 5px;border-radius: 3px;line-height: 14px;color: #ff4a1b;border: 1px solid #ff4a1b;}
|
||||
.muban_icons_blue{font-size: 12px;padding: 0 5px;border-radius: 3px;line-height: 14px;color: #3b94d6;border: 1px solid #3b94d6;}
|
||||
|
|
|
@ -607,6 +607,7 @@ a:hover.sy_class_ltitle{ color:#333;}
|
|||
.sy_new_table tbody tr:hover{ background:#f5f5f5;}
|
||||
.sy_new_table tbody tr td{ height:40px; line-height:40px; border-bottom:1px dashed #e5e5e5; font-weight:normal; color:#888; text-align: center}
|
||||
.sy_new_table tbody tr:last-child{ height:40px;}
|
||||
.sy_new_table tbody tr:last-child td{ border-bottom:none;}
|
||||
.sy_new_tchlist li{ height:30px; line-height:30px;}
|
||||
.sy_new_search{-webkit-border-radius:3px;-moz-border-radius:3px;-o-border-radius:3px;border-radius:3px; border:1px solid #d3d3d3; background:#fff; padding-left:5px; color:#888; height:32px; width:370px;box-shadow: inset 0px 0px 3px #dcdcdc; }
|
||||
.sy_new_tchbox{ background:#f5f5f5; padding:15px; margin:15px; margin-top:0px;}
|
||||
|
|
Loading…
Reference in New Issue