From fb01f45890da1883d622b4550af2bf997c029764 Mon Sep 17 00:00:00 2001 From: gitlabhq Date: Wed, 26 Oct 2011 07:34:02 +0300 Subject: [PATCH] issue search styleup --- app/assets/stylesheets/projects.css.scss | 17 ++++++++++ app/views/issues/index.html.haml | 43 ++++++++++++------------ config/database.yml | 19 ++++++----- 3 files changed, 49 insertions(+), 30 deletions(-) diff --git a/app/assets/stylesheets/projects.css.scss b/app/assets/stylesheets/projects.css.scss index 3e7633a6..2e97bdde 100644 --- a/app/assets/stylesheets/projects.css.scss +++ b/app/assets/stylesheets/projects.css.scss @@ -681,3 +681,20 @@ tbody tr:nth-child(2n) td, tbody tr.even td { } } } + +.top_panel_issues{ + #issue_search_form { + margin:5px 0; + input { + border:1px solid #D3D3D3; + padding: 3px; + height: 20px; + width: 300px; + + &:focus { + border-color:#c2e1ef; + } + } + } +} + diff --git a/app/views/issues/index.html.haml b/app/views/issues/index.html.haml index 7e4694ef..73d446be 100644 --- a/app/views/issues/index.html.haml +++ b/app/views/issues/index.html.haml @@ -1,25 +1,26 @@ %div - - if can? current_user, :write_issue, @project - .left - = form_tag search_project_issues_path(@project), :method => :get, :remote => true do - = hidden_field_tag :project_id, @project.id, { :id => 'project_id' } - = search_field_tag :issue_search, nil, { :placeholder => 'Search', :class => 'issue_search' } - = link_to 'New Issue', new_project_issue_path(@project), :remote => true, :class => "lbutton vm" - - .right - = form_tag project_issues_path(@project), :method => :get do - .span-2 - = radio_button_tag :f, 0, (params[:f] || "0") == "0", :onclick => "this.form.submit()", :id => "open_issues", :class => "status" - = label_tag "open_issues","Open" - .span-2 - = radio_button_tag :f, 2, params[:f] == "2", :onclick => "this.form.submit()", :id => "closed_issues", :class => "status" - = label_tag "closed_issues","Closed" - .span-2 - = radio_button_tag :f, 3, params[:f] == "3", :onclick => "this.form.submit()", :id => "my_issues", :class => "status" - = label_tag "my_issues","To Me" - .span-2 - = radio_button_tag :f, 1, params[:f] == "1", :onclick => "this.form.submit()", :id => "all_issues", :class => "status" - = label_tag "all_issues","All" + .top_panel_issues + - if can? current_user, :write_issue, @project + %div{:class => "left", :style => "margin-right: 10px;" } + = link_to 'New Issue', new_project_issue_path(@project), :remote => true, :class => "lbutton vm" + = form_tag search_project_issues_path(@project), :method => :get, :remote => true, :class => :left, :id => "issue_search_form" do + = hidden_field_tag :project_id, @project.id, { :id => 'project_id' } + = search_field_tag :issue_search, nil, { :placeholder => 'Search', :class => 'issue_search' } + + .right + = form_tag project_issues_path(@project), :method => :get do + .span-2 + = radio_button_tag :f, 0, (params[:f] || "0") == "0", :onclick => "this.form.submit()", :id => "open_issues", :class => "status" + = label_tag "open_issues","Open" + .span-2 + = radio_button_tag :f, 2, params[:f] == "2", :onclick => "this.form.submit()", :id => "closed_issues", :class => "status" + = label_tag "closed_issues","Closed" + .span-2 + = radio_button_tag :f, 3, params[:f] == "3", :onclick => "this.form.submit()", :id => "my_issues", :class => "status" + = label_tag "my_issues","To Me" + .span-2 + = radio_button_tag :f, 1, params[:f] == "1", :onclick => "this.form.submit()", :id => "all_issues", :class => "status" + = label_tag "all_issues","All" #issues-table-holder= render "issues" %br diff --git a/config/database.yml b/config/database.yml index 59e1f12c..51a4dd45 100644 --- a/config/database.yml +++ b/config/database.yml @@ -4,9 +4,8 @@ # Ensure the SQLite 3 gem is defined in your Gemfile # gem 'sqlite3' development: - adapter: mysql2 - database: gitlab_development - username: root + adapter: sqlite3 + database: db/development.sqlite3 pool: 5 timeout: 5000 @@ -14,11 +13,13 @@ development: # re-generated from your development database when you run "rake". # Do not set this db to the same as development or production. test: - adapter: mysql2 - database: gitlab_development - username: root + adapter: sqlite3 + database: db/test.sqlite3 + pool: 5 + timeout: 5000 production: - adatper: mysql2 - database: gitlab_test - username: root + adapter: sqlite3 + database: db/production.sqlite3 + pool: 5 + timeout: 5000