feat: Add seeders for Buku and Kategori with initial data

This commit is contained in:
2026-03-17 22:10:16 +07:00
parent 5f00a0dbf1
commit 60eb58a6cf
4 changed files with 191 additions and 37 deletions

View File

@@ -7,41 +7,20 @@ use Inertia\Middleware;
class HandleInertiaRequests extends Middleware
{
/**
* The root template that's loaded on the first page visit.
*
* @see https://inertiajs.com/server-side-setup#root-template
*
* @var string
*/
protected $rootView = 'app';
/**
* Determines the current asset version.
*
* @see https://inertiajs.com/asset-versioning
*/
public function version(Request $request): ?string
{
return parent::version($request);
}
/**
* Define the props that are shared by default.
*
* @see https://inertiajs.com/shared-data
*
* @return array<string, mixed>
*/
public function share(Request $request): array
{
return [
...parent::share($request),
//
return array_merge(parent::share($request), [
'flash' => [
'success' => fn () => $request->session()->get('success'),
'error' => fn () => $request->session()->get('error'),
'success' => fn() => $request->session()->get('success'),
'error' => fn() => $request->session()->get('error'),
],
];
]);
}
}