solidus_backend 4.5.1 → 4.6.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
 - data/app/assets/javascripts/spree/backend/option_value_picker.js +1 -0
 - data/app/assets/javascripts/spree/backend/product_picker.js +1 -0
 - data/app/assets/javascripts/spree/backend/taxon_autocomplete.js +1 -0
 - data/app/assets/javascripts/spree/backend/views/order/address.js +1 -1
 - data/app/views/spree/admin/payments/_list.html.erb +10 -6
 - data/app/views/spree/admin/search/users.json.jbuilder +4 -1
 - data/app/views/spree/admin/shared/_address.html.erb +2 -0
 - data/app/views/spree/admin/shared/_address_form.html.erb +20 -0
 - data/app/views/spree/admin/stores/_form.html.erb +11 -0
 - data/lib/spree/backend_configuration.rb +4 -0
 - metadata +7 -7
 
    
        checksums.yaml
    CHANGED
    
    | 
         @@ -1,7 +1,7 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            ---
         
     | 
| 
       2 
2 
     | 
    
         
             
            SHA256:
         
     | 
| 
       3 
     | 
    
         
            -
              metadata.gz:  
     | 
| 
       4 
     | 
    
         
            -
              data.tar.gz:  
     | 
| 
      
 3 
     | 
    
         
            +
              metadata.gz: c65304083db4c655a29d3e3023906e338d6274067f157482657e7a979ca60fac
         
     | 
| 
      
 4 
     | 
    
         
            +
              data.tar.gz: 22389566c4aa44ea193beeed9e65db2d64c46f0d5b8290a07594e2520c8d7f8b
         
     | 
| 
       5 
5 
     | 
    
         
             
            SHA512:
         
     | 
| 
       6 
     | 
    
         
            -
              metadata.gz:  
     | 
| 
       7 
     | 
    
         
            -
              data.tar.gz:  
     | 
| 
      
 6 
     | 
    
         
            +
              metadata.gz: 8afb0210b73fcf9ca01cf57ea761a1820f5156abd9c93dabe5dc5ee22866afc1db5c5263f85cb0627a3a4cc98bb7582f4e255f09aaf468f308d74bd97e85cf41
         
     | 
| 
      
 7 
     | 
    
         
            +
              data.tar.gz: 669532feea711782cf622022d99de0a12317a994601f50320025c0f3d174131b1ec19f8f89de5b727c0c60da351b7d6d2090dc3d9b288e3d5de8aa1a8b9f95f9
         
     | 
| 
         @@ -23,6 +23,7 @@ $.fn.optionValueAutocomplete = function (options) { 
     | 
|
| 
       23 
23 
     | 
    
         
             
                },
         
     | 
| 
       24 
