decidim-verifications 0.26.2 → 0.27.0.rc1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (77) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +2 -2
  3. data/app/commands/decidim/verifications/authorize_user.rb +2 -2
  4. data/app/commands/decidim/verifications/confirm_user_authorization.rb +1 -1
  5. data/app/commands/decidim/verifications/csv_census/admin/create_census_data.rb +1 -1
  6. data/app/commands/decidim/verifications/destroy_user_authorization.rb +1 -1
  7. data/app/commands/decidim/verifications/id_documents/admin/confirm_user_offline_authorization.rb +1 -1
  8. data/app/commands/decidim/verifications/id_documents/admin/update_config.rb +1 -1
  9. data/app/commands/decidim/verifications/perform_authorization_step.rb +1 -1
  10. data/app/commands/decidim/verifications/revoke_all_authorizations.rb +1 -1
  11. data/app/commands/decidim/verifications/revoke_by_condition_authorizations.rb +1 -1
  12. data/app/controllers/decidim/verifications/application_controller.rb +1 -1
  13. data/app/controllers/decidim/verifications/authorizations_controller.rb +12 -2
  14. data/app/controllers/decidim/verifications/id_documents/authorizations_controller.rb +0 -2
  15. data/app/controllers/decidim/verifications/postal_letter/authorizations_controller.rb +0 -2
  16. data/app/forms/decidim/verifications/id_documents/upload_form.rb +1 -1
  17. data/app/queries/decidim/verifications/authorizations.rb +1 -1
  18. data/app/queries/decidim/verifications/authorizations_before_date.rb +1 -1
  19. data/app/services/decidim/authorization_handler.rb +2 -2
  20. data/config/locales/am-ET.yml +1 -0
  21. data/config/locales/ar.yml +2 -1
  22. data/config/locales/bg.yml +1 -0
  23. data/config/locales/ca.yml +2 -1
  24. data/config/locales/cs.yml +1 -0
  25. data/config/locales/da.yml +1 -0
  26. data/config/locales/de.yml +1 -0
  27. data/config/locales/el.yml +1 -0
  28. data/config/locales/en.yml +1 -1
  29. data/config/locales/eo.yml +1 -0
  30. data/config/locales/es-MX.yml +2 -1
  31. data/config/locales/es-PY.yml +2 -1
  32. data/config/locales/es.yml +2 -1
  33. data/config/locales/et.yml +1 -0
  34. data/config/locales/eu.yml +1 -0
  35. data/config/locales/fi-plain.yml +1 -0
  36. data/config/locales/fi.yml +2 -1
  37. data/config/locales/fr-CA.yml +1 -0
  38. data/config/locales/fr.yml +1 -0
  39. data/config/locales/ga-IE.yml +1 -0
  40. data/config/locales/gl.yml +1 -0
  41. data/config/locales/hr.yml +1 -0
  42. data/config/locales/hu.yml +1 -0
  43. data/config/locales/id-ID.yml +1 -0
  44. data/config/locales/is-IS.yml +2 -1
  45. data/config/locales/it.yml +1 -0
  46. data/config/locales/ja.yml +1 -0
  47. data/config/locales/ko.yml +1 -0
  48. data/config/locales/lb.yml +1 -0
  49. data/config/locales/lt.yml +1 -0
  50. data/config/locales/lv.yml +1 -0
  51. data/config/locales/mt.yml +1 -0
  52. data/config/locales/nl.yml +2 -1
  53. data/config/locales/no.yml +1 -0
  54. data/config/locales/om-ET.yml +1 -0
  55. data/config/locales/pl.yml +1 -0
  56. data/config/locales/pt-BR.yml +2 -1
  57. data/config/locales/pt.yml +1 -0
  58. data/config/locales/ro-RO.yml +1 -0
  59. data/config/locales/ru.yml +1 -0
  60. data/config/locales/si-LK.yml +1 -0
  61. data/config/locales/sk.yml +1 -0
  62. data/config/locales/sl.yml +1 -0
  63. data/config/locales/so-SO.yml +1 -0
  64. data/config/locales/sr-CS.yml +1 -0
  65. data/config/locales/sv.yml +1 -0
  66. data/config/locales/sw-KE.yml +1 -0
  67. data/config/locales/ti-ER.yml +1 -0
  68. data/config/locales/tr-TR.yml +1 -0
  69. data/config/locales/uk.yml +1 -0
  70. data/config/locales/val-ES.yml +1 -0
  71. data/config/locales/vi.yml +1 -0
  72. data/config/locales/zh-CN.yml +1 -0
  73. data/config/locales/zh-TW.yml +1 -0
  74. data/lib/decidim/verifications/sms/example_gateway.rb +1 -1
  75. data/lib/decidim/verifications/version.rb +1 -1
  76. data/lib/decidim/verifications/workflow_manifest.rb +6 -6
  77. metadata +12 -12
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 936f3dc81615bf1d0e63d209ef2d1b021d8eaa0053f78aad6f26fc7f9c732bb4
4
- data.tar.gz: 5aad53092a176b1c926f36707fc49361cf62f0e08372accdec1984d431203cc2
3
+ metadata.gz: 1ee5a37d18af70ffb55bacdb53806094fc921e3a0f09f78e765efa9f671facc0
4
+ data.tar.gz: f5aeefc51841d4bd7614bf565f4b2b92b123fe8b56c0cac84e820b5ac9a1c4bb
5
5
  SHA512:
