Better cmtool integration

This commit is contained in:
2015-02-25 12:54:07 +01:00
parent 6a47ecb0eb
commit fd9afb9d53
15 changed files with 110 additions and 72 deletions
+34 -37
View File
@@ -12,42 +12,39 @@ html lang="en"
/[if lt IE 9]
= javascript_include_tag "http://html5shim.googlecode.com/svn/trunk/html5.js"
= stylesheet_link_tag "admin/application", :media => "all"
link href="images/apple-touch-icon-144x144.png" rel="apple-touch-icon-precomposed" sizes="144x144"
link href="images/apple-touch-icon-114x114.png" rel="apple-touch-icon-precomposed" sizes="114x114"
link href="images/apple-touch-icon-72x72.png" rel="apple-touch-icon-precomposed" sizes="72x72"
link href="images/apple-touch-icon.png" rel="apple-touch-icon-precomposed"
link href="images/favicon.ico" rel="shortcut icon"
body
nav.top-bar
ul.title-area
li.name: h4= link_to application_title, admin_root_path
section.top-bar-section
ul.left
li= link_to User.model_name.human_plural, admin_users_path
li= link_to "User Feedback", admin_user_feedbacks_path
li.divider
ul.left
li.has-dropdown.not-click
a href="#" = Supplier.model_name.human_plural
ul.dropdown
li= link_to Supplier.model_name.human_plural, admin_suppliers_path
li= link_to Section.model_name.human_plural, admin_sections_path
li= link_to Table.model_name.human_plural, admin_tables_path
li= link_to Product.model_name.human_plural, admin_products_path
li= link_to List.model_name.human_plural, admin_lists_path
li= link_to Order.model_name.human_plural, admin_orders_path
li= link_to ProductCategory.model_name.human_plural, admin_product_categories_path
li.divider
- if administrator_signed_in?
ul.right
li.divider
li.has-dropdown.not-click
a href="#" = current_administrator.email
ul.dropdown
li.log-out= link_to t('helpers.links.logout'), destroy_administrator_session_path
.container
- if defined?(Cmtool)
= render 'cmtool/application/menu'
- else
nav.top-bar
ul.title-area
li.name: h4= link_to application_title, admin_root_path
section.top-bar-section
ul.left
li= link_to User.model_name.human_plural, admin_users_path
li= link_to "User Feedback", admin_user_feedbacks_path
li.divider
ul.left
li.has-dropdown.not-click
a href="#" = Supplier.model_name.human_plural
ul.dropdown
li= link_to Supplier.model_name.human_plural, admin_suppliers_path
li= link_to Section.model_name.human_plural, admin_sections_path
li= link_to Table.model_name.human_plural, admin_tables_path
li= link_to Product.model_name.human_plural, admin_products_path
li= link_to List.model_name.human_plural, admin_lists_path
li= link_to Order.model_name.human_plural, admin_orders_path
li= link_to ProductCategory.model_name.human_plural, admin_product_categories_path
li.divider
- if administrator_signed_in?
ul.right
li.divider
li.has-dropdown.not-click
a href="#" = current_administrator.email
ul.dropdown
li.log-out= link_to t('helpers.links.logout'), destroy_administrator_session_path
.container
.content
- if flash[:alert].present?
.alert-box.alert
@@ -58,10 +55,10 @@ html lang="en"
a.close data-dismiss="alert" ×
div= flash[:notice]
.row
.large-9.columns
.small-12.large-9.columns
= yield
.large-3.columns
.well.sidebar-nav
.show-for-large-up.large-3.columns
.panel
h3= application_title
hr
ul.side-nav
+1 -9
View File
@@ -27,15 +27,7 @@ html lang="en"
.container
.content-top
.main-inner
.general-alerts
- if flash[:alert].present?
.flash-box.alert
div= flash[:alert]
a.close data-dismiss="alert" ×
- if flash[:notice].present?
.flash-box.notice
div= flash[:notice]
a.close data-dismiss="alert" ×
= render 'theme1/alerts'
= yield :page_title
= yield
= render 'theme1/footer'
+2 -9
View File
@@ -1,5 +1,5 @@
doctype html
html lang="en"
html lang=I18n.locale
head
title= site_page_title
= render 'meta'
@@ -22,14 +22,7 @@ html lang="en"
#main-wrap
.container
.main-inner
- if flash[:alert].present?
.flash-box.alert
div= flash[:alert]
a.close data-dismiss="alert" ×
- if flash[:notice].present?
.flash-box.notice
div= flash[:notice]
a.close data-dismiss="alert" ×
= render 'theme1/alerts'
- if @page && @page.title.present?
h1.page-title= @page.title
= yield