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,19 +1,19 @@
|
|
1
|
-
<%= render :partial => 'admin/shared/order_tabs', :locals => {:current =>
|
1
|
+
<%= render :partial => 'admin/shared/order_tabs', :locals => {:current => 'Order Details'} %>
|
2
2
|
<%= csrf_meta_tags %>
|
3
3
|
|
4
4
|
<div data-hook="admin_order_new_header">
|
5
|
-
<h2><%= t(
|
5
|
+
<h2><%= t(:new_order)%></h2>
|
6
6
|
<%= render 'shared/error_messages', :target => @order %>
|
7
7
|
</div>
|
8
8
|
|
9
|
-
<%= render :partial =>
|
9
|
+
<%= render :partial => 'add_product' %>
|
10
10
|
|
11
11
|
<div data-hook="admin_order_new_form">
|
12
12
|
<div id="order-form-wrapper">
|
13
|
-
<%= render :partial =>
|
13
|
+
<%= render :partial => 'form' %>
|
14
14
|
</div>
|
15
15
|
</div>
|
16
16
|
|
17
17
|
<% content_for :head do %>
|
18
|
-
<%= javascript_tag
|
18
|
+
<%= javascript_tag 'var expand_variants = true;' %>
|
19
19
|
<% end %>
|
@@ -1,20 +1,20 @@
|
|
1
|
-
<div class=
|
2
|
-
<%= button_link_to t(
|
3
|
-
<%= button_link_to t(
|
1
|
+
<div class="toolbar order-links" data-hook="admin_order_show_buttons">
|
2
|
+
<%= button_link_to t(:cancel), fire_admin_order_url(@order.number, {:e => "cancel"}), :icon => 'delete', :confirm => t(:are_you_sure) if @order.can_cancel? %>
|
3
|
+
<%= button_link_to t(:edit), edit_admin_order_url(@order.number), :icon => 'edit' %>
|
4
4
|
</div>
|
5
5
|
|
6
|
-
<%= render :partial => 'admin/shared/order_tabs', :locals => {:current =>
|
6
|
+
<%= render :partial => 'admin/shared/order_tabs', :locals => {:current => 'Order Details'} %>
|
7
7
|
|
8
8
|
<div data-hook="admin_order_show_addresses">
|
9
9
|
<% if @order.bill_address %>
|
10
|
-
<div class=
|
11
|
-
<h4><%= t(
|
10
|
+
<div class="adr">
|
11
|
+
<h4><%= t(:bill_address) %></h4>
|
12
12
|
<%= render :partial => 'admin/shared/address', :locals => {:address => @order.bill_address} %>
|
13
13
|
</div>
|
14
14
|
<% end %>
|
15
15
|
<% if @order.ship_address %>
|
16
16
|
<div class='adr'>
|
17
|
-
<h4><%= t(
|
17
|
+
<h4><%= t(:ship_address) %></h4>
|
18
18
|
<%= render :partial => 'admin/shared/address', :locals => {:address => @order.ship_address} %>
|
19
19
|
</div>
|
20
20
|
<% end %>
|
@@ -1,19 +1,19 @@
|
|
1
|
-
<%= render :partial => 'admin/shared/order_tabs', :locals => {:current =>
|
1
|
+
<%= render :partial => 'admin/shared/order_tabs', :locals => {:current => 'Customer Details'} %>
|
2
2
|
<%= csrf_meta_tags %>
|
3
3
|
|
4
4
|
<% if @order.cart? %>
|
5
5
|
<div id="add-line-item" data-hook>
|
6
6
|
<fieldset>
|
7
|
-
<legend><%= t(
|
8
|
-
<%= label_tag :customer_search, t(
|
7
|
+
<legend><%= t(:customer_search) %></legend>
|
8
|
+
<%= label_tag :customer_search, t(:enter_at_least_five_letters) %>
|
9
9
|
<%= text_field_tag :customer_search, nil, :class => 'fullwidth title' %>
|
10
10
|
</fieldset>
|
11
11
|
</div>
|
12
12
|
<% end %>
|
13
13
|
|
14
|
-
<%= render
|
14
|
+
<%= render 'shared/error_messages', :target => @order %>
|
15
15
|
|
16
|
-
<%= form_for
|
16
|
+
<%= form_for @order, :url => admin_order_url(@order), :html => { :method => :put} do |f| %>
|
17
17
|
<%= f.hidden_field :number %>
|
18
|
-
<%= render :partial =>
|
18
|
+
<%= render :partial => 'user_form', :locals => {:f => f} %>
|
19
19
|
<% end %>
|
@@ -1,50 +1,50 @@
|
|
1
1
|
<table data-hook="payment_method">
|
2
2
|
<tr data-hook="name">
|
3
|
-
<td
|
4
|
-
<td><%= text_field :payment_method, :name, {
|
3
|
+
<td><%= label_tag nil, t(:name) %></td>
|
4
|
+
<td><%= text_field :payment_method, :name, {'style' => 'width:200px;'} %></td>
|
5
5
|
</tr>
|
6
6
|
<tr data-hook="description">
|
7
|
-
<td
|
7
|
+
<td><%= label_tag nil, t(:description) %></td>
|
8
8
|
<td><%= text_area :payment_method, :description, {:cols => 60, :rows => 4} %></td>
|
9
9
|
</tr>
|
10
10
|
<tr data-hook="environment">
|
11
|
-
<td
|
11
|
+
<td><%= label_tag nil, t(:environment) %></td>
|
12
12
|
<td>
|
13
|
-
<%= collection_select(:payment_method, :environment, Configuration.configurations.keys, :to_s, :titleize, {}, {:id =>
|
13
|
+
<%= collection_select(:payment_method, :environment, Configuration.configurations.keys, :to_s, :titleize, {}, {:id => 'gtwy-env'}) %>
|
14
14
|
</td>
|
15
15
|
</tr>
|
16
16
|
<tr data-hook="display">
|
17
|
-
<td
|
17
|
+
<td><%= label_tag nil, t(:display) %></td>
|
18
18
|
<td>
|
19
19
|
<%= select(:payment_method, :display_on, PaymentMethod::DISPLAY.collect {|display| [t(display), display == :both ? nil : display.to_s]}) %>
|
20
20
|
</td>
|
21
21
|
</tr>
|
22
22
|
<tr data-hook="active">
|
23
|
-
<td
|
23
|
+
<td><%= label_tag nil, t(:active) %></td>
|
24
24
|
<td>
|
25
25
|
<label class="sub">
|
26
|
-
<%= radio_button
|
27
|
-
<%= t(
|
26
|
+
<%= radio_button :payment_method, :active, true %>
|
27
|
+
<%= t(:yes) %>
|
28
28
|
</label>
|
29
29
|
<label class="sub">
|
30
|
-
<%= radio_button
|
31
|
-
<%= t(
|
30
|
+
<%= radio_button :payment_method, :active, false %>
|
31
|
+
<%= t(:no) %>
|
32
32
|
</label>
|
33
33
|
</td>
|
34
34
|
</tr>
|
35
35
|
</table>
|
36
36
|
|
37
|
-
<h2><%= t(
|
37
|
+
<h2><%= t(:settings) %></h2>
|
38
38
|
|
39
39
|
<div id="preference-settings" data-hook>
|
40
|
-
<%= f.label
|
41
|
-
<%= collection_select(:payment_method, :type, @providers, :to_s, :name, {}, {:id =>
|
40
|
+
<%= f.label :type, t(:provider) %>
|
41
|
+
<%= collection_select(:payment_method, :type, @providers, :to_s, :name, {}, {:id => 'gtwy-type'}) %>
|
42
42
|
|
43
43
|
<% unless @object.new_record? %>
|
44
44
|
<%= preference_fields(@object, f) %>
|
45
45
|
|
46
46
|
<% if @object.respond_to?(:preferences) %>
|
47
|
-
<div id="gateway-settings-warning" style="color:#FF0000"><%= t(
|
47
|
+
<div id="gateway-settings-warning" style="color:#FF0000;"><%= t(:provider_settings_warning) %></div>
|
48
48
|
<% end %>
|
49
49
|
<% end %>
|
50
50
|
</div>
|
@@ -1,10 +1,10 @@
|
|
1
1
|
<%= render :partial => 'admin/shared/configuration_menu' %>
|
2
2
|
|
3
|
-
<h1><%= t(
|
4
|
-
<%= render
|
5
|
-
<%= form_for
|
6
|
-
<%= render :partial =>
|
3
|
+
<h1><%= t(:editing_payment_method) %></h1>
|
4
|
+
<%= render 'shared/error_messages', :target => @payment_method %>
|
5
|
+
<%= form_for @payment_method, :url => admin_payment_method_path(@payment_method), :html => { :method => :put } do |f| %>
|
6
|
+
<%= render :partial => 'form', :locals => { :f => f } %>
|
7
7
|
<p data-hook="buttons">
|
8
|
-
<%=submit_tag t(
|
8
|
+
<%= submit_tag t(:update) %>
|
9
9
|
</p>
|
10
10
|
<% end %>
|
@@ -3,22 +3,21 @@
|
|
3
3
|
<div class="toolbar" data-hook="toolbar">
|
4
4
|
<ul class="actions">
|
5
5
|
<li>
|
6
|
-
<%= button_link_to t(
|
7
|
-
:id => 'admin_new_payment_methods_link' %>
|
6
|
+
<%= button_link_to t(:new_payment_method), new_object_url, :icon => 'add', :id => 'admin_new_payment_methods_link' %>
|
8
7
|
</li>
|
9
8
|
</ul>
|
10
|
-
<br class=
|
9
|
+
<br class="clear" />
|
11
10
|
</div>
|
12
11
|
|
13
|
-
<h1><%= t(
|
12
|
+
<h1><%= t(:payment_methods) %></h1>
|
14
13
|
|
15
14
|
<table class="index" id='listing_payment_methods'>
|
16
15
|
<tr data-hook="admin_payment_methods_index_headers">
|
17
|
-
<th><%= t(
|
18
|
-
<th><%= t(
|
19
|
-
<th><%= t(
|
20
|
-
<th><%= t(
|
21
|
-
<th><%= t(
|
16
|
+
<th><%= t(:name) %></th>
|
17
|
+
<th><%= t(:provider) %></th>
|
18
|
+
<th><%= t(:environment) %></th>
|
19
|
+
<th><%= t(:display) %></th>
|
20
|
+
<th><%= t(:active) %></th>
|
22
21
|
<th data-hook="admin_payment_methods_index_header_actions"></th>
|
23
22
|
</tr>
|
24
23
|
<tbody>
|
@@ -27,7 +26,7 @@
|
|
27
26
|
<td width="120px"><%= method.name %></td>
|
28
27
|
<td width="140px"><%= method.type %></td>
|
29
28
|
<td width="100px"><%= method.environment.to_s.titleize %></td>
|
30
|
-
<td width="60px"><%= method.display_on.blank? ? t(
|
29
|
+
<td width="60px"><%= method.display_on.blank? ? t(:both) : t(method.display_on) %></td>
|
31
30
|
<td width="60px"><%= method.active ? t(:yes) : t(:no) %></td>
|
32
31
|
<td width="140px" data-hook="admin_payment_methods_index_row_actions">
|
33
32
|
<%= link_to_edit method, :class => 'edit' %>
|
@@ -1,11 +1,11 @@
|
|
1
1
|
<%= render :partial => 'admin/shared/configuration_menu' %>
|
2
2
|
|
3
|
-
<h1><%= t(
|
3
|
+
<h1><%= t(:new_payment_method) %></h1>
|
4
4
|
<%= render 'shared/error_messages', :target => @payment_method %>
|
5
5
|
|
6
|
-
<%= form_for
|
7
|
-
<%= render :partial =>
|
6
|
+
<%= form_for @payment_method, :url => collection_url do |f| %>
|
7
|
+
<%= render :partial => 'form', :locals => { :f => f } %>
|
8
8
|
<p data-hook="buttons">
|
9
|
-
<%= submit_tag t(
|
9
|
+
<%= submit_tag t(:create) %>
|
10
10
|
</p>
|
11
11
|
<% end %>
|
@@ -2,7 +2,7 @@
|
|
2
2
|
<% order_form.fields_for :checkout do |checkout_form| %>
|
3
3
|
|
4
4
|
<% checkout_form.fields_for :bill_address do |ba_form| %>
|
5
|
-
<%= render :partial =>
|
5
|
+
<%= render :partial => 'admin/shared/address_form', :locals => {:f => ba_form, :name => t(:billing_address)} %>
|
6
6
|
<% end %>
|
7
7
|
|
8
8
|
<% end %>
|
@@ -1,15 +1,15 @@
|
|
1
1
|
<p>
|
2
|
-
<%= f.label :amount, t(:amount) %>
|
3
|
-
<%= f.text_field :amount, :size=> 8, :value => @order.outstanding_balance %>
|
4
|
-
</p>
|
2
|
+
<%= f.label :amount, t(:amount) %>
|
3
|
+
<%= f.text_field :amount, :size => 8, :value => @order.outstanding_balance %>
|
4
|
+
</p>
|
5
5
|
|
6
6
|
<% @payment_methods.each do |method| %>
|
7
7
|
|
8
8
|
<label data-hook="payment_method">
|
9
|
-
<%= radio_button_tag
|
9
|
+
<%= radio_button_tag 'payment[payment_method_id]', method.id, method == @payment_method %>
|
10
10
|
<%= t(method.name, :scope => :payment_methods, :default => method.name) %>
|
11
11
|
</label>
|
12
12
|
|
13
13
|
<%= render "admin/payments/source_forms/#{method.method_type}", :payment_method => method %>
|
14
14
|
|
15
|
-
<% end %>
|
15
|
+
<% end %>
|
@@ -1,15 +1,15 @@
|
|
1
1
|
<table class="index">
|
2
2
|
<tr data-hook="payments_header">
|
3
3
|
<th><%= "#{t('spree.date')}/#{t('spree.time')}" %></th>
|
4
|
-
<th><%= t(
|
5
|
-
<th><%= t(
|
6
|
-
<th><%= t(
|
7
|
-
<th><%= t(
|
4
|
+
<th><%= t(:amount) %></th>
|
5
|
+
<th><%= t(:payment_method) %></th>
|
6
|
+
<th><%= t(:payment_state) %></th>
|
7
|
+
<th><%= t(:payment_actions) %></th>
|
8
8
|
</tr>
|
9
9
|
<% payments.each do |payment| %>
|
10
10
|
<tr data-hook="payments_row">
|
11
11
|
<td><%= payment.created_at.to_s(:date_time24) %></td>
|
12
|
-
<td><%= number_to_currency
|
12
|
+
<td><%= number_to_currency payment.amount %></td>
|
13
13
|
<td><%= link_to payment_method_name(payment), admin_order_payment_path(@order, payment) %></td>
|
14
14
|
<td><%= t(payment.state, :scope => :payment_states, :default => payment.state.capitalize) %></td>
|
15
15
|
<td>
|
@@ -1,15 +1,15 @@
|
|
1
1
|
<fieldset>
|
2
2
|
|
3
|
-
<legend><%= t(
|
3
|
+
<legend><%= t(:transactions) %></legend>
|
4
4
|
|
5
5
|
<table class="index">
|
6
6
|
<tr data-hook="transactions_header">
|
7
|
-
<th><%= t(
|
8
|
-
<th><%= 'date' %></th>
|
9
|
-
<th><%= t(
|
10
|
-
<th><%= t(
|
7
|
+
<th><%= t(:type) %></th>
|
8
|
+
<th><%= t('spree.date') %></th>
|
9
|
+
<th><%= t(:amount) %></th>
|
10
|
+
<th><%= t(:response_code) %></th>
|
11
11
|
</tr>
|
12
|
-
<%
|
12
|
+
<% txns.each do |txn| %>
|
13
13
|
<tr data-hook="transaction_row">
|
14
14
|
<td>
|
15
15
|
<%= txn.txn_type_name %>
|
@@ -1,14 +1,14 @@
|
|
1
|
-
<%= render :partial => 'admin/shared/order_tabs', :locals => {:current =>
|
1
|
+
<%= render :partial => 'admin/shared/order_tabs', :locals => {:current => 'Creditcards'} %>
|
2
2
|
|
3
3
|
<%= form_tag do %>
|
4
|
-
<h3><%= t(
|
4
|
+
<h3><%= t(:refund) %></h3>
|
5
5
|
<fieldset data-hook="credit">
|
6
6
|
<p>
|
7
|
-
|
7
|
+
<%= label_tag :amount, t(:amount) %>
|
8
8
|
<%= text_field_tag :amount, @payment.amount %>
|
9
9
|
</p>
|
10
10
|
<p class="form-buttons">
|
11
|
-
<%= button t(
|
12
|
-
</p>
|
11
|
+
<%= button t(:make_refund) %>
|
12
|
+
</p>
|
13
13
|
</fieldset>
|
14
14
|
<% end %>
|
@@ -1,22 +1,22 @@
|
|
1
1
|
<div class="toolbar" data-hook="toolbar">
|
2
|
-
<ul class=
|
2
|
+
<ul class="actions">
|
3
3
|
<% if @order.outstanding_balance? %>
|
4
|
-
<li id=
|
5
|
-
<%= button_link_to t(
|
4
|
+
<li id="new_payment_section">
|
5
|
+
<%= button_link_to t(:new_payment), new_admin_order_payment_url(@order), :icon => 'add' %>
|
6
6
|
</li>
|
7
7
|
<% end %>
|
8
8
|
</ul>
|
9
|
-
<br class=
|
9
|
+
<br class="clear" />
|
10
10
|
</div>
|
11
11
|
|
12
|
-
<%= render 'admin/shared/order_tabs', :current =>
|
12
|
+
<%= render 'admin/shared/order_tabs', :current => 'Payments' %>
|
13
13
|
|
14
14
|
<% if @order.outstanding_balance? %>
|
15
|
-
<p><%= @order.outstanding_balance < 0 ? t(
|
15
|
+
<p><%= @order.outstanding_balance < 0 ? t(:credit_owed) : t(:balance_due) %> <strong><%= number_to_currency @order.outstanding_balance %></strong></p>
|
16
16
|
<% end %>
|
17
17
|
|
18
|
-
<h2><%= t(
|
18
|
+
<h2><%= t(:payments) %></h2>
|
19
19
|
<%= render 'list', :payments => @payments %>
|
20
20
|
|
21
21
|
|
22
|
-
<%= button_link_to t(
|
22
|
+
<%= button_link_to t(:continue), admin_orders_url %>
|
@@ -1,19 +1,19 @@
|
|
1
|
-
<%= render :partial => 'admin/shared/order_tabs', :locals => {:current =>
|
1
|
+
<%= render :partial => 'admin/shared/order_tabs', :locals => {:current => 'Payments'} %>
|
2
2
|
|
3
|
-
<h2><%= t(
|
3
|
+
<h2><%= t(:new) %> <%= t("activerecord.models.#{@payment.class.to_s.underscore}.one") %></h2>
|
4
4
|
|
5
|
-
<%= render
|
5
|
+
<%= render 'shared/error_messages', :target => @payment %>
|
6
6
|
|
7
7
|
<%= form_for @payment, :url => admin_order_payments_path(@order) do |f| %>
|
8
8
|
|
9
|
-
<%= render
|
9
|
+
<%= render 'form', :f => f %>
|
10
10
|
|
11
11
|
<p class="form-buttons" data-hook="buttons">
|
12
|
-
<%= button @order.cart? ? t(
|
12
|
+
<%= button @order.cart? ? t(:continue) : t(:update) %>
|
13
13
|
</p>
|
14
14
|
|
15
15
|
<% end %>
|
16
16
|
|
17
17
|
<% content_for :head do %>
|
18
|
-
<%= javascript_include_tag '/admin/javascripts/payments/new.js' %>
|
18
|
+
<%= javascript_include_tag '/admin/javascripts/payments/new.js' %>
|
19
19
|
<% end %>
|
@@ -1,9 +1,9 @@
|
|
1
|
-
<%= render :partial => 'admin/shared/order_tabs', :locals => {:current =>
|
1
|
+
<%= render :partial => 'admin/shared/order_tabs', :locals => {:current => 'Payments'} %>
|
2
2
|
|
3
3
|
<h2><%= t("activerecord.models.#{@payment.class.to_s.underscore}.one") %></h2>
|
4
4
|
|
5
5
|
<p data-hook="amount">
|
6
|
-
|
6
|
+
<%= label_tag nil, t(:amount) %>
|
7
7
|
<%= @payment.amount %>
|
8
8
|
</p>
|
9
9
|
|
@@ -1,7 +1,7 @@
|
|
1
1
|
<fieldset>
|
2
2
|
|
3
3
|
<p class="field" data-hook="previous_cards">
|
4
|
-
<%
|
4
|
+
<% @previous_cards.each do |card| %>
|
5
5
|
<label><%= radio_button_tag :card, card.id, card == @previous_cards.first %> <%= card.display_number %><br /></label>
|
6
6
|
<% end %>
|
7
7
|
<label><%= radio_button_tag :card, 'new', @previous_cards.none? %> <%= t(:use_new_cc) %></label>
|
@@ -9,32 +9,32 @@
|
|
9
9
|
|
10
10
|
<div id="card_form" data-hook>
|
11
11
|
|
12
|
-
<%= image_tag
|
12
|
+
<%= image_tag 'creditcards/creditcard.gif', :id => 'creditcard-image' %>
|
13
13
|
<% param_prefix = "payment_source[#{payment_method.id}]" %>
|
14
14
|
|
15
15
|
<div data-hook="card_number">
|
16
|
-
|
16
|
+
<%= label_tag nil, t(:card_number) %><br />
|
17
17
|
<%= text_field_tag "#{param_prefix}[number]", '', :class => 'required', :size => 19, :maxlength => 19 %>
|
18
18
|
<span class="req">*</span>
|
19
19
|
|
20
20
|
<span id="card_type" style="display:none;">
|
21
|
-
( <span id="looks_like" ><%= t(
|
22
|
-
<span id="unrecognized"><%= t(
|
21
|
+
( <span id="looks_like" ><%= t(:card_type_is) %> <span id="type"></span></span>
|
22
|
+
<span id="unrecognized"><%= t(:unrecognized_card_type) %></span>
|
23
23
|
)
|
24
24
|
</span>
|
25
25
|
</div>
|
26
26
|
<div data-hook="card_expiration">
|
27
|
-
|
27
|
+
<%= label_tag nil, t(:expiration) %><br />
|
28
28
|
<%= select_month(Date.today, :prefix => param_prefix, :field_name => 'month', :use_month_numbers => true, :class => 'required') %>
|
29
29
|
<%= select_year(Date.today, :prefix => param_prefix, :field_name => 'year', :start_year => Date.today.year, :end_year => Date.today.year + 15, :class => 'required') %>
|
30
30
|
<span class="req">*</span>
|
31
31
|
</div>
|
32
32
|
<div data-hook="card_code">
|
33
|
-
|
33
|
+
<%= label_tag nil, t(:card_code) %><br />
|
34
34
|
<%= text_field_tag "#{param_prefix}[verification_value]", '', :class => 'required', :size => 5 %>
|
35
35
|
<span class="req">*</span>
|
36
36
|
<a href="/content/cvv" target="_blank" onclick="window.open(this.href,'cvv_info','left=20,top=20,width=500,height=500,toolbar=0,resizable=0,scrollbars=1');return false">
|
37
|
-
(<%= t(
|
37
|
+
(<%= t(:whats_this) %>)
|
38
38
|
</a>
|
39
39
|
</div>
|
40
40
|
|
@@ -1,30 +1,30 @@
|
|
1
1
|
<fieldset data-hook="creditcard">
|
2
|
-
<legend><%= t(
|
2
|
+
<legend><%= t(:creditcard) %></legend>
|
3
3
|
|
4
4
|
<table class="index">
|
5
5
|
<tr>
|
6
|
-
<th colspan="6"><%= t(
|
6
|
+
<th colspan="6"><%= t(:card_details) %></th>
|
7
7
|
</tr>
|
8
8
|
<tr>
|
9
|
-
<td
|
9
|
+
<td><%= label_tag nil, t(:card_number) %>:</td>
|
10
10
|
<td>
|
11
11
|
<%= payment.source.display_number %>
|
12
12
|
</td>
|
13
|
-
<td
|
13
|
+
<td><%= label_tag nil, t(:expiration) %>:</td>
|
14
14
|
<td>
|
15
15
|
<%= payment.source.month %>/<%= payment.source.year %>
|
16
16
|
</td>
|
17
|
-
<td
|
17
|
+
<td><%= label_tag nil, t(:card_code) %>:</td>
|
18
18
|
<td>
|
19
19
|
<%= payment.source.verification_value %>
|
20
20
|
</td>
|
21
21
|
</tr>
|
22
22
|
<tr>
|
23
|
-
<td
|
23
|
+
<td><%= label_tag nil, t(:maestro_or_solo_cards) %>:</td>
|
24
24
|
<td>
|
25
25
|
<%= payment.source.issue_number %>
|
26
26
|
</td>
|
27
|
-
<td
|
27
|
+
<td><%= label_tag nil, t(:start_date) %>:</td>
|
28
28
|
<td colspan="3">
|
29
29
|
<%= payment.source.start_month %>/<%= payment.source.start_year %>
|
30
30
|
</td>
|