6
- metadata.gz: 2f27dcaadfbabac220c2b52cb93ff03a3f1d4709e45d7dc646b0b7e25b68f49dffeca7e34ef1cefe0d06cdf2367b447060cf8985e96b3219a4c34eff3c787b0c
7
- data.tar.gz: 575fd8025b5537e4ad0cfba3964e028762cbe9d6ab7cf4e5494e42c79c5ff66459d2f347db35ff8154ffbbc33f57ce73d58e1c40d007d30a236b2e493eb87728
6
+ metadata.gz: 40d2c5f336f2ee77eac41990e0afabc76c5bb62bf64d6ae40b56ce8f14d9dfcc2a479ccf6e141c86eb71ed6d92f6cd8b717c147602504f18d740c60830be5105
7
+ data.tar.gz: c245dcd709dd8b5c2e153cf50fdf2745ce1add022070b76b2881d1d30dcdd604b446b713e2ef75686832af974a6640ac58bda2f249fe3930e153c484919e369b
data/README.md CHANGED
@@ -43,7 +43,7 @@ Decidim implements two type of authorization methods:
43
43
 
44
44
  * _Form authorizations_.
45
45
 
46
- When your verification method is simple enough, you can use a `Rectify::Form`
46
+ When your verification method is simple enough, you can use a `Decidim::Form`
47
47
  to implement it. "Simple" here means that the authorization can be granted
48
48
  with the submission of a single form. For example, to validate a user against
49
49
  a census API you will need a form with some fields that your users will use to
@@ -150,7 +150,7 @@ Decidim::Verifications.register_workflow(:my_workflow) do |workflow|
150
150
  end
