decidim-budgets 0.27.5 → 0.27.7
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/budgets/base_cell.rb +1 -1
- data/app/cells/decidim/budgets/budget_list_item/show.erb +1 -1
- data/app/cells/decidim/budgets/budgets_list/voted.erb +1 -1
- data/app/cells/decidim/budgets/project_list_item_cell.rb +1 -1
- data/app/controllers/decidim/budgets/admin/projects_controller.rb +3 -2
- data/app/controllers/decidim/budgets/line_items_controller.rb +15 -9
- data/app/packs/src/decidim/budgets/exit_handler.js +1 -1
- data/app/views/decidim/budgets/admin/budgets/index.html.erb +6 -2
- data/app/views/decidim/budgets/admin/projects/_project-tr.html.erb +5 -3
- data/app/views/decidim/budgets/admin/projects/edit.html.erb +1 -1
- data/app/views/decidim/budgets/admin/projects/index.html.erb +4 -2
- data/app/views/decidim/budgets/admin/projects/new.html.erb +1 -1
- data/config/locales/ar.yml +4 -0
- data/config/locales/bg.yml +375 -0
- data/config/locales/ca.yml +4 -1
- data/config/locales/cs.yml +3 -0
- data/config/locales/de.yml +5 -2
- data/config/locales/en.yml +3 -0
- data/config/locales/es-MX.yml +3 -0
- data/config/locales/es-PY.yml +3 -0
- data/config/locales/es.yml +5 -2
- data/config/locales/eu.yml +3 -0
- data/config/locales/fi-plain.yml +3 -0
- data/config/locales/fi.yml +3 -0
- data/config/locales/fr-CA.yml +3 -0
- data/config/locales/fr.yml +3 -0
- data/config/locales/he-IL.yml +1 -0
- data/config/locales/hu.yml +13 -0
- data/config/locales/ja.yml +3 -0
- data/config/locales/ko.yml +54 -0
- data/config/locales/pl.yml +30 -0
- data/config/locales/pt-BR.yml +55 -0
- data/config/locales/sq-AL.yml +52 -0
- data/decidim-budgets.gemspec +34 -0
- data/lib/decidim/budgets/test/factories.rb +29 -14
- data/lib/decidim/budgets/version.rb +1 -1
- metadata +17 -16
- data/config/environment.rb +0 -3
@@ -8,9 +8,12 @@ require "decidim/participatory_processes/test/factories"
|
|
8
8
|
|
9
9
|
FactoryBot.define do
|
10
10
|
factory :budgets_component, parent: :component do
|
11
|
-
|
11
|
+
transient do
|
12
|
+
skip_injection { false }
|
13
|
+
end
|
14
|
+
name { generate_component_name(participatory_space.organization.available_locales, :budgets, skip_injection: skip_injection) }
|
12
15
|
manifest_name { :budgets }
|
13
|
-
participatory_space { create(:participatory_process, :with_steps, organization: organization) }
|
16
|
+
participatory_space { create(:participatory_process, :with_steps, skip_injection: skip_injection, organization: organization) }
|
14
17
|
|
15
18
|
trait :with_geocoding_enabled do
|
16
19
|
settings do
|
@@ -109,10 +112,13 @@ FactoryBot.define do
|
|
109
112
|
end
|
110
113
|
|
111
114
|
factory :budget, class: "Decidim::Budgets::Budget" do
|
112
|
-
|
113
|
-
|
115
|
+
transient do
|
116
|
+
skip_injection { false }
|
117
|
+
end
|
118
|
+
title { generate_localized_title(:budget_title, skip_injection: skip_injection) }
|
119
|
+
description { generate_localized_description(:budget_description, skip_injection: skip_injection) }
|
114
120
|
total_budget { 100_000_000 }
|
115
|
-
component { create(:budgets_component) }
|
121
|
+
component { create(:budgets_component, skip_injection: skip_injection) }
|
116
122
|
|
117
123
|
trait :with_projects do
|
118
124
|
transient do
|
@@ -120,19 +126,22 @@ FactoryBot.define do
|
|
120
126
|
end
|
121
127
|
|
122
128
|
after(:create) do |budget, evaluator|
|
123
|
-
create_list(:project, evaluator.projects_number, budget: budget)
|
129
|
+
create_list(:project, evaluator.projects_number, skip_injection: evaluator.skip_injection, budget: budget)
|
124
130
|
end
|
125
131
|
end
|
126
132
|
end
|
127
133
|
|
128
134
|
factory :project, class: "Decidim::Budgets::Project" do
|
129
|
-
|
130
|
-
|
135
|
+
transient do
|
136
|
+
skip_injection { false }
|
137
|
+
end
|
138
|
+
title { generate_localized_title(:project_title, skip_injection: skip_injection) }
|
139
|
+
description { generate_localized_description(:project_description, skip_injection: skip_injection) }
|
131
140
|
address { "#{Faker::Address.street_name}, #{Faker::Address.city}" }
|
132
141
|
latitude { Faker::Address.latitude }
|
133
142
|
longitude { Faker::Address.longitude }
|
134
143
|
budget_amount { Faker::Number.number(digits: 8) }
|
135
|
-
budget { create(:budget) }
|
144
|
+
budget { create(:budget, skip_injection: skip_injection) }
|
136
145
|
|
137
146
|
trait :selected do
|
138
147
|
selected_at { Time.current }
|
@@ -144,14 +153,17 @@ FactoryBot.define do
|
|
144
153
|
end
|
145
154
|
|
146
155
|
after :create do |project, evaluator|
|
147
|
-
project.attachments = create_list(:attachment, evaluator.photos_number, :with_image, attached_to: project)
|
156
|
+
project.attachments = create_list(:attachment, evaluator.photos_number, :with_image, attached_to: project, skip_injection: evaluator.skip_injection)
|
148
157
|
end
|
149
158
|
end
|
150
159
|
end
|
151
160
|
|
152
161
|
factory :order, class: "Decidim::Budgets::Order" do
|
153
|
-
|
154
|
-
|
162
|
+
transient do
|
163
|
+
skip_injection { false }
|
164
|
+
end
|
165
|
+
budget { create(:budget, skip_injection: skip_injection) }
|
166
|
+
user { create(:user, organization: component.organization, skip_injection: skip_injection) }
|
155
167
|
|
156
168
|
trait :with_projects do
|
157
169
|
transient do
|
@@ -160,14 +172,17 @@ FactoryBot.define do
|
|
160
172
|
|
161
173
|
after(:create) do |order, evaluator|
|
162
174
|
project_budget = (order.maximum_budget / evaluator.projects_number).to_i
|
163
|
-
order.projects << create_list(:project, evaluator.projects_number, budget_amount: project_budget, budget: order.budget)
|
175
|
+
order.projects << create_list(:project, evaluator.projects_number, budget_amount: project_budget, budget: order.budget, skip_injection: evaluator.skip_injection)
|
164
176
|
order.save!
|
165
177
|
end
|
166
178
|
end
|
167
179
|
end
|
168
180
|
|
169
181
|
factory :line_item, class: "Decidim::Budgets::LineItem" do
|
182
|
+
transient do
|
183
|
+
skip_injection { false }
|
184
|
+
end
|
170
185
|
order
|
171
|
-
project { create(:project, budget: order.budget) }
|
186
|
+
project { create(:project, budget: order.budget, skip_injection: skip_injection) }
|
172
187
|
end
|
173
188
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: decidim-budgets
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.27.
|
4
|
+
version: 0.27.7
|
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:
|
13
|
+
date: 2024-07-16 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: decidim-comments
|
@@ -18,70 +18,70 @@ dependencies:
|
|
18
18
|
requirements:
|
19
19
|
- - '='
|
20
20
|
- !ruby/object:Gem::Version
|
21
|
-
version: 0.27.
|
21
|
+
version: 0.27.7
|
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.27.
|
28
|
+
version: 0.27.7
|
29
29
|
- !ruby/object:Gem::Dependency
|
30
30
|
name: decidim-core
|
31
31
|
requirement: !ruby/object:Gem::Requirement
|
32
32
|
requirements:
|
33
33
|
- - '='
|
34
34
|
- !ruby/object:Gem::Version
|
35
|
-
version: 0.27.
|
35
|
+
version: 0.27.7
|
36
36
|
type: :runtime
|
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.27.
|
42
|
+
version: 0.27.7
|
43
43
|
- !ruby/object:Gem::Dependency
|
44
44
|
name: decidim-admin
|
45
45
|
requirement: !ruby/object:Gem::Requirement
|
46
46
|
requirements:
|
47
47
|
- - '='
|
48
48
|
- !ruby/object:Gem::Version
|
49
|
-
version: 0.27.
|
49
|
+
version: 0.27.7
|
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.27.
|
56
|
+
version: 0.27.7
|
57
57
|
- !ruby/object:Gem::Dependency
|
58
58
|
name: decidim-dev
|
59
59
|
requirement: !ruby/object:Gem::Requirement
|
60
60
|
requirements:
|
61
61
|
- - '='
|
62
62
|
- !ruby/object:Gem::Version
|
63
|
-
version: 0.27.
|
63
|
+
version: 0.27.7
|
64
64
|
type: :development
|
65
65
|
prerelease: false
|
66
66
|
version_requirements: !ruby/object:Gem::Requirement
|
67
67
|
requirements:
|
68
68
|
- - '='
|
69
69
|
- !ruby/object:Gem::Version
|
70
|
-
version: 0.27.
|
70
|
+
version: 0.27.7
|
71
71
|
- !ruby/object:Gem::Dependency
|
72
72
|
name: decidim-proposals
|
73
73
|
requirement: !ruby/object:Gem::Requirement
|
74
74
|
requirements:
|
75
75
|
- - '='
|
76
76
|
- !ruby/object:Gem::Version
|
77
|
-
version: 0.27.
|
77
|
+
version: 0.27.7
|
78
78
|
type: :development
|
79
79
|
prerelease: false
|
80
80
|
version_requirements: !ruby/object:Gem::Requirement
|
81
81
|
requirements:
|
82
82
|
- - '='
|
83
83
|
- !ruby/object:Gem::Version
|
84
|
-
version: 0.27.
|
84
|
+
version: 0.27.7
|
85
85
|
description: A budgets component for decidim's participatory spaces.
|
86
86
|
email:
|
87
87
|
- josepjaume@gmail.com
|
@@ -234,7 +234,6 @@ files:
|
|
234
234
|
- app/views/decidim/budgets/projects/show.html.erb
|
235
235
|
- app/views/decidim/budgets/vote_reminder_mailer/vote_reminder.html.erb
|
236
236
|
- config/assets.rb
|
237
|
-
- config/environment.rb
|
238
237
|
- config/locales/am-ET.yml
|
239
238
|
- config/locales/ar-SA.yml
|
240
239
|
- config/locales/ar.yml
|
@@ -267,6 +266,7 @@ files:
|
|
267
266
|
- config/locales/ga-IE.yml
|
268
267
|
- config/locales/gl.yml
|
269
268
|
- config/locales/gn-PY.yml
|
269
|
+
- config/locales/he-IL.yml
|
270
270
|
- config/locales/hr-HR.yml
|
271
271
|
- config/locales/hr.yml
|
272
272
|
- config/locales/hu.yml
|
@@ -334,6 +334,7 @@ files:
|
|
334
334
|
- db/migrate/20200827154129_add_commentable_counter_cache_to_projects.rb
|
335
335
|
- db/migrate/20210310120613_add_followable_counter_cache_to_budgets.rb
|
336
336
|
- db/migrate/20220428072638_add_geolocalization_fields_to_projects.rb
|
337
|
+
- decidim-budgets.gemspec
|
337
338
|
- lib/decidim/api/budget_type.rb
|
338
339
|
- lib/decidim/api/budgets_type.rb
|
339
340
|
- lib/decidim/api/project_type.rb
|
@@ -362,16 +363,16 @@ require_paths:
|
|
362
363
|
- lib
|
363
364
|
required_ruby_version: !ruby/object:Gem::Requirement
|
364
365
|
requirements:
|
365
|
-
- - "
|
366
|
+
- - "~>"
|
366
367
|
- !ruby/object:Gem::Version
|
367
|
-
version:
|
368
|
+
version: 3.0.0
|
368
369
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
369
370
|
requirements:
|
370
371
|
- - ">="
|
371
372
|
- !ruby/object:Gem::Version
|
372
373
|
version: '0'
|
373
374
|
requirements: []
|
374
|
-
rubygems_version: 3.
|
375
|
+
rubygems_version: 3.5.14
|
375
376
|
signing_key:
|
376
377
|
specification_version: 4
|
377
378
|
summary: Decidim budgets module
|
data/config/environment.rb
DELETED