wip
This commit is contained in:
parent
d5a30a79ea
commit
01a2868adb
@ -5,6 +5,7 @@
|
|||||||
use App\DAL\Radiologists;
|
use App\DAL\Radiologists;
|
||||||
use App\Http\Controllers\HashidControllerBase;
|
use App\Http\Controllers\HashidControllerBase;
|
||||||
use App\Http\Requests\AssignPhysicianRequest;
|
use App\Http\Requests\AssignPhysicianRequest;
|
||||||
|
use App\Models\Enums\ReportStatus;
|
||||||
use App\Models\Enums\UserRole;
|
use App\Models\Enums\UserRole;
|
||||||
use App\Models\Study;
|
use App\Models\Study;
|
||||||
use App\Models\User;
|
use App\Models\User;
|
||||||
@ -18,12 +19,12 @@ public function show()
|
|||||||
$this->decodeKeys();
|
$this->decodeKeys();
|
||||||
$study = Study::with('assignedPhysician')->findOrFail($this->key);
|
$study = Study::with('assignedPhysician')->findOrFail($this->key);
|
||||||
$rads = User::active()->role(UserRole::Radiologist)->get(['id', 'display_name', 'profile_photo_path', 'first_name', 'last_name', 'created_at']);
|
$rads = User::active()->role(UserRole::Radiologist)->get(['id', 'display_name', 'profile_photo_path', 'first_name', 'last_name', 'created_at']);
|
||||||
$stats = Radiologists::worklist_stats();
|
$stats = Radiologists::worklist_stats(3, ReportStatus::Finalized->value);
|
||||||
foreach ($stats as $rad) {
|
foreach ($stats as $rad) {
|
||||||
$found = $rads->where('id', $rad->id)->first();
|
$found = $rads->where('id', $rad->id)->first();
|
||||||
if ($found) {
|
if ($found) {
|
||||||
$found->info['workload'] = $rad->workload;
|
$found->info['workload'] = $rad->workload;
|
||||||
$found->info['last_seen'] = 'Seen: ' . ($rad->last_seen ?? Carbon::now()->addHours(-10))->diffForHumans();
|
$found->info['last_seen'] = ($rad->last_seen ?? Carbon::now()->addHours(-10))->diffForHumans();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -7,3 +7,13 @@
|
|||||||
width: $badge-width;
|
width: $badge-width;
|
||||||
@include font-size($badge-font-size);
|
@include font-size($badge-font-size);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
.badge-tiny {
|
||||||
|
min-width: 1.8em;
|
||||||
|
padding: .25em !important;
|
||||||
|
margin-left: .1em;
|
||||||
|
margin-right: .1em;
|
||||||
|
color: white !important;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
@ -11,6 +11,7 @@
|
|||||||
$active-border: null
|
$active-border: null
|
||||||
) {
|
) {
|
||||||
}
|
}
|
||||||
|
|
||||||
@mixin template-button-variant(
|
@mixin template-button-variant(
|
||||||
$parent,
|
$parent,
|
||||||
$background,
|
$background,
|
||||||
@ -49,6 +50,7 @@
|
|||||||
@include gradient-bg($background);
|
@include gradient-bg($background);
|
||||||
border-color: $border;
|
border-color: $border;
|
||||||
@include box-shadow($btn-box-shadow);
|
@include box-shadow($btn-box-shadow);
|
||||||
|
|
||||||
&:hover {
|
&:hover {
|
||||||
color: $hover-color !important;
|
color: $hover-color !important;
|
||||||
@include gradient-bg($hover-background !important);
|
@include gradient-bg($hover-background !important);
|
||||||
@ -130,6 +132,7 @@
|
|||||||
|
|
||||||
#{$parent} {
|
#{$parent} {
|
||||||
color: $label-color !important;
|
color: $label-color !important;
|
||||||
|
|
||||||
&.waves-effect {
|
&.waves-effect {
|
||||||
.waves-ripple {
|
.waves-ripple {
|
||||||
background: radial-gradient(
|
background: radial-gradient(
|
||||||
@ -232,6 +235,7 @@
|
|||||||
color: $label-color;
|
color: $label-color;
|
||||||
border-color: $label-background;
|
border-color: $label-background;
|
||||||
background: $label-background;
|
background: $label-background;
|
||||||
|
|
||||||
&.waves-effect {
|
&.waves-effect {
|
||||||
.waves-ripple {
|
.waves-ripple {
|
||||||
background: radial-gradient(
|
background: radial-gradient(
|
||||||
@ -267,6 +271,7 @@
|
|||||||
background-image: if($enable-gradients, none !important, null);
|
background-image: if($enable-gradients, none !important, null);
|
||||||
border-color: $active-background !important;
|
border-color: $active-background !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
&.disabled,
|
&.disabled,
|
||||||
&:disabled {
|
&:disabled {
|
||||||
color: $label-color !important;
|
color: $label-color !important;
|
||||||
@ -324,6 +329,7 @@
|
|||||||
color: $color;
|
color: $color;
|
||||||
border-color: $border-color;
|
border-color: $border-color;
|
||||||
background: transparent;
|
background: transparent;
|
||||||
|
|
||||||
&.waves-effect {
|
&.waves-effect {
|
||||||
.waves-ripple {
|
.waves-ripple {
|
||||||
background: radial-gradient(
|
background: radial-gradient(
|
||||||
@ -381,3 +387,10 @@
|
|||||||
color: color-contrast($color-hover);
|
color: color-contrast($color-hover);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.btn-group-xs > .btn, .btn-xs {
|
||||||
|
padding: 1px 5px;
|
||||||
|
font-size: 12px;
|
||||||
|
line-height: 1.4;
|
||||||
|
border-radius: 3px;
|
||||||
|
}
|
||||||
|
@ -1,27 +1,46 @@
|
|||||||
<div class="row mb-2">
|
@php
|
||||||
<div class="col-4">
|
$label = isset($study->assignedPhysician) ? 'Re-assign': 'Assign';
|
||||||
Currently assigned: {{ $study->assignedPhysician?->display_name }}
|
$color = isset($study->assignedPhysician) ? 'btn-instagram': 'btn-primary';
|
||||||
</div>
|
@endphp
|
||||||
<div class="col-2">
|
<div class="row mb-2 text-nowrap">
|
||||||
|
<table class="table table-borderless table-sm">
|
||||||
|
<tr>
|
||||||
|
<td>Patient ID</td>
|
||||||
|
<td class="fw-semibold">{{ $study->patient_id }}</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>Patient Name</td>
|
||||||
|
<td class="fw-semibold">{{ $study->patient_name }}</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>Currently assigned</td>
|
||||||
|
<td>
|
||||||
@isset($study->assignedPhysician)
|
@isset($study->assignedPhysician)
|
||||||
|
<div class="d-inline-flex">
|
||||||
|
<span class="fw-semibold me-4">{{ $study->assignedPhysician?->display_name }}</span>
|
||||||
<form action="{{ route('staff.assign.remove', $study->hash) }}" class="inline" method="post">
|
<form action="{{ route('staff.assign.remove', $study->hash) }}" class="inline" method="post">
|
||||||
@csrf
|
@csrf
|
||||||
@method('DELETE')
|
@method('DELETE')
|
||||||
<button class="btn btn-danger btn-xs" type="submit">Remove</button>
|
<button class="btn btn-danger btn-xs" type="submit">
|
||||||
|
<i class="fa-light fa-user-slash me-2"></i>
|
||||||
|
Remove
|
||||||
|
</button>
|
||||||
</form>
|
</form>
|
||||||
|
</div>
|
||||||
@endisset
|
@endisset
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
<div class="col-2">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<table class="table table-sm">
|
<table class="table table-sm">
|
||||||
<thead>
|
<tr class="fw-light">
|
||||||
<tr>
|
<td>Physician</td>
|
||||||
<th>Physician</th>
|
<td>Workload</td>
|
||||||
<th>Workload</th>
|
<td> </td>
|
||||||
<th> </th>
|
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
|
|
||||||
@foreach ($rads as $doc)
|
@foreach ($rads as $doc)
|
||||||
<tr>
|
<tr>
|
||||||
@ -36,10 +55,13 @@
|
|||||||
<span class="text-truncate fw-semibold mb-0">
|
<span class="text-truncate fw-semibold mb-0">
|
||||||
{{ $doc->display_name }}
|
{{ $doc->display_name }}
|
||||||
@if ($study->isAssigned($doc->id))
|
@if ($study->isAssigned($doc->id))
|
||||||
<span class="badge bg-success badge-dot ms-2"></span>
|
<span class="badge bg-danger badge-dot ms-1"></span>
|
||||||
@endif
|
@endif
|
||||||
</span>
|
</span>
|
||||||
<small class="text-truncate fw-light text-muted">{{ $doc->info['last_seen'] }}</small>
|
<small class="text-truncate fw-light text-muted">
|
||||||
|
<i class="fa-light fa-wave-pulse me-2"></i>
|
||||||
|
{{ $doc->info['last_seen'] }}
|
||||||
|
</small>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
@ -52,7 +74,10 @@
|
|||||||
<form action="{{ route('staff.assign.save', $study->hash) }}" class="inline" method="post">
|
<form action="{{ route('staff.assign.save', $study->hash) }}" class="inline" method="post">
|
||||||
@csrf
|
@csrf
|
||||||
<input type="hidden" name="rad_id" value="{{ $doc->id }}">
|
<input type="hidden" name="rad_id" value="{{ $doc->id }}">
|
||||||
<button class="btn btn-primary btn-xs" type="submit">Assign</button>
|
<button class="btn {{ $color }} btn-xs" type="submit">
|
||||||
|
<i class="fa-light fa-user-check me-2"></i>
|
||||||
|
{{ $label }}
|
||||||
|
</button>
|
||||||
</form>
|
</form>
|
||||||
@endif
|
@endif
|
||||||
</td>
|
</td>
|
||||||
|
Loading…
Reference in New Issue
Block a user