修改查询过滤样式

This commit is contained in:
yanxd 2013-12-13 14:31:28 +08:00
parent dcc47ae989
commit b8e95ffc67
2 changed files with 54 additions and 13 deletions

View File

@ -1,14 +1,13 @@
<div class="content-title-top">
<% flag = false %><!-- 8,23行分别调用测试代码看是否需要增加按钮隐藏掉分类查询看不懂改了flag试试就知道了 -->
<div style="">
<div>
<%= link_to l(:label_issue_new), { :controller => 'issues', :action => 'new', :copy_from => nil }, :param => :project_id, :caption => :label_issue_new,
:html => { :accesskey => Redmine::AccessKeys.key_for(:new_issue) }, :class => 'icon icon-add' %>
<%= link_to l(:label_query), '#', :class => 'icon icon-help',
:onclick => '$("#custom_query").toggle(); ' if (User.current.logged? && flag) %>
:onclick => '$("#custom_query").toggle(); ' if User.current.logged? %>
</div>
</div>
</h3>
<div class="contextual">
<% if !@query.new_record? && @query.editable_by?(User.current) %>
<%= link_to l(:button_edit), edit_query_path(@query), :class => 'icon icon-edit' %>
@ -18,11 +17,13 @@
<% html_title(@query.new_record? ? l(:label_issue_plural) : @query.name) %>
<%= form_tag({ :controller => 'issues', :action => 'index', :project_id => @project }, :method => :get, :id => 'query_form') do %>
<%= form_tag({ :controller => 'issues', :action => 'index', :project_id => @project }, :method => :get, :id => 'query_form', :class => 'query_form') do %>
<%= hidden_field_tag 'set_filter', '1' %>
<div id="custom_query" style="display: <%= !flag ? 'block' : 'none' %>;">
<div id="custom_query" class="custom_query" style="display: <%= !params[:utf8].blank? ? 'block' : 'none' %>;">
<span>---<%= l :label_query_new %>---</span>
<div id="query_form_content" class="hide-when-print">
<fieldset id="filters" style="width:650px;" class="collapsible <%= @query.new_record? ? "" : "collapsed" %>">
<fieldset id="filters" class="collapsible <%= @query.new_record? ? "" : "collapsed" %>">
<legend onclick="toggleFieldset(this);">
<%= l(:label_issue_query_condition) %>
</legend>
@ -30,7 +31,7 @@
<%= render :partial => 'queries/filters', :locals => {:query => @query} %>
</div>
</fieldset>
<fieldset class="collapsible collapsed" style="width:650px;">
<fieldset class="collapsible collapsed" >
<legend onclick="toggleFieldset(this);">
<%= l(:label_options) %>
</legend>
@ -51,15 +52,16 @@
</table>
</div>
</fieldset>
</div>
<div class="buttons hide-when-print">
<%= link_to_function l(:label_issue_query), 'submit_query_form("query_form")', :class => 'icon icon-checked' %>
<%= link_to l(:label_issue_cancel_query), { :set_filter => 1, :project_id => @project }, :class => 'icon icon-reload' %>
</div>
</div>
</div>
<% end %>
<%= error_messages_for 'query' %>
<% if @query.valid? %>
<% if @issues.empty? %>
<p class="nodata">

View File

@ -1,4 +1,8 @@
/*add by nyan*/
/* TODO: base/common/page 准备封装一些基本样式组合调用 参考YUI
*******************************************************************************/
/* 按钮
*******************************************************************************/
input[class='whiteButton'], .whiteButton {
-moz-box-shadow:inset 0px 1px 0px 0px #ffffff;
@ -136,7 +140,8 @@ input[class='nyan-clean-gray']:active, .nyan-clean-gray:active {
line-height: 1.4em
}
/* 项目左侧siderbar下面工具集的样式
*******************************************************************************/
.tools a:link{
color: #116699;
text-decoration:none;
@ -182,7 +187,8 @@ input[class='nyan-clean-gray']:active, .nyan-clean-gray:active {
.tools li:last-child{
border: none;
}
/* 贴吧 forum memo
*******************************************************************************/
/** {
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
@ -258,4 +264,37 @@ table.content-text-list tbody tr td.locked, div.memo-section .locked{
background: url(../images/locked.png) no-repeat 0 1px;
padding-left: 20px;
margin-left: 5px;
}
}
/* 问题列表
*******************************************************************************/
.query_form {
}
.content-title-top {
padding-bottom: 10px;
}
.custom_query {
max-width : 95%;
margin : 3px auto;
border-bottom : solid 1px #;
-o-box-shadow :inset 0px 1px 1px 0px #FAFAFA;
-moz-box-shadow :inset 0px 1px 1px 0px #FAFAFA;
-webkit-box-shadow:inset 0px 1px 1px 0px #FAFAFA;
box-shadow :inset 0px 1px 1px 0px #FAFAFA;
}
.custom_query>span {
display : block;
max-width : 100%;
line-height : 1.8em;
font-size : 14px;
text-align : center;
border-radius : 3px;
background-color: #DBEBEE;
}
.custom_query > .hide-when-print {
max-width : 97%;
padding : 3px 6px;
margin : 0 auto;
background-color: #F7F7F7;
border-bottom-left-radius : 10px;
border-bottom-right-radius: 10px;
}