Implement package limit notification system
This commit is contained in:
30
app/Support/ApiError.php
Normal file
30
app/Support/ApiError.php
Normal file
@@ -0,0 +1,30 @@
|
||||
<?php
|
||||
|
||||
namespace App\Support;
|
||||
|
||||
use Illuminate\Http\JsonResponse;
|
||||
|
||||
class ApiError
|
||||
{
|
||||
public static function response(
|
||||
string $code,
|
||||
string $title,
|
||||
string $message,
|
||||
int $status,
|
||||
array $meta = []
|
||||
): JsonResponse {
|
||||
$payload = [
|
||||
'error' => [
|
||||
'code' => $code,
|
||||
'title' => $title,
|
||||
'message' => $message,
|
||||
],
|
||||
];
|
||||
|
||||
if ($meta !== []) {
|
||||
$payload['error']['meta'] = $meta;
|
||||
}
|
||||
|
||||
return response()->json($payload, $status);
|
||||
}
|
||||
}
|
||||
@@ -33,7 +33,7 @@ class JoinTokenLayoutRegistry
|
||||
'link_heading' => 'Falls der Scan nicht klappt',
|
||||
'cta_label' => 'Gästegalerie öffnen',
|
||||
'cta_caption' => 'Jetzt Erinnerungen sammeln',
|
||||
'qr' => ['size_px' => 520],
|
||||
'qr' => ['size_px' => 640],
|
||||
'svg' => ['width' => 1240, 'height' => 1754],
|
||||
'instructions' => [
|
||||
'QR-Code scannen und mit eurem Lieblingsnamen anmelden.',
|
||||
@@ -62,7 +62,7 @@ class JoinTokenLayoutRegistry
|
||||
'link_heading' => 'Link teilen statt scannen',
|
||||
'cta_label' => 'Jetzt Event-Hub öffnen',
|
||||
'cta_caption' => 'Programm, Uploads & Highlights',
|
||||
'qr' => ['size_px' => 560],
|
||||
'qr' => ['size_px' => 640],
|
||||
'svg' => ['width' => 1240, 'height' => 1754],
|
||||
'instructions' => [
|
||||
'QR-Code scannen oder Kurzlink eingeben.',
|
||||
@@ -91,7 +91,7 @@ class JoinTokenLayoutRegistry
|
||||
'link_heading' => 'Alternativ zum Scannen',
|
||||
'cta_label' => 'Gästebuch öffnen',
|
||||
'cta_caption' => 'Eure Grüße festhalten',
|
||||
'qr' => ['size_px' => 520],
|
||||
'qr' => ['size_px' => 660],
|
||||
'svg' => ['width' => 1240, 'height' => 1754],
|
||||
'instructions' => [
|
||||
'QR-Code scannen und Namen eintragen.',
|
||||
@@ -120,7 +120,7 @@ class JoinTokenLayoutRegistry
|
||||
'link_heading' => 'QR funktioniert nicht?',
|
||||
'cta_label' => 'Partyfeed starten',
|
||||
'cta_caption' => 'Momente live teilen',
|
||||
'qr' => ['size_px' => 560],
|
||||
'qr' => ['size_px' => 680],
|
||||
'svg' => ['width' => 1240, 'height' => 1754],
|
||||
'instructions' => [
|
||||
'Code scannen und kurz registrieren.',
|
||||
@@ -149,7 +149,7 @@ class JoinTokenLayoutRegistry
|
||||
'link_heading' => 'Kurzlink für Gäste',
|
||||
'cta_label' => 'Zur Geburtstagswand',
|
||||
'cta_caption' => 'Fotos & Grüße posten',
|
||||
'qr' => ['size_px' => 520],
|
||||
'qr' => ['size_px' => 680],
|
||||
'svg' => ['width' => 1240, 'height' => 1754],
|
||||
'instructions' => [
|
||||
'QR-Code scannen und Wunschname auswählen.',
|
||||
@@ -223,7 +223,7 @@ class JoinTokenLayoutRegistry
|
||||
'link_label' => null,
|
||||
'logo_url' => null,
|
||||
'qr' => [
|
||||
'size_px' => 360,
|
||||
'size_px' => 640,
|
||||
],
|
||||
'svg' => [
|
||||
'width' => 1240,
|
||||
|
||||
Reference in New Issue
Block a user