wip - edit
This commit is contained in:
parent
31e6fc1085
commit
381f01ff6b
@ -336,7 +336,7 @@ private function generateActionButtons(Study $study): string
|
||||
$btns[] = $this->renderButton($study->hash, 'fa-user-doctor', 'btn-outline-youtube show-assign', 'Assign');
|
||||
break;
|
||||
case WorklistButton::Attachment:
|
||||
// $btns[] = $this->renderButton($study->hash, 'fa-trash', 'btn-danger archive-study', 'Archive');
|
||||
$btns[] = '<a href="' . route('staff.meta.edit', $study->hash) . '" target="_blank" class="btn btn-sm btn-outline-light"><i class="fa-light fa-edit"></i></a>';
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@ -4,8 +4,8 @@
|
||||
|
||||
use App\Domain\ACL\Permission;
|
||||
use App\Http\Controllers\HashidControllerBase;
|
||||
use App\Http\Requests\StudyMetadataUpdateRequest;
|
||||
use App\Models\Study;
|
||||
use Illuminate\Http\Request;
|
||||
|
||||
class MetadataController extends HashidControllerBase
|
||||
{
|
||||
@ -27,8 +27,9 @@ public function edit()
|
||||
return view('staff.meta.edit', compact('study'));
|
||||
}
|
||||
|
||||
public function save(StudyMetadataUpdateRequest $request)
|
||||
public function save(Request $request)
|
||||
{
|
||||
dd($request);
|
||||
abort_unless(auth()->user()->may(Permission::StudyMetadataEdit), 403);
|
||||
$this->decodeKeys();
|
||||
$study = Study::find($this->key);
|
||||
|
@ -38,6 +38,7 @@ protected function casts(): array
|
||||
{
|
||||
return [
|
||||
'properties' => 'array',
|
||||
'dicom_properties' => 'array',
|
||||
'series' => 'array',
|
||||
'assignment_log' => 'array',
|
||||
];
|
||||
|
@ -1,28 +1,68 @@
|
||||
<x-app-layout>
|
||||
<x-slot name="header">
|
||||
<h2 class="font-semibold text-xl text-gray-800 leading-tight">
|
||||
{{ __('Metadata View') }}
|
||||
</h2>
|
||||
</x-slot>
|
||||
@extends('layouts.layoutMaster')
|
||||
|
||||
<div>
|
||||
<div class="max-w-7xl mx-auto py-10 sm:px-6 lg:px-8">
|
||||
@section('title', 'Edit Study')
|
||||
|
||||
<div class="mt-10 sm:mt-0">
|
||||
<h4>Clinical Information</h4>
|
||||
@section('vendor-style')
|
||||
@endsection
|
||||
|
||||
<h5>patient_name</h5>
|
||||
<div class="p-4 border-gray-100">
|
||||
{{ $study->patient_name }}
|
||||
@section('vendor-script')
|
||||
@endsection
|
||||
|
||||
@section('page-script')
|
||||
@endsection
|
||||
|
||||
@section('content')
|
||||
<form action="{{ route('staff.meta.save', $study->hash) }}" method="post">
|
||||
@csrf
|
||||
|
||||
<div class="row">
|
||||
<div class="col-xl">
|
||||
<div class="card mb-6">
|
||||
<div class="card-header d-flex justify-content-between align-items-center">
|
||||
<h5 class="mb-0">Patient Information</h5>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
@include('staff.meta.partials._text', ['name' => 'patient_id', 'label' => 'Patient ID', 'value' => $study->patient_id])
|
||||
@include('staff.meta.partials._text', ['name' => 'patient_name', 'label' => 'Patient Name', 'value' => $study->patient_name])
|
||||
@include('staff.meta.partials._text', ['name' => 'patient_sex', 'label' => 'Sex', 'value' => $study->patient_sex])
|
||||
<div class="form-floating form-floating-outline mb-6">
|
||||
<input type="text" name="patient_birthdate" id="patient_birthdate" class="form-control dob-picker" placeholder="YYYY-MM-DD" value="{{ $study->patient_birthdate->toDateString() }}" />
|
||||
<label for="patient_birthdate">Birth Date</label>
|
||||
</div>
|
||||
@include('staff.meta.partials._text', ['name' => 'accession_number', 'label' => 'Accession number', 'value' => $study->accession_number])
|
||||
</div>
|
||||
</div>
|
||||
<x-section-border/>
|
||||
</div>
|
||||
|
||||
@if (may(\App\Domain\ACL\Permission::StudyMetadataEdit))
|
||||
<a class="btn btn-sm" href="{{ route('staff.meta.edit', $study->hash) }}">Edit</a>
|
||||
@endif
|
||||
<div class="col-xl">
|
||||
<div class="card mb-6">
|
||||
<div class="card-header d-flex justify-content-between align-items-center">
|
||||
<h5 class="mb-0">Study Information</h5>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
@include('staff.meta.partials._text', ['name' => 'study_description', 'label' => 'Study Description', 'value' => $study->study_description])
|
||||
@include('staff.meta.partials._text', ['name' => 'body_part_examined', 'label' => 'Body Part Examined', 'value' => $study->body_part_examined])
|
||||
@include('staff.meta.partials._text', ['name' => 'institution_name', 'label' => 'Institution', 'value' => $study->institution_name])
|
||||
@include('staff.meta.partials._text', ['name' => 'referring_physician_name', 'label' => 'Referring Physician', 'value' => $study->referring_physician_name])
|
||||
|
||||
<label class="form-check-label">Priority</label>
|
||||
<div class="col my-2">
|
||||
@include('staff.meta.partials._check', ['name' => 'priority', 'id' => 'pri_0', 'label' => 'Low', 'value' => \App\Domain\Study\Priority::Low->value, 'checked' => $study->priority->value == \App\Domain\Study\Priority::Low->value])
|
||||
@include('staff.meta.partials._check', ['name' => 'priority', 'id' => 'pri_1', 'label' => 'Routine', 'value' => \App\Domain\Study\Priority::Routine->value, 'checked' => $study->priority->value == \App\Domain\Study\Priority::Routine->value])
|
||||
@include('staff.meta.partials._check', ['name' => 'priority', 'id' => 'pri_2', 'label' => 'High', 'value' => \App\Domain\Study\Priority::High->value, 'checked' => $study->priority->value == \App\Domain\Study\Priority::High->value])
|
||||
@include('staff.meta.partials._check', ['name' => 'priority', 'id' => 'pri_3', 'label' => 'Stat', 'value' => \App\Domain\Study\Priority::Stat->value, 'checked' => $study->priority->value == \App\Domain\Study\Priority::Stat->value])
|
||||
</div>
|
||||
|
||||
<label class="form-check m-0">
|
||||
<input name="cancel_read" type="checkbox" class="form-check-input" />
|
||||
<span class="form-check-label">Cancel interpretation by radiologist</span>
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</x-app-layout>
|
||||
|
||||
<button type="submit" class="btn btn-primary">Save</button>
|
||||
</form>
|
||||
@endsection
|
||||
|
4
resources/views/staff/meta/partials/_check.blade.php
Normal file
4
resources/views/staff/meta/partials/_check.blade.php
Normal file
@ -0,0 +1,4 @@
|
||||
<div class="form-check form-check-inline">
|
||||
<input name="{{ $name }}" class="form-check-input" type="radio" value="{{ $value }}" id="{{ $name }}" @if ($checked) checked @endif />
|
||||
<label class="form-check-label" for="{{ $name }}">{{ $label }}</label>
|
||||
</div>
|
4
resources/views/staff/meta/partials/_text.blade.php
Normal file
4
resources/views/staff/meta/partials/_text.blade.php
Normal file
@ -0,0 +1,4 @@
|
||||
<div class="form-floating form-floating-outline mb-6">
|
||||
<input type="text" class="form-control" name="{{ $name }}" id="{{ $name }}" value="{{ $value }}"/>
|
||||
<label for="{{ $name }}">{{ $label }}</label>
|
||||
</div>
|
@ -2,7 +2,6 @@
|
||||
|
||||
use App\Http\Controllers\Api\WorklistController as ApiWorklistController;
|
||||
use App\Http\Controllers\Guest\ViewSharedStudyController;
|
||||
use App\Http\Controllers\Radiologist\ReportWriteController;
|
||||
use App\Http\Controllers\SocialLoginController;
|
||||
use App\Http\Controllers\Staff\AssignmentController;
|
||||
use App\Http\Controllers\Staff\AttachmentController;
|
||||
@ -39,10 +38,6 @@
|
||||
Route::get('studies', [ApiWorklistController::class, 'studies'])->name('studies');
|
||||
});
|
||||
|
||||
Route::group(['prefix' => 'radiologist', 'as' => 'radiologist.'], function () {
|
||||
Route::get('report-write/{id}', ReportWriteController::class)->name('report-write');
|
||||
});
|
||||
|
||||
Route::group(['prefix' => 'viewer', 'as' => 'viewer.'], function () {
|
||||
Route::get('stone/{hashid}', [DicomViewerController::class, 'stone'])->name('stone');
|
||||
Route::get('ohif/{hashid}', [DicomViewerController::class, 'ohif'])->name('ohif');
|
||||
|
Loading…
Reference in New Issue
Block a user