Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
final-hamlized up through admin/taxonomies
- Loading branch information
1 parent
8e6400e
commit 9ed01de
Showing
20 changed files
with
96 additions
and
106 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,4 +5,4 @@ | |
%p | ||
= f.label :description, t("description") | ||
%br/ | ||
= f.text_field :description | ||
= f.text_field :description |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,6 @@ | ||
= render :partial => 'admin/shared/configuration_menu' | ||
%h1= t("editing_tax_category") | ||
= error_messages_for :tax_category | ||
- form_for(:tax_category, :url => object_url, :html => { :method => :put }) do |f| | ||
= render :partial => "form", :locals => { :f => f } | ||
%p.form-buttons | ||
= button t("update") | ||
- form_for(:tax_category, :url => object_url, :html => {:method => :put}) do |f| | ||
= render :partial => "form", :locals => {:f => f} | ||
%p.form-buttons= button t("update") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
= render :partial => 'admin/shared/configuration_menu' | ||
= render :partial => 'admin/shared/configuration_menu' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,11 @@ | ||
%table | ||
%tr | ||
%td | ||
= t("zone") | ||
\: | ||
%td #{t("zone")}: | ||
%td= f.collection_select(:zone_id, @available_zones, :id, :name) | ||
%tr | ||
%td | ||
= t("tax_category") | ||
\: | ||
%td #{t("tax_category")}: | ||
%td= f.collection_select(:tax_category_id, @available_categories,:id, :name) | ||
%tr | ||
%td | ||
= t("rate") | ||
\: | ||
%td #{t("rate")}: | ||
%td= f.text_field :amount | ||
= render "admin/shared/calculator_fields", :f => f | ||
= render "admin/shared/calculator_fields", :f => f |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
%h1= t("editing_tax_rate") | ||
= error_messages_for :tax_rate | ||
- form_for(@tax_rate, :url => object_url, :html => { :method => :put }) do |f| | ||
= render :partial => "form", :locals => { :f => f } | ||
%p | ||
= submit_tag t("update") | ||
- form_for(@tax_rate, :url => object_url, :html => {:method => :put}) do |f| | ||
= render :partial => "form", :locals => {:f => f} | ||
%p= submit_tag t("update") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
%h1= t("new_tax_rate") | ||
= error_messages_for :tax_rate | ||
- form_for(:tax_rate, :url => collection_url) do |f| | ||
= render :partial => "form", :locals => { :f => f } | ||
%p | ||
= submit_tag t("create") | ||
= render :partial => "form", :locals => {:f => f} | ||
%p= submit_tag t("create") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,10 @@ | ||
- content_for :head do | ||
= javascript_tag "var taxonomy_id = #{@taxonomy.id}; | | ||
var loading = '#{escape_javascript t('loading')}'; | | ||
var new_taxon = '#{escape_javascript t('new_taxon')}'; | | ||
var server_error = '#{escape_javascript t('server_error')}'; | | ||
var taxonomy_tree_error = '#{escape_javascript t('taxonomy_tree_error')}';" | | ||
:javascript | ||
var taxonomy_id = #{@taxonomy.id}; | ||
var loading = '#{escape_javascript t('loading')}'; | ||
var new_taxon = '#{escape_javascript t('new_taxon')}'; | ||
var server_error = '#{escape_javascript t('server_error')}'; | ||
var taxonomy_tree_error = '#{escape_javascript t('taxonomy_tree_error')}'; | ||
= javascript_include_tag 'taxonomy' | ||
%script{:src => "/javascripts/jsTree/jquery.tree.js", :type => "text/javascript"} | ||
%script{:src => "/javascripts/jsTree/plugins/jquery.tree.contextmenu.js", :type => "text/javascript"} | ||
%script{:src => "/javascripts/jsTree/plugins/jquery.tree.contextmenu.js", :type => "text/javascript"} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
%h3 Manage Products for [#{@taxon.presentation}] | ||
= save_button('Save', 'manage-products', @taxon.id) | ||
| | ||
= reload_button('Reset', 'manage-products', 'manage_products', @taxon.id) | ||
| | ||
= cancel_button('Cancel', 'manage-products') | ||
%table.two-col | ||
%tr | ||
%td.two-col-left | ||
%h4 Current Products | ||
%h5 Click to remove | ||
%ul#add-product-target.plain | ||
- @taxon.products.each do |p| | ||
%li | ||
%span.product-action.product-action-remove{:id => "product-#{p.id}"}= p.name | ||
%td.two-col-right | ||
%h4 All Products | ||
%h5 Click to add | ||
%ul#remove-product-target.plain | ||
- Product.find(:all).each do |p| | ||
%li | ||
%span.product-action.product-action-add{:id => "product-#{p.id}"}= p.name | ||
:javascript | ||
spree.taxon.pm.onload(#{@taxon.id}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,7 @@ | ||
- if taxon.children.length != 0 | ||
%ul | ||
- taxon.children.each do |child| | ||
%li{:id => child.id, :rel => "taxon"} | ||
%a{:href => "#"}= child.name | ||
- if child.children.length > 0 | ||
= render :partial => "taxon", :locals => {:taxon => child} | ||
</ul> | ||
</haml:block> | ||
%li{:id => child.id, :rel => "taxon"} | ||
%a{:href => "#"}= child.name | ||
- if child.children.length > 0 | ||
= render :partial => "taxon", :locals => {:taxon => child} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,4 +6,4 @@ | |
- unless t.children.empty? | ||
,state : "closed" | ||
}#{"," if i < (@taxons.size - 1)} | ||
] | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,7 @@ | ||
= render :partial => 'admin/shared/configuration_menu' | ||
.toolbar | ||
%ul.actions | ||
%li | ||
= button_link_to t("new_taxonomy"), new_admin_taxonomy_url, :icon => 'add' | ||
</p> | ||
%li= button_link_to t("new_taxonomy"), new_admin_taxonomy_url, :icon => 'add' | ||
%br.clear/ | ||
%h1= t("taxonomies") | ||
#list-taxonomies | ||
= render :partial => 'list' | ||
#list-taxonomies= render :partial => 'list' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
= render :partial => 'admin/shared/configuration_menu' | ||
%h1= t("new_taxonomy") | ||
- form_for(:taxon, :url => collection_url) do |f| | ||
= render :partial => "form", :locals => { :f => f } | ||
%p.form-buttons | ||
= button t("create") | ||
= render :partial => "form", :locals => {:f => f} | ||
%p.form-buttons= button t("create") |