24 
     | 
    
         
             
                ajax: {
         
     | 
| 
       25 
25 
     | 
    
         
             
                  url: Spree.pathFor('api/option_values'),
         
     | 
| 
      
 26 
     | 
    
         
            +
                  quietMillis: 500,
         
     | 
| 
       26 
27 
     | 
    
         
             
                  datatype: 'json',
         
     | 
| 
       27 
28 
     | 
    
         
             
                  data: function (term, page) {
         
     | 
| 
       28 
29 
     | 
    
         
             
                    var productId = typeof(productSelect) !== 'undefined' ? $(productSelect).select2('val') : null;
         
     | 
| 
         @@ -35,6 +35,7 @@ $.fn.productAutocomplete = function (options) { 
     | 
|
| 
       35 
35 
     | 
    
         
             
              this.select2({
         
     | 
| 
       36 
36 
     | 
    
         
             
                minimumInputLength: 3,
         
     | 
| 
       37 
37 
     | 
    
         
             
                multiple: multiple,
         
     | 
| 
      
 38 
     | 
    
         
            +
                quietMillis: 500,
         
     | 
| 
       38 
39 
     | 
    
         
             
                initSelection: function (element, callback) {
         
     | 
| 
       39 
40 
     | 
    
         
             
                  $.get(Spree.pathFor('admin/search/products'), {
         
     | 
| 
       40 
41 
     | 
    
         
             
                    ids: element.val().split(','),
         
     | 
| 
         @@ -24,7 +24,7 @@ Spree.Views.Order.Address = Backbone.View.extend({ 
     | 
|
| 
       24 
24 
     | 
    
         
             
              eachField: function(callback){
         
     | 
| 
       25 
25 
     | 
    
         
             
                var view = this;
         
     | 
| 
       26 
26 
     | 
    
         
             
                var fields = ["name", "company", "address1", "address2",
         
     | 
| 
       27 
     | 
    
         
            -
                  "city", "zipcode", "phone", "country_id", "state_name"];
         
     | 
| 
      
 27 
     | 
    
         
            +
                  "city", "zipcode", "phone", "country_id", "state_name", "vat_id", "email", "reverse_charge_status"];
         
     | 
| 
       28 
28 
     | 
    
         
             
                _.each(fields, function(field) {
         
     | 
| 
       29 
29 
     | 
    
         
             
                  var el = view.$('[name$="[' + field + ']"]');
         
     | 
| 
       30 
30 
     | 
    
         
             
                  if (el.length) callback(field, el);
         
     | 
| 
         @@ -56,15 +56,19 @@ 
     | 
|
| 
       56 
56 
     | 
    
         
             
                      </div>
         
     | 
| 
       57 
57 
     | 
    
         
             
                      <div class="editing-hide">
         
     | 
| 
       58 
58 
     | 
    
         
             
                        <% if payment.pending? %>
         
     | 
| 
       59 
     | 
    
         
            -
                          <%= link_to_with_icon 'edit', t('spree.actions.edit'), nil, no_text: true, class: "js-edit", data: {action: 'edit'} %>
         
     | 
| 
      
 59 
     | 
    
         
            +
                          <%= link_to_with_icon 'edit', t('spree.actions.edit'), nil, no_text: true, class: "js-edit", data: { action: 'edit' } %>
         
     | 
| 
       60 
60 
     | 
    
         
             
                        <% end %>
         
     | 
| 
       61 
     | 
    
         
            -
                        <%  
     | 
| 
       62 
     | 
    
         
            -
             
     | 
| 
      
 61 
     | 
    
         
            +
                        <% payment.actions.each do |action| %>
         
     | 
| 
      
 62 
     | 
    
         
            +
                          <% next unless can?(action.to_sym, payment) %>
         
     | 
| 
      
 63 
     | 
    
         
            +
             
     | 
| 
       63 
64 
     | 
    
         
             
                          <% if action == 'credit' %>
         
     | 
| 
       64 
     | 
    
         
            -
                             
     | 
| 
       65 
     | 
    
         
            -
             
     | 
| 
       66 
     | 
    
         
            -
                             
     | 
| 
      
 65 
     | 
    
         
            +
                            <% next if payment.invalid? || payment.failed? || payment.checkout? %>
         
     | 
| 
      
 66 
     | 
    
         
            +
             
     | 
| 
      
 67 
     | 
    
         
            +
                            <%= link_to_with_icon 'reply', t('spree.refund'), new_admin_order_payment_refund_path(@order, payment), no_text: true %>
         
     | 
| 
       67 
68 
     | 
    
         
             
                          <% else %>
         
     | 
| 
      
 69 
     | 
    
         
            +
                            <% next if action == 'capture' && !@order.completed? %>
         
     | 
| 
      
 70 
     | 
    
         
            +
                            <% next if action == 'void' && (payment.invalid? || payment.failed?) %>
         
     | 
| 
      
 71 
     | 
    
         
            +
             
     | 
| 
       68 
72 
     | 
    
         
             
                            <%= link_to_with_icon action, t(action, scope: 'spree'), fire_admin_order_payment_path(@order, payment, e: action), method: :put, no_text: true, data: {action: action} %>
         
     | 
| 
       69 
73 
     | 
    
         
             
                          <% end %>
         
     | 
| 
       70 
74 
     | 
    
         
             
                        <% end %>
         
     | 
| 
         @@ -1,6 +1,8 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            <div data-hook="address">
         
     | 
| 
       2 
2 
     | 
    
         
             
              <%= address.name %> <%= address.company unless address.company.blank? %><br>
         
     | 
| 
       3 
3 
     | 
    
         
             
              <%= address.phone %><%= address.alternative_phone unless address.alternative_phone.blank? %><br>
         
     | 
| 
      
 4 
     | 
    
         
            +
              <%= address.email unless address.email.blank? %><br>
         
     | 
| 
      
 5 
     | 
    
         
            +
              <%= address.vat_id unless address.vat_id.blank? %><br>
         
     | 
| 
       4 
6 
     | 
    
         
             
              <%= address.address1 %><br>
         
     | 
| 
       5 
7 
     | 
    
         
             
              <% if address.address2.present? %><%= address.address2 %><br><% end %>
         
     | 
| 
       6 
8 
     | 
    
         
             
              <%= "#{address.city}, #{address.state_text}, #{address.zipcode}" %><br>
         
     | 
| 
         @@ -63,4 +63,24 @@ 
     | 
|
| 
       63 
63 
     | 
    
         
             
                <%= f.label :phone %>
         
     | 
| 
       64 
64 
     | 
    
         
             
                <%= f.phone_field :phone, class: 'fullwidth' %>
         
     | 
| 
       65 
65 
     | 
    
         
             
              </div>
         
     | 
| 
      
 66 
     | 
    
         
            +
             
     | 
| 
      
 67 
     | 
    
         
            +
              <div class="field <%= "#{type}-row" %>">
         
     | 
| 
      
 68 
     | 
    
         
            +
                <%= f.label :email %>
         
     | 
| 
      
 69 
     | 
    
         
            +
                <%= f.email_field :email, class: 'fullwidth' %>
         
     | 
| 
      
 70 
     | 
    
         
            +
              </div>
         
     | 
| 
      
 71 
     | 
    
         
            +
              
         
     | 
| 
      
 72 
     | 
    
         
            +
              <% if Spree::Backend::Config.show_reverse_charge_fields %>
         
     | 
| 
      
 73 
     | 
    
         
            +
                <div class="field <%= "#{type}-row" %>">
         
     | 
| 
      
 74 
     | 
    
         
            +
                  <%= f.label :vat_id %>
         
     | 
| 
      
 75 
     | 
    
         
            +
                  <%= f.text_field :vat_id, class: 'fullwidth' %>
         
     | 
| 
      
 76 
     | 
    
         
            +
                </div>
         
     | 
| 
      
 77 
     | 
    
         
            +
             
     | 
| 
      
 78 
     | 
    
         
            +
                <div class="field <%= "#{type}-row" %>">
         
     | 
| 
      
 79 
     | 
    
         
            +
                  <%= f.label :reverse_charge_status %>
         
     | 
| 
      
 80 
     | 
    
         
            +
                  <%= f.select :reverse_charge_status,
         
     | 
| 
      
 81 
     | 
    
         
            +
                      Spree::Address.reverse_charge_statuses.keys.map { |key| [I18n.t("spree.reverse_charge_statuses.#{key}"), key] },
         
     | 
| 
      
 82 
     | 
    
         
            +
                      { include_blank: false },
         
     | 
| 
      
 83 
     | 
    
         
            +
                      { class: 'custom-select fullwidth' } %>
         
     | 
| 
      
 84 
     | 
    
         
            +
                </div>
         
     | 
| 
      
 85 
     | 
    
         
            +
              <% end %>
         
     | 
| 
       66 
86 
     | 
    
         
             
            </div>
         
     | 
| 
         @@ -30,6 +30,17 @@ 
     | 
|
| 
       30 
30 
     | 
    
         
             
                  <%= f.text_area :meta_description, class: 'fullwidth' %>
         
     | 
| 
       31 
31 
     | 
    
         
             
                  <%= f.error_message_on :meta_description %>
         
     | 
| 
       32 
32 
     | 
    
         
             
                <% end %>
         
     | 
| 
      
 33 
     | 
    
         
            +
             
     | 
| 
      
 34 
     | 
    
         
            +
                <% if Spree::Backend::Config.show_reverse_charge_fields %>
         
     | 
| 
      
 35 
     | 
    
         
            +
                  <%= f.field_container :reverse_charge_status do %>
         
     | 
| 
      
 36 
     | 
    
         
            +
                    <%= f.label :reverse_charge_status %>
         
     | 
| 
      
 37 
     | 
    
         
            +
                    <%= f.select :reverse_charge_status,
         
     | 
| 
      
 38 
     | 
    
         
            +
                      Spree::Store.reverse_charge_statuses.keys.map { |key| [I18n.t("spree.reverse_charge_statuses.#{key}"), key] },
         
     | 
| 
      
 39 
     | 
    
         
            +
                      { include_blank: false },
         
     | 
| 
      
 40 
     | 
    
         
            +
                      { class: 'custom-select fullwidth' } %>
         
     | 
| 
      
 41 
     | 
    
         
            +
                    <%= f.error_message_on :reverse_charge_status %>
         
     | 
| 
      
 42 
     | 
    
         
            +
                  <% end %>
         
     | 
| 
      
 43 
     | 
    
         
            +
                <% end %>
         
     | 
| 
       33 
44 
     | 
    
         
             
              </div>
         
     | 
| 
       34 
45 
     | 
    
         
             
              <div class="col-12 col-md-6">
         
     | 
| 
       35 
46 
     | 
    
         
             
                <%= f.field_container :url do %>
         
     | 
| 
         @@ -19,6 +19,10 @@ module Spree 
     | 
|
| 
       19 
19 
     | 
    
         
             
                  solidus_admin: 'spree/backend/themes/solidus_admin'
         
     | 
| 
       20 
20 
     | 
    
         
             
                }
         
     | 
| 
       21 
21 
     | 
    
         | 
| 
      
 22 
     | 
    
         
            +
                # @!attribute [rw] show_reverse_charge_fields
         
     | 
| 
      
 23 
     | 
    
         
            +
                #   @return [Boolean] Request reverse charge fields. (default: +false+)
         
     | 
| 
      
 24 
     | 
    
         
            +
                preference :show_reverse_charge_fields, :boolean, default: false
         
     | 
| 
      
 25 
     | 
    
         
            +
             
     | 
| 
       22 
26 
     | 
    
         
             
                preference :search_fields, :hash, default: {
         
     | 
| 
       23 
27 
     | 
    
         
             
                  "spree/admin/orders" => [
         
     | 
| 
       24 
28 
     | 
    
         
             
                    {
         
     | 
    
        metadata
    CHANGED
    
    | 
         @@ -1,13 +1,13 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            --- !ruby/object:Gem::Specification
         
     | 
| 
       2 
2 
     | 
    
         
             
            name: solidus_backend
         
     | 
| 
       3 
3 
     | 
    
         
             
            version: !ruby/object:Gem::Version
         
     | 
| 
       4 
     | 
    
         
            -
              version: 4. 
     | 
| 
      
 4 
     | 
    
         
            +
              version: 4.6.1
         
     | 
| 
       5 
5 
     | 
    
         
             
            platform: ruby
         
     | 
| 
       6 
6 
     | 
    
         
             
            authors:
         
     | 
| 
       7 
7 
     | 
    
         
             
            - Solidus Team
         
     | 
| 
       8 
8 
     | 
    
         
             
            bindir: bin
         
     | 
| 
       9 
9 
     | 
    
         
             
            cert_chain: []
         
     | 
| 
       10 
     | 
    
         
            -
            date:  
     | 
| 
      
 10 
     | 
    
         
            +
            date: 1980-01-02 00:00:00.000000000 Z
         
     | 
| 
       11 
11 
     | 
    
         
             
            dependencies:
         
     | 
| 
       12 
12 
     | 
    
         
             
            - !ruby/object:Gem::Dependency
         
     | 
| 
       13 
13 
     | 
    
         
             
              name: solidus_api
         
     | 
| 
         @@ -15,28 +15,28 @@ dependencies: 
     | 
|
| 
       15 
15 
     | 
    
         
             
                requirements:
         
     | 
| 
       16 
16 
     | 
    
         
             
                - - '='
         
     | 
| 
       17 
17 
     | 
    
         
             
                  - !ruby/object:Gem::Version
         
     | 
| 
       18 
     | 
    
         
            -
                    version: 4. 
     | 
| 
      
 18 
     | 
    
         
            +
                    version: 4.6.1
         
     | 
| 
       19 
19 
     | 
    
         
             
              type: :runtime
         
     | 
| 
       20 
20 
     | 
    
         
             
              prerelease: false
         
     | 
| 
       21 
21 
     | 
    
         
             
              version_requirements: !ruby/object:Gem::Requirement
         
     | 
| 
       22 
22 
     | 
    
         
             
                requirements:
         
     | 
| 
       23 
23 
     | 
    
         
             
                - - '='
         
     | 
| 
       24 
24 
     | 
    
         
             
                  - !ruby/object:Gem::Version
         
     | 
| 
       25 
     | 
    
         
            -
                    version: 4. 
     | 
| 
      
 25 
     | 
    
         
            +
                    version: 4.6.1
         
     | 
| 
       26 
26 
     | 
    
         
             
            - !ruby/object:Gem::Dependency
         
     | 
| 
       27 
27 
     | 
    
         
             
              name: solidus_core
         
     | 
| 
       28 
28 
     | 
    
         
             
              requirement: !ruby/object:Gem::Requirement
         
     | 
| 
       29 
29 
     | 
    
         
             
                requirements:
         
     | 
| 
       30 
30 
     | 
    
         
             
                - - '='
         
     | 
| 
       31 
31 
     | 
    
         
             
                  - !ruby/object:Gem::Version
         
     | 
| 
       32 
     | 
    
         
            -
                    version: 4. 
     | 
| 
      
 32 
     | 
    
         
            +
                    version: 4.6.1
         
     | 
| 
       33 
33 
     | 
    
         
             
              type: :runtime
         
     | 
| 
       34 
34 
     | 
    
         
             
              prerelease: false
         
     | 
| 
       35 
35 
     | 
    
         
             
              version_requirements: !ruby/object:Gem::Requirement
         
     | 
| 
       36 
36 
     | 
    
         
             
                requirements:
         
     | 
| 
       37 
37 
     | 
    
         
             
                - - '='
         
     | 
| 
       38 
38 
     | 
    
         
             
                  - !ruby/object:Gem::Version
         
     | 
| 
       39 
     | 
    
         
            -
                    version: 4. 
     | 
| 
      
 39 
     | 
    
         
            +
                    version: 4.6.1
         
     | 
| 
       40 
40 
     | 
    
         
             
            - !ruby/object:Gem::Dependency
         
     | 
| 
       41 
41 
     | 
    
         
             
              name: font-awesome-rails
         
     | 
| 
       42 
42 
     | 
    
         
             
              requirement: !ruby/object:Gem::Requirement
         
     | 
| 
         @@ -857,7 +857,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement 
     | 
|
| 
       857 
857 
     | 
    
         
             
                - !ruby/object:Gem::Version
         
     | 
| 
       858 
858 
     | 
    
         
             
                  version: 1.8.23
         
     | 
| 
       859 
859 
     | 
    
         
             
            requirements: []
         
     | 
| 
       860 
     | 
    
         
            -
            rubygems_version: 3.6. 
     | 
| 
      
 860 
     | 
    
         
            +
            rubygems_version: 3.6.9
         
     | 
| 
       861 
861 
     | 
    
         
             
            specification_version: 4
         
     | 
| 
       862 
862 
     | 
    
         
             
            summary: Admin interface for the Solidus e-commerce framework.
         
     | 
| 
       863 
863 
     | 
    
         
             
            test_files: []
         
     |