完成左一的配置
This commit is contained in:
parent
2acc545896
commit
b1cb4e5f94
|
@ -1,27 +1,169 @@
|
|||
<div class="por_hotbar clear">
|
||||
<h2 class="por_h2_index clear">网站头条<a href="javascript:void(0);" target="_blank" class="por_more_index fr">更多></a></h2>
|
||||
<ul class="por_hotbar_left fl">
|
||||
<li>
|
||||
<a href="javascript:void(0);" target="_blank" class="por_hot_title "><span class="por_icons_hot fl">热门推荐</span>阿里前副总裁:阿里巴巴给我上的10</a>
|
||||
<p class="mt5 mb5"><span class="por_time mr10">1分钟前 </span><a href="javascript:void(0);" target="_blank" class=" por_hot_name"> 窦豆</a></p>
|
||||
<p class="por_hot_txt ">本文选自阿本文选自阿里本文选自阿里本文选自阿里本文选自阿里本文选自阿里里巴巴前副总裁、首任美籍高管波特·埃里斯曼《阿里传》在这本书里,波特概括了他在阿里巴巴任职的8年中,学到的40堂课这40堂课简单明了地概括了马云的经营理念,以及阿里终成帝国的必</p>
|
||||
</li>
|
||||
<li>
|
||||
<a href="javascript:void(0);" target="_blank" class="por_hot_title "><span class="por_icons_hot fl">热门推荐</span>阿里前副总裁:阿里巴巴给我上的10</a>
|
||||
<p class="mt5 mb5"><span class="por_time mr10">1分钟前 </span><a href="javascript:void(0);" target="_blank" class=" por_hot_name"> 窦豆</a></p>
|
||||
<p class="por_hot_txt">本文选自阿本文选自阿里本文选自阿里本文选自阿里本文选自阿里本文选自阿里里巴巴前副总裁、首任美籍高管波特·埃里斯曼《阿里传》在这本书里,波特概括了他在阿里巴巴任职的8年中,学到的40堂课这40堂课简单明了地概括了马云的经营理念,以及阿里终成帝国的必</p>
|
||||
</li>
|
||||
<li>
|
||||
<a href="javascript:void(0);" target="_blank" class="por_hot_title ">阿里前副总裁里前副总裁:里前副总裁:里前副总裁::阿里巴巴给我上的10</a>
|
||||
<p class="mt5 mb5"><span class="por_time mr10">1分钟前 </span><a href="javascript:void(0);" target="_blank" class=" por_hot_name"> 窦豆</a></p>
|
||||
<p class="por_hot_txt">本文选自阿本文选自阿里本文选自阿里本文选自阿里本文选自阿里本文选自阿里里巴巴前副总裁、首任美籍高管波特·埃里斯曼《阿里传》在这本书里,波特概括了他在阿里巴巴任职的8年中,学到的40堂课这40堂课简单明了地概括了马云的经营理念,以及阿里终成帝国的必</p>
|
||||
</li>
|
||||
</ul>
|
||||
<div class="por_hotbar_right fl">
|
||||
<a href="javascript:void(0);" target="_blank" class=""><img src="/images/org_custom/por_img.jpg" width="299" height="246" alt=""/></a>
|
||||
<a href="javascript:void(0);" target="_blank" class="por_hot_title_r ">阿里前副总裁里前副总裁:里前副总裁:里前副总裁::阿里巴巴给我上的10</a>
|
||||
<p class="mt5 mb5"><span class="por_time mr10">1分钟前 </span><a href="javascript:void(0);" target="_blank" class=" por_hot_name"> 窦豆</a></p>
|
||||
<p class="por_hot_txt_r ">本文选自阿本文选自阿里本文选自阿里本文选自阿里本文选自阿里本文选自阿里里巴巴前副总裁、首任美籍高管波特·埃里斯曼《阿里传》在这本书里,波特概括了他在阿里巴巴任职的8年中,学到的40堂课这40堂课简单明了地概括了马云的经营理念,以及阿里终成帝国的必</p>
|
||||
</div>
|
||||
<div class="por_hotbar clear" style="display:<%= field.hide == 0 ? 'block':'none' %>;">
|
||||
<% if acts.blank? %>
|
||||
<h2 class="por_h2_index clear"><%= field.name %></h2>
|
||||
<p class="fontGrey2 f14 mt10 mb5">该模块暂时没有相关内容</p>
|
||||
<% else %>
|
||||
<h2 class="por_h2_index clear"><%= field.name %>
|
||||
<%= render :partial => 'organizations/link_subfield_more', :locals => {:field => field} %>
|
||||
</h2>
|
||||
<ul class="por_hotbar_left fl">
|
||||
<% if acts.count > 0 %>
|
||||
<% acts.first(2).each do |activity| %>
|
||||
<% if activity.container_type == 'Organization' && activity.org_act_type == 'OrgDocumentComment' && activity.org_act_id != @organization.home_id %>
|
||||
<% document = activity.org_act %>
|
||||
<li>
|
||||
<%= link_to "<span class='por_icons_hot fl'>热门推荐</span>#{document.title}".html_safe, org_document_comment_path(:id => document.id, :organization_id => document.organization.id), class: 'por_hot_title', :target => "_blank", :title => document.title %>
|
||||
<p class="mt5 mb5"><span class="por_time mr10"><%= time_from_now(document.created_at) %></span>
|
||||
<%= link_to document.creator.show_name, user_path(document.creator), :class => "por_hot_name", :target => "_blank" %>
|
||||
</p>
|
||||
<%=render :partial =>"organizations/organization_content_extension", :locals => {:user_activity_id => document.id, :content=> document.content, :maxheight => 60, :maxwordsnum => 80, :maxwidth => 0, :cl => "por_hot_txt"} %>
|
||||
</li>
|
||||
<% 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 %>
|
||||
<% message = activity.org_act %>
|
||||
<% content = message.parent_id.nil? ? message.content : message.parent.content %>
|
||||
<% title = message.parent_id.nil? ? message.subject : message.parent.subject %>
|
||||
<% if message.board.org_subfield_id %>
|
||||
<li>
|
||||
<%= link_to "<span class='por_icons_hot fl'>热门推荐</span>#{title}".html_safe, board_message_url_in_org(message.board.id,message.id), class: 'por_hot_title', :target => "_blank", :title => title %>
|
||||
<p class="mt5 mb5"><span class="por_time mr10"><%= time_from_now(message.created_on) %></span>
|
||||
<%= link_to message.author.show_name, user_path(message.author), :class => "por_hot_name", :target => "_blank" %>
|
||||
</p>
|
||||
<%=render :partial =>"organizations/organization_content_extension", :locals => {:user_activity_id => message.id, :content=> content, :maxheight => 60, :maxwordsnum => 80, :maxwidth => 0, :cl => "por_hot_txt"} %>
|
||||
</li>
|
||||
<% else %>
|
||||
<li>
|
||||
<%= link_to "<span class='por_icons_hot fl'>热门推荐</span>#{title}".html_safe, board_message_path(message.board.id,message.id), class: 'por_hot_title', :target => "_blank", :title => title %>
|
||||
<p class="mt5 mb5"><span class="por_time mr10"><%= time_from_now(message.created_on) %></span>
|
||||
<%= link_to message.author.show_name, user_path(message.author), :class => "por_hot_name", :target => "_blank" %>
|
||||
</p>
|
||||
<%=render :partial =>"organizations/organization_content_extension", :locals => {:user_activity_id => message.id, :content=> content, :maxheight => 60, :maxwordsnum => 80, :maxwidth => 0, :cl => "por_hot_txt"} %>
|
||||
</li>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<% if activity.org_act_type == 'News' and News.where("id=?", activity.org_act_id).count > 0 %>
|
||||
<% news = activity.org_act %>
|
||||
<li>
|
||||
<%= link_to "<span class='por_icons_hot fl'>热门推荐</span>#{news.title}".html_safe, news_path(news), class: 'por_hot_title', :target => "_blank", :title => news.title %>
|
||||
<p class="mt5 mb5"><span class="por_time mr10"><%= time_from_now(news.created_on) %></span>
|
||||
<%= link_to news.author.show_name, user_path(news.author), :class => "por_hot_name", :target => "_blank" %>
|
||||
</p>
|
||||
<%=render :partial =>"organizations/organization_content_extension", :locals => {:user_activity_id => news.id, :content=> news.description, :maxheight => 60, :maxwordsnum => 80, :maxwidth => 0, :cl => "por_hot_txt"} %>
|
||||
</li>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
|
||||
<% if acts.count > 2 %>
|
||||
<% activity = acts[2] %>
|
||||
<% if activity.container_type == 'Organization' && activity.org_act_type == 'OrgDocumentComment' && activity.org_act_id != @organization.home_id %>
|
||||
<% document = activity.org_act %>
|
||||
<li>
|
||||
<%= link_to document.title, org_document_comment_path(:id => document.id, :organization_id => document.organization.id), class: 'por_hot_title', :target => "_blank", :title => document.title %>
|
||||
<p class="mt5 mb5"><span class="por_time mr10"><%= time_from_now(document.created_at) %></span>
|
||||
<%= link_to document.creator.show_name, user_path(document.creator), :class => "por_hot_name", :target => "_blank" %>
|
||||
</p>
|
||||
<%=render :partial =>"organizations/organization_content_extension", :locals => {:user_activity_id => document.id, :content=> document.content, :maxheight => 60, :maxwordsnum => 80, :maxwidth => 0, :cl => "por_hot_txt"} %>
|
||||
</li>
|
||||
<% 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 %>
|
||||
<% message = activity.org_act %>
|
||||
<% content = message.parent_id.nil? ? message.content : message.parent.content %>
|
||||
<% title = message.parent_id.nil? ? message.subject : message.parent.subject %>
|
||||
<% if message.board.org_subfield_id %>
|
||||
<li>
|
||||
<%= link_to title, board_message_url_in_org(message.board.id,message.id), class: 'por_hot_title', :target => "_blank", :title => title %>
|
||||
<p class="mt5 mb5"><span class="por_time mr10"><%= time_from_now(message.created_on) %></span>
|
||||
<%= link_to message.author.show_name, user_path(message.author), :class => "por_hot_name", :target => "_blank" %>
|
||||
</p>
|
||||
<%=render :partial =>"organizations/organization_content_extension", :locals => {:user_activity_id => message.id, :content=> content, :maxheight => 60, :maxwordsnum => 80, :maxwidth => 0, :cl => "por_hot_txt"} %>
|
||||
</li>
|
||||
<% else %>
|
||||
<li>
|
||||
<%= link_to title, board_message_path(message.board.id,message.id), class: 'por_hot_title', :target => "_blank", :title => title %>
|
||||
<p class="mt5 mb5"><span class="por_time mr10"><%= time_from_now(message.created_on) %></span>
|
||||
<%= link_to message.author.show_name, user_path(message.author), :class => "por_hot_name", :target => "_blank" %>
|
||||
</p>
|
||||
<%=render :partial =>"organizations/organization_content_extension", :locals => {:user_activity_id => message.id, :content=> content, :maxheight => 60, :maxwordsnum => 80, :maxwidth => 0, :cl => "por_hot_txt"} %>
|
||||
</li>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<% if activity.org_act_type == 'News' and News.where("id=?", activity.org_act_id).count > 0 %>
|
||||
<% news = activity.org_act %>
|
||||
<li>
|
||||
<%= link_to news.title, news_path(news), class: 'por_hot_title', :target => "_blank", :title => news.title %>
|
||||
<p class="mt5 mb5"><span class="por_time mr10"><%= time_from_now(news.created_on) %></span>
|
||||
<%= link_to news.author.show_name, user_path(news.author), :class => "por_hot_name", :target => "_blank" %>
|
||||
</p>
|
||||
<%=render :partial =>"organizations/organization_content_extension", :locals => {:user_activity_id => news.id, :content=> news.description, :maxheight => 60, :maxwordsnum => 80, :maxwidth => 0, :cl => "por_hot_txt"} %>
|
||||
</li>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
|
||||
</ul>
|
||||
|
||||
<% if acts.count > 3 %>
|
||||
<% activity = acts[3] %>
|
||||
<% if activity.container_type == 'Organization' && activity.org_act_type == 'OrgDocumentComment' && activity.org_act_id != @organization.home_id %>
|
||||
<% document = activity.org_act %>
|
||||
<div class="por_hotbar_right fl">
|
||||
<% if get_image_path_from_content(document.content).nil? %>
|
||||
<%= link_to image_tag("/images/default_blank/left-04.jpg", :width => "299", :height => "246"), org_document_comment_path(:id => document.id, :organization_id => document.organization.id), :target => "_blank" %>
|
||||
<% else %>
|
||||
<%= link_to image_tag("/files/uploads/image#{get_image_path_from_content(document.content)}", :width => "299", :height => "246"), org_document_comment_path(:id => document.id, :organization_id => document.organization.id), :target => "_blank" %>
|
||||
<% end %>
|
||||
<%= link_to document.title, org_document_comment_path(:id => document.id, :organization_id => document.organization.id), :class => 'por_hot_title_r', :target => "_blank", :title => document.title %>
|
||||
<p class="mt5 mb5"><span class="por_time mr10"><%= time_from_now(document.created_at) %></span><%= link_to document.creator.show_name, user_path(document.creator), :class => "por_hot_name", :target => "_blank" %></p>
|
||||
<%=render :partial =>"organizations/organization_content_extension", :locals => {:user_activity_id => document.id, :content=> document.content, :maxheight => 80, :maxwordsnum => 90, :maxwidth => 0, :cl => "por_hot_txt_r"} %>
|
||||
</div>
|
||||
<% 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 %>
|
||||
<% message = activity.org_act %>
|
||||
<% content = message.parent_id.nil? ? message.content : message.parent.content %>
|
||||
<% title = message.parent_id.nil? ? message.subject : message.parent.subject %>
|
||||
<% if message.board.org_subfield_id %>
|
||||
<div class="por_hotbar_right fl">
|
||||
<% if get_image_path_from_content(document.content).nil? %>
|
||||
<%= link_to image_tag("/images/default_blank/left-04.jpg", :width => "299", :height => "246"), board_message_url_in_org(:id => message.id, :organization_id => message.organization.id), :target => "_blank" %>
|
||||
<% else %>
|
||||
<%= link_to image_tag("/files/uploads/image#{get_image_path_from_content(content)}", :width => "299", :height => "246"), board_message_url_in_org(:id => message.id, :organization_id => message.organization.id), :target => "_blank" %>
|
||||
<% end %>
|
||||
<%= link_to title, board_message_url_in_org(:id => message.id, :organization_id => message.organization.id), :class => 'por_hot_title_r', :target => "_blank", :title => title %>
|
||||
<p class="mt5 mb5"><span class="por_time mr10"><%= time_from_now(message.created_on) %></span><%= link_to message.author.show_name, user_path(message.author), :class => "por_hot_name", :target => "_blank" %></p>
|
||||
<%=render :partial =>"organizations/organization_content_extension", :locals => {:user_activity_id => message.id, :content=> content, :maxheight => 80, :maxwordsnum => 90, :maxwidth => 0, :cl => "por_hot_txt_r"} %>
|
||||
</div>
|
||||
<% else %>
|
||||
<div class="por_hotbar_right fl">
|
||||
<% if get_image_path_from_content(document.content).nil? %>
|
||||
<%= link_to image_tag("/images/default_blank/left-04.jpg", :width => "299", :height => "246"), board_message_path(:id => message.id, :organization_id => message.organization.id), :target => "_blank" %>
|
||||
<% else %>
|
||||
<%= link_to image_tag("/files/uploads/image#{get_image_path_from_content(content)}", :width => "299", :height => "246"), board_message_path(:id => message.id, :organization_id => message.organization.id), :target => "_blank" %>
|
||||
<% end %>
|
||||
<%= link_to title, board_message_path(:id => message.id, :organization_id => message.organization.id), :class => 'por_hot_title_r', :target => "_blank", :title => title %>
|
||||
<p class="mt5 mb5"><span class="por_time mr10"><%= time_from_now(message.created_on) %></span><%= link_to message.author.show_name, user_path(message.author), :class => "por_hot_name", :target => "_blank" %></p>
|
||||
<%=render :partial =>"organizations/organization_content_extension", :locals => {:user_activity_id => message.id, :content=> content, :maxheight => 80, :maxwordsnum => 90, :maxwidth => 0, :cl => "por_hot_txt_r"} %>
|
||||
</div>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<% if activity.org_act_type == 'News' and News.where("id=?", activity.org_act_id).count > 0 %>
|
||||
<% news = activity.org_act %>
|
||||
<% path = get_image_path_from_content(news.description) %>
|
||||
<div class="por_hotbar_right fl">
|
||||
<% if path.nil? %>
|
||||
<%= link_to image_tag("/images/default_blank/left-04.jpg", :width => "299", :height => "246"), news_path(news), :target => "_blank" %>
|
||||
<% else %>
|
||||
<%= link_to image_tag("/files/uploads/image#{path}", :width => "299", :height => "246"), news_path(news), :target => "_blank" %>
|
||||
<% end %>
|
||||
<%= link_to news.title, news_path(news), :class => 'por_hot_title_r', :target => "_blank", :title => news.title %>
|
||||
<p class="mt5 mb5"><span class="por_time mr10"><%= time_from_now(news.created_on) %></span><%= link_to news.author.show_name, user_path(news.author), :class => "por_hot_name", :target => "_blank" %></p>
|
||||
<%=render :partial =>"organizations/organization_content_extension", :locals => {:user_activity_id => news.id, :content=> news.description, :maxheight => 80, :maxwordsnum => 90, :maxwidth => 0, :cl => "por_hot_txt_r"} %>
|
||||
</div>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
|
||||
<% end %>
|
||||
<div class="cl"></div>
|
||||
</div><!--por_hotbar end-->
|
|
@ -9,67 +9,67 @@
|
|||
<div class="por_post_left fl">
|
||||
<div class="por_post_leftbar ">
|
||||
<% activity = acts.first %>
|
||||
<% if activity.container_type == 'Organization' && activity.org_act_type == 'OrgDocumentComment' && activity.org_act_id != @organization.home_id %>
|
||||
<% document = activity.org_act %>
|
||||
<% if get_image_path_from_content(acts.first.org_act.content).nil? %>
|
||||
<%= link_to image_tag("/images/default_blank/left-04.jpg", :width => "299", :height => "246"), org_document_comment_path(:id => acts.first.org_act.id, :organization_id => acts.first.org_act.organization.id), :target => "_blank" %>
|
||||
<% else %>
|
||||
<%= link_to image_tag("/files/uploads/image#{get_image_path_from_content(acts.first.org_act.content)}", :width => "299", :height => "246"), org_document_comment_path(:id => acts.first.org_act.id, :organization_id => acts.first.org_act.organization.id), :target => "_blank" %>
|
||||
<% end %>
|
||||
<%= link_to activity.org_act.title, org_document_comment_path(:id => acts.first.org_act.id, :organization_id => acts.first.org_act.organization.id), :target => '_blank', :class => "por_post_title", :title => activity.org_act.title %>
|
||||
<p class="mt5 mb5">
|
||||
<span class="por_time mr10"><%= time_from_now(acts.first.org_act.created_at) %> </span>
|
||||
<%= link_to acts.first.org_act.creator, user_path(acts.first.org_act.creator), :class => "por_hot_name", :target => "_blank" %>
|
||||
</p>
|
||||
<%=render :partial =>"organizations/organization_content_extension", :locals => {:user_activity_id => acts.first.org_act.id, :content=> acts.first.org_act.content, :maxheight => 40, :maxwordsnum => 60, :maxwidth => 0, :cl => "por_post_txt"} %>
|
||||
<% 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 %>
|
||||
<% message = activity.org_act %>
|
||||
<% content = message.parent_id.nil? ? message.content : message.parent.content %>
|
||||
<% title = message.parent_id.nil? ? message.subject : message.parent.subject %>
|
||||
<% iamge_path = get_image_path_from_content(content) %>
|
||||
<% if message.board.org_subfield_id %>
|
||||
<% if iamge_path.nil? %>
|
||||
<%= link_to image_tag("/images/default_blank/left-04.jpg", :width => "299", :height => "246"), board_message_url_in_org(message.board.id,message.id), :target => "_blank" %>
|
||||
<% else %>
|
||||
<%= link_to image_tag("/files/uploads/image#{iamge_path}", :width => "299", :height => "246"), board_message_url_in_org(message.board.id,message.id), :target => "_blank" %>
|
||||
<% end %>
|
||||
<%= link_to title, board_message_url_in_org(message.board.id,message.id), :target => '_blank', :class => "por_post_title", :title => title %>
|
||||
<p class="mt5 mb5">
|
||||
<span class="por_time mr10"><%= time_from_now(message.created_on) %> </span>
|
||||
<%= link_to message.author, user_path(message.author), :class => "por_hot_name", :target => "_blank" %>
|
||||
</p>
|
||||
<%=render :partial =>"organizations/organization_content_extension", :locals => {:user_activity_id => message.id, :content=> message.content, :maxheight => 40, :maxwordsnum => 60, :maxwidth => 0, :cl => "por_post_txt"} %>
|
||||
<% else %>
|
||||
<% if iamge_path.nil? %>
|
||||
<%= link_to image_tag("/images/default_blank/left-04.jpg", :width => "299", :height => "246"), board_message_path(message.board, message), :target => "_blank" %>
|
||||
<% else %>
|
||||
<%= link_to image_tag("/files/uploads/image#{iamge_path}", :width => "299", :height => "246"), board_message_path(message.board, message), :target => "_blank" %>
|
||||
<% end %>
|
||||
<%= link_to title, board_message_path(message.board, message), :target => '_blank', :class => "por_post_title", :title => title %>
|
||||
<p class="mt5 mb5">
|
||||
<span class="por_time mr10"><%= time_from_now(message.created_on) %> </span>
|
||||
<%= link_to message.author, user_path(message.author), :class => "por_hot_name", :target => "_blank" %>
|
||||
</p>
|
||||
<%=render :partial =>"organizations/organization_content_extension", :locals => {:user_activity_id => message.id, :content=> message.content, :maxheight => 40, :maxwordsnum => 60, :maxwidth => 0, :cl => "por_post_txt"} %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<% if activity.org_act_type == 'News' and News.where("id=?", activity.org_act_id).count > 0 %>
|
||||
<% news = News.find(activity.org_act_id) %>
|
||||
<% iamge_path = get_image_path_from_content(news.description) %>
|
||||
<% if activity.container_type == 'Organization' && activity.org_act_type == 'OrgDocumentComment' && activity.org_act_id != @organization.home_id %>
|
||||
<% document = activity.org_act %>
|
||||
<% if get_image_path_from_content(document.content).nil? %>
|
||||
<%= link_to image_tag("/images/default_blank/left-04.jpg", :width => "299", :height => "246"), org_document_comment_path(:id => document.id, :organization_id => document.organization.id), :target => "_blank" %>
|
||||
<% else %>
|
||||
<%= link_to image_tag("/files/uploads/image#{get_image_path_from_content(document.content)}", :width => "299", :height => "246"), org_document_comment_path(:id => document.id, :organization_id => document.organization.id), :target => "_blank" %>
|
||||
<% end %>
|
||||
<%= link_to document.title, org_document_comment_path(:id => document.id, :organization_id => document.organization.id), :target => '_blank', :class => "por_post_title", :title => document.title %>
|
||||
<p class="mt5 mb5">
|
||||
<span class="por_time mr10"><%= time_from_now(document.created_at) %> </span>
|
||||
<%= link_to document.creator.show_name, user_path(document.creator), :class => "por_hot_name", :target => "_blank" %>
|
||||
</p>
|
||||
<%=render :partial =>"organizations/organization_content_extension", :locals => {:user_activity_id => acts.first.org_act.id, :content=> acts.first.org_act.content, :maxheight => 40, :maxwordsnum => 60, :maxwidth => 0, :cl => "por_post_txt"} %>
|
||||
<% 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 %>
|
||||
<% message = activity.org_act %>
|
||||
<% content = message.parent_id.nil? ? message.content : message.parent.content %>
|
||||
<% title = message.parent_id.nil? ? message.subject : message.parent.subject %>
|
||||
<% iamge_path = get_image_path_from_content(content) %>
|
||||
<% if message.board.org_subfield_id %>
|
||||
<% if iamge_path.nil? %>
|
||||
<%= link_to image_tag("/images/default_blank/left-04.jpg", :width => "299", :height => "246"), news_path(news), :target => "_blank" %>
|
||||
<%= link_to image_tag("/images/default_blank/left-04.jpg", :width => "299", :height => "246"), board_message_url_in_org(message.board.id,message.id), :target => "_blank" %>
|
||||
<% else %>
|
||||
<%= link_to image_tag("/files/uploads/image#{iamge_path}", :width => "299", :height => "246"), news_path(news), :target => "_blank" %>
|
||||
<%= link_to image_tag("/files/uploads/image#{iamge_path}", :width => "299", :height => "246"), board_message_url_in_org(message.board.id,message.id), :target => "_blank" %>
|
||||
<% end %>
|
||||
<%= link_to news.title, news_path(news), :target => '_blank', :class => "por_post_title", :title => news.title %>
|
||||
<%= link_to title, board_message_url_in_org(message.board.id,message.id), :target => '_blank', :class => "por_post_title", :title => title %>
|
||||
<p class="mt5 mb5">
|
||||
<span class="por_time mr10"><%= time_from_now(news.created_on) %> </span>
|
||||
<%= link_to news.author, user_path(news.author), :class => "por_hot_name", :target => "_blank" %>
|
||||
<span class="por_time mr10"><%= time_from_now(message.created_on) %> </span>
|
||||
<%= link_to message.author.show_name, user_path(message.author), :class => "por_hot_name", :target => "_blank" %>
|
||||
</p>
|
||||
<%=render :partial =>"organizations/organization_content_extension", :locals => {:user_activity_id => news.id, :content=> news.description, :maxheight => 40, :maxwordsnum => 60, :maxwidth => 0, :cl => "por_post_txt"} %>
|
||||
<%=render :partial =>"organizations/organization_content_extension", :locals => {:user_activity_id => message.id, :content=> message.content, :maxheight => 40, :maxwordsnum => 60, :maxwidth => 0, :cl => "por_post_txt"} %>
|
||||
<% else %>
|
||||
<% if iamge_path.nil? %>
|
||||
<%= link_to image_tag("/images/default_blank/left-04.jpg", :width => "299", :height => "246"), board_message_path(message.board, message), :target => "_blank" %>
|
||||
<% else %>
|
||||
<%= link_to image_tag("/files/uploads/image#{iamge_path}", :width => "299", :height => "246"), board_message_path(message.board, message), :target => "_blank" %>
|
||||
<% end %>
|
||||
<%= link_to title, board_message_path(message.board, message), :target => '_blank', :class => "por_post_title", :title => title %>
|
||||
<p class="mt5 mb5">
|
||||
<span class="por_time mr10"><%= time_from_now(message.created_on) %> </span>
|
||||
<%= link_to message.author.show_name, user_path(message.author), :class => "por_hot_name", :target => "_blank" %>
|
||||
</p>
|
||||
<%=render :partial =>"organizations/organization_content_extension", :locals => {:user_activity_id => message.id, :content=> message.content, :maxheight => 40, :maxwordsnum => 60, :maxwidth => 0, :cl => "por_post_txt"} %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<% if activity.org_act_type == 'News' and News.where("id=?", activity.org_act_id).count > 0 %>
|
||||
<% news = News.find(activity.org_act_id) %>
|
||||
<% iamge_path = get_image_path_from_content(news.description) %>
|
||||
<% if iamge_path.nil? %>
|
||||
<%= link_to image_tag("/images/default_blank/left-04.jpg", :width => "299", :height => "246"), news_path(news), :target => "_blank" %>
|
||||
<% else %>
|
||||
<%= link_to image_tag("/files/uploads/image#{iamge_path}", :width => "299", :height => "246"), news_path(news), :target => "_blank" %>
|
||||
<% end %>
|
||||
<%= link_to news.title, news_path(news), :target => '_blank', :class => "por_post_title", :title => news.title %>
|
||||
<p class="mt5 mb5">
|
||||
<span class="por_time mr10"><%= time_from_now(news.created_on) %> </span>
|
||||
<%= link_to news.author.show_name, user_path(news.author), :class => "por_hot_name", :target => "_blank" %>
|
||||
</p>
|
||||
<%=render :partial =>"organizations/organization_content_extension", :locals => {:user_activity_id => news.id, :content=> news.description, :maxheight => 40, :maxwordsnum => 60, :maxwidth => 0, :cl => "por_post_txt"} %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
|
||||
<% unless acts[1..5].nil? %>
|
||||
<% acts[1..5].each do |activity| %>
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<div class="por_left">
|
||||
<% @subfield_content.each do |field| %>
|
||||
<% if field.status.to_i == 1 %>
|
||||
<%= render :partial => 'organizations/org_custom_left1', :locals => {:field => field} %>
|
||||
<%= render :partial => 'organizations/org_custom_left1', :locals => {:field => field, :acts => get_subfield_acts(field) } %>
|
||||
<% elsif field.status.to_i == 2 %>
|
||||
<%= render :partial => 'organizations/org_custom_left2', :locals => {:field => field} %>
|
||||
<% elsif field.status.to_i == 3 %>
|
||||
|
|
Loading…
Reference in New Issue