decidim-debates 0.9.0

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.
Files changed (66) hide show
  1. checksums.yaml +7 -0
  2. data/README.md +15 -0
  3. data/Rakefile +3 -0
  4. data/app/assets/images/decidim/debates/icon.svg +1 -0
  5. data/app/commands/decidim/debates/admin/create_debate.rb +57 -0
  6. data/app/commands/decidim/debates/admin/update_debate.rb +46 -0
  7. data/app/commands/decidim/debates/create_debate.rb +68 -0
  8. data/app/controllers/decidim/debates/admin/application_controller.rb +15 -0
  9. data/app/controllers/decidim/debates/admin/debates_controller.rb +73 -0
  10. data/app/controllers/decidim/debates/application_controller.rb +13 -0
  11. data/app/controllers/decidim/debates/debates_controller.rb +78 -0
  12. data/app/events/decidim/debates/create_debate_event.rb +42 -0
  13. data/app/forms/decidim/debates/admin/debate_form.rb +33 -0
  14. data/app/forms/decidim/debates/debate_form.rb +25 -0
  15. data/app/helpers/decidim/debates/application_helper.rb +12 -0
  16. data/app/models/decidim/debates/abilities/admin/admin_ability.rb +21 -0
  17. data/app/models/decidim/debates/abilities/admin/participatory_process_admin_ability.rb +23 -0
  18. data/app/models/decidim/debates/abilities/admin/participatory_process_moderator_ability.rb +21 -0
  19. data/app/models/decidim/debates/abilities/current_user_ability.rb +49 -0
  20. data/app/models/decidim/debates/application_record.rb +10 -0
  21. data/app/models/decidim/debates/debate.rb +103 -0
  22. data/app/presenters/decidim/debates/debate_presenter.rb +20 -0
  23. data/app/presenters/decidim/debates/official_author_presenter.rb +34 -0
  24. data/app/services/decidim/debates/debate_search.rb +38 -0
  25. data/app/views/decidim/debates/admin/debates/_form.html.erb +36 -0
  26. data/app/views/decidim/debates/admin/debates/edit.html.erb +7 -0
  27. data/app/views/decidim/debates/admin/debates/index.html.erb +52 -0
  28. data/app/views/decidim/debates/admin/debates/new.html.erb +7 -0
  29. data/app/views/decidim/debates/debates/_count.html.erb +1 -0
  30. data/app/views/decidim/debates/debates/_debate.html.erb +42 -0
  31. data/app/views/decidim/debates/debates/_debates.html.erb +4 -0
  32. data/app/views/decidim/debates/debates/_filters.html.erb +20 -0
  33. data/app/views/decidim/debates/debates/_filters_small_view.html.erb +18 -0
  34. data/app/views/decidim/debates/debates/_share.html.erb +33 -0
  35. data/app/views/decidim/debates/debates/index.html.erb +27 -0
  36. data/app/views/decidim/debates/debates/index.js.erb +9 -0
  37. data/app/views/decidim/debates/debates/new.html.erb +43 -0
  38. data/app/views/decidim/debates/debates/show.html.erb +80 -0
  39. data/config/locales/ca.yml +114 -0
  40. data/config/locales/en.yml +117 -0
  41. data/config/locales/es.yml +114 -0
  42. data/config/locales/eu.yml +114 -0
  43. data/config/locales/fi.yml +114 -0
  44. data/config/locales/fr.yml +114 -0
  45. data/config/locales/gl.yml +114 -0
  46. data/config/locales/it.yml +114 -0
  47. data/config/locales/nl.yml +114 -0
  48. data/config/locales/pl.yml +116 -0
  49. data/config/locales/pt-BR.yml +114 -0
  50. data/config/locales/pt.yml +114 -0
  51. data/config/locales/ru.yml +5 -0
  52. data/config/locales/sv.yml +114 -0
  53. data/config/locales/uk.yml +5 -0
  54. data/db/migrate/20170118141619_create_debates.rb +18 -0
  55. data/db/migrate/20180117100413_add_debate_information_updates.rb +7 -0
  56. data/db/migrate/20180118132243_add_author_to_debates.rb +7 -0
  57. data/db/migrate/20180119150434_add_reference_to_debates.rb +12 -0
  58. data/db/migrate/20180122090505_add_user_group_author_to_debates.rb +7 -0
  59. data/lib/decidim/debates/admin.rb +10 -0
  60. data/lib/decidim/debates/admin_engine.rb +33 -0
  61. data/lib/decidim/debates/engine.rb +26 -0
  62. data/lib/decidim/debates/feature.rb +55 -0
  63. data/lib/decidim/debates/test/factories.rb +52 -0
  64. data/lib/decidim/debates/version.rb +10 -0
  65. data/lib/decidim/debates.rb +12 -0
  66. metadata +197 -0
