decidim-initiatives 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/initiatives/content_blocks/highlighted_initiatives_settings_form/show.erb +1 -1
- data/app/commands/decidim/initiatives/create_initiative.rb +16 -4
- data/app/commands/decidim/initiatives/update_initiative.rb +23 -9
- data/app/controllers/concerns/decidim/initiatives/needs_initiative.rb +1 -1
- data/app/controllers/decidim/initiatives/admin/application_controller.rb +2 -0
- data/app/controllers/decidim/initiatives/admin/component_share_tokens_controller.rb +18 -0
- data/app/controllers/decidim/initiatives/admin/initiative_share_tokens_controller.rb +18 -0
- data/app/controllers/decidim/initiatives/admin/initiatives_controller.rb +8 -8
- data/app/controllers/decidim/initiatives/create_initiative_controller.rb +3 -2
- data/app/controllers/decidim/initiatives/initiative_types_controller.rb +1 -1
- data/app/controllers/decidim/initiatives/initiatives_controller.rb +3 -0
- data/app/forms/decidim/initiatives/admin/initiative_answer_form.rb +1 -1
- data/app/forms/decidim/initiatives/vote_form.rb +1 -1
- data/app/helpers/decidim/initiatives/initiative_helper.rb +1 -39
- data/app/helpers/decidim/initiatives/initiatives_helper.rb +8 -5
- data/app/helpers/decidim/initiatives/scopes_helper.rb +43 -0
- data/app/jobs/decidim/initiatives/export_initiatives_job.rb +5 -1
- data/app/models/decidim/initiative.rb +40 -27
- data/app/models/decidim/initiatives_type_scope.rb +9 -0
- data/app/permissions/decidim/initiatives/admin/permissions.rb +7 -0
- data/app/permissions/decidim/initiatives/permissions.rb +10 -3
- data/app/queries/decidim/initiatives/outdated_validating_initiatives.rb +1 -1
- data/app/queries/decidim/initiatives/support_period_finished_initiatives.rb +2 -2
- data/app/serializers/decidim/initiatives/download_your_data_initiative_serializer.rb +15 -0
- data/app/serializers/decidim/initiatives/initiative_serializer.rb +5 -24
- data/app/serializers/decidim/initiatives/open_data_initiative_serializer.rb +54 -0
- data/app/services/decidim/initiatives/data_encryptor.rb +1 -1
- data/app/services/decidim/initiatives/pdf_signature_example.rb +0 -2
- data/app/views/decidim/initiatives/admin/initiatives/edit.html.erb +1 -2
- data/app/views/decidim/initiatives/admin/initiatives/index.html.erb +7 -0
- data/app/views/decidim/initiatives/committee_requests/new.html.erb +1 -2
- data/app/views/decidim/initiatives/create_initiative/fill_data.html.erb +3 -3
- data/app/views/decidim/initiatives/create_initiative/select_initiative_type.html.erb +10 -2
- data/app/views/decidim/initiatives/initiatives/_form.html.erb +3 -3
- data/app/views/decidim/initiatives/initiatives/_new_initiative_button.html.erb +16 -13
- data/app/views/decidim/initiatives/initiatives/_vote_button.html.erb +9 -3
- data/app/views/decidim/initiatives/initiatives/_vote_cabin.html.erb +0 -1
- data/app/views/decidim/initiatives/initiatives/show.html.erb +7 -8
- data/app/views/layouts/decidim/admin/_manage_initiatives.html.erb +11 -0
- data/app/views/layouts/decidim/admin/initiatives.html.erb +1 -9
- data/config/assets.rb +1 -3
- data/config/locales/ar.yml +7 -8
- data/config/locales/bg.yml +2 -22
- data/config/locales/ca.yml +55 -21
- data/config/locales/cs.yml +55 -21
- data/config/locales/de.yml +55 -21
- data/config/locales/el.yml +2 -9
- data/config/locales/en.yml +53 -19
- data/config/locales/es-MX.yml +55 -21
- data/config/locales/es-PY.yml +55 -21
- data/config/locales/es.yml +55 -21
- data/config/locales/eu.yml +55 -21
- data/config/locales/fi-plain.yml +55 -21
- data/config/locales/fi.yml +55 -21
- data/config/locales/fr-CA.yml +9 -22
- data/config/locales/fr.yml +9 -22
- data/config/locales/ga-IE.yml +0 -3
- data/config/locales/gl.yml +2 -10
- data/config/locales/hu.yml +2 -20
- data/config/locales/id-ID.yml +2 -8
- data/config/locales/is-IS.yml +0 -9
- data/config/locales/it.yml +2 -11
- data/config/locales/ja.yml +55 -21
- data/config/locales/lb.yml +2 -7
- data/config/locales/lt.yml +2 -22
- data/config/locales/lv.yml +2 -9
- data/config/locales/nl.yml +2 -11
- data/config/locales/no.yml +2 -13
- data/config/locales/pl.yml +2 -21
- data/config/locales/pt-BR.yml +2 -27
- data/config/locales/pt.yml +2 -11
- data/config/locales/ro-RO.yml +2 -19
- data/config/locales/ru.yml +0 -9
- data/config/locales/sk.yml +2 -8
- data/config/locales/sl.yml +0 -1
- data/config/locales/sv.yml +12 -21
- data/config/locales/tr-TR.yml +2 -11
- data/config/locales/uk.yml +0 -9
- data/config/locales/zh-CN.yml +2 -10
- data/config/locales/zh-TW.yml +2 -21
- data/db/migrate/20241127104718_add_taxonomy_to_initiatives_type_scope.rb +7 -0
- data/decidim-initiatives.gemspec +1 -3
- data/lib/decidim/api/initiative_api_type.rb +9 -10
- data/lib/decidim/api/initiative_committee_member_type.rb +3 -4
- data/lib/decidim/api/initiative_type.rb +15 -21
- data/lib/decidim/api/initiative_type_interface.rb +1 -5
- data/lib/decidim/exporters/initiative_votes_pdf.rb +163 -0
- data/lib/decidim/initiatives/admin_engine.rb +68 -49
- data/lib/decidim/initiatives/application_form_pdf.rb +181 -0
- data/lib/decidim/initiatives/engine.rb +6 -0
- data/lib/decidim/initiatives/menu.rb +8 -0
- data/lib/decidim/initiatives/participatory_space.rb +8 -1
- data/lib/decidim/initiatives/test/factories.rb +5 -8
- data/lib/decidim/initiatives/version.rb +1 -1
- data/lib/decidim/initiatives.rb +7 -1
- metadata +25 -59
- data/app/cells/decidim/initiatives_votes/vote/show.erb +0 -39
- data/app/cells/decidim/initiatives_votes/vote_cell.rb +0 -58
- data/app/packs/entrypoints/decidim_initiatives_initiatives_votes.js +0 -1
- data/app/packs/entrypoints/decidim_initiatives_initiatives_votes.scss +0 -1
- data/app/packs/entrypoints/decidim_initiatives_print.js +0 -1
- data/app/packs/entrypoints/decidim_initiatives_print.scss +0 -1
- data/app/packs/stylesheets/decidim/initiatives/initiatives-votes.scss +0 -96
- data/app/packs/stylesheets/decidim/initiatives/print-initiative.scss +0 -172
- data/app/views/decidim/initiatives/admin/initiatives/_signatures.html.erb +0 -87
- data/app/views/decidim/initiatives/admin/initiatives/export_pdf_signatures.html.erb +0 -8
- data/app/views/decidim/initiatives/admin/initiatives/export_pdf_signatures.pdf.erb +0 -5
- data/app/views/decidim/initiatives/initiatives/_linked_initiatives.html.erb +0 -0
- data/app/views/decidim/initiatives/initiatives/print.html.erb +0 -161
- data/app/views/layouts/decidim/admin/initiatives_votes.pdf.erb +0 -11
- data/config/initializers/wicked_pdf.rb +0 -22
@@ -0,0 +1,15 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Decidim
|
4
|
+
module Initiatives
|
5
|
+
class DownloadYourDataInitiativeSerializer < OpenDataInitiativeSerializer
|
6
|
+
# Serializes a Debate for download your data feature
|
7
|
+
#
|
8
|
+
# Remove the author information as it is the same of the user that
|
9
|
+
# requested the data
|
10
|
+
def serialize
|
11
|
+
super.except!(:authors)
|
12
|
+
end
|
13
|
+
end
|
14
|
+
end
|
15
|
+
end
|
@@ -2,33 +2,14 @@
|
|
2
2
|
|
3
3
|
module Decidim
|
4
4
|
module Initiatives
|
5
|
-
class InitiativeSerializer < Decidim::
|
5
|
+
class InitiativeSerializer < Decidim::Initiatives::OpenDataInitiativeSerializer
|
6
6
|
# Serializes an initiative
|
7
7
|
def serialize
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
description: resource.description,
|
12
|
-
state: resource.state,
|
13
|
-
created_at: resource.created_at,
|
14
|
-
published_at: resource.published_at,
|
15
|
-
signature_end_date: resource.signature_end_date,
|
16
|
-
signature_type: resource.signature_type,
|
17
|
-
signatures: resource.supports_count,
|
18
|
-
scope: {
|
19
|
-
name: resource.scope&.name
|
20
|
-
},
|
21
|
-
type: {
|
22
|
-
title: resource.type&.title
|
23
|
-
},
|
24
|
-
authors: {
|
25
|
-
id: resource.author_users.map(&:id),
|
26
|
-
name: resource.author_users.map(&:name)
|
27
|
-
},
|
28
|
-
area: {
|
29
|
-
name: resource.area&.name
|
8
|
+
super.merge(
|
9
|
+
{
|
10
|
+
components: serialize_components
|
30
11
|
}
|
31
|
-
|
12
|
+
)
|
32
13
|
end
|
33
14
|
end
|
34
15
|
end
|
@@ -0,0 +1,54 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Decidim
|
4
|
+
module Initiatives
|
5
|
+
class OpenDataInitiativeSerializer < Decidim::Exporters::ParticipatorySpaceSerializer
|
6
|
+
# Public: Exports a hash with the serialized data for this initiative.
|
7
|
+
#
|
8
|
+
# Note that we do not merge the original serialize method here, as the Initiative
|
9
|
+
# model does not have the same attributes as the other Spaces models.
|
10
|
+
def serialize
|
11
|
+
{
|
12
|
+
reference: resource.reference,
|
13
|
+
title: resource.title,
|
14
|
+
url: EngineRouter.main_proxy(resource).initiative_url(resource),
|
15
|
+
description: resource.description,
|
16
|
+
state: resource.state,
|
17
|
+
created_at: resource.created_at,
|
18
|
+
updated_at: resource.updated_at,
|
19
|
+
published_at: resource.published_at,
|
20
|
+
signature_start_date: resource.signature_start_date,
|
21
|
+
signature_end_date: resource.signature_end_date,
|
22
|
+
signature_type: resource.signature_type,
|
23
|
+
signatures: resource.supports_count,
|
24
|
+
answer: resource.answer,
|
25
|
+
answered_at: resource.answered_at,
|
26
|
+
answer_url: resource.answer_url,
|
27
|
+
hashtag: resource.hashtag,
|
28
|
+
first_progress_notification_at: resource.first_progress_notification_at,
|
29
|
+
second_progress_notification_at: resource.second_progress_notification_at,
|
30
|
+
online_votes: resource.online_votes,
|
31
|
+
offline_votes: resource.offline_votes,
|
32
|
+
comments_count: resource.comments_count,
|
33
|
+
follows_count: resource.follows_count,
|
34
|
+
scope: {
|
35
|
+
id: resource.scope.try(:id),
|
36
|
+
name: resource.scope.try(:name) || empty_translatable
|
37
|
+
},
|
38
|
+
type: {
|
39
|
+
id: resource.type&.id,
|
40
|
+
title: resource.type&.title
|
41
|
+
},
|
42
|
+
authors: {
|
43
|
+
id: resource.author_users.map(&:id),
|
44
|
+
name: resource.author_users.map(&:name)
|
45
|
+
},
|
46
|
+
area: {
|
47
|
+
id: resource.area.try(:id),
|
48
|
+
name: resource.area.try(:name) || empty_translatable
|
49
|
+
}
|
50
|
+
}
|
51
|
+
end
|
52
|
+
end
|
53
|
+
end
|
54
|
+
end
|
@@ -9,7 +9,7 @@ module Decidim
|
|
9
9
|
def initialize(args = {})
|
10
10
|
@secret = args.fetch(:secret) || "default"
|
11
11
|
@key = ActiveSupport::KeyGenerator.new(secret).generate_key(
|
12
|
-
Rails.application.
|
12
|
+
Rails.application.secret_key_base, ActiveSupport::MessageEncryptor.key_len
|
13
13
|
)
|
14
14
|
@encryptor = ActiveSupport::MessageEncryptor.new(@key)
|
15
15
|
end
|
@@ -73,8 +73,7 @@
|
|
73
73
|
<% if allowed_to? :export_pdf_signatures, :initiative, initiative: current_initiative %>
|
74
74
|
<%= link_to t(".export_pdf_signatures"),
|
75
75
|
export_pdf_signatures_initiative_path(current_initiative, format: :pdf),
|
76
|
-
class: "button button__sm button__secondary"
|
77
|
-
data: { confirm: t(".confirm") } %>
|
76
|
+
class: "button button__sm button__secondary" %>
|
78
77
|
<% end %>
|
79
78
|
</div>
|
80
79
|
</div>
|
@@ -45,6 +45,13 @@
|
|
45
45
|
<td class="table-list__date"><%= l initiative.created_at, format: :short %></td>
|
46
46
|
<td class="table-list__date"><%= initiative.published_at? ? l(initiative.published_at, format: :short) : "" %></td>
|
47
47
|
<td class="table-list__actions">
|
48
|
+
|
49
|
+
<% if allowed_to? :read, :share_tokens, current_participatory_space: initiative %>
|
50
|
+
<%= icon_link_to "share-line", decidim_admin_initiatives.initiative_share_tokens_path(initiative), t("actions.share_tokens", scope: "decidim.admin"), class: "action-icon--new" %>
|
51
|
+
<% else %>
|
52
|
+
<span class="action-space icon"></span>
|
53
|
+
<% end %>
|
54
|
+
|
48
55
|
<% if allowed_to? :edit, :initiative, initiative: initiative %>
|
49
56
|
<%= icon_link_to "pencil-line",
|
50
57
|
decidim_admin_initiatives.edit_initiative_path(initiative.to_param),
|
@@ -1,11 +1,10 @@
|
|
1
1
|
<% add_decidim_meta_tags({
|
2
|
-
image_url: current_initiative
|
2
|
+
image_url: resolve_meta_image_url(current_initiative),
|
3
3
|
description: translated_attribute(current_initiative.description),
|
4
4
|
title: translated_attribute(current_initiative.title),
|
5
5
|
url: initiative_url(current_initiative.id)
|
6
6
|
}) %>
|
7
7
|
|
8
|
-
<% add_decidim_page_title(translated_attribute(current_initiative.title)) %>
|
9
8
|
<% provide :meta_image_url, current_initiative.type.attached_uploader(:banner_image).url %>
|
10
9
|
|
11
10
|
<%= render layout: "layouts/decidim/shared/layout_center" do %>
|
@@ -47,10 +47,10 @@
|
|
47
47
|
<% if initiative_type.attachments_enabled? %>
|
48
48
|
<%= f.attachment :documents,
|
49
49
|
multiple: true,
|
50
|
-
label: t("decidim.initiatives.form.
|
51
|
-
button_label: t("decidim.initiatives.form.
|
50
|
+
label: t("decidim.initiatives.form.add_attachments"),
|
51
|
+
button_label: t("decidim.initiatives.form.add_attachments"),
|
52
52
|
button_class: "button button__lg button__transparent-secondary w-full",
|
53
|
-
button_edit_label: t("decidim.initiatives.form.
|
53
|
+
button_edit_label: t("decidim.initiatives.form.edit_attachments"),
|
54
54
|
help_text: t("attachment_legend", scope: "decidim.initiatives.form") %>
|
55
55
|
<%= f.attachment :photos,
|
56
56
|
multiple: true,
|
@@ -27,8 +27,16 @@
|
|
27
27
|
<div class="initiatives__selection__text">
|
28
28
|
<h2 class="h5 text-secondary"><%= translated_attribute(type.title) %></h2>
|
29
29
|
<span><%= decidim_sanitize_admin(translated_attribute(type.description)) %></span>
|
30
|
-
<%=
|
31
|
-
|
30
|
+
<%= action_authorized_link_to(
|
31
|
+
:create,
|
32
|
+
fill_data_create_initiative_index_path(initiative: { type_id: type.id }),
|
33
|
+
authorizations_modal_path: authorization_create_modal_initiative_path(type),
|
34
|
+
permissions_holder: type,
|
35
|
+
class: "button button__sm button__secondary",
|
36
|
+
"data-dialog-open": "not-authorized-modal",
|
37
|
+
onclick: "event.preventDefault();"
|
38
|
+
) do %>
|
39
|
+
<%= t("verification_required", scope: "decidim.initiatives.create_initiative.select_initiative_type") %>
|
32
40
|
<% end %>
|
33
41
|
</div>
|
34
42
|
</div>
|
@@ -51,10 +51,10 @@
|
|
51
51
|
<% if current_initiative.type.attachments_enabled? %>
|
52
52
|
<%= form.attachment :documents,
|
53
53
|
multiple: true,
|
54
|
-
label: t("decidim.initiatives.form.
|
55
|
-
button_label: t("decidim.initiatives.form.
|
54
|
+
label: t("decidim.initiatives.form.add_attachments"),
|
55
|
+
button_label: t("decidim.initiatives.form.add_attachments"),
|
56
56
|
button_class: "button button__lg button__transparent-secondary w-full",
|
57
|
-
button_edit_label: t("decidim.initiatives.form.
|
57
|
+
button_edit_label: t("decidim.initiatives.form.edit_attachments"),
|
58
58
|
help_text: t("decidim.initiatives.form.attachment_legend") %>
|
59
59
|
|
60
60
|
<%= form.attachment :photos,
|
@@ -1,27 +1,30 @@
|
|
1
1
|
<% if Decidim::Initiatives.creation_enabled %>
|
2
|
-
<% if
|
3
|
-
|
4
|
-
<%= t("new_initiative", scope: "decidim.initiatives.initiatives.index_header") %>
|
5
|
-
<%= icon "add-fill" %>
|
6
|
-
<% end %>
|
7
|
-
<% elsif current_user %>
|
8
|
-
<% if allowed_to?(:create, :initiative, { initiative_type: available_initiative_types.first }) %>
|
2
|
+
<% if available_initiative_types.size > 1 %>
|
3
|
+
<% if current_user %>
|
9
4
|
<%= link_to create_initiative_path(:select_initiative_type), class: "!px-4 title-action__action button button__xl button__secondary w-full" do %>
|
10
5
|
<%= t("new_initiative", scope: "decidim.initiatives.initiatives.index_header") %>
|
11
6
|
<%= icon "add-fill" %>
|
12
7
|
<% end %>
|
13
8
|
<% else %>
|
14
|
-
|
9
|
+
<% content_for(:redirect_after_login) { create_initiative_url(:select_initiative_type) } %>
|
10
|
+
<button type="button" class="button button__xl button__secondary w-full" data-dialog-open="loginModal" aria-controls="loginModal" aria-haspopup="dialog" tabindex="0">
|
15
11
|
<%= t("new_initiative", scope: "decidim.initiatives.initiatives.index_header") %>
|
16
12
|
<%= icon "add-fill" %>
|
17
|
-
|
13
|
+
</button>
|
18
14
|
<% end %>
|
19
|
-
<%
|
20
|
-
<% content_for(:redirect_after_login) {
|
21
|
-
|
15
|
+
<% elsif (initiative_type = available_initiative_types.first).present? %>
|
16
|
+
<% content_for(:redirect_after_login) { fill_data_create_initiative_index_path(initiative: { type_id: initiative_type.id }) } unless current_user %>
|
17
|
+
<%= action_authorized_link_to(
|
18
|
+
:create,
|
19
|
+
fill_data_create_initiative_index_path(initiative: { type_id: initiative_type.id }),
|
20
|
+
authorizations_modal_path: authorization_create_modal_initiative_path(initiative_type),
|
21
|
+
permissions_holder: initiative_type,
|
22
|
+
"data-dialog-open": allowed_to?(:create, :initiative, { initiative_type: }) ? "" : "not-authorized-modal",
|
23
|
+
class: "!px-4 title-action__action button button__xl button__secondary w-full"
|
24
|
+
) do %>
|
22
25
|
<%= t("new_initiative", scope: "decidim.initiatives.initiatives.index_header") %>
|
23
26
|
<%= icon "add-fill" %>
|
24
|
-
|
27
|
+
<% end %>
|
25
28
|
<% end %>
|
26
29
|
<% end %>
|
27
30
|
|
@@ -34,8 +34,14 @@
|
|
34
34
|
</button>
|
35
35
|
<% end %>
|
36
36
|
<% else %>
|
37
|
-
<%=
|
38
|
-
|
39
|
-
|
37
|
+
<%= action_authorized_link_to(
|
38
|
+
:vote,
|
39
|
+
t("vote", scope: "decidim.initiatives.initiatives.vote_cabin"),
|
40
|
+
steps ? initiative_signatures_path(initiative_slug: current_initiative.slug) : initiative_path(current_initiative),
|
41
|
+
resource: current_initiative,
|
42
|
+
permissions_holder: current_initiative.type,
|
43
|
+
authorizations_modal_path: authorization_sign_modal_initiative_path(current_initiative),
|
44
|
+
class: "button button__xl w-full button__secondary"
|
45
|
+
) %>
|
40
46
|
<% end %>
|
41
47
|
<% end %>
|
@@ -4,7 +4,6 @@
|
|
4
4
|
initiative:,
|
5
5
|
vote_label: t("vote", scope: "decidim.initiatives.initiatives.vote_cabin"),
|
6
6
|
unvote_label: t("already_voted", scope: "decidim.initiatives.initiatives.vote_cabin"),
|
7
|
-
verification_label: t("verification_required", scope: "decidim.initiatives.initiatives.vote_cabin"),
|
8
7
|
steps: signature_has_steps?
|
9
8
|
} %>
|
10
9
|
<% else %>
|
@@ -1,9 +1,8 @@
|
|
1
|
-
<% add_decidim_meta_tags(
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
}) %>
|
1
|
+
<% add_decidim_meta_tags(
|
2
|
+
description: translated_attribute(current_initiative.description),
|
3
|
+
title: translated_attribute(current_initiative.title),
|
4
|
+
url: initiative_url(current_initiative.id),
|
5
|
+
resource: current_initiative) %>
|
7
6
|
|
8
7
|
<%
|
9
8
|
edit_link(
|
@@ -210,8 +209,8 @@ edit_link(
|
|
210
209
|
<% if current_initiative.commentable? && current_initiative.published? %>
|
211
210
|
<%= cell "decidim/comments_button", nil, display: current_initiative.commentable? && current_initiative.published? %>
|
212
211
|
<% end %>
|
213
|
-
<div class="ml-auto">
|
214
|
-
<%= cell "decidim/
|
212
|
+
<div class="ml-auto lg:ml-0">
|
213
|
+
<%= cell "decidim/share_widget", current_initiative %>
|
215
214
|
</div>
|
216
215
|
</section>
|
217
216
|
|
@@ -0,0 +1,11 @@
|
|
1
|
+
<div class="inline-block relative">
|
2
|
+
<%= button_tag data: { component: "dropdown", target: "initiatives-dropdown-menu-settings" }, class: "dropdown__trigger button button__transparent" do %>
|
3
|
+
<span>
|
4
|
+
<%= t("menu.manage", scope: "decidim.admin") %>
|
5
|
+
</span>
|
6
|
+
<%= icon "arrow-down-s-line" %>
|
7
|
+
<% end %>
|
8
|
+
<div id="initiatives-dropdown-menu-settings" class="process-title-content-dropdown" aria-hidden="true">
|
9
|
+
<%= dropdown_menu(:admin_initiatives_menu).render %>
|
10
|
+
</div>
|
11
|
+
</div>
|
@@ -1,13 +1,5 @@
|
|
1
1
|
<% content_for :breadcrumb_context_menu do %>
|
2
|
-
|
3
|
-
<%= button_tag data: { component: "dropdown", target: "initiatives-dropdown-menu-settings" }, class: "dropdown__trigger button button__transparent" do %>
|
4
|
-
<%= t("actions.manage", scope: "decidim.admin") %>
|
5
|
-
<%= icon "arrow-down-s-line" %>
|
6
|
-
<% end %>
|
7
|
-
<div id="initiatives-dropdown-menu-settings" class="process-title-content-dropdown" aria-hidden="true">
|
8
|
-
<%= dropdown_menu(:admin_initiatives_menu).render %>
|
9
|
-
</div>
|
10
|
-
</div>
|
2
|
+
<%= render partial: "layouts/decidim/admin/manage_initiatives" %>
|
11
3
|
<% end %>
|
12
4
|
|
13
5
|
<%= render "layouts/decidim/admin/application" do %>
|
data/config/assets.rb
CHANGED
@@ -5,7 +5,5 @@ base_path = File.expand_path("..", __dir__)
|
|
5
5
|
Decidim::Webpacker.register_path("#{base_path}/app/packs")
|
6
6
|
Decidim::Webpacker.register_entrypoints(
|
7
7
|
decidim_initiatives: "#{base_path}/app/packs/entrypoints/decidim_initiatives.js",
|
8
|
-
decidim_initiatives_admin: "#{base_path}/app/packs/entrypoints/decidim_initiatives_admin.js"
|
9
|
-
decidim_initiatives_print: "#{base_path}/app/packs/entrypoints/decidim_initiatives_print.js",
|
10
|
-
decidim_initiatives_initiatives_votes: "#{base_path}/app/packs/entrypoints/decidim_initiatives_initiatives_votes.js"
|
8
|
+
decidim_initiatives_admin: "#{base_path}/app/packs/entrypoints/decidim_initiatives_admin.js"
|
11
9
|
)
|
data/config/locales/ar.yml
CHANGED
@@ -96,9 +96,8 @@ ar:
|
|
96
96
|
initiative_start_date: تاريخ البدء
|
97
97
|
initiative_title: عنوان المبادرة
|
98
98
|
name_and_surname: اسم ولقب
|
99
|
+
nickname: الاسم المستعار
|
99
100
|
postal_code: الكود البريدى
|
100
|
-
scope: نطاق
|
101
|
-
time_and_date: الوقت و التاريخ
|
102
101
|
timestamp: الطابع الزمني
|
103
102
|
titles:
|
104
103
|
initiatives: المبادرات
|
@@ -125,8 +124,8 @@ ar:
|
|
125
124
|
badges:
|
126
125
|
initiatives:
|
127
126
|
conditions:
|
128
|
-
|
129
|
-
|
127
|
+
- انتقل إلى مساحة مشاركة المبادرات
|
128
|
+
- اتبع الخطوات لإنشاء مبادرة جديدة
|
130
129
|
description: تُمنح هذه الشارة عند إطلاق مبادرات جديدة ، وإقامة شراكة مع الآخرين لتنفيذها.
|
131
130
|
description_another: حصل هذا المشارك على %{score} مبادرة تم نشرها.
|
132
131
|
name: المبادرات المنشورة
|
@@ -202,7 +201,6 @@ ar:
|
|
202
201
|
admin_states:
|
203
202
|
created: تمّ إنشاؤه
|
204
203
|
discarded: التخلص منها
|
205
|
-
published: نشرت
|
206
204
|
validating: المصادقة الفنية
|
207
205
|
application_helper:
|
208
206
|
filter_state_values:
|
@@ -253,6 +251,10 @@ ar:
|
|
253
251
|
email_outro: لقد تلقيت هذا الإشعار لأنك تتابع %{author_nickname}. يمكنك إيقاف تلقي الإخطارات باتباع الرابط السابق.
|
254
252
|
email_subject: المبادرة التي أقرتها %{author_nickname}
|
255
253
|
notification_title: تمت الموافقة على مبادرة <a href="%{resource_path}">%{resource_title}</a> من قبل <a href="%{author_path}">%{author_name} %{author_nickname}</a>.
|
254
|
+
form:
|
255
|
+
add_attachments: إضافة مرفقات
|
256
|
+
attachment_legend: إضافة مستند أو صورة
|
257
|
+
edit_attachments: تعديل المرفقات
|
256
258
|
initiative_signatures:
|
257
259
|
fill_personal_data:
|
258
260
|
continue: استمر
|
@@ -315,7 +317,6 @@ ar:
|
|
315
317
|
full_name: الاسم الكامل
|
316
318
|
initiative:
|
317
319
|
description: 'الوصف:'
|
318
|
-
print: طباعة
|
319
320
|
result:
|
320
321
|
initiative_rejected_reason: تم رفض هذه المبادرة بسبب افتقارها للتوقيعات.
|
321
322
|
signatures_count:
|
@@ -327,7 +328,6 @@ ar:
|
|
327
328
|
other: " التوقيعات"
|
328
329
|
vote_cabin:
|
329
330
|
already_voted: وقعت بالفعل
|
330
|
-
verification_required: تحقق من حسابك لتوقيع المبادرة
|
331
331
|
vote: إشارة
|
332
332
|
votes_blocked: توقيع المعوقين
|
333
333
|
votes_count:
|
@@ -365,7 +365,6 @@ ar:
|
|
365
365
|
comment: تعليق
|
366
366
|
initiatives_type:
|
367
367
|
actions:
|
368
|
-
create: إنشاء
|
369
368
|
title: أفعال
|
370
369
|
vote: إشارة
|
371
370
|
layouts:
|
data/config/locales/bg.yml
CHANGED
@@ -92,7 +92,6 @@ bg:
|
|
92
92
|
accepted: Достатъчно подписи
|
93
93
|
created: Създаден
|
94
94
|
discarded: Отхвърлено
|
95
|
-
published: Публикувано
|
96
95
|
rejected: Няма достатъчно подписи
|
97
96
|
validating: Техническа проверка
|
98
97
|
type_id_eq:
|
@@ -101,7 +100,6 @@ bg:
|
|
101
100
|
title_or_description_or_id_string_or_author_name_or_author_nickname_cont: Търсете в %{collection} по заглавие, описание, идент. № или име на автора.
|
102
101
|
initiatives_settings:
|
103
102
|
update:
|
104
|
-
error: Възникна грешка.
|
105
103
|
success: Настройките на инициативите са актуализирани успешно.
|
106
104
|
menu:
|
107
105
|
attachments: Прикачени файлове
|
@@ -147,8 +145,6 @@ bg:
|
|
147
145
|
initiative_title: Заглавие на инициативата
|
148
146
|
name_and_surname: Име и фамилия
|
149
147
|
postal_code: Пощенски код
|
150
|
-
scope: Обхват
|
151
|
-
time_and_date: Време и дата
|
152
148
|
timestamp: Времево клеймо
|
153
149
|
titles:
|
154
150
|
initiatives: Инициативи
|
@@ -191,8 +187,8 @@ bg:
|
|
191
187
|
badges:
|
192
188
|
initiatives:
|
193
189
|
conditions:
|
194
|
-
|
195
|
-
|
190
|
+
- Отидете в пространството за участие на Инициативи
|
191
|
+
- Следвайте стъпките, за да създадете нова инициатива
|
196
192
|
description: Тази значка се предоставя, когато стартирате нови инициативи, като си партнирате с други, за да ги изпълните.
|
197
193
|
description_another: Този участник е публикувал %{score} инициативи.
|
198
194
|
description_own: Имате %{score} публикувани инициативи.
|
@@ -262,7 +258,6 @@ bg:
|
|
262
258
|
new: Ново
|
263
259
|
photos: Снимки
|
264
260
|
update:
|
265
|
-
error: Възникна грешка.
|
266
261
|
success: Инициативата беше актуализирана успешно.
|
267
262
|
initiatives_settings:
|
268
263
|
edit:
|
@@ -276,7 +271,6 @@ bg:
|
|
276
271
|
title: Настройки за инициативи
|
277
272
|
initiatives_type_scopes:
|
278
273
|
create:
|
279
|
-
error: Възникна грешка.
|
280
274
|
success: Създаден е нов обхват за дадения тип инициатива.
|
281
275
|
destroy:
|
282
276
|
success: Обхватът беше премахнат успешно.
|
@@ -287,11 +281,8 @@ bg:
|
|
287
281
|
create: Създаване
|
288
282
|
title: Създаване на обхват на типа инициатива
|
289
283
|
update:
|
290
|
-
error: Възникна грешка.
|
291
284
|
success: Обхватът беше актуализиран успешно.
|
292
285
|
initiatives_types:
|
293
|
-
create:
|
294
|
-
error: Възникна грешка.
|
295
286
|
destroy:
|
296
287
|
success: Типът инициатива беше премахнат успешно.
|
297
288
|
edit:
|
@@ -307,7 +298,6 @@ bg:
|
|
307
298
|
create: Създаване
|
308
299
|
title: Нов тип инициатива
|
309
300
|
update:
|
310
|
-
error: Възникна грешка.
|
311
301
|
success: Типът инициатива беше актуализиран успешно.
|
312
302
|
admin_log:
|
313
303
|
initiative:
|
@@ -325,7 +315,6 @@ bg:
|
|
325
315
|
accepted: Достатъчно подписи
|
326
316
|
created: Създаден
|
327
317
|
discarded: Отхвърлено
|
328
|
-
published: Публикувано
|
329
318
|
rejected: Няма достатъчно подписи
|
330
319
|
validating: Техническа проверка
|
331
320
|
application_helper:
|
@@ -423,10 +412,7 @@ bg:
|
|
423
412
|
email_subject: "%{applicant_nickname} иска да се присъедини към вашата инициатива"
|
424
413
|
notification_title: <a href="%{applicant_profile_url}">%{applicant_nickname}</a> кандидатства за промоторския комитет на вашата инициатива <a href="%{resource_url}">%{resource_title}</a>. За да приемете или отхвърлите, щракнете <a href="%{resource_url}/edit">тук</a>.
|
425
414
|
form:
|
426
|
-
add_documents: Добавяне на документи
|
427
415
|
add_image: Добавяне на изображение
|
428
|
-
attachment_legend: "(Незадължително) Добавяне на прикачен файл"
|
429
|
-
edit_documents: Редактиране на документ
|
430
416
|
edit_image: Редактиране на изображение
|
431
417
|
image_legend: "(По избор) Добавяне на изображение"
|
432
418
|
index:
|
@@ -515,9 +501,7 @@ bg:
|
|
515
501
|
phone_number: Телефонен номер
|
516
502
|
place_date: Място, дата
|
517
503
|
postal_code: Пощенски код (ПК)
|
518
|
-
print: Принтиране
|
519
504
|
province: Район/Област
|
520
|
-
section: 'При поискване от организацията, моля, отпечатайте и попълнете този формуляр, за да го изпратите, където е посочено:'
|
521
505
|
signature: Подпис
|
522
506
|
result:
|
523
507
|
answer_title: На тази инициатива е отговорено.
|
@@ -539,7 +523,6 @@ bg:
|
|
539
523
|
other: " подписи"
|
540
524
|
vote_cabin:
|
541
525
|
already_voted: Вече подписани
|
542
|
-
verification_required: Потвърдете профила си, за да подпишете инициативата
|
543
526
|
vote: Подписване
|
544
527
|
votes_blocked: Подписването е деактивирано
|
545
528
|
votes_count:
|
@@ -574,7 +557,6 @@ bg:
|
|
574
557
|
accepted: Достатъчно подписи
|
575
558
|
created: Създаден
|
576
559
|
discarded: Отхвърлено
|
577
|
-
published: Публикувано
|
578
560
|
rejected: Няма достатъчно подписи
|
579
561
|
validating: Техническа проверка
|
580
562
|
states:
|
@@ -582,7 +564,6 @@ bg:
|
|
582
564
|
expired: Изтекло
|
583
565
|
unavailable_scope: Недостъпен обхват
|
584
566
|
update:
|
585
|
-
error: Възникна грешка.
|
586
567
|
success: Инициативата беше актуализирана успешно.
|
587
568
|
menu:
|
588
569
|
initiatives: Инициативи
|
@@ -592,7 +573,6 @@ bg:
|
|
592
573
|
comment: Коментар
|
593
574
|
initiatives_type:
|
594
575
|
actions:
|
595
|
-
create: Създаване
|
596
576
|
title: Активности
|
597
577
|
vote: Подписване
|
598
578
|
layouts:
|