Added Template Files, Grouped Den Routes

Added the necessary template files for every page needed. Most are still
empty but all are accounted for from the previous version.

Also organized all routes to the dashboard, named the den for better security
about-updates
Ro 1 year ago
parent 14af284103
commit 66cf78ba75
Signed by untrusted user: are0h
GPG Key ID: 29B551CDBD4D3B50

@ -13,7 +13,7 @@ class AuthController extends Controller
//$token = $request->session()->token(); //$token = $request->session()->token();
//$token = csrf_token(); //$token = csrf_token();
return view('front.login'); return view('back.login');
} }
public function memberAuth(Request $request): Response public function memberAuth(Request $request): Response

@ -13,4 +13,10 @@ class DenController extends Controller
$member = Auth::user(); $member = Auth::user();
return view('back.start', ['handle' => $member->handle]); return view('back.start', ['handle' => $member->handle]);
} }
public function member(Request $request)
{
$member = Auth::user();
return view('back.member', ['handle' => $member->handle]);
}
} }

@ -9,7 +9,7 @@ class FrontIndexController extends Controller
{ {
public function start() public function start()
{ {
$locations = Location::all(); $locations = Location::where("active", true)->get();
$count = count($locations); $count = count($locations);
$terms = "no|agenda"; $terms = "no|agenda";

@ -0,0 +1,4 @@
<div>
<h1>Mmeber Stuff</h1>
Hey {{$handle}}
</div>

@ -5,6 +5,27 @@
@section('main-content') @section('main-content')
@parent @parent
<p>This is where we start</p> <section role="start">
<div role="index-wrapper">
<div role="index-search">
<form action="/search" method="post" enctype="multipart/form-data">
<input type="text" name="index_search" value="" placeholder="SEARCH ME!" />
<button>
<i class="ti ti-search"></i>
</button>
</form>
</div>
<div role="index-results">
{{$count}} {{$count}}
Bad Spaces tracked. Shot by
<a href="https://unsplash.com/photos/935EcPU1pBI">Ussama Azam</a>
</div>
</div>
</section>
@endsection @endsection

@ -16,13 +16,16 @@ use App\Http\Controllers\DenController;
| |
*/ */
//index //front
Route::get("/", [FrontIndexController::class, 'start']); Route::get("/", [FrontIndexController::class, 'start']);
//auth //auth
Route::get("/login", [AuthController::class, 'showLogin']); Route::get("/login", [AuthController::class, 'showLogin']);
Route::post("/login", [AuthController::class, 'memberAuth']); Route::post("/login", [AuthController::class, 'memberAuth']);
//den
Route::get("/den", [DenController::class, 'start'])->middleware('member.check');
Route::get("/logout", [AuthController::class, 'leave']); Route::get("/logout", [AuthController::class, 'leave']);
//back
Route::group(['prefix' => 'den', 'middleware' => 'member.check'], function () {
Route::get("/", [DenController::class, 'start']);
Route::get("/member", [DenController::class, 'member']);
});

Loading…
Cancel
Save