Добавлена возможность сохранения добавленного пациента

Исправлена инкрементация идентификаторов
This commit is contained in:
brusnitsyn
2026-05-05 21:03:14 +09:00
parent 717641e4bb
commit fe2264dfce
4 changed files with 72 additions and 9 deletions

View File

@@ -20,7 +20,7 @@ const form = ref({
urgency_id: 1,
visit_result_id: 0,
birth_date: null,
recipient_date: new Date(),
recipient_date: format(new Date(), 'yyyy-MM-dd HH:mm:ss'),
death_date: null,
extract_date: null
})
@@ -34,7 +34,7 @@ const resetForm = () => {
urgency_id: 1,
visit_result_id: 0,
birth_date: null,
recipient_date: new Date(),
recipient_date: format(new Date(), 'yyyy-MM-dd HH:mm:ss'),
death_date: null,
extract_date: null
}
@@ -133,6 +133,8 @@ const submit = () => {
buttonLoading.value = false
}
})
}).catch((e) => {
buttonLoading.value = false
})
}
@@ -217,16 +219,16 @@ watch(() => currentStep.value, (val) => {
<NSelect filterable v-model:value="form.visit_result_id" :options="visitResultOptions" />
</NFormItemGi>
<NFormItemGi span="1" label="Дата рождения">
<NDatePicker v-model:value="form.birth_date" class="w-full" format="dd.MM.yyyy" value-format="yyyy-MM-dd" clearable />
<NDatePicker v-model:formatted-value="form.birth_date" class="w-full" format="dd.MM.yyyy" value-format="yyyy-MM-dd" clearable />
</NFormItemGi>
<NFormItemGi span="1" label="Дата и время госпитализации">
<NDatePicker v-model:value="form.recipient_date" type="datetime" class="w-full" format="dd.MM.yyyy HH:mm:ss" value-format="yyyy-MM-dd HH:mm:ss" clearable />
<NDatePicker v-model:formatted-value="form.recipient_date" type="datetime" class="w-full" format="dd.MM.yyyy HH:mm:ss" value-format="yyyy-MM-dd HH:mm:ss" clearable />
</NFormItemGi>
<NFormItemGi span="1" label="Дата и время выписки">
<NDatePicker v-model:value="form.extract_date" type="datetime" class="w-full" format="dd.MM.yyyy HH:mm:ss" value-format="yyyy-MM-dd HH:mm:ss" clearable />
<NDatePicker v-model:formatted-value="form.extract_date" type="datetime" class="w-full" format="dd.MM.yyyy HH:mm:ss" value-format="yyyy-MM-dd HH:mm:ss" clearable />
</NFormItemGi>
<NFormItemGi span="1" label="Дата и время смерти">
<NDatePicker v-model:value="form.death_date" type="datetime" class="w-full" format="dd.MM.yyyy HH:mm:ss" value-format="yyyy-MM-dd HH:mm:ss" clearable />
<NDatePicker v-model:formatted-value="form.death_date" type="datetime" class="w-full" format="dd.MM.yyyy HH:mm:ss" value-format="yyyy-MM-dd HH:mm:ss" clearable />
</NFormItemGi>
</NGrid>
</NTabPane>