Merge branch 'develop' of http://repository.trustie.net/xianbo/trustie2 into develop
This commit is contained in:
commit
c8f4149206
|
@ -18,18 +18,41 @@
|
|||
<%= call_hook :view_layouts_base_html_head %>
|
||||
<!-- page specific tags -->
|
||||
<%= yield :header_tags -%>
|
||||
|
||||
<!-- MathJax的配置 -->
|
||||
<script type="text/javascript"
|
||||
src="/javascripts/MathJax/MathJax.js?config=TeX-AMS-MML_HTMLorMML">
|
||||
</script>
|
||||
<!-- 配置 : 在生成的公式图片上去掉Math定义的右键菜单,$$ $$ \( \) \[ \] 中的公式给予显示-->
|
||||
<script type="text/x-mathjax-config">
|
||||
MathJax.Hub.Config({
|
||||
showMathMenu: false,
|
||||
showMathMenuMSIE: false,
|
||||
tex2jax: {inlineMath: [['$','$'], ['\\(','\\)']]}
|
||||
});
|
||||
</script>
|
||||
|
||||
</head>
|
||||
<!--add by huang-->
|
||||
<body onload="prettyPrint();">
|
||||
<div class="orgContainer">
|
||||
<div class="orgNav">
|
||||
<div class="navOrgLogo fl"><a href="javascript:void(0);"><img src="/images/home_logo.png" width="21" height="19" alt="确实Trustie" class="mt3" /></a></div>
|
||||
<div class="navOrgLogo fl"><a href="javascript:void(0);" onclick="show_homepage(<%= @organization.id %>, <%= @organization.home_id.nil? ? 0 : 1 %>);"><img src="/images/home_logo.png" width="21" height="19" alt="Trustie" class="mt3" /></a></div>
|
||||
<ul>
|
||||
<li class="navOrgMenu fl"> <%= link_to '首页', organization_path(@organization, :show_homepage => 1),:class=>"linkGrey8 f14" %></li>
|
||||
<li class="navOrgMenu fl">
|
||||
<a href="javascript:void(0);" onclick="show_homepage(<%= @organization.id %>, <%= @organization.home_id.nil? ? 0 : 1 %>);" class="linkGrey8 f14">首页</a>
|
||||
<%#= link_to '首页', organization_path(@organization, :show_homepage => 1),:class=>"linkGrey8 f14" %>
|
||||
</li>
|
||||
<% if User.current.logged? %>
|
||||
<li class="navOrgMenu fr"><%=link_to User.current, user_path(User.current), :class => "linkGrey8 f14" %></li>
|
||||
<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" %></li>
|
||||
<li><%= link_to "退出",signout_path, :class =>"linkGrey8", :method => 'post', :rel => "nofollow" %></li>
|
||||
</ul>
|
||||
</span>
|
||||
</li>
|
||||
<li class="navOrgMenu fr" id="orgUser" style="cursor:pointer;"><%=link_to User.current, user_path(User.current), :class => "linkGrey8 f14", :id => "orgUserName" %></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>
|
||||
<li class="navOrgMenu fr"><a href="<%= signin_path(:login=>false) %>" class="linkGrey8 f14 mr15">注册</a></li>
|
||||
|
@ -73,10 +96,12 @@
|
|||
<!--<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 @organization.is_public? %>
|
||||
<span class="img_private"><%= l(:label_public)%></span>
|
||||
<% else %>
|
||||
<span class="img_private"><%= l(:label_private)%></span>
|
||||
<% 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>
|
||||
|
||||
|
@ -95,10 +120,17 @@
|
|||
|
||||
<div class="cl"></div>
|
||||
<div class="f12 fontGrey3">
|
||||
<%= link_to '文章', organization_org_document_comments_path(@organization) %> (
|
||||
<%= link_to OrgDocumentComment.where("organization_id =? and parent_id is null", @organization.id).count, organization_org_document_comments_path(@organization), :class => "linkBlue" %>
|
||||
) |
|
||||
<%= link_to '成员', members_organization_path(@organization.id) %> (<%= link_to @organization.org_members.count, members_organization_path(@organization.id), :id => 'org_members_count_id', :class => "linkBlue" %>)
|
||||
<%= 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">
|
||||
|
@ -152,7 +184,33 @@
|
|||
$("#projectMenu").mouseleave(function(){
|
||||
$("#topnav_project_menu").hide();
|
||||
});
|
||||
</script>
|
||||
|
||||
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){
|
||||
$(".org_login_list").css("display","none");
|
||||
$("#orgArrow").attr("class","orgMenuArrow");
|
||||
};
|
||||
});
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
|
|
|
@ -22,11 +22,10 @@
|
|||
</head>
|
||||
|
||||
<body>
|
||||
<div class="resourceSharePopup">
|
||||
<!--<div class="resourceSharePopup">-->
|
||||
<div>
|
||||
<div class="relateText fl">请选择关联到组织的课程</div>
|
||||
</div>
|
||||
<div class="resourcePopupClose"> <a href="javascript:void(0);" class="resourceClose"></a></div>
|
||||
<div class="fl">
|
||||
<%=form_tag url_for(:controller => 'organizations', :action => 'join_courses', :organization_id => organization_id),:method => 'post', :id => 'join_courses_form', :remote => true,:class=>"resourcesSearchBox" do %>
|
||||
<input type="text" name="courses" placeholder="搜索您已加入的课程的名称" class="searchCourse" />
|
||||
|
@ -42,7 +41,7 @@
|
|||
<div>
|
||||
</div>
|
||||
<div class="cl"></div>
|
||||
</div>
|
||||
<!--</div>-->
|
||||
|
||||
<script type="text/javascript">
|
||||
var lastSearchCondition = '';
|
||||
|
|
|
@ -22,11 +22,10 @@
|
|||
</head>
|
||||
|
||||
<body>
|
||||
<div class="resourceSharePopup">
|
||||
|
||||
<div>
|
||||
<div class="relateText fl">请选择关联到组织的项目</div>
|
||||
</div>
|
||||
<div class="resourcePopupClose"> <a href="javascript:void(0);" class="resourceClose"></a></div>
|
||||
<div class="fl">
|
||||
<%=form_tag url_for(:controller => 'organizations', :action => 'join_projects', :organization_id => organization_id),:method => 'post', :id => 'join_projects_form', :remote => true,:class=>"resourcesSearchBox" do %>
|
||||
<input type="text" name="projects" placeholder="搜索您已加入的项目的名称" class="searchCourse" />
|
||||
|
@ -38,7 +37,7 @@
|
|||
<% end %>
|
||||
</div>
|
||||
<div class="cl"></div>
|
||||
</div>
|
||||
|
||||
|
||||
<script type="text/javascript">
|
||||
var lastSearchCondition = '';
|
||||
|
|
|
@ -1,12 +1,11 @@
|
|||
<div class="homepageLeftMenuBlock">
|
||||
<%= link_to "组织首页",organization_path(@organization, :show_homepage => 1), :class => 'homepageMenuText' %>
|
||||
</div>
|
||||
<div class="homepageLeftMenuBlock">
|
||||
<%= link_to "动态",organization_path(organization), :class => "homepageMenuText" %>
|
||||
</div>
|
||||
<div class="homepageLeftMenuBlock">
|
||||
<a href="javascript:void(0);" class="homepageMenuText" onclick="$('#homepageLeftMenuProjects').slideToggle();">项目</a>
|
||||
<%=link_to "", join_project_menu_organization_path(organization),:remote => true, :method => "post", :class => "homepageMenuSetting fr", :title => "关联项目"%>
|
||||
<% if User.current.logged? %>
|
||||
<%=link_to "", join_project_menu_organization_path(organization),:remote => true, :method => "post", :class => "homepageMenuSetting fr", :title => "关联项目"%>
|
||||
<% end %>
|
||||
</div>
|
||||
<div class="homepageLeftMenuCourses" id="homepageLeftMenuProjects" style="display:<%= organization.projects.count == 0?'none':'' %>">
|
||||
<ul >
|
||||
|
@ -15,7 +14,9 @@
|
|||
</div>
|
||||
<div class="homepageLeftMenuBlock">
|
||||
<a href="javascript:void(0);" class="homepageMenuText" onclick="$('#homepageLeftMenuCourses').slideToggle();">课程</a>
|
||||
<%=link_to "", join_course_menu_organization_path(organization),:remote => true, :method => "post", :class => "homepageMenuSetting fr", :title => "关联课程"%>
|
||||
<% if User.current.logged? %>
|
||||
<%=link_to "", join_course_menu_organization_path(organization),:remote => true, :method => "post", :class => "homepageMenuSetting fr", :title => "关联课程"%>
|
||||
<% end %>
|
||||
</div>
|
||||
<div class="homepageLeftMenuCourses" id="homepageLeftMenuCourses" style="display:<%= organization.courses.count == 0 ?'none':'' %>">
|
||||
<ul >
|
||||
|
|
|
@ -37,7 +37,7 @@
|
|||
</div>
|
||||
<div class="cl"></div>
|
||||
|
||||
<% html_title(l(:label_organization_new)) -%>
|
||||
<% html_title(l(:label_edit_organization)) -%>
|
||||
|
||||
<script>
|
||||
function update_org(id){
|
||||
|
|
|
@ -1,3 +1,11 @@
|
|||
$('#topnav_course_menu').hide();
|
||||
|
||||
$('#ajax-modal').html('<%= escape_javascript(render :partial => 'join_course_menu', :locals => {:organization_id => @organization.id}) %>');
|
||||
$('#ajax-modal').show();
|
||||
showModal('ajax-modal', '320px');
|
||||
$('#ajax-modal').siblings().hide();
|
||||
$('#ajax-modal').before(
|
||||
"<a href='javascript:' onclick='hideModal();location.reload();' class='resourceClose' style='margin-left: 300px;'></a>");
|
||||
//$('#ajax-modal').css('position','absolute')
|
||||
$('#ajax-modal').css("top","").css("left","");
|
||||
$('#ajax-modal').parent().addClass("resourceSharePopup");
|
||||
|
||||
|
|
|
@ -1,3 +1,11 @@
|
|||
$('#topnav_project_menu').hide();
|
||||
|
||||
$('#ajax-modal').html('<%= escape_javascript(render :partial => 'join_project_menu', :locals => {:organization_id => @organization.id}) %>');
|
||||
$('#ajax-modal').show();
|
||||
showModal('ajax-modal', '320px');
|
||||
$('#ajax-modal').siblings().hide();
|
||||
$('#ajax-modal').before(
|
||||
"<a href='javascript:' onclick='hideModal();location.reload();' class='resourceClose' style='margin-left: 300px;'></a>");
|
||||
//$('#ajax-modal').css('position','absolute');
|
||||
$('#ajax-modal').css("top","").css("left","");
|
||||
$('#ajax-modal').parent().addClass("resourceSharePopup");
|
||||
|
||||
|
|
|
@ -28,10 +28,9 @@
|
|||
<!--<div class="fr mt5"><a href="javascript:void(0);" class="vl_btn fb" onclick="zip()"><span class="vl_fork"></span>Fork</a> <span href="javascript:void(0);" class="vl_btn_2 fb">0</span> </div>-->
|
||||
<% unless User.current.id == @project.user_id %>
|
||||
<div class="fr mt5"><%= link_to "<span class='vl_fork'></span>".html_safe+"Fork", {:controller => 'repositories', :action => 'forked'}, :class=>"vl_btn"%>
|
||||
<span href="javascript:void(0);" class="vl_btn_2 fb"><%= @project.forked_count.to_i %></span>
|
||||
</div>
|
||||
<% end %>
|
||||
<%#= link_to "<span id='span'>My span </span>#{@user.profile.my_data}".html_safe, "#", class: 'button white' %>
|
||||
|
||||
<span href="javascript:void(0);" class="vl_btn_2 fb"><%= @project.forked_count.to_i %></span> </div>
|
||||
<div class="cl"></div>
|
||||
<div class="recordBanner mt10">
|
||||
<% if @changesets && !@changesets.empty? %>
|
||||
|
@ -53,12 +52,14 @@
|
|||
</span>
|
||||
|
||||
<span class="fr mr5"><font class="fb ml2 mr2 vl_commit">
|
||||
<%=link_to @changesets_all_count, {:action => 'changes', :path => to_path_param(@path), :id => @project, :repository_id => @repository.identifier_param, :rev => @rev,:page=>1 ,:commit_count =>"#{@changesets_all_count}"} %></font> 提交
|
||||
|
||||
<%=link_to @changesets_all_count, {:action => 'changes', :path => to_path_param(@path), :id => @project,
|
||||
:repository_id => @repository.identifier_param,
|
||||
:rev => @rev,:page=>1 ,
|
||||
:commit_count =>"#{@changesets_all_count}"} %></font> 提交
|
||||
</span>
|
||||
</div>
|
||||
<% end %>
|
||||
</div>
|
||||
|
||||
<!--contextual end-->
|
||||
|
||||
<% if !@entries.nil? && authorize_for('repositories', 'browse') %>
|
||||
|
@ -67,14 +68,14 @@
|
|||
<%# end %>
|
||||
<%= render :partial => 'dir_list' %>
|
||||
<% end %>
|
||||
<%= render_properties(@properties) %>
|
||||
<%#= render_properties(@properties) %>
|
||||
|
||||
<!-- 代码修订 -->
|
||||
<%= render_properties(@properties) %>
|
||||
<%#= render_properties(@properties) %>
|
||||
|
||||
|
||||
<a href="https://<%=Setting.host_name %>/forums/1/memos/1232" >如何提交代码</a>
|
||||
|
||||
</div>
|
||||
<% content_for :header_tags do %>
|
||||
<%= stylesheet_link_tag "scm" %>
|
||||
<% end %>
|
||||
|
|
|
@ -387,6 +387,7 @@ zh:
|
|||
label_organization_list: 组织列表
|
||||
label_school_plural: 学校列表
|
||||
label_organization_new: 新建组织
|
||||
label_edit_organization: 编辑组织
|
||||
label_organization_edit: 修改组织
|
||||
label_project_plural: 项目列表
|
||||
|
||||
|
|
|
@ -484,7 +484,7 @@ a.uploadIcon {background:url(images/resource_icon_list.png) 8px -60px no-repeat;
|
|||
/*发送资源弹窗*/
|
||||
/*.resourceShareContainer {width:100%; height:100%; background:#666; filter:alpha(opacity=50); opacity:0.5; -moz-opacity:0.5; position:absolute; left:0; top:0; z-index:-999;}*/
|
||||
/*.resourceSharePopup {width:300px; height:auto; border:3px solid #15bccf; padding-left:16px; padding-bottom:16px; background-color:#ffffff; position:absolute; top:50%; left:50%; margin-left:-150px; z-index:1000;}*/
|
||||
.resourceSharePopup {width:300px; height:auto; border:3px solid #269ac9; padding-left:16px; padding-bottom:16px; background-color:#ffffff; position:absolute; top:50%; left:50%; margin-left:-150px; z-index:1000;}
|
||||
.resourceSharePopup {width:300px; height:auto; border:3px solid #269ac9 !important; padding-left:16px; padding-bottom:16px; background-color:#ffffff; position:absolute; top:50%; left:50%; margin-left:-150px; z-index:1000;}
|
||||
.sendText {font-size:16px; color:#269ac9; line-height:16px; padding-top:20px; width:110px; display:inline-block; font-weight: bold;}
|
||||
.resourcesSendTo {float:left; height:20px; margin-top:15px;}
|
||||
.boxContainer {height:33px; line-height:33px; position:relative}
|
||||
|
|
|
@ -64,4 +64,8 @@ a.cancelBtn:hover {background-color:#717171; color:#ffffff;}
|
|||
a.linkGrey8 {color:#888888;}
|
||||
a.linkGrey8:hover {color:#585858;}
|
||||
.orgBorder {width:583px; height:21px; border-bottom:3px solid #e4e4e4; float:left;}
|
||||
.orgListRow {border-bottom:1px solid #e4e4e4; padding-bottom:5px; color:#555555;}
|
||||
.orgListRow {border-bottom:1px solid #e4e4e4; padding-bottom:5px; color:#555555;}
|
||||
.orgMenuArrow {background:url(../images/nav_icon.png) -10px -165px no-repeat; position:relative; display:inline-block; width:20px; height:30px;}
|
||||
.orgMenuArrow2 {background:url(../images/nav_icon.png) -10px -132px no-repeat; position:relative; display:inline-block; width:20px; height:30px;}
|
||||
.org_login_list{ border:1px solid #eaeaea; background:#fff; padding-left:10px; padding-bottom:10px; padding-top:8px; width:60px; left:-53px; position:absolute; z-index:9999; line-height:2; box-shadow: 0px 2px 8px rgba(146, 153, 169, 0.5); margin-top: 30px;}
|
||||
#orgUserName {max-width:50px; overflow:hidden; white-space: nowrap; text-overflow: ellipsis; display:inline-block;}
|
Loading…
Reference in New Issue