feature: Simulation Control Center (Dashboard)
This commit is contained in:
@@ -9,6 +9,7 @@ import {
|
||||
patientRoom,
|
||||
stalenessClass,
|
||||
} from '@/composables/wardFormat'
|
||||
import { isSimulatedPatient } from '@/api/normalize'
|
||||
|
||||
const props = defineProps({ patient: { type: Object, required: true } })
|
||||
|
||||
@@ -23,8 +24,10 @@ const vitalsStaleness = computed(() =>
|
||||
observationStaleness(props.patient.lastObservationAt, props.patient.status),
|
||||
)
|
||||
|
||||
const simulated = computed(() => isSimulatedPatient(props.patient))
|
||||
|
||||
const cardLabel = computed(() =>
|
||||
`Patient ${props.patient.firstName} ${props.patient.lastName}, room ${patientRoom(props.patient)}`,
|
||||
`Patient ${props.patient.firstName} ${props.patient.lastName}, room ${patientRoom(props.patient)}${simulated.value ? ', simulated' : ''}`,
|
||||
)
|
||||
|
||||
const emit = defineEmits(['activate'])
|
||||
@@ -53,6 +56,13 @@ function onKeydown(event) {
|
||||
Room {{ patientRoom(patient) }}
|
||||
</span>
|
||||
<Badge v-if="patient.sepsisActive" variant="critical" size="xs">Sepsis</Badge>
|
||||
<span
|
||||
v-if="simulated"
|
||||
class="inline-flex items-center rounded px-1.5 py-0.5 text-[10px] font-bold uppercase tracking-wide bg-amber-100 text-amber-900 dark:bg-amber-900/40 dark:text-amber-200"
|
||||
title="Simulated patient"
|
||||
>
|
||||
SIM
|
||||
</span>
|
||||
</div>
|
||||
<h3 class="mt-2 truncate text-base font-semibold text-gray-900 dark:text-white">
|
||||
{{ patient.firstName }} {{ patient.lastName }}
|
||||
|
||||
Reference in New Issue
Block a user