Skip to content

Commit 08f87ee

Browse files
authored
Merge pull request #1267 from City-of-Helsinki/UHF-13019
UHF-13100: Updated district and project indexes to use the new Main image processor
2 parents 4725ada + 9eff050 commit 08f87ee

File tree

3 files changed

+62
-26
lines changed

3 files changed

+62
-26
lines changed

composer.lock

Lines changed: 12 additions & 12 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

conf/cmi/search_api.index.districts.yml

Lines changed: 25 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,9 @@ dependencies:
99
- field.storage.node.field_subdistricts
1010
- search_api.server.default
1111
module:
12+
- helfi_platform_config
1213
- helfi_react_search
14+
- helfi_recommendations
1315
- media
1416
- node
1517
id: districts
@@ -25,11 +27,6 @@ field_settings:
2527
dependencies:
2628
module:
2729
- node
28-
district_image_absolute_url:
29-
label: 'District image absolute URL'
30-
datasource_id: 'entity:node'
31-
property_path: district_image_absolute_url
32-
type: string
3330
field_district_image_alt:
3431
label: 'District image alt'
3532
datasource_id: 'entity:node'
@@ -92,6 +89,24 @@ field_settings:
9289
- field.storage.node.field_subdistricts
9390
module:
9491
- node
92+
main_image_url:
93+
label: 'Main image: URL'
94+
datasource_id: 'entity:node'
95+
property_path: main_image_url
96+
type: string
97+
configuration:
98+
field_name: field_district_image
99+
image_styles:
100+
- { id: '1.5_304w_203h', breakpoint: '1248' }
101+
- { id: '1.5_294w_196h', breakpoint: '992' }
102+
- { id: '1.5_220w_147h', breakpoint: '768' }
103+
- { id: '1.5_176w_118h', breakpoint: '576' }
104+
- { id: '1.5_511w_341h', breakpoint: '320' }
105+
- { id: '1.5_608w_406w_LQ', breakpoint: '1248_2x' }
106+
- { id: '1.5_588w_392h_LQ', breakpoint: '992_2x' }
107+
- { id: '1.5_440w_294h_LQ', breakpoint: '768_2x' }
108+
- { id: '1.5_352w_236h_LQ', breakpoint: '576_2x' }
109+
- { id: '1.5_1022w_682h_LQ', breakpoint: '320_2x' }
95110
nid:
96111
label: Nid
97112
datasource_id: 'entity:node'
@@ -138,7 +153,7 @@ datasource_settings:
138153
processor_settings:
139154
add_url: { }
140155
aggregated_field: { }
141-
district_image_absolute_url: { }
156+
custom_value: { }
142157
entity_status: { }
143158
entity_type: { }
144159
ignorecase:
@@ -152,10 +167,12 @@ processor_settings:
152167
- field_district_subdistricts_title
153168
- title
154169
language_with_fallback: { }
170+
main_image_url: { }
155171
project_execution_schedule: { }
156-
project_image_absolute_url: { }
157172
project_plan_schedule: { }
158173
rendered_item: { }
174+
scored_reference: { }
175+
scored_reference_parent: { }
159176
tokenizer:
160177
weights:
161178
preprocess_index: -6
@@ -172,6 +189,7 @@ tracker_settings:
172189
indexing_order: fifo
173190
options:
174191
cron_limit: 50
192+
delete_on_fail: true
175193
index_directly: false
176194
track_changes_in_references: true
177195
server: default

conf/cmi/search_api.index.projects.yml

Lines changed: 25 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,9 @@ dependencies:
1313
- field.storage.node.field_project_type
1414
- search_api.server.default
1515
module:
16+
- helfi_platform_config
1617
- helfi_react_search
18+
- helfi_recommendations
1719
- media
1820
- node
1921
- taxonomy
@@ -130,6 +132,24 @@ field_settings:
130132
- field.storage.node.field_project_type
131133
module:
132134
- taxonomy
135+
main_image_url:
136+
label: 'Main image: URL'
137+
datasource_id: 'entity:node'
138+
property_path: main_image_url
139+
type: string
140+
configuration:
141+
field_name: field_project_image
142+
image_styles:
143+
- { id: '1.5_304w_203h', breakpoint: '1248' }
144+
- { id: '1.5_294w_196h', breakpoint: '992' }
145+
- { id: '1.5_220w_147h', breakpoint: '768' }
146+
- { id: '1.5_176w_118h', breakpoint: '576' }
147+
- { id: '1.5_511w_341h', breakpoint: '320' }
148+
- { id: '1.5_608w_406w_LQ', breakpoint: '1248_2x' }
149+
- { id: '1.5_588w_392h_LQ', breakpoint: '992_2x' }
150+
- { id: '1.5_440w_294h_LQ', breakpoint: '768_2x' }
151+
- { id: '1.5_352w_236h_LQ', breakpoint: '576_2x' }
152+
- { id: '1.5_1022w_682h_LQ', breakpoint: '320_2x' }
133153
nid:
134154
label: Nid
135155
datasource_id: 'entity:node'
@@ -143,11 +163,6 @@ field_settings:
143163
datasource_id: 'entity:node'
144164
property_path: project_execution_schedule
145165
type: string
146-
project_image_absolute_url:
147-
label: 'Project image absolute URL'
148-
datasource_id: 'entity:node'
149-
property_path: project_image_absolute_url
150-
type: string
151166
project_plan_schedule:
152167
label: 'Project plan schedule'
153168
datasource_id: 'entity:node'
@@ -191,7 +206,7 @@ datasource_settings:
191206
processor_settings:
192207
add_url: { }
193208
aggregated_field: { }
194-
district_image_absolute_url: { }
209+
custom_value: { }
195210
entity_status: { }
196211
entity_type: { }
197212
ignorecase:
@@ -208,10 +223,12 @@ processor_settings:
208223
- field_project_type_name
209224
- title
210225
language_with_fallback: { }
226+
main_image_url: { }
211227
project_execution_schedule: { }
212-
project_image_absolute_url: { }
213228
project_plan_schedule: { }
214229
rendered_item: { }
230+
scored_reference: { }
231+
scored_reference_parent: { }
215232
tokenizer:
216233
weights:
217234
preprocess_index: -6
@@ -228,6 +245,7 @@ tracker_settings:
228245
indexing_order: fifo
229246
options:
230247
cron_limit: 50
248+
delete_on_fail: true
231249
index_directly: false
232250
track_changes_in_references: true
233251
server: default

0 commit comments

Comments
 (0)