From 30d685ec321f81ad5b2eb70697a8ca53be04e3c6 Mon Sep 17 00:00:00 2001 From: Alberto Garcia Cabeza Date: Sat, 22 Aug 2015 18:06:27 +0200 Subject: [PATCH] Adds styles for organizations --- app/assets/stylesheets/admin.scss | 14 ++++++ app/assets/stylesheets/participacion.scss | 51 ++++++++++++++++++++ app/views/admin/organizations/index.html.erb | 37 ++++++++------ 3 files changed, 87 insertions(+), 15 deletions(-) diff --git a/app/assets/stylesheets/admin.scss b/app/assets/stylesheets/admin.scss index bf9d7dd22..8d1a2bbcb 100644 --- a/app/assets/stylesheets/admin.scss +++ b/app/assets/stylesheets/admin.scss @@ -149,6 +149,20 @@ body.admin { } } +.verified { + color: $check; +} + +.verified a { + border-bottom: 1px dotted $check; + color: $check; + font-size: rem-calc(12); +} + +.rejected { + color: #F04124; +} + .level { font-size: rem-calc(12); } diff --git a/app/assets/stylesheets/participacion.scss b/app/assets/stylesheets/participacion.scss index 29159aaba..e6aea4db2 100644 --- a/app/assets/stylesheets/participacion.scss +++ b/app/assets/stylesheets/participacion.scss @@ -13,6 +13,7 @@ // 11. Filters // 12. Official levels // 13. Pagination +// 14. Tables // // 01. Variables @@ -126,6 +127,29 @@ h1, h2, h3, h4, h5, h6 { } } +.sub-nav { + background-color: #f2f2f2; + border-radius: rem-calc(3); + padding: rem-calc(10) rem-calc(10) rem-calc(10) 0; + margin: rem-calc(12) 0; +} + +.sub-nav dt, .sub-nav dd, .sub-nav li { + + &.active { + background: #008CBA; + border-radius: rem-calc(3); + color: white; + cursor: default; + font-weight: normal; + padding: 0.16667rem 0.88889rem; + + a:hover { + color: #737373; + } + } +} + // 04. Header // - - - - - - - - - - - - - - - - - - - - - - - - - @@ -762,3 +786,30 @@ ul.pagination { color: $text-medium; } } + +// 14. Tables +// - - - - - - - - - - - - - - - - - - - - - - - - - + +table { + border-collapse: collapse; + border-spacing: 0; + width: 100%; + + tr { + + td { + line-height: $line-height; + padding: rem-calc(12) rem-calc(6); + } + + &:nth-child(odd) { + background: #F0F2F6; + } + } + + .button { + margin: 0; + } +} + + diff --git a/app/views/admin/organizations/index.html.erb b/app/views/admin/organizations/index.html.erb index 425bee1f7..9097da44c 100644 --- a/app/views/admin/organizations/index.html.erb +++ b/app/views/admin/organizations/index.html.erb @@ -1,17 +1,17 @@

<%= t('admin.organizations.index.title') %>

-

- <%= t('admin.organizations.index.filter') %>: +

<%= page_entries_info @organizations %>

@@ -22,22 +22,29 @@ <%= organization.email %> <%= organization.phone_number %> <% if organization.verified? %> - <%= t('admin.organizations.index.verified') %> - <% end %> - <% if can? :verify, organization %> - <%= link_to t('admin.organizations.index.verify'), - verify_admin_organization_path(organization, request.query_parameters), - method: :put - %> + + + <%= t('admin.organizations.index.verified') %> <% end %> <% if organization.rejected? %> - <%= t('admin.organizations.index.rejected') %> + + + <%= t('admin.organizations.index.rejected') %> + + <% end %> + <% if can? :verify, organization %> + + <%= link_to t('admin.organizations.index.verify'), + verify_admin_organization_path(organization, request.query_parameters), + method: :put, class: "button radius tiny success" + %> + <% end %> <% if can? :reject, organization %> <%= link_to t('admin.organizations.index.reject'), reject_admin_organization_path(organization, request.query_parameters), - method: :put + method: :put, class: "button radius tiny alert" %> <% end %>