decidim-verifications 0.26.0 → 0.26.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: 9ee7945251d337d924058f58bc23e57313d185197033365d31e1a3dc0942aea9
4
- data.tar.gz: 4f24450e8c792bf524bde9ad16c11201d13aae20ece409d555e757f7258a20eb
3
+ metadata.gz: 40b3d3819f7f93fe5831354b2ad193b254abb246ec42f4251abb2e53d7f2117c
4
+ data.tar.gz: 18b3b3fe23120bfabe07dc65e68ffbb80814e549590e20671109228e92a7f711
5
5
  SHA512:
6
- metadata.gz: dc1a2fa436600b8d287f7fe740cee1ecad8aac3f017812af1c4fa1d3e1958b1983a9c978903503344db75d26aa17cbecaeaf3c1c5143e551f212df12bf9950f4
7
- data.tar.gz: 84460be71764709177de3914c6b931ae328a94bfabed2153f573ca070bd36b270454623bb986f90ecc88c1cbd916990014d2f205d6064ea4c4c32ffd4f2270e1
6
+ metadata.gz: 12aca3ffbe5cef789ac595406a474d7190a1420e48649205db48bb4af66a453393acec7fb8d2ceb69505d9d6be4db172f34e0cdc97b83944302b3601cbd749e6
7
+ data.tar.gz: 1b59dde4639968735d96955f53642032ffb9da8f369d6d811550d6a2aee12da4cf4018189301250c327f716bbd434af52179175a1833898fc60cf11d5abf5ed2
@@ -7,8 +7,9 @@ module Decidim
7
7
  # Public: Initializes the command.
8
8
  #
9
9
  # handler - An AuthorizationHandler object.
10
- def initialize(handler)
10
+ def initialize(handler, organization)
11
11
  @handler = handler
12
+ @organization = organization
12
13
  end
13
14
 
14
15
  # Executes the command. Broadcasts these events:
@@ -39,7 +40,7 @@ module Decidim
39
40
  event: "decidim.events.verifications.managed_user_error_event",
40
41
  event_class: Decidim::Verifications::ManagedUserErrorEvent,
41
42
  resource: conflict,
42
- affected_users: Decidim::User.where(admin: true)
43
+ affected_users: Decidim::User.where(admin: true, organization: @organization)
43
44
  )
44
45
  end
45
46
 
@@ -35,7 +35,7 @@ module Decidim
35
35
  end
36
36
 
37
37
  def create
38
- AuthorizeUser.call(handler) do
38
+ AuthorizeUser.call(handler, current_organization) do
39
39
  on(:ok) do
40
40
  flash[:notice] = t("authorizations.create.success", scope: "decidim.verifications")
41
41
  redirect_to redirect_url || authorizations_path
@@ -3,12 +3,16 @@
3
3
  module Decidim
4
4
  module Verifications
5
5
  class ManagedUserErrorEvent < Decidim::Events::SimpleEvent
6
+ include Rails.application.routes.mounted_helpers
7
+
6
8
  delegate :profile_path, :profile_url, :name, to: :updated_user
7
9
 
8
10
  def i18n_scope
9
11
  "decidim.events.verifications.verify_with_managed_user"
10
12
  end
11
13
 
14
+ delegate :conflicts_path, to: :decidim_admin
15
+
12
16
  def resource_path
13
17
  profile_path
14
18
  end
@@ -22,7 +26,7 @@ module Decidim
22
26
  end
23
27
 
24
28
  def default_i18n_options
25
- super.merge({ managed_user_path: managed_user.profile_path, managed_user_name: managed_user.name })
29
+ super.merge({ conflicts_path: conflicts_path, managed_user_path: managed_user.profile_path, managed_user_name: managed_user.name })
26
30
  end
27
31
 
28
32
  private
@@ -75,10 +75,6 @@ ca:
75
75
  postal_letter:
76
76
  explanation: T'enviarem una carta postal amb un codi que hauràs d'introduir perquè puguem verificar la teva adreça
77
77
  name: Codi per carta postal
78
- events:
79
- verifications:
80
- verify_with_managed_user:
81
- 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>
82
78
  verifications:
83
79
  authorizations:
84
80
  authorization_metadata:
