1.转发帖子时,当组织没有资源栏目时,给出提示;

2.组织文章的附件显示在组织动态/组织文章列表中;
This commit is contained in:
ouyangxuhua 2015-12-29 17:13:48 +08:00
parent dd88742b78
commit 15cff47c92
3 changed files with 12 additions and 5 deletions

View File

@ -14,7 +14,7 @@ class OrganizationsController < ApplicationController
include PollHelper
helper :user_score
helper :journals
helper :attachments
# added by liuping 关注
helper :watchers

View File

@ -2,10 +2,14 @@
<!--<span class="fontBlue pl10">请在左侧选择要转发的位置</span>-->
<% if !org.nil? %>
<span class="fontBlue pl10">组织:<%= org.name %></span>
<% org.org_subfields.where("field_type='Post'").each do |subfield| %>
<li>
<label><input type="checkbox" name='org_subfields[]' value='<%= subfield.id %>' class="mt3 fl mr5"/><span><%= subfield.name %></span></label>
</li>
<% if org.org_subfields.where("field_type='Post'").count > 0 %>
<% org.org_subfields.where("field_type='Post'").each do |subfield| %>
<li>
<label><input type="checkbox" name='org_subfields[]' value='<%= subfield.id %>' class="mt3 fl mr5"/><span><%= subfield.name %></span></label>
</li>
<% end %>
<% else %>
<li><span class="mt3 fl mr5">暂无资源栏目</span></li>
<% end %>
<% else %>
<span class="fontBlue pl10">请在左侧选择组织</span>

View File

@ -18,6 +18,9 @@
<%= document.content.html_safe %>
</div>
<% end %>
<div class=" fl" style="width: 600px">
<%= link_to_attachments_course document, :author => false %>
</div>
<!-- <%# if defined?(home_id) %>
<div style="float:right;">最后编辑:<%#= User.find() %></div>
<%# end %>-->