|
|
|
@ -43,16 +43,16 @@
|
|
|
|
|
<%#= link_to '首页', organization_path(@organization, :show_homepage => 1),:class=>"linkGrey8 f14" %>
|
|
|
|
|
</li>
|
|
|
|
|
<% if User.current.logged? %>
|
|
|
|
|
<li class="navOrgMenu fr" id="orgSwitch" style="cursor:pointer;">
|
|
|
|
|
<li class="navOrgMenu fr" id="orgSwitch" style="cursor:pointer;">
|
|
|
|
|
<span class="orgMenuArrow" id="orgArrow">
|
|
|
|
|
<ul class="org_login_list" style="display:none;">
|
|
|
|
|
<li> <%= link_to "个人主页",user_path(User.current), :class => "linkGrey8", :target => "_blank" %></li>
|
|
|
|
|
<li><%= link_to "退出",logout_organization_path(@organization), :class =>"linkGrey8", :method => 'post', :rel => "nofollow" %></li>
|
|
|
|
|
<li> <%= link_to "个人主页",user_path(User.current), :class => "menuGrey", :target => "_blank" %></li>
|
|
|
|
|
<li><%= link_to "退出",logout_organization_path(@organization), :class =>"menuGrey", :method => 'post', :rel => "nofollow" %></li>
|
|
|
|
|
<!--<li><%#= link_to "退出",signout_path, :class =>"linkGrey8", :method => 'post', :rel => "nofollow" %></li>-->
|
|
|
|
|
</ul>
|
|
|
|
|
</ul>
|
|
|
|
|
</span>
|
|
|
|
|
</li>
|
|
|
|
|
<li class="navOrgMenu fr" id="orgUser" style="cursor:pointer;"><a href="javascript:void(0);" class="linkGrey8 f14" id="orgUserName"><%= User.current %></a></li>
|
|
|
|
|
</li>
|
|
|
|
|
<li class="navOrgMenu fr" id="orgUser" style="cursor:pointer;"><a href="javascript:void(0);" class="fontGrey2 f14" id="orgUserName"><%= User.current %></a></li>
|
|
|
|
|
<!--<li class="navOrgMenu fr"><%#=link_to User.current, user_path(User.current), :class => "linkGrey8 f14" %></li>-->
|
|
|
|
|
<% else %>
|
|
|
|
|
<li class="navOrgMenu fr"><a href="<%= signin_path(:login=>true) %>" class="linkGrey8 f14">登录</a></li>
|
|
|
|
@ -75,141 +75,136 @@
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="cl"></div>
|
|
|
|
|
<div class="homepageContentContainer">
|
|
|
|
|
<div class="homepageContent">
|
|
|
|
|
<div class="homepageLeft">
|
|
|
|
|
<div class="homepagePortraitContainer">
|
|
|
|
|
<!--<div class="pr_info_logo fl mr10 mb5">-->
|
|
|
|
|
<!--<%#= image_tag(url_to_avatar(@organization), :width=>"60", :height=>"60", :alt=>"组织logo") %>-->
|
|
|
|
|
<!--</div>-->
|
|
|
|
|
<div class="pr_info_logo fl fl mr10 mb5" id="homepage_portrait_image">
|
|
|
|
|
<%= image_tag(url_to_avatar(@organization),width:"60", height: "60", :id=>'nh_user_tx') %>
|
|
|
|
|
<% if User.current.logged?%>
|
|
|
|
|
<% if User.current.id == @organization.creator_id%>
|
|
|
|
|
<div id="edit_org_file_btn" class="none">
|
|
|
|
|
<div class="homepageEditProfile">
|
|
|
|
|
<a href="<%= clear_org_avatar_temp_organization_path(@organization) %>" data-remote="true" class="homepageEditProfileIcon"></a>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="homepageContentContainer">
|
|
|
|
|
<div class="homepageContent">
|
|
|
|
|
<div class="homepageLeft">
|
|
|
|
|
<div class="homepagePortraitContainer">
|
|
|
|
|
<!--<div class="pr_info_logo fl mr10 mb5">-->
|
|
|
|
|
<!--<%#= image_tag(url_to_avatar(@organization), :width=>"60", :height=>"60", :alt=>"组织logo") %>-->
|
|
|
|
|
<!--</div>-->
|
|
|
|
|
<div class="pr_info_logo fl fl mr10 mb5" id="homepage_portrait_image">
|
|
|
|
|
<%= image_tag(url_to_avatar(@organization),width:"60", height: "60", :id=>'nh_user_tx') %>
|
|
|
|
|
<% if User.current.logged?%>
|
|
|
|
|
<% if User.current.id == @organization.creator_id%>
|
|
|
|
|
<div id="edit_org_file_btn" class="none">
|
|
|
|
|
<div class="homepageEditProfile">
|
|
|
|
|
<a href="<%= clear_org_avatar_temp_organization_path(@organization) %>" data-remote="true" class="homepageEditProfileIcon"></a>
|
|
|
|
|
</div>
|
|
|
|
|
<% end %>
|
|
|
|
|
<% end%>
|
|
|
|
|
</div>
|
|
|
|
|
<!--<div class="orgName fl mb5 f14">组织id:<%#= @organization.id %></div>-->
|
|
|
|
|
<div class="orgName fl mb5 f14">
|
|
|
|
|
<%= link_to @organization.name, organization_path(@organization.id), :class=>"pr_info_name fl c_dark fb break_word" %>
|
|
|
|
|
<% if User.current.logged? %>
|
|
|
|
|
<% if @organization.is_public? %>
|
|
|
|
|
<span class="img_private"><%= l(:label_public)%></span>
|
|
|
|
|
<% else %>
|
|
|
|
|
<span class="img_private"><%= l(:label_private)%></span>
|
|
|
|
|
<% end %>
|
|
|
|
|
<% end %>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<% end %>
|
|
|
|
|
<% end%>
|
|
|
|
|
</div>
|
|
|
|
|
<!--<div class="orgName fl mb5 f14">组织id:<%#= @organization.id %></div>-->
|
|
|
|
|
<div class="orgName fl mb5 f14">
|
|
|
|
|
<%= link_to @organization.name, organization_path(@organization.id), :class=>"pr_info_name fl c_dark fb break_word" %>
|
|
|
|
|
<% if User.current.logged? %>
|
|
|
|
|
<% if @organization.is_public? %>
|
|
|
|
|
<span class="img_private"><%= l(:label_public)%></span>
|
|
|
|
|
<% else %>
|
|
|
|
|
<span class="img_private"><%= l(:label_private)%></span>
|
|
|
|
|
<% end %>
|
|
|
|
|
<% end %>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<% if User.current.admin_of_org?(@organization) %>
|
|
|
|
|
<% if User.current.admin_of_org?(@organization) %>
|
|
|
|
|
<a href="<%= setting_organization_path(@organization) %>" class="pr_join_a c_white"><span class="pr_setting"></span>配置</a>
|
|
|
|
|
<% end %>
|
|
|
|
|
<% end %>
|
|
|
|
|
|
|
|
|
|
<!--<div style="clear:both;">-->
|
|
|
|
|
<!--<%#= link_to l(:label_org_name)+"#{@organization.name}", organization_path(@organization.id), :class=>"pr_info_name fl c_dark fb break_word" %>-->
|
|
|
|
|
<!--<%# if @organization.is_public? %>-->
|
|
|
|
|
<!--<span class="img_private"><%#= l(:label_public)%></span>-->
|
|
|
|
|
<!--<%# else %>-->
|
|
|
|
|
<!--<span class="img_private"><%#= l(:label_private)%></span>-->
|
|
|
|
|
<!--<%# end %>-->
|
|
|
|
|
<!--</div>-->
|
|
|
|
|
<!--<div style="clear:both;">-->
|
|
|
|
|
<!--<%#= link_to l(:label_org_name)+"#{@organization.name}", organization_path(@organization.id), :class=>"pr_info_name fl c_dark fb break_word" %>-->
|
|
|
|
|
<!--<%# if @organization.is_public? %>-->
|
|
|
|
|
<!--<span class="img_private"><%#= l(:label_public)%></span>-->
|
|
|
|
|
<!--<%# else %>-->
|
|
|
|
|
<!--<span class="img_private"><%#= l(:label_private)%></span>-->
|
|
|
|
|
<!--<%# end %>-->
|
|
|
|
|
<!--</div>-->
|
|
|
|
|
|
|
|
|
|
<div class="cl"></div>
|
|
|
|
|
<div class="f12 fontGrey3">
|
|
|
|
|
<%= link_to '文章', organization_org_document_comments_path(@organization) %>
|
|
|
|
|
<% if User.current.logged? %>
|
|
|
|
|
(
|
|
|
|
|
<%= link_to OrgDocumentComment.where("organization_id =? and parent_id is null", @organization.id).count, organization_org_document_comments_path(@organization), :class => "linkBlue" %>
|
|
|
|
|
)
|
|
|
|
|
<% end %>
|
|
|
|
|
|
|
|
|
|
|
<%= link_to '成员', members_organization_path(@organization.id) %>
|
|
|
|
|
<% if User.current.logged? %>
|
|
|
|
|
<div class="cl"></div>
|
|
|
|
|
<div class="f12 fontGrey3">
|
|
|
|
|
<%= link_to '文章', organization_org_document_comments_path(@organization) %>
|
|
|
|
|
<% if User.current.logged? %>
|
|
|
|
|
(
|
|
|
|
|
<%= link_to OrgDocumentComment.where("organization_id =? and parent_id is null", @organization.id).count, organization_org_document_comments_path(@organization), :class => "linkBlue" %>
|
|
|
|
|
)
|
|
|
|
|
<% end %>
|
|
|
|
|
|
|
|
|
|
|
<%= link_to '成员', members_organization_path(@organization.id) %>
|
|
|
|
|
<% if User.current.logged? %>
|
|
|
|
|
(<%= link_to @organization.org_members.count, members_organization_path(@organization.id), :id => 'org_members_count_id', :class => "linkBlue" %>)
|
|
|
|
|
<% end %>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="homepageLeftMenuContainer" id="sub_field_left_lists">
|
|
|
|
|
<%= render :partial => "organizations/org_left_subfield_list", :locals => {:organization => @organization} %>
|
|
|
|
|
<% end %>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="homepageRight" style="margin-top:<%= params[:show_homepage].nil? ? '10px':'0px' %>;">
|
|
|
|
|
<%= render_flash_messages %>
|
|
|
|
|
<%= yield %>
|
|
|
|
|
<%= call_hook :view_layouts_base_content %>
|
|
|
|
|
<div style="clear:both;"></div>
|
|
|
|
|
<div class="homepageLeftMenuContainer" id="sub_field_left_lists">
|
|
|
|
|
<%= render :partial => "organizations/org_left_subfield_list", :locals => {:organization => @organization} %>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="homepageRight" style="margin-top:<%= params[:show_homepage].nil? ? '10px':'0px' %>;">
|
|
|
|
|
<%= render_flash_messages %>
|
|
|
|
|
<%= yield %>
|
|
|
|
|
<%= call_hook :view_layouts_base_content %>
|
|
|
|
|
<div style="clear:both;"></div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<!--页面底部-->
|
|
|
|
|
<div class="cl"></div>
|
|
|
|
|
<div id="Footer">
|
|
|
|
|
<div class="footerAboutContainer">
|
|
|
|
|
<ul class="footerAbout">
|
|
|
|
|
<li class="fl"><a href="<%= about_us_path %>" class=" f_grey mw20" target="_blank">关于我们</a>|</li>
|
|
|
|
|
<li class="fl"><a href="<%= agreement_path %>" class=" f_grey mw20" target="_blank">服务协议</a>|</li>
|
|
|
|
|
<li class="fl"><a href="http://forge.trustie.net/forums/1/memos/1168" class="f_grey mw20" target="_blank">帮助中心</a>|</li>
|
|
|
|
|
<li class="fl"><a href="<%= forums_path(:reorder_complex=>'desc')%>" class="f_grey mw20" target="_blank">贴吧交流</a></li>
|
|
|
|
|
</ul>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="cl"></div>
|
|
|
|
|
<!--页面底部-->
|
|
|
|
|
<div class="cl"></div>
|
|
|
|
|
<div id="Footer">
|
|
|
|
|
<div class="footerAboutContainer">
|
|
|
|
|
<ul class="footerAbout">
|
|
|
|
|
<li class="fl"><a href="<%= about_us_path %>" class=" f_grey mw20" target="_blank">关于我们</a>|</li>
|
|
|
|
|
<li class="fl"><a href="<%= agreement_path %>" class=" f_grey mw20" target="_blank">服务协议</a>|</li>
|
|
|
|
|
<li class="fl"><a href="http://forge.trustie.net/forums/1/memos/1168" class="f_grey mw20" target="_blank">帮助中心</a>|</li>
|
|
|
|
|
<li class="fl"><a href="<%= forums_path(:reorder_complex=>'desc')%>" class="f_grey mw20" target="_blank">贴吧交流</a></li>
|
|
|
|
|
</ul>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="cl"></div>
|
|
|
|
|
|
|
|
|
|
<ul class="copyright mt10">
|
|
|
|
|
<li class="fl mr30">Copyright © 2007-2015, All Rights Riserved</li>
|
|
|
|
|
<li>ICP备09019772</li>
|
|
|
|
|
</ul>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="cl"></div>
|
|
|
|
|
<div id="ajax-modal" style="display:none;"></div>
|
|
|
|
|
<ul class="copyright mt10">
|
|
|
|
|
<li class="fl mr30">Copyright © 2007-2015, All Rights Riserved</li>
|
|
|
|
|
<li>ICP备09019772</li>
|
|
|
|
|
</ul>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="cl"></div>
|
|
|
|
|
<div id="ajax-modal" style="display:none;"></div>
|
|
|
|
|
|
|
|
|
|
<div id="ajax-indicator" style="display:none;">
|
|
|
|
|
<span><%= l(:label_loading) %></span>
|
|
|
|
|
</div>
|
|
|
|
|
<div id="ajax-indicator" style="display:none;">
|
|
|
|
|
<span><%= l(:label_loading) %></span>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<script type="text/javascript">
|
|
|
|
|
$("#courseMenu").mouseenter(function(){
|
|
|
|
|
$("#topnav_course_menu").show();
|
|
|
|
|
});
|
|
|
|
|
$("#courseMenu").mouseleave(function(){
|
|
|
|
|
$("#topnav_course_menu").hide();
|
|
|
|
|
});
|
|
|
|
|
$("#projectMenu").mouseenter(function(){
|
|
|
|
|
$("#topnav_project_menu").show();
|
|
|
|
|
});
|
|
|
|
|
$("#projectMenu").mouseleave(function(){
|
|
|
|
|
$("#topnav_project_menu").hide();
|
|
|
|
|
});
|
|
|
|
|
<script type="text/javascript">
|
|
|
|
|
$("#courseMenu").mouseenter(function(){
|
|
|
|
|
$("#topnav_course_menu").show();
|
|
|
|
|
});
|
|
|
|
|
$("#courseMenu").mouseleave(function(){
|
|
|
|
|
$("#topnav_course_menu").hide();
|
|
|
|
|
});
|
|
|
|
|
$("#projectMenu").mouseenter(function(){
|
|
|
|
|
$("#topnav_project_menu").show();
|
|
|
|
|
});
|
|
|
|
|
$("#projectMenu").mouseleave(function(){
|
|
|
|
|
$("#topnav_project_menu").hide();
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
function show_homepage(id, has_homepage){
|
|
|
|
|
if (has_homepage == 1)
|
|
|
|
|
{
|
|
|
|
|
window.location.href = "/organizations/" + id + "?show_homepage=1";
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
alert("您还未设置首页!");
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
function show_homepage(id, has_homepage){
|
|
|
|
|
if (has_homepage == 1)
|
|
|
|
|
{
|
|
|
|
|
window.location.href = "/organizations/" + id + "?show_homepage=1";
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
alert("您还未设置首页!");
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
$(document).ready(function(){
|
|
|
|
|
$("#orgUser,#orgSwitch").click(function(){
|
|
|
|
|
$(".org_login_list").toggle();
|
|
|
|
|
if($("#orgArrow").attr("class") == "orgMenuArrow"){
|
|
|
|
|
$("#orgArrow").attr("class","orgMenuArrow2");
|
|
|
|
|
}
|
|
|
|
|
else {
|
|
|
|
|
$("#orgArrow").attr("class","orgMenuArrow") ;
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
if($(".org_login_list").children().click){
|
|
|
|
|
$("#orgUser,#orgSwitch,#org_login_list").mouseout(function(){
|
|
|
|
|
$(".org_login_list").css("display","none");
|
|
|
|
|
$("#orgArrow").attr("class","orgMenuArrow");
|
|
|
|
|
};
|
|
|
|
|
});
|
|
|
|
|
$("#orgUser,#orgSwitch,#org_login_list").mouseover(function(){
|
|
|
|
|
$(".org_login_list").css("display","block");
|
|
|
|
|
$("#orgArrow").attr("class","orgMenuArrow2");
|
|
|
|
|
});
|
|
|
|
|
});
|
|
|
|
|
</script>
|
|
|
|
|
</body>
|
|
|
|
|