@@ -78,7 +78,10 @@ cs:
78
78
  events:
79
79
  verifications:
80
80
  verify_with_managed_user:
81
- notification_title: Účastník <a href="%{resource_path}">%{resource_title}</a> se pokusil ověřit údaji spravovaného účastníka <a href="%{managed_user_path}">%{managed_user_name}</a>
81
+ email_intro: Účastník <a href="%{resource_path}">%{resource_title}</a> se pokusil ověřit se údaji spravovaného účastníka <a href="%{managed_user_path}">%{managed_user_name}</a>.
82
+ email_outro: Zkontrolujte seznam konfliktů <a href="%{conflicts_path}">ověření</a> a kontaktujte uživatele pro ověření jejich údajů a vyřešení problému.
83
+ email_subject: Neúspěšný pokus o ověření proti spravovanému uživateli
84
+ notification_title: Účastník <a href="%{resource_path}">%{resource_title}</a> se pokusil ověřit se údaji spravovaného účastníka <a href="%{managed_user_path}">%{managed_user_name}</a>.
82
85
  verifications:
83
86
  authorizations:
84
87
  authorization_metadata:
@@ -75,10 +75,6 @@ de:
75
75
  postal_letter:
76
76
  explanation: Wir senden Ihnen einen Brief mit einem Code, den Sie eingeben müssen, damit wir Ihre Adresse bestätigen können
77
77
  name: Code per Post
78
- events:
79
- verifications:
80
- verify_with_managed_user:
81
- notification_title: Der Teilnehmer <a href="%{resource_path}">%{resource_title}</a> hat versucht, sich mit den Daten des verwalteten Teilnehmers <a href="%{managed_user_path}">%{managed_user_name}</a> zu verifizieren.
82
78
  verifications:
83
79
  authorizations:
84
80
  authorization_metadata:
@@ -79,7 +79,10 @@ en:
79
79
  events:
80
80
  verifications:
81
81
  verify_with_managed_user:
82
- notification_title: The participant <a href="%{resource_path}">%{resource_title}</a> has tried to verify herself with the data of the managed participant <a href="%{managed_user_path}">%{managed_user_name}</a>
82
+ email_intro: The participant <a href="%{resource_path}">%{resource_title}</a> has tried to verify themself with the data of the managed participant <a href="%{managed_user_path}">%{managed_user_name}</a>.
83
+ email_outro: Check the <a href="%{conflicts_path}">Verifications's conflicts list</a> and contact the participant to verify their details and solve the issue.
84
+ email_subject: Failed verification attempt against a managed participant
85
+ notification_title: The participant <a href="%{resource_path}">%{resource_title}</a> has tried to verify themself with the data of the managed participant <a href="%{managed_user_path}">%{managed_user_name}</a>.
83
86
  verifications:
84
87
  authorizations:
85
88
  authorization_metadata:
@@ -75,10 +75,6 @@ es-MX:
75
75
  postal_letter:
76
76
  explanation: Te enviaremos una carta postal con un código que deberás ingresar para que podamos verificar tu dirección
77
77
  name: Código por carta postal
78
- events:
79
- verifications:
80
- verify_with_managed_user:
81
- 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>
82
78
  verifications:
83
79
  authorizations:
84
80
  authorization_metadata:
@@ -75,10 +75,6 @@ es-PY:
75
75
  postal_letter:
76
76
  explanation: Te enviaremos una carta postal con un código que deberás ingresar para que podamos verificar tu dirección
77
77
  name: Código por carta postal
78
- events:
79
- verifications:
80
- verify_with_managed_user:
81
- 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>
82
78
  verifications:
83
79
  authorizations:
84
80
  authorization_metadata:
@@ -75,10 +75,6 @@ es:
75
75
  postal_letter:
76
76
  explanation: Te enviaremos una carta postal con un código que deberás ingresar para que podamos verificar tu dirección
77
77
  name: Código por carta postal
78
- events:
79
- verifications:
80
- verify_with_managed_user:
81
- 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>
82
78
  verifications:
83
79
  authorizations:
84
80
  authorization_metadata:
@@ -75,10 +75,6 @@ eu:
75
75
  postal_letter:
