Add nursing assessment packs, ward board, and nurse performance KPIs.
Deploy Ladill Care / deploy (push) Successful in 55s
Deploy Ladill Care / deploy (push) Successful in 55s
Seeds NEWS2/Braden/Morse/pain packs with visit vitals and a unit dashboard for MAR, assessments, notes, and handover activity. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -3,6 +3,7 @@
|
||||
namespace App\Services\Care;
|
||||
|
||||
use App\Models\AssessmentTemplate;
|
||||
use App\Models\ClinicalPathway;
|
||||
use App\Models\Organization;
|
||||
use Database\Seeders\AssessmentTemplateSeeder;
|
||||
use Database\Seeders\ClinicalPathwaySeeder;
|
||||
@@ -72,16 +73,24 @@ class CareFeatures
|
||||
return;
|
||||
}
|
||||
|
||||
if (AssessmentTemplate::query()->whereNull('organization_id')->exists()) {
|
||||
return;
|
||||
$nursingCodes = ['news2', 'braden', 'morse', 'pain_nrs'];
|
||||
$haveNursing = AssessmentTemplate::query()
|
||||
->whereNull('organization_id')
|
||||
->whereIn('code', $nursingCodes)
|
||||
->where('is_current', true)
|
||||
->count();
|
||||
|
||||
$empty = ! AssessmentTemplate::query()->whereNull('organization_id')->exists();
|
||||
|
||||
if ($empty || $haveNursing < count($nursingCodes)) {
|
||||
Artisan::call('db:seed', [
|
||||
'--class' => AssessmentTemplateSeeder::class,
|
||||
'--force' => true,
|
||||
]);
|
||||
}
|
||||
|
||||
Artisan::call('db:seed', [
|
||||
'--class' => AssessmentTemplateSeeder::class,
|
||||
'--force' => true,
|
||||
]);
|
||||
|
||||
if (Schema::hasTable('care_clinical_pathways')) {
|
||||
if (Schema::hasTable('care_clinical_pathways')
|
||||
&& ! ClinicalPathway::query()->whereNull('organization_id')->exists()) {
|
||||
Artisan::call('db:seed', [
|
||||
'--class' => ClinicalPathwaySeeder::class,
|
||||
'--force' => true,
|
||||
|
||||
Reference in New Issue
Block a user