1、添加CSS文件

2、调整首页HTML
3、去掉base_header中没用的erb语句
This commit is contained in:
sw 2015-03-16 11:51:12 +08:00
parent 0a19f65611
commit 747a109638
6 changed files with 348 additions and 70 deletions

View File

@ -1,32 +1,3 @@
<%
request.headers['REQUEST_URI'] = "" if request.headers['REQUEST_URI'].nil?
realUrl = request.original_url
if (realUrl.match(/.*forge\.trustie\.net\/*/))
#@nav_dispaly_project_label = 1
#@nav_dispaly_forum_label = 1
elsif (realUrl.match(/.*course\.trustie\.net\/*/))
#@nav_dispaly_course_all_label = 1
#@nav_dispaly_forum_label = 1
#@nav_dispaly_course_label = nil
#@nav_dispaly_store_all_label = 1
elsif (realUrl.match(/.*user\.trustie\.net\/*/))
#@nav_dispaly_home_path_label = 1
#@nav_dispaly_main_course_label = 1
#@nav_dispaly_main_project_label = 1
#@nav_dispaly_main_contest_label = 1
elsif (realUrl.match(/.*contest\.trustie\.net\/*/))
#@nav_dispaly_contest_label = 1
#@nav_dispaly_store_all_label = 1
else
#@nav_dispaly_project_all_label = 1
#@nav_dispaly_course_all_label = 1
#@nav_dispaly_forum_label = 1
#@nav_dispaly_bid_label = 1
#@nav_dispaly_contest_label = 1
#@nav_dispaly_store_all_label = 1
#@nav_dispaly_user_label = 1
end
%>
<%= render :partial => "layouts/base_feedback" %>
<div id="top-menu" style="background-color: #15bccf;height:40px;margin-top: 10px;margin-bottom: 10px;">
<div class="welcome_logo">
@ -66,12 +37,8 @@
</ul>
</div>
<% end -%>
<%#= render_menu :top_menu if User.current.logged? || !Setting.login_required? -%>
<%= render_dynamic_nav if User.current.logged? || !Setting.login_required? -%>
<%# 自建导航条在base页面中以 (@nav_dispaly......) 开头变量设定, 全局搜索即可发现 %>
</div>
<div style="border-top:solid 1px #C6E9F1;width:940px;margin-left:auto;margin-right:auto;margin-bottom: 0px;margin-top: -10px;"></div>
<div style="clear:left;"></div>
<script type="text/javascript">
function setMessageCount () {

View File

@ -1,45 +1,49 @@
<!DOCTYPE html>
<html lang="<%= current_language %>">
<head>
<meta charset="utf-8" />
<title><%=h html_title %></title>
<meta name="description" content="<%= Redmine::Info.app_name %>" />
<meta name="keywords" content="issue,bug,tracker" />
<%= csrf_meta_tag %>
<%= favicon %>
<%= stylesheet_link_tag 'jquery/jquery-ui-1.9.2', 'application', 'nyan', :media => 'all' %>
<%= stylesheet_link_tag 'rtl', :media => 'all' if l(:direction) == 'rtl' %>
<%= javascript_heads %>
<%= javascript_include_tag "jquery.leanModal.min" %>
<%= javascript_include_tag 'seems_rateable/jRating', 'seems_rateable/rateable'%>
<%= heads_for_theme %>
<%= call_hook :view_layouts_base_html_head %>
<!-- page specific tags -->
<%= yield :header_tags -%>
<meta charset="utf-8" />
<title><%=h html_title %></title>
<meta name="description" content="<%= Redmine::Info.app_name %>" />
<meta name="keywords" content="issue,bug,tracker" />
<%= stylesheet_link_tag 'jquery/jquery-ui-1.9.2', 'application', 'nyan', :media => 'all' %>
<%= stylesheet_link_tag 'rtl', :media => 'all' if l(:direction) == 'rtl' %>
<%= javascript_include_tag "jquery.leanModal.min" %>
<%= javascript_include_tag 'seems_rateable/jRating', 'seems_rateable/rateable'%>
<%= csrf_meta_tag %>
<%= favicon %>
<%= javascript_heads %>
<%= heads_for_theme %>
<%= call_hook :view_layouts_base_html_head %>
<!-- page specific tags -->
<%= yield :header_tags -%>
</head>
<body class="<%=h body_css_classes %>">
<div id="wrapper">
<div id="wrapper2">
<div id="wrapper3">
<%=render :partial => 'layouts/base_header'%>
<div id="main" class="nosidebar">
<div id="content_">
<%= render_flash_messages %>
<%= yield %>
<%= call_hook :view_layouts_base_content %>
<div style="clear:both;"></div>
<%=render :partial => 'layouts/base_footer'%>
<div id="wrapper">
<div id="wrapper2">
<div id="wrapper3">
<%=render :partial => 'layouts/base_header'%>
<div id="main" class="nosidebar">
<div id="content_">
<%= render_flash_messages %>
<%= yield %>
<%= call_hook :view_layouts_base_content %>
<div style="clear:both;"></div>
<%=render :partial => 'layouts/base_footer'%>
</div>
</div>
</div>
<div id="ajax-indicator" style="display:none;">
<span>
<%= l(:label_loading) %>
</span>
</div>
<div id="ajax-modal" style="display:none;"></div>
</div>
</div>
</div>
</div>
<div id="ajax-indicator" style="display:none;"><span><%= l(:label_loading) %></span></div>
<div id="ajax-modal" style="display:none;"></div>
</div>
</div>
<%= call_hook :view_layouts_base_body_bottom %>
<%= call_hook :view_layouts_base_body_bottom %>
</body>
</html>

View File

@ -0,0 +1,49 @@
<!DOCTYPE html>
<html lang="<%= current_language %>">
<head>
<meta charset="utf-8" />
<title><%=h html_title %></title>
<meta name="description" content="<%= Redmine::Info.app_name %>" />
<meta name="keywords" content="issue,bug,tracker" />
<%= stylesheet_link_tag 'jquery/jquery-ui-1.9.2', 'application', 'nyan', :media => 'all' %>
<%= stylesheet_link_tag 'rtl', :media => 'all' if l(:direction) == 'rtl' %>
<%= javascript_include_tag "jquery.leanModal.min" %>
<%= javascript_include_tag 'seems_rateable/jRating', 'seems_rateable/rateable'%>
<%= csrf_meta_tag %>
<%= favicon %>
<%= javascript_heads %>
<%= heads_for_theme %>
<%= call_hook :view_layouts_base_html_head %>
<!-- page specific tags -->
<%= yield :header_tags -%>
</head>
<body class="<%=h body_css_classes %>">
<div id="wrapper">
<div id="wrapper2">
<div id="wrapper3">
<%=render :partial => 'layouts/base_header'%>
<div id="main" class="nosidebar">
<div id="content_">
<%= render_flash_messages %>
<%= yield %>
<%= call_hook :view_layouts_base_content %>
<div style="clear:both;"></div>
<%=render :partial => 'layouts/base_footer'%>
</div>
</div>
</div>
<div id="ajax-indicator" style="display:none;">
<span>
<%= l(:label_loading) %>
</span>
</div>
<div id="ajax-modal" style="display:none;"></div>
</div>
</div>
<%= call_hook :view_layouts_base_body_bottom %>
</body>
</html>

View File

@ -0,0 +1,49 @@
/*右侧内容--动态*/
.project_r_h{ width:670px; height:40px; background:#eaeaea; margin-bottom:10px;}
.project_h2{ background:#64bdd9; color:#fff; height:33px; width:90px; text-align:center; font-weight:normal; padding-top:7px; font-size:16px;}
.project_r_box{ border:1px solid #e2e1e1; width:670px; margin-top:10px;}
.project_h3 { color:#646464; font-size:14px; padding:0 10px; border-bottom:1px solid #e2e1e1;}
.more{ float:right; font-size:12px; font-weight:normal; color:#a9a9a9; margin-top:3px;}
.more:hover{ color:#64bdd9;}
.project_box_ul{ padding:0 10px;}
.project_box_list{ padding:10px 0; border-bottom:1px dashed #e2e1e1; padding-left:30px; color:#6f6c6c;}
.img_problem{ background:url(../images/img_project.png) 0 -20px no-repeat;}
.img_talk{ background:url(../images/img_project.png) 0 -62px no-repeat;}
.img_ziyuan{ background:url(../images/img_project.png) 0 -115px no-repeat;}
.img_edition{ background:url(../images/img_project.png) 0 -167px no-repeat;}
.project_name{ color:#058c42;}
.project_name:hover{ color:#016f33;}
.project_txt{ color:#0781b4; width:445px; display:block; float:left; overflow:hidden; white-space: nowrap; text-overflow:ellipsis;}
.project_txt02{ color:#0781b4; width:618px; display:block; float:left; overflow:hidden; white-space: nowrap; text-overflow:ellipsis;}
.project_txt:hover{ color:#066e9a;}
.noline{ border-bottom:none;}
/*问题跟踪*/
.problem_top{ margin:10px 0 ;}
.problem_search_input{ border:1px solid #64bdd9; width:180px; height:24px; color:#9b9b9b; padding-left:5px; margin-bottom:10px;}
.problem_search_btn{ background:#64bdd9; color:#fff; text-align: center; width:40px; height:22px;border:1px solid #64bdd9; padding-top:2px; cursor:pointer;}
.problem_search_btn:hover{ background:#3da1c1; border:1px solid #3da1c1;}
.problem_new_btn{ margin-left:10px; border:1px solid #ff7143; color:#ff7143; width:60px; height:22px; font-size:12px; text-align:center; padding-top:2px;}
.problem_new_btn:hover{ background:#ff7143; color:#fff;}
.problem_p{ color:#535252; margin-top:5px;}
.problem_p span{ color:#ff3e00;}
.problem_pic{ display:block; width:42px; height:42px; padding:3px; border:1px solid #e3e3e3;}
.problem_pic:hover{border:1px solid #64bdd9;}
.problem_txt{ width:610px; margin-left:10px; color:#777777;}
.problem_name{ color:#ff5722;}
.problem_name:hover{ color:#d33503;}
.problem_tit{ color:#0781b4; width:430px; display:block; overflow:hidden; white-space: nowrap; text-overflow:ellipsis;}
.problem_tit:hover{ color:#09658c; }
.problem_main{ border-bottom:1px dashed #d4d4d4; padding-bottom:10px; margin-bottom:10px;}
/****翻页***/
.wlist{}
.wlist a{ float:right; border:1px solid #64bdd9; padding:0 5px; margin-left:3px; color:#64bdd9;}
.wlist a:hover{border:1px solid #64bdd9; background-color:#64bdd9; color:#fff; text-decoration:none;}
.wlist_select a { background-color:#48aac9; color:#fff;}

View File

@ -0,0 +1,59 @@
.topbar_info02{ margin:5px 10px;width:480px; }
.topbar_info02 p{color: #7f7f7f;}
.search{ margin-top:8px; margin-left:71px;}
/*信息*/
.project_info{ background:#fff; padding:10px;width:222px; padding-right:8px; margin-bottom:10px;}
.pr_info_id{ width:137px; color:#5a5a5a; font-size:14px; margin-top:5px;}
.pr_info_logo{ border:1px solid #eaeaea; width:60px; height:60px; padding:1px;}
.pr_info_logo:hover{ border:1px solid #64bdd9; }
.pr_info_join{}
.pr_info_join a{ color:#fff; display:block; padding:0 5px; padding-top:3px; margin-right:10px; float:left; height:19px; background:#64bdd9; text-align:center; }
.pr_info_join a:hover{ background:#41a8c8;}
.pr_info_name{ color:#3e4040; font-size:14px; line-height:1.5;}
.pr_info_name:hover{ color:#3ca5c6;}
.pr_info_score{ font-size:14px; color:#3e4040; }
.pr_info_score a{ color:#ff7143;}
.pr_info_score a:hover{ color:#64bdd9;}
.img_private{ background:url(../images/img_project.png) 0 0 no-repeat; width:32px; height:16px; color:#fff; font-size:12px; padding-left:7px; }
.info_foot_num{ color:#3ca5c6; }
.pr_info_foot{ color:#7f7f7f; margin-top:5px; }
.info_foot_num:hover{ color:#2390b2;}
.info_box{background:#fff; padding:10px;width:222px; }
.info_box ul li{ font-size:14px; color: #3e4040; line-height:1.9;}
/*左侧导航*/
.subNavBox{width:240px; background:#fff;margin:10px 10px 0 0;}
.subNav{border-bottom:solid 1px #e5e3da;cursor:pointer;font-weight:bold;font-size:14px;color:#3ca5c6;line-height:28px;padding-left:10px;background-color:#fff;}
.subNav_jiantou{background:url(../images/jiantou1.jpg) no-repeat;background-position:95% 50%; background-color:#fff;}
.subNav_jiantou:hover{color:#0781b4; }
.currentDd{color:#0781b4; }
.currentDt{background-color:#fff; }
.navContent{display: none;border-bottom:solid 1px #e5e3da; }
.navContent li a{display:block;width:240px;heigh:28px;text-align:center;font-size:12px;line-height:28px;color:#333}
.navContent li a:hover{color:#fff;background-color:#b3e0ee}
.subnav_num{ font-weight:normal; color:#ff7143; font-size:12px;}
.subnav_green{ background:#28be6c; color:#fff; font-size:12px; font-weight:normal;height:20px; padding:0px 5px; text-align:center; margin-top:5px; margin-left:82px;}
.ml95{ margin-left:97px;}
.ml105{ margin-left:120px;}
.subnav_green:hover{ background:#14ad5a;}
/*简介*/
.project_intro{ width:220px; padding:10px; background:#fff; margin-top:10px; padding-top:5px; color:#6d6d6d; line-height:1.9;}
.course_description{max-height: 110px;overflow:hidden;}
.course_description_none{max-height: none;}
.lg-foot{ border:1px solid #e8eef2; color: #929598; text-align:center; width:220px; height:23px; cursor:pointer;}
.lg-foot:hover{ color:#787b7e;}
/****标签(和资源库的tag样式一致)***/
.project_Label{ width:220px; padding:10px; background:#fff; margin-top:10px; padding-top:5px; margin-bottom:10px;}
a.yellowBtn{ display:inline-block;color:#0d90c3; height:22px;}
.submit{height:21px;border:0; cursor:pointer; background:url(../images/btn.png) no-repeat 0 0;width:42px; margin-top:2px; margin-left:3px; }
.isTxt{background:#fbfbfb url(../images/inputBg.png) repeat-x left top;height:22px;line-height:22px;border:1px solid #c1c1c1;padding:0 5px;color:#666666;}
.re_tag{ width: auto; padding:0 5px; padding-top:3px; height:19px; border:1px solid #f8df8c; background:#fffce6; margin-right:5px; }
.re_tag a{ color:#0d90c3;}
.tag_h{ }
.tag_h span,.tag_h a{ margin-top:5px;}

View File

@ -0,0 +1,150 @@
/* CSS Document */
body,h1,h2,h3,h4,h5,h6,hr,p,blockquote,dl,dt,dd,ul,ol,li,pre,form,fieldset,legend,button,input,textarea,th,td{ margin:0; padding:0;}
body,table,input,textarea,select,button { font-family: "微软雅黑","宋体"; font-size:12px;line-height:1.5; background:#eaebec;}
div,img,tr,td,table{ border:0;}
table,tr,td{border:0;cellspacing:0; cellpadding:0;}
ol,ul,li{ list-style-type:none}
a:link,a:visited{color:#7f7f7f;text-decoration:none;}
a:hover,a:active{color:#000;}
/*常用*/
.cl{ clear:both; overflow:hidden; }
.fl{ float: left;}
.fr{ float:right;}
.ml10{ margin-left:10px;}
.ml20{ margin-left:20px;}
.ml30{ margin-left:30px;}
.mr10{ margin-right:10px;}
.mr20{ margin-right:20px;}
.mr30{ margin-right:30px;}
.mt5{ margin-top:5px;}
.mt10{ margin-top:10px;}
.mb5{ margin-bottom:5px;}
.mb10{ margin-bottom:10px;}
h2{ font-size:18px; color:#15bccf;}
h3{ font-size:14px; color:#e8770d;}
h4{ font-size:14px; color:#3b3b3b;}
a.b_grey{ background: #F5F5F5;}
a.c_orange{color:#e8770d;}
a:hover.c_orange{color: #F30;}
a.c_lorange{color:#ff9900;}
a:hover.c_lorange{color:#fff;}
a.c_blue{ color:#15bccf;}
a.c_dblue{ color:#09658c;}
a:hover.c_dblue{ color:#15bccf;}
a.c_white{ color:#fff;}
a.c_dorange{ color:#fd6e2a;}
a.c_dark{color: #3e4040;}
a:hover.c_dark{color: #3ca5c6;}
a.b_blue{background: #64bdd9;}
a:hover.b_blue{background: #41a8c8;}
a.b_green{background:#28be6c;}
a:hover.b_green{background:#14ad5a;}
a.c_blue02{color: #3ca5c6;}
a:hover.c_blue02{color: #0781b4;}
.f14{ font-size:14px;}
.fb{ font-weight:bold;}
.f12{ font-size:12px; font-weight:normal;}
.b_grey{ background: #F5F5F5;}
.c_orange{color:#e8770d;}
.c_lorange{ color:#ff9900;}
.c_purple{color: #6883b6;}
.c_blue{ color:#15bccf;}
.c_dblue{ color:#09658c;}
.b_blue{background:#64bdd9;}
.b_green{background:#28be6c;}
.more{ font-weight:normal; color:#999; font-size:12px;}
.no_line{ border-bottom:none;}
/*框架主类容*/
#Container{ width:940px; margin:0 auto; }
/*头部导航*/
#Header{ margin:10px 0; background:#15bccf; height:40px; -moz-border-radius:5px; -webkit-border-radius:5px; border-radius:5px; }
.logo{ margin:5px 10px; }
#TopNav{}
#TopNav ul li{ margin-top:8px;}
.topnav_a a{ font-size:14px; font-weight:bold; color:#fff; margin-right:10px;}
.topnav_a a:hover{color: #a1ebff;}
#TopUser{}
#TopUser ul li{ margin-top:8px;}
.topuser_a a{ font-size:14px; font-weight:bold; color:#fff; margin-right:10px;}
.topuser_a a:hover{color: #a1ebff;}
#TopUser02{ }
#TopUser02 li{ float: left;}
#TopUser02 li a{ margin-right:10px;color: #FFF;text-align: center;}
#TopUser02 li a:hover{color: #a1ebff;}
#TopUser02 div{ position: absolute;visibility: hidden;background:#fff;border: 1px solid #15bccf;}
#TopUser02 div a{position: relative;display: block;white-space: nowrap;text-align: left; line-height:1.9; margin-left:5px;background: #fff;color:#15bccf; font-weight:normal;}
#TopUser02 div a:hover{ color:#e8770d; font-weight: bold;}
/*头部导航下拉*/
.topuser_nav ul{}
.topuser_nav ul li{position: relative; line-height:1.9; margin-top:0; }
.topuser_nav ul li ul{position: absolute;width:80px; /*sub menu width*/top: 25px;display: none; background:#15bccf; }
.topuser_nav ul li ul li ul{ left:80px; top:-8px; /* Parent menu width - 1*/ width:100px; overflow:hidden; white-space: nowrap; text-overflow:ellipsis;}
.topuser_nav ul li a{display: block;color:#fff;background:#15bccf; padding-left:10px; font-size:14px; font-weight: bold;margin-right:10px;}
.topuser_nav ul li a:hover{font-weight: bold;color: #a1ebff; }
.topuser_nav .subfolderstyle{ width:67px;background: url(../images/pic_headnav.png) no-repeat center right; }
/* Holly Hack for IE \*/
* html .topuser_nav ul li { float: left; height: 1%; }
* html .topuser_nav ul li a { height: 1%; }
/* End */
/*主类容*/
#Main{ background:#fff; margin-bottom:10px;}
#Content{ }
/*主类容搜索*/
#TopBar{ height:60px; margin-bottom:10px; background:#fff;}
.topbar_info02{ margin:5px 10px;width:480px; }
.topbar_info02 p{color: #7f7f7f;}
.search{ margin-top:8px; margin-left:71px;}
.search_form{margin-top:8px;margin-left:72px;}
.topbar_info{ width:350px; color:#5c5c5c; font-size:16px; margin-right:50px; line-height:1.3; padding-left:100px;}
.search_btn{ display:block; background:#15bccf; color:#fff; width:60px; height:24px; text-align:center; padding-top:3px;}
.search_btn:hover{ background: #0fa9bb;}
.search_text{ border:1px solid #15bccf; background:#fff; width:220px; height:25px; padding-left:5px; }
/*主类容左右分栏*/
#LSide{ width:240px; }
#RSide{ width:670px; margin-left:10px; background:#fff; padding:10px; margin-bottom:10px;}
/*底部*/
#Footer{ padding-top:10px; background:#fff; margin-bottom:10px;}
.copyright{ width:780px; margin:0 auto;height:30px; }
.footlogo{ width:580px; margin:0 auto;height:50px; }
/*意见反馈*/
html{ overflow-x:hidden;}
.scrollsidebar{ position:absolute;top:1px; right:1px; background:none; }
.side_content{width:154px; height:auto; overflow:hidden; float:left; }
.side_content .side_list {width:154px;overflow:hidden;}
.show_btn{ width:0; height:112px; overflow:hidden; float:left; cursor:pointer;}
.show_btn span { display:none;}
.close_btn{width:24px;height:24px;cursor:pointer;}
.side_title,.side_bottom,.close_btn,.show_btn {background:url(../images/sidebar_bg.png) no-repeat; }
.side_title {height:35px;}
.side_bottom { height:8px;}
.side_center {font-family:Verdana, Geneva, sans-serif; padding:0px 12px; font-size:12px;}
.close_btn { float:right; display:block; width:21px; height:16px; margin:9px 10px 0 0; _margin:16px 5px 0 0;}
.close_btn span { display:none;}
.side_center .custom_service p { text-align:center; padding:6px 0; margin:0; vertical-align:middle;}
.msgserver { margin:10px 0 0px 5px;}
.msgserver a { background:url(../images/sidebar_bg.png) no-repeat -119px -115px; padding-left:22px;}
.opnionText{box-shadow:none; width:122px; height:180px; border-color: #DFDFDF; background:#fff; color:#999; padding:3px; font-size:12px;overflow:auto; background-attachment:fixed;border-style:solid;}
.opnionButton{ display:block; background:#15bccf; width:130px; height:23px; margin-top:5px; text-align:center; padding-top:3px;}
.opnionButton:hover{background: #0fa9bb; }
/* blue skin as the default skin */
.side_title {background-position:-195px 0;}
.side_center {background:url(../images/blue_line.png) repeat-y center; }
.side_bottom {background-position:-195px -50px;}
.close_btn {background-position:-44px 0;}
.close_btn:hover {background-position:-66px 0;}
.show_btn {background-position:-119px 0;}
.msgserver a {color:#15bccf; }
.msgserver a:hover { text-decoration:underline; }