From 598f215536724ff32326204b51638248e474cffd Mon Sep 17 00:00:00 2001 From: Ronald-pro <36841157+Ronald-pro@users.noreply.github.com> Date: Fri, 26 Jan 2024 13:26:36 +0300 Subject: [PATCH] revised the initial page and added facility directory --- app/Http/Controllers/Auth/LoginController.php | 2 +- app/Http/Controllers/DirectoryController.php | 28 +++ resources/views/auth/login.blade.php | 12 +- .../clients/adolescents_clients.blade.php | 189 ++++++++-------- resources/views/directory/search.blade.php | 211 ++++++++++++++++++ resources/views/landing/page.blade.php | 62 +++++ routes/web.php | 8 +- 7 files changed, 412 insertions(+), 100 deletions(-) create mode 100644 app/Http/Controllers/DirectoryController.php create mode 100644 resources/views/directory/search.blade.php create mode 100644 resources/views/landing/page.blade.php diff --git a/app/Http/Controllers/Auth/LoginController.php b/app/Http/Controllers/Auth/LoginController.php index 83e1e32..1386965 100644 --- a/app/Http/Controllers/Auth/LoginController.php +++ b/app/Http/Controllers/Auth/LoginController.php @@ -40,7 +40,7 @@ protected function redirectTo() { Session::flash('statuscode', 'success'); return '/admin/dashboard'; }else { - return '/'; + return '/login'; } } /** diff --git a/app/Http/Controllers/DirectoryController.php b/app/Http/Controllers/DirectoryController.php new file mode 100644 index 0000000..c0be76d --- /dev/null +++ b/app/Http/Controllers/DirectoryController.php @@ -0,0 +1,28 @@ +successful()) { + + $apiData = $response->json(); + return response()->json($apiData); + } else { + + $errorData = $response->json(); + return response()->json(['error' => 'API request failed'], $response->status()); + } + } +} diff --git a/resources/views/auth/login.blade.php b/resources/views/auth/login.blade.php index daf8d59..4ee8ab7 100644 --- a/resources/views/auth/login.blade.php +++ b/resources/views/auth/login.blade.php @@ -12,6 +12,12 @@ +
+ + Go back + +
+
@@ -22,7 +28,9 @@
-

Login

+
+

Login

+
@csrf @@ -131,4 +139,4 @@ - + \ No newline at end of file diff --git a/resources/views/clients/adolescents_clients.blade.php b/resources/views/clients/adolescents_clients.blade.php index 0a79448..360a05f 100644 --- a/resources/views/clients/adolescents_clients.blade.php +++ b/resources/views/clients/adolescents_clients.blade.php @@ -6,114 +6,111 @@ @section('main-content') + +
-
+
-
- ADOLESCENT Grouping List -
+
+ ADOLESCENT Grouping List +
-
-
- - - - - - - - - - - - - - - - - @if (count($all_adolescents_clients) > 0) - @foreach($all_adolescents_clients as $result) - - - - - - - - - - - - @endforeach - @endif - + +
+
No.Clinic NumberFirst NameMiddle NameLast NamePhone NoGroupingTreatmentDate Enrolled
{{ $loop->iteration }} {{$result->clinic_number}} {{$result->f_name}} {{$result->m_name}} {{$result->l_name}} {{$result->phone_no}} {{$result->name}} {{$result->client_status}} {{$result->enrollment_date}}
+ + + + + + + + + + + -
No.Clinic NumberFirst NameMiddle NameLast NamePhone NoGroupingTreatmentDate Enrolled
+ + + + @if (count($all_adolescents_clients) > 0) + @foreach($all_adolescents_clients as $result) + + {{ $loop->iteration }} + {{$result->clinic_number}} + {{$result->f_name}} + {{$result->m_name}} + {{$result->l_name}} + {{$result->phone_no}} + {{$result->name}} + {{$result->client_status}} + {{$result->enrollment_date}} + + @endforeach + @endif + -
+ -
-
- + +
+
+
+ @endsection @section('page-js') - - + + -@endsection +@endsection \ No newline at end of file diff --git a/resources/views/directory/search.blade.php b/resources/views/directory/search.blade.php new file mode 100644 index 0000000..5ae30d9 --- /dev/null +++ b/resources/views/directory/search.blade.php @@ -0,0 +1,211 @@ + + + + + + + + + Ushauri - Getting better one text at a time + + + + + + + +
+ +
+
+ Back +
+ +
+

Facility Directory

+
+
+ +
+
+ + +
+ +
+
+ + + +
+
+ + + +
+ + + +
+ + + + + + + + + + + \ No newline at end of file diff --git a/resources/views/landing/page.blade.php b/resources/views/landing/page.blade.php new file mode 100644 index 0000000..1871ab7 --- /dev/null +++ b/resources/views/landing/page.blade.php @@ -0,0 +1,62 @@ + + + + + + + + + Ushauri - Getting better one text at a time + + + + + + + +
+
+

mHealth Applications

+
+ +
+ + + +
+ + +
+ + + + + + \ No newline at end of file diff --git a/routes/web.php b/routes/web.php index 230161f..370cea8 100644 --- a/routes/web.php +++ b/routes/web.php @@ -26,9 +26,15 @@ | */ -Route::get('/', function () { +Route::get('/login', function () { return view('auth/login'); }); +Route::get('/', function () { + return view('landing/page'); +}); +Route::get('/directory', function () { + return view('directory/search'); +}); //SMS Scheduler routes