diff --git a/app/views/organizations/_org_subfield_leftMD.html.erb b/app/views/organizations/_org_subfield_leftMD.html.erb index 1b1349c30..3858fcdf0 100644 --- a/app/views/organizations/_org_subfield_leftMD.html.erb +++ b/app/views/organizations/_org_subfield_leftMD.html.erb @@ -30,7 +30,7 @@
<%= link_to activity.description.to_s.html_safe, student_work_index_url_in_org(activity.id), :target => '_blank', :class => "resources-tag" %>
- 更多 + <%= link_to "更多", student_work_index_url_in_org(activity.id), :class => "more-btn", :target => "_blank" %> <% elsif act.org_act_type == "Message" %> <% activity = Message.find(act.org_act_id) %> @@ -51,7 +51,11 @@
<%= link_to activity.content.to_s.html_safe, board_message_url_in_org(activity.board_id, activity.id), :target => '_blank', :class => "resources-tag" %>
- 更多 + <% if activity.parent_id.nil? %> + <%= link_to "更多", board_message_url_in_org(activity.board_id, activity.id), :class => "more-btn", :target => "_blank" %> + <% else %> + <%= link_to "更多", board_message_url_in_org(activity.board_id, activity.id), :class => "more-btn", :target => "_blank" %> + <% end %> <% elsif act.org_act_type == "News" %> <% activity = News.find(act.org_act_id) %> @@ -68,7 +72,7 @@
<%= link_to activity.description.to_s.html_safe, news_url_in_org(activity.id), :target => '_blank', :class => "resources-tag" %>
- 更多 + <%= link_to "更多", news_url_in_org(activity.id), :class => "more-btn", :target => "_blank" %> <% elsif act.org_act_type == "Poll" %> <% activity = Poll.find(act.org_act_id) %> @@ -92,7 +96,11 @@
<%= link_to activity.polls_description.to_s.html_safe, Setting.protocol + "://" + Setting.host_name + "/poll/" + activity.id.to_s + "/poll_result", :target => '_blank', :class => "resources-tag" %>
- 更多 + <% if has_commit %> + <%= link_to "更多", Setting.protocol + "://" + Setting.host_name + "/poll/" + activity.id.to_s + "/poll_result", :class => "more-btn", :target => "_blank" %> + <% else %> + <%= link_to "更多", Setting.protocol + "://" + Setting.host_name + "/poll/" + activity.id.to_s + "/poll_result", :class => "more-btn", :target => "_blank" %> + <% end %> <% end %> <% end %> @@ -130,7 +138,7 @@
<%= link_to activity.description.to_s.html_safe, issue_url_in_org(activity.id), :target => '_blank', :class => "resources-tag" %>
- 更多 + <%= link_to "更多", issue_url_in_org(activity.id), :class => "more-btn", :target => "_blank" %> <% elsif act.org_act_type == "Message" %> <% activity = Message.find(act.org_act_id) %> @@ -151,7 +159,11 @@
<%= link_to activity.content.to_s.html_safe, board_message_url_in_org(activity.board_id, activity.id), :target => '_blank', :class => "resources-tag" %>
- 更多 + <% if activity.parent_id.nil? %> + <%= link_to "更多", board_message_url_in_org(activity.board_id, activity.id), :class => "more-btn", :target => "_blank" %> + <% else %> + <%= link_to "更多", board_message_url_in_org(activity.board_id, activity.id), :class => "more-btn", :target => "_blank" %> + <% end %> <% elsif act.org_act_type == "News" %> <% activity = News.find(act.org_act_id) %> @@ -168,7 +180,7 @@
<%= link_to activity.content.to_s.html_safe, news_url_in_org(activity.id), :target => '_blank', :class => "resources-tag" %>
- 更多 + <%= link_to "更多", news_url_in_org(activity.id), :class => "more-btn", :target => "_blank" %> <% end %> <% end %> @@ -213,7 +225,8 @@
<%= link_to document.content.to_s.html_safe, org_document_comment_path(:id => document.id, :organization_id => document.organization.id), :target => '_blank', :class => "resources-tag" %>
- 更多 + <%= link_to "更多", org_document_comment_path(:id => document.id, :organization_id => document.organization.id), :class => "more-btn", :target => "_blank" %> + <% else activity.container_type == 'OrgSubfield' %> <% if activity.org_act_type == 'Message' and activity.org_act_id and Message.where("id=#{activity.org_act_id}").count > 0 %> @@ -241,7 +254,7 @@
<%= link_to content.to_s.html_safe, board_message_url_in_org(activity.board_id, activity.id), :target => '_blank', :class => "resources-tag" %>
- 更多 + <%= link_to "更多", board_message_url_in_org(message.board.id,message.id), :class => "more-btn", :target => "_blank" %> <% else %>
@@ -260,7 +273,7 @@
<%= link_to content.to_s.html_safe, board_message_path(message.board,activity), :target => '_blank', :class => "resources-tag" %>
- 更多 + <%= link_to "更多", board_message_path(message.board,activity), :class => "more-btn", :target => "_blank" %>
<% end %> <% end %> @@ -279,7 +292,7 @@
<%= link_to news.description.to_s.html_safe, news_path(news), :target => '_blank', :class => "resources-tag" %>
- 更多 + <%= link_to "更多", news_path(news), :class => "more-btn", :target => "_blank" %> <% end %> <% end %> @@ -287,7 +300,6 @@
- <% end %> <% end %> <% end %> diff --git a/db/migrate/20160506085852_update_org_hide.rb b/db/migrate/20160506085852_update_org_hide.rb new file mode 100644 index 000000000..31dc22be5 --- /dev/null +++ b/db/migrate/20160506085852_update_org_hide.rb @@ -0,0 +1,10 @@ +class UpdateOrgHide < ActiveRecord::Migration + def up + Organization.all.each do |org| + org.update_column(:show_mode, false) + end + end + + def down + end +end