decidim-blogs 0.29.2 → 0.30.0.rc1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/cells/decidim/blogs/content_blocks/highlighted_posts_cell.rb +0 -3
- data/app/commands/decidim/blogs/create_post.rb +35 -0
- data/app/commands/decidim/blogs/update_post.rb +21 -0
- data/app/controllers/decidim/blogs/admin/posts_controller.rb +12 -9
- data/app/controllers/decidim/blogs/posts_controller.rb +61 -1
- data/app/forms/decidim/blogs/post_form.rb +52 -0
- data/app/helpers/decidim/blogs/posts_helper.rb +5 -0
- data/app/helpers/decidim/blogs/posts_select_helper.rb +32 -0
- data/app/models/decidim/blogs/post.rb +2 -1
- data/app/packs/stylesheets/blogs.scss +0 -20
- data/app/permissions/decidim/blog/permissions.rb +85 -2
- data/app/presenters/decidim/blogs/admin_log/post_presenter.rb +1 -1
- data/app/presenters/decidim/blogs/post_presenter.rb +25 -1
- data/app/views/decidim/blogs/admin/posts/_actions.html.erb +21 -0
- data/app/views/decidim/blogs/admin/posts/_post-tr.html.erb +25 -0
- data/app/views/decidim/blogs/admin/posts/_posts-thead.html.erb +9 -0
- data/app/views/decidim/blogs/admin/posts/index.html.erb +16 -55
- data/app/views/decidim/blogs/admin/posts/manage_trash.html.erb +20 -0
- data/app/views/decidim/blogs/posts/_actions.html.erb +7 -14
- data/app/views/decidim/blogs/posts/_form.html.erb +11 -0
- data/app/views/decidim/blogs/posts/_menu_actions.html.erb +21 -0
- data/app/views/decidim/blogs/posts/_schema_org_blog_posting_post.html.erb +3 -0
- data/app/views/decidim/blogs/posts/edit.html.erb +21 -0
- data/app/views/decidim/blogs/posts/index.html.erb +16 -1
- data/app/views/decidim/blogs/posts/new.html.erb +21 -0
- data/app/views/decidim/blogs/posts/show.html.erb +15 -6
- data/config/locales/ar.yml +0 -1
- data/config/locales/bg.yml +0 -3
- data/config/locales/ca.yml +58 -3
- data/config/locales/cs.yml +39 -4
- data/config/locales/de.yml +58 -3
- data/config/locales/el.yml +0 -3
- data/config/locales/en.yml +58 -3
- data/config/locales/es-MX.yml +58 -3
- data/config/locales/es-PY.yml +58 -3
- data/config/locales/es.yml +58 -3
- data/config/locales/eu.yml +58 -3
- data/config/locales/fi-plain.yml +39 -4
- data/config/locales/fi.yml +39 -4
- data/config/locales/fr-CA.yml +32 -2
- data/config/locales/fr.yml +32 -2
- data/config/locales/gl.yml +0 -1
- data/config/locales/hu.yml +0 -3
- data/config/locales/ja.yml +57 -2
- data/config/locales/kaa.yml +0 -1
- data/config/locales/ko.yml +0 -2
- data/config/locales/lt.yml +0 -3
- data/config/locales/nl.yml +0 -1
- data/config/locales/no.yml +0 -1
- data/config/locales/pl.yml +0 -3
- data/config/locales/pt-BR.yml +0 -3
- data/config/locales/ro-RO.yml +20 -1
- data/config/locales/ru.yml +0 -3
- data/config/locales/sq-AL.yml +0 -3
- data/config/locales/sv.yml +58 -3
- data/config/locales/zh-TW.yml +0 -3
- data/db/migrate/20200827153709_add_commentable_counter_cache_to_posts.rb +1 -1
- data/db/migrate/20210310120514_add_followable_counter_cache_to_blogs.rb +1 -1
- data/db/migrate/20240828103324_add_deleted_at_to_decidim_blogs_posts.rb +8 -0
- data/decidim-blogs.gemspec +1 -1
- data/lib/decidim/api/blogs_type.rb +4 -5
- data/lib/decidim/api/post_type.rb +2 -2
- data/lib/decidim/blogs/admin_engine.rb +7 -1
- data/lib/decidim/blogs/component.rb +27 -0
- data/lib/decidim/blogs/engine.rb +1 -1
- data/lib/decidim/blogs/post_serializer.rb +70 -0
- data/lib/decidim/blogs/schema_org_blog_posting_post_serializer.rb +81 -0
- data/lib/decidim/blogs/test/factories.rb +9 -0
- data/lib/decidim/blogs/version.rb +1 -1
- data/lib/decidim/blogs.rb +2 -0
- metadata +34 -18
data/config/locales/fr-CA.yml
CHANGED
@@ -18,11 +18,12 @@ fr-CA:
|
|
18
18
|
blogs:
|
19
19
|
actions:
|
20
20
|
author_id: Créer un article comme
|
21
|
-
|
22
|
-
|
21
|
+
confirm_delete_post: Êtes-vous sûr(e) de vouloir supprimer cet article ?
|
22
|
+
deleted_posts_info: Les articles supprimés peuvent être restaurés depuis la corbeille.
|
23
23
|
edit: Modifier
|
24
24
|
new: Nouvel article
|
25
25
|
title: Actions
|
26
|
+
view_deleted_posts: Voir les articles supprimés
|
26
27
|
admin:
|
27
28
|
posts:
|
28
29
|
create:
|
@@ -36,6 +37,8 @@ fr-CA:
|
|
36
37
|
index:
|
37
38
|
not_published_yet: Pas encore publié.
|
38
39
|
title: Articles
|
40
|
+
manage_trash:
|
41
|
+
title: Articles supprimés
|
39
42
|
new:
|
40
43
|
create: Créer
|
41
44
|
title: Créer un article
|
@@ -63,11 +66,28 @@ fr-CA:
|
|
63
66
|
published_at: Date de publication
|
64
67
|
title: Titre
|
65
68
|
posts:
|
69
|
+
edit:
|
70
|
+
back: Retour à l'article
|
71
|
+
button: Mettre à jour
|
72
|
+
title: Modifier l'article
|
73
|
+
form:
|
74
|
+
author_id: Auteur
|
75
|
+
body: Corps de texte
|
76
|
+
title: Titre
|
66
77
|
index:
|
67
78
|
count:
|
68
79
|
one: "%{count} article"
|
69
80
|
other: "%{count} articles"
|
70
81
|
empty: Il n'y a pas encore d'articles.
|
82
|
+
new_post: Nouvel article
|
83
|
+
menu_actions:
|
84
|
+
button_destroy: Supprimer l'article
|
85
|
+
button_destroy_confirm: Êtes-vous sûr(e) de vouloir supprimer cet article ?
|
86
|
+
button_edit: Modifier l'article
|
87
|
+
new:
|
88
|
+
back: Retour aux articles
|
89
|
+
button: Créer
|
90
|
+
title: Créer un nouvel article
|
71
91
|
components:
|
72
92
|
blogs:
|
73
93
|
actions:
|
@@ -82,6 +102,7 @@ fr-CA:
|
|
82
102
|
announcement: Annonce
|
83
103
|
comments_enabled: Activer le module de commentaire
|
84
104
|
comments_max_length: Longueur max des commentaires (laisser 0 pour la valeur par défaut)
|
105
|
+
creation_enabled_for_participants: Les participants peuvent créer des articles
|
85
106
|
step:
|
86
107
|
announcement: Annonce
|
87
108
|
comments_blocked: Commentaires désactivés
|
@@ -94,5 +115,14 @@ fr-CA:
|
|
94
115
|
email_outro: Vous avez reçu cette notification parce que vous suivez "%{participatory_space_title}". Vous pouvez le retirer du lien précédent.
|
95
116
|
email_subject: Nouvel article publié dans %{participatory_space_title}
|
96
117
|
notification_title: L'article <a href="%{resource_path}">%{resource_title}</a> a été publié dans %{participatory_space_title}
|
118
|
+
open_data:
|
119
|
+
help:
|
120
|
+
post_comments:
|
121
|
+
alignment: Si ce commentaire était pour, contre ou neutre
|
122
|
+
author: Le nom du participant qui a fait ce commentaire
|
123
|
+
body: Le commentaire lui-même
|
124
|
+
commentable_id: L'identifiant unique du commentaire
|
125
|
+
created_at: La date de création de ce commentaire
|
126
|
+
id: L'id de ce commentaire
|
97
127
|
statistics:
|
98
128
|
posts_count: Publications
|
data/config/locales/fr.yml
CHANGED
@@ -18,11 +18,12 @@ fr:
|
|
18
18
|
blogs:
|
19
19
|
actions:
|
20
20
|
author_id: Créer un article en tant que
|
21
|
-
|
22
|
-
|
21
|
+
confirm_delete_post: Êtes-vous sûr(e) de vouloir supprimer cet article ?
|
22
|
+
deleted_posts_info: Les articles supprimés peuvent être restaurés depuis la corbeille.
|
23
23
|
edit: Modifier
|
24
24
|
new: Nouvel article
|
25
25
|
title: Actions
|
26
|
+
view_deleted_posts: Voir les articles supprimés
|
26
27
|
admin:
|
27
28
|
posts:
|
28
29
|
create:
|
@@ -36,6 +37,8 @@ fr:
|
|
36
37
|
index:
|
37
38
|
not_published_yet: Pas encore publié.
|
38
39
|
title: Articles
|
40
|
+
manage_trash:
|
41
|
+
title: Articles supprimés
|
39
42
|
new:
|
40
43
|
create: Créer
|
41
44
|
title: Créer un article
|
@@ -63,11 +66,28 @@ fr:
|
|
63
66
|
published_at: Date de publication
|
64
67
|
title: Titre
|
65
68
|
posts:
|
69
|
+
edit:
|
70
|
+
back: Retour à l'article
|
71
|
+
button: Mettre à jour
|
72
|
+
title: Modifier l'article
|
73
|
+
form:
|
74
|
+
author_id: Auteur
|
75
|
+
body: Corps de texte
|
76
|
+
title: Titre
|
66
77
|
index:
|
67
78
|
count:
|
68
79
|
one: "%{count} article"
|
69
80
|
other: "%{count} articles"
|
70
81
|
empty: Il n'y a pas encore d'articles.
|
82
|
+
new_post: Nouvel article
|
83
|
+
menu_actions:
|
84
|
+
button_destroy: Supprimer l'article
|
85
|
+
button_destroy_confirm: Êtes-vous sûr(e) de vouloir supprimer cet article ?
|
86
|
+
button_edit: Modifier l'article
|
87
|
+
new:
|
88
|
+
back: Retour aux articles
|
89
|
+
button: Créer
|
90
|
+
title: Créer un nouvel article
|
71
91
|
components:
|
72
92
|
blogs:
|
73
93
|
actions:
|
@@ -82,6 +102,7 @@ fr:
|
|
82
102
|
announcement: Annonce
|
83
103
|
comments_enabled: Activer le module de commentaire
|
84
104
|
comments_max_length: Longueur max des commentaires (laisser 0 pour la valeur par défaut)
|
105
|
+
creation_enabled_for_participants: Les participants peuvent créer des articles
|
85
106
|
step:
|
86
107
|
announcement: Annonce
|
87
108
|
comments_blocked: Commentaires désactivés
|
@@ -94,5 +115,14 @@ fr:
|
|
94
115
|
email_outro: Vous avez reçu cette notification parce que vous suivez "%{participatory_space_title}". Si vous souhaitez vous désabonner des notifications, connectez-vous à la plateforme, puis rendez-vous dans l'onglet “Mon compte” > “Paramètres des notifications”.
|
95
116
|
email_subject: Nouvel article publié dans %{participatory_space_title}
|
96
117
|
notification_title: L'article <a href="%{resource_path}">%{resource_title}</a> a été publié dans %{participatory_space_title}
|
118
|
+
open_data:
|
119
|
+
help:
|
120
|
+
post_comments:
|
121
|
+
alignment: Si ce commentaire était pour, contre ou neutre
|
122
|
+
author: Le nom du participant qui a fait ce commentaire
|
123
|
+
body: Le commentaire lui-même
|
124
|
+
commentable_id: L'identifiant unique du commentaire
|
125
|
+
created_at: La date de création de ce commentaire
|
126
|
+
id: L'id de ce commentaire
|
97
127
|
statistics:
|
98
128
|
posts_count: Articles
|
data/config/locales/gl.yml
CHANGED
data/config/locales/hu.yml
CHANGED
@@ -18,7 +18,6 @@ hu:
|
|
18
18
|
blogs:
|
19
19
|
actions:
|
20
20
|
author_id: Bejegyzés létrehozása
|
21
|
-
destroy: Törlés
|
22
21
|
edit: Szerkesztés
|
23
22
|
new: Új bejegyzés
|
24
23
|
title: Műveletek
|
@@ -27,8 +26,6 @@ hu:
|
|
27
26
|
create:
|
28
27
|
invalid: Probléma történt a bejegyzés létrehozásakor.
|
29
28
|
success: Bejegyzés sikeresen létrehozva.
|
30
|
-
destroy:
|
31
|
-
success: Bejegyzés sikeresen törölve.
|
32
29
|
edit:
|
33
30
|
save: Frissítés
|
34
31
|
title: Bejegyzés szerkesztése
|
data/config/locales/ja.yml
CHANGED
@@ -14,14 +14,19 @@ ja:
|
|
14
14
|
decidim/blogs/post:
|
15
15
|
other: 投稿
|
16
16
|
decidim:
|
17
|
+
admin:
|
18
|
+
admin_log:
|
19
|
+
changeset:
|
20
|
+
posts: 投稿
|
17
21
|
blogs:
|
18
22
|
actions:
|
19
23
|
author_id: 次のように投稿を作成
|
20
|
-
|
21
|
-
|
24
|
+
confirm_delete_post: この投稿を削除してもよろしいですか?
|
25
|
+
deleted_posts_info: 削除された投稿はゴミ箱から復元できます。
|
22
26
|
edit: 編集
|
23
27
|
new: 新規投稿
|
24
28
|
title: アクション
|
29
|
+
view_deleted_posts: 削除された投稿を表示
|
25
30
|
admin:
|
26
31
|
posts:
|
27
32
|
create:
|
@@ -35,6 +40,8 @@ ja:
|
|
35
40
|
index:
|
36
41
|
not_published_yet: まだ公開されていません。
|
37
42
|
title: 投稿
|
43
|
+
manage_trash:
|
44
|
+
title: 削除された投稿
|
38
45
|
new:
|
39
46
|
create: 作成
|
40
47
|
title: 投稿を作成
|
@@ -45,6 +52,8 @@ ja:
|
|
45
52
|
post:
|
46
53
|
create: "%{user_name} が %{space_name} でブログ投稿 %{resource_name} を作成しました"
|
47
54
|
delete: "%{user_name} がブログ投稿 %{resource_name} を %{space_name} から削除しました"
|
55
|
+
restore: "%{user_name} が %{space_name} のブログ投稿 %{resource_name} を復元しました"
|
56
|
+
soft_delete: "%{user_name} は %{space_name} のブログ投稿 %{resource_name} をゴミ箱に移動しました"
|
48
57
|
update: "%{user_name} が %{space_name} のブログ投稿 %{resource_name} を更新しました"
|
49
58
|
content_blocks:
|
50
59
|
highlighted_posts:
|
@@ -62,10 +71,27 @@ ja:
|
|
62
71
|
published_at: 公開時刻
|
63
72
|
title: タイトル
|
64
73
|
posts:
|
74
|
+
edit:
|
75
|
+
back: 投稿に戻る
|
76
|
+
button: 更新
|
77
|
+
title: 投稿を編集
|
78
|
+
form:
|
79
|
+
author_id: 作成者
|
80
|
+
body: 本文
|
81
|
+
title: タイトル
|
65
82
|
index:
|
66
83
|
count:
|
67
84
|
other: "%{count} 件の投稿"
|
68
85
|
empty: 投稿はまだありません。
|
86
|
+
new_post: 新規投稿
|
87
|
+
menu_actions:
|
88
|
+
button_destroy: 投稿の削除
|
89
|
+
button_destroy_confirm: この投稿を削除してもよろしいですか?
|
90
|
+
button_edit: 投稿を編集
|
91
|
+
new:
|
92
|
+
back: 投稿に戻る
|
93
|
+
button: 作成
|
94
|
+
title: 新しい投稿を作成
|
69
95
|
components:
|
70
96
|
blogs:
|
71
97
|
actions:
|
@@ -80,6 +106,7 @@ ja:
|
|
80
106
|
announcement: お知らせ
|
81
107
|
comments_enabled: コメントを有効にする
|
82
108
|
comments_max_length: コメント最大長 (デフォルト値は 0 のまま)
|
109
|
+
creation_enabled_for_participants: 参加者は投稿を作成できます
|
83
110
|
step:
|
84
111
|
announcement: お知らせ
|
85
112
|
comments_blocked: コメントをブロック
|
@@ -92,5 +119,33 @@ ja:
|
|
92
119
|
email_outro: '「%{participatory_space_title}」をフォローしているため、この通知を受け取りました。前のリンクからこの通知をアンフォローすることができます。'
|
93
120
|
email_subject: '%{participatory_space_title} に新しい投稿が公開されました'
|
94
121
|
notification_title: '%{participatory_space_title} で投稿 <a href="%{resource_path}">%{resource_title}</a> が公開されました'
|
122
|
+
open_data:
|
123
|
+
help:
|
124
|
+
post_comments:
|
125
|
+
alignment: このコメントが好意的、敵対的、中立的であった場合
|
126
|
+
author: このコメントを作成した参加者の名前
|
127
|
+
body: コメントそのもの
|
128
|
+
commentable_id: コメント対象の固有ID
|
129
|
+
commentable_type: コメント対象の種別 (結果、提案など)
|
130
|
+
created_at: コメントの作成日時
|
131
|
+
depth: コメントがコメントツリーのどこに位置しているか(回答、または回答の回答である場合)
|
132
|
+
id: コメントのID
|
133
|
+
locale: コメントを残した参加者の使っていたロケール(言語)
|
134
|
+
root_commentable_url: コメントに関連するリソースの URL
|
135
|
+
user_group: コメントを作成したユーザーグループの名前 (もしあれば)
|
136
|
+
posts:
|
137
|
+
author: 作者の情報
|
138
|
+
body: 投稿の本文
|
139
|
+
comments_count: 投稿のコメント数
|
140
|
+
component: ポストが属するコンポーネント
|
141
|
+
created_at: この投稿の作成日時
|
142
|
+
endorsements_count: 投稿のオススメ数
|
143
|
+
follows_count: 投稿のフォロー数
|
144
|
+
id: 投稿の固有ID
|
145
|
+
participatory_space: この投稿が所属するスペース(参加型プロセス、参加スペースなど)
|
146
|
+
published_at: この投稿の公開日時
|
147
|
+
title: 投稿のタイトル
|
148
|
+
updated_at: この投稿が更新された日時
|
149
|
+
url: この投稿の URL
|
95
150
|
statistics:
|
96
151
|
posts_count: 投稿
|
data/config/locales/kaa.yml
CHANGED
data/config/locales/ko.yml
CHANGED
data/config/locales/lt.yml
CHANGED
@@ -20,7 +20,6 @@ lt:
|
|
20
20
|
blogs:
|
21
21
|
actions:
|
22
22
|
author_id: Sukurti įrašą kaip
|
23
|
-
destroy: Ištrinti
|
24
23
|
edit: Redaguoti
|
25
24
|
new: Naujas įrašas
|
26
25
|
title: Veiksmai
|
@@ -29,8 +28,6 @@ lt:
|
|
29
28
|
create:
|
30
29
|
invalid: Kuriant šį įrašą iškilo problema.
|
31
30
|
success: Įrašas sukurtas sėkmingai.
|
32
|
-
destroy:
|
33
|
-
success: Įrašas pašalintas.
|
34
31
|
edit:
|
35
32
|
save: Atnaujinimas
|
36
33
|
title: Redaguoti publikaciją
|
data/config/locales/nl.yml
CHANGED
data/config/locales/no.yml
CHANGED
data/config/locales/pl.yml
CHANGED
@@ -20,7 +20,6 @@ pl:
|
|
20
20
|
blogs:
|
21
21
|
actions:
|
22
22
|
author_id: Utwórz wpis jako
|
23
|
-
destroy: Usuń
|
24
23
|
edit: Edytuj
|
25
24
|
new: Nowy wpis
|
26
25
|
title: Działania
|
@@ -29,8 +28,6 @@ pl:
|
|
29
28
|
create:
|
30
29
|
invalid: Podczas tworzenia tego posta wystąpił błąd.
|
31
30
|
success: Post został utworzony.
|
32
|
-
destroy:
|
33
|
-
success: Post został usunięty.
|
34
31
|
edit:
|
35
32
|
save: Aktualizuj
|
36
33
|
title: Edytuj wpis
|
data/config/locales/pt-BR.yml
CHANGED
@@ -18,7 +18,6 @@ pt-BR:
|
|
18
18
|
blogs:
|
19
19
|
actions:
|
20
20
|
author_id: Criar publicação como
|
21
|
-
destroy: Excluir
|
22
21
|
edit: Editar
|
23
22
|
new: Nova postagem
|
24
23
|
title: Ações
|
@@ -27,8 +26,6 @@ pt-BR:
|
|
27
26
|
create:
|
28
27
|
invalid: Houve um problema ao criar esta postagem.
|
29
28
|
success: Post criado com sucesso.
|
30
|
-
destroy:
|
31
|
-
success: Postagem excluída com sucesso.
|
32
29
|
edit:
|
33
30
|
save: Atualizar
|
34
31
|
title: Editar publicação
|
data/config/locales/ro-RO.yml
CHANGED
@@ -19,7 +19,6 @@ ro:
|
|
19
19
|
blogs:
|
20
20
|
actions:
|
21
21
|
author_id: Creează postare ca
|
22
|
-
destroy: Șterge
|
23
22
|
edit: Editează
|
24
23
|
new: Postare nouă
|
25
24
|
title: Acțiuni
|
@@ -57,6 +56,25 @@ ro:
|
|
57
56
|
official_blog_post: Postare oficială
|
58
57
|
published_at: Publicat la
|
59
58
|
title: Titlu
|
59
|
+
posts:
|
60
|
+
edit:
|
61
|
+
back: Înapoi la postare
|
62
|
+
button: Actualizați
|
63
|
+
title: Modificați postarea
|
64
|
+
form:
|
65
|
+
author_id: Autor
|
66
|
+
body: Conținut
|
67
|
+
title: Titlu
|
68
|
+
index:
|
69
|
+
new_post: Postare nouă
|
70
|
+
menu_actions:
|
71
|
+
button_destroy: Ștergeți postarea
|
72
|
+
button_destroy_confirm: Sunteți sigur că doriți să ștergeți această postare?
|
73
|
+
button_edit: Modificați postarea
|
74
|
+
new:
|
75
|
+
back: Înapoi la postări
|
76
|
+
button: Creați
|
77
|
+
title: Creați o postare nouă
|
60
78
|
components:
|
61
79
|
blogs:
|
62
80
|
actions:
|
@@ -71,6 +89,7 @@ ro:
|
|
71
89
|
announcement: Anunţ
|
72
90
|
comments_enabled: Comentarii activate
|
73
91
|
comments_max_length: Lungimea maximă a comentariilor (lăsați 0 pentru valoarea implicită)
|
92
|
+
creation_enabled_for_participants: Participanții pot crea postări
|
74
93
|
step:
|
75
94
|
announcement: Anunţ
|
76
95
|
comments_blocked: Comentarii blocate
|
data/config/locales/ru.yml
CHANGED
@@ -20,7 +20,6 @@ ru:
|
|
20
20
|
blogs:
|
21
21
|
actions:
|
22
22
|
author_id: Создать пост как
|
23
|
-
destroy: Удалить
|
24
23
|
edit: Редактировать
|
25
24
|
new: Создать новый пост
|
26
25
|
title: Действия
|
@@ -29,8 +28,6 @@ ru:
|
|
29
28
|
create:
|
30
29
|
invalid: При попытке добавить этот пост произошла ошибка.
|
31
30
|
success: Пост успешно создан.
|
32
|
-
destroy:
|
33
|
-
success: Пост успешно удален.
|
34
31
|
edit:
|
35
32
|
save: Обновить
|
36
33
|
title: Изменить пост
|
data/config/locales/sq-AL.yml
CHANGED
@@ -18,7 +18,6 @@ sq:
|
|
18
18
|
blogs:
|
19
19
|
actions:
|
20
20
|
author_id: Krijo postimin si
|
21
|
-
destroy: Fshij
|
22
21
|
edit: Përpuno
|
23
22
|
new: Postim i ri
|
24
23
|
title: Veprime
|
@@ -27,8 +26,6 @@ sq:
|
|
27
26
|
create:
|
28
27
|
invalid: Ndodhi një gabim gjatë krijimit të këtij postimi.
|
29
28
|
success: Postimi u krijua me sukses.
|
30
|
-
destroy:
|
31
|
-
success: Postimi u fshi me sukses.
|
32
29
|
edit:
|
33
30
|
save: Përditëso
|
34
31
|
title: Përpuno postimin
|
data/config/locales/sv.yml
CHANGED
@@ -15,27 +15,34 @@ sv:
|
|
15
15
|
one: Inlägg
|
16
16
|
other: Inlägg
|
17
17
|
decidim:
|
18
|
+
admin:
|
19
|
+
admin_log:
|
20
|
+
changeset:
|
21
|
+
posts: Inlägg
|
18
22
|
blogs:
|
19
23
|
actions:
|
20
24
|
author_id: Skapa inlägg som
|
21
|
-
|
22
|
-
|
25
|
+
confirm_delete_post: Är du säker på att du vill radera inlägget?
|
26
|
+
deleted_posts_info: Raderade inlägg kan återställas från papperskorgen.
|
23
27
|
edit: Redigera
|
24
28
|
new: Nytt inlägg
|
25
29
|
title: Åtgärder
|
30
|
+
view_deleted_posts: Visa raderade inlägg
|
26
31
|
admin:
|
27
32
|
posts:
|
28
33
|
create:
|
29
34
|
invalid: Det gick inte att skapa inlägget.
|
30
35
|
success: Inlägget har skapats.
|
31
36
|
destroy:
|
32
|
-
success: Inlägget
|
37
|
+
success: Inlägget raderades.
|
33
38
|
edit:
|
34
39
|
save: Uppdatera
|
35
40
|
title: Redigera inlägg
|
36
41
|
index:
|
37
42
|
not_published_yet: Ej publicerat.
|
38
43
|
title: Inlägg
|
44
|
+
manage_trash:
|
45
|
+
title: Raderade inlägg
|
39
46
|
new:
|
40
47
|
create: Skapa
|
41
48
|
title: Skapa inlägg
|
@@ -46,6 +53,8 @@ sv:
|
|
46
53
|
post:
|
47
54
|
create: "%{user_name} skapade blogginlägget %{resource_name} i %{space_name}"
|
48
55
|
delete: "%{user_name} raderade blogginlägget %{resource_name} från %{space_name}"
|
56
|
+
restore: "%{user_name} återställde %{resource_name} blogginlägg i %{space_name}"
|
57
|
+
soft_delete: "%{user_name} flyttade blogginlägget %{resource_name} i %{space_name} till papperskorgen"
|
49
58
|
update: "%{user_name} uppdaterade blogginlägget %{resource_name} i %{space_name}"
|
50
59
|
content_blocks:
|
51
60
|
highlighted_posts:
|
@@ -63,11 +72,28 @@ sv:
|
|
63
72
|
published_at: Publicerad
|
64
73
|
title: Titel
|
65
74
|
posts:
|
75
|
+
edit:
|
76
|
+
back: Tillbaka till inlägget
|
77
|
+
button: Uppdatera
|
78
|
+
title: Redigera inlägg
|
79
|
+
form:
|
80
|
+
author_id: Författare
|
81
|
+
body: Text
|
82
|
+
title: Titel
|
66
83
|
index:
|
67
84
|
count:
|
68
85
|
one: "%{count} inlägg"
|
69
86
|
other: "%{count} inlägg"
|
70
87
|
empty: Det finns inga inlägg ännu.
|
88
|
+
new_post: Nytt inlägg
|
89
|
+
menu_actions:
|
90
|
+
button_destroy: Ta bort inlägg
|
91
|
+
button_destroy_confirm: Är du säker på att du vill radera inlägget?
|
92
|
+
button_edit: Redigera inlägg
|
93
|
+
new:
|
94
|
+
back: Tillbaka till inlägg
|
95
|
+
button: Skapa
|
96
|
+
title: Skapa nytt inlägg
|
71
97
|
components:
|
72
98
|
blogs:
|
73
99
|
actions:
|
@@ -82,6 +108,7 @@ sv:
|
|
82
108
|
announcement: Meddelande
|
83
109
|
comments_enabled: Aktivera kommentarer
|
84
110
|
comments_max_length: Maximal kommentarslängd (ange 0 för att använda standardvärdet)
|
111
|
+
creation_enabled_for_participants: Deltagarna kan skapa inlägg
|
85
112
|
step:
|
86
113
|
announcement: Meddelande
|
87
114
|
comments_blocked: Stäng av kommentarer
|
@@ -94,5 +121,33 @@ sv:
|
|
94
121
|
email_outro: Du har fått det här meddelandet eftersom du följer "%{participatory_space_title}". Du kan sluta att följa det från den föregående länken.
|
95
122
|
email_subject: Ett nytt inlägg har publicerats i %{participatory_space_title}
|
96
123
|
notification_title: Inlägget <a href="%{resource_path}">%{resource_title}</a> har publicerats i %{participatory_space_title}
|
124
|
+
open_data:
|
125
|
+
help:
|
126
|
+
post_comments:
|
127
|
+
alignment: Positiva, negativa eller neutrala kommentarer
|
128
|
+
author: Namn på den som kommenterat
|
129
|
+
body: Kommentaren
|
130
|
+
commentable_id: Kommentarens unika id
|
131
|
+
commentable_type: Vad som kommenterades (resultat, förslag etc)
|
132
|
+
created_at: Datum för kommentaren
|
133
|
+
depth: Kommentarens plats i en hierarki av kommentarer (om den är ett svar på en annan kommentar)
|
134
|
+
id: Id för kommentaren
|
135
|
+
locale: Kommentarförfattarens språk
|
136
|
+
root_commentable_url: URL till innehållet som är relaterat till kommentaren
|
137
|
+
user_group: Namn på gruppen som kommenterat (om det var en grupp)
|
138
|
+
posts:
|
139
|
+
author: Uppgifter om författaren
|
140
|
+
body: Inläggets text
|
141
|
+
comments_count: Antalet kommentarer till inlägget
|
142
|
+
component: Komponenten som inlägget tillhör
|
143
|
+
created_at: Datum för inlägget
|
144
|
+
endorsements_count: Antal gilla-markeringar för inlägget
|
145
|
+
follows_count: Antal följare för inlägget
|
146
|
+
id: Unikt id för inlägget
|
147
|
+
participatory_space: Vilket utrymme (deltagandeprocess eller samråd) inlägget tillhör
|
148
|
+
published_at: Publiceringsdatum för inlägget
|
149
|
+
title: Titeln på inlägget
|
150
|
+
updated_at: Senaste datum när inlägget uppdaterades
|
151
|
+
url: URL för inlägget
|
97
152
|
statistics:
|
98
153
|
posts_count: Inlägg
|
data/config/locales/zh-TW.yml
CHANGED
@@ -17,7 +17,6 @@ zh-TW:
|
|
17
17
|
blogs:
|
18
18
|
actions:
|
19
19
|
author_id: 發佈文章
|
20
|
-
destroy: 刪除
|
21
20
|
edit: 編輯
|
22
21
|
new: 新貼文
|
23
22
|
title: 操作
|
@@ -26,8 +25,6 @@ zh-TW:
|
|
26
25
|
create:
|
27
26
|
invalid: 建立此文章時出現問題
|
28
27
|
success: 文章已成功建立
|
29
|
-
destroy:
|
30
|
-
success: 文章已成功刪除
|
31
28
|
edit:
|
32
29
|
save: 更新
|
33
30
|
title: 编辑文章
|
@@ -4,6 +4,6 @@ class AddCommentableCounterCacheToPosts < ActiveRecord::Migration[5.2]
|
|
4
4
|
def change
|
5
5
|
add_column :decidim_blogs_posts, :comments_count, :integer, null: false, default: 0, index: true
|
6
6
|
Decidim::Blogs::Post.reset_column_information
|
7
|
-
Decidim::Blogs::Post.find_each(&:update_comments_count)
|
7
|
+
Decidim::Blogs::Post.unscoped.find_each(&:update_comments_count)
|
8
8
|
end
|
9
9
|
end
|
@@ -7,7 +7,7 @@ class AddFollowableCounterCacheToBlogs < ActiveRecord::Migration[5.2]
|
|
7
7
|
reversible do |dir|
|
8
8
|
dir.up do
|
9
9
|
Decidim::Blogs::Post.reset_column_information
|
10
|
-
Decidim::Blogs::Post.find_each do |record|
|
10
|
+
Decidim::Blogs::Post.unscoped.find_each do |record|
|
11
11
|
record.class.reset_counters(record.id, :follows)
|
12
12
|
end
|
13
13
|
end
|
data/decidim-blogs.gemspec
CHANGED
@@ -19,7 +19,7 @@ Gem::Specification.new do |s|
|
|
19
19
|
"homepage_uri" => "https://decidim.org",
|
20
20
|
"source_code_uri" => "https://github.com/decidim/decidim"
|
21
21
|
}
|
22
|
-
s.required_ruby_version = "~> 3.
|
22
|
+
s.required_ruby_version = "~> 3.3.0"
|
23
23
|
|
24
24
|
s.name = "decidim-blogs"
|
25
25
|
s.summary = "Decidim blogs module"
|
@@ -6,14 +6,13 @@ module Decidim
|
|
6
6
|
graphql_name "Blogs"
|
7
7
|
description "A blogs component of a participatory space."
|
8
8
|
|
9
|
-
field :posts, type: Decidim::Blogs::PostType.connection_type, description: "List all posts", connection: true, null: false do
|
10
|
-
argument :order, Decidim::Blogs::PostInputSort, "Provides several methods to order the results", required: false
|
11
|
-
argument :filter, Decidim::Blogs::PostInputFilter, "Provides several methods to filter the results", required: false
|
12
|
-
end
|
13
|
-
|
14
9
|
field :post, type: Decidim::Blogs::PostType, description: "Finds one post", null: true do
|
15
10
|
argument :id, GraphQL::Types::ID, "The ID of the post", required: true
|
16
11
|
end
|
12
|
+
field :posts, type: Decidim::Blogs::PostType.connection_type, description: "List all posts", connection: true, null: false do
|
13
|
+
argument :filter, Decidim::Blogs::PostInputFilter, "Provides several methods to filter the results", required: false
|
14
|
+
argument :order, Decidim::Blogs::PostInputSort, "Provides several methods to order the results", required: false
|
15
|
+
end
|
17
16
|
|
18
17
|
def posts(filter: {}, order: {})
|
19
18
|
base_query = Decidim::Core::ComponentListBase.new(model_class: Post).call(object, { filter:, order: }, context)
|
@@ -13,10 +13,10 @@ module Decidim
|
|
13
13
|
|
14
14
|
description "A post"
|
15
15
|
|
16
|
-
field :id, GraphQL::Types::ID, "The internal ID of this post", null: false
|
17
|
-
field :title, Decidim::Core::TranslatedFieldType, "The title for this post", null: true
|
18
16
|
field :body, Decidim::Core::TranslatedFieldType, "The body of this post", null: true
|
17
|
+
field :id, GraphQL::Types::ID, "The internal ID of this post", null: false
|
19
18
|
field :published_at, Decidim::Core::DateTimeType, "The time this page was published", null: false
|
19
|
+
field :title, Decidim::Core::TranslatedFieldType, "The title for this post", null: true
|
20
20
|
|
21
21
|
def self.authorized?(object, context)
|
22
22
|
context[:post] = object
|