effective_products 0.0.4 → 0.0.5
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
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 665679c4c40101d5dd9830dbda20965773ad06cdc258908b11df23458c1dd817
|
|
4
|
+
data.tar.gz: a5cce4c9c948adf0040070b37974399253c649275416ed1731d44d4d317b0568
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 27b4eedf0d16d9ff1d256cbbbd35f9314669f41f18a70ee802cfe47e6cf1a700f85b47c80876e14e43d8a6c5d6888faa00c2e263b471b27a6762c083c2f6f5de
|
|
7
|
+
data.tar.gz: eeda05f3993792a146324ff33c29a9999e33180a2fad7cf663891347c8146e9c662f49e1e7627e66efa414835285eaf717439d10fc7775134e010de6c3046b51
|
|
@@ -6,26 +6,5 @@ module Effective
|
|
|
6
6
|
|
|
7
7
|
resource_scope -> { EffectiveProducts.RingWizard.deep.where(owner: current_user) }
|
|
8
8
|
|
|
9
|
-
# Allow only 1 in-progress application at a time
|
|
10
|
-
before_action(only: [:new, :show], unless: -> { resource&.done? }) do
|
|
11
|
-
existing = resource_scope.in_progress.where.not(id: resource).first
|
|
12
|
-
|
|
13
|
-
if existing.present?
|
|
14
|
-
flash[:success] = "You have been redirected to your existing in progress payment"
|
|
15
|
-
redirect_to effective_products.ring_wizard_build_path(existing, existing.next_step)
|
|
16
|
-
end
|
|
17
|
-
end
|
|
18
|
-
|
|
19
|
-
after_save do
|
|
20
|
-
flash.now[:success] = ''
|
|
21
|
-
end
|
|
22
|
-
|
|
23
|
-
private
|
|
24
|
-
|
|
25
|
-
def permitted_params
|
|
26
|
-
model = (params.key?(:effective_ring_wizard) ? :effective_ring_wizard : :ring_wizard)
|
|
27
|
-
params.require(model).permit!.except(:status, :status_steps, :wizard_steps, :submitted_at)
|
|
28
|
-
end
|
|
29
|
-
|
|
30
9
|
end
|
|
31
10
|
end
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: effective_products
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.0.
|
|
4
|
+
version: 0.0.5
|
|
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-01-
|
|
11
|
+
date: 2022-01-31 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: rails
|