effective_orders 1.3.5 → 1.3.6
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
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2320934b1b20e85e0b4b43bd665923cf2b162d3e
|
4
|
+
data.tar.gz: 2af569b2d128dc78dfce91d0d53e3bd9d39394f0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ffbd42ef26796303772654798396323ad416c670bd72e9c252dcf1890e80461fa4362e9bb8b02a32a42c692163ba94ddea78c8c9127963b2cc9cf82cd2d7d41b
|
7
|
+
data.tar.gz: e4c189e58052bd46a814b4cf6fa2c0fa9bbc512d8bb63a2dc03f481b056b978fc2c049e6badbd4f6ca669ee0a3636a0d7677a55b46d90892f54e707a6987897d
|
@@ -13,6 +13,9 @@ module Effective
|
|
13
13
|
@page_title ||= 'My Subscriptions'
|
14
14
|
|
15
15
|
@subscriptions = @customer.subscriptions.purchased
|
16
|
+
@active_stripe_subscription = @subscriptions.map(&:stripe_subscription).find do |subscription|
|
17
|
+
subscription.present? && subscription.status == 'active' && subscription.current_period_end > Time.zone.now.to_i
|
18
|
+
end
|
16
19
|
|
17
20
|
EffectiveOrders.authorized?(self, :index, Effective::Subscription)
|
18
21
|
end
|
@@ -1,11 +1,16 @@
|
|
1
1
|
%h4 Payment Details
|
2
2
|
|
3
|
-
|
4
|
-
|
3
|
+
- if order.payment.present?
|
4
|
+
- if order.purchased?
|
5
|
+
%p This order was purchased with the following details:
|
6
|
+
- elsif order.declined?
|
7
|
+
%p This order was declined with the following details:
|
5
8
|
|
6
|
-
%table.table
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
%table.table
|
10
|
+
%tbody
|
11
|
+
- order.payment.each do |k, v|
|
12
|
+
%tr
|
13
|
+
%td= k
|
14
|
+
%td= v
|
15
|
+
- else
|
16
|
+
%p None
|
@@ -11,6 +11,10 @@
|
|
11
11
|
= '-'
|
12
12
|
= link_to 'unsubscribe', effective_orders.subscription_path(subscription.stripe_plan_id), :data => {:method => :delete, :confirm => 'This will cancel your subscription. Are you sure? This cannot be undone.'}
|
13
13
|
= ')'
|
14
|
+
|
15
|
+
- if @active_stripe_subscription.present?
|
16
|
+
%p Your current subscription will be renewed automatically at #{ Time.zone.at(@active_stripe_subscription.current_period_end).strftime('%d-%b-%Y %H:%M') }.
|
17
|
+
|
14
18
|
- else
|
15
19
|
%p You have no subscriptions
|
16
20
|
|
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: 1.3.
|
4
|
+
version: 1.3.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: 2015-
|
11
|
+
date: 2015-04-27 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|