151
151
  ```
152
152
 
153
- The format of the options you can define is the standard for a virtus attribute,
153
+ The format of the options you can define is the standard for a Decidim attribute,
154
154
  plus an additional `required` (true by default) option were you can choose
155
155
  whether the option is compulsory when configuring the workflow as a permission
156
156
  for an action or not.
@@ -3,7 +3,7 @@
3
3
  module Decidim
4
4
  module Verifications
5
5
  # A command to authorize a user with an authorization handler.
6
- class AuthorizeUser < Rectify::Command
6
+ class AuthorizeUser < Decidim::Command
7
7
  # Public: Initializes the command.
8
8
  #
9
9
  # handler - An AuthorizationHandler object.
@@ -40,7 +40,7 @@ module Decidim
40
40
  event: "decidim.events.verifications.managed_user_error_event",
41
41
  event_class: Decidim::Verifications::ManagedUserErrorEvent,
42
42
  resource: conflict,
43
- affected_users: Decidim::User.where(admin: true, organization: @organization)
43
+ affected_users: @organization.admins
44
44
  )
45
45
  end
46
46
 
@@ -3,7 +3,7 @@
3
3
  module Decidim
4
4
  module Verifications
5
5
  # A command to confirm a previous partial authorization.
6
- class ConfirmUserAuthorization < Rectify::Command
6
+ class ConfirmUserAuthorization < Decidim::Command
7
7
  # Number of failed confirmation attempts before throttling.
8
8
  MAX_FAILED_ATTEMPTS = 2
9
9
 
@@ -6,7 +6,7 @@ module Decidim
6
6
  module Admin
7
7
  # A command with the business logic to create census data for a
8
8
  # organization.
9
- class CreateCensusData < Rectify::Command
9
+ class CreateCensusData < Decidim::Command
10
10
  def initialize(form, organization)
11
11
  @form = form
12
12
  @organization = organization
@@ -3,7 +3,7 @@
3
3
  module Decidim
4
4
  module Verifications
5
5
  # A command to Destroy the Authorization of a user.
6
- class DestroyUserAuthorization < Rectify::Command
6
+ class DestroyUserAuthorization < Decidim::Command
7
7
  def initialize(authorization)
8
8
  @authorization = authorization
9
9
  end
@@ -5,7 +5,7 @@ module Decidim
5
5
  module IdDocuments
6
6
  module Admin
7
7
  # A command to confirm a previous partial offline authorization.
8
- class ConfirmUserOfflineAuthorization < Rectify::Command
8
+ class ConfirmUserOfflineAuthorization < Decidim::Command
9
9
  # Public: Initializes the command.
10
10
  #
11
11
  # form - A form object with the verification data to confirm it.
@@ -4,7 +4,7 @@ module Decidim
4
4
  module Verifications
5
5
  module IdDocuments
6
6
  module Admin
7
- class UpdateConfig < Rectify::Command
7
+ class UpdateConfig < Decidim::Command
8
8
  def initialize(form)
9
9
  @form = form
10
10
  end
@@ -3,7 +3,7 @@
3
3
  module Decidim
4
4
  module Verifications
5
5
  # A command to create a partial authorization for a user.
6
- class PerformAuthorizationStep < Rectify::Command
6
+ class PerformAuthorizationStep < Decidim::Command
7
7
  # Public: Initializes the command.
8
8
  #
9
9
  # authorization - An Authorization object.
@@ -3,7 +3,7 @@
3
3
  module Decidim
4
4
  module Verifications
5
5
  # A command to revoke authorizations
6
- class RevokeAllAuthorizations < Rectify::Command
6
+ class RevokeAllAuthorizations < Decidim::Command
7
7
  # Public: Initializes the command.
8
8
  #
9
9
  # organization - Organization object.
@@ -3,7 +3,7 @@
3
3
  module Decidim
4
4
  module Verifications
5
5
  # A command to revoke authorizations with filter
6
- class RevokeByConditionAuthorizations < Rectify::Command
6
+ class RevokeByConditionAuthorizations < Decidim::Command
7
7
  # Public: Initializes the command.
8
8
  #
9
9
  # organization - Organization object.
@@ -22,7 +22,7 @@ module Decidim
22
22
  private
23
23
 
24
24
  def confirmed_user
25
- return true if !current_user || current_user && current_user.verifiable?
25
+ return true if !current_user || (current_user && current_user.verifiable?)
26
26
 
27
27
  redirect_back(
28
28
  fallback_location: root_path,
@@ -71,9 +71,19 @@ module Decidim
71
71
  def valid_handler
72
72
  return true if handler
73
73
 
74
- logger.warn "Invalid authorization handler given: #{handler_name} doesn't"\
75
- "exist or you haven't added it to `Decidim.authorization_handlers`"
74
+ msg = <<-MSG
75
+ Invalid authorization handler given: #{handler_name} doesn't
76
+ exist or you haven't added it to `Decidim.authorization_handlers.
76
77
 
