This commit is contained in:
suntao 2015-08-31 17:51:08 +08:00
commit 1d1d2f738d
10 changed files with 54 additions and 51 deletions

View File

@ -101,9 +101,9 @@
<a href="javascript:void(0);" class="homepageMenuText" onclick="$('#homepageLeftMenuCourses').slideToggle();">课程</a>
<% if is_current_user%>
<% if User.current.user_extensions && User.current.user_extensions.identity == 0 && User.current.allowed_to?(:add_course, nil, :global => true)%>
<%=link_to image_tag("../images/menu_setting.png",width:"14px", height: "14px",class: "homepageMenuSetting"), new_course_path%>
<%=link_to image_tag("../images/menu_setting.png",width:"14px", height: "14px",class: "homepageMenuSetting fr"), new_course_path%>
<% else%>
<%=link_to image_tag("../images/menu_setting.png",width:"14px", height: "14px",class: "homepageMenuSetting"), join_private_courses_courses_path ,:remote => true%>
<%=link_to image_tag("../images/menu_setting.png",width:"14px", height: "14px",class: "homepageMenuSetting fr"), join_private_courses_courses_path ,:remote => true%>
<% end%>
<% end%>
</div>
@ -117,7 +117,7 @@
<a href="javascript:void(0);" class="homepageMenuText" onclick="$('#homepageLeftMenuForge').slideToggle();">项目</a>
<% if is_current_user%>
<%=link_to image_tag("../images/menu_setting.png",width:"14px", height: "14px",class: "homepageMenuSetting"), new_project_path%>
<%=link_to image_tag("../images/menu_setting.png",width:"14px", height: "14px",class: "homepageMenuSetting fr"), new_project_path%>
<% end%>
</div>
<div class="homepageLeftMenuCourses" id="homepageLeftMenuForge">

View File

@ -10,10 +10,10 @@
<% else %>
<%= link_to activity.try(:user).try(:realname), user_path(activity.user_id), :class => "newsBlue mr15" %>
<% end %> TO <!--+"(课程名称)" -->
<%= link_to activity.course.name.to_s+" | 课程作业", homework_common_index_path(:course => activity.course.id), :class => "newsBlue ml15", :style=>"word-break:break-all" %>
<%= link_to activity.course.name.to_s+" | 课程作业", homework_common_index_path(:course => activity.course.id), :class => "newsBlue ml15"%>
</div>
<div class="homepagePostTitle break_word"> <!--+"(作业名称)"-->
<%= link_to activity.name.to_s, student_work_index_path(:homework => activity.id), :class => "postGrey", :style=>"word-break:break-all" %>
<%= link_to activity.name.to_s, student_work_index_path(:homework => activity.id), :class => "postGrey"%>
</div>
<div class="homepagePostSubmitContainer">
<div class="homepagePostSubmit">
@ -21,7 +21,7 @@
</div>
<div class="homepagePostDeadline">截止时间:<%= format_date(activity.end_time) %></div>
</div>
<div class="homepagePostIntro break_word" id="activity_description_<%= user_activity.id%>">
<div class="homepagePostIntro break_word upload_img" id="activity_description_<%= user_activity.id%>">
作业描述:<%= activity.description.html_safe %>
</div>
<!--<p style="display: none" id="activity_message_<%#= user_activity.id%>">

View File

@ -11,14 +11,14 @@
<%= link_to activity.try(:author).try(:realname), user_path(activity.author_id), :class => "newsBlue mr15" %>
<% end %>
TO
<%= link_to activity.course.name.to_s+" | 课程讨论区", course_boards_path(activity.course), :class => "newsBlue ml15 mr5", :style=>"word-break:break-all"%>
<%#= link_to activity.course.name.to_s+"(课程讨论区)", course_path(activity.course), :class => "newsBlue ml15 mr5", :style=>"word-break:break-all"%>
<%= link_to activity.course.name.to_s+" | 课程讨论区", course_boards_path(activity.course), :class => "newsBlue ml15 mr5"%>
<%#= link_to activity.course.name.to_s+"(课程讨论区)", course_path(activity.course), :class => "newsBlue ml15 mr5"%>
</div>
<div class="homepagePostTitle break_word">
<% if activity.parent_id.nil? %> <!--+"(帖子标题)"-->
<%= link_to activity.subject.to_s.html_safe, course_boards_path(activity.course,:parent_id =>activity.id, :topic_id => activity.id), :class=> "postGrey", :style=>"word-break:break-all" %>
<%= link_to activity.subject.to_s.html_safe, course_boards_path(activity.course,:parent_id =>activity.id, :topic_id => activity.id), :class=> "postGrey" %>
<% else %>
<%= link_to activity.parent.subject.to_s.html_safe, course_boards_path(activity.course,:parent_id =>activity.parent_id, :topic_id => activity.id), :class=> "postGrey", :style=>"word-break:break-all"%>
<%= link_to activity.parent.subject.to_s.html_safe, course_boards_path(activity.course,:parent_id =>activity.parent_id, :topic_id => activity.id), :class=> "postGrey"%>
<% end %>
</div>
<div class="homepagePostDate">
@ -26,7 +26,7 @@
</div>
<div class="homepagePostIntro break_word" id="activity_description_<%= user_activity.id%>">帖子描述:
<div class="homepagePostIntro break_word upload_img" id="activity_description_<%= user_activity.id%>">帖子描述:
<% if activity.parent_id.nil? %>
<%= activity.content.to_s.html_safe%>
<% else %>

