1.修改课程讨论区回复不会自动换号

2.本地化代码
This commit is contained in:
sw 2014-09-16 10:42:17 +08:00
parent d1435e07d4
commit 1b97361ec6
6 changed files with 43 additions and 41 deletions

View File

@ -173,10 +173,6 @@
<%= pagination_links_full @reply_pages, @reply_count, :per_page_links => false %>
</div>
<% end %>
<% if !@topic.locked? && authorize_for_course('messages', 'reply') %>
<div id="reply" style="display:none;">
<%= form_for @reply, :as => :reply, :url => {:action => 'reply', :id => @topic}, :html => {:multipart => true, :id => 'message-form'} do |f| %>

View File

@ -1,39 +1,46 @@
<script src="/javascripts/ckeditor/ckeditor.js?1404953555" type="text/javascript"></script>
<%= error_messages_for 'message' %>
<% replying ||= false %>
<div class="box ph10_5">
<!--[form:message]-->
<% unless replying %>
<p><label for="message_subject"><%= l(:field_subject) %><span class="required"> *&nbsp;&nbsp;</span></label><br/>
<%= f.text_field :subject, :size => 60, :style => "width: 99%;", :id => "message_subject" %><!--by young-->
</p>
<% else %>
<p><label for="message_subject"><%= l(:field_subject) %><span class="required"> *&nbsp;&nbsp;</span></label><br/>
<%= f.text_field :subject, :size => 60, :style => "width: 99%;", :id => "message_subject", :readonly => true %>
</p>
<% end %>
<p>
<% unless replying %>
<% if @message.safe_attribute? 'sticky' %>
<%= f.check_box :sticky %> <%= label_tag 'message_sticky', l(:label_board_sticky) %>
<% end %>
<% if @message.safe_attribute? 'locked' %>
<%= f.check_box :locked %> <%= label_tag 'message_locked', l(:label_board_locked) %>
<% end %>
<% end %>
</p>
<p><label for="message_subject"><%= l(:field_description) %><span class="required"> *&nbsp;&nbsp;</span></label>
<div id="message_quote" class="wiki" style="width: 100%;word-break: break-all;word-wrap: break-word;"></div>
<%= text_area :quote,:quote,:style => 'display:none' %>
</p>
<p>
<%= label_tag "message_content", l(:description_message_content), :class => "hidden-for-sighted" %>
<%= f.text_area :content, :cols => 80, :rows => 13, :class => 'wiki-edit', :id => 'message_content' %></p>
<!--[form:message]-->
<% unless replying %>
<p><label for="message_subject"><%= l(:field_subject) %><span class="required"> *&nbsp;&nbsp;</span></label><br/>
<%= f.text_field :subject, :size => 60, :style => "width: 99%;", :id => "message_subject" %><!--by young-->
</p>
<% else %>
<p><label for="message_subject"><%= l(:field_subject) %><span class="required"> *&nbsp;&nbsp;</span></label><br/>
<%= f.text_field :subject, :size => 60, :style => "width: 99%;", :id => "message_subject", :readonly => true %>
</p>
<% end %>
<p>
<% unless replying %>
<% if @message.safe_attribute? 'sticky' %>
<%= f.check_box :sticky %> <%= label_tag 'message_sticky', l(:label_board_sticky) %>
<% end %>
<% if @message.safe_attribute? 'locked' %>
<%= f.check_box :locked %> <%= label_tag 'message_locked', l(:label_board_locked) %>
<% end %>
<% end %>
</p>
<p>
<label for="message_subject"><%= l(:field_description) %>
<span class="required"> *&nbsp;&nbsp;</span></label>
<div id="message_quote" class="wiki" style="width: 100%;word-break: break-all;word-wrap: break-word;"></div>
<%= text_area :quote,:quote,:style => 'display:none' %>
</p>
<p>
<%= label_tag "message_content", l(:description_message_content), :class => "hidden-for-sighted" %>
<%= f.text_area :content, :cols => 80, :rows => 13, :class => 'wiki-edit', :id => 'message_content' %>
</p>
<!--[eoform:message]-->
<!--[eoform:message]-->
<p><%= l(:label_attachment_plural) %><br />
<%= render :partial => 'attachments/form_course', :locals => {:container => @message,:isReply => @isReply} %></p>
<p>
<%= l(:label_attachment_plural) %>
<br />
<%= render :partial => 'attachments/form_course', :locals => {:container => @message,:isReply => @isReply} %>
</p>
</div>

View File

@ -5,4 +5,4 @@
<% end %>
<% end %>
&nbsp;&nbsp;&nbsp;&nbsp;
<%= link_to "更多>>", {:controller => 'courses', :action => 'index', :school_id => school_id} %>
<%= link_to l(:label_more), {:controller => 'courses', :action => 'index', :school_id => school_id} %>

View File

@ -161,7 +161,7 @@
<% end %>
<% end %>
&nbsp;&nbsp;
<%= link_to l(:label_more_information), {:controller => 'contests', :action => 'index'}, :target => "_blank" %>
<%= link_to l(:label_more), {:controller => 'contests', :action => 'index'}, :target => "_blank" %>
</span>
<div class="d-p-projectlist-box">
<div class="d-p-projectlist">

View File

@ -75,7 +75,7 @@
<div id="J_Slide" class="d-p-index-box d-p-index-hotproject">
<h3><strong>新开课程</strong></h3>
<h3><strong><%= l(:lable_hot_course)%></strong></h3>
<% if @school_id %>
<% school_course = find_miracle_course(10,7, @school_id) %>
<% else %>

View File

@ -231,9 +231,6 @@ zh:
mail_body_wiki_content_added: "'%{id}' wiki页面已由 %{author} 添加。"
mail_subject_wiki_content_updated: "'%{id}' wiki页面已更新。"
mail_body_wiki_content_updated: "'%{id}' wiki页面已由 %{author} 更新。"
field_name: 名称
#added by huang
field_tea_name: 教师
@ -2122,4 +2119,6 @@ zh:
label_my_school: 我的学校
label_all_schol: 全部学校
label_select_province: 请选择省份
label_search_conditions_not_null: 搜索条件不能为空
label_search_conditions_not_null: 搜索条件不能为空
lable_hot_course: 活跃课程