Изменил привязку id при добавлении пациента

Изменил приоритет вывода карты после репликации
This commit is contained in:
brusnitsyn
2026-06-03 12:42:17 +09:00
parent c857bd9f72
commit e758769035
8 changed files with 154 additions and 41 deletions

View File

@@ -4,7 +4,7 @@ import {computed, ref, watch} from "vue";
import AppRadio from "../../../Components/AppRadio.vue";
import {useDebounceFn} from "@vueuse/core";
import {format} from "date-fns";
import {router} from "@inertiajs/vue3";
import {router, usePage} from "@inertiajs/vue3";
import AppPanel from "../../../Components/AppPanel.vue"
const show = defineModel('show', { default: false })
@@ -23,7 +23,8 @@ const form = ref({
birth_date: null,
recipient_date: format(new Date(), 'yyyy-MM-dd HH:mm:ss'),
death_date: null,
extract_date: null
extract_date: null,
mis_id: null
})
const resetForm = () => {
@@ -37,7 +38,8 @@ const resetForm = () => {
birth_date: null,
recipient_date: format(new Date(), 'yyyy-MM-dd HH:mm:ss'),
death_date: null,
extract_date: null
extract_date: null,
mis_id: null
}
}
@@ -116,7 +118,9 @@ const next = () => {
const submit = () => {
buttonLoading.value = true
axios.post('/api/nurse/patients', {
const departmentId = usePage().props.selectedDepartmentId
const userId = usePage().props.selectedUserId
axios.post(`/api/nurse/patients?departmentId=${departmentId}&userId=${userId}`, {
...form.value
}).then(res => {
router.reload({
@@ -216,7 +220,7 @@ const onAfterLeave = () => {
<AppPanel :loading="loadingChangeSelect" class="border-none!" no-padding>
<NGrid cols="2" x-gap="8">
<NFormItemGi v-if="form.patient_source === 'mis'" span="2" label="Поиск пациента">
<NSelect v-model:value="form.id"
<NSelect v-model:value="form.mis_id"
filterable
placeholder="Найти пациента по ФИО"
remote