spree_core 0.70.0.rc2 → 0.70.0
Sign up to get free protection for your applications and to get access to all the features.
- data/LICENSE +1 -1
- data/app/assets/javascripts/admin/taxonomy.js +1 -1
- data/app/controllers/admin/tax_rates_controller.rb +2 -2
- data/app/helpers/admin/base_helper.rb +1 -1
- data/app/helpers/spree/base_helper.rb +1 -1
- data/app/mailers/order_mailer.rb +5 -5
- data/app/mailers/shipment_mailer.rb +3 -3
- data/app/mailers/test_mailer.rb +1 -1
- data/app/models/calculator.rb +7 -9
- data/app/models/calculator/flat_percent_item_total.rb +0 -5
- data/app/models/calculator/flat_rate.rb +0 -5
- data/app/models/calculator/flexi_rate.rb +0 -5
- data/app/models/calculator/per_item.rb +0 -5
- data/app/models/calculator/price_bucket.rb +0 -6
- data/app/models/calculator/sales_tax.rb +1 -6
- data/app/models/calculator/vat.rb +6 -11
- data/app/models/creditcard.rb +12 -10
- data/app/models/order.rb +1 -1
- data/app/models/payment.rb +1 -1
- data/app/models/payment_method.rb +1 -7
- data/app/views/admin/adjustments/_adjustments_table.html.erb +3 -3
- data/app/views/admin/adjustments/_form.html.erb +4 -4
- data/app/views/admin/adjustments/edit.html.erb +7 -7
- data/app/views/admin/adjustments/index.html.erb +2 -2
- data/app/views/admin/adjustments/new.html.erb +6 -6
- data/app/views/admin/configurations/index.html.erb +29 -29
- data/app/views/admin/general_settings/edit.html.erb +5 -5
- data/app/views/admin/general_settings/show.html.erb +4 -5
- data/app/views/admin/images/_form.html.erb +2 -2
- data/app/views/admin/images/edit.html.erb +8 -8
- data/app/views/admin/images/index.html.erb +11 -11
- data/app/views/admin/images/new.html.erb +1 -1
- data/app/views/admin/inventory_settings/edit.html.erb +7 -7
- data/app/views/admin/inventory_settings/show.html.erb +4 -4
- data/app/views/admin/inventory_units/adjust.html.erb +11 -11
- data/app/views/admin/mail_methods/_form.html.erb +23 -26
- data/app/views/admin/mail_methods/edit.html.erb +4 -4
- data/app/views/admin/mail_methods/index.html.erb +6 -6
- data/app/views/admin/mail_methods/new.html.erb +4 -4
- data/app/views/admin/option_types/_available.html.erb +9 -9
- data/app/views/admin/option_types/_form.html.erb +2 -2
- data/app/views/admin/option_types/_option_value_fields.html.erb +3 -3
- data/app/views/admin/option_types/_selected.html.erb +4 -4
- data/app/views/admin/option_types/available.js.erb +1 -1
- data/app/views/admin/option_types/edit.html.erb +10 -10
- data/app/views/admin/option_types/index.html.erb +7 -7
- data/app/views/admin/option_types/new.html.erb +4 -4
- data/app/views/admin/option_types/selected.html.erb +1 -1
- data/app/views/admin/orders/_add_product.html.erb +6 -6
- data/app/views/admin/orders/_form.html.erb +15 -15
- data/app/views/admin/orders/_line_item.html.erb +4 -4
- data/app/views/admin/orders/_user_form.html.erb +11 -11
- data/app/views/admin/orders/edit.html.erb +8 -8
- data/app/views/admin/orders/history.html.erb +8 -8
- data/app/views/admin/orders/index.html.erb +28 -29
- data/app/views/admin/orders/new.html.erb +5 -5
- data/app/views/admin/orders/show.html.erb +7 -7
- data/app/views/admin/orders/user.html.erb +6 -6
- data/app/views/admin/payment_methods/_form.html.erb +15 -15
- data/app/views/admin/payment_methods/edit.html.erb +5 -5
- data/app/views/admin/payment_methods/index.html.erb +9 -10
- data/app/views/admin/payment_methods/new.html.erb +4 -4
- data/app/views/admin/payments/_bill_address_form.html.erb +1 -1
- data/app/views/admin/payments/_form.html.erb +5 -5
- data/app/views/admin/payments/_list.html.erb +5 -5
- data/app/views/admin/payments/_transaction_list.html.erb +6 -6
- data/app/views/admin/payments/credit.html.erb +5 -5
- data/app/views/admin/payments/index.html.erb +8 -8
- data/app/views/admin/payments/new.html.erb +6 -6
- data/app/views/admin/payments/show.html.erb +2 -2
- data/app/views/admin/payments/source_forms/_gateway.html.erb +8 -8
- data/app/views/admin/payments/source_views/_gateway.html.erb +7 -7
- data/app/views/admin/product_groups/_preview.html.erb +2 -2
- data/app/views/admin/product_groups/_product_scope.html.erb +3 -3
- data/app/views/admin/product_groups/edit.html.erb +9 -9
- data/app/views/admin/product_groups/index.html.erb +8 -8
- data/app/views/admin/product_groups/new.html.erb +3 -3
- data/app/views/admin/product_groups/show.html.erb +1 -1
- data/app/views/admin/product_groups/update.js.erb +3 -3
- data/app/views/admin/product_properties/_product_property_fields.html.erb +3 -3
- data/app/views/admin/product_properties/index.html.erb +15 -15
- data/app/views/admin/product_scopes/create.js.erb +3 -3
- data/app/views/admin/product_scopes/destroy.js.erb +3 -3
- data/app/views/admin/products/_form.html.erb +25 -25
- data/app/views/admin/products/_option_types.html.erb +14 -14
- data/app/views/admin/products/_properties_form.erb +1 -1
- data/app/views/admin/products/edit.html.erb +3 -3
- data/app/views/admin/products/index.html.erb +12 -12
- data/app/views/admin/products/new.html.erb +14 -14
- data/app/views/admin/products/show.html.erb +1 -1
- data/app/views/admin/properties/_form.html.erb +2 -2
- data/app/views/admin/properties/edit.html.erb +3 -3
- data/app/views/admin/properties/index.html.erb +6 -6
- data/app/views/admin/properties/new.html.erb +3 -3
- data/app/views/admin/prototypes/_form.html.erb +6 -6
- data/app/views/admin/prototypes/_prototypes.html.erb +3 -4
- data/app/views/admin/prototypes/edit.html.erb +4 -4
- data/app/views/admin/prototypes/index.html.erb +6 -6
- data/app/views/admin/prototypes/new.html.erb +3 -3
- data/app/views/admin/reports/index.html.erb +3 -3
- data/app/views/admin/reports/sales_total.html.erb +7 -7
- data/app/views/admin/return_authorizations/_form.html.erb +13 -14
- data/app/views/admin/return_authorizations/edit.html.erb +10 -10
- data/app/views/admin/return_authorizations/index.html.erb +9 -9
- data/app/views/admin/return_authorizations/new.html.erb +7 -7
- data/app/views/admin/shared/_additional_field.html.erb +1 -1
- data/app/views/admin/shared/_address_form.html.erb +24 -24
- data/app/views/admin/shared/_calculator_fields.html.erb +4 -4
- data/app/views/admin/shared/_configuration_menu.html.erb +12 -12
- data/app/views/admin/shared/_destroy.js.erb +1 -1
- data/app/views/admin/shared/_edit_resource_links.html.erb +2 -2
- data/app/views/admin/shared/_group_from_products_form.html.erb +6 -6
- data/app/views/admin/shared/_head.html.erb +5 -5
- data/app/views/admin/shared/_new_adjustment_button.html.erb +2 -2
- data/app/views/admin/shared/_new_resource_links.html.erb +2 -2
- data/app/views/admin/shared/_order_tabs.html.erb +25 -25
- data/app/views/admin/shared/_product_tabs.html.erb +14 -14
- data/app/views/admin/shared/_report_criteria.html.erb +4 -4
- data/app/views/admin/shared/_show_resource_links.html.erb +3 -3
- data/app/views/admin/shared/_update_order_state.js +4 -4
- data/app/views/admin/shipments/_form.html.erb +15 -15
- data/app/views/admin/shipments/edit.html.erb +11 -11
- data/app/views/admin/shipments/index.html.erb +11 -11
- data/app/views/admin/shipments/new.html.erb +6 -6
- data/app/views/admin/shipping_categories/_form.html.erb +2 -2
- data/app/views/admin/shipping_categories/edit.html.erb +4 -4
- data/app/views/admin/shipping_categories/index.html.erb +8 -8
- data/app/views/admin/shipping_categories/new.html.erb +4 -4
- data/app/views/admin/shipping_methods/_form.html.erb +5 -5
- data/app/views/admin/shipping_methods/edit.html.erb +5 -5
- data/app/views/admin/shipping_methods/index.html.erb +9 -10
- data/app/views/admin/shipping_methods/new.html.erb +4 -4
- data/app/views/admin/states/_form.html.erb +3 -3
- data/app/views/admin/states/_state_list.html.erb +6 -8
- data/app/views/admin/states/edit.html.erb +4 -4
- data/app/views/admin/states/index.html.erb +4 -4
- data/app/views/admin/states/new.html.erb +3 -3
- data/app/views/admin/states/new.js.erb +1 -1
- data/app/views/admin/tax_categories/_form.html.erb +6 -6
- data/app/views/admin/tax_categories/edit.html.erb +4 -4
- data/app/views/admin/tax_categories/index.html.erb +8 -9
- data/app/views/admin/tax_categories/new.html.erb +4 -4
- data/app/views/admin/tax_rates/_form.html.erb +5 -5
- data/app/views/admin/tax_rates/edit.html.erb +5 -5
- data/app/views/admin/tax_rates/index.html.erb +10 -10
- data/app/views/admin/tax_rates/new.html.erb +4 -4
- data/app/views/admin/tax_settings/edit.html.erb +10 -10
- data/app/views/admin/tax_settings/show.html.erb +6 -6
- data/app/views/admin/taxonomies/_form.html.erb +1 -1
- data/app/views/admin/taxonomies/_js_head.html.erb +4 -4
- data/app/views/admin/taxonomies/_list.html.erb +4 -4
- data/app/views/admin/taxonomies/_taxon.html.erb +2 -2
- data/app/views/admin/taxonomies/edit.erb +31 -32
- data/app/views/admin/taxonomies/get_children.json.erb +7 -7
- data/app/views/admin/taxonomies/index.html.erb +4 -4
- data/app/views/admin/taxonomies/new.html.erb +5 -5
- data/app/views/admin/taxons/_form.html.erb +3 -3
- data/app/views/admin/taxons/_taxon_table.html.erb +4 -4
- data/app/views/admin/taxons/edit.html.erb +3 -3
- data/app/views/admin/taxons/remove.html.erb +1 -1
- data/app/views/admin/taxons/select.js.erb +1 -1
- data/app/views/admin/taxons/selected.html.erb +5 -5
- data/app/views/admin/trackers/_form.html.erb +10 -10
- data/app/views/admin/trackers/edit.html.erb +5 -5
- data/app/views/admin/trackers/index.html.erb +8 -8
- data/app/views/admin/trackers/new.html.erb +4 -4
- data/app/views/admin/users/_form.html.erb +6 -6
- data/app/views/admin/users/edit.html.erb +4 -4
- data/app/views/admin/users/index.html.erb +8 -8
- data/app/views/admin/users/new.html.erb +4 -4
- data/app/views/admin/users/show.html.erb +5 -5
- data/app/views/admin/variants/_form.html.erb +5 -5
- data/app/views/admin/variants/edit.html.erb +3 -3
- data/app/views/admin/variants/index.html.erb +14 -18
- data/app/views/admin/variants/new.html.erb +3 -3
- data/app/views/admin/variants/new.js.erb +1 -1
- data/app/views/admin/zones/_country_member.html.erb +1 -1
- data/app/views/admin/zones/_form.html.erb +14 -14
- data/app/views/admin/zones/_state_member.html.erb +1 -1
- data/app/views/admin/zones/edit.html.erb +5 -5
- data/app/views/admin/zones/index.html.erb +5 -5
- data/app/views/admin/zones/new.html.erb +5 -5
- data/app/views/checkout/_address.html.erb +25 -25
- data/app/views/checkout/_confirm.html.erb +1 -1
- data/app/views/checkout/_delivery.html.erb +7 -7
- data/app/views/checkout/_payment.html.erb +3 -3
- data/app/views/checkout/_summary.html.erb +2 -2
- data/app/views/checkout/edit.html.erb +3 -3
- data/app/views/checkout/payment/_gateway.html.erb +9 -9
- data/app/views/checkout/registration.html.erb +6 -6
- data/app/views/content/cvv.html.erb +6 -6
- data/app/views/home/index.html.erb +2 -2
- data/app/views/layouts/admin.html.erb +9 -11
- data/app/views/layouts/spree_application.html.erb +3 -3
- data/app/views/order_mailer/cancel_email.text.erb +2 -2
- data/app/views/orders/_form.html.erb +5 -5
- data/app/views/orders/_line_item.html.erb +3 -3
- data/app/views/orders/edit.html.erb +11 -11
- data/app/views/orders/new.html.erb +3 -3
- data/app/views/orders/show.html.erb +3 -3
- data/app/views/products/_cart_form.html.erb +8 -8
- data/app/views/products/_taxons.html.erb +1 -1
- data/app/views/products/_thumbnails.html.erb +2 -2
- data/app/views/products/index.html.erb +4 -4
- data/app/views/products/show.html.erb +1 -1
- data/app/views/shared/_filters.html.erb +2 -3
- data/app/views/shared/_google_analytics.html.erb +6 -6
- data/app/views/shared/_head.html.erb +3 -3
- data/app/views/shared/_order_details.html.erb +12 -12
- data/app/views/shared/_store_menu.html.erb +1 -1
- data/app/views/shared/_taxonomies.html.erb +1 -1
- data/app/views/shipment_mailer/shipped_email.text.erb +2 -2
- data/app/views/taxons/_taxon.html.erb +1 -1
- data/app/views/taxons/show.html.erb +4 -4
- data/app/views/test_mailer/test_email.text.erb +2 -2
- data/config/locales/en.yml +4 -2
- data/lib/environment_extension.rb +26 -0
- data/lib/generators/spree/site/site_generator.rb +8 -0
- data/lib/product_filters.rb +8 -0
- data/lib/spree/calculated_adjustments.rb +8 -8
- data/lib/spree/environment.rb +12 -0
- data/lib/spree/environment/calculators.rb +10 -0
- data/lib/spree_core.rb +1 -1
- data/lib/spree_core/railtie.rb +36 -46
- data/lib/spree_core/ssl_requirement.rb +1 -1
- data/lib/spree_core/version.rb +1 -1
- metadata +13 -18
- data/config/initializers/sprockets_precompile_patch.rb +0 -16
- data/lib/subclass_registration.rb +0 -21
@@ -1,10 +1,10 @@
|
|
1
1
|
<%= render :partial => 'admin/shared/configuration_menu' %>
|
2
2
|
|
3
|
-
<h1><%= t(
|
3
|
+
<h1><%= t(:editing_state) %></h1>
|
4
4
|
|
5
5
|
<%= render 'shared/error_messages', :target => @state %>
|
6
6
|
|
7
|
-
<%= form_for
|
8
|
-
<%= render :partial =>
|
9
|
-
<%= render :partial =>
|
7
|
+
<%= form_for [:admin, @country, @state] do |f| %>
|
8
|
+
<%= render :partial => 'form', :locals => { :f => f } %>
|
9
|
+
<%= render :partial => 'admin/shared/edit_resource_links' %>
|
10
10
|
<% end %>
|
@@ -1,16 +1,16 @@
|
|
1
1
|
<%= render :partial => 'admin/shared/configuration_menu' %>
|
2
2
|
|
3
|
-
<h1><%= t(
|
3
|
+
<h1><%= t(:states) %></h1>
|
4
4
|
|
5
5
|
<p data-hook="country">
|
6
|
-
|
6
|
+
<%= label_tag :country, t(:country) %>
|
7
7
|
<select id="country" class='observe_field' data-base-url="<%=admin_states_path(:format => :js)%>?country_id=" data-update="#state-list">
|
8
8
|
<%= options_from_collection_for_select(@countries, :id, :name, @country.id) %>
|
9
9
|
</select>
|
10
10
|
</p>
|
11
11
|
|
12
|
-
<%= image_tag
|
12
|
+
<%= image_tag 'spinner.gif', :plugin => 'spree', :style => 'display:none;', :id => 'busy_indicator' %>
|
13
13
|
|
14
14
|
<div id="state-list" data-hook>
|
15
|
-
<%=render :partial => 'state_list'%>
|
15
|
+
<%= render :partial => 'state_list'%>
|
16
16
|
</div>
|
@@ -2,7 +2,7 @@
|
|
2
2
|
|
3
3
|
<%= render 'shared/error_messages', :target => @state %>
|
4
4
|
|
5
|
-
<%= form_for
|
6
|
-
<%= render :partial =>
|
7
|
-
<%= render :partial =>
|
5
|
+
<%= form_for [:admin, @country, @state] do |f| %>
|
6
|
+
<%= render :partial => 'form', :locals => { :f => f } %>
|
7
|
+
<%= render :partial => 'admin/shared/new_resource_links' %>
|
8
8
|
<% end %>
|
@@ -1,2 +1,2 @@
|
|
1
|
-
$("#new_state").html(
|
1
|
+
$("#new_state").html("<%= escape_javascript(render :template => 'admin/states/new.html.erb') %>");
|
2
2
|
$("#new_state_link").parent().hide();
|
@@ -1,12 +1,12 @@
|
|
1
1
|
<%= f.field_container :name do %>
|
2
|
-
<%= f.label :name, t(
|
3
|
-
<%=f.text_field :name %>
|
2
|
+
<%= f.label :name, t(:name) %><br />
|
3
|
+
<%= f.text_field :name %>
|
4
4
|
<% end %>
|
5
5
|
<%= f.field_container :description do %>
|
6
|
-
<%= f.label :description, t(
|
7
|
-
<%=f.text_field :description %>
|
6
|
+
<%= f.label :description, t(:description) %><br />
|
7
|
+
<%= f.text_field :description %>
|
8
8
|
<% end %>
|
9
9
|
<%= f.field_container :is_default do %>
|
10
|
-
<%= f.label :is_default, t(
|
11
|
-
<%=f.check_box :is_default %>
|
10
|
+
<%= f.label :is_default, t(:default) %><br />
|
11
|
+
<%= f.check_box :is_default %>
|
12
12
|
<% end %>
|
@@ -1,10 +1,10 @@
|
|
1
1
|
<%= render :partial => 'admin/shared/configuration_menu' %>
|
2
2
|
|
3
|
-
<h1><%=t(
|
3
|
+
<h1><%= t(:editing_tax_category) %></h1>
|
4
4
|
|
5
5
|
<%= render 'shared/error_messages', :target => @tax_category %>
|
6
6
|
|
7
|
-
<%= form_for
|
8
|
-
<%= render :partial =>
|
9
|
-
<%= render :partial =>
|
7
|
+
<%= form_for [:admin, @tax_category] do |f| %>
|
8
|
+
<%= render :partial => 'form', :locals => { :f => f } %>
|
9
|
+
<%= render :partial => 'admin/shared/edit_resource_links' %>
|
10
10
|
<% end %>
|
@@ -3,22 +3,21 @@
|
|
3
3
|
<div class="toolbar" data-hook="toolbar">
|
4
4
|
<ul class="actions">
|
5
5
|
<li>
|
6
|
-
<p><%= button_link_to t(
|
7
|
-
:id => 'admin_new_tax_categories_link' %>
|
6
|
+
<p><%= button_link_to t(:new_tax_category), new_object_url, :icon => 'add', :id => 'admin_new_tax_categories_link' %>
|
8
7
|
</p>
|
9
8
|
</li>
|
10
9
|
</ul>
|
11
|
-
<br class="clear"
|
10
|
+
<br class="clear" />
|
12
11
|
</div>
|
13
12
|
|
14
13
|
|
15
|
-
<h1><%=t(
|
14
|
+
<h1><%= t(:listing_tax_categories) %></h1>
|
16
15
|
<table class="index" id='listing_tax_categories' data-hook>
|
17
16
|
<thead>
|
18
17
|
<tr data-hook="tax_header">
|
19
|
-
<th><%= t(
|
20
|
-
<th><%= t(
|
21
|
-
<th><%= t(
|
18
|
+
<th><%= t(:name) %></th>
|
19
|
+
<th><%= t(:description) %></th>
|
20
|
+
<th><%= t(:default) %></th>
|
22
21
|
<th></th>
|
23
22
|
</tr>
|
24
23
|
</thead>
|
@@ -32,8 +31,8 @@
|
|
32
31
|
<td><%= tax_category.description %></td>
|
33
32
|
<td><%= tax_category.is_default.to_s.titleize %></td>
|
34
33
|
<td class="actions">
|
35
|
-
<%=link_to_edit tax_category, :class => 'edit' %>
|
36
|
-
<%=link_to_delete tax_category %>
|
34
|
+
<%= link_to_edit tax_category, :class => 'edit' %>
|
35
|
+
<%= link_to_delete tax_category %>
|
37
36
|
</tr>
|
38
37
|
<% end %>
|
39
38
|
<% if @tax_categories.empty? %>
|
@@ -1,10 +1,10 @@
|
|
1
1
|
<%= render :partial => 'admin/shared/configuration_menu' %>
|
2
2
|
|
3
|
-
<h1><%=t(
|
3
|
+
<h1><%= t(:new_tax_category) %></h1>
|
4
4
|
|
5
5
|
<%= render 'shared/error_messages', :target => @tax_category %>
|
6
6
|
|
7
|
-
<%= form_for
|
8
|
-
<%= render :partial =>
|
9
|
-
<%= render :partial =>
|
7
|
+
<%= form_for [:admin, @tax_category] do |f| %>
|
8
|
+
<%= render :partial => 'form', :locals => { :f => f } %>
|
9
|
+
<%= render :partial => 'admin/shared/new_resource_links' %>
|
10
10
|
<% end %>
|
@@ -1,16 +1,16 @@
|
|
1
1
|
<table data-hook="tax_rates">
|
2
2
|
<tr data-hook="zone">
|
3
|
-
<td><%=t(
|
3
|
+
<td><%= t(:zone) %>:</td>
|
4
4
|
<td><%= f.collection_select(:zone_id, @available_zones, :id, :name) %></td>
|
5
5
|
</tr>
|
6
6
|
<tr data-hook="category">
|
7
|
-
<td><%=t(
|
7
|
+
<td><%= t(:tax_category) %>:</td>
|
8
8
|
<td><%= f.collection_select(:tax_category_id, @available_categories,:id, :name) %></td>
|
9
9
|
</tr>
|
10
10
|
<tr="rate">
|
11
|
-
<td><%=t(
|
11
|
+
<td><%= t(:rate) %>:</td>
|
12
12
|
<td><%= f.text_field :amount %></td>
|
13
|
-
</tr>
|
13
|
+
</tr>
|
14
14
|
</table>
|
15
15
|
|
16
|
-
<%= render
|
16
|
+
<%= render 'admin/shared/calculator_fields', :f => f %>
|
@@ -1,6 +1,6 @@
|
|
1
|
-
<h1><%= t(
|
2
|
-
<%= render
|
3
|
-
<%= form_for
|
4
|
-
<%= render :partial =>
|
5
|
-
<%= render :partial =>
|
1
|
+
<h1><%= t(:editing_tax_rate) %></h1>
|
2
|
+
<%= render 'shared/error_messages', :target => @tax_rate %>
|
3
|
+
<%= form_for [:admin, @tax_rate] do |f| %>
|
4
|
+
<%= render :partial => 'form', :locals => { :f => f } %>
|
5
|
+
<%= render :partial => 'admin/shared/edit_resource_links' %>
|
6
6
|
<% end %>
|
@@ -1,20 +1,20 @@
|
|
1
1
|
<div class="toolbar" data-hook="toolbar">
|
2
2
|
<ul class="actions">
|
3
3
|
<li>
|
4
|
-
<%= button_link_to t(
|
4
|
+
<%= button_link_to t(:new_tax_rate), new_object_url, :icon => 'add' %>
|
5
5
|
</li>
|
6
6
|
</ul>
|
7
|
-
<br class="clear"
|
7
|
+
<br class="clear" />
|
8
8
|
</div>
|
9
|
-
<h1><%=t(
|
9
|
+
<h1><%= t(:tax_rates) %></h1>
|
10
10
|
<table class="index">
|
11
11
|
<thead>
|
12
12
|
<tr data-hook="rate_header">
|
13
|
-
<th><%=t(
|
14
|
-
<th><%=t(
|
15
|
-
<th><%=t(
|
16
|
-
<th><%=t(
|
17
|
-
<th><%=t(
|
13
|
+
<th><%= t(:zone) %></th>
|
14
|
+
<th><%= t(:category) %></th>
|
15
|
+
<th><%= t(:amount) %></th>
|
16
|
+
<th><%= t(:calculator) %></th>
|
17
|
+
<th><%= t(:action) %></th>
|
18
18
|
</tr>
|
19
19
|
</thead>
|
20
20
|
<tbody>
|
@@ -25,8 +25,8 @@
|
|
25
25
|
<td><%=tax_rate.amount %></td>
|
26
26
|
<td><%=tax_rate.calculator.to_s %></td>
|
27
27
|
<td>
|
28
|
-
|
29
|
-
|
28
|
+
<%= link_to_edit tax_rate %>
|
29
|
+
<%= link_to_delete tax_rate %>
|
30
30
|
</td>
|
31
31
|
</tr>
|
32
32
|
<% end %>
|
@@ -1,8 +1,8 @@
|
|
1
|
-
<h1><%= t(
|
1
|
+
<h1><%= t(:new_tax_rate) %></h1>
|
2
2
|
|
3
3
|
<%= render 'shared/error_messages', :target => @tax_rate %>
|
4
4
|
|
5
|
-
<%= form_for
|
6
|
-
<%= render :partial =>
|
7
|
-
<%= render :partial =>
|
5
|
+
<%= form_for [:admin, @tax_rate] do |f| %>
|
6
|
+
<%= render :partial => 'form', :locals => { :f => f } %>
|
7
|
+
<%= render :partial => 'admin/shared/new_resource_links' %>
|
8
8
|
<% end %>
|
@@ -1,23 +1,23 @@
|
|
1
1
|
<%= render :partial => 'admin/shared/configuration_menu' %>
|
2
2
|
|
3
|
-
<h1><%= t(
|
3
|
+
<h1><%= t(:tax_settings) %></h1>
|
4
4
|
|
5
|
-
<%= form_tag
|
5
|
+
<%= form_tag admin_tax_settings_path, :method => :put do %>
|
6
6
|
|
7
7
|
<p data-hook="show_vat">
|
8
|
-
|
9
|
-
|
10
|
-
|
8
|
+
<%= label_tag nil, t(:show_price_inc_vat) %>
|
9
|
+
<%= hidden_field_tag 'preferences[show_price_inc_vat]', '0' %>
|
10
|
+
<%= check_box_tag 'preferences[show_price_inc_vat]', '1', Spree::Config[:show_price_inc_vat] %>
|
11
11
|
</p>
|
12
12
|
|
13
13
|
<p data-hook="shipment_vat">
|
14
|
-
|
15
|
-
|
16
|
-
|
14
|
+
<%= label_tag nil, t(:shipment_inc_vat) %>
|
15
|
+
<%= hidden_field_tag 'preferences[shipment_inc_vat]', '0' %>
|
16
|
+
<%= check_box_tag 'preferences[shipment_inc_vat]', '1', Spree::Config[:shipment_inc_vat] %>
|
17
17
|
</p>
|
18
18
|
|
19
19
|
<p class="form-buttons" data-hook="buttons">
|
20
|
-
<%= button t(
|
21
|
-
<%= t(
|
20
|
+
<%= button t(:update) %>
|
21
|
+
<%= t(:or) %> <%= link_to t(:cancel), admin_tax_settings_url %>
|
22
22
|
</p>
|
23
23
|
<% end %>
|
@@ -1,18 +1,18 @@
|
|
1
1
|
<%= render :partial => 'admin/shared/configuration_menu' %>
|
2
2
|
|
3
|
-
<h1><%= t(
|
3
|
+
<h1><%= t(:tax_settings) %></h1>
|
4
4
|
|
5
5
|
<table id='listing_tax_settings' data-hook>
|
6
6
|
<tr>
|
7
|
-
<th scope="row"><%= t(
|
8
|
-
<td><%=
|
7
|
+
<th scope="row"><%= t(:show_price_inc_vat) %>:</th>
|
8
|
+
<td><%= Spree::Config[:show_price_inc_vat] %></td>
|
9
9
|
</tr>
|
10
10
|
<tr>
|
11
|
-
<th scope="row"><%= t(
|
12
|
-
<td><%=
|
11
|
+
<th scope="row"><%= t(:shipment_inc_vat) %>:</th>
|
12
|
+
<td><%= Spree::Config[:shipment_inc_vat] %></td>
|
13
13
|
</tr>
|
14
14
|
</table>
|
15
15
|
|
16
16
|
<p data-hook="buttons">
|
17
|
-
<%= link_to_with_icon 'edit', t(
|
17
|
+
<%= link_to_with_icon 'edit', t(:edit), edit_admin_tax_settings_path %>
|
18
18
|
</p>
|
@@ -1,6 +1,6 @@
|
|
1
1
|
<div data-hook="admin_inside_taxonomy_form">
|
2
2
|
<%= f.field_container :name do %>
|
3
|
-
<%= f.label :name, t(
|
3
|
+
<%= f.label :name, t(:name) %> <span class="required">*</span><br />
|
4
4
|
<%= error_message_on :taxonomy, :name, :class => 'fullwidth title' %>
|
5
5
|
<%= text_field :taxonomy, :name %>
|
6
6
|
<% end %>
|
@@ -1,8 +1,8 @@
|
|
1
1
|
<% content_for :head do %>
|
2
2
|
<%= javascript_tag "var taxonomy_id = #{@taxonomy.id};
|
3
|
-
var loading = '#{escape_javascript t(
|
4
|
-
var new_taxon = '#{escape_javascript t(
|
5
|
-
var server_error = '#{escape_javascript t(
|
6
|
-
var taxonomy_tree_error = '#{escape_javascript t(
|
3
|
+
var loading = '#{escape_javascript t(:loading)}';
|
4
|
+
var new_taxon = '#{escape_javascript t(:new_taxon)}';
|
5
|
+
var server_error = '#{escape_javascript t(:server_error)}';
|
6
|
+
var taxonomy_tree_error = '#{escape_javascript t(:taxonomy_tree_error)}';"
|
7
7
|
%>
|
8
8
|
<% end %>
|
@@ -1,12 +1,12 @@
|
|
1
1
|
<table class="index" id='listing_taxonomies' data-hook>
|
2
2
|
<tr data-hook="taxonomies_header">
|
3
|
-
<th><%= t(
|
3
|
+
<th><%= t(:name) %></th>
|
4
4
|
<th></th>
|
5
5
|
</tr>
|
6
|
-
<%
|
6
|
+
<% @taxonomies.each do |taxonomy| %>
|
7
7
|
<tr id="<%= dom_id taxonomy %>" data-hook="taxonomies_row">
|
8
|
-
|
9
|
-
|
8
|
+
<td>
|
9
|
+
<%= taxonomy.name %>
|
10
10
|
</td>
|
11
11
|
<td class="actions">
|
12
12
|
<%= link_to_edit taxonomy.id, :class => 'edit' %>
|
@@ -2,9 +2,9 @@
|
|
2
2
|
<ul>
|
3
3
|
<% taxon.children.each do |child| %>
|
4
4
|
<li id="<%= child.id %>" rel="taxon">
|
5
|
-
<a style="background-image: url(<%=child.icon.url%>)" href="#"><%= child.name %></a>
|
5
|
+
<a style="background-image: url(<%= child.icon.url %>);" href="#"><%= child.name %></a>
|
6
6
|
<% if child.children.length > 0 %>
|
7
|
-
<%= render :partial =>
|
7
|
+
<%= render :partial => 'taxon', :locals => {:taxon => child} %>
|
8
8
|
<% end %>
|
9
9
|
</li>
|
10
10
|
<% end %>
|
@@ -1,49 +1,48 @@
|
|
1
1
|
<%= render :partial => 'admin/shared/configuration_menu' %>
|
2
2
|
|
3
|
-
<%= render :partial =>
|
3
|
+
<%= render :partial => 'js_head' %>
|
4
4
|
|
5
|
-
<h1><%= t(
|
5
|
+
<h1><%= t(:taxonomy_edit) %></h1>
|
6
6
|
|
7
7
|
<p id="ajax_error" class="errorExplanation" style="display:none;"></p>
|
8
8
|
|
9
|
-
<%= form_for
|
9
|
+
<%= form_for [:admin, @taxonomy] do |f| %>
|
10
10
|
<%= render :partial => 'form', :locals => {:f => f} %>
|
11
|
-
|
12
|
-
|
11
|
+
<div>
|
12
|
+
<%= label_tag nil, t(:tree) %><br />
|
13
13
|
<div id="taxonomy_tree" class="tree"></div>
|
14
|
-
|
15
|
-
|
16
|
-
|
14
|
+
</div>
|
15
|
+
<p id="progress" style="display:none;">
|
16
|
+
<%= image_tag 'spinner.gif', :title => 'Spinner', :style => "vertical-align:bottom;" %> <%= t(:updating) %>..
|
17
17
|
</p>
|
18
|
-
<p><br/><small><%= t(
|
18
|
+
<p><br /><small><%= t(:taxonomy_tree_instruction) %></small></p>
|
19
19
|
|
20
|
-
|
21
|
-
|
22
|
-
|
20
|
+
<p class="form-buttons">
|
21
|
+
<%= button t(:update) %> <%= t(:or) %> <%= link_to t(:cancel), admin_taxonomies_path %>
|
22
|
+
</p>
|
23
23
|
<% end %>
|
24
24
|
|
25
25
|
|
26
26
|
<% content_for :head do %>
|
27
|
-
|
27
|
+
<%= javascript_tag do -%>
|
28
28
|
var initial = [
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
29
|
+
{ "attr" :
|
30
|
+
{ "id" : "<%= @taxonomy.root.id %>", "rel" : "root" },
|
31
|
+
"data" : "<%= @taxonomy.root.name %>",
|
32
|
+
"state" : "open",
|
33
|
+
"children" : [
|
34
|
+
<% @taxonomy.root.children.each_with_index do |taxon,i| %>
|
35
|
+
{
|
36
|
+
"attr" :
|
37
|
+
{ "id" : "<%= taxon.id %>"},
|
38
|
+
"data" : "<%= taxon.name %>"
|
39
|
+
<% unless taxon.children.empty? %>
|
40
|
+
,"state" : "closed"
|
41
|
+
<% end %>
|
42
|
+
}<%= ',' if i < (@taxonomy.root.children.size - 1) %>
|
43
|
+
<% end %>
|
44
|
+
]
|
45
|
+
}
|
46
46
|
];
|
47
|
-
|
48
|
-
</script>
|
47
|
+
<% end -%>
|
49
48
|
<% end %>
|
@@ -1,9 +1,9 @@
|
|
1
1
|
[<% @taxons.each_with_index do |t,i| %>
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
2
|
+
{ "attr" :
|
3
|
+
{ "id" : "<%= t.id %>" },
|
4
|
+
"data" : "<%= t.name %>"
|
5
|
+
<% unless t.children.empty? %>
|
6
|
+
,"state" : "closed"
|
7
|
+
<% end %>
|
8
|
+
}<%= "," if i < (@taxons.size - 1) %>
|
9
9
|
<% end %>]
|