decidim-surveys 0.9.3 → 0.10.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/assets/images/decidim/surveys/icon.svg +10 -10
- data/app/commands/decidim/surveys/admin/update_survey.rb +4 -4
- data/app/events/decidim/surveys/closed_survey_event.rb +8 -0
- data/app/events/decidim/surveys/opened_survey_event.rb +8 -0
- data/app/jobs/decidim/surveys/settings_change_job.rb +44 -0
- data/config/locales/ca.yml +12 -0
- data/config/locales/en.yml +12 -0
- data/config/locales/es.yml +12 -0
- data/config/locales/eu.yml +12 -0
- data/config/locales/fi.yml +12 -0
- data/config/locales/fr.yml +12 -0
- data/config/locales/gl.yml +12 -0
- data/config/locales/it.yml +12 -0
- data/config/locales/nl.yml +12 -0
- data/config/locales/pl.yml +12 -0
- data/config/locales/pt-BR.yml +12 -0
- data/config/locales/pt.yml +12 -0
- data/config/locales/sv.yml +12 -0
- data/config/locales/uk.yml +1 -1
- data/lib/decidim/surveys/engine.rb +10 -0
- data/lib/decidim/surveys/version.rb +1 -1
- metadata +14 -11
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d88ca8d55ad76e4c40d90bd24192f9e5f034df72d791b2cb5a6665d01ae0bcc1
|
4
|
+
data.tar.gz: 1b9a5510bf87b0518f6c19815732fa257b5b82758ef7e437ada21ce0dbb9df74
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1f673c935d668cd87c11a37e4f7ad5fbba69d4a315cc3e3310b30dfa69db0dc9320ad1fd65e7a8154ed5d9f1d152872a25d107137bce0b7cda0293217970646d
|
7
|
+
data.tar.gz: 6fc514018359de82c07e6aafa0327acfab218504d3980df71d12c0952693cd3289a635de1fe18c8489f4f7bd011a993ef613c3a7c2456990a68e5c69cc32afec
|
@@ -1,19 +1,19 @@
|
|
1
1
|
<?xml version="1.0" encoding="utf-8"?>
|
2
2
|
<!-- Generator: Adobe Illustrator 19.2.1, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
|
3
3
|
<svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
|
4
|
-
|
4
|
+
viewBox="0 0 36 36" style="enable-background:new 0 0 36 36;" xml:space="preserve">
|
5
5
|
<path d="M27,28H9c-0.6,0-1-0.4-1-1V11c0-0.6,0.4-1,1-1h3.1c0.6,0,1,0.4,1,1v1.9h9.7V11c0-0.6,0.4-1,1-1H27c0.6,0,1,0.4,1,1v16
|
6
|
-
|
6
|
+
C28,27.6,27.6,28,27,28z M10,26h16V12h-1.2v1.9c0,0.6-0.4,1-1,1H12.1c-0.6,0-1-0.4-1-1V12H10V26z"/>
|
7
7
|
<g>
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
8
|
+
<g>
|
9
|
+
<path d="M21,11h-6c-0.6,0-1-0.4-1-1s0.4-1,1-1h6c0.6,0,1,0.4,1,1S21.6,11,21,11z"/>
|
10
|
+
</g>
|
11
|
+
<g>
|
12
|
+
<path d="M18.7,11h-1.5c-0.6,0-1-0.4-1-1V8c0-0.6,0.4-1,1-1h1.5c0.6,0,1,0.4,1,1v2C19.7,10.5,19.3,11,18.7,11z"/>
|
13
|
+
</g>
|
14
14
|
</g>
|
15
15
|
<g>
|
16
|
-
|
17
|
-
|
16
|
+
<path d="M18,36.1c-9.9,0-18-8.1-18-18s8.1-18,18-18s18,8.1,18,18S27.9,36.1,18,36.1z M18,2.1c-8.8,0-16,7.2-16,16s7.2,16,16,16
|
17
|
+
s16-7.2,16-16S26.8,2.1,18,2.1z"/>
|
18
18
|
</g>
|
19
19
|
</svg>
|
@@ -46,7 +46,7 @@ module Decidim
|
|
46
46
|
if form_question.deleted?
|
47
47
|
question.destroy!
|
48
48
|
else
|
49
|
-
question.
|
49
|
+
question.update!(question_attributes)
|
50
50
|
end
|
51
51
|
else
|
52
52
|
@survey.questions.create!(question_attributes)
|
@@ -55,9 +55,9 @@ module Decidim
|
|
55
55
|
end
|
56
56
|
|
57
57
|
def update_survey
|
58
|
-
@survey.
|
59
|
-
|
60
|
-
|
58
|
+
@survey.update!(title: @form.title,
|
59
|
+
description: @form.description,
|
60
|
+
tos: @form.tos)
|
61
61
|
end
|
62
62
|
end
|
63
63
|
end
|
@@ -0,0 +1,44 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Decidim
|
4
|
+
module Surveys
|
5
|
+
class SettingsChangeJob < ApplicationJob
|
6
|
+
def perform(feature_id, previous_settings, current_settings)
|
7
|
+
return if unchanged?(previous_settings, current_settings)
|
8
|
+
|
9
|
+
feature = Decidim::Feature.find(feature_id)
|
10
|
+
|
11
|
+
if survey_opened?(previous_settings, current_settings)
|
12
|
+
event = "decidim.events.surveys.survey_opened"
|
13
|
+
event_class = Decidim::Surveys::OpenedSurveyEvent
|
14
|
+
elsif survey_closed?(previous_settings, current_settings)
|
15
|
+
event = "decidim.events.surveys.survey_closed"
|
16
|
+
event_class = Decidim::Surveys::ClosedSurveyEvent
|
17
|
+
end
|
18
|
+
|
19
|
+
Decidim::EventsManager.publish(
|
20
|
+
event: event,
|
21
|
+
event_class: event_class,
|
22
|
+
resource: feature,
|
23
|
+
recipient_ids: feature.participatory_space.followers.pluck(:id)
|
24
|
+
)
|
25
|
+
end
|
26
|
+
|
27
|
+
private
|
28
|
+
|
29
|
+
def unchanged?(previous_settings, current_settings)
|
30
|
+
current_settings[:allow_answers] == previous_settings[:allow_answers]
|
31
|
+
end
|
32
|
+
|
33
|
+
def survey_opened?(previous_settings, current_settings)
|
34
|
+
current_settings[:allow_answers] == true &&
|
35
|
+
previous_settings[:allow_answers] == false
|
36
|
+
end
|
37
|
+
|
38
|
+
def survey_closed?(previous_settings, current_settings)
|
39
|
+
current_settings[:allow_answers] == false &&
|
40
|
+
previous_settings[:allow_answers] == true
|
41
|
+
end
|
42
|
+
end
|
43
|
+
end
|
44
|
+
end
|
data/config/locales/ca.yml
CHANGED
@@ -7,6 +7,18 @@ ca:
|
|
7
7
|
mandatory: Obligatori
|
8
8
|
question_type: Tipus
|
9
9
|
decidim:
|
10
|
+
events:
|
11
|
+
surveys:
|
12
|
+
survey_closed:
|
13
|
+
email_intro: L'enquesta %{resource_title} a %{participatory_space_title} ha estat tancada.
|
14
|
+
email_outro: Heu rebut aquesta notificació perquè est`as seguint %{participatory_space_title}. Pots deixar de rebre notificacions seguint l'enllaç anterior.
|
15
|
+
email_subject: S'ha acabat una enquesta a %{participatory_space_title}
|
16
|
+
notification_title: L'enquesta <a href="%{resource_path}">%{resource_title}</a> a <a href="%{participatory_space_url}">%{participatory_space_title}</a> ha acabat.
|
17
|
+
survey_opened:
|
18
|
+
email_intro: 'L''enquesta %{resource_title} a %{participatory_space_title} ja està oberta. Pots participar-hi des d''aquesta pàgina:'
|
19
|
+
email_outro: Has rebut aquesta notificació perquè estàs seguint %{participatory_space_title}. Pots deixar de rebre notificacions seguint l'enllaç anterior.
|
20
|
+
email_subject: Una nova enquesta a %{participatory_space_title}
|
21
|
+
notification_title: L'enquesta <a href="%{resource_path}">%{resource_title}</a> en <a href="%{participatory_space_url}">%{participatory_space_title}</a> ja està oberta.
|
10
22
|
features:
|
11
23
|
surveys:
|
12
24
|
actions:
|
data/config/locales/en.yml
CHANGED
@@ -8,6 +8,18 @@ en:
|
|
8
8
|
mandatory: Mandatory
|
9
9
|
question_type: Type
|
10
10
|
decidim:
|
11
|
+
events:
|
12
|
+
surveys:
|
13
|
+
survey_closed:
|
14
|
+
email_intro: The survey %{resource_title} in %{participatory_space_title} has been closed.
|
15
|
+
email_outro: You have received this notification because you are following %{participatory_space_title}. You can stop receiving notifications following the previous link.
|
16
|
+
email_subject: A survey has finished in %{participatory_space_title}
|
17
|
+
notification_title: The survey <a href="%{resource_path}">%{resource_title}</a> in <a href="%{participatory_space_url}">%{participatory_space_title}</a> has finished.
|
18
|
+
survey_opened:
|
19
|
+
email_intro: 'The survey %{resource_title} in %{participatory_space_title} is now open. You can participate in it from this page:'
|
20
|
+
email_outro: You have received this notification because you are following %{participatory_space_title}. You can stop receiving notifications following the previous link.
|
21
|
+
email_subject: A new survey in %{participatory_space_title}
|
22
|
+
notification_title: The survey <a href="%{resource_path}">%{resource_title}</a> in <a href="%{participatory_space_url}">%{participatory_space_title}</a> is now open.
|
11
23
|
features:
|
12
24
|
surveys:
|
13
25
|
actions:
|
data/config/locales/es.yml
CHANGED
@@ -7,6 +7,18 @@ es:
|
|
7
7
|
mandatory: Obligatorio
|
8
8
|
question_type: Tipo
|
9
9
|
decidim:
|
10
|
+
events:
|
11
|
+
surveys:
|
12
|
+
survey_closed:
|
13
|
+
email_intro: Se ha cerrado la encuesta %{resource_title} en %{participatory_space_title}.
|
14
|
+
email_outro: Recibiste esta notificación porque estás siguiendo %{participatory_space_title}. Puedes dejar de recibir notificaciones desde el enlace anterior.
|
15
|
+
email_subject: Ha terminado una encuesta en %{participatory_space_title}
|
16
|
+
notification_title: La encuesta <a href="%{resource_path}">%{resource_title}</a> en <a href="%{participatory_space_url}">%{participatory_space_title}</a> ha terminado.
|
17
|
+
survey_opened:
|
18
|
+
email_intro: 'Ya está abierta la encuesta %{resource_title} en %{participatory_space_title}. Puedes participar desde esta página:'
|
19
|
+
email_outro: Has recibido esta notificación porque estás siguiendo %{participatory_space_title}. Puedes dejar de recibir notificaciones siguiendo el enlace anterior.
|
20
|
+
email_subject: Nueva encuesta en %{participatory_space_title}
|
21
|
+
notification_title: Ya está abierta la encuesta <a href="%{resource_path}">%{resource_title}</a> en <a href="%{participatory_space_url}">%{participatory_space_title}</a>.
|
10
22
|
features:
|
11
23
|
surveys:
|
12
24
|
actions:
|
data/config/locales/eu.yml
CHANGED
@@ -7,6 +7,18 @@ eu:
|
|
7
7
|
mandatory: Derrigorrezkoa
|
8
8
|
question_type: Mota
|
9
9
|
decidim:
|
10
|
+
events:
|
11
|
+
surveys:
|
12
|
+
survey_closed:
|
13
|
+
email_intro: '%{resource_title} inkesta %{participatory_space_title} itxita egon da.'
|
14
|
+
email_outro: Jakinarazpena jaso duzu %{participatory_space_title}jarraituz gero. Aurreko esteka jarraituz jakinarazpenak jasotzeari uztea erabaki dezakezu.
|
15
|
+
email_subject: Inkestaren arabera %{participatory_space_title} amaitu da
|
16
|
+
notification_title: Inkesta <a href="%{resource_path}">%{resource_title}</a> <a href="%{participatory_space_url}">%{participatory_space_title}</a> amaitu da.
|
17
|
+
survey_opened:
|
18
|
+
email_intro: '%{resource_title} inkestaren %{participatory_space_title} zenbakian dago orain. Orri honetan parte har dezakezu:'
|
19
|
+
email_outro: Jakinarazpena jaso duzu %{participatory_space_title}jarraituz gero. Aurreko esteka jarraituz jakinarazpenak jasotzeari uztea erabaki dezakezu.
|
20
|
+
email_subject: '%{participatory_space_title} inkesta berri bat'
|
21
|
+
notification_title: <a href="%{resource_path}">%{resource_title}</a> in <a href="%{participatory_space_url}">%{participatory_space_title}</a> inkesta orain irekita dago.
|
10
22
|
features:
|
11
23
|
surveys:
|
12
24
|
actions:
|
data/config/locales/fi.yml
CHANGED
@@ -7,6 +7,18 @@ fi:
|
|
7
7
|
mandatory: Pakollinen
|
8
8
|
question_type: Tyyppi
|
9
9
|
decidim:
|
10
|
+
events:
|
11
|
+
surveys:
|
12
|
+
survey_closed:
|
13
|
+
email_intro: Kysely %{resource_title} %{participatory_space_title} on suljettu.
|
14
|
+
email_outro: Olet saanut tämän ilmoituksen, koska seuraat %{participatory_space_title}. Voit lopettaa ilmoitusten vastaanottamisen edellisen linkin jälkeen.
|
15
|
+
email_subject: Kysely on päättynyt %{participatory_space_title}
|
16
|
+
notification_title: Kysely <a href="%{resource_path}">%{resource_title}</a> <a href="%{participatory_space_url}">%{participatory_space_title}</a> on päättynyt.
|
17
|
+
survey_opened:
|
18
|
+
email_intro: 'Kysely %{resource_title} %{participatory_space_title} on nyt auki. Voit osallistua siihen tällä sivulla:'
|
19
|
+
email_outro: Olet saanut tämän ilmoituksen, koska seuraat %{participatory_space_title}. Voit lopettaa ilmoitusten vastaanottamisen edellisen linkin jälkeen.
|
20
|
+
email_subject: 'Uusi tutkimus %{participatory_space_title}: ssa'
|
21
|
+
notification_title: Kysely <a href="%{resource_path}">%{resource_title}</a> <a href="%{participatory_space_url}">%{participatory_space_title}</a> on nyt auki.
|
10
22
|
features:
|
11
23
|
surveys:
|
12
24
|
actions:
|
data/config/locales/fr.yml
CHANGED
@@ -7,6 +7,18 @@ fr:
|
|
7
7
|
mandatory: Requis
|
8
8
|
question_type: Type de question
|
9
9
|
decidim:
|
10
|
+
events:
|
11
|
+
surveys:
|
12
|
+
survey_closed:
|
13
|
+
email_intro: Le sondage %{resource_title} dans %{participatory_space_title} a été fermé.
|
14
|
+
email_outro: Vous avez reçu cette notification, car vous suivez %{participatory_space_title}. Vous pouvez arrêter de recevoir des notifications en suivant le lien précédent.
|
15
|
+
email_subject: Une enquête est terminée à %{participatory_space_title}
|
16
|
+
notification_title: Le sondage <a href="%{resource_path}">%{resource_title}</a> dans <a href="%{participatory_space_url}">%{participatory_space_title}</a> est terminé.
|
17
|
+
survey_opened:
|
18
|
+
email_intro: 'Le sondage %{resource_title} dans %{participatory_space_title} est maintenant ouvert. Vous pouvez y participer à partir de cette page:'
|
19
|
+
email_outro: Vous avez reçu cette notification, car vous suivez %{participatory_space_title}. Vous pouvez arrêter de recevoir des notifications en suivant le lien précédent.
|
20
|
+
email_subject: Un nouveau sondage en %{participatory_space_title}
|
21
|
+
notification_title: Le sondage <a href="%{resource_path}">%{resource_title}</a> dans <a href="%{participatory_space_url}">%{participatory_space_title}</a> est maintenant ouvert.
|
10
22
|
features:
|
11
23
|
surveys:
|
12
24
|
actions:
|
data/config/locales/gl.yml
CHANGED
@@ -7,6 +7,18 @@ gl:
|
|
7
7
|
mandatory: Obrigatorio
|
8
8
|
question_type: Tipo
|
9
9
|
decidim:
|
10
|
+
events:
|
11
|
+
surveys:
|
12
|
+
survey_closed:
|
13
|
+
email_intro: A enquisa %{resource_title} en %{participatory_space_title} foi pechada.
|
14
|
+
email_outro: Recibiches esta notificación porque estás seguindo %{participatory_space_title}. Podes deixar de recibir notificacións seguindo a ligazón anterior.
|
15
|
+
email_subject: Acaba unha enquisa en %{participatory_space_title}
|
16
|
+
notification_title: A enquisa <a href="%{resource_path}">%{resource_title}</a> en <a href="%{participatory_space_url}">%{participatory_space_title}</a> rematou.
|
17
|
+
survey_opened:
|
18
|
+
email_intro: 'A enquisa %{resource_title} en %{participatory_space_title} está agora aberta. Podes participar nesta páxina dende esta páxina:'
|
19
|
+
email_outro: Recibiches esta notificación porque estás seguindo %{participatory_space_title}. Podes deixar de recibir notificacións seguindo a ligazón anterior.
|
20
|
+
email_subject: Unha nova enquisa en %{participatory_space_title}
|
21
|
+
notification_title: A enquisa <a href="%{resource_path}">%{resource_title}</a> en <a href="%{participatory_space_url}">%{participatory_space_title}</a> está agora aberta.
|
10
22
|
features:
|
11
23
|
surveys:
|
12
24
|
actions:
|
data/config/locales/it.yml
CHANGED
@@ -7,6 +7,18 @@ it:
|
|
7
7
|
mandatory: Obbligatorio
|
8
8
|
question_type: Tipo
|
9
9
|
decidim:
|
10
|
+
events:
|
11
|
+
surveys:
|
12
|
+
survey_closed:
|
13
|
+
email_intro: Il sondaggio %{resource_title} in %{participatory_space_title} è stato chiuso.
|
14
|
+
email_outro: Hai ricevuto questa notifica perché stai seguendo %{participatory_space_title}. È possibile interrompere la ricezione di notifiche seguendo il collegamento precedente.
|
15
|
+
email_subject: Un sondaggio è terminato in %{participatory_space_title}
|
16
|
+
notification_title: L'indagine <a href="%{resource_path}">%{resource_title}</a> in <a href="%{participatory_space_url}">%{participatory_space_title}</a> è finita.
|
17
|
+
survey_opened:
|
18
|
+
email_intro: 'Il sondaggio %{resource_title} in %{participatory_space_title} è ora aperto. Puoi partecipare da questa pagina:'
|
19
|
+
email_outro: Hai ricevuto questa notifica perché stai seguendo %{participatory_space_title}. È possibile interrompere la ricezione di notifiche seguendo il collegamento precedente.
|
20
|
+
email_subject: Una nuova indagine su %{participatory_space_title}
|
21
|
+
notification_title: Il sondaggio <a href="%{resource_path}">%{resource_title}</a> in <a href="%{participatory_space_url}">%{participatory_space_title}</a> è ora aperto.
|
10
22
|
features:
|
11
23
|
surveys:
|
12
24
|
actions:
|
data/config/locales/nl.yml
CHANGED
@@ -7,6 +7,18 @@ nl:
|
|
7
7
|
mandatory: Verplicht
|
8
8
|
question_type: Type
|
9
9
|
decidim:
|
10
|
+
events:
|
11
|
+
surveys:
|
12
|
+
survey_closed:
|
13
|
+
email_intro: De enquête %{resource_title} in %{participatory_space_title} is gesloten.
|
14
|
+
email_outro: Je hebt deze melding ontvangen omdat je %{participatory_space_title}volgt. Je kunt stoppen met het ontvangen van meldingen na de vorige link.
|
15
|
+
email_subject: Een enquête is voltooid in %{participatory_space_title}
|
16
|
+
notification_title: De enquête <a href="%{resource_path}">%{resource_title}</a> in <a href="%{participatory_space_url}">%{participatory_space_title}</a> is voltooid.
|
17
|
+
survey_opened:
|
18
|
+
email_intro: 'De enquête %{resource_title} in %{participatory_space_title} is nu geopend. U kunt vanaf deze pagina deelnemen:'
|
19
|
+
email_outro: Je hebt deze melding ontvangen omdat je %{participatory_space_title}volgt. Je kunt stoppen met het ontvangen van meldingen na de vorige link.
|
20
|
+
email_subject: Een nieuwe enquête in %{participatory_space_title}
|
21
|
+
notification_title: De enquête <a href="%{resource_path}">%{resource_title}</a> in <a href="%{participatory_space_url}">%{participatory_space_title}</a> is nu geopend.
|
10
22
|
features:
|
11
23
|
surveys:
|
12
24
|
actions:
|
data/config/locales/pl.yml
CHANGED
@@ -7,6 +7,18 @@ pl:
|
|
7
7
|
mandatory: Obowiązkowy
|
8
8
|
question_type: Rodzaj
|
9
9
|
decidim:
|
10
|
+
events:
|
11
|
+
surveys:
|
12
|
+
survey_closed:
|
13
|
+
email_intro: Ankieta %{resource_title} w %{participatory_space_title} została zamknięta.
|
14
|
+
email_outro: Otrzymałeś to powiadomienie, ponieważ obserwujesz %{participatory_space_title}. Możesz przestać otrzymywać powiadomienia po poprzednim linku.
|
15
|
+
email_subject: Ankieta zakończyła się w %{participatory_space_title}
|
16
|
+
notification_title: Ankieta <a href="%{resource_path}">%{resource_title}</a> w <a href="%{participatory_space_url}">%{participatory_space_title}</a> została zakończona.
|
17
|
+
survey_opened:
|
18
|
+
email_intro: 'Ankieta %{resource_title} w %{participatory_space_title} jest teraz otwarta. Możesz wziąć w nim udział z tej strony:'
|
19
|
+
email_outro: Otrzymałeś to powiadomienie, ponieważ obserwujesz %{participatory_space_title}. Możesz przestać otrzymywać powiadomienia po poprzednim linku.
|
20
|
+
email_subject: Nowa ankieta w %{participatory_space_title}
|
21
|
+
notification_title: Ankieta <a href="%{resource_path}">%{resource_title}</a> w <a href="%{participatory_space_url}">%{participatory_space_title}</a> jest teraz otwarta.
|
10
22
|
features:
|
11
23
|
surveys:
|
12
24
|
actions:
|
data/config/locales/pt-BR.yml
CHANGED
@@ -7,6 +7,18 @@ pt-BR:
|
|
7
7
|
mandatory: Obrigatório
|
8
8
|
question_type: Tipo
|
9
9
|
decidim:
|
10
|
+
events:
|
11
|
+
surveys:
|
12
|
+
survey_closed:
|
13
|
+
email_intro: A pesquisa %{resource_title} em %{participatory_space_title} foi fechada.
|
14
|
+
email_outro: Você recebeu esta notificação porque está seguindo %{participatory_space_title}. Você pode parar de receber notificações após o link anterior.
|
15
|
+
email_subject: Uma pesquisa terminou em %{participatory_space_title}
|
16
|
+
notification_title: A pesquisa <a href="%{resource_path}">%{resource_title}</a> em <a href="%{participatory_space_url}">%{participatory_space_title}</a> terminou.
|
17
|
+
survey_opened:
|
18
|
+
email_intro: 'A pesquisa %{resource_title} em %{participatory_space_title} está agora aberta. Você pode participar desta página:'
|
19
|
+
email_outro: Você recebeu esta notificação porque está seguindo %{participatory_space_title}. Você pode parar de receber notificações após o link anterior.
|
20
|
+
email_subject: Uma nova pesquisa em %{participatory_space_title}
|
21
|
+
notification_title: A pesquisa <a href="%{resource_path}">%{resource_title}</a> em <a href="%{participatory_space_url}">%{participatory_space_title}</a> está agora aberta.
|
10
22
|
features:
|
11
23
|
surveys:
|
12
24
|
actions:
|
data/config/locales/pt.yml
CHANGED
@@ -7,6 +7,18 @@ pt:
|
|
7
7
|
mandatory: Obrigatório
|
8
8
|
question_type: Tipo
|
9
9
|
decidim:
|
10
|
+
events:
|
11
|
+
surveys:
|
12
|
+
survey_closed:
|
13
|
+
email_intro: A pesquisa %{resource_title} em %{participatory_space_title} foi fechada.
|
14
|
+
email_outro: Você recebeu esta notificação porque está seguindo %{participatory_space_title}. Você pode parar de receber notificações após o link anterior.
|
15
|
+
email_subject: Uma pesquisa terminou em %{participatory_space_title}
|
16
|
+
notification_title: A pesquisa <a href="%{resource_path}">%{resource_title}</a> em <a href="%{participatory_space_url}">%{participatory_space_title}</a> terminou.
|
17
|
+
survey_opened:
|
18
|
+
email_intro: 'A pesquisa %{resource_title} em %{participatory_space_title} está agora aberta. Você pode participar desta página:'
|
19
|
+
email_outro: Você recebeu esta notificação porque está seguindo %{participatory_space_title}. Você pode parar de receber notificações após o link anterior.
|
20
|
+
email_subject: Uma nova pesquisa em %{participatory_space_title}
|
21
|
+
notification_title: A pesquisa <a href="%{resource_path}">%{resource_title}</a> em <a href="%{participatory_space_url}">%{participatory_space_title}</a> está agora aberta.
|
10
22
|
features:
|
11
23
|
surveys:
|
12
24
|
actions:
|
data/config/locales/sv.yml
CHANGED
@@ -7,6 +7,18 @@ sv:
|
|
7
7
|
mandatory: Obligatorisk
|
8
8
|
question_type: Typ
|
9
9
|
decidim:
|
10
|
+
events:
|
11
|
+
surveys:
|
12
|
+
survey_closed:
|
13
|
+
email_intro: Undersökningen %{resource_title} i %{participatory_space_title} har stängts.
|
14
|
+
email_outro: Du har fått den här meddelandet eftersom du följer %{participatory_space_title}. Du kan sluta ta emot meddelanden efter föregående länk.
|
15
|
+
email_subject: En undersökning har slutförts på %{participatory_space_title}
|
16
|
+
notification_title: Undersökningen <a href="%{resource_path}">%{resource_title}</a> i <a href="%{participatory_space_url}">%{participatory_space_title}</a> har slutförts.
|
17
|
+
survey_opened:
|
18
|
+
email_intro: 'Undersökningen %{resource_title} i %{participatory_space_title} är nu öppen. Du kan delta i det från den här sidan:'
|
19
|
+
email_outro: Du har fått den här meddelandet eftersom du följer %{participatory_space_title}. Du kan sluta ta emot meddelanden efter föregående länk.
|
20
|
+
email_subject: En ny undersökning i %{participatory_space_title}
|
21
|
+
notification_title: Undersökningen <a href="%{resource_path}">%{resource_title}</a> i <a href="%{participatory_space_url}">%{participatory_space_title}</a> är nu öppen.
|
10
22
|
features:
|
11
23
|
surveys:
|
12
24
|
actions:
|
data/config/locales/uk.yml
CHANGED
@@ -20,6 +20,16 @@ module Decidim
|
|
20
20
|
config.abilities += ["Decidim::Surveys::Abilities::CurrentUserAbility"]
|
21
21
|
end
|
22
22
|
end
|
23
|
+
|
24
|
+
initializer "decidim_changes" do
|
25
|
+
Decidim::SettingsChange.subscribe "surveys" do |changes|
|
26
|
+
Decidim::Surveys::SettingsChangeJob.perform_later(
|
27
|
+
changes[:feature_id],
|
28
|
+
changes[:previous_settings],
|
29
|
+
changes[:current_settings]
|
30
|
+
)
|
31
|
+
end
|
32
|
+
end
|
23
33
|
end
|
24
34
|
end
|
25
35
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: decidim-surveys
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.10.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Josep Jaume Rey Peroy
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2018-
|
13
|
+
date: 2018-03-27 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: decidim-core
|
@@ -18,14 +18,14 @@ dependencies:
|
|
18
18
|
requirements:
|
19
19
|
- - '='
|
20
20
|
- !ruby/object:Gem::Version
|
21
|
-
version: 0.
|
21
|
+
version: 0.10.0
|
22
22
|
type: :runtime
|
23
23
|
prerelease: false
|
24
24
|
version_requirements: !ruby/object:Gem::Requirement
|
25
25
|
requirements:
|
26
26
|
- - '='
|
27
27
|
- !ruby/object:Gem::Version
|
28
|
-
version: 0.
|
28
|
+
version: 0.10.0
|
29
29
|
- !ruby/object:Gem::Dependency
|
30
30
|
name: jquery-tmpl-rails
|
31
31
|
requirement: !ruby/object:Gem::Requirement
|
@@ -46,42 +46,42 @@ dependencies:
|
|
46
46
|
requirements:
|
47
47
|
- - '='
|
48
48
|
- !ruby/object:Gem::Version
|
49
|
-
version: 0.
|
49
|
+
version: 0.10.0
|
50
50
|
type: :development
|
51
51
|
prerelease: false
|
52
52
|
version_requirements: !ruby/object:Gem::Requirement
|
53
53
|
requirements:
|
54
54
|
- - '='
|
55
55
|
- !ruby/object:Gem::Version
|
56
|
-
version: 0.
|
56
|
+
version: 0.10.0
|
57
57
|
- !ruby/object:Gem::Dependency
|
58
58
|
name: decidim-dev
|
59
59
|
requirement: !ruby/object:Gem::Requirement
|
60
60
|
requirements:
|
61
61
|
- - '='
|
62
62
|
- !ruby/object:Gem::Version
|
63
|
-
version: 0.
|
63
|
+
version: 0.10.0
|
64
64
|
type: :development
|
65
65
|
prerelease: false
|
66
66
|
version_requirements: !ruby/object:Gem::Requirement
|
67
67
|
requirements:
|
68
68
|
- - '='
|
69
69
|
- !ruby/object:Gem::Version
|
70
|
-
version: 0.
|
70
|
+
version: 0.10.0
|
71
71
|
- !ruby/object:Gem::Dependency
|
72
72
|
name: decidim-participatory_processes
|
73
73
|
requirement: !ruby/object:Gem::Requirement
|
74
74
|
requirements:
|
75
75
|
- - '='
|
76
76
|
- !ruby/object:Gem::Version
|
77
|
-
version: 0.
|
77
|
+
version: 0.10.0
|
78
78
|
type: :development
|
79
79
|
prerelease: false
|
80
80
|
version_requirements: !ruby/object:Gem::Requirement
|
81
81
|
requirements:
|
82
82
|
- - '='
|
83
83
|
- !ruby/object:Gem::Version
|
84
|
-
version: 0.
|
84
|
+
version: 0.10.0
|
85
85
|
description: A surveys component for decidim's participatory spaces.
|
86
86
|
email:
|
87
87
|
- josepjaume@gmail.com
|
@@ -106,12 +106,15 @@ files:
|
|
106
106
|
- app/controllers/decidim/surveys/admin/surveys_controller.rb
|
107
107
|
- app/controllers/decidim/surveys/application_controller.rb
|
108
108
|
- app/controllers/decidim/surveys/surveys_controller.rb
|
109
|
+
- app/events/decidim/surveys/closed_survey_event.rb
|
110
|
+
- app/events/decidim/surveys/opened_survey_event.rb
|
109
111
|
- app/forms/decidim/surveys/admin/survey_form.rb
|
110
112
|
- app/forms/decidim/surveys/admin/survey_question_answer_option_form.rb
|
111
113
|
- app/forms/decidim/surveys/admin/survey_question_form.rb
|
112
114
|
- app/forms/decidim/surveys/survey_answer_form.rb
|
113
115
|
- app/forms/decidim/surveys/survey_form.rb
|
114
116
|
- app/helpers/decidim/surveys/admin/application_helper.rb
|
117
|
+
- app/jobs/decidim/surveys/settings_change_job.rb
|
115
118
|
- app/models/decidim/surveys/abilities/admin_ability.rb
|
116
119
|
- app/models/decidim/surveys/abilities/current_user_ability.rb
|
117
120
|
- app/models/decidim/surveys/abilities/participatory_process_admin_ability.rb
|
@@ -175,7 +178,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
175
178
|
version: '0'
|
176
179
|
requirements: []
|
177
180
|
rubyforge_project:
|
178
|
-
rubygems_version: 2.7.
|
181
|
+
rubygems_version: 2.7.6
|
179
182
|
signing_key:
|
180
183
|
specification_version: 4
|
181
184
|
summary: Decidim surveys module
|