Добавил реанимацию
Правки окна операций
This commit is contained in:
@@ -16,6 +16,7 @@ import TooltipColumn from "./Components/DataTableColumns/TooltipColumn.vue";
|
||||
import ActionsColumn from "./Components/DataTableColumns/ActionsColumn.vue";
|
||||
import OperationsColumn from "./Components/DataTableColumns/OperationsColumn.vue";
|
||||
import ReportWidget from "./Components/ReportWidget.vue";
|
||||
import OperationInfoModal from "./Components/OperationInfoModal.vue";
|
||||
|
||||
const props = defineProps({
|
||||
department: {
|
||||
@@ -63,6 +64,10 @@ const props = defineProps({
|
||||
type: Object,
|
||||
default: { data: [] }
|
||||
},
|
||||
reanimationHistories: {
|
||||
type: Object,
|
||||
default: { data: [] }
|
||||
},
|
||||
dates: {
|
||||
type: Array,
|
||||
default: []
|
||||
@@ -73,6 +78,8 @@ const reportStore = useReportStore()
|
||||
const authStore = useAuthStore()
|
||||
const userDepartment = authStore.userDepartment
|
||||
const loading = ref(false)
|
||||
const operationsInModal = ref(null)
|
||||
const showOperationsModal = ref(false)
|
||||
|
||||
const columns = [
|
||||
{
|
||||
@@ -116,7 +123,7 @@ const columns = [
|
||||
key: 'latest_migration.operations',
|
||||
width: 140,
|
||||
className: 'relative',
|
||||
render: (row) => h(OperationsColumn, { operations: row.latest_migration.operations })
|
||||
render: (row) => h(OperationsColumn, { operations: row.latest_migration.operations, onClick: (operations) => onShowOperationsModal(operations) })
|
||||
},
|
||||
{
|
||||
title: '',
|
||||
@@ -134,6 +141,11 @@ const columns = [
|
||||
}
|
||||
]
|
||||
|
||||
const onShowOperationsModal = (operations) => {
|
||||
operationsInModal.value = operations
|
||||
showOperationsModal.value = true
|
||||
}
|
||||
|
||||
const syncPageProps = () => reportStore.initializeFromPage(props)
|
||||
|
||||
onMounted(syncPageProps)
|
||||
@@ -199,8 +211,8 @@ watch(() => props, (newProps) => {
|
||||
<PatientTypeSectionItem label="Находятся на контроле" :counter="recipientHistories.data.length">
|
||||
<PatientDataTable :data="recipientHistories.data" :columns="columns" />
|
||||
</PatientTypeSectionItem>
|
||||
<PatientTypeSectionItem label="Находятся в реанимации" :counter="recipientHistories.data.length">
|
||||
<PatientDataTable :data="recipientHistories.data" :columns="columns" />
|
||||
<PatientTypeSectionItem label="Находятся в реанимации" :counter="reanimationHistories.data.length">
|
||||
<PatientDataTable :data="reanimationHistories.data" :columns="columns" />
|
||||
</PatientTypeSectionItem>
|
||||
<PatientTypeSectionItem label="Выбывшие" :counter="dischargedHistories.data.length + deceasedHistories.data.length">
|
||||
<NTabs type="segment" animated>
|
||||
@@ -247,4 +259,5 @@ watch(() => props, (newProps) => {
|
||||
</AppPanel>
|
||||
</AppContainer>
|
||||
</AppLayout>
|
||||
<OperationInfoModal :operations="operationsInModal" v-model:show="showOperationsModal" />
|
||||
</template>
|
||||
|
||||
Reference in New Issue
Block a user