From 811113d4e8bd80a718114ec98df7c32998892ff3 Mon Sep 17 00:00:00 2001 From: LailaWulandarii Date: Sun, 15 Feb 2026 13:57:03 +0700 Subject: [PATCH 1/7] add PreventBackHistory middleware and apply to admin routes --- app/Http/Middleware/PreventBackHistory.php | 24 ++++++++++++++++++++++ routes/web.php | 2 +- 2 files changed, 25 insertions(+), 1 deletion(-) create mode 100644 app/Http/Middleware/PreventBackHistory.php diff --git a/app/Http/Middleware/PreventBackHistory.php b/app/Http/Middleware/PreventBackHistory.php new file mode 100644 index 0000000..e5b141b --- /dev/null +++ b/app/Http/Middleware/PreventBackHistory.php @@ -0,0 +1,24 @@ +header('Cache-Control', 'no-cache, no-store, max-age=0, must-revalidate') + ->header('Pragma', 'no-cache') + ->header('Expires', 'Fri, 01 Jan 1990 00:00:00 GMT'); + } +} diff --git a/routes/web.php b/routes/web.php index 85868fb..68a35bf 100644 --- a/routes/web.php +++ b/routes/web.php @@ -50,7 +50,7 @@ |-------------------------------------------------------------------------- | */ -Route::prefix('admin')->name('admin.')->middleware(['auth'])->group(function () { +Route::prefix('admin')->name('admin.')->middleware(['auth', 'prevent-back'])->group(function () { Route::redirect('/', '/admin/beranda'); From 4b1a4784a2aa1f910037cdb32ef43c7cca979a14 Mon Sep 17 00:00:00 2001 From: LailaWulandarii Date: Sun, 15 Feb 2026 14:13:53 +0700 Subject: [PATCH 2/7] fix: update attribute labels for BookingFotoRequest and PesanBuketRequest to use proper capitalization --- app/Http/Requests/User/BookingFotoRequest.php | 6 +++--- app/Http/Requests/User/PesanBuketRequest.php | 12 ++++++------ 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/app/Http/Requests/User/BookingFotoRequest.php b/app/Http/Requests/User/BookingFotoRequest.php index 0647f6e..b189d48 100644 --- a/app/Http/Requests/User/BookingFotoRequest.php +++ b/app/Http/Requests/User/BookingFotoRequest.php @@ -44,9 +44,9 @@ public function messages(): array public function attributes(): array { return [ - 'nama' => 'nama pemesan', - 'no_wa' => 'nomor WhatsApp', - 'bukti_bayar' => 'bukti pembayaran', + 'nama' => 'Nama pemesan', + 'no_wa' => 'Nomor WhatsApp', + 'bukti_bayar' => 'Bukti pembayaran', ]; } } diff --git a/app/Http/Requests/User/PesanBuketRequest.php b/app/Http/Requests/User/PesanBuketRequest.php index 5dcdaf7..d342fb1 100644 --- a/app/Http/Requests/User/PesanBuketRequest.php +++ b/app/Http/Requests/User/PesanBuketRequest.php @@ -54,12 +54,12 @@ public function messages(): array public function attributes(): array { return [ - 'nama' => 'nama pemesan', - 'no_wa' => 'nomor WhatsApp', - 'tgl_ambil' => 'tanggal pengambilan', - 'waktu_ambil' => 'waktu pengambilan', - 'bukti_bayar' => 'bukti pembayaran', - 'ucapan' => 'kartu ucapan', + 'nama' => 'Nama pemesan', + 'no_wa' => 'Nomor WhatsApp', + 'tgl_ambil' => 'Tanggal pengambilan', + 'waktu_ambil' => 'Waktu pengambilan', + 'bukti_bayar' => 'Bukti pembayaran', + 'ucapan' => 'Kartu ucapan', ]; } } From b088d90f5dac01f419fe88352d8a49ca1c28a3f0 Mon Sep 17 00:00:00 2001 From: LailaWulandarii Date: Mon, 16 Feb 2026 14:14:19 +0700 Subject: [PATCH 3/7] fix: update attribute labels in AdditionalRequest, BuketRequest, and FotoRequest to use proper capitalization --- app/Http/Requests/Admin/AdditionalRequest.php | 4 ++-- app/Http/Requests/Admin/BuketRequest.php | 14 +++++++------- app/Http/Requests/Admin/FotoRequest.php | 9 +++++---- 3 files changed, 14 insertions(+), 13 deletions(-) diff --git a/app/Http/Requests/Admin/AdditionalRequest.php b/app/Http/Requests/Admin/AdditionalRequest.php index 637e4a2..b6beae3 100644 --- a/app/Http/Requests/Admin/AdditionalRequest.php +++ b/app/Http/Requests/Admin/AdditionalRequest.php @@ -36,8 +36,8 @@ public function messages(): array public function attributes(): array { return [ - 'nama' => 'nama additional', - 'harga' => 'harga additional', + 'nama' => 'Nama additional', + 'harga' => 'Harga additional', ]; } diff --git a/app/Http/Requests/Admin/BuketRequest.php b/app/Http/Requests/Admin/BuketRequest.php index 70017c2..f3c7882 100644 --- a/app/Http/Requests/Admin/BuketRequest.php +++ b/app/Http/Requests/Admin/BuketRequest.php @@ -49,13 +49,13 @@ public function messages(): array public function attributes(): array { return [ - 'nama' => 'nama buket', - 'ukuran' => 'ukuran buket', - 'kategori' => 'kategori buket', - 'harga' => 'harga', - 'request_khusus' => 'request khusus', - 'deskripsi' => 'deskripsi produk', - 'foto' => 'foto produk', + 'nama' => 'Nama buket', + 'ukuran' => 'Ukuran buket', + 'kategori' => 'Kategori buket', + 'harga' => 'Harga buket', + 'request_khusus' => 'Request khusus', + 'deskripsi' => 'Deskripsi buket', + 'foto' => 'Foto buket', ]; } diff --git a/app/Http/Requests/Admin/FotoRequest.php b/app/Http/Requests/Admin/FotoRequest.php index bb2beb2..b34d679 100644 --- a/app/Http/Requests/Admin/FotoRequest.php +++ b/app/Http/Requests/Admin/FotoRequest.php @@ -46,10 +46,11 @@ public function messages(): array public function attributes(): array { return [ - 'nama' => 'nama paket', - 'harga' => 'harga paket', - 'durasi' => 'durasi paket', - 'foto' => 'foto paket', + 'nama' => 'Nama paket', + 'harga' => 'Harga paket', + 'durasi' => 'Durasi paket', + 'foto' => 'Foto paket', + 'deskripsi' => 'Deskripsi paket', ]; } From 0e500c7802a70e5545140662dbc63905516e09f2 Mon Sep 17 00:00:00 2001 From: LailaWulandarii Date: Mon, 16 Feb 2026 14:14:34 +0700 Subject: [PATCH 4/7] fix: update attribute labels in AdminRequest and ProfilRequest to use proper capitalization --- app/Http/Requests/Admin/AdminRequest.php | 12 ++++++------ app/Http/Requests/Admin/ProfilRequest.php | 7 +++++-- 2 files changed, 11 insertions(+), 8 deletions(-) diff --git a/app/Http/Requests/Admin/AdminRequest.php b/app/Http/Requests/Admin/AdminRequest.php index a6ae475..efc32a6 100644 --- a/app/Http/Requests/Admin/AdminRequest.php +++ b/app/Http/Requests/Admin/AdminRequest.php @@ -50,12 +50,12 @@ public function messages(): array public function attributes(): array { return [ - 'nama' => 'nama lengkap', - 'username' => 'username', - 'email' => 'alamat email', - 'no_wa' => 'nomor WA', - 'role' => 'peran admin', - 'alamat' => 'alamat lengkap', + 'nama' => 'Nama lengkap', + 'username' => 'Username', + 'email' => 'Alamat email', + 'no_wa' => 'Nomor WhatsApp', + 'role' => 'Peran admin', + 'alamat' => 'Alamat', ]; } diff --git a/app/Http/Requests/Admin/ProfilRequest.php b/app/Http/Requests/Admin/ProfilRequest.php index 812aeed..ec1152f 100644 --- a/app/Http/Requests/Admin/ProfilRequest.php +++ b/app/Http/Requests/Admin/ProfilRequest.php @@ -47,8 +47,11 @@ public function messages(): array public function attributes(): array { return [ - 'nama' => 'Nama Lengkap', - 'no_wa' => 'Nomor WA', + 'nama' => 'Nama lengkap', + 'no_wa' => 'Nomor WhatsApp', + 'alamat' => 'Alamat', + 'username' => 'Username', + 'email' => 'Email', ]; } } From 0efb9bb0961825bb5e0b67eedba5c666e5ac9ada Mon Sep 17 00:00:00 2001 From: LailaWulandarii Date: Tue, 17 Feb 2026 14:15:02 +0700 Subject: [PATCH 5/7] fix: adjust formatting and remove unnecessary type hints in app.php --- bootstrap/app.php | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/bootstrap/app.php b/bootstrap/app.php index c183276..969b0b6 100644 --- a/bootstrap/app.php +++ b/bootstrap/app.php @@ -6,13 +6,16 @@ return Application::configure(basePath: dirname(__DIR__)) ->withRouting( - web: __DIR__.'/../routes/web.php', - commands: __DIR__.'/../routes/console.php', + web: __DIR__ . '/../routes/web.php', + commands: __DIR__ . '/../routes/console.php', health: '/up', ) - ->withMiddleware(function (Middleware $middleware): void { - // + ->withMiddleware(function (Middleware $middleware) { + // Daftarkan alias di sini + $middleware->alias([ + 'prevent-back' => \App\Http\Middleware\PreventBackHistory::class, + ]); }) - ->withExceptions(function (Exceptions $exceptions): void { + ->withExceptions(function (Exceptions $exceptions) { // })->create(); From 5c9aa904196d43a2513bcf653d20acaa1fb2ac7c Mon Sep 17 00:00:00 2001 From: LailaWulandarii Date: Tue, 17 Feb 2026 14:16:14 +0700 Subject: [PATCH 6/7] fix: improve date and time input handling in pembayaran-buket form --- .../views/user/pembayaran-buket.blade.php | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) diff --git a/resources/views/user/pembayaran-buket.blade.php b/resources/views/user/pembayaran-buket.blade.php index 9376e3e..edf2424 100644 --- a/resources/views/user/pembayaran-buket.blade.php +++ b/resources/views/user/pembayaran-buket.blade.php @@ -83,25 +83,23 @@ class="form-control formulirbuket-input @error('no_wa') is-invalid @enderror"
- + @error('tgl_ambil')
{{ $message }}
@enderror
-
- + class="form-control bg-white @error('waktu_ambil') is-invalid @enderror" + placeholder="Pilih Jam" value="{{ old('waktu_ambil') }}" readonly + onkeydown="return false;"> -
- Jam operasional: 09:00 - 21:00 WIB @error('waktu_ambil') @@ -259,7 +257,7 @@ class="btn formulirbuket-btn-cancel flex-fill">Batalkan time_24hr: true, minTime: "09:00", maxTime: "21:00", - disableMobile: "true" + disableMobile: true, }); }); From 2473a31c8b71b0a794e8849136b3cd0490d58d8a Mon Sep 17 00:00:00 2001 From: LailaWulandarii Date: Tue, 17 Feb 2026 14:16:25 +0700 Subject: [PATCH 7/7] fix: add validation feedback for 'ukuran' and 'kategori' fields in modal forms --- .../admin/paket-foto/partials/modal-create-foto.blade.php | 2 +- .../admin/produk-buket/partials/modal-create.blade.php | 6 ++++++ .../views/admin/produk-buket/partials/modal-edit.blade.php | 6 ++++++ 3 files changed, 13 insertions(+), 1 deletion(-) diff --git a/resources/views/admin/paket-foto/partials/modal-create-foto.blade.php b/resources/views/admin/paket-foto/partials/modal-create-foto.blade.php index 6ba773d..27a4dfd 100644 --- a/resources/views/admin/paket-foto/partials/modal-create-foto.blade.php +++ b/resources/views/admin/paket-foto/partials/modal-create-foto.blade.php @@ -70,7 +70,7 @@ class="form-control @error('durasi') is-invalid @enderror"
- + {{-- Area Upload Custom --}}
Large (L) + @error('ukuran') +
{{ $message }}
+ @enderror
{{-- Input Kategori --}} @@ -59,6 +62,9 @@ class="form-control @error('nama') is-invalid @enderror" style="font-size: 14px; + @error('kategori') +
{{ $message }}
+ @enderror
diff --git a/resources/views/admin/produk-buket/partials/modal-edit.blade.php b/resources/views/admin/produk-buket/partials/modal-edit.blade.php index ba3b333..2dad4c5 100644 --- a/resources/views/admin/produk-buket/partials/modal-edit.blade.php +++ b/resources/views/admin/produk-buket/partials/modal-edit.blade.php @@ -44,6 +44,9 @@ class="form-control @error('nama') is-invalid @enderror" style="font-size: 14px; Large (L) + @error('ukuran') +
{{ $message }}
+ @enderror
{{-- Kategori --}} @@ -64,6 +67,9 @@ class="form-control @error('nama') is-invalid @enderror" style="font-size: 14px; {{ old('kategori', $b->kategori) == 'artificial' ? 'selected' : '' }}> Artificial + @error('kategori') +
{{ $message }}
+ @enderror