View File

@ -10,15 +10,15 @@
<% else %>
<%= link_to activity.try(:author).try(:realname), user_path(activity.author_id), :class => "newsBlue mr15" %>
<% end %> TO <!--+"(课程名称)"-->
<%= link_to activity.course.name.to_s+" | 课程通知", course_news_index_path(activity.course), :class => "newsBlue ml15", :style => "word-break:break-all" %>
<%= link_to activity.course.name.to_s+" | 课程通知", course_news_index_path(activity.course), :class => "newsBlue ml15" %>
</div>
<div class="homepagePostTitle break_word"> <!--+"(通知标题)"-->
<%= link_to activity.title.to_s, news_path(activity), :class => "postGrey", :style => "word-break:break-all" %>
<%= link_to activity.title.to_s, news_path(activity), :class => "postGrey" %>
</div>
<div class="homepagePostDate">
发布时间:<%= format_date(activity.created_on) %>
</div>
<div class="homepagePostIntro break_word" id="activity_description_<%= user_activity.id %>">通知描述:<%= activity.description.html_safe %></div>
<div class="homepagePostIntro break_word upload_img" id="activity_description_<%= user_activity.id %>">通知描述:<%= activity.description.html_safe %></div>
<div class="homepagePostSetting" id="act-<%= user_activity.id %>" style="visibility: hidden">
<ul>

View File

@ -14,7 +14,7 @@
<%= link_to activity.try(:user).try(:realname), user_path(activity.user_id), :class => "newsBlue mr15" %>
<% end %>
TO
<%= link_to Course.find(activity.polls_group_id).name.to_s+" | 问卷", poll_index_path(:polls_type => "Course", :polls_group_id => activity.polls_group_id), :class => "newsBlue ml15", :style=>"word-break:break-all" %>
<%= link_to Course.find(activity.polls_group_id).name.to_s+" | 问卷", poll_index_path(:polls_type => "Course", :polls_group_id => activity.polls_group_id), :class => "newsBlue ml15" %>
<!--<a href="javascript:void(0);" class="newsBlue ml15">分布式计算环境(课程名称)</a>-->
</div>
<div class="homepagePostTitle break_word" >
@ -28,7 +28,7 @@
<div class="homepagePostDate">
发布时间:<%= format_date(activity.published_at) %>
</div>
<div class="homepagePostIntro break_word" id="activity_description_<%= user_activity.id%>">问卷描述:<%=activity.polls_description.html_safe.to_s%></div>
<div class="homepagePostIntro break_word upload_img" id="activity_description_<%= user_activity.id%>">问卷描述:<%=activity.polls_description.html_safe.to_s%></div>
<div class="homepagePostSetting" id="act-<%= user_activity.id %>" style="visibility: hidden">
<ul>
<li class="homepagePostSettingIcon">

View File

