-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add workSchedule for doctor: ver 0.0.1 alpha is finished :D
- Loading branch information
Showing
7 changed files
with
100 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
<?php | ||
|
||
namespace App\View\Components\Doctor; | ||
|
||
use App\Enums\ApplicationStatus; | ||
use App\Models\Application; | ||
use Illuminate\Support\Facades\DB; | ||
use Illuminate\View\Component; | ||
|
||
class Index extends Component | ||
{ | ||
public $allPatients; | ||
|
||
/** | ||
* Create a new component instance. | ||
* | ||
* @return void | ||
*/ | ||
public function __construct() | ||
{ | ||
$this->allPatients = | ||
Application:: | ||
selectRaw("COUNT(date_vaccination) as HOW_MANY,date(date_vaccination) as DATE_VACCINATION") | ||
->where('status', ApplicationStatus::PENDING) | ||
->where('doctor_id', auth()->user()->id) | ||
->groupBy(DB::raw('Date(date_vaccination)')) | ||
->orderBy('date_vaccination','ASC') | ||
->get(); | ||
} | ||
|
||
/** | ||
* Get the view / contents that represent the component. | ||
* | ||
* @return \Illuminate\Contracts\View\View|\Closure|string | ||
*/ | ||
public function render() | ||
{ | ||
return view('components.doctor.index'); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
table { | ||
margin: 5% 25% 0 25%; | ||
border-top: 1px solid black; | ||
border-left: 1px solid black; | ||
} | ||
|
||
table th, table td { | ||
text-align: center; | ||
padding: 15px; | ||
border-bottom: 1px solid black; | ||
border-right: 1px solid black; | ||
font-size: 2rem; | ||
} | ||
|
||
table th { | ||
color: rgba(255, 255, 255, 0.75); | ||
background-color: rgb(91, 162, 244); | ||
} | ||
|
||
table tr { | ||
background-color: rgba(201, 187, 170, 0.5) | ||
} | ||
|
||
table tr:nth-child(2n) { | ||
background-color: rgba(113, 128, 150, 0.5); | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
<link rel="stylesheet" href="{{ asset('css/workSchedule.css') }}"> | ||
|
||
<table> | ||
<tr> | ||
<th> DATA </th> | ||
<th> LICZBA CHĘTNYCH DO SZCZEPIENIA</th> | ||
</tr> | ||
@foreach($allPatients as $patient) | ||
<tr> | ||
<td> {{ $patient->DATE_VACCINATION }}</td> | ||
<td> {{ $patient->HOW_MANY }}</td> | ||
</tr> | ||
@endforeach | ||
</table> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
<x-layout> | ||
|
||
<x-layout.navigation> </x-layout.navigation> | ||
|
||
<x-doctor.index> </x-doctor.index> | ||
|
||
</x-layout> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters