OSDN Git Service

Move navbar to shared partial
[sharp4k/CUTEn.git] / CutenServer / app / views / home / index.html.haml
index f51aa2f..a79e70a 100644 (file)
@@ -1,20 +1,4 @@
-.navbar
-  .navbar-inner
-    .container
-      %span.brand CUTEn
-      %ul.nav
-        %li.active
-          %a{:href => '#'} Home
-          - if user_signed_in?
-            %li= link_to I18n.t('home.profile'), :controller => :users, :action => :profile
-            %li= link_to I18n.t('home.achievement'), :controller => :achievements, :action => :index
-          - elsif teacher_signed_in?
-            %li= link_to I18n.t('home.profile'), :controller => :teachers, :action => :profile
-            %li= link_to I18n.t('home.achievement'), :controller => :achievements, :action => :index
-      - if user_signed_in?
-        = link_to I18n.t('devise.sign_out'), destroy_user_session_path, :class => 'signout-btn'
-      - elsif teacher_signed_in?
-        = link_to I18n.t('devise.sign_out'), destroy_user_session_path, :class => 'signout-btn'
+= render :partial => 'shared/navbar'
 
 - if notice
   %div#notice= notice