Commit 6dfbd3f771d48cfefe0dcf7a41f44e833a1e7878

Authored by Dmitriy Zaporozhets
1 parent d0a56e22

Style admin->projects filter

Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Showing 1 changed file with 26 additions and 28 deletions   Show diff stats
app/views/admin/projects/index.html.haml
1 1 .row
2 2 .col-md-4
3 3 .admin-filter
4   - = form_tag admin_projects_path, method: :get, class: 'form-inline' do
  4 + = form_tag admin_projects_path, method: :get, class: '' do
5 5 .form-group
6   - = label_tag :name, 'Name:', class: 'control-label'
7   - .col-sm-10
8   - = text_field_tag :name, params[:name], class: "span2"
  6 + = label_tag :name, 'Name:'
  7 + = text_field_tag :name, params[:name], class: "form-control"
9 8  
10 9 .form-group
11   - = label_tag :owner_id, 'Owner:', class: 'control-label'
12   - .col-sm-10
  10 + = label_tag :owner_id, 'Owner:'
  11 + %div
13 12 = users_select_tag :owner_id, selected: params[:owner_id], class: 'input-large input-clamp'
14   - .form-group.visibility-levels
15   - = label_tag :visibility_level, 'Visibility Levels', class: 'control-label'
16   - - Project.visibility_levels.each do |label, level|
17   - .col-sm-10
18   - = check_box_tag 'visibility_levels[]', level, params[:visibility_levels].present? && params[:visibility_levels].include?(level.to_s)
19   - %span.descr
20   - = visibility_level_icon(level)
21   - = label
22   - .form-group
23   - = label_tag :with_push, 'Not empty', class: 'control-label'
24   - .col-sm-10
25   - = check_box_tag :with_push, 1, params[:with_push]
26   - &nbsp;
27   - %span.light Projects with push events
28   - .form-group
29   - = label_tag :abandoned, 'Abandoned', class: 'control-label'
30   - .col-sm-10
31   - = check_box_tag :abandoned, 1, params[:abandoned]
32   - &nbsp;
33   - %span.light No activity over 6 month
34   -
35   -
  13 + .checkbox
  14 + = label_tag :with_push, 'Not empty'
  15 + = check_box_tag :with_push, 1, params[:with_push]
  16 + &nbsp;
  17 + %span.light Projects with push events
  18 + .checkbox
  19 + = label_tag :abandoned, 'Abandoned'
  20 + = check_box_tag :abandoned, 1, params[:abandoned]
  21 + &nbsp;
  22 + %span.light No activity over 6 month
36 23  
  24 + %fieldset
  25 + %strong Visibility level:
  26 + .visibility-levels
  27 + - Project.visibility_levels.each do |label, level|
  28 + .checkbox
  29 + %label
  30 + = check_box_tag 'visibility_levels[]', level, params[:visibility_levels].present? && params[:visibility_levels].include?(level.to_s)
  31 + %span.descr
  32 + = visibility_level_icon(level)
  33 + = label
37 34 .form-actions
38 35 = submit_tag "Search", class: "btn submit btn-primary"
39 36 = link_to "Reset", admin_projects_path, class: "btn"
  37 +
40 38 .col-md-8
41 39 .ui-box
42 40 .title
... ...