Skip to content

Commit fd888e6

Browse files
authored
Merge branch 'main' into feature/III-6977-notification-publication-delay
2 parents 808ad45 + c531eb4 commit fd888e6

File tree

5 files changed

+31
-6
lines changed

5 files changed

+31
-6
lines changed

src/i18n/de.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1422,6 +1422,7 @@
14221422
"labels": {
14231423
"title": "Titel",
14241424
"type": "Typ",
1425+
"theme": "Thema",
14251426
"labels": "Labels",
14261427
"description": "Beschreibung",
14271428
"location": "Wo",
@@ -1439,6 +1440,7 @@
14391440
},
14401441
"empty_value": {
14411442
"description": "Keine Beschreibung",
1443+
"theme": "Kein Thema",
14421444
"organiser": "Keine Organisationsinformationen",
14431445
"price": "Keine Preisinformation",
14441446
"booking": "Keine Reservierungsinformationen",

src/i18n/fr.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1421,6 +1421,7 @@
14211421
"labels": {
14221422
"title": "Titre",
14231423
"type": "Type",
1424+
"theme": "Thème",
14241425
"labels": "Étiquettes",
14251426
"description": "Description",
14261427
"location": "",
@@ -1438,6 +1439,7 @@
14381439
},
14391440
"empty_value": {
14401441
"description": "Aucune description",
1442+
"theme": "Aucun thème",
14411443
"organiser": "Aucune information sur l'organisation",
14421444
"price": "Pas d'information du prix",
14431445
"booking": "Aucune information sur la réservation",

src/i18n/nl.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1478,6 +1478,7 @@
14781478
"labels": {
14791479
"title": "Titel",
14801480
"type": "Type",
1481+
"theme": "Thema",
14811482
"labels": "Labels",
14821483
"description": "Beschrijving",
14831484
"location": "Waar",
@@ -1495,6 +1496,7 @@
14951496
},
14961497
"empty_value": {
14971498
"description": "Geen beschrijving",
1499+
"theme": "Geen thema",
14981500
"organiser": "Geen organisatie-informatie",
14991501
"price": "Geen prijsinformatie",
15001502
"booking": "Geen reservatie-informatie",

src/pages/events/[eventId]/preview/Preview.tsx

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,7 @@ const Preview = () => {
7272
);
7373

7474
const typeTerm = terms.find((term) => term.domain === 'eventtype');
75+
const themeTerm = terms.find((term) => term.domain === 'theme');
7576

7677
const description = getLanguageObjectOrFallback<string>(
7778
offer.description,
@@ -281,6 +282,14 @@ const Preview = () => {
281282
const tableData = [
282283
{ field: t('preview.labels.title'), value: title },
283284
{ field: t('preview.labels.type'), value: typeTerm.label },
285+
{
286+
field: t('preview.labels.theme'),
287+
value: themeTerm ? (
288+
themeTerm.label
289+
) : (
290+
<EmptyValue>{t('preview.empty_value.theme')}</EmptyValue>
291+
),
292+
},
284293
{
285294
field: t('preview.labels.labels'),
286295
value: (

src/test/e2e/events/create-calendar-multiple.spec.ts

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,7 @@ test('create an event with calendarType multiple', async ({
7777
const expectedLabels = [
7878
'Titel',
7979
'Type',
80+
'Thema',
8081
'Labels',
8182
'Beschrijving',
8283
'Waar',
@@ -103,18 +104,27 @@ test('create an event with calendarType multiple', async ({
103104
// Validate that some rows have "Geen" when empty
104105
const tableRows = await page.locator('table.table > tbody > tr').count();
105106

106-
const rowsWithGeenValue = [3, 6, 7, 10, 11, 13, 14];
107-
108-
const secondColumnCells = await page
109-
.locator('table.table > tbody > tr > td:nth-child(2)')
110-
.allTextContents();
107+
const expectedEmptyFields = [
108+
'Thema',
109+
'Beschrijving',
110+
'Organisatie',
111+
'Prijsinfo',
112+
'Reservatie',
113+
'Contactgegevens',
114+
'Afbeeldingen',
115+
"Video's",
116+
];
111117

112118
for (let i = 0; i < tableRows; i++) {
119+
const firstColumnValue = await page
120+
.locator(`table.table > tbody > tr:nth-child(${i + 1}) > td:nth-child(1)`)
121+
.textContent();
122+
113123
const secondColumnValue = await page
114124
.locator(`table.table > tbody > tr:nth-child(${i + 1}) > td:nth-child(2)`)
115125
.textContent();
116126

117-
if (rowsWithGeenValue.includes(i)) {
127+
if (expectedEmptyFields.includes(firstColumnValue?.trim() ?? '')) {
118128
expect(secondColumnValue).toContain('Geen');
119129
} else {
120130
expect(secondColumnValue?.trim()).not.toBe('');

0 commit comments

Comments
 (0)