events werden nun erfolgreich gespeichert, branding wird nun erfolgreich gespeichert, emotionen können nun angelegt werden. Task Ansicht im Event admin verbessert, Buttons in FAB umgewandelt und vereinheitlicht. Teilen-Link Guest PWA schicker gemacht, SynGoogleFonts ausgebaut (mit Einzel-Family-Download).
This commit is contained in:
@@ -41,9 +41,21 @@ class TaskResource extends JsonResource
|
||||
'eventType',
|
||||
fn () => new EventTypeResource($this->eventType)
|
||||
),
|
||||
'emotion_id' => $this->emotion_id,
|
||||
'emotion' => $this->whenLoaded(
|
||||
'emotion',
|
||||
fn () => [
|
||||
'id' => $this->emotion->id,
|
||||
'name' => $this->translatedText($this->normalizeTranslations($this->emotion->name), ''),
|
||||
'name_translations' => $this->emotion->name,
|
||||
'icon' => $this->emotion->icon,
|
||||
'color' => $this->emotion->color,
|
||||
]
|
||||
),
|
||||
'collection_id' => $this->collection_id,
|
||||
'source_task_id' => $this->source_task_id,
|
||||
'source_collection_id' => $this->source_collection_id,
|
||||
'sort_order' => $this->pivot?->sort_order,
|
||||
'assigned_events_count' => $assignedEventsCount,
|
||||
'assigned_events' => $this->whenLoaded(
|
||||
'assignedEvents',
|
||||
@@ -86,7 +98,7 @@ class TaskResource extends JsonResource
|
||||
}
|
||||
|
||||
/**
|
||||
* @param array<string, string> $translations
|
||||
* @param array<string, string> $translations
|
||||
*/
|
||||
protected function translatedText(array $translations, string $fallback): string
|
||||
{
|
||||
@@ -109,4 +121,3 @@ class TaskResource extends JsonResource
|
||||
return $first !== false ? $first : $fallback;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user