76
76
  explanation: Posta-gutun bat bidaliko dizugu, sartu behar duzun kode batekin, beraz, zure helbidea egiaztatu ahal izango dugu
77
77
  name: Kodea posta bidez
78
- events:
79
- verifications:
80
- verify_with_managed_user:
81
- notification_title: <a href="%{resource_path}">%{resource_title}</a> parte-hartzailea saiatu da bere burua identifikatzen <a href="%{managed_user_path}">%{managed_user_name}</a> kudeatutako parte-hartzailearen datuekin
82
78
  verifications:
83
79
  authorizations:
84
80
  authorization_metadata:
@@ -78,7 +78,10 @@ fi-pl:
78
78
  events:
79
79
  verifications:
80
80
  verify_with_managed_user:
81
- notification_title: Osallistuja <a href="%{resource_path}">%{resource_title}</a> yritti tunnistautua hallitun käyttäjän <a href="%{managed_user_path}">%{managed_user_name}</a> tiedoilla
81
+ email_intro: Osallistuja <a href="%{resource_path}">%{resource_title}</a> yritti tunnistautua hallitun käyttäjän <a href="%{managed_user_path}">%{managed_user_name}</a> tiedoilla.
82
+ email_outro: Tarkasta <a href="%{conflicts_path}">tunnistautumisten vahvistusten konfliktilista</a> ja ota yhteyttä osallistujaan tarkastaaksesi hänen tietonsa ja ratkaistaksesi ongelman.
83
+ email_subject: Hallitun käyttäjän tunnistaminen epäonnistui
84
+ notification_title: Osallistuja <a href="%{resource_path}">%{resource_title}</a> yritti tunnistautua hallitun käyttäjän <a href="%{managed_user_path}">%{managed_user_name}</a> tiedoilla.
82
85
  verifications:
83
86
  authorizations:
84
87
  authorization_metadata:
@@ -78,7 +78,10 @@ fi:
78
78
  events:
79
79
  verifications:
80
80
  verify_with_managed_user:
81
- notification_title: Osallistuja <a href="%{resource_path}">%{resource_title}</a> yritti tunnistautua hallitun käyttäjän <a href="%{managed_user_path}">%{managed_user_name}</a> tiedoilla
81
+ email_intro: Osallistuja <a href="%{resource_path}">%{resource_title}</a> yritti tunnistautua hallitun käyttäjän <a href="%{managed_user_path}">%{managed_user_name}</a> tiedoilla.
82
+ email_outro: Tarkasta <a href="%{conflicts_path}">tunnistautumisten vahvistusten konfliktilista</a> ja ota yhteyttä osallistujaan tarkastaaksesi hänen tietonsa ja ratkaistaksesi ongelman.
83
+ email_subject: Hallitun käyttäjän tunnistaminen epäonnistui
84
+ notification_title: Osallistuja <a href="%{resource_path}">%{resource_title}</a> yritti tunnistautua hallitun käyttäjän <a href="%{managed_user_path}">%{managed_user_name}</a> tiedoilla.
82
85
  verifications:
83
86
  authorizations:
84
87
  authorization_metadata:
@@ -78,7 +78,10 @@ fr-CA:
78
78
  events:
79
79
  verifications:
80
80
  verify_with_managed_user:
81
- notification_title: Le participant <a href="%{resource_path}">%{resource_title}</a> a essayé de se vérifier avec les données du participant représenté <a href="%{managed_user_path}">%{managed_user_name}</a>
81
+ email_intro: Le participant <a href="%{resource_path}">%{resource_title}</a> a essayé d'être vérifié avec les données de l'utilisateur représenté <a href="%{managed_user_path}">%{managed_user_name}</a>.
82
+ email_outro: Consultez la <a href="%{conflicts_path}">liste de conflits des vérifications</a> et contactez le participant pour vérifier ses détails et résoudre le problème.
83
+ email_subject: Echec lors de la tentative de vérification d'un participant
84
+ notification_title: Le participant <a href="%{resource_path}">%{resource_title}</a> a essayé d'être vérifié avec les données de l'utilisateur représenté <a href="%{managed_user_path}">%{managed_user_name}</a>.
82
85
  verifications:
83
86
  authorizations:
84
87
  authorization_metadata:
