solidus_backend 2.5.2 → 2.6.0.rc1
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of solidus_backend might be problematic. Click here for more details.
- checksums.yaml +4 -4
- data/Rakefile +5 -3
- data/app/assets/javascripts/spree/backend.js +1 -0
- data/app/assets/javascripts/spree/backend/admin.js +1 -0
- data/app/assets/javascripts/spree/backend/highlight_negative_numbers.js +14 -0
- data/app/assets/javascripts/spree/backend/locale_selection.js +18 -0
- data/app/assets/javascripts/spree/backend/templates/products/sortable.hbs +1 -1
- data/app/assets/javascripts/spree/backend/templates/stock_items/stock_location_stock_item.hbs +11 -2
- data/app/assets/javascripts/spree/backend/views/stock/edit_stock_item_row.js +3 -1
- data/app/assets/stylesheets/spree/backend/components/_navigation.scss +6 -2
- data/app/assets/stylesheets/spree/backend/globals/_functions.scss +1 -2
- data/app/assets/stylesheets/spree/backend/shared/_typography.scss +3 -0
- data/app/controllers/spree/admin/adjustment_reasons_controller.rb +2 -0
- data/app/controllers/spree/admin/adjustments_controller.rb +2 -0
- data/app/controllers/spree/admin/base_controller.rb +2 -0
- data/app/controllers/spree/admin/cancellations_controller.rb +2 -0
- data/app/controllers/spree/admin/customer_returns_controller.rb +2 -0
- data/app/controllers/spree/admin/dashboards_controller.rb +2 -0
- data/app/controllers/spree/admin/general_settings_controller.rb +2 -0
- data/app/controllers/spree/admin/images_controller.rb +2 -0
- data/app/controllers/spree/admin/locale_controller.rb +24 -0
- data/app/controllers/spree/admin/log_entries_controller.rb +2 -0
- data/app/controllers/spree/admin/option_types_controller.rb +2 -0
- data/app/controllers/spree/admin/option_values_controller.rb +2 -0
- data/app/controllers/spree/admin/orders/customer_details_controller.rb +2 -0
- data/app/controllers/spree/admin/orders_controller.rb +4 -2
- data/app/controllers/spree/admin/payment_methods_controller.rb +2 -0
- data/app/controllers/spree/admin/payments_controller.rb +2 -0
- data/app/controllers/spree/admin/prices_controller.rb +2 -0
- data/app/controllers/spree/admin/product_properties_controller.rb +2 -0
- data/app/controllers/spree/admin/products_controller.rb +2 -0
- data/app/controllers/spree/admin/promotion_actions_controller.rb +2 -0
- data/app/controllers/spree/admin/promotion_categories_controller.rb +2 -0
- data/app/controllers/spree/admin/promotion_code_batches_controller.rb +2 -0
- data/app/controllers/spree/admin/promotion_codes_controller.rb +2 -0
- data/app/controllers/spree/admin/promotion_rules_controller.rb +6 -0
- data/app/controllers/spree/admin/promotions_controller.rb +2 -0
- data/app/controllers/spree/admin/properties_controller.rb +2 -0
- data/app/controllers/spree/admin/refund_reasons_controller.rb +2 -0
- data/app/controllers/spree/admin/refunds_controller.rb +2 -0
- data/app/controllers/spree/admin/reimbursement_types_controller.rb +2 -0
- data/app/controllers/spree/admin/reimbursements_controller.rb +2 -0
- data/app/controllers/spree/admin/reports_controller.rb +2 -0
- data/app/controllers/spree/admin/resource_controller.rb +2 -0
- data/app/controllers/spree/admin/return_authorizations_controller.rb +2 -0
- data/app/controllers/spree/admin/return_items_controller.rb +2 -0
- data/app/controllers/spree/admin/return_reasons_controller.rb +2 -0
- data/app/controllers/spree/admin/root_controller.rb +2 -0
- data/app/controllers/spree/admin/search_controller.rb +2 -0
- data/app/controllers/spree/admin/shipping_categories_controller.rb +2 -0
- data/app/controllers/spree/admin/shipping_methods_controller.rb +2 -0
- data/app/controllers/spree/admin/stock_items_controller.rb +2 -0
- data/app/controllers/spree/admin/stock_locations_controller.rb +2 -1
- data/app/controllers/spree/admin/stock_movements_controller.rb +2 -0
- data/app/controllers/spree/admin/store_credits_controller.rb +2 -0
- data/app/controllers/spree/admin/stores_controller.rb +2 -0
- data/app/controllers/spree/admin/style_guide_controller.rb +2 -0
- data/app/controllers/spree/admin/tax_categories_controller.rb +2 -0
- data/app/controllers/spree/admin/tax_rates_controller.rb +2 -0
- data/app/controllers/spree/admin/taxonomies_controller.rb +2 -0
- data/app/controllers/spree/admin/taxons_controller.rb +2 -0
- data/app/controllers/spree/admin/users_controller.rb +4 -1
- data/app/controllers/spree/admin/variant_property_rule_values_controller.rb +2 -0
- data/app/controllers/spree/admin/variants_controller.rb +2 -0
- data/app/controllers/spree/admin/variants_including_master_controller.rb +2 -0
- data/app/controllers/spree/admin/zones_controller.rb +2 -0
- data/app/helpers/spree/admin/adjustments_helper.rb +2 -0
- data/app/helpers/spree/admin/base_helper.rb +6 -3
- data/app/helpers/spree/admin/customer_returns_helper.rb +2 -0
- data/app/helpers/spree/admin/navigation_helper.rb +11 -7
- data/app/helpers/spree/admin/orders_helper.rb +5 -3
- data/app/helpers/spree/admin/payments_helper.rb +4 -3
- data/app/helpers/spree/admin/products_helper.rb +2 -0
- data/app/helpers/spree/admin/reimbursement_type_helper.rb +2 -0
- data/app/helpers/spree/admin/stock_locations_helper.rb +2 -0
- data/app/helpers/spree/admin/stock_movements_helper.rb +2 -0
- data/app/helpers/spree/admin/store_credit_events_helper.rb +2 -0
- data/app/helpers/spree/promotion_rules_helper.rb +2 -0
- data/app/models/spree/backend_configuration.rb +2 -0
- data/app/views/spree/admin/adjustment_reasons/index.html.erb +1 -1
- data/app/views/spree/admin/adjustments/edit.html.erb +1 -1
- data/app/views/spree/admin/adjustments/index.html.erb +2 -2
- data/app/views/spree/admin/adjustments/new.html.erb +2 -2
- data/app/views/spree/admin/customer_returns/index.html.erb +1 -1
- data/app/views/spree/admin/customer_returns/new.html.erb +2 -2
- data/app/views/spree/admin/images/_image_row.html.erb +1 -1
- data/app/views/spree/admin/images/_new.html.erb +1 -1
- data/app/views/spree/admin/images/edit.html.erb +2 -2
- data/app/views/spree/admin/log_entries/index.html.erb +2 -2
- data/app/views/spree/admin/option_types/index.html.erb +1 -1
- data/app/views/spree/admin/orders/_carton_manifest.html.erb +1 -1
- data/app/views/spree/admin/orders/_shipment_manifest.html.erb +1 -1
- data/app/views/spree/admin/orders/cart.html.erb +2 -2
- data/app/views/spree/admin/orders/confirm/_payments.html.erb +1 -1
- data/app/views/spree/admin/orders/customer_details/_form.html.erb +1 -1
- data/app/views/spree/admin/orders/customer_details/show.html.erb +1 -1
- data/app/views/spree/admin/orders/edit.html.erb +1 -1
- data/app/views/spree/admin/orders/index.html.erb +2 -2
- data/app/views/spree/admin/payment_methods/edit.html.erb +1 -1
- data/app/views/spree/admin/payment_methods/index.html.erb +1 -1
- data/app/views/spree/admin/payment_methods/new.html.erb +1 -1
- data/app/views/spree/admin/payments/_list.html.erb +2 -2
- data/app/views/spree/admin/payments/credit.html.erb +1 -1
- data/app/views/spree/admin/payments/index.html.erb +1 -1
- data/app/views/spree/admin/payments/new.html.erb +1 -1
- data/app/views/spree/admin/payments/show.html.erb +2 -2
- data/app/views/spree/admin/prices/_form.html.erb +1 -1
- data/app/views/spree/admin/prices/index.html.erb +2 -2
- data/app/views/spree/admin/product_properties/index.html.erb +1 -1
- data/app/views/spree/admin/products/_form.html.erb +4 -1
- data/app/views/spree/admin/products/edit.html.erb +1 -1
- data/app/views/spree/admin/products/index.html.erb +2 -2
- data/app/views/spree/admin/promotion_categories/_form.html.erb +1 -1
- data/app/views/spree/admin/promotion_categories/index.html.erb +37 -29
- data/app/views/spree/admin/promotion_code_batches/download.csv.ruby +2 -0
- data/app/views/spree/admin/promotion_code_batches/index.html.erb +1 -1
- data/app/views/spree/admin/promotion_code_batches/new.html.erb +6 -1
- data/app/views/spree/admin/promotion_codes/index.csv.ruby +2 -0
- data/app/views/spree/admin/promotion_codes/index.html.erb +1 -1
- data/app/views/spree/admin/promotions/_actions.html.erb +2 -2
- data/app/views/spree/admin/promotions/_activations_new.html.erb +4 -0
- data/app/views/spree/admin/promotions/_rules.html.erb +2 -2
- data/app/views/spree/admin/promotions/actions/_create_quantity_adjustments.html.erb +5 -2
- data/app/views/spree/admin/promotions/edit.html.erb +2 -2
- data/app/views/spree/admin/promotions/index.html.erb +2 -2
- data/app/views/spree/admin/promotions/rules/_store.html.erb +6 -0
- data/app/views/spree/admin/properties/index.html.erb +2 -2
- data/app/views/spree/admin/refund_reasons/index.html.erb +1 -1
- data/app/views/spree/admin/refunds/edit.html.erb +2 -2
- data/app/views/spree/admin/refunds/new.html.erb +2 -2
- data/app/views/spree/admin/reimbursements/edit.html.erb +2 -2
- data/app/views/spree/admin/reimbursements/index.html.erb +1 -1
- data/app/views/spree/admin/reimbursements/show.html.erb +1 -1
- data/app/views/spree/admin/return_authorizations/edit.html.erb +3 -3
- data/app/views/spree/admin/return_authorizations/index.html.erb +1 -1
- data/app/views/spree/admin/return_authorizations/new.html.erb +2 -2
- data/app/views/spree/admin/search/products.json.jbuilder +2 -0
- data/app/views/spree/admin/search/users.json.jbuilder +2 -0
- data/app/views/spree/admin/shared/_datepicker.html.erb +8 -0
- data/app/views/spree/admin/shared/_edit_resource_links.html.erb +2 -2
- data/app/views/spree/admin/shared/_locale_selection.html.erb +15 -0
- data/app/views/spree/admin/shared/_navigation.html.erb +1 -0
- data/app/views/spree/admin/shared/_new_resource_links.html.erb +1 -1
- data/app/views/spree/admin/shared/_no_objects_found.html.erb +1 -1
- data/app/views/spree/admin/shared/_order_summary.html.erb +1 -1
- data/app/views/spree/admin/shared/_refunds.html.erb +1 -1
- data/app/views/spree/admin/shared/_report_order_criteria.html.erb +1 -1
- data/app/views/spree/admin/shared/_variant_search.html.erb +1 -1
- data/app/views/spree/admin/shared/named_types/_index.html.erb +1 -1
- data/app/views/spree/admin/shipping_categories/index.html.erb +1 -1
- data/app/views/spree/admin/shipping_methods/_form.html.erb +8 -0
- data/app/views/spree/admin/shipping_methods/index.html.erb +1 -1
- data/app/views/spree/admin/stock_locations/_form.html.erb +1 -1
- data/app/views/spree/admin/stock_locations/edit.html.erb +7 -0
- data/app/views/spree/admin/stock_locations/index.html.erb +1 -1
- data/app/views/spree/admin/stock_movements/index.html.erb +15 -15
- data/app/views/spree/admin/store_credits/edit_validity.html.erb +2 -2
- data/app/views/spree/admin/store_credits/show.html.erb +2 -0
- data/app/views/spree/admin/stores/_form.html.erb +77 -60
- data/app/views/spree/admin/stores/edit.html.erb +1 -1
- data/app/views/spree/admin/stores/index.html.erb +3 -3
- data/app/views/spree/admin/tax_categories/index.html.erb +1 -1
- data/app/views/spree/admin/tax_rates/index.html.erb +1 -1
- data/app/views/spree/admin/taxonomies/{edit.erb → edit.html.erb} +3 -3
- data/app/views/spree/admin/taxonomies/index.html.erb +1 -1
- data/app/views/spree/admin/taxonomies/new.html.erb +1 -1
- data/app/views/spree/admin/taxons/edit.html.erb +3 -3
- data/app/views/spree/admin/taxons/search.json.jbuilder +2 -0
- data/app/views/spree/admin/users/_user_page_actions.html.erb +1 -1
- data/app/views/spree/admin/users/edit.html.erb +3 -3
- data/app/views/spree/admin/users/index.html.erb +2 -2
- data/app/views/spree/admin/zones/index.html.erb +1 -1
- data/config/initializers/assets.rb +2 -0
- data/config/initializers/form_builder.rb +2 -0
- data/config/routes.rb +4 -0
- data/lib/solidus_backend.rb +2 -0
- data/lib/spree/backend.rb +2 -0
- data/lib/spree/backend/action_callbacks.rb +2 -0
- data/lib/spree/backend/callbacks.rb +2 -0
- data/lib/spree/backend/engine.rb +2 -0
- data/lib/spree_backend.rb +2 -0
- data/script/rails +4 -2
- data/solidus_backend.gemspec +6 -5
- data/spec/controllers/spree/admin/base_controller_spec.rb +2 -0
- data/spec/controllers/spree/admin/cancellations_controller_spec.rb +2 -0
- data/spec/controllers/spree/admin/customer_returns_controller_spec.rb +2 -0
- data/spec/controllers/spree/admin/missing_products_controller_spec.rb +2 -0
- data/spec/controllers/spree/admin/orders/customer_details_controller_spec.rb +2 -1
- data/spec/controllers/spree/admin/orders_controller_spec.rb +2 -9
- data/spec/controllers/spree/admin/payment_methods_controller_spec.rb +2 -0
- data/spec/controllers/spree/admin/payments_controller_spec.rb +2 -0
- data/spec/controllers/spree/admin/prices_controller_spec.rb +2 -0
- data/spec/controllers/spree/admin/product_properties_controller_spec.rb +2 -0
- data/spec/controllers/spree/admin/products_controller_spec.rb +2 -0
- data/spec/controllers/spree/admin/promotion_actions_controller_spec.rb +2 -0
- data/spec/controllers/spree/admin/promotion_codes_controller_spec.rb +2 -0
- data/spec/controllers/spree/admin/promotion_rules_controller_spec.rb +27 -12
- data/spec/controllers/spree/admin/promotions_controller_spec.rb +2 -0
- data/spec/controllers/spree/admin/refunds_controller_spec.rb +2 -0
- data/spec/controllers/spree/admin/reimbursements_controller_spec.rb +2 -0
- data/spec/controllers/spree/admin/reports_controller_spec.rb +2 -0
- data/spec/controllers/spree/admin/resource_controller_spec.rb +2 -0
- data/spec/controllers/spree/admin/return_authorizations_controller_spec.rb +2 -0
- data/spec/controllers/spree/admin/return_items_controller_spec.rb +2 -0
- data/spec/controllers/spree/admin/root_controller_spec.rb +2 -0
- data/spec/controllers/spree/admin/search_controller_spec.rb +2 -0
- data/spec/controllers/spree/admin/shipping_methods_controller_spec.rb +2 -0
- data/spec/controllers/spree/admin/stock_items_controller_spec.rb +2 -0
- data/spec/controllers/spree/admin/stock_locations_controller_spec.rb +2 -0
- data/spec/controllers/spree/admin/store_credits_controller_spec.rb +2 -0
- data/spec/controllers/spree/admin/users_controller_spec.rb +2 -1
- data/spec/controllers/spree/admin/variants_controller_spec.rb +2 -0
- data/spec/features/admin/configuration/payment_methods_spec.rb +2 -0
- data/spec/features/admin/configuration/shipping_methods_spec.rb +2 -0
- data/spec/features/admin/configuration/stock_locations_spec.rb +2 -0
- data/spec/features/admin/configuration/store_spec.rb +2 -0
- data/spec/features/admin/configuration/tax_categories_spec.rb +2 -0
- data/spec/features/admin/configuration/tax_rates_spec.rb +2 -0
- data/spec/features/admin/configuration/taxonomies_spec.rb +2 -0
- data/spec/features/admin/configuration/zones_spec.rb +2 -0
- data/spec/features/admin/homepage_spec.rb +2 -0
- data/spec/features/admin/javascript_format_money_spec.rb +2 -0
- data/spec/features/admin/locale_spec.rb +3 -0
- data/spec/features/admin/orders/adjustments_promotions_spec.rb +2 -0
- data/spec/features/admin/orders/adjustments_spec.rb +2 -0
- data/spec/features/admin/orders/cancelling_and_resuming_spec.rb +2 -0
- data/spec/features/admin/orders/cancelling_inventory_spec.rb +2 -0
- data/spec/features/admin/orders/customer_details_spec.rb +3 -1
- data/spec/features/admin/orders/line_items_spec.rb +2 -0
- data/spec/features/admin/orders/listing_spec.rb +2 -0
- data/spec/features/admin/orders/log_entries_spec.rb +2 -0
- data/spec/features/admin/orders/new_order_spec.rb +3 -1
- data/spec/features/admin/orders/order_details_spec.rb +3 -2
- data/spec/features/admin/orders/payments_spec.rb +5 -6
- data/spec/features/admin/orders/return_authorizations_spec.rb +2 -0
- data/spec/features/admin/orders/return_payment_state_spec.rb +2 -0
- data/spec/features/admin/orders/risk_analysis_spec.rb +2 -0
- data/spec/features/admin/orders/shipments_spec.rb +2 -0
- data/spec/features/admin/payments/store_credits_spec.rb +2 -0
- data/spec/features/admin/products/edit/images_spec.rb +2 -0
- data/spec/features/admin/products/edit/products_spec.rb +2 -1
- data/spec/features/admin/products/edit/taxons_spec.rb +3 -1
- data/spec/features/admin/products/edit/variants_spec.rb +2 -0
- data/spec/features/admin/products/option_types_spec.rb +2 -0
- data/spec/features/admin/products/pricing_spec.rb +2 -0
- data/spec/features/admin/products/products_spec.rb +2 -1
- data/spec/features/admin/products/properties_spec.rb +2 -0
- data/spec/features/admin/products/stock_management_spec.rb +2 -0
- data/spec/features/admin/products/variant_spec.rb +2 -1
- data/spec/features/admin/promotion_adjustments_spec.rb +2 -0
- data/spec/features/admin/promotions/option_value_rule_spec.rb +2 -0
- data/spec/features/admin/promotions/product_rule_spec.rb +2 -0
- data/spec/features/admin/promotions/promotion_categories_spec.rb +83 -0
- data/spec/features/admin/promotions/tiered_calculator_spec.rb +3 -1
- data/spec/features/admin/promotions/user_rule_spec.rb +2 -0
- data/spec/features/admin/reimbursements_spec.rb +2 -0
- data/spec/features/admin/reports_spec.rb +2 -0
- data/spec/features/admin/store_credits_spec.rb +2 -0
- data/spec/features/admin/stores_spec.rb +2 -0
- data/spec/features/admin/style_guide_spec.rb +2 -0
- data/spec/features/admin/taxons_spec.rb +2 -0
- data/spec/features/admin/users_spec.rb +2 -0
- data/spec/helpers/admin/base_helper_spec.rb +2 -0
- data/spec/helpers/admin/navigation_helper_spec.rb +2 -1
- data/spec/helpers/admin/stock_movements_helper_spec.rb +2 -0
- data/spec/helpers/admin/store_credit_events_helper_spec.rb +2 -0
- data/spec/helpers/promotion_rules_helper_spec.rb +2 -0
- data/spec/spec_helper.rb +3 -1
- data/spec/support/appear_before_matcher.rb +2 -0
- data/spec/support/feature/base_feature_helper.rb +2 -0
- data/spec/support/feature/order_feature_helper.rb +2 -0
- data/spec/teaspoon_env.rb +3 -1
- data/spec/views/spree/admin/shared/navigation_footer_spec.rb +2 -1
- metadata +43 -35
@@ -1,15 +1,16 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
<%
|
4
|
-
|
5
|
-
|
6
|
-
<%
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
<%
|
1
|
+
<% admin_breadcrumb(t('spree.settings')) %>
|
2
|
+
<% admin_breadcrumb(t('spree.admin.tab.shipping')) %>
|
3
|
+
<% if can?(:display, Spree::StockLocation) %>
|
4
|
+
<% admin_breadcrumb(link_to plural_resource_name(Spree::StockLocation), spree.admin_stock_locations_path) %>
|
5
|
+
<% else %>
|
6
|
+
<% admin_breadcrumb(plural_resource_name(Spree::StockLocation)) %>
|
7
|
+
<% end %>
|
8
|
+
<% if can?(:update, @stock_location) %>
|
9
|
+
<% admin_breadcrumb(link_to(admin_stock_location_display_name(@stock_location), spree.edit_admin_stock_location_path(@stock_location.id))) %>
|
10
|
+
<% else %>
|
11
|
+
<% admin_breadcrumb(admin_stock_location_display_name(@stock_location)) %>
|
12
12
|
<% end %>
|
13
|
+
<% admin_breadcrumb(plural_resource_name(Spree::StockMovement)) %>
|
13
14
|
|
14
15
|
<% if @stock_movements.any? %>
|
15
16
|
<table class="index" id='listing_stock_movements'>
|
@@ -20,9 +21,9 @@
|
|
20
21
|
</colgroup>
|
21
22
|
<thead>
|
22
23
|
<tr data-hook="admin_stock_movements_index_headers">
|
23
|
-
<th><%= Spree::StockMovement.human_attribute_name(:
|
24
|
+
<th><%= Spree::StockMovement.human_attribute_name(:variant) %>
|
24
25
|
<th><%= Spree::StockMovement.human_attribute_name(:quantity) %></th>
|
25
|
-
<th><%= Spree::StockMovement.human_attribute_name(:
|
26
|
+
<th><%= Spree::StockMovement.human_attribute_name(:originated_by) %></th>
|
26
27
|
</tr>
|
27
28
|
</thead>
|
28
29
|
<tbody>
|
@@ -40,8 +41,7 @@
|
|
40
41
|
<% else %>
|
41
42
|
<div class="no-objects-found">
|
42
43
|
<%= render 'spree/admin/shared/no_objects_found',
|
43
|
-
resource: Spree::StockMovement
|
44
|
-
new_resource_url: new_object_url %>
|
44
|
+
resource: Spree::StockMovement %>
|
45
45
|
</div>
|
46
46
|
<% end %>
|
47
47
|
|
@@ -19,8 +19,8 @@
|
|
19
19
|
</div>
|
20
20
|
</div>
|
21
21
|
<div class="form-buttons filter-actions actions" data-hook="buttons">
|
22
|
-
<%=
|
23
|
-
<%=
|
22
|
+
<%= button_tag t('spree.store_credit.actions.invalidate'), class: 'btn btn-primary' %>
|
23
|
+
<%= link_to t('spree.actions.cancel'), admin_user_store_credit_path(@user, @store_credit), class: 'btn btn-primary' %>
|
24
24
|
</div>
|
25
25
|
</fieldset>
|
26
26
|
<% end %>
|
@@ -83,6 +83,7 @@
|
|
83
83
|
<th><%= t('spree.admin.store_credits.amount_credited') %></th>
|
84
84
|
<th><%= t('spree.admin.store_credits.created_by') %></th>
|
85
85
|
<th><%= Spree::StoreCreditEvent.human_attribute_name(:user_total_amount) %></th>
|
86
|
+
<th><%= Spree::StoreCreditEvent.human_attribute_name(:amount_remaining) %></th>
|
86
87
|
<th><%= Spree::StoreCreditUpdateReason.human_attribute_name(:name) %></th>
|
87
88
|
</tr>
|
88
89
|
</thead>
|
@@ -96,6 +97,7 @@
|
|
96
97
|
<td><%= event.display_amount %></td>
|
97
98
|
<td><%= store_credit_event_originator_link(event) %></td>
|
98
99
|
<td><%= event.display_user_total_amount %></td>
|
100
|
+
<td><%= event.display_remaining_amount %></td>
|
99
101
|
<td><%= event.update_reason.try!(:name) %></td>
|
100
102
|
</tr>
|
101
103
|
<% end %>
|
@@ -1,60 +1,77 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
<%= f.
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
<%= f.
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
<%= f.
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
1
|
+
<div class="row">
|
2
|
+
<div class="col-12 col-md-6">
|
3
|
+
<%= f.field_container :name do %>
|
4
|
+
<%= f.label :name, class: 'required' %>
|
5
|
+
<%= f.text_field :name, required: true, class: 'fullwidth' %>
|
6
|
+
<%= f.error_message_on :name %>
|
7
|
+
<% end %>
|
8
|
+
|
9
|
+
<%= f.field_container :code do %>
|
10
|
+
<%= f.label :code, class: 'required' %>
|
11
|
+
<%= f.text_field :code, required: true, class: 'fullwidth' %>
|
12
|
+
<%= f.error_message_on :code %>
|
13
|
+
<% end %>
|
14
|
+
|
15
|
+
<%= f.field_container :seo_title do %>
|
16
|
+
<%= f.label :seo_title %>
|
17
|
+
<%= f.text_field :seo_title, class: 'fullwidth' %>
|
18
|
+
<%= f.error_message_on :seo_title %>
|
19
|
+
<% end %>
|
20
|
+
|
21
|
+
<%= f.field_container :meta_keywords do %>
|
22
|
+
<%= f.label :meta_keywords %>
|
23
|
+
<%= f.text_field :meta_keywords, class: 'fullwidth' %>
|
24
|
+
<%= f.error_message_on :meta_keywords %>
|
25
|
+
<% end %>
|
26
|
+
|
27
|
+
<%= f.field_container :meta_description do %>
|
28
|
+
<%= f.label :meta_description %>
|
29
|
+
<%= f.text_area :meta_description, class: 'fullwidth' %>
|
30
|
+
<%= f.error_message_on :meta_description %>
|
31
|
+
<% end %>
|
32
|
+
</div>
|
33
|
+
<div class="col-12 col-md-6">
|
34
|
+
<%= f.field_container :url do %>
|
35
|
+
<%= f.label :url, class: 'required' %>
|
36
|
+
<%= f.text_field :url, required: true, class: 'fullwidth' %>
|
37
|
+
<%= f.error_message_on :url %>
|
38
|
+
<% end %>
|
39
|
+
|
40
|
+
<%= f.field_container :mail_from_address do %>
|
41
|
+
<%= f.label :mail_from_address, class: 'required' %>
|
42
|
+
<%= f.text_field :mail_from_address, required: true, class: 'fullwidth' %>
|
43
|
+
<%= f.error_message_on :mail_from_address %>
|
44
|
+
<% end %>
|
45
|
+
|
46
|
+
<%= f.field_container :default_currency do %>
|
47
|
+
<%= f.label :default_currency %>
|
48
|
+
<%= f.select :default_currency,
|
49
|
+
Spree::Config.available_currencies.map(&:iso_code),
|
50
|
+
{ include_blank: true },
|
51
|
+
{ class: 'custom-select fullwidth' } %>
|
52
|
+
<%= f.error_message_on :default_currency %>
|
53
|
+
<% end %>
|
54
|
+
|
55
|
+
<%= f.field_container :cart_tax_country_iso do %>
|
56
|
+
<%= f.label :cart_tax_country_iso %>
|
57
|
+
<%= f.field_hint :cart_tax_country_iso %>
|
58
|
+
<%= f.select :cart_tax_country_iso,
|
59
|
+
Spree::Country.all.map { |c| [c.name, c.iso] },
|
60
|
+
{ include_blank: t(".no_cart_tax_country") },
|
61
|
+
{ class: "custom-select fullwidth" } %>
|
62
|
+
<%= f.error_message_on :cart_tax_country_iso %>
|
63
|
+
<% end %>
|
64
|
+
|
65
|
+
<%= f.field_container :available_locales do %>
|
66
|
+
<%= f.label :available_locales %>
|
67
|
+
<%= f.field_hint :available_locales %>
|
68
|
+
<%= f.select :available_locales,
|
69
|
+
Spree.i18n_available_locales.map { |locale|
|
70
|
+
[I18n.t('spree.i18n.this_file_language', locale: locale, default: locale.to_s, fallback: false), locale]
|
71
|
+
}.sort,
|
72
|
+
{ },
|
73
|
+
{ class: 'select2 fullwidth', multiple: true } %>
|
74
|
+
<%= f.error_message_on :default_currency %>
|
75
|
+
<% end %>
|
76
|
+
</div>
|
77
|
+
</div>
|
@@ -15,8 +15,8 @@
|
|
15
15
|
<table class="index">
|
16
16
|
<thead>
|
17
17
|
<tr>
|
18
|
-
<th
|
19
|
-
<th
|
18
|
+
<th><%= Spree::Store.human_attribute_name(:name) %></th>
|
19
|
+
<th><%= Spree::Store.human_attribute_name(:url) %></th>
|
20
20
|
<th class="actions"></th>
|
21
21
|
</tr>
|
22
22
|
</thead>
|
@@ -26,7 +26,7 @@
|
|
26
26
|
<td>
|
27
27
|
<%= store.name %>
|
28
28
|
<% if store.default? %>
|
29
|
-
<span class="label label-default"
|
29
|
+
<span class="label label-default"><%= Spree::Store.human_attribute_name(:default) %></span>
|
30
30
|
<% end %>
|
31
31
|
</td>
|
32
32
|
<td><%= store.url %></td>
|
@@ -9,7 +9,7 @@
|
|
9
9
|
<ul class="actions inline-menu">
|
10
10
|
<% if can?(:create, Spree::TaxCategory) %>
|
11
11
|
<li>
|
12
|
-
<%=
|
12
|
+
<%= link_to t('spree.new_tax_category'), new_object_url, id: 'admin_new_tax_categories_link', class: 'btn btn-primary' %>
|
13
13
|
</li>
|
14
14
|
<% end %>
|
15
15
|
</ul>
|
@@ -8,7 +8,7 @@
|
|
8
8
|
<% content_for :page_actions do %>
|
9
9
|
<% if can?(:create, Spree::TaxRate) %>
|
10
10
|
<li>
|
11
|
-
<%=
|
11
|
+
<%= link_to t('spree.new_tax_rate'), new_object_url, class: 'btn btn-primary' %>
|
12
12
|
</li>
|
13
13
|
<% end %>
|
14
14
|
<% end %>
|
@@ -5,7 +5,7 @@
|
|
5
5
|
|
6
6
|
<% content_for :page_actions do %>
|
7
7
|
<li>
|
8
|
-
<%=
|
8
|
+
<%= link_to t('spree.add_taxon'), spree.admin_taxonomies_path, class: 'add-taxon-button btn btn-primary' %>
|
9
9
|
</li>
|
10
10
|
<% end %>
|
11
11
|
|
@@ -13,8 +13,8 @@
|
|
13
13
|
<fieldset class="no-border-top">
|
14
14
|
<%= render partial: 'form', locals: { f: f } %>
|
15
15
|
<div class="filter-actions actions">
|
16
|
-
<%=
|
17
|
-
<%=
|
16
|
+
<%= button_tag t('spree.actions.update'), class: 'btn btn-primary' %>
|
17
|
+
<%= link_to t('spree.actions.cancel'), admin_taxonomies_path, class: 'btn btn-primary' %>
|
18
18
|
</div>
|
19
19
|
</fieldset>
|
20
20
|
|
@@ -5,7 +5,7 @@
|
|
5
5
|
<% content_for :page_actions do %>
|
6
6
|
<% if can?(:create, Spree::Taxonomy) %>
|
7
7
|
<li>
|
8
|
-
<%=
|
8
|
+
<%= link_to t('spree.new_taxonomy'), spree.new_admin_taxonomy_url, id: 'admin_new_taxonomy_link', class: 'btn btn-primary' %>
|
9
9
|
</li>
|
10
10
|
<% end %>
|
11
11
|
<% end %>
|
@@ -3,7 +3,7 @@
|
|
3
3
|
|
4
4
|
<% content_for :page_actions do %>
|
5
5
|
<li>
|
6
|
-
<%=
|
6
|
+
<%= link_to t('spree.back_to_taxonomies_list'), spree.admin_taxonomies_path, class: 'btn btn-primary' %>
|
7
7
|
</li>
|
8
8
|
<% end %>
|
9
9
|
|
@@ -13,7 +13,7 @@
|
|
13
13
|
<%= render 'form', f: f %>
|
14
14
|
|
15
15
|
<div class="form-buttons filter-actions" data-hook="buttons">
|
16
|
-
<%=
|
17
|
-
<%=
|
16
|
+
<%= button_tag t('spree.actions.update'), class: 'btn btn-primary' %>
|
17
|
+
<%= link_to t('spree.actions.cancel'), edit_admin_taxonomy_url(@taxonomy), class: 'btn btn-primary' %>
|
18
18
|
</div>
|
19
19
|
<% end %>
|
@@ -1,7 +1,7 @@
|
|
1
1
|
<% content_for :page_actions do %>
|
2
2
|
<% if can?([:admin, :create], Spree::Order) %>
|
3
3
|
<li>
|
4
|
-
<%=
|
4
|
+
<%= link_to t(".create_order"), spree.new_admin_order_path(user_id: @user.id), class: 'btn btn-primary' %>
|
5
5
|
</li>
|
6
6
|
<% end %>
|
7
7
|
<% end %>
|
@@ -41,8 +41,8 @@
|
|
41
41
|
|
42
42
|
</div>
|
43
43
|
<div class="filter-actions actions">
|
44
|
-
<%=
|
45
|
-
<%=
|
44
|
+
<%= button_to t('.clear_key'), spree.clear_api_key_admin_user_path(@user), method: :put, data: { confirm: t('.confirm_clear_key') }, class: 'btn btn-primary' %>
|
45
|
+
<%= button_to t('.regenerate_key'), spree.generate_api_key_admin_user_path(@user), method: :put, data: { confirm: t('.confirm_regenerate_key') }, class: 'btn btn-primary' %>
|
46
46
|
</div>
|
47
47
|
|
48
48
|
<% else %>
|
@@ -50,7 +50,7 @@
|
|
50
50
|
<div class="no-objects-found"><%= t('.no_key') %></div>
|
51
51
|
|
52
52
|
<div class="filter-actions actions">
|
53
|
-
<%=
|
53
|
+
<%= button_to t('.generate_key'), spree.generate_api_key_admin_user_path(@user), method: :put, class: 'btn btn-primary' %>
|
54
54
|
</div>
|
55
55
|
<% end %>
|
56
56
|
</fieldset>
|
@@ -3,7 +3,7 @@
|
|
3
3
|
<% content_for :page_actions do %>
|
4
4
|
<% if can?(:admin, Spree.user_class) && can?(:create, Spree.user_class) %>
|
5
5
|
<li>
|
6
|
-
<%=
|
6
|
+
<%= link_to t('spree.new_user'), new_admin_user_url, id: 'admin_new_user_link', class: 'btn btn-primary' %>
|
7
7
|
</li>
|
8
8
|
<% end %>
|
9
9
|
<% end %>
|
@@ -50,7 +50,7 @@
|
|
50
50
|
</div>
|
51
51
|
|
52
52
|
<div class="actions filter-actions" data-hook="admin_users_index_search_buttons">
|
53
|
-
<%=
|
53
|
+
<%= button_tag t('spree.search'), class: 'btn btn-primary' %>
|
54
54
|
</div>
|
55
55
|
<% end %>
|
56
56
|
</div>
|
@@ -4,7 +4,7 @@
|
|
4
4
|
<% content_for :page_actions do %>
|
5
5
|
<% if can?(:create, Spree::Zone) %>
|
6
6
|
<li>
|
7
|
-
<%=
|
7
|
+
<%= link_to t('spree.new_zone'), new_object_url, id: 'admin_new_zone_link', class: 'btn btn-primary' %>
|
8
8
|
</li>
|
9
9
|
<% end %>
|
10
10
|
<% end %>
|
data/config/routes.rb
CHANGED
@@ -1,8 +1,12 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
Spree::Core::Engine.routes.draw do
|
2
4
|
namespace :admin do
|
3
5
|
get '/search/users', to: "search#users", as: :search_users
|
4
6
|
get '/search/products', to: "search#products", as: :search_products
|
5
7
|
|
8
|
+
put '/locale/set', to: 'locale#set', defaults: { format: :json }, as: :set_locale
|
9
|
+
|
6
10
|
resources :dashboards, only: [] do
|
7
11
|
collection do
|
8
12
|
get :home
|
data/lib/solidus_backend.rb
CHANGED
data/lib/spree/backend.rb
CHANGED