effective_orders 6.30.4 → 6.30.6
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/mailers/effective/orders_mailer.rb +6 -1
- data/app/models/effective/order.rb +17 -17
- data/config/effective_orders.rb +6 -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: 184e488ae56c8f57964bc8b95c69ac60be438c31ca305ca2e4dfe492eac77e1e
|
|
4
|
+
data.tar.gz: 4ecfd86a4e39a48e77f070a1daa97ef70765e28e1a10904f7d63958840fbb8ee
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 79821bd949e9a20a7b034ae7ac1cc7b9c9f900de93970a7de37086f5f4a312d8a78fb3cc14fffd829c02efed01c1e0f04cde42ff505a252c1d61c7a55d6307a4
|
|
7
|
+
data.tar.gz: 54a564990255816fec95ee3d5b92522aa2a2c0d45fb1606ba9a0921c5478a71daf62d799f22c6458b2f0606d4c889b7d02a51fe50ef0b4801b0ca1b035a982d6
|
|
@@ -17,8 +17,13 @@ module Effective
|
|
|
17
17
|
|
|
18
18
|
subject = subject_for(__method__, @order_email.subject, @order, opts)
|
|
19
19
|
headers = headers_for(@order, opts)
|
|
20
|
+
cc = @order_email.cc
|
|
20
21
|
|
|
21
|
-
|
|
22
|
+
if @order_email.event_registrants_cancelled?
|
|
23
|
+
cc = (Array(mailer_admin) + Array(cc)).map(&:presence).compact
|
|
24
|
+
end
|
|
25
|
+
|
|
26
|
+
mail(to: @order_email.to, cc: cc, subject: subject, **headers)
|
|
22
27
|
end
|
|
23
28
|
|
|
24
29
|
# Same as above but sent to admin
|
|
@@ -969,6 +969,23 @@ module Effective
|
|
|
969
969
|
"#{value.to_s.first(8)}...#{value.to_s.last(4)}" if attribute == :delayed_payment_intent && value.present?
|
|
970
970
|
end
|
|
971
971
|
|
|
972
|
+
# Organization first
|
|
973
|
+
def assign_billing_name
|
|
974
|
+
owner = (organization || user)
|
|
975
|
+
|
|
976
|
+
assign_attributes(
|
|
977
|
+
billing_name: owner.to_s.presence,
|
|
978
|
+
billing_first_name: owner.try(:first_name).presence,
|
|
979
|
+
billing_last_name: owner.try(:last_name).presence
|
|
980
|
+
)
|
|
981
|
+
end
|
|
982
|
+
|
|
983
|
+
# User first
|
|
984
|
+
def assign_billing_email
|
|
985
|
+
email = emails.first
|
|
986
|
+
assign_attributes(email: email) if email.present?
|
|
987
|
+
end
|
|
988
|
+
|
|
972
989
|
protected
|
|
973
990
|
|
|
974
991
|
def get_subtotal
|
|
@@ -1094,23 +1111,6 @@ module Effective
|
|
|
1094
1111
|
order_items.reject { |oi| oi.marked_for_destruction? }
|
|
1095
1112
|
end
|
|
1096
1113
|
|
|
1097
|
-
# Organization first
|
|
1098
|
-
def assign_billing_name
|
|
1099
|
-
owner = (organization || user)
|
|
1100
|
-
|
|
1101
|
-
assign_attributes(
|
|
1102
|
-
billing_name: owner.to_s.presence,
|
|
1103
|
-
billing_first_name: owner.try(:first_name).presence,
|
|
1104
|
-
billing_last_name: owner.try(:last_name).presence
|
|
1105
|
-
)
|
|
1106
|
-
end
|
|
1107
|
-
|
|
1108
|
-
# User first
|
|
1109
|
-
def assign_billing_email
|
|
1110
|
-
email = emails.first
|
|
1111
|
-
assign_attributes(email: email) if email.present?
|
|
1112
|
-
end
|
|
1113
|
-
|
|
1114
1114
|
def assign_organization_address
|
|
1115
1115
|
return unless organization.present?
|
|
1116
1116
|
|
data/config/effective_orders.rb
CHANGED
|
@@ -56,9 +56,13 @@ EffectiveOrders.setup do |config|
|
|
|
56
56
|
config.tax_label = "Tax"
|
|
57
57
|
|
|
58
58
|
# Credit Card Surcharge
|
|
59
|
-
#
|
|
60
|
-
# Use 2.4 for 2.4% or nil for none
|
|
59
|
+
# Effective Orders will add a credit card surcharge to the order based off the after-tax total and charge the increased amount.
|
|
60
|
+
# Use 2.4 for 2.4% or nil for none.
|
|
61
|
+
# Cannot be used with Helcim EffectiveOrders.fee_saver? where the payment processor adds a convenience fee instead
|
|
61
62
|
config.credit_card_surcharge_percent = nil
|
|
63
|
+
|
|
64
|
+
# This is the item name for Quickbooks Online
|
|
65
|
+
# Used for EffectiveOrders.surcharge? (there is a credit_card_surcharge_percentage above) and when EffectiveOrders.fee_saver? (there is a helcim fee saver order)
|
|
62
66
|
config.credit_card_surcharge_qb_item_name = nil # 'Credit Card Surcharge'
|
|
63
67
|
|
|
64
68
|
# Minimum Charge
|
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: 6.30.
|
|
4
|
+
version: 6.30.6
|
|
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: 2026-01-
|
|
11
|
+
date: 2026-01-26 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: rails
|