@@ -78,7 +78,10 @@ fr:
78
78
  events:
79
79
  verifications:
80
80
  verify_with_managed_user:
81
- notification_title: Le participant <a href="%{resource_path}">%{resource_title}</a> a essayé de se vérifier avec les données du participant représenté <a href="%{managed_user_path}">%{managed_user_name}</a>
81
+ email_intro: Le participant <a href="%{resource_path}">%{resource_title}</a> a essayé d'être vérifié avec les données de l'utilisateur représenté <a href="%{managed_user_path}">%{managed_user_name}</a>.
82
+ email_outro: Consultez la <a href="%{conflicts_path}">liste de conflits des vérifications</a> et contactez le participant pour vérifier ses détails et résoudre le problème.
83
+ email_subject: Echec lors de la tentative de vérification d'un participant
84
+ notification_title: Le participant <a href="%{resource_path}">%{resource_title}</a> a essayé d'être vérifié avec les données de l'utilisateur représenté <a href="%{managed_user_path}">%{managed_user_name}</a>.
82
85
  verifications:
83
86
  authorizations:
84
87
  authorization_metadata:
@@ -75,10 +75,6 @@ gl:
75
75
  postal_letter:
76
76
  explanation: Enviarémosche unha carta postal cun código que terás que ingresar para poder verificar a túa dirección
77
77
  name: Código por carta postal
78
- events:
79
- verifications:
80
- verify_with_managed_user:
81
- notification_title: P participante <a href="%{resource_path}">%{resource_title}</a> tentou a verificación de si mesmo/a cos datos do participante xestionado <a href="%{managed_user_path}">%{managed_user_name}</a>
82
78
  verifications:
83
79
  authorizations:
84
80
  authorization_metadata:
@@ -78,7 +78,10 @@ it:
78
78
  events:
79
79
  verifications:
80
80
  verify_with_managed_user:
81
- notification_title: La partecipante <a href="%{resource_path}">%{resource_title}</a> ha provato a verificarsi con i dati della partecipante gestita <a href="%{managed_user_path}">%{managed_user_name}</a>
81
+ email_intro: L'utente<a href="%{resource_path}">%{resource_title}</a> ha provato a verificarsi con i dati dell'utente<a href="%{managed_user_path}">%{managed_user_name}</a>.
82
+ email_outro: Controllare l'<a href="%{conflicts_path}">elenco dei conflitti nelle verifiche</a> e contattare l'utente per verificare i propri dati e risolvere il problema.
83
+ email_subject: 'Tentativo di verifica fallito: l''utente esiste già'
84
+ notification_title: L'utente<a href="%{resource_path}">%{resource_title}</a> ha provato a verificarsi con i dati dell'utente<a href="%{managed_user_path}">%{managed_user_name}</a>.
82
85
  verifications:
83
86
  authorizations:
84
87
  authorization_metadata:
@@ -78,7 +78,10 @@ ja:
78
78
  events:
79
79
  verifications:
80
80
  verify_with_managed_user:
81
- notification_title: 参加者 <a href="%{resource_path}">%{resource_title}</a> が管理参加者 <a href="%{managed_user_path}">%{managed_user_name}</a> のデータと自分自身を確認しようとしました。
81
+ email_intro: 参加者 <a href="%{resource_path}">%{resource_title}</a> が管理対象参加者 <a href="%{managed_user_path}">%{managed_user_name}</a>のデータで検証しようとしました。
82
+ email_outro: <a href="%{conflicts_path}">検証の競合リスト</a> を確認し、参加者に連絡して詳細を調査し、問題を解決します。
83
+ email_subject: 管理対象参加者に対する検証の試みに失敗しました
84
+ notification_title: 参加者 <a href="%{resource_path}">%{resource_title}</a> が管理参加者 <a href="%{managed_user_path}">%{managed_user_name}</a>のデータでそれらを確認しようとしました。
82
85
  verifications:
83
86
  authorizations:
84
87
  authorization_metadata:
@@ -75,10 +75,6 @@
75
75
  postal_letter:
76
76
  explanation: Vi sender deg et postbrev med en kode som du må oppgi slik at vi kan bekrefte adressen din
77
77
  name: Kode med post brev
