effective_orders 5.7.1 → 5.7.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/models/effective/order.rb +1 -1
- data/app/views/admin/orders/_form.html.haml +3 -2
- data/lib/effective_orders/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ccd5fb4a32b778af10466e4b8eab1fd40de1c9c7bf6033960ae1b72ea8254ea8
|
4
|
+
data.tar.gz: c32de9af51826855c96fc33364be02fb0c7efbeee78206de5268dd1636f388fe
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e191aad0d3e26a3f0f1f221c196e3351c269cd3f7dc19d21f77b45de3a8b52f65a6f5428099d376f59d9463d03720828c0634b1c3bea40aed482cc99e983e3c3
|
7
|
+
data.tar.gz: d97326c36979460db32c854ee210fdec62eb1ff21a2e344163040f66dff1cc163241ac344af41e4e58dae2a3e203aeaa77e244e755cd6e3c63df4fee8fdf277e
|
@@ -33,7 +33,7 @@ module Effective
|
|
33
33
|
accepts_nested_attributes_for :user, allow_destroy: false, update_only: true
|
34
34
|
|
35
35
|
has_many :order_items, -> { order(:id) }, inverse_of: :order, dependent: :delete_all
|
36
|
-
accepts_nested_attributes_for :order_items, allow_destroy:
|
36
|
+
accepts_nested_attributes_for :order_items, allow_destroy: true, reject_if: :all_blank
|
37
37
|
|
38
38
|
# Attributes
|
39
39
|
effective_resource do
|
@@ -1,9 +1,10 @@
|
|
1
1
|
= effective_form_with(model: [:admin, order], engine: true) do |f|
|
2
2
|
= f.hidden_field :user_type, value: (f.object.user || current_user).class.name
|
3
3
|
|
4
|
+
- ajax_url = (@select2_ajax_path || effective_resources.users_admin_select2_ajax_index_path) unless Rails.env.test?
|
5
|
+
|
4
6
|
= f.select :user_id, current_user.class.all, label: 'Buyer', required: true,
|
5
|
-
ajax_url:
|
6
|
-
hint: 'The user that should purchase this order.'
|
7
|
+
ajax_url: ajax_url, hint: 'The user that should purchase this order.'
|
7
8
|
|
8
9
|
= f.email_cc_field :cc, hint: "Cc the above on any emailed receipts or payment requests."
|
9
10
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: effective_orders
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 5.7.
|
4
|
+
version: 5.7.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Code and Effect
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-06-
|
11
|
+
date: 2022-06-27 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|