decidim-assemblies 0.23.6 → 0.24.0.rc1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (76) hide show
  1. checksums.yaml +4 -4
  2. data/app/cells/decidim/assemblies/assembly_m_cell.rb +2 -0
  3. data/app/cells/decidim/assemblies/statistic/show.erb +9 -0
  4. data/app/cells/decidim/assemblies/statistic_cell.rb +20 -0
  5. data/app/cells/decidim/assemblies/statistics/show.erb +17 -0
  6. data/app/cells/decidim/assemblies/statistics_cell.rb +18 -0
  7. data/app/commands/decidim/assemblies/admin/create_assembly.rb +1 -0
  8. data/app/commands/decidim/assemblies/admin/update_assembly.rb +2 -1
  9. data/app/controllers/decidim/assemblies/admin/imports_controller.rb +14 -0
  10. data/app/controllers/decidim/assemblies/admin/moderations/reports_controller.rb +14 -0
  11. data/app/controllers/decidim/assemblies/assemblies_controller.rb +1 -1
  12. data/app/forms/decidim/assemblies/admin/assembly_form.rb +1 -0
  13. data/app/helpers/decidim/assemblies/admin/assemblies_admin_menu_helper.rb +15 -0
  14. data/app/models/decidim/assembly.rb +3 -3
  15. data/app/presenters/decidim/assemblies/assembly_stats_presenter.rb +35 -25
  16. data/app/queries/decidim/assemblies/organization_assemblies.rb +1 -1
  17. data/app/queries/decidim/assemblies/organization_published_assemblies.rb +1 -1
  18. data/app/serializers/decidim/assemblies/assembly_serializer.rb +1 -0
  19. data/app/views/decidim/assemblies/admin/assemblies/_form.html.erb +4 -0
  20. data/app/views/decidim/assemblies/admin/assemblies/index.html.erb +11 -1
  21. data/app/views/decidim/assemblies/admin/assemblies_types/index.html.erb +1 -1
  22. data/app/views/decidim/assemblies/assemblies/show.html.erb +1 -1
  23. data/app/views/layouts/decidim/admin/assemblies.html.erb +2 -20
  24. data/app/views/layouts/decidim/admin/assembly.html.erb +2 -1
  25. data/config/locales/ar.yml +0 -1
  26. data/config/locales/ca.yml +1 -4
  27. data/config/locales/cs.yml +11 -5
  28. data/config/locales/de.yml +9 -3
  29. data/config/locales/el.yml +0 -4
  30. data/config/locales/en.yml +9 -3
  31. data/config/locales/es-MX.yml +0 -4
  32. data/config/locales/es-PY.yml +0 -4
  33. data/config/locales/es.yml +0 -4
  34. data/config/locales/eu.yml +0 -1
  35. data/config/locales/fi-plain.yml +9 -3
  36. data/config/locales/fi.yml +9 -3
  37. data/config/locales/fr-CA.yml +9 -3
  38. data/config/locales/fr.yml +9 -3
  39. data/config/locales/gl.yml +0 -57
  40. data/config/locales/hu.yml +0 -4
  41. data/config/locales/id-ID.yml +0 -1
  42. data/config/locales/is-IS.yml +0 -1
  43. data/config/locales/it.yml +0 -4
  44. data/config/locales/ja.yml +0 -4
  45. data/config/locales/lv.yml +0 -4
  46. data/config/locales/nl.yml +9 -3
  47. data/config/locales/no.yml +0 -4
  48. data/config/locales/pl.yml +16 -10
  49. data/config/locales/pt-BR.yml +0 -1
  50. data/config/locales/pt.yml +0 -4
  51. data/config/locales/ro-RO.yml +101 -135
  52. data/config/locales/ru.yml +1 -2
  53. data/config/locales/sk.yml +0 -3
  54. data/config/locales/sl.yml +0 -1
  55. data/config/locales/sr-CS.yml +0 -3
  56. data/config/locales/sv.yml +1 -7
  57. data/config/locales/tr-TR.yml +0 -4
  58. data/config/locales/uk.yml +1 -2
  59. data/config/locales/zh-CN.yml +0 -4
  60. data/db/migrate/20210204152393_add_weight_field_to_assembly.rb +7 -0
  61. data/lib/decidim/api/assemblies_type_type.rb +16 -0
  62. data/lib/decidim/api/assembly_member_type.rb +28 -0
  63. data/lib/decidim/api/assembly_type.rb +64 -0
  64. data/lib/decidim/assemblies/admin_engine.rb +31 -1
  65. data/lib/decidim/assemblies/api.rb +9 -0
  66. data/lib/decidim/assemblies/engine.rb +3 -5
  67. data/lib/decidim/assemblies/participatory_space.rb +38 -38
  68. data/lib/decidim/assemblies/query_extensions.rb +39 -20
  69. data/lib/decidim/assemblies/test/factories.rb +5 -4
  70. data/lib/decidim/assemblies/version.rb +1 -1
  71. data/lib/decidim/assemblies.rb +1 -0
  72. metadata +24 -16
  73. data/app/types/decidim/assemblies/assemblies_type_type.rb +0 -17
  74. data/app/types/decidim/assemblies/assembly_member_type.rb +0 -29
  75. data/app/types/decidim/assemblies/assembly_type.rb +0 -67
  76. data/app/views/decidim/assemblies/assemblies/_statistics.html.erb +0 -10
