diff options
Diffstat (limited to 'app')
-rw-r--r-- | app/controllers/page_controller.rb | 2 | ||||
-rw-r--r-- | app/views/layouts/_navbar.html.haml | 27 | ||||
-rw-r--r-- | app/views/layouts/application.html.haml | 2 | ||||
-rw-r--r-- | app/views/phone_books/_index_core.html.haml | 7 | ||||
-rw-r--r-- | app/views/sessions/new.html.haml | 16 |
5 files changed, 32 insertions, 22 deletions
diff --git a/app/controllers/page_controller.rb b/app/controllers/page_controller.rb index ed48e3c..10ecf2c 100644 --- a/app/controllers/page_controller.rb +++ b/app/controllers/page_controller.rb @@ -7,6 +7,8 @@ class PageController < ApplicationController def index if current_user redirect_to [current_user.current_tenant, current_user] + else + redirect_to log_in_path end end diff --git a/app/views/layouts/_navbar.html.haml b/app/views/layouts/_navbar.html.haml index 8e09859..a7f47cf 100644 --- a/app/views/layouts/_navbar.html.haml +++ b/app/views/layouts/_navbar.html.haml @@ -1,13 +1,9 @@ .navbar.navbar-inverse.navbar-fixed-top .navbar-inner .container - %a.brand{:href => (current_user.nil? ? '/' : tenant_path(current_user.current_tenant))} - Gemeinschaft 5 - - %a.btn.btn-navbar{"data-target" => ".nav-collapse", "data-toggle" => "collapse"} - %span.icon-bar - %span.icon-bar - %span.icon-bar + %span.hidden-phone + %a.brand{:href => (current_user.nil? ? '/' : tenant_path(current_user.current_tenant))} + Gemeinschaft 5 .nav-collapse.collapse %ul.nav @@ -29,13 +25,14 @@ - if current_user %ul.nav.pull-right %li.display - - if current_user.image? - = image_tag(current_user.image_url(:mini).to_s, :class => 'img-rounded') - - else - - if current_user.male? - = image_tag 'icons/user-male-16x.png', :class => 'img-rounded' + %span.hidden-phone + - if current_user.image? + = image_tag(current_user.image_url(:mini).to_s, :class => 'img-rounded') - else - = image_tag 'icons/user-female-16x.png', :class => 'img-rounded' + - if current_user.male? + = image_tag 'icons/user-male-16x.png', :class => 'img-rounded' + - else + = image_tag 'icons/user-female-16x.png', :class => 'img-rounded' - if current_page?(tenant_user_path(current_user.current_tenant, current_user)) %li.active @@ -51,3 +48,7 @@ %a.navbar-link{:href => log_out_path} %i.icon-off.icon-white + - if GuiFunction.display?('search_field_in_top_navigation_bar', current_user) + = form_tag search_path, :method => :post, :class => 'navbar-search pull-right' do + %input.text{:placeholder => 'Suchen ...', :name => 'q', :class => 'search-query span2'} + diff --git a/app/views/layouts/application.html.haml b/app/views/layouts/application.html.haml index 33a730f..eab6096 100644 --- a/app/views/layouts/application.html.haml +++ b/app/views/layouts/application.html.haml @@ -3,7 +3,7 @@ %head %meta{:charset => "utf-8"}/ %title - = content_for?(:title) ? yield(:title) : "Gemeinschaft 5" + = content_for?(:title) ? yield(:title) : "Gemeinschaft 5.1" %meta{:name => 'viewport', :content => "width=device-width, initial-scale=1.0"} - if content_for?(:meta_description) %meta{:description => yield(:meta_description)}/ diff --git a/app/views/phone_books/_index_core.html.haml b/app/views/phone_books/_index_core.html.haml index 09ce3a3..290a12e 100644 --- a/app/views/phone_books/_index_core.html.haml +++ b/app/views/phone_books/_index_core.html.haml @@ -5,7 +5,9 @@ %th %span.visible-desktop = t('phone_books.index.description') - %th= t('phone_books.index.count') + %th + %span.visible-desktop + = t('phone_books.index.count') %tbody - for phone_book in phone_books @@ -16,6 +18,7 @@ %span.visible-desktop = phone_book.description %td - = number_with_delimiter( phone_book.phone_book_entries.count ) + %span.visible-desktop + = number_with_delimiter( phone_book.phone_book_entries.count ) =render :partial => 'shared/index_view_edit_destroy_part', :locals => {:parent => phone_book.phone_bookable, :child => phone_book}
\ No newline at end of file diff --git a/app/views/sessions/new.html.haml b/app/views/sessions/new.html.haml index 75dd3de..0c5c96d 100644 --- a/app/views/sessions/new.html.haml +++ b/app/views/sessions/new.html.haml @@ -1,8 +1,12 @@ - content_for :title, t("sessions.new.page_title") -= simple_form_for :sessions, :url => sessions_path do |t| - = t.input :login_data, :label => t('sessions.form.email'), :autofocus => true - = t.input :password, :label => t('sessions.form.password'), :required => false - = t.input :reset_password, :label => t('sessions.form.reset_password'), :as => :boolean - .form-actions - = t.button :submit, :value => 'Login' +.row + .span12 + %h1=t("sessions.new.page_title") + + = simple_form_for :sessions, :url => sessions_path do |t| + = t.input :login_data, :label => t('sessions.form.email'), :autofocus => true + = t.input :password, :label => t('sessions.form.password'), :required => false + = t.input :reset_password, :label => t('sessions.form.reset_password'), :as => :boolean + .form-actions + = t.button :submit, :value => 'Login' |