mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-08-28 10:33:49 +00:00
restructure json data
This commit is contained in:
@@ -29,10 +29,12 @@ class NewsItemNormalizer implements NormalizerInterface
|
||||
return [
|
||||
'id' => $newsItem->getId(),
|
||||
'type' => 'news',
|
||||
'title' => $newsItem->getTitle(),
|
||||
'content' => $newsItem->getContent(),
|
||||
'startdate' => $newsItem->getStartDate(),
|
||||
'enddate' => $newsItem->getEndDate()
|
||||
'metadata' => [
|
||||
'title' => $newsItem->getTitle(),
|
||||
'content' => $newsItem->getContent(),
|
||||
'startdate' => $newsItem->getStartDate(),
|
||||
'enddate' => $newsItem->getEndDate()
|
||||
],
|
||||
];
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user