Merge branch 'szzh' of https://git.trustie.net/jacknudt/trustieforge into szzh
This commit is contained in:
commit
067f3be598
|
@ -229,7 +229,11 @@ class AttachmentsController < ApplicationController
|
|||
@attachment.container.init_journal(User.current)
|
||||
end
|
||||
if @attachment.container
|
||||
@attachment.container.attachments.delete(@attachment)
|
||||
if @attachment.container_type == "Issue"
|
||||
@attachment.destroy
|
||||
else
|
||||
@attachment.container.attachments.delete(@attachment)
|
||||
end
|
||||
else
|
||||
@attachment.destroy
|
||||
end
|
||||
|
@ -281,7 +285,7 @@ class AttachmentsController < ApplicationController
|
|||
format.js
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
def delete_homework
|
||||
@bid = @attachment.container.bid
|
||||
# Make sure association callbacks are called
|
||||
|
@ -344,13 +348,13 @@ class AttachmentsController < ApplicationController
|
|||
end
|
||||
|
||||
respond_to do |format|
|
||||
format.js
|
||||
format.js
|
||||
end
|
||||
rescue NoMethodError
|
||||
@save_flag = false
|
||||
@save_message = [] << l(:error_attachment_empty)
|
||||
respond_to do |format|
|
||||
format.js
|
||||
format.js
|
||||
end
|
||||
end
|
||||
|
||||
|
|
|
@ -875,7 +875,7 @@ class UsersController < ApplicationController
|
|||
#显示更多用户课程
|
||||
def user_courses4show
|
||||
@page = params[:page].to_i + 1
|
||||
@courses = @user.courses.visible.select("courses.*,(SELECT MAX(created_at) FROM `course_activities` WHERE course_activities.course_id = courses.id) AS a").order("a desc").limit(5).offset(@page * 5)
|
||||
@courses = @user.courses.visible.where("is_delete =?", 0).select("courses.*,(SELECT MAX(created_at) FROM `course_activities` WHERE course_activities.course_id = courses.id) AS a").order("a desc").limit(5).offset(@page * 5)
|
||||
end
|
||||
|
||||
#显示更多用户项目
|
||||
|
|
|
@ -180,7 +180,7 @@ module ApiHelper
|
|||
if timePassed < 0
|
||||
updateAtValue = "时间有问题"
|
||||
elsif timePassed < ONE_MINUTE
|
||||
updateAtValue = "一分钟前"
|
||||
updateAtValue = "1分钟前"
|
||||
elsif timePassed < ONE_HOUR
|
||||
timeIntoFormat = timePassed / ONE_MINUTE
|
||||
updateAtValue = timeIntoFormat.to_s + "分钟前"
|
||||
|
|
|
@ -199,8 +199,7 @@ class Message < ActiveRecord::Base
|
|||
def act_as_forge_activity
|
||||
# 如果project为空,那么就是课程相关的消息
|
||||
if self.board.project_id != -1 && self.parent_id.nil?
|
||||
self.forge_acts << ForgeActivity.new(:user_id => self.author_id,
|
||||
:project_id => self.board.project.id)
|
||||
self.forge_acts << ForgeActivity.new(:user_id => self.author_id, :project_id => self.board.project.id)
|
||||
end
|
||||
end
|
||||
|
||||
|
|
|
@ -1,7 +1,24 @@
|
|||
<% if @in_user_center%>
|
||||
$("#user_activity_<%= @user_activity_id%>").replaceWith("<%= escape_javascript(render :partial => 'users/user_blog', :locals => {:activity => @article,:user_activity_id =>@user_activity_id}) %>");
|
||||
init_activity_KindEditor_data(<%= @user_activity_id%>,"","87%", 'UserActivity');
|
||||
// init_activity_KindEditor_data(<%#= @user_activity_id%>,"","87%", 'UserActivity');
|
||||
<% else%>
|
||||
$("#user_activity_<%= @user_activity_id%>").replaceWith("<%= escape_javascript(render :partial => 'blogs/article', :locals => {:activity => @article,:user_activity_id =>@user_activity_id}) %>");
|
||||
//init_activity_KindEditor_data(<%#= @user_activity_id%>,"","87%", 'UserActivity');
|
||||
<% end %>
|
||||
init_activity_KindEditor_data(<%= @user_activity_id%>,"","87%", 'UserActivity');
|
||||
<% end %>
|
||||
showNormalImage('activity_description_<%= @user_activity_id %>');
|
||||
if($("#intro_content_<%= @user_activity_id %>").height() > 810) {
|
||||
$("#intro_content_show_<%= @user_activity_id %>").show();
|
||||
}
|
||||
$("#intro_content_show_<%= @user_activity_id %>").click(function(){
|
||||
$("#activity_description_<%= @user_activity_id %>").toggleClass("maxh360");
|
||||
$("#activity_description_<%= @user_activity_id%>").toggleClass("lh18");
|
||||
$("#intro_content_show_<%= @user_activity_id %>").hide();
|
||||
$("#intro_content_hide_<%= @user_activity_id %>").show();
|
||||
});
|
||||
$("#intro_content_hide_<%= @user_activity_id %>").click(function(){
|
||||
$("#activity_description_<%= @user_activity_id %>").toggleClass("maxh360");
|
||||
$("#activity_description_<%= @user_activity_id%>").toggleClass("lh18");
|
||||
$("#intro_content_hide_<%= @user_activity_id %>").hide();
|
||||
$("#intro_content_show_<%= @user_activity_id %>").show();
|
||||
});
|
|
@ -57,13 +57,14 @@
|
|||
<div class="homepagePostDate">
|
||||
发帖时间:<%= format_time(activity.created_on) %>
|
||||
</div>
|
||||
|
||||
<div class="homepagePostIntro break_word upload_img list_style" id="activity_description_<%= user_activity_id%>">
|
||||
<% if activity.parent_id.nil? %>
|
||||
<%= activity.content.to_s.html_safe%>
|
||||
<% else %>
|
||||
<%= activity.parent.content.to_s.html_safe%>
|
||||
<% end %>
|
||||
<div class="homepagePostIntro break_word upload_img list_style maxh360 lh18 table_maxWidth" id="activity_description_<%= user_activity_id%>">
|
||||
<div id="intro_content_<%= user_activity_id%>">
|
||||
<% if activity.parent_id.nil? %>
|
||||
<%= activity.content.to_s.html_safe%>
|
||||
<% else %>
|
||||
<%= activity.parent.content.to_s.html_safe%>
|
||||
<% end %>
|
||||
</div>
|
||||
</div>
|
||||
<div class="cl"></div>
|
||||
<div class=" fl" style="width: 600px">
|
||||
|
@ -72,6 +73,11 @@
|
|||
<%= render :partial => 'blog_comments/attachments_links', :locals => {:attachments => activity.attachments, :options => options, :is_float => true} %>
|
||||
<% end %>
|
||||
</div>
|
||||
<div class="cl"></div>
|
||||
<div id="intro_content_show_<%= user_activity_id%>" class="fr" style="display:none;"><a href="javascript:void(0);" class="linkBlue">[展开]</a></div>
|
||||
<div id="intro_content_hide_<%= user_activity_id%>" class="fr" style="display:none;"><a href="javascript:void(0);" class="linkBlue">[收起]</a></div>
|
||||
<div class="cl"></div>
|
||||
|
||||
<div class="homepagePostSetting" id="act-<%= user_activity_id %>" style="visibility: hidden">
|
||||
<ul>
|
||||
<li class="homepagePostSettingIcon">
|
||||
|
|
|
@ -76,15 +76,21 @@
|
|||
$(function () {
|
||||
init_activity_KindEditor_data(<%= topic.id%>, null, "87%", "<%=topic.class.to_s%>");
|
||||
showNormalImage('activity_description_<%= topic.id %>');
|
||||
/*var description_images=$("div#activity_description_<%#= topic.id %>").find("img");
|
||||
if (description_images.length>0) {
|
||||
for (var i=0; i<description_images.length; i++){
|
||||
var image=$(description_images[i]);
|
||||
var element=$("<a></a>").attr("href",image.attr('src'));
|
||||
image.wrap(element);
|
||||
}
|
||||
}
|
||||
$('#activity_description_<%#= topic.id %> a').colorbox({rel:'nofollow', close: "关闭", returnFocus: false});*/
|
||||
if($("#intro_content_<%= topic.id %>").height() > 810) {
|
||||
$("#intro_content_show_<%= topic.id %>").show();
|
||||
}
|
||||
$("#intro_content_show_<%= topic.id %>").click(function(){
|
||||
$("#activity_description_<%= topic.id %>").toggleClass("maxh360");
|
||||
$("#activity_description_<%= topic.id%>").toggleClass("lh18");
|
||||
$("#intro_content_show_<%= topic.id %>").hide();
|
||||
$("#intro_content_hide_<%= topic.id %>").show();
|
||||
});
|
||||
$("#intro_content_hide_<%= topic.id %>").click(function(){
|
||||
$("#activity_description_<%= topic.id %>").toggleClass("maxh360");
|
||||
$("#activity_description_<%= topic.id%>").toggleClass("lh18");
|
||||
$("#intro_content_hide_<%= topic.id %>").hide();
|
||||
$("#intro_content_show_<%= topic.id %>").show();
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<% if topic %>
|
||||
|
|
|
@ -42,15 +42,21 @@
|
|||
$(function () {
|
||||
init_activity_KindEditor_data(<%= topic.id%>, null, "87%");
|
||||
showNormalImage('activity_description_<%= topic.id %>');
|
||||
/*var description_images=$("div#activity_description_<%#= topic.id %>").find("img");
|
||||
if (description_images.length>0) {
|
||||
for (var i=0; i<description_images.length; i++){
|
||||
var image=$(description_images[i]);
|
||||
var element=$("<a></a>").attr("href",image.attr('src'));
|
||||
image.wrap(element);
|
||||
}
|
||||
}
|
||||
$('#activity_description_<%#= topic.id %> a').colorbox({rel:'nofollow', close: "关闭", returnFocus: false});*/
|
||||
if($("#intro_content_<%= topic.id %>").height() > 810) {
|
||||
$("#intro_content_show_<%= topic.id %>").show();
|
||||
}
|
||||
$("#intro_content_show_<%= topic.id %>").click(function(){
|
||||
$("#activity_description_<%= topic.id %>").toggleClass("maxh360");
|
||||
$("#activity_description_<%= topic.id%>").toggleClass("lh18");
|
||||
$("#intro_content_show_<%= topic.id %>").hide();
|
||||
$("#intro_content_hide_<%= topic.id %>").show();
|
||||
});
|
||||
$("#intro_content_hide_<%= topic.id %>").click(function(){
|
||||
$("#activity_description_<%= topic.id %>").toggleClass("maxh360");
|
||||
$("#activity_description_<%= topic.id%>").toggleClass("lh18");
|
||||
$("#intro_content_hide_<%= topic.id %>").hide();
|
||||
$("#intro_content_show_<%= topic.id %>").show();
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<% if topic %>
|
||||
|
|
|
@ -41,15 +41,21 @@
|
|||
$(function () {
|
||||
init_activity_KindEditor_data(<%= topic.id%>, null, "87%");
|
||||
showNormalImage('activity_description_<%= topic.id %>');
|
||||
/*var description_images=$("div#activity_description_<%#= topic.id %>").find("img");
|
||||
if (description_images.length>0) {
|
||||
for (var i=0; i<description_images.length; i++){
|
||||
var image=$(description_images[i]);
|
||||
var element=$("<a></a>").attr("href",image.attr('src'));
|
||||
image.wrap(element);
|
||||
}
|
||||
}
|
||||
$('#activity_description_<%#= topic.id %> a').colorbox({rel:'nofollow', close: "关闭", returnFocus: false});*/
|
||||
if($("#intro_content_<%= topic.id %>").height() > 810) {
|
||||
$("#intro_content_show_<%= topic.id %>").show();
|
||||
}
|
||||
$("#intro_content_show_<%= topic.id %>").click(function(){
|
||||
$("#activity_description_<%= topic.id %>").toggleClass("maxh360");
|
||||
$("#activity_description_<%= topic.id%>").toggleClass("lh18");
|
||||
$("#intro_content_show_<%= topic.id %>").hide();
|
||||
$("#intro_content_hide_<%= topic.id %>").show();
|
||||
});
|
||||
$("#intro_content_hide_<%= topic.id %>").click(function(){
|
||||
$("#activity_description_<%= topic.id %>").toggleClass("maxh360");
|
||||
$("#activity_description_<%= topic.id%>").toggleClass("lh18");
|
||||
$("#intro_content_hide_<%= topic.id %>").hide();
|
||||
$("#intro_content_show_<%= topic.id %>").show();
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<% if topic %>
|
||||
|
|
|
@ -2,19 +2,19 @@
|
|||
<% is_teacher = User.current.logged? && (User.current.admin? || User.current.allowed_to?(:as_teacher,@course)) %>
|
||||
<% if show_nav?(@course.homework_commons.count) %>
|
||||
<div class="subNav">
|
||||
<%= link_to l(:label_homework), homework_common_index_path(:course => @course.id), :class => "f14 c_blue02 ml10"%>
|
||||
<%= link_to l(:label_homework), homework_common_index_path(:course => @course.id), :class => "f14 c_blue02 ml10 fn"%>
|
||||
<%= link_to( "", homework_common_index_path(:course => @course.id,:is_new => 1), :class => 'courseMenuSetting', :title =>"#{l(:label_course_homework_new)}") if is_teacher %>
|
||||
</div>
|
||||
<% end %>
|
||||
<% if show_nav?(@course.news.count) %>
|
||||
<div class="subNav">
|
||||
<%= link_to l(:label_course_news), course_news_index_path(@course), :class => "f14 c_blue02 ml10" %>
|
||||
<%= link_to l(:label_course_news), course_news_index_path(@course), :class => "f14 c_blue02 ml10 fn" %>
|
||||
<%= link_to( "", new_course_news_path(@course), :class => 'courseMenuSetting', :title =>"#{l(:label_course_news_new)}") if is_teacher %>
|
||||
</div>
|
||||
<% end %>
|
||||
<% if show_nav?(course_file_num) %>
|
||||
<div class="subNav">
|
||||
<%= link_to l(:label_course_file), course_files_path(@course), :class => "f14 c_blue02 ml10" %>
|
||||
<%= link_to l(:label_course_file), course_files_path(@course), :class => "f14 c_blue02 ml10 fn" %>
|
||||
<% if is_teacher || (@course.publish_resource == 1 && User.current.member_of_course?(@course)) %>
|
||||
<!--link_to( "+#{l(:label_upload_files)}", course_files_path(@course), :class => 'subnav_green ml95 c_white')-->
|
||||
<a class="courseMenuSetting" title="上传资源" href="javascript:void(0);" onclick="course_files_upload();"> </a>
|
||||
|
@ -23,25 +23,25 @@
|
|||
<% end %>
|
||||
<% if show_nav?(@course.boards.first ? @course.boards.first.topics.count : 0) %>
|
||||
<div class="subNav">
|
||||
<%= link_to l(:label_course_board), course_boards_path(@course), :class => "f14 c_blue02 ml10" %>
|
||||
<%= link_to l(:label_course_board), course_boards_path(@course), :class => "f14 c_blue02 ml10 fn" %>
|
||||
<%= link_to( "",course_boards_path(@course, :flag => true, :is_new => 1), :class => 'courseMenuSetting', :title =>"#{l(:label_message_new)}") if User.current.member_of_course?(@course) && @course.boards.first %>
|
||||
</div>
|
||||
<% end %>
|
||||
<% if show_nav?(course_feedback_count) %>
|
||||
<div class="subNav">
|
||||
<%= link_to l(:label_course_feedback), course_feedback_path(@course), :class => "f14 c_blue02 ml10" %>
|
||||
<%= link_to l(:label_course_feedback), course_feedback_path(@course), :class => "f14 c_blue02 ml10 fn" %>
|
||||
<%= link_to "", course_feedback_path(@course), :class => 'courseMenuSetting', :title =>"#{l(:label_course_feedback)}", :id => "course_jour_count"%>
|
||||
</div>
|
||||
<% end %>
|
||||
<% if show_nav?(course_poll_count) %>
|
||||
<div class="subNav">
|
||||
<%= link_to l(:label_poll), poll_index_path(:polls_type => "Course", :polls_group_id => @course.id), :class => " f14 c_blue02 ml10"%>
|
||||
<%= link_to l(:label_poll), poll_index_path(:polls_type => "Course", :polls_group_id => @course.id), :class => " f14 c_blue02 ml10 fn"%>
|
||||
<%= link_to( "", new_poll_path(:polls_type => "Course",:polls_group_id => @course.id), :class => 'courseMenuSetting', :title =>"#{l(:label_new_poll)}") if is_teacher %>
|
||||
</div>
|
||||
<% end %>
|
||||
<% if show_nav?(User.current.allowed_to?(:as_teacher,@course)? @course.exercises.count : @course.exercises.where("exercise_status=2").count) %>
|
||||
<div class="subNav">
|
||||
<%= link_to "在线测验", exercise_index_path(:course_id => @course.id), :class => " f14 c_blue02 ml10"%>
|
||||
<%= link_to "在线测验", exercise_index_path(:course_id => @course.id), :class => " f14 c_blue02 ml10 fn"%>
|
||||
<%= link_to( "", new_exercise_path(:course_id => @course.id), :class => 'courseMenuSetting', :title =>"新建试卷") if is_teacher %>
|
||||
</div>
|
||||
<% end %>
|
|
@ -5,4 +5,20 @@
|
|||
<% elsif @org_subfield %>
|
||||
$("#user_activity_<%= @user_activity_id%>").replaceWith("<%= escape_javascript(render :partial => 'organizations/org_subfield_message', :locals => {:activity => @topic,:user_activity_id =>@user_activity_id}) %>");
|
||||
<%end%>
|
||||
init_activity_KindEditor_data(<%= @user_activity_id%>,"","87%", "UserActivity");
|
||||
init_activity_KindEditor_data(<%= @user_activity_id %>,"","87%", "UserActivity");
|
||||
showNormalImage('activity_description_<%= @user_activity_id %>');
|
||||
if($("#intro_content_<%= @user_activity_id %>").height() > 810) {
|
||||
$("#intro_content_show_<%= @user_activity_id %>").show();
|
||||
}
|
||||
$("#intro_content_show_<%= @user_activity_id %>").click(function(){
|
||||
$("#activity_description_<%= @user_activity_id %>").toggleClass("maxh360");
|
||||
$("#activity_description_<%= @user_activity_id %>").toggleClass("lh18");
|
||||
$("#intro_content_show_<%= @user_activity_id %>").hide();
|
||||
$("#intro_content_hide_<%= @user_activity_id %>").show();
|
||||
});
|
||||
$("#intro_content_hide_<%= @user_activity_id %>").click(function(){
|
||||
$("#activity_description_<%= @user_activity_id %>").toggleClass("maxh360");
|
||||
$("#activity_description_<%= @user_activity_id %>").toggleClass("lh18");
|
||||
$("#intro_content_hide_<%= @user_activity_id %>").hide();
|
||||
$("#intro_content_show_<%= @user_activity_id %>").show();
|
||||
});
|
|
@ -44,9 +44,7 @@
|
|||
<option value="1">
|
||||
<%= l(:label_account_identity_student) %>
|
||||
</option>
|
||||
<option value="2">
|
||||
<%= l(:label_account_identity_enterprise) %>
|
||||
</option>
|
||||
|
||||
<option value="3">
|
||||
<%= l(:label_account_identity_developer) %>
|
||||
</option>
|
||||
|
|
|
@ -44,7 +44,27 @@
|
|||
<span class="green_homework_btn_cir ml5" title="目前教师和教辅正在评阅">教师评阅中</span>
|
||||
<% end%>
|
||||
<% end%>
|
||||
<div class="cl"></div>
|
||||
<% if activity.homework_type == 3 && activity.homework_detail_group.base_on_project == 1%>
|
||||
<span class="c_red">系统提示:该作业要求各组长<%=link_to "创建项目", new_project_path(:host=>Setting.host_name),:class=>"c_red",:title=>"新建项目",:style=>"text-decoration:underline;"%>,组成员加入项目,然后由组长关联项目。谢谢配合!</span>
|
||||
<% elsif activity.homework_type == 3 && activity.homework_detail_group.base_on_project == 0%>
|
||||
<span class="c_red">系统提示:该作业要求各组长提交作品,提交作品时请添加组成员。谢谢配合!</span>
|
||||
<% end %>
|
||||
<div class="homepagePostSubmitContainer">
|
||||
<% if activity.homework_type == 3 && !is_teacher && activity.homework_detail_group.base_on_project == 1 && User.current.member_of_course?(activity.course)%>
|
||||
<% projects = cur_user_projects_for_homework activity %>
|
||||
<% works = cur_user_works_for_homework activity %>
|
||||
<% if works.nil? && projects.nil? %>
|
||||
<div class="homepagePostSubmit">
|
||||
<%=link_to "关联项目",new_student_work_project_student_work_index_path(:homework => activity.id,:is_in_course=>-1,:user_activity_id=>user_activity_id,:course_activity=>course_activity),remote: true,:class=> 'c_blue', :title=> '请各组长关联作业项目' %>
|
||||
<%#= relate_project(activity,is_teacher,-1,user_activity_id,course_activity) %>
|
||||
</div>
|
||||
<% elsif works.nil? %>
|
||||
<div class="homepagePostSubmit">
|
||||
<%=link_to "取消关联",cancel_relate_project_student_work_index_path(:homework => activity.id,:is_in_course=>-1,:user_activity_id=>user_activity_id,:course_activity=>course_activity), :confirm => "您确定要取消关联吗?", remote: true,:class => "c_blue", :title=> '取消关联项目' %>
|
||||
</div>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<div class="homepagePostSubmit">
|
||||
<% is_teacher = User.current.allowed_to?(:as_teacher,activity.course) %>
|
||||
<%= user_for_homework_common activity,is_teacher %>
|
||||
|
@ -61,8 +81,16 @@
|
|||
<%= activity.language_name%>
|
||||
</div>
|
||||
<% end %>
|
||||
|
||||
<div class="homepagePostDeadline">截止时间:<%= activity.end_time.to_s %> 23:59</div>
|
||||
<% if activity.homework_type == 3 && activity.homework_detail_group%>
|
||||
<div class="homepagePostDeadline mr15">
|
||||
分组人数:<%=activity.homework_detail_group.min_num %>-<%=activity.homework_detail_group.max_num %> 人
|
||||
</div>
|
||||
<% end %>
|
||||
<% if activity.homework_detail_manual && activity.homework_detail_manual.comment_status < 2 %>
|
||||
<div class="homepagePostDeadline">提交截止时间:<%= activity.end_time.to_s %> 23:59</div>
|
||||
<% elsif activity.homework_detail_manual && activity.homework_detail_manual.comment_status >= 2 %>
|
||||
<div class="homepagePostDeadline">匿评截止时间:<%= activity.homework_detail_manual.evaluation_end.to_s %> 23:59</div>
|
||||
<% end %>
|
||||
</div>
|
||||
<div class="homepagePostIntro break_word upload_img list_style maxh360 lh18 table_maxWidth" id="activity_description_<%= user_activity_id%>">
|
||||
<div id="intro_content_<%= user_activity_id%>">
|
||||
|
@ -73,10 +101,88 @@
|
|||
<div id="intro_content_show_<%= user_activity_id%>" class="fr" style="display:none;"><a href="javascript:void(0);" class="linkBlue">[展开]</a></div>
|
||||
<div id="intro_content_hide_<%= user_activity_id%>" class="fr" style="display:none;"><a href="javascript:void(0);" class="linkBlue">[收起]</a></div>
|
||||
<div class="cl"></div>
|
||||
<div class="mt10">
|
||||
<div class="homepagePostDeadline">
|
||||
迟交扣分:<%= activity.late_penalty%>分
|
||||
</div>
|
||||
<% if activity.anonymous_comment == 0%>
|
||||
<div class="homepagePostDeadline" style="float: right; margin-right: 220px;" id="evaluation_start_time_<%=user_activity_id %>">
|
||||
匿评开启时间:<%= activity.homework_detail_manual.evaluation_start%> 00:00
|
||||
</div>
|
||||
<% end %>
|
||||
</div>
|
||||
<div class="cl"></div>
|
||||
<div>
|
||||
<div class="homepagePostDeadline">
|
||||
缺评扣分:<%= activity.homework_detail_manual.absence_penalty%>分/作品
|
||||
</div>
|
||||
<% if activity.anonymous_comment == 0%>
|
||||
<div class="homepagePostDeadline" style="float: right; margin-right: 220px;" id="evaluation_end_time_<%=user_activity_id %>">
|
||||
匿评关闭时间:<%= activity.homework_detail_manual.evaluation_end%> 23:59
|
||||
</div>
|
||||
<% end %>
|
||||
</div>
|
||||
<div class="cl"></div>
|
||||
<% if activity.student_works.count != 0 %>
|
||||
<% sw = activity.student_works.reorder("created_at desc").first %>
|
||||
<div class="mt10 homepagePostDeadline">
|
||||
<%=time_from_now sw.created_at %><%= link_to sw.user.show_name, user_activities_path(sw.user_id), :class => "newsBlue ml5 mr5"%>提交了作品
|
||||
</div>
|
||||
<% end %>
|
||||
<div class="cl"></div>
|
||||
<% if activity.student_works.count != 0 %>
|
||||
<% sw_id = "("+activity.student_works.map{|sw| sw.id}.join(",")+")" %>
|
||||
<% student_work_scores = StudentWorksScore.where("student_work_id in #{sw_id}").reorder("created_at desc") %>
|
||||
<% unless student_work_scores.empty? %>
|
||||
<% last_score = student_work_scores.first %>
|
||||
<div class="mt5 homepagePostDeadline">
|
||||
<%=time_from_now last_score.created_at %><%= link_to last_score.user.show_name, user_activities_path(last_score.user_id), :class => "newsBlue ml5 mr5"%>评阅了作品
|
||||
</div>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<div class="cl"></div>
|
||||
<div>
|
||||
<%= render :partial => 'student_work/work_attachments', :locals => {:attachments => activity.attachments} %>
|
||||
<div class="cl"></div>
|
||||
</div>
|
||||
<% if activity.homework_type == 3 && activity.homework_detail_group.base_on_project == 1 %>
|
||||
<div class="mt10">
|
||||
<% projects = activity.student_work_projects.where("is_leader = 1") %>
|
||||
<div class="fl mr20 fontGrey3 w80">
|
||||
已关联项目:<%='各小组尚未将小组项目关联到本次作业。' if projects.empty? %>
|
||||
</div>
|
||||
<% projects.each do |pro| %>
|
||||
<% project = Project.find pro.project_id %>
|
||||
<script type="text/javascript">
|
||||
$(document).ready(function(){
|
||||
$("#project_img_<%=project.id %>_<%=activity.id %>").mouseover(function(){
|
||||
$("#relatePInfo_<%=project.id %>_<%=activity.id %>").css("display","block");
|
||||
}).mouseout(function(){
|
||||
$("#relatePInfo_<%=project.id %>_<%=activity.id %>").css("display","none");
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
||||
<div class="mr20 mb10 fl w80" style="text-align: center;">
|
||||
<% if project.is_public || User.current.member_of?(project) || User.current.admin? %>
|
||||
<%= link_to image_tag(url_to_avatar(project),:width=>"40",:height => "40",:class => "borderRadius"),project_path(project.id,:host=>Setting.host_name),:id=>"project_img_"+project.id.to_s+"_"+activity.id.to_s,:alt =>"项目头像" %>
|
||||
<% else %>
|
||||
<%= image_tag(url_to_avatar(project),:width=>"40",:height => "40",:class => "borderRadius",:id=>"project_img_"+project.id.to_s+"_"+activity.id.to_s,:alt =>"项目头像") %>
|
||||
<% end %>
|
||||
<% time=project.updated_on %>
|
||||
<% time=ForgeActivity.where("project_id=?",project.id).last.updated_at if ForgeActivity.where("project_id=?",project.id).last %>
|
||||
<p><span class="captainName" title="<%=(User.find project.user_id).show_name %>"><%=(User.find project.user_id).show_name %></span><span style="vertical-align: top;">(组长)</span></p>
|
||||
<p><%=time_from_now time %></p>
|
||||
<div class="relatePInfo" id="relatePInfo_<%=project.id %>_<%=activity.id %>">
|
||||
项目名称:<%=project.name %><br />
|
||||
创建者:<%=(User.find project.user_id).show_name %>(组长)<br />
|
||||
更新时间:<%=time_from_now time %>
|
||||
</div>
|
||||
</div>
|
||||
<% end %>
|
||||
</div>
|
||||
<% end %>
|
||||
<div class="cl"></div>
|
||||
<% if is_teacher%>
|
||||
<% comment_status = activity.homework_detail_manual.comment_status %>
|
||||
<div class="homepagePostSetting">
|
||||
|
|
|
@ -34,7 +34,7 @@
|
|||
$(function () {
|
||||
init_activity_KindEditor_data(<%= activity.id%>, null, "87%", "<%= activity.class.to_s %>");
|
||||
showNormalImage('activity_description_<%= activity.id %>');
|
||||
if ($("#intro_content_<%= activity.id %>").height() > 360) {
|
||||
if ($("#intro_content_<%= activity.id %>").height() > 810) {
|
||||
$("#intro_content_show_<%= activity.id %>").show();
|
||||
}
|
||||
$("#intro_content_show_<%= activity.id %>").click(function () {
|
||||
|
|
|
@ -124,6 +124,24 @@
|
|||
<% end %>
|
||||
</div>
|
||||
<div class="cl"></div>
|
||||
<% if activity.student_works.count != 0 %>
|
||||
<% sw = activity.student_works.reorder("created_at desc").first %>
|
||||
<div class="mt10 homepagePostDeadline">
|
||||
<%=time_from_now sw.created_at %><%= link_to sw.user.show_name, user_activities_path(sw.user_id), :class => "newsBlue ml5 mr5"%>提交了作品
|
||||
</div>
|
||||
<% end %>
|
||||
<div class="cl"></div>
|
||||
<% if activity.student_works.count != 0 %>
|
||||
<% sw_id = "("+activity.student_works.map{|sw| sw.id}.join(",")+")" %>
|
||||
<% student_work_scores = StudentWorksScore.where("student_work_id in #{sw_id}").reorder("created_at desc") %>
|
||||
<% unless student_work_scores.empty? %>
|
||||
<% last_score = student_work_scores.first %>
|
||||
<div class="mt5 homepagePostDeadline">
|
||||
<%=time_from_now last_score.created_at %><%= link_to last_score.user.show_name, user_activities_path(last_score.user_id), :class => "newsBlue ml5 mr5"%>评阅了作品
|
||||
</div>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<div class="cl"></div>
|
||||
<div>
|
||||
<%= render :partial => 'student_work/work_attachments', :locals => {:attachments => activity.attachments} %>
|
||||
<div class="cl"></div>
|
||||
|
@ -131,7 +149,7 @@
|
|||
<% if activity.homework_type == 3 && activity.homework_detail_group.base_on_project == 1 %>
|
||||
<div class="mt10">
|
||||
<% projects = activity.student_work_projects.where("is_leader = 1") %>
|
||||
<div class="mb10 mr5 fontGrey3">
|
||||
<div class="fl mr20 fontGrey3 w80">
|
||||
已关联项目:<%='各小组尚未将小组项目关联到本次作业。' if projects.empty? %>
|
||||
</div>
|
||||
<% projects.each do |pro| %>
|
||||
|
@ -154,7 +172,7 @@
|
|||
<% end %>
|
||||
<% time=project.updated_on %>
|
||||
<% time=ForgeActivity.where("project_id=?",project.id).last.updated_at if ForgeActivity.where("project_id=?",project.id).last %>
|
||||
<p><span class="captainName"><%=(User.find project.user_id).show_name %></span><span style="vertical-align: top;">(组长)</span></p>
|
||||
<p><span class="captainName" title="<%=(User.find project.user_id).show_name %>"><%=(User.find project.user_id).show_name %></span><span style="vertical-align: top;">(组长)</span></p>
|
||||
<p><%=time_from_now time %></p>
|
||||
<div class="relatePInfo" id="relatePInfo_<%=project.id %>_<%=activity.id %>">
|
||||
项目名称:<%=project.name %><br />
|
||||
|
|
|
@ -86,9 +86,7 @@
|
|||
<div class="homepagePostReply">
|
||||
<div class="topBorder" style="display: <%= count>0 ? 'none': '' %>"></div>
|
||||
<div class="homepagePostReplyBanner" style="display: <%= count>0 ? '': 'none' %>">
|
||||
<div class="homepagePostReplyBannerCount" onclick="expand_reply_input('#reply_input_<%= user_activity_id %>');">回复(
|
||||
<%=count %>
|
||||
)</div>
|
||||
<div class="homepagePostReplyBannerCount" onclick="expand_reply_input('#reply_input_<%= user_activity_id %>');">回复(<%=count %>)</div>
|
||||
<div class="homepagePostReplyBannerTime"><%#=format_date(activity.updated_on)%></div>
|
||||
<%if count>3 %>
|
||||
<div class="homepagePostReplyBannerMore"><a id="reply_btn_<%=user_activity_id%>" onclick="expand_reply('#reply_div_<%= user_activity_id %> li','#reply_btn_<%=user_activity_id%>')" data-count="<%= count %>" data-init="0" class=" replyGrey" href="javascript:void(0)" value="show_help" >展开更多</a></div>
|
||||
|
|
|
@ -127,6 +127,24 @@
|
|||
<% end %>
|
||||
</div>
|
||||
<div class="cl"></div>
|
||||
<% if homework_common.student_works.count != 0 %>
|
||||
<% sw = homework_common.student_works.reorder("created_at desc").first %>
|
||||
<div class="mt10 homepagePostDeadline">
|
||||
<%=time_from_now sw.created_at %><%= link_to sw.user.show_name, user_activities_path(sw.user_id), :class => "newsBlue ml5 mr5"%>提交了作品
|
||||
</div>
|
||||
<% end %>
|
||||
<div class="cl"></div>
|
||||
<% if homework_common.student_works.count != 0 %>
|
||||
<% sw_id = "("+homework_common.student_works.map{|sw| sw.id}.join(",")+")" %>
|
||||
<% student_work_scores = StudentWorksScore.where("student_work_id in #{sw_id}").reorder("created_at desc") %>
|
||||
<% unless student_work_scores.empty? %>
|
||||
<% last_score = student_work_scores.first %>
|
||||
<div class="mt5 homepagePostDeadline">
|
||||
<%=time_from_now last_score.created_at %><%= link_to last_score.user.show_name, user_activities_path(last_score.user_id), :class => "newsBlue ml5 mr5"%>评阅了作品
|
||||
</div>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<div class="cl"></div>
|
||||
<div>
|
||||
<%= render :partial => 'student_work/work_attachments', :locals => {:attachments => homework_common.attachments} %>
|
||||
<div class="cl"></div>
|
||||
|
@ -134,7 +152,7 @@
|
|||
<% if homework_common.homework_type == 3 && homework_common.homework_detail_group.base_on_project == 1 %>
|
||||
<div class="mt10">
|
||||
<% projects = homework_common.student_work_projects.where("is_leader = 1") %>
|
||||
<div class="fl mr5 fontGrey3">
|
||||
<div class="fl mr20 fontGrey3 w80">
|
||||
已关联项目:<%='各小组尚未将小组项目关联到本次作业。' if projects.empty? %>
|
||||
</div>
|
||||
<% projects.each do |pro| %>
|
||||
|
@ -156,7 +174,7 @@
|
|||
<% end %>
|
||||
<% time=project.updated_on %>
|
||||
<% time=ForgeActivity.where("project_id=?",project.id).last.updated_at if ForgeActivity.where("project_id=?",project.id).last %>
|
||||
<p><span class="captainName"><%=(User.find project.user_id).show_name %></span><span style="vertical-align: top;">(组长)</span></p>
|
||||
<p><span class="captainName" title="<%=(User.find project.user_id).show_name %>"><%=(User.find project.user_id).show_name %></span><span style="vertical-align: top;">(组长)</span></p>
|
||||
<p><%=time_from_now time %></p>
|
||||
<div class="relatePInfo" id="relatePInfo_<%=project.id %>_<%=homework_common.id %>">
|
||||
项目名称:<%=project.name %><br />
|
||||
|
|
|
@ -67,6 +67,7 @@ RedmineApp::Application.routes.draw do
|
|||
|
||||
get '/', to: 'organizations#show', defaults: { id: 5 }, constraints: {subdomain: 'micros'}
|
||||
get '/', to: 'organizations#show', defaults: { id: 23 }, constraints: {subdomain: 'nubot'}
|
||||
get '/', to: 'organizations#show', defaults: { id: 1 }, constraints: {subdomain: 'team'}
|
||||
|
||||
resources :org_member do
|
||||
member do
|
||||
|
|
|
@ -0,0 +1,14 @@
|
|||
class DropMessageForForgeActivities < ActiveRecord::Migration
|
||||
def up
|
||||
forge_activities = ForgeActivity.where("forge_act_type =?", "Message")
|
||||
forge_activities.each do |fa|
|
||||
# 删除项目动态中,讨论区也会多一条记录问题
|
||||
if fa.forge_act && !fa.forge_act.parent_id.nil?
|
||||
fa.delete
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
def down
|
||||
end
|
||||
end
|
272
db/schema.rb
272
db/schema.rb
|
@ -11,8 +11,7 @@
|
|||
#
|
||||
# It's strongly recommended to check this file into your version control system.
|
||||
|
||||
|
||||
ActiveRecord::Schema.define(:version => 20151102090519) do
|
||||
ActiveRecord::Schema.define(:version => 20160105073350) do
|
||||
|
||||
create_table "activities", :force => true do |t|
|
||||
t.integer "act_id", :null => false
|
||||
|
@ -67,6 +66,41 @@ ActiveRecord::Schema.define(:version => 20151102090519) do
|
|||
t.datetime "updated_at", :null => false
|
||||
end
|
||||
|
||||
create_table "at_messages", :force => true do |t|
|
||||
t.integer "user_id"
|
||||
t.integer "at_message_id"
|
||||
t.string "at_message_type"
|
||||
t.boolean "viewed", :default => false
|
||||
t.string "container_type"
|
||||
t.integer "container_id"
|
||||
t.datetime "created_at", :null => false
|
||||
t.datetime "updated_at", :null => false
|
||||
t.integer "sender_id"
|
||||
end
|
||||
|
||||
add_index "at_messages", ["user_id"], :name => "index_at_messages_on_user_id"
|
||||
|
||||
create_table "attachment_histories", :force => true do |t|
|
||||
t.integer "container_id"
|
||||
t.string "container_type"
|
||||
t.string "filename", :default => ""
|
||||
t.string "disk_filename", :default => ""
|
||||
t.integer "filesize", :default => 0
|
||||
t.string "content_type", :default => ""
|
||||
t.string "digest", :limit => 40, :default => ""
|
||||
t.integer "downloads", :default => 0
|
||||
t.integer "author_id"
|
||||
t.datetime "created_on"
|
||||
t.string "description"
|
||||
t.string "disk_directory"
|
||||
t.integer "attachtype"
|
||||
t.integer "is_public"
|
||||
t.integer "copy_from"
|
||||
t.integer "quotes"
|
||||
t.integer "version"
|
||||
t.integer "attachment_id"
|
||||
end
|
||||
|
||||
create_table "attachments", :force => true do |t|
|
||||
t.integer "container_id"
|
||||
t.string "container_type", :limit => 30
|
||||
|
@ -384,6 +418,20 @@ ActiveRecord::Schema.define(:version => 20151102090519) do
|
|||
t.integer "container_id", :default => 0
|
||||
end
|
||||
|
||||
create_table "course_contributor_scores", :force => true do |t|
|
||||
t.integer "course_id"
|
||||
t.integer "user_id"
|
||||
t.integer "message_num"
|
||||
t.integer "message_reply_num"
|
||||
t.integer "news_reply_num"
|
||||
t.integer "resource_num"
|
||||
t.integer "journal_num"
|
||||
t.integer "journal_reply_num"
|
||||
t.datetime "created_at", :null => false
|
||||
t.datetime "updated_at", :null => false
|
||||
t.integer "total_score"
|
||||
end
|
||||
|
||||
create_table "course_groups", :force => true do |t|
|
||||
t.string "name"
|
||||
t.integer "course_id"
|
||||
|
@ -427,8 +475,8 @@ ActiveRecord::Schema.define(:version => 20151102090519) 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"
|
||||
|
@ -438,14 +486,16 @@ ActiveRecord::Schema.define(:version => 20151102090519) 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 "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"
|
||||
end
|
||||
|
@ -532,23 +582,32 @@ ActiveRecord::Schema.define(:version => 20151102090519) do
|
|||
add_index "documents", ["created_on"], :name => "index_documents_on_created_on"
|
||||
add_index "documents", ["project_id"], :name => "documents_project_id"
|
||||
|
||||
create_table "dts", :force => true do |t|
|
||||
t.string "IPLineCode"
|
||||
t.string "Description"
|
||||
t.string "Num"
|
||||
t.string "Variable"
|
||||
t.string "TraceInfo"
|
||||
t.string "Method"
|
||||
create_table "dts", :primary_key => "Num", :force => true do |t|
|
||||
t.string "Defect", :limit => 50
|
||||
t.string "Category", :limit => 50
|
||||
t.string "File"
|
||||
t.string "IPLine"
|
||||
t.string "Review"
|
||||
t.string "Category"
|
||||
t.string "Defect"
|
||||
t.string "PreConditions"
|
||||
t.string "StartLine"
|
||||
t.string "Method"
|
||||
t.string "Module", :limit => 20
|
||||
t.string "Variable", :limit => 50
|
||||
t.integer "StartLine"
|
||||
t.integer "IPLine"
|
||||
t.string "IPLineCode", :limit => 200
|
||||
t.string "Judge", :limit => 15
|
||||
t.integer "Review", :limit => 1
|
||||
t.string "Description"
|
||||
t.text "PreConditions", :limit => 2147483647
|
||||
t.text "TraceInfo", :limit => 2147483647
|
||||
t.text "Code", :limit => 2147483647
|
||||
t.integer "project_id"
|
||||
t.datetime "created_at", :null => false
|
||||
t.datetime "updated_at", :null => false
|
||||
t.datetime "created_at"
|
||||
t.datetime "updated_at"
|
||||
t.integer "id", :null => false
|
||||
end
|
||||
|
||||
create_table "editor_of_documents", :force => true do |t|
|
||||
t.integer "editor_id"
|
||||
t.integer "org_document_comment_id"
|
||||
t.datetime "created_at"
|
||||
end
|
||||
|
||||
create_table "enabled_modules", :force => true do |t|
|
||||
|
@ -573,6 +632,66 @@ ActiveRecord::Schema.define(:version => 20151102090519) do
|
|||
add_index "enumerations", ["id", "type"], :name => "index_enumerations_on_id_and_type"
|
||||
add_index "enumerations", ["project_id"], :name => "index_enumerations_on_project_id"
|
||||
|
||||
create_table "exercise_answers", :force => true do |t|
|
||||
t.integer "user_id"
|
||||
t.integer "exercise_question_id"
|
||||
t.integer "exercise_choice_id"
|
||||
t.text "answer_text"
|
||||
t.datetime "created_at", :null => false
|
||||
t.datetime "updated_at", :null => false
|
||||
end
|
||||
|
||||
create_table "exercise_choices", :force => true do |t|
|
||||
t.integer "exercise_question_id"
|
||||
t.text "choice_text"
|
||||
t.integer "choice_position"
|
||||
t.datetime "created_at", :null => false
|
||||
t.datetime "updated_at", :null => false
|
||||
end
|
||||
|
||||
create_table "exercise_questions", :force => true do |t|
|
||||
t.text "question_title"
|
||||
t.integer "question_type"
|
||||
t.integer "question_number"
|
||||
t.integer "exercise_id"
|
||||
t.datetime "created_at", :null => false
|
||||
t.datetime "updated_at", :null => false
|
||||
t.integer "question_score"
|
||||
end
|
||||
|
||||
create_table "exercise_standard_answers", :force => true do |t|
|
||||
t.integer "exercise_question_id"
|
||||
t.integer "exercise_choice_id"
|
||||
t.text "answer_text"
|
||||
t.datetime "created_at", :null => false
|
||||
t.datetime "updated_at", :null => false
|
||||
end
|
||||
|
||||
create_table "exercise_users", :force => true do |t|
|
||||
t.integer "user_id"
|
||||
t.integer "exercise_id"
|
||||
t.integer "score"
|
||||
t.datetime "start_at"
|
||||
t.datetime "created_at", :null => false
|
||||
t.datetime "updated_at", :null => false
|
||||
t.datetime "end_at"
|
||||
t.integer "status"
|
||||
end
|
||||
|
||||
create_table "exercises", :force => true do |t|
|
||||
t.text "exercise_name"
|
||||
t.text "exercise_description"
|
||||
t.integer "course_id"
|
||||
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 "publish_time"
|
||||
t.datetime "end_time"
|
||||
t.integer "show_result"
|
||||
end
|
||||
|
||||
create_table "first_pages", :force => true do |t|
|
||||
t.string "web_title"
|
||||
t.string "title"
|
||||
|
@ -662,6 +781,19 @@ ActiveRecord::Schema.define(:version => 20151102090519) do
|
|||
t.integer "anonymous_comment", :default => 0
|
||||
end
|
||||
|
||||
add_index "homework_commons", ["course_id", "id"], :name => "index_homework_commons_on_course_id_and_id"
|
||||
|
||||
create_table "homework_detail_groups", :force => true do |t|
|
||||
t.integer "homework_common_id"
|
||||
t.integer "min_num"
|
||||
t.integer "max_num"
|
||||
t.integer "base_on_project"
|
||||
t.datetime "created_at", :null => false
|
||||
t.datetime "updated_at", :null => false
|
||||
end
|
||||
|
||||
add_index "homework_detail_groups", ["homework_common_id"], :name => "index_homework_detail_groups_on_homework_common_id"
|
||||
|
||||
create_table "homework_detail_manuals", :force => true do |t|
|
||||
t.float "ta_proportion"
|
||||
t.integer "comment_status"
|
||||
|
@ -818,16 +950,6 @@ ActiveRecord::Schema.define(:version => 20151102090519) do
|
|||
|
||||
add_index "journal_details", ["journal_id"], :name => "journal_details_journal_id"
|
||||
|
||||
create_table "journal_details_copy", :force => true do |t|
|
||||
t.integer "journal_id", :default => 0, :null => false
|
||||
t.string "property", :limit => 30, :default => "", :null => false
|
||||
t.string "prop_key", :limit => 30, :default => "", :null => false
|
||||
t.text "old_value"
|
||||
t.text "value"
|
||||
end
|
||||
|
||||
add_index "journal_details_copy", ["journal_id"], :name => "journal_details_journal_id"
|
||||
|
||||
create_table "journal_replies", :id => false, :force => true do |t|
|
||||
t.integer "journal_id"
|
||||
t.integer "user_id"
|
||||
|
@ -947,6 +1069,7 @@ ActiveRecord::Schema.define(:version => 20151102090519) do
|
|||
t.boolean "locked", :default => false
|
||||
t.integer "sticky", :default => 0
|
||||
t.integer "reply_id"
|
||||
t.integer "quotes"
|
||||
end
|
||||
|
||||
add_index "messages", ["author_id"], :name => "index_messages_on_author_id"
|
||||
|
@ -964,6 +1087,7 @@ ActiveRecord::Schema.define(:version => 20151102090519) do
|
|||
t.datetime "created_on"
|
||||
t.integer "comments_count", :default => 0, :null => false
|
||||
t.integer "course_id"
|
||||
t.integer "sticky", :default => 0
|
||||
end
|
||||
|
||||
add_index "news", ["author_id"], :name => "index_news_on_author_id"
|
||||
|
@ -1049,10 +1173,46 @@ ActiveRecord::Schema.define(:version => 20151102090519) do
|
|||
t.integer "project_id"
|
||||
end
|
||||
|
||||
create_table "org_activities", :force => true do |t|
|
||||
t.integer "user_id"
|
||||
t.integer "org_act_id"
|
||||
t.string "org_act_type"
|
||||
t.integer "container_id"
|
||||
t.string "container_type"
|
||||
t.datetime "created_at", :null => false
|
||||
t.datetime "updated_at", :null => false
|
||||
end
|
||||
|
||||
create_table "org_courses", :force => true do |t|
|
||||
t.integer "organization_id"
|
||||
t.integer "course_id"
|
||||
t.datetime "created_at"
|
||||
end
|
||||
|
||||
create_table "org_document_comments", :force => true do |t|
|
||||
t.text "title"
|
||||
t.text "content"
|
||||
t.integer "organization_id"
|
||||
t.integer "creator_id"
|
||||
t.integer "parent_id"
|
||||
t.integer "reply_id"
|
||||
t.datetime "created_at", :null => false
|
||||
t.datetime "updated_at", :null => false
|
||||
t.boolean "locked", :default => false
|
||||
t.integer "sticky", :default => 0
|
||||
t.integer "org_subfield_id"
|
||||
end
|
||||
|
||||
create_table "org_member_roles", :force => true do |t|
|
||||
t.integer "org_member_id"
|
||||
t.integer "role_id"
|
||||
end
|
||||
|
||||
create_table "org_members", :force => true do |t|
|
||||
t.integer "user_id"
|
||||
t.integer "organization_id"
|
||||
t.string "role"
|
||||
t.integer "user_id"
|
||||
t.integer "organization_id"
|
||||
t.datetime "created_at", :null => false
|
||||
t.datetime "updated_at", :null => false
|
||||
end
|
||||
|
||||
create_table "org_projects", :force => true do |t|
|
||||
|
@ -1212,27 +1372,30 @@ ActiveRecord::Schema.define(:version => 20151102090519) do
|
|||
end
|
||||
|
||||
create_table "projects", :force => true do |t|
|
||||
t.string "name", :default => "", :null => false
|
||||
t.string "name", :default => "", :null => false
|
||||
t.text "description"
|
||||
t.string "homepage", :default => ""
|
||||
t.boolean "is_public", :default => true, :null => false
|
||||
t.string "homepage", :default => ""
|
||||
t.boolean "is_public", :default => true, :null => false
|
||||
t.integer "parent_id"
|
||||
t.datetime "created_on"
|
||||
t.datetime "updated_on"
|
||||
t.string "identifier"
|
||||
t.integer "status", :default => 1, :null => false
|
||||
t.integer "status", :default => 1, :null => false
|
||||
t.integer "lft"
|
||||
t.integer "rgt"
|
||||
t.boolean "inherit_members", :default => false, :null => false
|
||||
t.boolean "inherit_members", :default => false, :null => false
|
||||
t.integer "project_type"
|
||||
t.boolean "hidden_repo", :default => false, :null => false
|
||||
t.integer "attachmenttype", :default => 1
|
||||
t.boolean "hidden_repo", :default => false, :null => false
|
||||
t.integer "attachmenttype", :default => 1
|
||||
t.integer "user_id"
|
||||
t.integer "dts_test", :default => 0
|
||||
t.integer "dts_test", :default => 0
|
||||
t.string "enterprise_name"
|
||||
t.integer "organization_id"
|
||||
t.integer "project_new_type"
|
||||
t.integer "gpid"
|
||||
t.integer "forked_from_project_id"
|
||||
t.integer "forked_count"
|
||||
t.integer "commits_count", :default => 0
|
||||
end
|
||||
|
||||
add_index "projects", ["lft"], :name => "index_projects_on_lft"
|
||||
|
@ -1397,6 +1560,21 @@ ActiveRecord::Schema.define(:version => 20151102090519) do
|
|||
t.integer "project_id"
|
||||
end
|
||||
|
||||
create_table "student_work_projects", :force => true do |t|
|
||||
t.integer "homework_common_id"
|
||||
t.integer "student_work_id"
|
||||
t.integer "project_id"
|
||||
t.integer "user_id"
|
||||
t.integer "is_leader"
|
||||
t.datetime "created_at", :null => false
|
||||
t.datetime "updated_at", :null => false
|
||||
end
|
||||
|
||||
add_index "student_work_projects", ["homework_common_id"], :name => "index_student_work_projects_on_homework_common_id"
|
||||
add_index "student_work_projects", ["project_id"], :name => "index_student_work_projects_on_project_id"
|
||||
add_index "student_work_projects", ["student_work_id"], :name => "index_student_work_projects_on_student_work_id"
|
||||
add_index "student_work_projects", ["user_id"], :name => "index_student_work_projects_on_user_id"
|
||||
|
||||
create_table "student_work_tests", :force => true do |t|
|
||||
t.integer "student_work_id"
|
||||
t.datetime "created_at", :null => false
|
||||
|
@ -1424,6 +1602,8 @@ ActiveRecord::Schema.define(:version => 20151102090519) do
|
|||
t.boolean "is_test", :default => false
|
||||
end
|
||||
|
||||
add_index "student_works", ["homework_common_id", "user_id"], :name => "index_student_works_on_homework_common_id_and_user_id"
|
||||
|
||||
create_table "student_works_evaluation_distributions", :force => true do |t|
|
||||
t.integer "student_work_id"
|
||||
t.integer "user_id"
|
||||
|
|
|
@ -216,8 +216,8 @@ a.menuGrey:hover {color:#fe7d68;}
|
|||
#navSearchAlert {display:none;}
|
||||
.homepagePostReplyjournal{margin-left: 15px; float: left;}
|
||||
|
||||
.lh18 {line-height: 18px;}
|
||||
.maxh360 {max-height: 360px;}
|
||||
/*.lh18 {line-height: 18px;}*/
|
||||
/*.maxh360 {max-height: 360px;}*/
|
||||
|
||||
/*邮件邀请*/
|
||||
.box_main{ width:345px; margin:0 auto;}
|
||||
|
@ -1220,6 +1220,7 @@ a:hover.blueCir{ background:#3598db; color:#fff;}
|
|||
.hworkPrName {width:110px; max-width:110px; overflow:hidden; white-space: nowrap; text-overflow:ellipsis; float:left; height:18px; line-height:18px; font-size:12px; color:#888888; text-align:center;}
|
||||
.mr150 {margin-right:150px;}
|
||||
.relatePInfo {text-align: left; position:absolute; background-color:#ffffff; padding:3px 8px; white-space:nowrap; box-shadow:0px 2px 8px rgba(146, 153, 169, 0.5); z-index:999; color:#585858; cursor:pointer; display:none;}
|
||||
.captainName {max-width:40px; white-space: nowrap; text-overflow: ellipsis; overflow: hidden; display: inline-block;}
|
||||
|
||||
/*上传资源弹窗*/
|
||||
.resourceUploadPopup {width:400px; height:auto; border:3px solid #269ac9 !important; padding-left:16px; padding-bottom:16px; background-color:#ffffff; position:absolute; top:50%; left:50%; margin-left:-200px; z-index:1000;}
|
||||
|
@ -1259,3 +1260,5 @@ div.disable_link {background-color: #c1c1c1 !important;}
|
|||
.fileTagWrap{ width:710px;}
|
||||
|
||||
.boxShadow {box-shadow:0px 2px 8px rgba(146, 153, 169, 0.5);}
|
||||
|
||||
.fn {font-weight:normal}
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -103,4 +103,8 @@ ul.wlist{ float:right; border-bottom:none; height:30px; margin-top:20px; }
|
|||
.sectionContent span {width:175px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; display:inline-block; height:18px; vertical-align:middle;}.popbox_polls{width:300px;height:100px;position:fixed !important;z-index:100;left:50%;top:50%;margin:-100px 0 0 -150px;
|
||||
background:#fff; -moz-border-radius:5px; -webkit-border-radius:5px; border-radius:5px; box-shadow:0px 0px 8px #194a81; overflow:auto;}
|
||||
.org_login_list a {color:#269ac9;}
|
||||
div.flash {margin-top :0px !important}
|
||||
div.flash {margin-top :0px !important}
|
||||
|
||||
.w80{ width:80px;}
|
||||
.relatePInfo {text-align: left; position:absolute; background-color:#ffffff; padding:3px 8px; white-space:nowrap; box-shadow:0px 2px 8px rgba(146, 153, 169, 0.5); z-index:999; color:#585858; cursor:pointer; display:none;}
|
||||
.captainName {max-width:40px; white-space: nowrap; text-overflow: ellipsis; overflow: hidden; display: inline-block;}
|
|
@ -962,12 +962,6 @@ a:hover.Reply_pic{border:1px solid #64bdd9;}
|
|||
margin-bottom: 5px;
|
||||
font-weight: bold;
|
||||
}
|
||||
.maxh360 {
|
||||
max-height: 360px;
|
||||
}
|
||||
.lh18 {
|
||||
line-height: 18px;
|
||||
}
|
||||
.homepagePostIntro {
|
||||
font-size: 14px;
|
||||
color: #484848;
|
||||
|
|
|
@ -958,3 +958,7 @@ span.at a{color:#269ac9;text-decoration: none;}
|
|||
.sectionContent span {width:160px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; display:inline-block; height:20px; vertical-align:top;}
|
||||
.orgDirection {width:392px; background-color:#f1f1f1; height:30px; vertical-align:middle; line-height:30px; color:#585858; padding-left:10px;}
|
||||
.orgSendSearch {border:1px solid #dddddd; outline:none; width:262px; height:22px; padding-left:10px; float:left;}
|
||||
|
||||
/*文本描述展开高度*/
|
||||
.maxh360 {max-height: 810px;}
|
||||
.lh18 { line-height: 18px;}
|
Loading…
Reference in New Issue