spree_backend 4.1.9 → 4.2.0.beta
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/assets/images/backend-add.svg +5 -0
- data/app/assets/images/backend-adjust.svg +5 -0
- data/app/assets/images/backend-approve.svg +3 -0
- data/app/assets/images/backend-arrow-down.svg +1 -0
- data/app/assets/images/backend-arrow-left.svg +1 -0
- data/app/assets/images/backend-arrow-right.svg +1 -0
- data/app/assets/images/backend-arrow-up.svg +1 -0
- data/app/assets/images/backend-calendar.svg +9 -0
- data/app/assets/images/backend-cancel.svg +7 -0
- data/app/assets/images/backend-capture.svg +3 -0
- data/app/assets/images/backend-cart.svg +1 -0
- data/app/assets/images/backend-chevron-down.svg +1 -0
- data/app/assets/images/backend-chevron-left.svg +1 -0
- data/app/assets/images/backend-chevron-right.svg +1 -0
- data/app/assets/images/backend-chevron-up.svg +1 -0
- data/app/assets/images/backend-clone.svg +7 -0
- data/app/assets/images/backend-close.svg +7 -0
- data/app/assets/images/backend-delete.svg +6 -0
- data/app/assets/images/backend-double-chevron-left.svg +15 -0
- data/app/assets/images/backend-double-chevron-right.svg +17 -0
- data/app/assets/images/backend-edit.svg +14 -0
- data/app/assets/images/backend-enter.svg +6 -0
- data/app/assets/images/backend-envelope.svg +3 -0
- data/app/assets/images/backend-exit.svg +13 -0
- data/app/assets/images/backend-extensions.svg +4 -0
- data/app/assets/images/backend-eye-open.svg +8 -0
- data/app/assets/images/backend-file.svg +6 -0
- data/app/assets/images/backend-filter.svg +3 -0
- data/app/assets/images/backend-folder.svg +4 -0
- data/app/assets/images/backend-images.svg +7 -0
- data/app/assets/images/backend-info.svg +7 -0
- data/app/assets/images/backend-items.svg +5 -0
- data/app/assets/images/backend-leaf.svg +7 -0
- data/app/assets/images/backend-list.svg +5 -0
- data/app/assets/images/backend-location.svg +4 -0
- data/app/assets/images/backend-menu.svg +5 -0
- data/app/assets/images/backend-money.svg +1 -0
- data/app/assets/images/backend-move.svg +5 -0
- data/app/assets/images/backend-ok.svg +3 -0
- data/app/assets/images/backend-pagination-double-arrow-right.svg +8 -0
- data/app/assets/images/backend-payments.svg +8 -0
- data/app/assets/images/backend-pencil.svg +1 -0
- data/app/assets/images/backend-products.svg +5 -0
- data/app/assets/images/backend-promotion.svg +8 -0
- data/app/assets/images/backend-recycle.svg +5 -0
- data/app/assets/images/backend-remove.svg +6 -0
- data/app/assets/images/backend-report.svg +6 -0
- data/app/assets/images/backend-resume.svg +5 -0
- data/app/assets/images/backend-returns.svg +3 -0
- data/app/assets/images/backend-save.svg +3 -0
- data/app/assets/images/backend-search.svg +1 -0
- data/app/assets/images/backend-settings.svg +6 -0
- data/app/assets/images/backend-shipping.svg +3 -0
- data/app/assets/images/backend-slack.svg +3 -0
- data/app/assets/images/backend-sort.svg +5 -0
- data/app/assets/images/backend-split.svg +3 -0
- data/app/assets/images/backend-store.svg +14 -0
- data/app/assets/images/backend-tick.svg +3 -0
- data/app/assets/images/backend-update.svg +3 -0
- data/app/assets/images/backend-user.svg +3 -0
- data/app/assets/images/backend-users.svg +6 -0
- data/app/assets/images/backend-view.svg +8 -0
- data/app/assets/images/backend-void.svg +7 -0
- data/app/assets/javascripts/spree/backend.js +5 -2
- data/app/assets/javascripts/spree/backend/admin.js +156 -147
- data/app/assets/javascripts/spree/backend/checkouts/edit.js +1 -0
- data/app/assets/javascripts/spree/backend/flatpickr_locals.js +37 -0
- data/app/assets/javascripts/spree/backend/multi_currency.js +38 -0
- data/app/assets/javascripts/spree/backend/payments/edit.js +4 -3
- data/app/assets/javascripts/spree/backend/payments/new.js +18 -18
- data/app/assets/javascripts/spree/backend/promotions.js +1 -1
- data/app/assets/javascripts/spree/backend/spree-select2.js +18 -4
- data/app/assets/javascripts/spree/backend/stock_management.js +2 -1
- data/app/assets/javascripts/spree/backend/taxon_tree_menu.js +4 -4
- data/app/assets/javascripts/spree/backend/taxonomy.js +8 -1
- data/app/assets/javascripts/spree/backend/taxons.js +25 -16
- data/app/assets/javascripts/spree/backend/user_picker.js +1 -1
- data/app/assets/javascripts/spree/backend/variant_autocomplete.js +1 -1
- data/app/assets/javascripts/spree/backend/variant_management.js +2 -1
- data/app/assets/stylesheets/spree/backend.css +1 -1
- data/app/assets/stylesheets/spree/backend/components/_buttons.scss +27 -11
- data/app/assets/stylesheets/spree/backend/components/_filters.scss +35 -5
- data/app/assets/stylesheets/spree/backend/components/_icons.scss +39 -4
- data/app/assets/stylesheets/spree/backend/components/_main.scss +32 -6
- data/app/assets/stylesheets/spree/backend/components/_navbar.scss +16 -8
- data/app/assets/stylesheets/spree/backend/components/_sidebar.scss +119 -55
- data/app/assets/stylesheets/spree/backend/components/_tables.scss +62 -19
- data/app/assets/stylesheets/spree/backend/components/_taxon_products_view.scss +26 -63
- data/app/assets/stylesheets/spree/backend/global/_variables.scss +5 -1
- data/app/assets/stylesheets/spree/backend/plugins/_flatpickr.scss +95 -0
- data/app/assets/stylesheets/spree/backend/plugins/_jquery_ui.scss +0 -117
- data/app/assets/stylesheets/spree/backend/plugins/_select2.scss +73 -24
- data/app/assets/stylesheets/spree/backend/shared/_base.scss +40 -0
- data/app/assets/stylesheets/spree/backend/shared/_forms.scss +38 -0
- data/app/assets/stylesheets/spree/backend/spree_admin.css.scss +5 -0
- data/app/assets/stylesheets/spree/backend/views/_order_payments.scss +12 -0
- data/app/assets/stylesheets/spree/backend/views/_product_properties.scss +11 -0
- data/app/assets/stylesheets/spree/backend/views/prototypes.scss +42 -0
- data/app/controllers/spree/admin/general_settings_controller.rb +27 -0
- data/app/controllers/spree/admin/prices_controller.rb +39 -0
- data/app/controllers/spree/admin/stock_transfers_controller.rb +8 -1
- data/app/controllers/spree/admin/stores_controller.rb +61 -1
- data/app/controllers/spree/admin/taxons_controller.rb +5 -1
- data/app/helpers/spree/admin/base_helper.rb +25 -8
- data/app/helpers/spree/admin/navigation_helper.rb +50 -19
- data/app/helpers/spree/admin/orders_helper.rb +2 -2
- data/app/views/kaminari/{twitter-bootstrap-4 → admin-twitter-bootstrap-4}/_first_page.html.erb +1 -1
- data/app/views/kaminari/{twitter-bootstrap-4 → admin-twitter-bootstrap-4}/_gap.html.erb +1 -1
- data/app/views/kaminari/{twitter-bootstrap-4 → admin-twitter-bootstrap-4}/_last_page.html.erb +1 -1
- data/app/views/kaminari/{twitter-bootstrap-4 → admin-twitter-bootstrap-4}/_next_page.html.erb +1 -1
- data/app/views/kaminari/{twitter-bootstrap-4 → admin-twitter-bootstrap-4}/_page.html.erb +0 -0
- data/app/views/kaminari/{twitter-bootstrap-4 → admin-twitter-bootstrap-4}/_paginator.html.erb +1 -1
- data/app/views/kaminari/{twitter-bootstrap-4 → admin-twitter-bootstrap-4}/_prev_page.html.erb +1 -1
- data/app/views/spree/admin/adjustments/_adjustment.html.erb +2 -2
- data/app/views/spree/admin/adjustments/_adjustments_table.html.erb +16 -16
- data/app/views/spree/admin/adjustments/edit.html.erb +2 -2
- data/app/views/spree/admin/adjustments/index.html.erb +3 -3
- data/app/views/spree/admin/adjustments/new.html.erb +1 -1
- data/app/views/spree/admin/countries/_form.html.erb +9 -4
- data/app/views/spree/admin/countries/index.html.erb +27 -24
- data/app/views/spree/admin/customer_returns/_reimbursements_table.html.erb +37 -35
- data/app/views/spree/admin/customer_returns/_return_item_decision.html.erb +2 -0
- data/app/views/spree/admin/customer_returns/_return_item_selection.html.erb +45 -43
- data/app/views/spree/admin/customer_returns/index.html.erb +3 -1
- data/app/views/spree/admin/customer_returns/new.html.erb +1 -1
- data/app/views/spree/admin/general_settings/_form.html.erb +27 -0
- data/app/views/spree/admin/general_settings/edit.html.erb +4 -3
- data/app/views/spree/admin/images/edit.html.erb +2 -2
- data/app/views/spree/admin/images/index.html.erb +7 -7
- data/app/views/spree/admin/images/new.html.erb +2 -2
- data/app/views/spree/admin/log_entries/index.html.erb +4 -3
- data/app/views/spree/admin/option_types/_option_value_fields.html.erb +1 -1
- data/app/views/spree/admin/option_types/edit.html.erb +22 -20
- data/app/views/spree/admin/option_types/index.html.erb +27 -25
- data/app/views/spree/admin/orders/_adjustments.html.erb +26 -26
- data/app/views/spree/admin/orders/_line_items.html.erb +7 -7
- data/app/views/spree/admin/orders/_order_actions.html.erb +1 -1
- data/app/views/spree/admin/orders/_risk_analysis.html.erb +44 -42
- data/app/views/spree/admin/orders/_shipment.html.erb +6 -6
- data/app/views/spree/admin/orders/_shipment_manifest.html.erb +5 -5
- data/app/views/spree/admin/orders/_store_form.html.erb +3 -3
- data/app/views/spree/admin/orders/customer_details/_form.html.erb +1 -1
- data/app/views/spree/admin/orders/index.html.erb +135 -127
- data/app/views/spree/admin/payment_methods/index.html.erb +6 -4
- data/app/views/spree/admin/payments/_capture_events.html.erb +18 -16
- data/app/views/spree/admin/payments/_form.html.erb +1 -1
- data/app/views/spree/admin/payments/_list.html.erb +39 -37
- data/app/views/spree/admin/payments/index.html.erb +2 -3
- data/app/views/spree/admin/payments/new.html.erb +1 -1
- data/app/views/spree/admin/payments/show.html.erb +1 -1
- data/app/views/spree/admin/payments/source_forms/_gateway.html.erb +30 -30
- data/app/views/spree/admin/payments/source_views/_gateway.html.erb +20 -18
- data/app/views/spree/admin/payments/source_views/_storecredit.html.erb +28 -26
- data/app/views/spree/admin/prices/_variant_prices.html.erb +43 -0
- data/app/views/spree/admin/prices/index.html.erb +21 -0
- data/app/views/spree/admin/product_properties/_product_property_fields.html.erb +16 -4
- data/app/views/spree/admin/product_properties/index.html.erb +24 -19
- data/app/views/spree/admin/products/_add_stock_form.html.erb +1 -1
- data/app/views/spree/admin/products/_autocomplete.js.erb +27 -21
- data/app/views/spree/admin/products/_form.html.erb +40 -9
- data/app/views/spree/admin/products/edit.html.erb +1 -1
- data/app/views/spree/admin/products/index.html.erb +24 -19
- data/app/views/spree/admin/products/new.html.erb +11 -2
- data/app/views/spree/admin/products/stock.html.erb +3 -3
- data/app/views/spree/admin/promotion_categories/index.html.erb +4 -1
- data/app/views/spree/admin/promotions/_actions.html.erb +2 -2
- data/app/views/spree/admin/promotions/_form.html.erb +44 -17
- data/app/views/spree/admin/promotions/_promotion_action.html.erb +1 -1
- data/app/views/spree/admin/promotions/_promotion_rule.html.erb +1 -1
- data/app/views/spree/admin/promotions/_rules.html.erb +4 -4
- data/app/views/spree/admin/promotions/edit.html.erb +2 -2
- data/app/views/spree/admin/promotions/index.html.erb +5 -3
- data/app/views/spree/admin/promotions/new.html.erb +7 -6
- data/app/views/spree/admin/promotions/rules/_country.html.erb +1 -1
- data/app/views/spree/admin/promotions/rules/_item_total.html.erb +5 -5
- data/app/views/spree/admin/promotions/rules/_option_value.html.erb +6 -13
- data/app/views/spree/admin/promotions/rules/_product.html.erb +1 -1
- data/app/views/spree/admin/promotions/rules/_taxon.html.erb +1 -1
- data/app/views/spree/admin/properties/index.html.erb +5 -3
- data/app/views/spree/admin/prototypes/_prototypes.html.erb +30 -28
- data/app/views/spree/admin/prototypes/index.html.erb +21 -19
- data/app/views/spree/admin/prototypes/show.html.erb +21 -8
- 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/reimbursement_types/_form.html.erb +4 -4
- data/app/views/spree/admin/reimbursement_types/index.html.erb +4 -2
- data/app/views/spree/admin/reimbursements/edit.html.erb +66 -63
- data/app/views/spree/admin/reimbursements/index.html.erb +21 -20
- data/app/views/spree/admin/reimbursements/show.html.erb +66 -60
- data/app/views/spree/admin/reports/index.html.erb +18 -17
- data/app/views/spree/admin/reports/sales_total.html.erb +20 -19
- data/app/views/spree/admin/return_authorizations/_form.html.erb +3 -2
- data/app/views/spree/admin/return_authorizations/edit.html.erb +3 -3
- data/app/views/spree/admin/return_authorizations/index.html.erb +3 -1
- data/app/views/spree/admin/return_authorizations/new.html.erb +2 -2
- data/app/views/spree/admin/return_index/customer_returns.html.erb +4 -4
- data/app/views/spree/admin/return_index/return_authorizations.html.erb +4 -4
- data/app/views/spree/admin/roles/index.html.erb +21 -19
- data/app/views/spree/admin/shared/_account_nav.html.erb +51 -65
- data/app/views/spree/admin/shared/_address_form.html.erb +31 -73
- data/app/views/spree/admin/shared/_cal_close.html.erb +10 -0
- data/app/views/spree/admin/shared/_content_header.html.erb +40 -21
- data/app/views/spree/admin/shared/_edit_resource_links.html.erb +2 -2
- data/app/views/spree/admin/shared/_header.html.erb +14 -11
- data/app/views/spree/admin/shared/_index_table_options.html.erb +5 -7
- data/app/views/spree/admin/shared/_main_menu.html.erb +25 -14
- data/app/views/spree/admin/shared/_new_resource_links.html.erb +2 -2
- data/app/views/spree/admin/shared/_order_summary.html.erb +2 -0
- data/app/views/spree/admin/shared/_order_tabs.html.erb +9 -9
- data/app/views/spree/admin/shared/_product_tabs.html.erb +13 -5
- data/app/views/spree/admin/shared/_refunds.html.erb +31 -29
- data/app/views/spree/admin/shared/_report_order_criteria.html.erb +27 -6
- data/app/views/spree/admin/shared/_sidebar.html.erb +19 -1
- data/app/views/spree/admin/shared/_table_filter.html.erb +3 -3
- data/app/views/spree/admin/shared/_translations.html.erb +33 -1
- data/app/views/spree/admin/shared/_version.html.erb +1 -1
- data/app/views/spree/admin/shared/named_types/_index.html.erb +3 -1
- data/app/views/spree/admin/shipping_categories/index.html.erb +3 -1
- data/app/views/spree/admin/shipping_methods/index.html.erb +3 -1
- data/app/views/spree/admin/state_changes/index.html.erb +5 -2
- data/app/views/spree/admin/states/_state_list.html.erb +25 -24
- data/app/views/spree/admin/states/index.html.erb +1 -1
- data/app/views/spree/admin/stock_locations/_transfer_stock_form.html.erb +2 -2
- data/app/views/spree/admin/stock_locations/index.html.erb +3 -1
- data/app/views/spree/admin/stock_movements/index.html.erb +28 -26
- data/app/views/spree/admin/stock_transfers/_stock_movements.html.erb +20 -18
- data/app/views/spree/admin/stock_transfers/index.html.erb +6 -4
- data/app/views/spree/admin/stock_transfers/new.html.erb +3 -3
- data/app/views/spree/admin/stock_transfers/show.html.erb +3 -3
- data/app/views/spree/admin/store_credit_categories/index.html.erb +3 -1
- data/app/views/spree/admin/store_credits/index.html.erb +3 -1
- data/app/views/spree/admin/stores/_form.html.erb +128 -68
- data/app/views/spree/admin/stores/edit.html.erb +1 -1
- data/app/views/spree/admin/stores/index.html.erb +4 -2
- data/app/views/spree/admin/tax_categories/index.html.erb +29 -27
- data/app/views/spree/admin/tax_rates/index.html.erb +3 -1
- data/app/views/spree/admin/taxonomies/_list.html.erb +24 -22
- data/app/views/spree/admin/taxonomies/edit.html.erb +2 -2
- data/app/views/spree/admin/taxonomies/index.html.erb +1 -1
- data/app/views/spree/admin/taxons/_form.html.erb +3 -3
- data/app/views/spree/admin/taxons/_taxon_table.html.erb +24 -22
- data/app/views/spree/admin/taxons/edit.html.erb +6 -2
- data/app/views/spree/admin/taxons/index.html.erb +1 -1
- data/app/views/spree/admin/users/_lifetime_stats.html.erb +24 -23
- data/app/views/spree/admin/users/_sidebar.html.erb +5 -5
- data/app/views/spree/admin/users/_user_page_actions.html.erb +1 -1
- data/app/views/spree/admin/users/edit.html.erb +2 -2
- data/app/views/spree/admin/users/index.html.erb +25 -23
- data/app/views/spree/admin/users/items.html.erb +3 -2
- data/app/views/spree/admin/users/orders.html.erb +30 -29
- data/app/views/spree/admin/variants/_autocomplete_line_items_stock.js.erb +3 -3
- data/app/views/spree/admin/variants/_autocomplete_stock.js.erb +2 -2
- data/app/views/spree/admin/variants/_form.html.erb +14 -2
- data/app/views/spree/admin/variants/_split.js.erb +2 -2
- data/app/views/spree/admin/variants/index.html.erb +7 -5
- data/app/views/spree/admin/zones/index.html.erb +4 -4
- data/app/views/spree/layouts/admin.html.erb +33 -27
- data/config/initializers/ransack.rb +31 -0
- data/config/routes.rb +1 -0
- data/lib/spree/backend.rb +2 -0
- data/lib/spree_backend.rb +0 -1
- data/spec/fixtures/thinking-cat.jpg +0 -0
- data/spree_backend.gemspec +6 -4
- data/vendor/assets/javascripts/js.cookie.js +154 -156
- data/vendor/assets/javascripts/purify.js +1217 -0
- data/vendor/assets/javascripts/sortable.js +3709 -0
- data/vendor/assets/stylesheets/animate.css +7 -3156
- data/vendor/assets/stylesheets/jquery.jstree/themes/spree/style.scss +23 -9
- metadata +137 -24
@@ -43,8 +43,8 @@
|
|
43
43
|
</td>
|
44
44
|
<td class="actions text-center">
|
45
45
|
<% if can? :update, shipment %>
|
46
|
-
<%= link_to_with_icon 'cancel', Spree.t('actions.cancel'), "#", class: 'cancel-method btn btn-
|
47
|
-
<%= link_to_with_icon 'save', Spree.t('actions.save'), "#", class: 'save-method btn btn-success btn-sm', data: {'shipment-number' => shipment.number, action: 'save'}, title: Spree.t('actions.save'), no_text: true %>
|
46
|
+
<%= link_to_with_icon 'cancel.svg', Spree.t('actions.cancel'), "#", class: 'cancel-method btn btn-outline-secondary btn-sm', data: {action: 'cancel'}, title: Spree.t('actions.cancel'), no_text: true %>
|
47
|
+
<%= link_to_with_icon 'save.svg', Spree.t('actions.save'), "#", class: 'save-method btn btn-success btn-sm', data: {'shipment-number' => shipment.number, action: 'save'}, title: Spree.t('actions.save'), no_text: true %>
|
48
48
|
<% end %>
|
49
49
|
</td>
|
50
50
|
</tr>
|
@@ -64,7 +64,7 @@
|
|
64
64
|
|
65
65
|
<td class="actions text-center">
|
66
66
|
<% if( (can? :update, shipment) and !shipment.shipped?) %>
|
67
|
-
<%= link_to_with_icon 'edit', Spree.t('edit'), "javascript:;", class: 'edit-method with-tip btn btn-sm btn-
|
67
|
+
<%= link_to_with_icon 'edit.svg', Spree.t('edit'), "javascript:;", class: 'edit-method with-tip btn btn-sm btn-outline-secondary', data: {action: 'edit'}, no_text: true %>
|
68
68
|
<% end %>
|
69
69
|
</td>
|
70
70
|
</tr>
|
@@ -77,8 +77,8 @@
|
|
77
77
|
</td>
|
78
78
|
<td class="actions text-center">
|
79
79
|
<% if can? :update, shipment %>
|
80
|
-
<%= link_to_with_icon 'cancel', Spree.t('actions.cancel'), "#", class: 'cancel-tracking btn btn-
|
81
|
-
<%= link_to_with_icon 'save', Spree.t('actions.save'), "#", class: 'save-tracking btn btn-success btn-sm', data: {'shipment-number' => shipment.number, action: 'save'}, title: Spree.t('actions.save'), no_text: true %>
|
80
|
+
<%= link_to_with_icon 'cancel.svg', Spree.t('actions.cancel'), "#", class: 'cancel-tracking btn btn-outline-secondary btn-sm', data: {action: 'cancel'}, title: Spree.t('actions.cancel'), no_text: true %>
|
81
|
+
<%= link_to_with_icon 'save.svg', Spree.t('actions.save'), "#", class: 'save-tracking btn btn-success btn-sm', data: {'shipment-number' => shipment.number, action: 'save'}, title: Spree.t('actions.save'), no_text: true %>
|
82
82
|
<% end %>
|
83
83
|
</td>
|
84
84
|
</tr>
|
@@ -101,7 +101,7 @@
|
|
101
101
|
</td>
|
102
102
|
<td class="actions text-center">
|
103
103
|
<% if can? :update, shipment %>
|
104
|
-
<%= link_to_with_icon 'edit', Spree.t('edit'), "#", class: 'edit-tracking btn btn-
|
104
|
+
<%= link_to_with_icon 'edit.svg', Spree.t('edit'), "#", class: 'edit-tracking btn btn-outline-secondary btn-sm', data: {action: 'edit'}, title: Spree.t('edit'), no_text: true %>
|
105
105
|
<% end %>
|
106
106
|
</td>
|
107
107
|
</tr>
|
@@ -33,11 +33,11 @@
|
|
33
33
|
|
34
34
|
<td class="cart-item-delete actions actions-3 text-center" data-hook="cart_item_delete">
|
35
35
|
<% if((!shipment.shipped?) && can?(:update, item.line_item)) %>
|
36
|
-
<%= link_to_with_icon '
|
37
|
-
<%= link_to_with_icon 'cancel', Spree.t('actions.cancel'), "#", class: 'cancel-item btn btn-
|
38
|
-
<%= link_to_with_icon '
|
39
|
-
<%= link_to_with_icon 'split', Spree.t('split'), "#", class: 'split-item btn btn-
|
40
|
-
<%= link_to_with_icon 'delete', Spree.t('delete'), "#", class: 'delete-item btn btn-danger btn-sm', data: { 'shipment-number' => shipment.number, 'variant-id' => item.variant.id, action: 'remove'}, title: Spree.t('delete'), no_text: true %>
|
36
|
+
<%= link_to_with_icon 'edit.svg', Spree.t('actions.edit'), "#", class: 'edit-item btn btn-outline-secondary btn-sm', title: Spree.t('actions.edit'), no_text: true %>
|
37
|
+
<%= link_to_with_icon 'cancel.svg', Spree.t('actions.cancel'), "#", class: 'cancel-item btn btn-outline-secondary btn-sm', data: { action: 'cancel' }, title: Spree.t('actions.cancel'), style: 'display: none', no_text: true %>
|
38
|
+
<%= link_to_with_icon 'save.svg', Spree.t('actions.save'), "#", class: 'save-item btn btn-success btn-sm', data: {'shipment-number' => shipment.number, 'variant-id' => item.variant.id, action: 'save'}, title: Spree.t('actions.save'), style: 'display: none', no_text: true %>
|
39
|
+
<%= link_to_with_icon 'split.svg', Spree.t('split'), "#", class: 'split-item btn btn-outline-secondary btn-sm', data: {action: 'split', 'variant-id' => item.variant.id}, title: Spree.t('split'), no_text: true %>
|
40
|
+
<%= link_to_with_icon 'delete.svg', Spree.t('delete'), "#", class: 'delete-item btn btn-danger btn-sm', data: { 'shipment-number' => shipment.number, 'variant-id' => item.variant.id, action: 'remove'}, title: Spree.t('delete'), no_text: true %>
|
41
41
|
<% end %>
|
42
42
|
</td>
|
43
43
|
</tr>
|
@@ -9,10 +9,10 @@
|
|
9
9
|
<% end %>
|
10
10
|
</div>
|
11
11
|
<div class="form-actions" data-hook="buttons">
|
12
|
-
<%= button Spree.t('actions.update'), '
|
12
|
+
<%= button Spree.t('actions.update'), 'recycle.svg', 'submit', {class: 'btn-success', data: { disable_with: "#{ Spree.t(:saving) }..." }} %>
|
13
13
|
<span class="or"><%= Spree.t(:or) %></span>
|
14
|
-
<%= button_link_to Spree.t('actions.cancel'), edit_admin_order_url(order), icon: '
|
14
|
+
<%= button_link_to Spree.t('actions.cancel'), edit_admin_order_url(order), icon: 'cancel.svg' %>
|
15
15
|
</div>
|
16
16
|
<fieldset>
|
17
17
|
<% end %>
|
18
|
-
</div>
|
18
|
+
</div>
|
@@ -6,7 +6,7 @@
|
|
6
6
|
<%= button_link_to Spree.t(:new_order),
|
7
7
|
new_admin_order_url,
|
8
8
|
class: "btn-success",
|
9
|
-
icon: 'add',
|
9
|
+
icon: 'add.svg',
|
10
10
|
id: 'admin_new_order' %>
|
11
11
|
<% end if can? :create, Spree::Order %>
|
12
12
|
|
@@ -14,161 +14,161 @@
|
|
14
14
|
<div data-hook="admin_orders_index_search">
|
15
15
|
|
16
16
|
<%= search_form_for [:admin, @search] do |f| %>
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
17
|
+
<div class="row">
|
18
|
+
|
19
|
+
<div class="date-range-filter col-12 col-lg-8">
|
20
|
+
<div class="form-group">
|
21
|
+
<%= label_tag :q_created_at_gt, Spree.t(:date_range) %>
|
22
|
+
<div class="row pb-0">
|
23
|
+
<div class="col-12 col-md-6 mb-3 mb-md-0">
|
24
|
+
<div class="input-group datePickerFrom"
|
25
|
+
data-wrap="true"
|
26
|
+
data-max-date="<%= params[:q][:created_at_lt] %>">
|
27
|
+
<%= f.text_field :created_at_gt,
|
28
|
+
class: 'form-control js-filterable shadow-none',
|
29
|
+
value: params[:q][:created_at_gt],
|
30
|
+
placeholder: Spree.t(:starting_from),
|
31
|
+
'data-input':'' %>
|
32
|
+
|
33
|
+
<%= render partial: 'spree/admin/shared/cal_close' %>
|
35
34
|
</div>
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
35
|
+
</div>
|
36
|
+
<div class="col-12 col-md-6 mt-3 mt-md-0">
|
37
|
+
<div class="input-group datePickerTo"
|
38
|
+
data-wrap="true"
|
39
|
+
data-min-date="<%= params[:q][:created_at_gt] %>">
|
40
|
+
|
41
|
+
<%= f.text_field :created_at_lt,
|
42
|
+
class: 'form-control js-filterable shadow-none',
|
43
|
+
value: params[:q][:created_at_lt],
|
44
|
+
placeholder: Spree.t(:ending_at),
|
45
|
+
'data-input':'' %>
|
46
|
+
|
47
|
+
<%= render partial: 'spree/admin/shared/cal_close' %>
|
47
48
|
</div>
|
48
|
-
</div>
|
49
49
|
</div>
|
50
50
|
</div>
|
51
51
|
</div>
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
</div>
|
52
|
+
</div>
|
53
|
+
<div class="col-12 col-lg-4">
|
54
|
+
<div class="form-group">
|
55
|
+
<%= label_tag :q_number_cont, Spree.t(:order_number, number: '') %>
|
56
|
+
<%= f.text_field :number_cont, class: 'form-control js-quick-search-target js-filterable' %>
|
58
57
|
</div>
|
59
|
-
|
60
58
|
</div>
|
61
59
|
|
62
|
-
|
60
|
+
</div>
|
63
61
|
|
64
|
-
|
65
|
-
<div class="form-group">
|
66
|
-
<%= label_tag :q_state_eq, Spree.t(:status) %>
|
67
|
-
<%= f.select :state_eq,
|
68
|
-
Spree::Order.state_machines[:state].states.map {|s| [Spree.t("order_state.#{s.name}"), s.value]},
|
69
|
-
{ include_blank: true },
|
70
|
-
class: 'select2 js-filterable' %>
|
71
|
-
</div>
|
72
|
-
</div>
|
62
|
+
<div class="row">
|
73
63
|
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
64
|
+
<div class="col-12 col-lg-4">
|
65
|
+
<div class="form-group">
|
66
|
+
<%= label_tag :q_state_eq, Spree.t(:status) %>
|
67
|
+
<%= f.select :state_eq,
|
68
|
+
Spree::Order.state_machines[:state].states.map {|s| [Spree.t("order_state.#{s.name}"), s.value]},
|
69
|
+
{ include_blank: true },
|
70
|
+
class: 'select2 js-filterable' %>
|
79
71
|
</div>
|
72
|
+
</div>
|
80
73
|
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
</div>
|
74
|
+
<div class="col-12 col-lg-4">
|
75
|
+
<div class="form-group">
|
76
|
+
<%= label_tag :q_payment_state_eq, Spree.t(:payment_state) %>
|
77
|
+
<%= f.select :payment_state_eq, Spree::Order::PAYMENT_STATES.map {|s| [Spree.t("payment_states.#{s}"), s]}, { include_blank: true }, class: 'select2 js-filterable' %>
|
86
78
|
</div>
|
79
|
+
</div>
|
87
80
|
|
81
|
+
<div class="col-12 col-lg-4">
|
82
|
+
<div class="form-group">
|
83
|
+
<%= label_tag :q_shipment_state_eq, Spree.t(:shipment_state) %>
|
84
|
+
<%= f.select :shipment_state_eq, Spree::Order::SHIPMENT_STATES.map {|s| [Spree.t("shipment_states.#{s}"), s]}, { include_blank: true }, class: 'select2 js-filterable' %>
|
85
|
+
</div>
|
88
86
|
</div>
|
89
87
|
|
90
|
-
|
88
|
+
</div>
|
91
89
|
|
92
|
-
|
93
|
-
<div class="form-group">
|
94
|
-
<%= label_tag :q_bill_address_firstname_start, Spree.t(:first_name_begins_with) %>
|
95
|
-
<%= f.text_field :bill_address_firstname_start, class: 'form-control js-filterable' %>
|
96
|
-
</div>
|
97
|
-
</div>
|
90
|
+
<div class="row">
|
98
91
|
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
</div>
|
92
|
+
<div class="col-12 col-lg-4">
|
93
|
+
<div class="form-group">
|
94
|
+
<%= label_tag :q_bill_address_firstname_start, Spree.t(:first_name_begins_with) %>
|
95
|
+
<%= f.text_field :bill_address_firstname_start, class: 'form-control js-filterable' %>
|
104
96
|
</div>
|
97
|
+
</div>
|
105
98
|
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
</div>
|
99
|
+
<div class="col-12 col-lg-4">
|
100
|
+
<div class="form-group">
|
101
|
+
<%= label_tag :q_bill_address_lastname_start, Spree.t(:last_name_begins_with) %>
|
102
|
+
<%= f.text_field :bill_address_lastname_start, class: 'form-control js-filterable' %>
|
111
103
|
</div>
|
104
|
+
</div>
|
112
105
|
|
106
|
+
<div class="col-12 col-lg-4">
|
107
|
+
<div class="form-group">
|
108
|
+
<%= label_tag :q_email_cont, Spree.t(:email) %>
|
109
|
+
<%= f.text_field :email_cont, class: 'form-control js-filterable' %>
|
110
|
+
</div>
|
113
111
|
</div>
|
114
112
|
|
115
|
-
|
113
|
+
</div>
|
116
114
|
|
117
|
-
|
118
|
-
<div class="form-group">
|
119
|
-
<%= label_tag :q_line_items_variant_sku_eq, Spree.t(:sku) %>
|
120
|
-
<%= f.text_field :line_items_variant_sku_eq, class: 'form-control js-filterable' %>
|
121
|
-
</div>
|
122
|
-
</div>
|
115
|
+
<div class="row">
|
123
116
|
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
</div>
|
117
|
+
<div class="col-12 col-lg-4">
|
118
|
+
<div class="form-group">
|
119
|
+
<%= label_tag :q_line_items_variant_sku_eq, Spree.t(:sku) %>
|
120
|
+
<%= f.text_field :line_items_variant_sku_eq, class: 'form-control js-filterable' %>
|
129
121
|
</div>
|
122
|
+
</div>
|
130
123
|
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
|
135
|
-
</div>
|
124
|
+
<div class="col-12 col-lg-4">
|
125
|
+
<div class="form-group">
|
126
|
+
<%= label_tag :q_promotions_id_in, Spree.t(:promotion) %>
|
127
|
+
<%= f.select :promotions_id_in, Spree::Promotion.applied.pluck(:name, :id), { include_blank: true }, class: 'select2 js-filterable' %>
|
136
128
|
</div>
|
129
|
+
</div>
|
137
130
|
|
138
|
-
|
139
|
-
|
140
|
-
|
141
|
-
|
142
|
-
</div>
|
131
|
+
<div class="col-12 col-lg-4">
|
132
|
+
<div class="form-group">
|
133
|
+
<%= label_tag :q_store_id_in, Spree.t(:store) %>
|
134
|
+
<%= f.select :store_id_in, Spree::Store.order(:name).pluck(:name, :id), { include_blank: true }, class: 'select2 js-filterable' %>
|
143
135
|
</div>
|
136
|
+
</div>
|
144
137
|
|
145
|
-
|
138
|
+
<div class="col-12 col-lg-4">
|
139
|
+
<div class="form-group">
|
140
|
+
<%= label_tag :q_channel_eq, Spree.t(:channel) %>
|
141
|
+
<%= f.select :channel_eq, Spree::Order.distinct.pluck(:channel), { include_blank: true }, class: 'select2 js-filterable' %>
|
142
|
+
</div>
|
143
|
+
</div>
|
146
144
|
|
147
|
-
|
145
|
+
<div class="col-12 col-lg-4">
|
148
146
|
|
149
|
-
|
150
|
-
<%= label_tag 'q_completed_at_not_null' do %>
|
151
|
-
<%= f.check_box :completed_at_not_null, {checked: @show_only_completed}, '1', '0' %>
|
152
|
-
<%= Spree.t(:show_only_complete_orders) %>
|
153
|
-
<% end %>
|
154
|
-
</div>
|
147
|
+
<div class="form-group">
|
155
148
|
|
156
|
-
|
157
|
-
|
158
|
-
|
159
|
-
|
160
|
-
|
161
|
-
|
149
|
+
<div class="checkbox mt-2">
|
150
|
+
<%= label_tag 'q_completed_at_not_null' do %>
|
151
|
+
<%= f.check_box :completed_at_not_null, {checked: @show_only_completed}, '1', '0' %>
|
152
|
+
<%= Spree.t(:show_only_complete_orders) %>
|
153
|
+
<% end %>
|
154
|
+
</div>
|
162
155
|
|
156
|
+
<div class="checkbox mt-2">
|
157
|
+
<%= label_tag 'q_considered_risky_eq' do %>
|
158
|
+
<%= f.check_box :considered_risky_eq, {checked: (params[:q][:considered_risky_eq] == '1')}, '1', '' %>
|
159
|
+
<%= Spree.t(:show_only_considered_risky) %>
|
160
|
+
<% end %>
|
163
161
|
</div>
|
164
162
|
|
165
163
|
</div>
|
166
164
|
|
167
165
|
</div>
|
168
166
|
|
169
|
-
|
170
|
-
|
171
|
-
|
167
|
+
</div>
|
168
|
+
|
169
|
+
<div data-hook="admin_orders_index_search_buttons" class="form-actions">
|
170
|
+
<%= button Spree.t(:filter_results), 'search.svg' %>
|
171
|
+
</div>
|
172
172
|
|
173
173
|
<% end %>
|
174
174
|
|
@@ -176,18 +176,17 @@
|
|
176
176
|
|
177
177
|
<% end %>
|
178
178
|
|
179
|
-
<%= render 'spree/admin/shared/index_table_options', collection: @orders %>
|
180
|
-
|
181
179
|
<% if @orders.any? %>
|
180
|
+
<div class="table-responsive">
|
182
181
|
<table class="table" id="listing_orders" data-hook>
|
183
182
|
<thead>
|
184
183
|
<tr data-hook="admin_orders_index_headers">
|
184
|
+
<th><%= sort_link @search, :number, I18n.t(:number, scope: 'activerecord.attributes.spree/order') %></th>
|
185
185
|
<% if @show_only_completed %>
|
186
186
|
<th><%= sort_link @search, :completed_at, I18n.t(:completed_at, scope: 'activerecord.attributes.spree/order') %></th>
|
187
187
|
<% else %>
|
188
188
|
<th><%= sort_link @search, :created_at, I18n.t(:created_at, scope: 'activerecord.attributes.spree/order') %></th>
|
189
189
|
<% end %>
|
190
|
-
<th><%= sort_link @search, :number, I18n.t(:number, scope: 'activerecord.attributes.spree/order') %></th>
|
191
190
|
<th><%= sort_link @search, :considered_risky, I18n.t(:considered_risky, scope: 'activerecord.attributes.spree/order') %></th>
|
192
191
|
<th><%= sort_link @search, :state, I18n.t(:state, scope: 'activerecord.attributes.spree/order') %></th>
|
193
192
|
<th><%= sort_link @search, :payment_state, I18n.t(:payment_state, scope: 'activerecord.attributes.spree/order') %></th>
|
@@ -202,47 +201,55 @@
|
|
202
201
|
<tbody>
|
203
202
|
<% @orders.each do |order| %>
|
204
203
|
<tr data-hook="admin_orders_index_rows" class="state-<%= order.state.downcase %> <%= cycle('odd', 'even') %>">
|
204
|
+
<td><%= link_to order.number, edit_admin_order_path(order) %></td>
|
205
205
|
<td>
|
206
206
|
<%= order_time(@show_only_completed ? order.completed_at : order.created_at) %>
|
207
207
|
</td>
|
208
|
-
<td><%= link_to order.number, edit_admin_order_path(order) %></td>
|
209
208
|
<td>
|
210
209
|
<span class="badge badge-<%= order.considered_risky ? 'considered_risky' : 'considered_safe' %>">
|
211
210
|
<%= order.considered_risky ? Spree.t("risky") : Spree.t("safe") %>
|
212
211
|
</span>
|
213
212
|
</td>
|
214
|
-
<td>
|
213
|
+
<td class="no-wrap">
|
215
214
|
<span class="badge badge-<%= order.state.downcase %>"><%= Spree.t("order_state.#{order.state.downcase}") %></span>
|
216
|
-
<span class="
|
215
|
+
<span class="filterable js-add-filter" data-ransack-field="q_state_eq" data-ransack-value="<%= order.state %>">
|
216
|
+
<%= svg_icon name: "filter.svg", width: '14', height: '14' %>
|
217
|
+
</span>
|
217
218
|
</td>
|
218
|
-
<td>
|
219
|
+
<td class="no-wrap">
|
219
220
|
<% if order.payment_state %>
|
220
221
|
|
221
222
|
<%= link_to Spree.t("payment_states.#{order.payment_state}"),
|
222
223
|
admin_order_payments_path(order),
|
223
224
|
class: "badge badge-#{order.payment_state}" %>
|
224
225
|
|
225
|
-
<span class="
|
226
|
+
<span class="filterable js-add-filter"
|
226
227
|
data-ransack-field="q_payment_state_eq"
|
227
|
-
data-ransack-value="<%= order.payment_state %>"
|
228
|
+
data-ransack-value="<%= order.payment_state %>">
|
229
|
+
<%= svg_icon name: "filter.svg", width: '14', height: '14' %>
|
230
|
+
</span>
|
228
231
|
<% end %>
|
229
232
|
</td>
|
230
233
|
<% if Spree::Order.checkout_step_names.include?(:delivery) %>
|
231
|
-
<td>
|
234
|
+
<td class="no-wrap">
|
232
235
|
<% if order.shipment_state %>
|
233
236
|
<span class="badge badge-<%= order.shipment_state %>"><%= Spree.t("shipment_states.#{order.shipment_state}") %></span>
|
234
|
-
<span class="
|
237
|
+
<span class="filterable js-add-filter" data-ransack-field="q_shipment_state_eq" data-ransack-value="<%= order.shipment_state %>">
|
238
|
+
<%= svg_icon name: "filter.svg", width: '14', height: '14' %>
|
239
|
+
</span>
|
235
240
|
<% end %>
|
236
241
|
</td>
|
237
242
|
<% end %>
|
238
|
-
<td>
|
243
|
+
<td class="no-wrap">
|
239
244
|
<% if order.user %>
|
240
245
|
<%= link_to order.email, edit_admin_user_path(order.user) %>
|
241
246
|
<% else %>
|
242
247
|
<%= mail_to order.email %>
|
243
248
|
<% end %>
|
244
249
|
<% if order.user || order.email %>
|
245
|
-
<span class="
|
250
|
+
<span class="filterable js-add-filter" data-ransack-field="q_email_cont" data-ransack-value="<%= order.email %>">
|
251
|
+
<%= svg_icon name: "filter.svg", width: '14', height: '14' %>
|
252
|
+
</span>
|
246
253
|
<% end %>
|
247
254
|
</td>
|
248
255
|
<td><%= order.display_total.to_html %></td>
|
@@ -253,6 +260,7 @@
|
|
253
260
|
<% end %>
|
254
261
|
</tbody>
|
255
262
|
</table>
|
263
|
+
</div>
|
256
264
|
<% else %>
|
257
265
|
<div class="alert alert-info no-objects-found">
|
258
266
|
<%= Spree.t(:no_resource_found, resource: plural_resource_name(Spree::Order)) %>,
|