decidim-assemblies 0.24.3 → 0.25.0.rc1
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.
- checksums.yaml +4 -4
- data/app/cells/decidim/assemblies/assembly_m_cell.rb +1 -1
- data/app/cells/decidim/assemblies/assembly_member/show.erb +1 -1
- data/app/cells/decidim/assemblies/content_blocks/highlighted_assemblies/show.erb +1 -1
- data/app/commands/decidim/assemblies/admin/copy_assembly.rb +11 -3
- data/app/commands/decidim/assemblies/admin/create_assembly.rb +2 -1
- data/app/commands/decidim/assemblies/admin/create_assembly_member.rb +5 -1
- data/app/commands/decidim/assemblies/admin/update_assembly.rb +7 -11
- data/app/controllers/decidim/assemblies/admin/assemblies_controller.rb +1 -5
- data/app/forms/decidim/assemblies/admin/assembly_form.rb +3 -2
- data/app/forms/decidim/assemblies/admin/assembly_import_form.rb +1 -0
- data/app/forms/decidim/assemblies/admin/assembly_member_form.rb +1 -1
- data/app/helpers/decidim/assemblies/admin/assemblies_admin_menu_helper.rb +0 -5
- data/app/models/decidim/assembly.rb +5 -5
- data/app/models/decidim/assembly_member.rb +1 -1
- data/app/packs/entrypoints/decidim_assemblies.js +5 -0
- data/app/packs/entrypoints/decidim_assemblies_admin.js +3 -0
- data/app/{assets/images/decidim/assemblies/assembly.svg → packs/images/decidim/assemblies/decidim_assemblies.svg} +0 -0
- data/app/packs/src/decidim/assemblies/admin/assemblies.js +63 -0
- data/app/{assets/javascripts/decidim/assemblies/admin/assembly_members.js.es6 → packs/src/decidim/assemblies/admin/assembly_members.js} +3 -3
- data/app/packs/src/decidim/assemblies/assemblies.js +14 -0
- data/app/packs/src/decidim/assemblies/orgchart.js +695 -0
- data/app/presenters/decidim/assemblies/assembly_presenter.rb +2 -12
- data/app/presenters/decidim/assemblies/assembly_stats_presenter.rb +3 -13
- data/app/queries/decidim/assemblies/admin/admin_users.rb +24 -11
- data/app/serializers/decidim/assemblies/assembly_importer.rb +3 -2
- data/app/serializers/decidim/assemblies/assembly_serializer.rb +4 -2
- data/app/views/decidim/assemblies/admin/assemblies/_form.html.erb +6 -3
- data/app/views/decidim/assemblies/admin/assembly_copies/_form.html.erb +1 -1
- data/app/views/decidim/assemblies/admin/assembly_imports/_form.html.erb +1 -1
- data/app/views/decidim/assemblies/admin/assembly_members/_form.html.erb +2 -2
- data/app/views/decidim/assemblies/assemblies/_promoted_assembly.html.erb +1 -1
- data/app/views/decidim/assemblies/assemblies/index.html.erb +2 -2
- data/app/views/decidim/assemblies/assemblies/show.html.erb +6 -4
- data/app/views/layouts/decidim/_assembly_header.html.erb +1 -1
- data/app/views/layouts/decidim/admin/assemblies.html.erb +1 -1
- data/app/views/layouts/decidim/admin/assembly.html.erb +4 -73
- data/app/views/layouts/decidim/assembly.html.erb +2 -2
- data/config/assets.rb +9 -0
- data/config/locales/ar.yml +0 -17
- data/config/locales/ca.yml +4 -38
- data/config/locales/cs.yml +4 -38
- data/config/locales/de.yml +4 -38
- data/config/locales/el.yml +0 -31
- data/config/locales/en.yml +5 -39
- data/config/locales/es-MX.yml +4 -38
- data/config/locales/es-PY.yml +4 -38
- data/config/locales/es.yml +4 -38
- data/config/locales/eu.yml +0 -17
- data/config/locales/fi-plain.yml +5 -39
- data/config/locales/fi.yml +5 -39
- data/config/locales/fr-CA.yml +1 -39
- data/config/locales/fr-LU.yml +449 -0
- data/config/locales/fr.yml +0 -38
- data/config/locales/gl.yml +4 -38
- data/config/locales/hu.yml +0 -31
- data/config/locales/id-ID.yml +0 -17
- data/config/locales/is-IS.yml +0 -14
- data/config/locales/it.yml +6 -39
- data/config/locales/ja.yml +4 -33
- data/config/locales/lb-LU.yml +1 -0
- data/config/locales/lv.yml +0 -30
- data/config/locales/nl.yml +5 -39
- data/config/locales/no.yml +0 -38
- data/config/locales/pl.yml +4 -41
- data/config/locales/pt-BR.yml +82 -17
- data/config/locales/pt.yml +0 -31
- data/config/locales/ro-RO.yml +5 -36
- data/config/locales/ru.yml +0 -17
- data/config/locales/sk.yml +0 -16
- data/config/locales/sl.yml +0 -17
- data/config/locales/sr-CS.yml +0 -16
- data/config/locales/sv.yml +3 -36
- data/config/locales/tr-TR.yml +0 -31
- data/config/locales/uk.yml +0 -17
- data/config/locales/zh-CN.yml +0 -31
- data/db/migrate/20210507063604_add_announcement_to_assemblies.rb +7 -0
- data/lib/decidim/api/assembly_type.rb +10 -1
- data/lib/decidim/assemblies/admin_engine.rb +122 -30
- data/lib/decidim/assemblies/engine.rb +6 -9
- data/lib/decidim/assemblies/participatory_space.rb +46 -8
- data/lib/decidim/assemblies/test/factories.rb +1 -0
- data/lib/decidim/assemblies/version.rb +1 -1
- metadata +22 -23
- data/app/assets/config/admin/decidim_assemblies_manifest.js +0 -2
- data/app/assets/config/decidim_assemblies_manifest.js +0 -2
- data/app/assets/javascripts/decidim/assemblies/admin/assemblies.js.es6 +0 -67
- data/app/assets/javascripts/decidim/assemblies/assemblies.js.es6 +0 -18
- data/app/assets/javascripts/decidim/assemblies/orgchart.js.es6 +0 -698
- data/app/cells/decidim/assemblies/statistic/show.erb +0 -9
- data/app/cells/decidim/assemblies/statistic_cell.rb +0 -20
- data/app/cells/decidim/assemblies/statistics/show.erb +0 -17
- data/app/cells/decidim/assemblies/statistics_cell.rb +0 -18
- data/config/locales/ja-JP.yml +0 -471
|
@@ -3,22 +3,12 @@
|
|
|
3
3
|
module Decidim
|
|
4
4
|
module Assemblies
|
|
5
5
|
class AssemblyPresenter < SimpleDelegator
|
|
6
|
-
include Rails.application.routes.mounted_helpers
|
|
7
|
-
include ActionView::Helpers::UrlHelper
|
|
8
|
-
|
|
9
|
-
delegate :url, to: :hero_image, prefix: true
|
|
10
|
-
delegate :url, to: :banner_image, prefix: true
|
|
11
|
-
|
|
12
6
|
def hero_image_url
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
URI.join(decidim.root_url(host: assembly.organization.host), assembly.hero_image_url).to_s
|
|
7
|
+
assembly.attached_uploader(:hero_image).url(host: assembly.organization.host)
|
|
16
8
|
end
|
|
17
9
|
|
|
18
10
|
def banner_image_url
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
URI.join(decidim.root_url(host: assembly.organization.host), assembly.banner_image_url).to_s
|
|
11
|
+
assembly.attached_uploader(:banner_image).url(host: assembly.organization.host)
|
|
22
12
|
end
|
|
23
13
|
|
|
24
14
|
def assembly
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
module Decidim
|
|
4
4
|
module Assemblies
|
|
5
5
|
# A presenter to render statistics in an Assembly.
|
|
6
|
-
class AssemblyStatsPresenter <
|
|
6
|
+
class AssemblyStatsPresenter < Decidim::StatsPresenter
|
|
7
7
|
attribute :assembly, Decidim::Assembly
|
|
8
8
|
include Decidim::IconHelper
|
|
9
9
|
|
|
@@ -13,22 +13,12 @@ module Decidim
|
|
|
13
13
|
highlighted_stats.concat(assembly_followers_stats(priority: StatsRegistry::HIGH_PRIORITY))
|
|
14
14
|
highlighted_stats.concat(component_stats(priority: StatsRegistry::HIGH_PRIORITY))
|
|
15
15
|
highlighted_stats.concat(component_stats(priority: StatsRegistry::MEDIUM_PRIORITY))
|
|
16
|
+
highlighted_stats.concat(comments_stats(:assemblies))
|
|
16
17
|
highlighted_stats = highlighted_stats.reject(&:empty?)
|
|
17
18
|
highlighted_stats = highlighted_stats.reject { |_stat_manifest, _stat_title, stat_number| stat_number.zero? }
|
|
18
19
|
grouped_highlighted_stats = highlighted_stats.group_by(&:first)
|
|
19
20
|
|
|
20
|
-
statistics
|
|
21
|
-
grouped_highlighted_stats.each do |_manifest_name, stats|
|
|
22
|
-
stats.each_with_index.each do |stat, _index|
|
|
23
|
-
stat.each_with_index.map do |_item, subindex|
|
|
24
|
-
next unless (subindex % 3).zero?
|
|
25
|
-
next if stat[subindex + 2].zero?
|
|
26
|
-
|
|
27
|
-
statistics << { stat_title: stat[subindex + 1], stat_number: stat[subindex + 2] }
|
|
28
|
-
end
|
|
29
|
-
end
|
|
30
|
-
end
|
|
31
|
-
statistics
|
|
21
|
+
statistics(grouped_highlighted_stats)
|
|
32
22
|
end
|
|
33
23
|
|
|
34
24
|
private
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
module Decidim
|
|
4
4
|
module Assemblies
|
|
5
5
|
module Admin
|
|
6
|
-
# A class used to find the admins for an assembly.
|
|
6
|
+
# A class used to find the admins for an assembly or an organization assemblies.
|
|
7
7
|
class AdminUsers < Rectify::Query
|
|
8
8
|
# Syntactic sugar to initialize the class and return the queried objects.
|
|
9
9
|
#
|
|
@@ -12,33 +12,46 @@ module Decidim
|
|
|
12
12
|
new(assembly).query
|
|
13
13
|
end
|
|
14
14
|
|
|
15
|
+
# Syntactic sugar to initialize the class and return the queried objects.
|
|
16
|
+
#
|
|
17
|
+
# organization - an organization that needs to find its assembly admins
|
|
18
|
+
def self.for_organization(organization)
|
|
19
|
+
new(nil, organization).query
|
|
20
|
+
end
|
|
21
|
+
|
|
15
22
|
# Initializes the class.
|
|
16
23
|
#
|
|
17
24
|
# assembly - an assembly that needs to find its assembly admins
|
|
18
|
-
|
|
25
|
+
# organization - an organization that needs to find its assembly admins
|
|
26
|
+
def initialize(assembly, organization = nil)
|
|
19
27
|
@assembly = assembly
|
|
28
|
+
@organization = assembly&.organization || organization
|
|
20
29
|
end
|
|
21
30
|
|
|
22
31
|
# Finds organization admins and the users with role admin for the given assembly.
|
|
23
32
|
#
|
|
24
33
|
# Returns an ActiveRecord::Relation.
|
|
25
34
|
def query
|
|
26
|
-
|
|
35
|
+
organization.admins.or(assemblies_user_admins)
|
|
27
36
|
end
|
|
28
37
|
|
|
29
38
|
private
|
|
30
39
|
|
|
31
|
-
attr_reader :assembly
|
|
40
|
+
attr_reader :assembly, :organization
|
|
32
41
|
|
|
33
|
-
def
|
|
34
|
-
|
|
42
|
+
def assemblies_user_admins
|
|
43
|
+
Decidim::User.where(
|
|
44
|
+
id: Decidim::AssemblyUserRole.where(assembly: assemblies, role: :admin)
|
|
45
|
+
.select(:decidim_user_id)
|
|
46
|
+
)
|
|
35
47
|
end
|
|
36
48
|
|
|
37
|
-
def
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
49
|
+
def assemblies
|
|
50
|
+
if assembly
|
|
51
|
+
[assembly]
|
|
52
|
+
else
|
|
53
|
+
Decidim::Assembly.where(organization: organization)
|
|
54
|
+
end
|
|
42
55
|
end
|
|
43
56
|
end
|
|
44
57
|
end
|
|
@@ -58,7 +58,8 @@ module Decidim
|
|
|
58
58
|
youtube_handler: attributes["youtube_handler"],
|
|
59
59
|
github_handler: attributes["github_handler"],
|
|
60
60
|
created_by: attributes["created_by"],
|
|
61
|
-
meta_scope: attributes["meta_scope"]
|
|
61
|
+
meta_scope: attributes["meta_scope"],
|
|
62
|
+
announcement: attributes["announcement"]
|
|
62
63
|
)
|
|
63
64
|
@imported_assembly.remote_hero_image_url = attributes["remote_hero_image_url"] if remote_file_exists?(attributes["remote_hero_image_url"])
|
|
64
65
|
@imported_assembly.remote_banner_image_url = attributes["remote_banner_image_url"] if remote_file_exists?(attributes["remote_banner_image_url"])
|
|
@@ -115,7 +116,7 @@ module Decidim
|
|
|
115
116
|
content_type: file_tmp.content_type,
|
|
116
117
|
attached_to: @imported_assembly,
|
|
117
118
|
weight: file["weight"],
|
|
118
|
-
file:
|
|
119
|
+
file: file_tmp, # Define attached_to before this
|
|
119
120
|
file_size: file_tmp.size
|
|
120
121
|
)
|
|
121
122
|
attachment.create_attachment_collection(file["attachment_collection"])
|
|
@@ -72,13 +72,15 @@ module Decidim
|
|
|
72
72
|
attachment_collections: serialize_attachment_collections,
|
|
73
73
|
files: serialize_attachments
|
|
74
74
|
},
|
|
75
|
-
components: serialize_components
|
|
75
|
+
components: serialize_components,
|
|
76
|
+
announcement: assembly.announcement
|
|
76
77
|
}
|
|
77
78
|
end
|
|
78
79
|
|
|
79
80
|
private
|
|
80
81
|
|
|
81
82
|
attr_reader :assembly
|
|
83
|
+
alias resource assembly
|
|
82
84
|
|
|
83
85
|
def serialize_categories
|
|
84
86
|
return unless assembly.categories.first_class.any?
|
|
@@ -141,7 +143,7 @@ module Decidim
|
|
|
141
143
|
|
|
142
144
|
def serialize_components
|
|
143
145
|
serializer = Decidim::Exporters::ParticipatorySpaceComponentsSerializer.new(@assembly)
|
|
144
|
-
serializer.
|
|
146
|
+
serializer.run
|
|
145
147
|
end
|
|
146
148
|
end
|
|
147
149
|
end
|
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
<%= javascript_include_tag "decidim/slug_form" %>
|
|
2
|
-
|
|
3
1
|
<div class="card">
|
|
4
2
|
<div class="card-divider">
|
|
5
3
|
<h2 class="card-title"><%= t(".title") %></h2>
|
|
@@ -50,6 +48,11 @@
|
|
|
50
48
|
<div class="row column">
|
|
51
49
|
<%= form.translated :editor, :internal_organisation %>
|
|
52
50
|
</div>
|
|
51
|
+
|
|
52
|
+
<div class="row column">
|
|
53
|
+
<%= form.translated :editor, :announcement %>
|
|
54
|
+
<p class="help-text"><%== t(".announcement_help") %></p>
|
|
55
|
+
</div>
|
|
53
56
|
</div>
|
|
54
57
|
|
|
55
58
|
<div class="card-divider">
|
|
@@ -236,4 +239,4 @@
|
|
|
236
239
|
</div>
|
|
237
240
|
</div>
|
|
238
241
|
|
|
239
|
-
<%=
|
|
242
|
+
<%= javascript_pack_tag "decidim_assemblies_admin" %>
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
</div>
|
|
17
17
|
|
|
18
18
|
<div class="row column user-fields--user-picker">
|
|
19
|
-
<% prompt_options = { url: decidim_admin.
|
|
19
|
+
<% prompt_options = { url: decidim_admin.user_entities_organization_url, placeholder: t(".select_user") } %>
|
|
20
20
|
<%= form.autocomplete_select(:user_id, form.object.user.presence, { multiple: false }, prompt_options) do |user|
|
|
21
21
|
{ value: user.id, label: "#{user.name} (@#{user.nickname})" }
|
|
22
22
|
end %>
|
|
@@ -63,4 +63,4 @@
|
|
|
63
63
|
</div>
|
|
64
64
|
</div>
|
|
65
65
|
|
|
66
|
-
<%=
|
|
66
|
+
<%= javascript_pack_tag "decidim_assemblies_admin" %>
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
</div>
|
|
14
14
|
<div class="columns mediumlarge-8 large-6 card--process__column">
|
|
15
15
|
<div class="card--full__image"
|
|
16
|
-
style="background-image:url(<%= promoted_assembly.hero_image.
|
|
16
|
+
style="background-image:url(<%= promoted_assembly.attached_uploader(:hero_image).path %>)">
|
|
17
17
|
<div class="card__content row collapse">
|
|
18
18
|
<div class="large-6 large-offset-6 columns">
|
|
19
19
|
<%= link_to assembly_path(promoted_assembly), class: "button expanded button--sc" do %>
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<% add_decidim_meta_tags({
|
|
2
|
-
image_url: current_participatory_space.hero_image.
|
|
2
|
+
image_url: current_participatory_space.attached_uploader(:hero_image).path,
|
|
3
3
|
description: translated_attribute(current_participatory_space.short_description),
|
|
4
4
|
url: assembly_url(current_participatory_space),
|
|
5
5
|
twitter_handler: current_organization.twitter_handler
|
|
@@ -21,6 +21,8 @@ edit_link(
|
|
|
21
21
|
locals: { text: t("private_space", scope: "decidim.assemblies.show") } %>
|
|
22
22
|
<% end %>
|
|
23
23
|
|
|
24
|
+
<%= cell("decidim/announcement", current_participatory_space.announcement) %>
|
|
25
|
+
|
|
24
26
|
<div class="row column">
|
|
25
27
|
<% if current_participatory_space.parent.present? %>
|
|
26
28
|
<div class="row">
|
|
@@ -87,7 +89,7 @@ edit_link(
|
|
|
87
89
|
<section id="assemblies-grid" class="section row collapse">
|
|
88
90
|
<h3 class="section-heading"><%= t("children", scope: "decidim.assemblies.show") %></h3>
|
|
89
91
|
<div class="row small-up-1 medium-up-2 large-up-2 card-grid">
|
|
90
|
-
<%= render partial: "decidim/assemblies/assembly", collection: current_participatory_space.children.visible_for(current_user).published %>
|
|
92
|
+
<%= render partial: "decidim/assemblies/assembly", collection: current_participatory_space.children.visible_for(current_user).published.order(weight: :asc) %>
|
|
91
93
|
</div>
|
|
92
94
|
</section>
|
|
93
95
|
<% end %>
|
|
@@ -214,8 +216,8 @@ edit_link(
|
|
|
214
216
|
</div>
|
|
215
217
|
|
|
216
218
|
<% if current_participatory_space.show_statistics? %>
|
|
217
|
-
<%= cell "decidim/
|
|
219
|
+
<%= cell "decidim/statistics", stats.collection %>
|
|
218
220
|
<% end %>
|
|
219
221
|
</div>
|
|
220
222
|
|
|
221
|
-
<%=
|
|
223
|
+
<%= javascript_pack_tag "decidim_assemblies" %>
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<div class="process-header">
|
|
2
2
|
<div class="process-header__inner">
|
|
3
3
|
<div class="row column process-header__main"
|
|
4
|
-
style="background-image:url(<%= current_participatory_space.banner_image.
|
|
4
|
+
style="background-image:url(<%= current_participatory_space.attached_uploader(:banner_image).path %>);">
|
|
5
5
|
</div>
|
|
6
6
|
<div class="process-header__container row collapse column">
|
|
7
7
|
<div class="columns mediumlarge-8 process-header__info">
|
|
@@ -1,76 +1,7 @@
|
|
|
1
|
-
<% content_for :
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
<% if allowed_to? :update, :assembly, assembly: current_participatory_space %>
|
|
6
|
-
<li <% if is_active_link?(decidim_admin_assemblies.edit_assembly_path(current_participatory_space)) %> class="is-active" <% end %>>
|
|
7
|
-
<%= aria_selected_link_to t("info", scope: "decidim.admin.menu.assemblies_submenu"), decidim_admin_assemblies.edit_assembly_path(current_participatory_space) %>
|
|
8
|
-
</li>
|
|
9
|
-
<% end %>
|
|
10
|
-
<% if allowed_to? :read, :component, assembly: current_participatory_space %>
|
|
11
|
-
<li <% if is_active_link?(decidim_admin_assemblies.components_path(current_participatory_space)) %> class="is-active" <% end %>>
|
|
12
|
-
<%= aria_selected_link_to t("components", scope: "decidim.admin.menu.assemblies_submenu"), decidim_admin_assemblies.components_path(current_participatory_space) %>
|
|
13
|
-
<ul id="components-list">
|
|
14
|
-
<% current_participatory_space.components.each do |component| %>
|
|
15
|
-
<% if component.manifest.admin_engine && user_role_config.component_is_accessible?(component.manifest_name) %>
|
|
16
|
-
<li <% if is_active_link?(manage_component_path(component)) || is_active_link?(decidim_admin_assemblies.edit_component_path(current_participatory_space, component)) || is_active_link?(decidim_admin_assemblies.edit_component_permissions_path(current_participatory_space, component)) || participatory_space_active_link?(component) %> class="is-active" <% end %>>
|
|
17
|
-
<%= link_to manage_component_path(component) do %>
|
|
18
|
-
<%= translated_attribute component.name %>
|
|
19
|
-
<% if component.primary_stat.present? %>
|
|
20
|
-
<span class="component-counter <%= "component-counter--off" if component.primary_stat.zero? %>"><%= component.primary_stat %></span>
|
|
21
|
-
<% end %>
|
|
22
|
-
<% end %>
|
|
23
|
-
</li>
|
|
24
|
-
<% end %>
|
|
25
|
-
<% end %>
|
|
26
|
-
</ul>
|
|
27
|
-
</li>
|
|
28
|
-
<% end %>
|
|
29
|
-
<% if allowed_to? :read, :category, assembly: current_participatory_space %>
|
|
30
|
-
<li <% if is_active_link?(decidim_admin_assemblies.categories_path(current_participatory_space)) %> class="is-active" <% end %>>
|
|
31
|
-
<%= aria_selected_link_to t("categories", scope: "decidim.admin.menu.assemblies_submenu"), decidim_admin_assemblies.categories_path(current_participatory_space) %>
|
|
32
|
-
</li>
|
|
33
|
-
<% end %>
|
|
34
|
-
<% if allowed_to?(:read, :attachment_collection, assembly: current_participatory_space) || allowed_to?(:read, :attachment, assembly: current_participatory_space) %>
|
|
35
|
-
<li>
|
|
36
|
-
<span class="secondary-nav__subtitle"><%= t("attachments", scope: "decidim.admin.menu.assemblies_submenu") %></span>
|
|
37
|
-
<ul>
|
|
38
|
-
<% if allowed_to? :read, :attachment_collection, assembly: current_participatory_space %>
|
|
39
|
-
<li <% if is_active_link?(decidim_admin_assemblies.assembly_attachment_collections_path(current_participatory_space)) %> class="is-active" <% end %>>
|
|
40
|
-
<%= aria_selected_link_to t("attachment_collections", scope: "decidim.admin.menu.assemblies_submenu"), decidim_admin_assemblies.assembly_attachment_collections_path(current_participatory_space) %>
|
|
41
|
-
</li>
|
|
42
|
-
<% end %>
|
|
43
|
-
<% if allowed_to? :read, :attachment, assembly: current_participatory_space %>
|
|
44
|
-
<li <% if is_active_link?(decidim_admin_assemblies.assembly_attachments_path(current_participatory_space)) %> class="is-active" <% end %>>
|
|
45
|
-
<%= aria_selected_link_to t("attachment_files", scope: "decidim.admin.menu.assemblies_submenu"), decidim_admin_assemblies.assembly_attachments_path(current_participatory_space) %>
|
|
46
|
-
</li>
|
|
47
|
-
<% end %>
|
|
48
|
-
</ul>
|
|
49
|
-
</li>
|
|
50
|
-
<% end %>
|
|
51
|
-
<% if allowed_to? :read, :assembly_member, assembly: current_participatory_space %>
|
|
52
|
-
<li <% if is_active_link?(decidim_admin_assemblies.assembly_members_path(current_participatory_space)) %> class="is-active" <% end %>>
|
|
53
|
-
<%= aria_selected_link_to t("assembly_members", scope: "decidim.admin.menu.assemblies_submenu"), decidim_admin_assemblies.assembly_members_path(current_participatory_space) %>
|
|
54
|
-
</li>
|
|
55
|
-
<% end %>
|
|
56
|
-
<% if allowed_to? :read, :assembly_user_role, assembly: current_participatory_space %>
|
|
57
|
-
<li <% if is_active_link?(decidim_admin_assemblies.assembly_user_roles_path(current_participatory_space)) %> class="is-active" <% end %>>
|
|
58
|
-
<%= aria_selected_link_to t("assembly_admins", scope: "decidim.admin.menu.assemblies_submenu"), decidim_admin_assemblies.assembly_user_roles_path(current_participatory_space) %>
|
|
59
|
-
</li>
|
|
60
|
-
<% end %>
|
|
61
|
-
<% if allowed_to? :read, :space_private_user, assembly: current_participatory_space %>
|
|
62
|
-
<li <% if is_active_link?(decidim_admin_assemblies.participatory_space_private_users_path(current_participatory_space)) %> class="is-active" <% end %>>
|
|
63
|
-
<%= aria_selected_link_to t("private_users", scope: "decidim.admin.menu.assemblies_submenu"), decidim_admin_assemblies.participatory_space_private_users_path(current_participatory_space) %>
|
|
64
|
-
</li>
|
|
65
|
-
<% end %>
|
|
66
|
-
<% if allowed_to? :read, :moderation, assembly: current_participatory_space %>
|
|
67
|
-
<li <% if is_active_link?(decidim_admin_assemblies.moderations_path(current_participatory_space)) %> class="is-active" <% end %>>
|
|
68
|
-
<%= aria_selected_link_to t("moderations", scope: "decidim.admin.menu.assemblies_submenu"), decidim_admin_assemblies.moderations_path(current_participatory_space) %>
|
|
69
|
-
</li>
|
|
70
|
-
<% end %>
|
|
71
|
-
<%= Decidim::Admin.view_hooks.render(:admin_secondary_nav, deep_dup) %>
|
|
72
|
-
</ul>
|
|
73
|
-
</div>
|
|
1
|
+
<% content_for :sidebar_menu_nav do %>
|
|
2
|
+
<%= sidebar_menu(:admin_assembly_menu).render do
|
|
3
|
+
public_page_link decidim_assemblies.assembly_path(current_participatory_space)
|
|
4
|
+
end %>
|
|
74
5
|
<% end %>
|
|
75
6
|
|
|
76
7
|
<%= render "layouts/decidim/admin/application" do %>
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<% add_decidim_page_title(translated_attribute(current_component.name)) if try(:current_component) %>
|
|
2
2
|
<% add_decidim_page_title(translated_attribute(current_participatory_space.title)) %>
|
|
3
3
|
<% add_decidim_meta_tags(
|
|
4
|
-
image_url: current_participatory_space.banner_image.
|
|
4
|
+
image_url: current_participatory_space.attached_uploader(:banner_image).path,
|
|
5
5
|
description: translated_attribute(current_participatory_space.short_description),
|
|
6
6
|
) %>
|
|
7
7
|
|
|
@@ -22,4 +22,4 @@
|
|
|
22
22
|
<% end %>
|
|
23
23
|
<% end %>
|
|
24
24
|
|
|
25
|
-
<% provide :meta_image_url, current_participatory_space.banner_image.
|
|
25
|
+
<% provide :meta_image_url, current_participatory_space.attached_uploader(:banner_image).path %>
|
data/config/assets.rb
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
base_path = File.expand_path("..", __dir__)
|
|
4
|
+
|
|
5
|
+
Decidim::Webpacker.register_path("#{base_path}/app/packs")
|
|
6
|
+
Decidim::Webpacker.register_entrypoints(
|
|
7
|
+
decidim_assemblies: "#{base_path}/app/packs/entrypoints/decidim_assemblies.js",
|
|
8
|
+
decidim_assemblies_admin: "#{base_path}/app/packs/entrypoints/decidim_assemblies_admin.js"
|
|
9
|
+
)
|
data/config/locales/ar.yml
CHANGED
|
@@ -347,23 +347,6 @@ ar:
|
|
|
347
347
|
scope: نطاق
|
|
348
348
|
social_networks: شبكات التواصل الاجتماعي
|
|
349
349
|
target: من يشارك
|
|
350
|
-
statistics:
|
|
351
|
-
answers_count: أجوبة
|
|
352
|
-
assemblies_count: الجمعيات
|
|
353
|
-
comments_count: تعليقات
|
|
354
|
-
debates_count: مناقشات
|
|
355
|
-
endorsements_count: موافقات
|
|
356
|
-
meetings_count: اجتماعات
|
|
357
|
-
orders_count: تأييدات
|
|
358
|
-
pages_count: صفحات
|
|
359
|
-
participants_count: مشارك
|
|
360
|
-
projects_count: مشاريع
|
|
361
|
-
proposals_count: اقتراحات
|
|
362
|
-
results_count: نتائج
|
|
363
|
-
supports_count: تأييدات
|
|
364
|
-
surveys_count: دراسات استقصائية
|
|
365
|
-
users_count: مشارك
|
|
366
|
-
votes_count: الدعم
|
|
367
350
|
assembly_members:
|
|
368
351
|
assembly_member:
|
|
369
352
|
designated_on: المعينة على
|
data/config/locales/ca.yml
CHANGED
|
@@ -52,7 +52,7 @@ ca:
|
|
|
52
52
|
target: Qui participa
|
|
53
53
|
title: Títol
|
|
54
54
|
twitter: Twitter
|
|
55
|
-
weight:
|
|
55
|
+
weight: Ordre de posició
|
|
56
56
|
youtube: YouTube
|
|
57
57
|
assembly_member:
|
|
58
58
|
birthday: Aniversari
|
|
@@ -262,6 +262,7 @@ ca:
|
|
|
262
262
|
admin:
|
|
263
263
|
assemblies:
|
|
264
264
|
form:
|
|
265
|
+
announcement_help: El text que introdueixis aquí es mostrarà a la participant just a sota de la informació de l'assemblea.
|
|
265
266
|
duration: Durada
|
|
266
267
|
duration_help: Si la durada d'aquesta assemblea és limitada, selecciona la data de finalització. En cas contrari, apareixerà com a indefinida.
|
|
267
268
|
filters: Filtres
|
|
@@ -381,38 +382,11 @@ ca:
|
|
|
381
382
|
social_networks: Xarxes socials
|
|
382
383
|
social_networks_title: Compartir aquesta assemblea a
|
|
383
384
|
target: Qui participa
|
|
384
|
-
statistics:
|
|
385
|
-
answers_count: Respostes
|
|
386
|
-
assemblies_count: Assemblees
|
|
387
|
-
comments_count: Comentaris
|
|
388
|
-
debates_count: Debats
|
|
389
|
-
endorsements_count: Adhesions
|
|
390
|
-
followers_count: Seguidors
|
|
391
|
-
headline: Estadístiques
|
|
392
|
-
meetings_count: Trobades
|
|
393
|
-
no_stats: Encara no hi ha estadístiques.
|
|
394
|
-
orders_count: Suports
|
|
395
|
-
pages_count: Pàgines
|
|
396
|
-
participants_count: Participants
|
|
397
|
-
posts_count: Publicacions
|
|
398
|
-
processes_count: Processos
|
|
399
|
-
projects_count: Projectes
|
|
400
|
-
proposals_count: Propostes
|
|
401
|
-
results_count: Resultats
|
|
402
|
-
supports_count: Suports
|
|
403
|
-
surveys_count: Enquestes
|
|
404
|
-
users_count: Participants
|
|
405
|
-
votes_count: Suports
|
|
406
385
|
assembly_members:
|
|
407
386
|
assembly_member:
|
|
408
387
|
designated_on: Designat a
|
|
409
388
|
index:
|
|
410
389
|
title: Membres
|
|
411
|
-
conferences:
|
|
412
|
-
pages:
|
|
413
|
-
home:
|
|
414
|
-
highlighted_conferences:
|
|
415
|
-
conferences_button_title: Enllaç a la pàgina de Jornades mostrant totes les jornades
|
|
416
390
|
events:
|
|
417
391
|
assemblies:
|
|
418
392
|
create_assembly_member:
|
|
@@ -445,19 +419,11 @@ ca:
|
|
|
445
419
|
description: Nombre d'assemblees creades
|
|
446
420
|
object: assemblees
|
|
447
421
|
title: Assemblees
|
|
448
|
-
pages:
|
|
449
|
-
home:
|
|
450
|
-
hero:
|
|
451
|
-
participate_title: Participa als processos de la plataforma
|
|
452
|
-
sub_hero:
|
|
453
|
-
register_title: Registra't
|
|
454
422
|
participatory_processes:
|
|
455
|
-
pages:
|
|
456
|
-
home:
|
|
457
|
-
highlighted_processes:
|
|
458
|
-
processes_button_title: Enllaç a la pàgina de Processos mostrant tots els processos
|
|
459
423
|
show:
|
|
460
424
|
related_assemblies: Assemblees relacionades
|
|
425
|
+
statistics:
|
|
426
|
+
assemblies_count: Assemblees
|
|
461
427
|
errors:
|
|
462
428
|
messages:
|
|
463
429
|
cannot_be_blank: no es pot estar en blanc
|