@@ -4,7 +4,7 @@ module Decidim
4
4
  # This holds the decidim-assemblies version.
5
5
  module Assemblies
6
6
  def self.version
7
- "0.23.6"
7
+ "0.24.0.rc1"
8
8
  end
9
9
  end
10
10
  end
@@ -1,6 +1,7 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  require "decidim/assemblies/admin"
4
+ require "decidim/assemblies/api"
4
5
  require "decidim/assemblies/engine"
5
6
  require "decidim/assemblies/admin_engine"
6
7
  require "decidim/assemblies/participatory_space"
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: decidim-assemblies
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.23.6
4
+ version: 0.24.0.rc1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Josep Jaume Rey Peroy
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2021-05-10 00:00:00.000000000 Z
13
+ date: 2021-03-01 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: decidim-core
@@ -18,42 +18,42 @@ dependencies:
18
18
  requirements:
19
19
  - - '='
20
20
  - !ruby/object:Gem::Version
21
- version: 0.23.6
21
+ version: 0.24.0.rc1
22
22
  type: :runtime
23
23
  prerelease: false
24
24
  version_requirements: !ruby/object:Gem::Requirement
25
25
  requirements:
26
26
  - - '='
27
27
  - !ruby/object:Gem::Version
28
- version: 0.23.6
28
+ version: 0.24.0.rc1
29
29
  - !ruby/object:Gem::Dependency
30
30
  name: decidim-admin
31
31
  requirement: !ruby/object:Gem::Requirement
32
32
  requirements:
33
33
  - - '='
34
34
  - !ruby/object:Gem::Version
35
- version: 0.23.6
35
+ version: 0.24.0.rc1
36
36
  type: :development
37
37
  prerelease: false
38
38
  version_requirements: !ruby/object:Gem::Requirement
39
39
  requirements:
40
40
  - - '='
41
41
  - !ruby/object:Gem::Version
42
- version: 0.23.6
42
+ version: 0.24.0.rc1
43
43
  - !ruby/object:Gem::Dependency
44
44
  name: decidim-dev
45
45
  requirement: !ruby/object:Gem::Requirement
46
46
  requirements:
47
47
  - - '='
48
48
  - !ruby/object:Gem::Version
49
- version: 0.23.6
49
+ version: 0.24.0.rc1
50
50
  type: :development
51
51
  prerelease: false
52
52
  version_requirements: !ruby/object:Gem::Requirement
53
53
  requirements:
54
54
  - - '='
55
55
  - !ruby/object:Gem::Version
56
- version: 0.23.6
56
+ version: 0.24.0.rc1
57
57
  description: Assemblies component for decidim.
58
58
  email:
59
59
  - josepjaume@gmail.com
@@ -82,6 +82,10 @@ files:
82
82
  - app/cells/decidim/assemblies/content_blocks/highlighted_assemblies_cell.rb
83
83
  - app/cells/decidim/assemblies/content_blocks/highlighted_assemblies_settings_form/show.erb
84
84
  - app/cells/decidim/assemblies/content_blocks/highlighted_assemblies_settings_form_cell.rb
85
+ - app/cells/decidim/assemblies/statistic/show.erb
86
+ - app/cells/decidim/assemblies/statistic_cell.rb
87
+ - app/cells/decidim/assemblies/statistics/show.erb
88
+ - app/cells/decidim/assemblies/statistics_cell.rb
85
89
  - app/cells/decidim/assembly_activity_cell.rb