@ -10,10 +10,10 @@
<% else %>
<%= link_to activity.try(:author).try(:realname), user_path(activity.author_id), :class => "newsBlue mr15" %>
<% end %> TO
<%= link_to activity.project.name.to_s+" | 项目缺陷", project_issues_path(activity.project), :class => "newsBlue ml15", :style=>"word-break:break-all" %>
<%= link_to activity.project.name.to_s+" | 项目缺陷", project_issues_path(activity.project), :class => "newsBlue ml15"%>
</div>
<div class="homepagePostTitle break_word">
<%= link_to activity.subject.to_s, issue_path(activity), :class => "postGrey", :style=>"word-break:break-all" %>
<%= link_to activity.subject.to_s, issue_path(activity), :class => "postGrey" %>
<span class='<%= get_issue_priority(activity.priority_id)[0] %>'><%= get_issue_priority(activity.priority_id)[1] %></span>
</div>
<div class="homepagePostSubmitContainer">
@ -28,7 +28,7 @@
</div>
<div class="homepagePostDeadline">时间:<%=format_date(activity.created_on) %></div>
</div>
<div class="homepagePostIntro break_word" id="activity_description_<%= user_activity.id %>">缺陷描述:
<div class="homepagePostIntro break_word upload_img" id="activity_description_<%= user_activity.id %>">缺陷描述:
<% if activity.description? %>
<%= textAreailizable activity, :description, :attachments => activity.attachments %>
<% end %>

View File

@ -11,20 +11,22 @@
<%= link_to activity.try(:author).try(:realname), user_path(activity.author_id), :class => "newsBlue mr15" %>
<% end %>
TO
<%= link_to activity.project.name.to_s+" | 项目讨论区",project_boards_path(activity.project), :class => "newsBlue ml15 mr5", :style=>"word-break:break-all"%>
<%= link_to activity.project.name.to_s+" | 项目讨论区",project_boards_path(activity.project), :class => "newsBlue ml15 mr5"%>
<!--<a href="javascript:void(0);" class="newsBlue ml15 mr5"><%= activity.project.name %>(项目讨论区)</a>-->
</div>
<div class="homepagePostTitle break_word">
<% if activity.parent_id.nil? %>
<%= link_to activity.subject.to_s.html_safe, project_boards_path(activity.project,:parent_id =>activity.id, :topic_id => activity.id), :class=> "postGrey", :style=>"word-break:break-all" %>
<%= link_to activity.subject.to_s.html_safe, project_boards_path(activity.project,:parent_id =>activity.id, :topic_id => activity.id), :class=> "postGrey"
%>
<% else %>
<%= link_to activity.parent.subject.to_s.html_safe, project_boards_path(activity.project,:parent_id =>activity.parent_id, :topic_id => activity.id), :class=> "postGrey", :style=>"word-break:break-all"%>
<%= link_to activity.parent.subject.to_s.html_safe, project_boards_path(activity.project,:parent_id =>activity.parent_id, :topic_id => activity.id), :class=> "postGrey"
%>
<% end %>
</div>
<div class="homepagePostDate">
时间:<%= format_date(activity.created_on) %>
</div>
<div class="homepagePostIntro break_word" id="activity_description_<%= user_activity.id%>">帖子描述:
<div class="homepagePostIntro break_word upload_img" id="activity_description_<%= user_activity.id%>">帖子描述:
<% if activity.parent_id.nil? %>
<%= activity.content.to_s.html_safe%>
<% else %>

View File

