effective_orders 6.18.0 → 6.18.2
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 30573ea76732efc461d77ac72855675f2a8de7010a81e9d651fafaceb86c75c5
|
4
|
+
data.tar.gz: 605bb5659cb3b7faf9e0940ed59367b3abfc09535f9f42dcb4048594f1408c09
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4f14a09c4ea459f96eb727ac1b7bd8249e1fd42f087a1afca09e3c5705837ddb5ff7b859ab81e654a1e1607f5e4875a82ae8df58c846b50cef79b0296ce9e809
|
7
|
+
data.tar.gz: c2863834450dad29c443746f3dc4c0db11115ffb03796dd4e35d99d707e12bc81c15cc7d609625dd9ae222f42e276e8d8aa046c089fb0572b66862efa23ceb61
|
@@ -59,7 +59,8 @@ module Effective
|
|
59
59
|
mail(to: @order.emails, cc: @order.cc.presence, subject: subject, **headers)
|
60
60
|
end
|
61
61
|
|
62
|
-
# This is sent when someone chooses to Pay by Cheque
|
62
|
+
# This is sent when someone chooses to Pay by Cheque or Pay by E-transfer
|
63
|
+
# This is not automatically sent for a delayed purchase
|
63
64
|
def pending_order_invoice_to_buyer(resource, opts = {})
|
64
65
|
raise('expected an Effective::Order') unless resource.kind_of?(Effective::Order)
|
65
66
|
|
@@ -67,7 +68,9 @@ module Effective
|
|
67
68
|
subject = subject_for(__method__, "Pending Order: ##{@order.to_param}", resource, opts)
|
68
69
|
headers = headers_for(resource, opts)
|
69
70
|
|
70
|
-
|
71
|
+
cc = (@order.cc.to_s.split(',') + [mailer_admin] - [nil, '', ' ']).compact.presence
|
72
|
+
|
73
|
+
mail(to: @order.emails, cc: cc, subject: subject, **headers)
|
71
74
|
end
|
72
75
|
|
73
76
|
# This is sent to admin when someone Accepts Refund
|
@@ -475,6 +475,10 @@ module Effective
|
|
475
475
|
false
|
476
476
|
end
|
477
477
|
|
478
|
+
def purchased_or_deferred?
|
479
|
+
purchased? || deferred?
|
480
|
+
end
|
481
|
+
|
478
482
|
def purchased_with_credit_card?
|
479
483
|
purchased? && EffectiveOrders.credit_card_payment_providers.include?(payment_provider)
|
480
484
|
end
|
@@ -811,7 +815,7 @@ module Effective
|
|
811
815
|
|
812
816
|
raise "Failed to defer order: #{error || errors.full_messages.to_sentence}" unless error.nil?
|
813
817
|
|
814
|
-
|
818
|
+
send_pending_order_invoice_to_buyer! if email
|
815
819
|
|
816
820
|
true
|
817
821
|
end
|
@@ -2,12 +2,22 @@
|
|
2
2
|
|
3
3
|
%p We have received notice of your intention to purchase the following items.
|
4
4
|
|
5
|
-
|
5
|
+
- if @order.delayed?
|
6
|
+
%p{style: "margin-bottom: 4px; font-weight: bold;"} Please note:
|
7
|
+
%ul{style: "margin-top: 0;"}
|
8
|
+
%li Your credit card will be charged on <strong>#{@order.delayed_payment_date.strftime("%A, %B %d, %Y")}</strong>.
|
9
|
+
%li Changes and cancellations must be made before this date.
|
10
|
+
%li A receipt will be sent after the transaction is completed.
|
6
11
|
|
7
|
-
|
12
|
+
- elsif @order.deferred?
|
13
|
+
%p Please remit payment at your earliest convenience.
|
8
14
|
|
9
|
-
- if EffectiveOrders.deferred_providers.present?
|
10
|
-
|
11
|
-
|
15
|
+
- if EffectiveOrders.deferred_providers.present?
|
16
|
+
- providers = EffectiveOrders.deferred_providers.to_sentence(last_word_connector: ', or', two_words_connector: ' or ')
|
17
|
+
%p When we receive your #{providers} we will mark your order paid.
|
12
18
|
|
13
19
|
= render(@order, no_order_actions: true)
|
20
|
+
|
21
|
+
%hr
|
22
|
+
%p{style: "text-align: center;"}
|
23
|
+
= link_to('View your order', effective_orders.order_url(@order))
|
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.18.
|
4
|
+
version: 6.18.2
|
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:
|
11
|
+
date: 2025-01-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|