86
90
  - app/commands/decidim/assemblies/admin/copy_assembly.rb
87
91
  - app/commands/decidim/assemblies/admin/create_assemblies_type.rb
@@ -121,6 +125,8 @@ files:
121
125
  - app/controllers/decidim/assemblies/admin/components_controller.rb
122
126
  - app/controllers/decidim/assemblies/admin/concerns/assembly_admin.rb
123
127
  - app/controllers/decidim/assemblies/admin/exports_controller.rb
128
+ - app/controllers/decidim/assemblies/admin/imports_controller.rb
129
+ - app/controllers/decidim/assemblies/admin/moderations/reports_controller.rb
124
130
  - app/controllers/decidim/assemblies/admin/moderations_controller.rb
125
131
  - app/controllers/decidim/assemblies/admin/participatory_space_private_users_controller.rb
126
132
  - app/controllers/decidim/assemblies/admin/participatory_space_private_users_csv_imports_controller.rb
@@ -137,6 +143,7 @@ files:
137
143
  - app/forms/decidim/assemblies/admin/assembly_import_form.rb
138
144
  - app/forms/decidim/assemblies/admin/assembly_member_form.rb
139
145
  - app/forms/decidim/assemblies/admin/assembly_user_role_form.rb
146
+ - app/helpers/decidim/assemblies/admin/assemblies_admin_menu_helper.rb
140
147
  - app/helpers/decidim/assemblies/admin/assemblies_helper.rb
141
148
  - app/helpers/decidim/assemblies/assemblies_helper.rb
142
149
  - app/helpers/decidim/assemblies/filter_assemblies_helper.rb
@@ -177,9 +184,6 @@ files:
177
184
  - app/serializers/decidim/assemblies/assembly_importer.rb
178
185
  - app/serializers/decidim/assemblies/assembly_serializer.rb
179
186
  - app/services/decidim/assemblies/assembly_search.rb
180
- - app/types/decidim/assemblies/assemblies_type_type.rb
181
- - app/types/decidim/assemblies/assembly_member_type.rb
182
- - app/types/decidim/assemblies/assembly_type.rb
183
187
  - app/views/decidim/assemblies/_assembly.html.erb
184
188
  - app/views/decidim/assemblies/_filter_by_type.html.erb
185
189
  - app/views/decidim/assemblies/admin/assemblies/_form.html.erb
@@ -208,7 +212,6 @@ files:
208
212
  - app/views/decidim/assemblies/assemblies/_nav_breadcumb.html.erb
209
213
  - app/views/decidim/assemblies/assemblies/_parent_assemblies.html.erb
210
214
  - app/views/decidim/assemblies/assemblies/_promoted_assembly.html.erb
211
- - app/views/decidim/assemblies/assemblies/_statistics.html.erb
212
215
  - app/views/decidim/assemblies/assemblies/index.html.erb
213
216
  - app/views/decidim/assemblies/assemblies/index.js.erb
214
217
  - app/views/decidim/assemblies/assemblies/show.html.erb
@@ -306,13 +309,18 @@ files:
306
309
  - db/migrate/20200320105907_index_foreign_keys_in_decidim_assembly_user_roles.rb
307
310
  - db/migrate/20200416132109_remove_legacy_decidim_assembly_type.rb
308
311
  - db/migrate/20200430202456_create_decidim_assemblies_settings.rb
312
+ - db/migrate/20210204152393_add_weight_field_to_assembly.rb
309
313
  - db/seeds/Exampledocument.pdf
310
314
  - db/seeds/city.jpeg
311
315
  - db/seeds/city2.jpeg
312
316
  - db/seeds/homepage_image.jpg
317
+ - lib/decidim/api/assemblies_type_type.rb
318
+ - lib/decidim/api/assembly_member_type.rb
319
+ - lib/decidim/api/assembly_type.rb
313
320
  - lib/decidim/assemblies.rb
314
321
  - lib/decidim/assemblies/admin.rb
315
322
  - lib/decidim/assemblies/admin_engine.rb
323
+ - lib/decidim/assemblies/api.rb
316
324
  - lib/decidim/assemblies/engine.rb
317
325
  - lib/decidim/assemblies/participatory_space.rb