@@ -0,0 +1,114 @@
1
+ es:
2
+ activemodel:
3
+ attributes:
4
+ debate:
5
+ category_id: Categoría
6
+ description: Descripción
7
+ end_time: Fecha de fin
8
+ information_updates: Actualizaciones de información
9
+ instructions: Instrucciones para participar
10
+ start_time: Fecha de inicio
11
+ title: Título
12
+ user_group_id: Crear debate como
13
+ decidim:
14
+ debates:
15
+ actions:
16
+ confirm_destroy: '¿Seguro que quieres borrar el debate?'
17
+ destroy: Borrar
18
+ edit: Editar
19
+ new: Nuevo %{name}
20
+ title: Acciones
21
+ admin:
22
+ debates:
23
+ create:
24
+ invalid: Ha habido un problema al crear el debate.
25
+ success: Debate creado con éxito.
26
+ destroy:
27
+ success: El debate se borró con éxito.
28
+ edit:
29
+ title: Editar debate
30
+ update: Actualizar debate
31
+ index:
32
+ title: Debates
33
+ new:
34
+ create: Crear debate
35
+ title: Nuevo debate
36
+ update:
37
+ invalid: Ha habido un problema al actualizar este debate.
38
+ success: Debate actualizado con éxito.
39
+ models:
40
+ debate:
41
+ name: Debate
42
+ debates:
43
+ count:
44
+ debates_count:
45
+ one: "%{count} debate"
46
+ other: "%{count} debates"
47
+ create:
48
+ invalid: Ha habido un problema al crear el debate.
49
+ success: Debate creado con éxito.
50
+ debate:
51
+ comments:
52
+ one: Comentario
53
+ other: Comentarios
54
+ participate: Participar
55
+ filters:
56
+ all: Todos
57
+ category: Categoría
58
+ category_prompt: Selecciona una categoría
59
+ citizens: Ciudadanía
60
+ official: Oficial
61
+ origin: Origen
62
+ search: Buscar
63
+ filters_small_view:
64
+ close_modal: Cerrar ventana
65
+ filter: Filtrar
66
+ filter_by: Filtrar por
67
+ unfold: Desplegar
68
+ index:
69
+ new_debate: Nuevo debate
70
+ new:
71
+ back: Atrás
72
+ create: Crear
73
+ select_a_category: Por favor, selecciona una categoría
74
+ title: Nuevo debate
75
+ share:
76
+ close_window: Cerrar ventana
77
+ share: Compartir
78
+ share_link: Compartir enlace
79
+ show:
80
+ comments: Comentarios
81
+ report: Informe
82
+ models:
83
+ debate:
84
+ fields:
85
+ end_time: Fecha de finalización
86
+ official_debate: Debate oficial
87
+ start_time: Fecha de inicio
88
+ title: Título
89
+ events:
90
+ debates:
91
+ create_debate_event:
92
+ space_followers:
93
+ email_intro: |-
94
+ Se ha creado un nuevo debate en el espacio participativo %{space_title}, compruébalo y contribuye:
95
+ email_outro: Has recibido esta notificación porque estás siguiendo a %{space_title}. Puedes dejar de recibir notificaciones siguiendo el enlace anterior.
96
+ email_subject: Nuevo debate en %{space_title}
97
+ notification_title: El debate <a href="%{resource_path}">%{resource_title}</a> fue creado el <a href="%{space_path}">%{space_title}</a>.
98
+ user_followers:
99
+ email_intro: |-
100
+ %{author_name} %{author_nickname}, a quién sigues, ha creado un nuevo debate, compruébalo y contribuye:
101
+ email_outro: Has recibido esta notificación porque estás siguiendo a %{author_nickname}. Puedes dejar de recibir notificaciones siguiendo el enlace anterior.
102
+ email_subject: Nuevo debate de %{author_nickname}
103
+ notification_title: El debate <a href="%{resource_path}">%{resource_title}</a> fue creado por <a href="%{author_path}">%{author_name} %{author_nickname}</a>.
104
+ features:
105
+ debates:
106
+ actions:
107
+ create: Crear
108
+ name: Debates
109
+ settings:
110
+ global:
111
+ comments_enabled: Comentarios habilitados
112
+ step:
113
+ comments_blocked: Comentarios bloqueados
114
+ creation_enabled: Habilitar la creación de debates por los usuarios
@@ -0,0 +1,114 @@
1
+ eu:
2
+ activemodel:
3
+ attributes:
4
+ debate:
5
+ category_id: Kategoria
6
+ description: deskribapena
7
+ end_time: Amaitzen du
8
+ information_updates: Informazioaren eguneratzeak
9
+ instructions: Parte hartzeko argibideak
10
+ start_time: Hasi da
11
+ title: Izenburua
12
+ user_group_id: Sortu eztabaida gisa
13
+ decidim:
14
+ debates:
15
+ actions:
16
+ confirm_destroy: Ziur zaude?
17
+ destroy: ezabatu
18
+ edit: Editatu
19
+ new: '%{name} berria'
20
+ title: Ekintzak
21
+ admin:
22
+ debates:
23
+ create:
24
+ invalid: Arazo bat izan da eztabaida sortzen ari den bitartean.
25
+ success: Debate sortu da behar bezala.
26
+ destroy:
27
+ success: Debata zuzen ezabatu da.
28
+ edit:
29
+ title: Editatu eztabaida
30
+ update: Eguneratu eztabaida
31
+ index:
32
+ title: eztabaidak
33
+ new:
34
+ create: Sortu eztabaida
35
+ title: Berri eztabaida
36
+ update:
37
+ invalid: Arazo bat izan da eztabaida hau eguneratzean.
38
+ success: Debate arrakastaz eguneratu da.
39
+ models:
40
+ debate:
41
+ name: Debate
42
+ debates:
43
+ count:
44
+ debates_count:
45
+ one: "%{count} eztabaida"
46
+ other: "%{count} eztabaidak"
47
+ create:
48
+ invalid: Arazo bat izan da eztabaida sortzen ari den bitartean.
49
+ success: Debate sortu da behar bezala.
50
+ debate:
51
+ comments:
52
+ one: Iruzkina
53
+ other: Oharrak
54
+ participate: Parte hartu
55
+ filters:
56
+ all: guztiak
57
+ category: Kategoria
58
+ category_prompt: Aukeratu kategoria bat
59
+ citizens: Hiritarrak
60
+ official: Ofiziala
61
+ origin: Origin
62
+ search: Search
63
+ filters_small_view:
64
+ close_modal: Itxi modal
65
+ filter: Filter
66
+ filter_by: Iragazi arabera
67
+ unfold: Zabaldu
68
+ index:
69
+ new_debate: Berri eztabaida
70
+ new:
71
+ back: Back
72
+ create: Sortu
73
+ select_a_category: Hautatu kategoria bat
74
+ title: Berri eztabaida
75
+ share:
76
+ close_window: Itxi leihoa
77
+ share: Share
78
+ share_link: Partekatu esteka
79
+ show:
80
+ comments: Oharrak
81
+ report: txostena
82
+ models:
83
+ debate:
84
+ fields:
85
+ end_time: Amaiera data
86
+ official_debate: Ofizial eztabaida
87
+ start_time: Hasiera data
88
+ title: Izenburua
89
+ events:
90
+ debates:
91
+ create_debate_event:
92
+ space_followers:
93
+ email_intro: |-
94
+ Kaixo, %{space_title} partaidetzako espazioan eztabaida berria sortu da, egiaztatu eta lagundu:
95
+ email_outro: Jakinarazpen hori jaso duzu %{space_title} partaidetzazko espazioa jarraituz gero. Aurreko esteka jarraituz jakinarazpenak jasotzeari uztea erabaki dezakezu.
96
+ email_subject: Eztabaida berria %{space_title}
97
+ notification_title: <a href="%{resource_path}">%{resource_title}</a> eztabaida sortu zen <a href="%{space_path}">%{space_title}</a>.
98
+ user_followers:
99
+ email_intro: |-
100
+ Kaixo, %{author_name} %{author_nickname}, jarraitzen ari zarenak, eztabaida berri bat sortu du, egiaztatu eta lagundu:
101
+ email_outro: Jakinarazpena jaso duzu %{author_nickname} jarraituz gero. Aurreko esteka jarraituz jakinarazpenak jasotzeari uztea erabaki dezakezu.
102
+ email_subject: Eztabaida berria %{author_nickname}-ri
103
+ notification_title: <a href="%{resource_path}">%{resource_title}</a> eztabaida sortu zen <a href="%{author_path}">%{author_name} %{author_nickname}</a>.
104
+ features:
105
+ debates:
106
+ actions:
107
+ create: Sortu
108
+ name: eztabaidak
109
+ settings:
110
+ global:
111
+ comments_enabled: Iruzkinak gaituta
112
+ step:
113
+ comments_blocked: Iruzkinak blokeatuta
114
+ creation_enabled: Erabiltzaileek gaitutako eztabaida sortzea
@@ -0,0 +1,114 @@
1
+ fi:
2
+ activemodel:
3
+ attributes:
4
+ debate:
5
+ category_id: Kategoria
6
+ description: Kuvaus
7
+ end_time: Päättymisaika
8
+ information_updates: Tietojen päivitykset
9
+ instructions: Osallistumisohjeet
10
+ start_time: Alkamisaika
11
+ title: Otsikko
12
+ user_group_id: Luo keskustelu käyttäjänä
13
+ decidim:
14
+ debates:
15
+ actions:
16
+ confirm_destroy: Oletko varma?
17
+ destroy: Poista
18
+ edit: Muokkaa
19
+ new: Uusi %{name}
20
+ title: Toiminnot
21
+ admin:
22
+ debates:
23
+ create:
24
+ invalid: Luotaessa keskustelua tapahtui virhe.
25
+ success: Keskustelu luotu onnistuneesti.
26
+ destroy:
27
+ success: Keskustelu poistettu onnistuneesti.
28
+ edit:
29
+ title: Muokkaa keskustelua
30
+ update: Päivitä keskustelu
31
+ index:
32
+ title: Keskustelut
33
+ new:
34
+ create: Luo keskustelu
35
+ title: Uusi keskustelu
36
+ update:
37
+ invalid: Keskustelun päivittämisessä tapahtui virhe.
38
+ success: Keskustelu päivitetty onnistuneesti.
39
+ models:
40
+ debate:
41
+ name: Keskustelu
42
+ debates:
43
+ count:
44
+ debates_count:
45
+ one: "%{count} keskustelu"
46
+ other: "%{count} keskustelua"
47
+ create:
48
+ invalid: Luotaessa keskustelua tapahtui virhe.
49
+ success: Keskustelu luotu onnistuneesti.
50
+ debate:
51
+ comments:
52
+ one: Kommentti
53
+ other: Kommenttia
54
+ participate: Osallistu
55
+ filters:
56
+ all: Kaikki
57
+ category: Kategoria
58
+ category_prompt: Valitse kategoria
59
+ citizens: Kansalaiset
60
+ official: Virallinen
61
+ origin: Alkuperä
62
+ search: Hae
63
+ filters_small_view:
64
+ close_modal: Sulje ikkuna
65
+ filter: Suodata
66
+ filter_by: Suodata
67
+ unfold: Avaa
68
+ index:
69
+ new_debate: Uusi keskustelu
70
+ new:
71
+ back: Takaisin
72
+ create: Luo
73
+ select_a_category: Valitse kategoria
74
+ title: Uusi keskustelu
75
+ share:
76
+ close_window: Sulje ikkuna
77
+ share: Jaa
78
+ share_link: Jaa linkki
79
+ show:
80
+ comments: Kommentit
81
+ report: Raportti
82
+ models:
83
+ debate:
84
+ fields:
85
+ end_time: Päättymispäivä
86
+ official_debate: Virallinen keskustelu
87
+ start_time: Aloituspäivämäärä
88
+ title: Otsikko
89
+ events:
90
+ debates:
91
+ create_debate_event:
92
+ space_followers:
93
+ email_intro: |-
94
+ Hei, %{space_title} osallistuvaan tilaan on luotu uusi keskustelu, tarkista se ja osallistu:
95
+ email_outro: Olet saanut tämän ilmoituksen, koska noudatat %{space_title} osallistumistilaa. Voit lopettaa ilmoitusten vastaanottamisen edellisen linkin jälkeen.
96
+ email_subject: Uusi keskustelu %{space_title}
97
+ notification_title: <a href="%{resource_path}">%{resource_title}</a> keskustelu luotiin <a href="%{space_path}">%{space_title}</a>.
98
+ user_followers:
99
+ email_intro: |-
100
+ Hei, %{author_name} %{author_nickname}, jonka seuraat, on luonut uuden keskustelun, tarkista sen ja edistä:
101
+ email_outro: Olet saanut tämän ilmoituksen, koska seuraat %{author_nickname}. Voit lopettaa ilmoitusten vastaanottamisen edellisen linkin jälkeen.
102
+ email_subject: Uusi keskustelu %{author_nickname}
103
+ notification_title: <a href="%{resource_path}">%{resource_title}</a> keskustelu luotiin <a href="%{author_path}">%{author_name} %{author_nickname}</a>.
104
+ features:
105
+ debates:
106
+ actions:
107
+ create: Luo
108
+ name: Keskustelut
109
+ settings:
110
+ global:
111
+ comments_enabled: Kommentointi käytössä
112
+ step:
113
+ comments_blocked: Kommentointi estetty
114
+ creation_enabled: Keskustelujen luominen käyttäjien toimesta sallittu
@@ -0,0 +1,114 @@
1
+ fr:
2
+ activemodel:
3
+ attributes:
4
+ debate:
5
+ category_id: Catégorie
6
+ description: Description
7
+ end_time: Prend fin à
8
+ information_updates: Informations mises à jour
9
+ instructions: Instructions pour participer
10
+ start_time: Commence à
11
+ title: Titre
12
+ user_group_id: Créer un débat en tant que
13
+ decidim:
14
+ debates:
15
+ actions:
16
+ confirm_destroy: Êtes-vous certain ?
17
+ destroy: Effacer
18
+ edit: Modifier
19
+ new: Nouveau %{name}
20
+ title: Actions
21
+ admin:
22
+ debates:
23
+ create:
24
+ invalid: Il y a eu un problème lors de la création du débat.
25
+ success: Débat créé avec succès.
26
+ destroy:
27
+ success: Débat supprimé avec succès.
28
+ edit:
29
+ title: Modifier le débat
30
+ update: Actualiser le débat
31
+ index:
32
+ title: Débats
33
+ new:
34
+ create: Créer un débat
35
+ title: Nouveau débat
36
+ update:
37
+ invalid: Il y a eu un problème lors de la mise à jour de ce débat.
38
+ success: Débat mis à jour avec succès.
39
+ models:
40
+ debate:
41
+ name: Débat
42
+ debates:
43
+ count:
44
+ debates_count:
45
+ one: "%{count} débat"
46
+ other: "%{count} débats"
47
+ create:
48
+ invalid: Il y a eu un problème lors de la création du débat.
49
+ success: Débat créé avec succès.
50
+ debate:
51
+ comments:
52
+ one: Commentaire
53
+ other: Commentaires
54
+ participate: Participer
55
+ filters:
56
+ all: Tout
57
+ category: Catégorie
58
+ category_prompt: Choisir une catégorie
59
+ citizens: Citoyens
60
+ official: Officiel
61
+ origin: Origine
62
+ search: Chercher
63
+ filters_small_view:
64
+ close_modal: Fermer
65
+ filter: Filtre
66
+ filter_by: Filtrer par
67
+ unfold: Déplier
68
+ index:
69
+ new_debate: Nouveau débat
70
+ new:
71
+ back: Retour
72
+ create: Créer
73
+ select_a_category: Veuillez sélectionner une catégorie
74
+ title: Nouveau débat
75
+ share:
76
+ close_window: Fermer la fenêtre
77
+ share: Partager
78
+ share_link: Lien de partage
79
+ show:
80
+ comments: Commentaires
81
+ report: Rapport
82
+ models:
83
+ debate:
84
+ fields:
85
+ end_time: Date de fin
86
+ official_debate: Débat officiel
87
+ start_time: Date de début
88
+ title: Titre
89
+ events:
90
+ debates:
91
+ create_debate_event:
92
+ space_followers:
93
+ email_intro: |-
94
+ Bonjour, un nouveau débat a été créé sur l'espace participatif %{space_title}, consultez-le et contribuez :
95
+ email_outro: Vous avez reçu cette notification parce que vous suivez l'espace participatif %{space_title}. Vous pouvez cesser de recevoir des notifications à partir le lien précédent.
96
+ email_subject: Nouveau débat sur %{space_title}
97
+ notification_title: Le débat <a href="%{resource_path}">%{resource_title}</a> a été créé le <a href="%{space_path}">%{space_title}</a>.
98
+ user_followers:
99
+ email_intro: |-
100
+ Bonjour, %{author_name} %{author_nickname}, que vous suivez, a créé un nouveau débat, prenez-en connaissance et contribuez :
101
+ email_outro: Vous avez reçu cette notification, car vous suivez %{author_nickname}. Vous pouvez cesser de recevoir des notifications à partir du lien précédent.
102
+ email_subject: Nouveau débat par %{author_nickname}
103
+ notification_title: Le débat <a href="%{resource_path}">%{resource_title}</a> a été créé par <a href="%{author_path}">%{author_name} %{author_nickname}</a>.
104
+ features:
105
+ debates:
106
+ actions:
107
+ create: Créer
108
+ name: Débats
109
+ settings:
110
+ global:
111
+ comments_enabled: Commentaires activés
112
+ step:
113
+ comments_blocked: Commentaires bloqués
114
+ creation_enabled: Création de débats par les utilisateurs activés