@ -1,44 +1,46 @@
<%= javascript_include_tag "/assets/kindeditor/kindeditor" %>
<div class="HomeWorkCon">
<div>
<input type="text" name="homework_common[name]" id="homework_name" class="InputBox W700" maxlength="255" onkeyup="regex_homework_name();" placeholder="请输入作业标题" value="<%= homework.name%>" >
<input type="text" name="homework_common[name]" id="homework_name" class="InputBox W700" maxlength="255" onfocus="$('#homework_editor').show()" onkeyup="regex_homework_name();" placeholder="请输入作业标题" value="<%= homework.name%>" >
<p id="homework_name_span" class="c_red mt5"></p>
</div>
<div class="cl"></div>
<div class=" mt10">
<%= link_to "导入作业", user_import_homeworks_user_path(User.current.id),:class => "BlueCirBtn fl mr10",:remote => true%>
<span class="fl mt5 ml10">截止日期:</span>
<div class="calendar_div fl">
<input type="text" name="homework_common[end_time]" id="homework_end_time" placeholder="截止日期" class="InputBox fl W120 calendar_input" readonly="readonly" >
<%= calendar_for('homework_end_time')%>
</div>
</div>
<div class="cl"></div>
<div id="homework_editor" style="display: none">
<div class="mt10">
<% if edit_mode %>
<%= f.kindeditor :description, :editor_id => 'homework_description_editor', :height => "150px", :owner_id => homework.id, :owner_type => OwnerTypeHelper::HOMEWORKCOMMON %>
<% else %>
<%= hidden_field_tag :asset_id, params[:asset_id], :required => false, :style => 'display:none' %>
<%= f.kindeditor :description, :editor_id => 'homework_description_editor', :height => "150px" %>
<% end %>
</div>
<div class="cl"></div>
<div class="mt10">
<% if edit_mode %>
<%= f.kindeditor :description,:editor_id => 'homework_description_editor',:height => "150px",:owner_id => homework.id,:owner_type =>OwnerTypeHelper::HOMEWORKCOMMON %>
<% else %>
<%= hidden_field_tag :asset_id,params[:asset_id],:required => false,:style => 'display:none' %>
<%= f.kindeditor :description,:editor_id => 'homework_description_editor',:height => "150px" %>
<% end %>
<div class="mt10">
<!--<input type="text" class="InputBox W700 SearchIcon" placeholder="发送到课程" />-->
<%= select_tag :course_id, options_for_select(get_as_teacher_courses(User.current), homework.course_id), {:class => "InputBox w708"} %>
</div>
<div class="cl"></div>
<div id="homework_attachments">
<%= render :partial => 'users/user_homework_attachment', :locals => {:container => homework} %>
</div>
<div class="mt5 fr">
<a href="javascript:void(0);" class="BlueCirBtnMini fr" onclick=" submit_homework('new_homework_common');">发送</a>
<span class="fr mr10 mt3">或</span>
<a href="javascript:void(0);" class=" fr mr10 mt3" onclick="reset_homework();">取消</a>
</div>
</div>
<div class="cl"></div>
<div class="mt10">
<!--<input type="text" class="InputBox W700 SearchIcon" placeholder="发送到课程" />-->
<%= select_tag :course_id,options_for_select(get_as_teacher_courses(User.current),homework.course_id), {:class => "InputBox w708"} %>
</div>
<div class="cl"></div>
<div id="homework_attachments">
<%= render :partial => 'users/user_homework_attachment', :locals => { :container => homework } %>
</div>
<div class="mt5 fr">
<a href="javascript:void(0);" class="BlueCirBtnMini fr" onclick=" submit_homework('new_homework_common');">发送</a>
<span class="fr mr10 mt3">或</span>
<a href="javascript:void(0);" class=" fr mr10 mt3" onclick="reset_homework();">取消</a>
</div>
</div>
<div class="cl"></div>

View File

@ -49,7 +49,7 @@ a.coursesLineGrey:hover {color:#ffffff;}
.homepageLeftMenuMore {height:18px;}
.homepageLeftMenuMore:hover {background-color:#b3e0ee;}
.homepageLeftMenuMoreIcon {background:url(../images/homepage_icon.png) -74px -240px no-repeat; display:block; height:18px;}
.homepageMenuSetting {display:inline-block; margin-left:155px;}
.homepageMenuSetting {display:inline-block; margin-right: 17px; margin-top: 18px;}
a.homepageMenuText {color:#484848; font-size:16px; margin-left:20px;}
.homepageLeftLabelContainer {width:238px; border:1px solid #dddddd; background-color:#ffffff; margin-top:10px;}
.homepageLabelText {color:#484848; font-size:16px; margin-left:10px; margin-bottom:12px; display:block;}

View File

@ -528,7 +528,7 @@ a.coursesLineGrey:hover {color:#ffffff;}
.homepageLeftMenuMore {height:18px;}
.homepageLeftMenuMore:hover {background-color:#269ac9;}
.homepageLeftMenuMoreIcon {background:url(../images/homepage_icon.png) -74px -240px no-repeat; display:block; height:18px;}
.homepageMenuSetting {display:inline-block; margin-left:155px;}
.homepageMenuSetting {display:inline-block; margin-right: 17px; margin-top: 18px;}
a.homepageMenuText {color:#484848; font-size:16px; margin-left:20px;}
.homepageLeftLabelContainer {width:238px; border:1px solid #dddddd; background-color:#ffffff; margin-top:10px;}
.homepageLabelText {color:#484848; font-size:16px; margin-left:10px; margin-bottom:12px; display:block;}
@ -954,7 +954,6 @@ img.ui-datepicker-trigger {
.is_public_checkbox{display: none !important;}
.is_public{display: none !important;}
.ui-corner-left{background: #64bdd9;}
.homepagePostIntro img{max-width: 100%;}