Skip to content

Commit

Permalink
Merge pull request #172 from cultuurnet/feature/WID-550
Browse files Browse the repository at this point in the history
WID-550 - Add option to show uitx in widget
  • Loading branch information
brampauwelyn authored Jan 16, 2024
2 parents 6c9c7db + 900a23b commit 071b3be
Show file tree
Hide file tree
Showing 7 changed files with 50 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/app/core/template/page-templates/uitpas-page-template.ts
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,9 @@ export class UitPasPageTemplate implements PageTemplate {
icon_museumpass: {
enabled: true,
},
icon_uitx: {
enabled: true,
},
description: {
enabled: true,
characters: 200,
Expand Down Expand Up @@ -219,6 +222,9 @@ export class UitPasPageTemplate implements PageTemplate {
icon_museumpass: {
enabled: true,
},
icon_uitx: {
enabled: true,
},
when: {
enabled: true,
label: 'Wanneer',
Expand Down
8 changes: 8 additions & 0 deletions src/app/page.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,10 @@
"show": true,
"label": "Museumpas"
},
"icon_uitx": {
"show": true,
"label": "UiTX"
},
"description": {
"show": true,
"characters": 200
Expand Down Expand Up @@ -102,6 +106,10 @@
"show": true,
"label": "Museumpas"
},
"icon_uitx": {
"show": true,
"label": "UiTX"
},
"description": {
"show": true,
"characters": 200
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -200,6 +200,18 @@
}}</span>
</label>
</div>
<div
class="edit-searchfilters--selectgroup"
formGroupName="icon_uitx"
>
<label>
<input type="checkbox" formControlName="enabled" />
<span>{{
'LABEL_SEARCH_RESULTS_EDIT_FORM_ELEMENTS_ICON_UITX'
| translate
}}</span>
</label>
</div>
<div
class="edit-searchfilters--selectgroup"
formGroupName="description"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,9 @@ export class SearchResultsWidgetEditComponent extends BaseWidgetEditDirective {
_.get(this.widget.settings, 'items.icon_museumpass.enabled', ''),
],
}),
icon_uitx: this.formBuilder.group({
enabled: [_.get(this.widget.settings, 'items.icon_uitx.enabled', '')],
}),
description: this.formBuilder.group({
enabled: [
_.get(this.widget.settings, 'items.description.enabled', ''),
Expand Down Expand Up @@ -285,6 +288,11 @@ export class SearchResultsWidgetEditComponent extends BaseWidgetEditDirective {
),
],
}),
icon_uitx: this.formBuilder.group({
enabled: [
_.get(this.widget.settings, 'detail_page.icon_uitx.enabled', ''),
],
}),
description: this.formBuilder.group({
enabled: [
_.get(this.widget.settings, 'detail_page.description.enabled', ''),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,17 @@
}}</span>
</label>
</div>
<div
class="edit-searchfilters--selectgroup"
formGroupName="icon_uitx"
>
<label>
<input type="checkbox" formControlName="enabled" />
<span>{{
'LABEL_TIPS_EDIT_FORM_ELEMENTS_ICON_UITX' | translate
}}</span>
</label>
</div>
<div
class="edit-searchfilters--selectgroup"
formGroupName="description"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,9 @@ export class TipsWidgetWidgetEditComponent extends BaseWidgetEditDirective {
_.get(this.widget.settings, 'items.icon_museumpass.enabled', ''),
],
}),
icon_uitx: this.formBuilder.group({
enabled: [_.get(this.widget.settings, 'items.icon_uitx.enabled', '')],
}),
description: this.formBuilder.group({
enabled: [
_.get(this.widget.settings, 'items.description.enabled', ''),
Expand Down
2 changes: 2 additions & 0 deletions src/assets/i18n/nl.json
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@
"LABEL_TIPS_EDIT_FORM_ELEMENTS_ICON_VLIEG": "Vlieg-logo",
"LABEL_TIPS_EDIT_FORM_ELEMENTS_ICON_UITPAS": "UiTPAS-logo",
"LABEL_TIPS_EDIT_FORM_ELEMENTS_ICON_MUSEUMPASS": "Museumpas-logo",
"LABEL_TIPS_EDIT_FORM_ELEMENTS_ICON_UITX": "UiTX-logo",
"LABEL_TIPS_EDIT_FORM_ELEMENTS_DESCRIPTION": "Beschrijving",
"LABEL_TIPS_EDIT_FORM_ELEMENTS_DESCRIPTION_LABEL": "Label",
"LABEL_TIPS_EDIT_FORM_ELEMENTS_DESCRIPTION_NUM_CHARACTERS": "Aantal karakters",
Expand Down Expand Up @@ -137,6 +138,7 @@
"LABEL_SEARCH_RESULTS_EDIT_FORM_ELEMENTS_ICON_VLIEG": "Vlieg-logo",
"LABEL_SEARCH_RESULTS_EDIT_FORM_ELEMENTS_ICON_UITPAS": "UiTPAS-logo",
"LABEL_SEARCH_RESULTS_EDIT_FORM_ELEMENTS_ICON_MUSEUMPASS": "Museumpas-logo",
"LABEL_SEARCH_RESULTS_EDIT_FORM_ELEMENTS_ICON_UITX": "UiTX-logo",
"LABEL_SEARCH_RESULTS_EDIT_FORM_ELEMENTS_DESCRIPTION": "Beschrijving",
"LABEL_SEARCH_RESULTS_EDIT_FORM_ELEMENTS_DESCRIPTION_LABEL": "Label",
"LABEL_SEARCH_RESULTS_EDIT_FORM_ELEMENTS_DESCRIPTION_NUM_CHARACTERS": "Aantal karakters",
Expand Down

0 comments on commit 071b3be

Please sign in to comment.