78
+ Make sure this name matches with your registrations:\n\n
79
+ Decidim::Verifications.register_workflow(:#{handler_name}) do
80
+ ...
81
+ end
82
+ MSG
83
+
84
+ raise msg if Rails.env.development?
85
+
86
+ logger.warn msg
77
87
  redirect_to(authorizations_path) && (return false)
78
88
  end
79
89
 
@@ -77,11 +77,9 @@ module Decidim
77
77
 
78
78
  private
79
79
 
80
- # rubocop:disable Naming/MemoizedInstanceVariableName
81
80
  def authorization
82
81
  @authorization_presenter ||= AuthorizationPresenter.new(@authorization)
83
82
  end
84
- # rubocop:enable Naming/MemoizedInstanceVariableName
85
83
 
86
84
  def load_authorization
87
85
  @authorization = Decidim::Authorization.find_or_initialize_by(
@@ -60,11 +60,9 @@ module Decidim
60
60
 
61
61
  private
62
62
 
63
- # rubocop:disable Naming/MemoizedInstanceVariableName
64
63
  def authorization
65
64
  @authorization_presenter ||= AuthorizationPresenter.new(@authorization)
66
65
  end
67
- # rubocop:enable Naming/MemoizedInstanceVariableName
68
66
 
69
67
  def load_authorization
70
68
  @authorization = Decidim::Authorization.find_or_initialize_by(
@@ -8,7 +8,7 @@ module Decidim
8
8
  class UploadForm < InformationForm
9
9
  mimic :id_document_upload
10
10
 
11
- attribute :verification_attachment, String
11
+ attribute :verification_attachment
12
12
 
13
13
  validates :verification_attachment,
14
14
  passthru: { to: Decidim::Authorization },
@@ -3,7 +3,7 @@
3
3
  module Decidim
4
4
  module Verifications
5
5
  # Finds authorizations by different criteria
6
- class Authorizations < Rectify::Query
6
+ class Authorizations < Decidim::Query
7
7
  # Initializes the class.
8
8
  #
9
9
  # @param organization [Organization] The organization where this authorization belongs to
@@ -3,7 +3,7 @@
3
3
  module Decidim
4
4
  module Verifications
5
5
  # Finds authorizations by different criteria
6
- class AuthorizationsBeforeDate < Rectify::Query
6
+ class AuthorizationsBeforeDate < Decidim::Query
7
7
  # Initializes the class.
8
8
  #
9
9
  # @param organization [Organization] The organization where this authorization belongs to
@@ -29,12 +29,12 @@ module Decidim
29
29
  nil
30
30
  end
31
31
 
32
- # THe attributes of the handler that should be exposed as form input when
32
+ # The attributes of the handler that should be exposed as form input when
33
33
  # rendering the handler in a form.
34
34
  #
35
35
  # Returns an Array of Strings.
36
36
  def form_attributes
37
- attributes.except(:id, :user).keys
37
+ attributes.except("id", "user").keys
38
38
  end
39
39
 
40
40
  # The String partial path so Rails can render the handler as a form. This
@@ -1 +1,2 @@
1
+ ---
1
2
  am:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  ar:
2
3
  activemodel:
3
4
  attributes:
@@ -145,7 +146,7 @@ ar:
145
146
  verification_number: 'التحقق #%{n}'
146
147
  rejections:
147
148
  create:
148
- success: تم رفض التحقق. ستتم مطالبة المشاركة بتعديل مستنداتها
149
+ success: تم رفض التحقق. ستتم مطالبة المشاركين بتعديل مستنداتها
149
150
  authorizations:
150
151
  choose:
151
152
  choose_a_type: 'الرجاء تحديد الطريقة التي تريد التحقق منها:'
@@ -1,3 +1,4 @@
1
+ ---
1
2
  bg:
2
3
  activemodel:
3
4
  attributes:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  ca:
2
3
  activemodel:
3
4
  attributes:
@@ -80,7 +81,7 @@ ca:
80
81
  verify_with_managed_user:
81
82
  email_intro: La participant <a href="%{resource_path}">%{resource_title}</a> ha intentat verificar-se amb les dades de la participant gestionada <a href="%{managed_user_path}">%{managed_user_name}</a>.
82
83
  email_outro: Comprova la <a href="%{conflicts_path}">llista de conflictes de verificacions</a> i posa't en contacte amb la participant per a verificar els seus detalls i resoldre el problema.
83
- email_subject: Error en intentar verificar-se contra una participant gestionada
84
+ email_subject: Error a l'intentar verificar-se contra una participant gestionada
84
85
  notification_title: La participant <a href="%{resource_path}">%{resource_title}</a> ha intentat verificar-se amb les dades de la participant gestionada <a href="%{managed_user_path}">%{managed_user_name}</a>.
85
86
  verifications:
86
87
  authorizations:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  cs:
2
3
  activemodel:
3
4
  attributes:
@@ -1 +1,2 @@
1
+ ---
1
2
  da:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  de:
2
3
  activemodel:
3
4
  attributes:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  el:
2
3
  activemodel:
3
4
  attributes:
@@ -192,7 +192,7 @@ en:
192
192
  verification_number: 'Verification #%{n}'
193
193
  rejections:
194
194
  create:
195
- success: Verification rejected. Participant will be prompted to amend her documents
195
+ success: Verification rejected. Participant will be prompted to amend their documents
196
196
  authorizations:
197
197
  choose:
198
198
  choose_a_type: 'Please select how you want to be verified:'
@@ -1 +1,2 @@
1
+ ---
1
2
  eo:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  es-MX:
2
3
  activemodel:
3
4
  attributes:
@@ -81,7 +82,7 @@ es-MX:
81
82
  email_intro: La participante <a href="%{resource_path}">%{resource_title}</a> ha intentado verificarse a si misma con los datos de la participante gestionada <a href="%{managed_user_path}">%{managed_user_name}</a>.
82
83
  email_outro: Comprueba la <a href="%{conflicts_path}">lista de conflictos de verificaciones</a> y ponte en contacto con la participante para verificar sus detalles y resolver el problema.
83
84
  email_subject: Error al intentar verificarse contra una participante gestionada
84
- notification_title: La participante <a href="%{resource_path}">%{resource_title}</a> ha intentado verificarse con los datos de la participante gestionada <a href="%{managed_user_path}">%{managed_user_name}</a>.
85
+ notification_title: La participante <a href="%{resource_path}">%{resource_title}</a> ha intentado verificarse a si misma con los datos de la participante gestionada <a href="%{managed_user_path}">%{managed_user_name}</a>.
85
86
  verifications:
86
87
  authorizations:
87
88
  authorization_metadata:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  es-PY:
2
3
  activemodel:
3
4
  attributes:
@@ -81,7 +82,7 @@ es-PY:
81
82
  email_intro: La participante <a href="%{resource_path}">%{resource_title}</a> ha intentado verificarse a si misma con los datos de la participante gestionada <a href="%{managed_user_path}">%{managed_user_name}</a>.
82
83
  email_outro: Comprueba la <a href="%{conflicts_path}">lista de conflictos de verificaciones</a> y ponte en contacto con la participante para verificar sus detalles y resolver el problema.
83
84
  email_subject: Error al intentar verificarse contra una participante gestionada
84
- notification_title: La participante <a href="%{resource_path}">%{resource_title}</a> ha intentado verificarse con los datos de la participante gestionada <a href="%{managed_user_path}">%{managed_user_name}</a>.
85
+ notification_title: La participante <a href="%{resource_path}">%{resource_title}</a> ha intentado verificarse a si misma con los datos de la participante gestionada <a href="%{managed_user_path}">%{managed_user_name}</a>.
85
86
  verifications:
86
87
  authorizations:
87
88
  authorization_metadata:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  es:
2
3
  activemodel:
3
4
  attributes:
@@ -81,7 +82,7 @@ es:
81
82
  email_intro: La participante <a href="%{resource_path}">%{resource_title}</a> ha intentado verificarse a si misma con los datos de la participante gestionada <a href="%{managed_user_path}">%{managed_user_name}</a>.
82
83
  email_outro: Comprueba la <a href="%{conflicts_path}">lista de conflictos de verificaciones</a> y ponte en contacto con la participante para verificar sus detalles y resolver el problema.
83
84
  email_subject: Error al intentar verificarse contra una participante gestionada
84
- notification_title: La participante <a href="%{resource_path}">%{resource_title}</a> ha intentado verificarse con los datos de la participante gestionada <a href="%{managed_user_path}">%{managed_user_name}</a>.
85
+ notification_title: La participante <a href="%{resource_path}">%{resource_title}</a> ha intentado verificarse a si misma con los datos de la participante gestionada <a href="%{managed_user_path}">%{managed_user_name}</a>.
85
86
  verifications:
86
87
  authorizations:
87
88
  authorization_metadata:
@@ -1 +1,2 @@
1
+ ---
1
2
  et:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  eu:
2
3
  activemodel:
3
4
  attributes:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  fi-pl:
2
3
  activemodel:
3
4
  attributes:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  fi:
2
3
  activemodel:
3
4
  attributes:
@@ -191,7 +192,7 @@ fi:
191
192
  verification_number: 'Vahvistus #%{n}'
192
193
  rejections:
193
194
  create:
194
- success: Vahvistus hylätty. Käyttäjää pyydetään muuttamaan asiakirjojaan
195
+ success: Vahvistus hylätty. Käyttäjää pyydetään päivittämään lataamiaan asiakirjoja
195
196
  authorizations:
196
197
  choose:
197
198
  choose_a_type: 'Valitse, kuinka haluat varmistaa henkilöllisyytesi:'
@@ -1,3 +1,4 @@
1
+ ---
1
2
  fr-CA:
2
3
  activemodel:
3
4
  attributes:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  fr:
2
3
  activemodel:
3
4
  attributes:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  ga:
2
3
  activemodel:
3
4
  attributes:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  gl:
2
3
  activemodel:
3
4
  attributes:
@@ -1 +1,2 @@
1
+ ---
1
2
  hr:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  hu:
2
3
  activemodel:
3
4
  attributes:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  id:
2
3
  activemodel:
3
4
  attributes:
@@ -1,4 +1,5 @@
1
- is-IS:
1
+ ---
2
+ is:
2
3
  activemodel:
3
4
  attributes:
4
5
  id_document_information:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  it:
2
3
  activemodel:
3
4
  attributes:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  ja:
2
3
  activemodel:
3
4
  attributes:
@@ -1 +1,2 @@
1
+ ---
1
2
  ko:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  lb:
2
3
  activemodel:
3
4
  attributes:
@@ -1 +1,2 @@
1
+ ---
1
2
  lt:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  lv:
2
3
  activemodel:
3
4
  attributes:
@@ -1 +1,2 @@
1
+ ---
1
2
  mt:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  nl:
2
3
  activemodel:
3
4
  attributes:
@@ -184,7 +185,7 @@ nl:
184
185
  verification_number: 'Verificatie # %{n}'
185
186
  rejections:
186
187
  create:
187
- success: Verificatie geweigerd. De deelnemer wordt gevraagd om haar documenten te wijzigen
188
+ success: Verificatie geweigerd. De deelnemer wordt gevraagd om zijn/haar documenten te wijzigen
188
189
  authorizations:
189
190
  choose:
190
191
  choose_a_type: 'Selecteer alstublieft hoe u wilt worden geverifieerd:'
@@ -1,3 +1,4 @@
1
+ ---
1
2
  "no":
2
3
  activemodel:
3
4
  attributes:
@@ -1 +1,2 @@
1
+ ---
1
2
  om:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  pl:
2
3
  activemodel:
3
4
  attributes:
@@ -1,4 +1,5 @@
1
- pt-BR:
1
+ ---
2
+ pt:
2
3
  activemodel:
3
4
  attributes:
4
5
  config:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  pt:
2
3
  activemodel:
3
4
  attributes:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  ro:
2
3
  activemodel:
3
4
  attributes:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  ru:
2
3
  activemodel:
3
4
  attributes:
@@ -1 +1,2 @@
1
+ ---
1
2
  si:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  sk:
2
3
  activemodel:
3
4
  attributes:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  sl:
2
3
  activemodel:
3
4
  attributes:
@@ -1 +1,2 @@
1
+ ---
1
2
  so:
@@ -1 +1,2 @@
1
+ ---
1
2
  sr:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  sv:
2
3
  activemodel:
3
4
  attributes:
@@ -1 +1,2 @@
1
+ ---
1
2
  sw:
@@ -1 +1,2 @@
1
+ ---
1
2
  ti:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  tr:
2
3
  activemodel:
3
4
  attributes:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  uk:
2
3
  activemodel:
3
4
  attributes:
@@ -1 +1,2 @@
1
+ ---
1
2
  val:
@@ -1 +1,2 @@
1
+ ---
1
2
  vi:
@@ -1,3 +1,4 @@
1
+ ---
1
2
  zh-CN:
2
3
  activemodel:
3
4
  attributes:
@@ -1 +1,2 @@
1
+ ---
1
2
  zh-TW:
@@ -12,7 +12,7 @@ module Decidim
12
12
  end
13
13
 
14
14
  def deliver_code
15
- Rails.logger.debug("Example SMS gateway service, verification code is: #{code}, should have been delivered to #{mobile_phone_number}")
15
+ Rails.logger.debug { "Example SMS gateway service, verification code is: #{code}, should have been delivered to #{mobile_phone_number}" }
16
16
  true
17
17
  end
18
18
  end
@@ -4,7 +4,7 @@ module Decidim
4
4
  # This holds the decidim-verifications version.
5
5
  module Verifications
6
6
  def self.version
7
- "0.26.2"
7
+ "0.27.0.rc1"
8
8
  end
9
9
  end
10
10
  end
@@ -10,7 +10,7 @@ module Decidim
10
10
  # This class serves as a DSL to declaratively specify a verification method.
11
11
  #
12
12
  # To define a direct verification method, you need to specify the `form`
13
- # attribute as a `Rectify::Form` that will be valid if the authorization is
13
+ # attribute as a `Decidim::Form` that will be valid if the authorization is
14
14
  # valid.
15
15
  #
16
16
  # To define a deferred verification method, you need specify the `engine`
@@ -27,10 +27,10 @@ module Decidim
27
27
  #
28
28
  class WorkflowManifest
29
29
  include ActiveModel::Model
30
- include Virtus.model
30
+ include Decidim::AttributeObject::Model
31
31
 
32
- attribute :engine, Rails::Engine
33
- attribute :admin_engine, Rails::Engine
32
+ attribute :engine, Rails::Engine, **{}
33
+ attribute :admin_engine, Rails::Engine, **{}
34
34
  attribute :form, String
35
35
  attribute :expires_in, ActiveSupport::Duration, default: 0.minutes
36
36
  attribute :action_authorizer, String
@@ -62,8 +62,8 @@ module Decidim
62
62
  end
63
63
 
64
64
  def action_authorizer_class
65
- if @action_authorizer.present?
66
- @action_authorizer.constantize
65
+ if action_authorizer.present?
66
+ action_authorizer.constantize
67
67
  else
68
68
  DefaultActionAuthorizer
69
69
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: decidim-verifications
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.26.2
4
+ version: 0.27.0.rc1
5
5
  platform: ruby
6
6
  authors:
7
7
  - David Rodriguez
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-06-14 00:00:00.000000000 Z
11
+ date: 2022-06-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: decidim-core
@@ -16,42 +16,42 @@ dependencies:
16
16
  requirements:
17
17
  - - '='
18
18
  - !ruby/object:Gem::Version
19
- version: 0.26.2
19
+ version: 0.27.0.rc1
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - '='
25
25
  - !ruby/object:Gem::Version
26
- version: 0.26.2
26
+ version: 0.27.0.rc1
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: decidim-admin
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - '='
32
32
  - !ruby/object:Gem::Version
33
- version: 0.26.2
33
+ version: 0.27.0.rc1
34
34
  type: :development
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - '='
39
39
  - !ruby/object:Gem::Version
40
- version: 0.26.2
40
+ version: 0.27.0.rc1
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: decidim-dev
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
45
  - - '='
46
46
  - !ruby/object:Gem::Version
47
- version: 0.26.2
47
+ version: 0.27.0.rc1
48
48
  type: :development
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - '='
53
53
  - !ruby/object:Gem::Version
54
- version: 0.26.2
54
+ version: 0.27.0.rc1
55
55
  description: Several verification methods for your decidim instance
56
56
  email:
57
57
  - deivid.rodriguez@riseup.net
@@ -253,14 +253,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
253
253
  requirements:
254
254
  - - ">="
255
255
  - !ruby/object:Gem::Version
256
- version: '2.7'
256
+ version: '3.0'
257
257
  required_rubygems_version: !ruby/object:Gem::Requirement
258
258
  requirements:
259
- - - ">="
259
+ - - ">"
260
260
  - !ruby/object:Gem::Version
261
- version: '0'
261
+ version: 1.3.1
262
262
  requirements: []
263
- rubygems_version: 3.1.6
263
+ rubygems_version: 3.2.22
264
264
  signing_key:
265
265
  specification_version: 4
266
266
  summary: Decidim verifications module