318
326
  - lib/decidim/assemblies/query_extensions.rb
@@ -330,14 +338,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
330
338
  requirements:
331
339
  - - ">="
332
340
  - !ruby/object:Gem::Version
333
- version: '2.6'
341
+ version: '2.7'
334
342
  required_rubygems_version: !ruby/object:Gem::Requirement
335
343
  requirements:
336
- - - ">="
344
+ - - ">"
337
345
  - !ruby/object:Gem::Version
338
- version: '0'
346
+ version: 1.3.1
339
347
  requirements: []
340
- rubygems_version: 3.0.3
348
+ rubygems_version: 3.1.2
341
349
  signing_key:
342
350
  specification_version: 4
343
351
  summary: Decidim assemblies module
@@ -1,17 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module Decidim
4
- module Assemblies
5
- # This type represents an AssembliesType.
6
- AssembliesTypeType = GraphQL::ObjectType.define do
7
- name "AssembliesType"
8
- description "An assemblies type"
9
-
10
- field :id, !types.ID, "The assemblies type's unique ID"
11
- field :title, !Decidim::Core::TranslatedFieldType, "The title of this assemblies type."
12
- field :createdAt, !Decidim::Core::DateTimeType, "The time this assemblies type was created", property: :created_at
13
- field :updatedAt, !Decidim::Core::DateTimeType, "The time this assemblies type was updated", property: :updated_at
14
- field :assemblies, !types[Decidim::Assemblies::AssemblyType], "Assemblies with this assemblies type"
15
- end
16
- end
17
- end
@@ -1,29 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module Decidim
4
- module Assemblies
5
- # This type represents a assembly.
6
- AssemblyMemberType = GraphQL::ObjectType.define do
7
- name "AssemblyMember"
8
- description "An assembly member"
9
-
10
- field :id, !types.ID, "Internal ID of the member"
11
- field :fullName, types.String, "Full name of the member", property: :full_name
12
- field :position, types.String, "Position of the member in the assembly"
13
-
14
- field :user, Decidim::Core::UserType, "The corresponding decidim user", property: :user
15
-
16
- field :createdAt, Decidim::Core::DateTimeType, "The time this member was created", property: :created_at
17
- field :updatedAt, Decidim::Core::DateTimeType, "The time this member was updated", property: :updated_at
18
-
19
- field :weight, types.Int, "Order of appearance in which it should be represented"
20
- field :gender, types.String, "Gender of the member"
21
- # field :birthday, Decidim::Core::DateType, "Birthday date of the member" # non-public currently
22
- field :birthplace, types.String, "Birthplace of the member"
23
- field :designationDate, Decidim::Core::DateType, "Date of designation of the member", property: :designation_date
24
- # field :designationMode, types.String, "Mode in which the member was designated", property: :designation_mode # non-public currently
25
- field :positionOther, types.String, "Custom position name", property: :position_other
26
- field :ceasedDate, Decidim::Core::DateType, "Date of cease for the member", property: :ceased_date
27
- end
28
- end
29
- end
@@ -1,67 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- module Decidim
4
- module Assemblies
5
- # This type represents a assembly.
6
- AssemblyType = GraphQL::ObjectType.define do
7
- interfaces [
8
- -> { Decidim::Core::ParticipatorySpaceInterface },
9
- -> { Decidim::Core::AttachableInterface },
10
- -> { Decidim::Core::ParticipatorySpaceResourceableInterface }
11
- ]
12
-
13
- name "Assembly"
14
- description "An assembly"
15
-
16
- field :id, !types.ID, "The internal ID for this assembly"
17
- field :subtitle, Decidim::Core::TranslatedFieldType, "The subtitle of this assembly"
18
- field :shortDescription, Decidim::Core::TranslatedFieldType, "The sort description of this assembly", property: :short_description
19
- field :description, Decidim::Core::TranslatedFieldType, "The description of this assembly"
20
- field :slug, !types.String, "The slug of this assembly"
21
- field :hashtag, types.String, "The hashtag for this assembly"
22
- field :createdAt, !Decidim::Core::DateTimeType, "The time this assembly was created", property: :created_at
23
- field :updatedAt, !Decidim::Core::DateTimeType, "The time this assembly was updated", property: :updated_at
24
- field :publishedAt, !Decidim::Core::DateTimeType, "The time this assembly was published", property: :published_at
25
- field :reference, !types.String, "Reference for this assembly"
26
- field :categories, !types[Decidim::Core::CategoryType], "Categories for this assembly"
27
-
28
- field :heroImage, types.String, "The hero image for this assembly", property: :hero_image
29
- field :bannerImage, types.String, "The banner image for this assembly", property: :banner_image
30
- field :promoted, types.Boolean, "If this assembly is promoted (therefore in the homepage)"
31
- field :developerGroup, Decidim::Core::TranslatedFieldType, "The promoter group of this assembly", property: :developer_group
32
- field :metaScope, Decidim::Core::TranslatedFieldType, "The scope metadata of this assembly", property: :meta_scope
33
- field :localArea, Decidim::Core::TranslatedFieldType, "The organization area of this assembly", property: :local_area
34
- field :target, Decidim::Core::TranslatedFieldType, "Who participates in this assembly"
35
- field :participatoryScope, Decidim::Core::TranslatedFieldType, "What is decided on this assembly", property: :participatory_scope
36
- field :participatoryStructure, Decidim::Core::TranslatedFieldType, "How it is decided on this assembly", property: :participatory_structure
37
- field :showStatistics, types.Boolean, "If this assembly should show statistics", property: :show_statistics
38
- field :scopesEnabled, types.Boolean, "If this assembly has scopes enabled", property: :scopes_enabled
39
- field :privateSpace, types.Boolean, "If this assembly is a private space", property: :private_space
40
- field :area, Decidim::Core::AreaApiType, "Area of this assembly"
41
- field :parent, Decidim::Assemblies::AssemblyType, "The parent assembly of this assembly"
42
- field :parentsPath, types.String, "Assembly hierarchy representation", property: :parents_path
43
- field :childrenCount, types.Int, "Number of children assemblies", property: :children_count
44
- field :purposeOfAction, Decidim::Core::TranslatedFieldType, "Purpose of action", property: :purpose_of_action
45
- field :composition, Decidim::Core::TranslatedFieldType, "Composition of this assembly"
46
- field :assemblyType, Decidim::Assemblies::AssembliesTypeType, "Type of the assembly", property: :assembly_type
47
- field :creationDate, Decidim::Core::DateType, "Creation date of this assembly", property: :creation_date
48
- field :createdBy, types.String, "The creator of this assembly", property: :created_by
49
- field :createdByOther, Decidim::Core::TranslatedFieldType, "Custom creator", property: :created_by_other
50
- field :duration, Decidim::Core::DateType, "Duration of this assembly"
51
- field :includedAt, Decidim::Core::DateType, "Included at", property: :included_at
52
- field :closingDate, Decidim::Core::DateType, "Closing date of the assembly", property: :closing_date
53
- field :closingDateReason, Decidim::Core::TranslatedFieldType, "Closing date reason of this assembly", property: :closing_date_reason
54
- field :internalOrganisation, Decidim::Core::TranslatedFieldType, "Internal organisation of this assembly", property: :internal_organisation
55
- field :isTransparent, types.Boolean, "If this assembly is transparent", property: :is_transparent
56
- field :specialFeatures, Decidim::Core::TranslatedFieldType, "Special features of this assembly", property: :special_features
57
- field :twitterHandler, types.String, "Twitter handler", property: :twitter_handler
58
- field :instagramHandler, types.String, "Instagram handler", property: :instagram_handler
59
- field :facebookHandler, types.String, "Facebook handler", property: :facebook_handler
60
- field :youtubeHandler, types.String, "Youtube handler", property: :youtube_handler
61
- field :githubHandler, types.String, "Github handler", property: :github_handler
62
-
63
- field :members, !types[Decidim::Assemblies::AssemblyMemberType], "Members of this assembly"
64
- field :children, !types[Decidim::Assemblies::AssemblyType], "Childrens of this assembly"
65
- end
66
- end
67
- end
@@ -1,10 +0,0 @@
1
- <section class="extended" id="assembly-statistics" class="statistics">
2
- <div class="row column">
3
- <h4 class="section-heading"><%= t("statistics.headline", scope: "decidim.assemblies") %></h4>
4
- </div>
5
- <div class="row">
6
- <div class="columns small-centered mediumlarge-12 large-12 process_stats">
7
- <%= stats.highlighted %>
8
- </div>
9
- </div>
10
- </section>