effective_classifieds 0.2.0 → 0.2.1

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: b922833fe51ff1291c85c0708b708120ab0d87c25ff96185c62b105b53fb1fe7
4
- data.tar.gz: 7bbb631c54607a94616f8493234dbab069c1446b6d6256ed8758cba5b9c2dd2e
3
+ metadata.gz: b86483009f7d9be8e80a451b7b957bbfe1ac9ec2d88d7a11e13f36a97a261a6e
4
+ data.tar.gz: bd9cd48a34bd463f87c12cb3353f9a474f4de95645c4999f9188d10fd2f52d76
5
5
  SHA512:
6
- metadata.gz: c0945747f72335c70181f4f63f89467b936974ad166a938a70e6b97ce23201b42c034997c4279d7f7372662b6afe15e1101759e3551e6d9a495612a9aa3fa148
7
- data.tar.gz: c7dea63e19d5d077ba9c83f0cfaf7bace041f2aa82fdfa173fb5b8d75a5d8358a7380cc759769f75ce308d8b2c698ff88255791ea060e5fb705664d1ee3e209a
6
+ metadata.gz: 820fd500352d1a4b20cc7ed71f0f9569a25d27ca3d2e6a91befc4d8ccfc3244d882e77dcdbb240e73634b419fb90b5b7abfe0ce5abf09d63c11945f90f690f57
7
+ data.tar.gz: 5f2c5ea34d257e972c9f3f2e4e30216537a3f899a8c4778af8c578485653b0d134f6e7c4e44146c456efd2cd7cdde55f85e87f5f96b0c0c972ca37c75d6cb924
@@ -6,26 +6,5 @@ module Effective
6
6
 
7
7
  resource_scope -> { EffectiveClassifieds.ClassifiedWizard.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 in-progress classified ad submission"
15
- redirect_to effective_classifieds.classified_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_classified_wizard) ? :effective_classified_wizard : :classified_wizard)
27
- params.require(model).permit!.except(:status, :status_steps, :wizard_steps, :submitted_at)
28
- end
29
-
30
9
  end
31
10
  end
@@ -26,7 +26,7 @@ module Effective
26
26
  private
27
27
 
28
28
  def permitted_params
29
- params.require(:effective_classified).permit!.except(:status, :status_steps)
29
+ params.require(:effective_classified).except(:status, :status_steps).permit!
30
30
  end
31
31
 
32
32
  end
@@ -1,3 +1,3 @@
1
1
  module EffectiveClassifieds
2
- VERSION = '0.2.0'.freeze
2
+ VERSION = '0.2.1'.freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: effective_classifieds
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.1
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-28 00:00:00.000000000 Z
11
+ date: 2022-01-31 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails