Refactor views to use new layout structure and update routes for administrator pages

- Changed view extends from "admin.main" to "administrator.layout.master" across multiple files.
- Updated route names in admin.php and administrator.php to reflect new structure for user, order, invoice, and other management functionalities.
- Adjusted view includes to point to the new directory structure for blocks and components.
- Ensured all permission checks remain intact while refactoring the views.
This commit is contained in:
pbao9
2026-02-02 10:31:11 +07:00
parent d3b264262b
commit 17b02631e4
106 changed files with 284 additions and 259 deletions
@@ -1,5 +1,5 @@
@php use Carbon\Carbon; @endphp
@extends("admin.main")
@extends("administrator.layout.master")
@section("content")
@if(auth()->guard('admins')->user()->can("edit order"))
<div class="card card-outline card-primary">
@@ -128,7 +128,7 @@
<form
onclick=" {{ $order->status === 1 ? "return false;" : "" }}"
class="d-lg-inline"
action="{{ route('admin.order.update',['id' => $order->id,'action' => 'accept']) }}"
action="{{ route('administrator.pages.order.update',['id' => $order->id,'action' => 'accept']) }}"
method="post">
@method('put')
@csrf
@@ -140,7 +140,7 @@
</button>
</form>
<form class="d-lg-inline"
action="{{ route('admin.order.update',['id' => $order->id,'action' => 'cancel']) }}"
action="{{ route('administrator.pages.order.update',['id' => $order->id,'action' => 'cancel']) }}"
method="post">
@method('put')
@csrf
@@ -148,7 +148,7 @@
class="btn bg-gradient-secondary">Cancel Order
</button>
</form>
<form class="d-lg-inline" action="{{ route('admin.order.destroy',['id' => $order->id]) }}"
<form class="d-lg-inline" action="{{ route('administrator.pages.order.destroy',['id' => $order->id]) }}"
method="post">
@method('delete')
@csrf
@@ -156,7 +156,7 @@
class="btn bg-gradient-danger">Delete Order
</button>
</form>
<a href="{{ route('admin.order.index') }}" class="btn bg-gradient-secondary">
<a href="{{ route('administrator.pages.order.index') }}" class="btn bg-gradient-secondary">
Back
</a>
</div>