78
- events:
79
- verifications:
80
- verify_with_managed_user:
81
- notification_title: Deltakeren <a href="%{resource_path}">%{resource_title}</a> har forsøkt å verifisere seg selv med data fra den håndterte deltakeren <a href="%{managed_user_path}">%{managed_user_name}</a>
82
78
  verifications:
83
79
  authorizations:
84
80
  authorization_metadata:
@@ -75,10 +75,6 @@ pl:
75
75
  postal_letter:
76
76
  explanation: Wyślemy Ci list pocztowy z kodem, który musisz wprowadzić, abyśmy mogli zweryfikować twój adres
77
77
  name: Kod listem pocztowym
78
- events:
79
- verifications:
80
- verify_with_managed_user:
81
- notification_title: Użytkownik <a href="%{resource_path}">%{resource_title}</a> próbował zweryfikować siebie z danymi zarządzanego użytkownika <a href="%{managed_user_path}">%{managed_user_name}</a>
82
78
  verifications:
83
79
  authorizations:
84
80
  authorization_metadata:
@@ -75,10 +75,6 @@ pt-BR:
75
75
  postal_letter:
76
76
  explanation: Nós lhe enviaremos uma carta postal com um código que você terá que inserir para que possamos verificar seu endereço
77
77
  name: Código por carta postal
78
- events:
79
- verifications:
80
- verify_with_managed_user:
81
- notification_title: O usuário <a href="%{resource_path}">%{resource_title}</a> tentou se verificar com os dados do usuário gerenciado <a href="%{managed_user_path}">%{managed_user_name}</a>
82
78
  verifications:
83
79
  authorizations:
84
80
  authorization_metadata:
@@ -75,10 +75,6 @@ pt:
75
75
  postal_letter:
76
76
  explanation: Enviaremos-lhe uma carta postal com um código que terá que inserir para que possamos verificar o seu endereço
77
77
  name: Código por carta postal
78
- events:
79
- verifications:
80
- verify_with_managed_user:
81
- notification_title: O participante <a href=«%{resource_path}»>%{resource_title}</a> tentou verificar-se com os dados do participante gerido <a href=«%{managed_user_path}»>>%{managed_user_name}</a>
82
78
  verifications:
83
79
  authorizations:
84
80
  authorization_metadata:
@@ -75,10 +75,6 @@ ro:
75
75
  postal_letter:
76
76
  explanation: Îți vom trimite o scrisoare poștală cu un cod pe care va trebui să-l introduci pentru a-ți putea verifica adresa
77
77
  name: Cod primit prin scrisoare poștală
78
- events:
79
- verifications:
80
- verify_with_managed_user:
81
- notification_title: Participantul <a href="%{resource_path}">%{resource_title}</a> a încercat să își verifice contul cu datele participantului <a href="%{managed_user_path}">%{managed_user_name}</a>
82
78
  verifications:
83
79
  authorizations:
84
80
  authorization_metadata:
@@ -67,10 +67,6 @@ tr:
67
67
  postal_letter:
68
68
  explanation: Size adresinizi doğrulayabilmemiz için girmeniz gereken bir kod içeren bir posta mektubu göndereceğiz.
69
69
  name: Posta mektubu ile kod
70
- events:
71
- verifications:
72
- verify_with_managed_user:
73
- notification_title: Katılımcı <a href="%{resource_path}">%{resource_title} </a>, yönetilen katılımcının <a href="%{managed_user_path}">%{managed_user_name} </a> verileriyle kendini doğrulamaya çalıştı
74
70
  verifications:
75
71
  authorizations:
76
72
  authorization_metadata:
@@ -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.0"
7
+ "0.26.1"
8
8
  end
9
9
  end
10
10
  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.0
4
+ version: 0.26.1
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-02-22 00:00:00.000000000 Z
11
+ date: 2022-03-25 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.0
19
+ version: 0.26.1
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.0
26
+ version: 0.26.1
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.0
33
+ version: 0.26.1
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.0
40
+ version: 0.26.1
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.0
47
+ version: 0.26.1
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.0
54
+ version: 0.26.1
55
55
  description: Several verification methods for your decidim instance
56
56
  email:
57
57
  - deivid.rodriguez@riseup.net