fan 2 лет назад
Родитель
Сommit
ba1b7f28cf

+ 12 - 6
src/components/XTList/src/List.vue

@@ -9,9 +9,8 @@
       :style="{ width: width + 'px', height: height + 'px' }"
       v-for="item in data"
       :key="item.id"
-      @click="handleClick(item)"
     >
-      <div class="menu-item_left">
+      <div class="menu-item_left" @click="handleClick(item)">
         <div class="menu-item_left-t">{{ item.title }}</div>
         <div class="menu-item_left-b">
           <span v-if="item.startTime">
@@ -28,7 +27,7 @@
           {{ item.status }}
         </div>
         <div class="menu-item_right-t" v-if="item.attachment">
-          <i class="iconfont icon-attachemnt" />
+          <i class="iconfont icon-xt-details-annex iconfont-attachment" />
           {{ item.attachment }}
         </div>
         <div class="menu-item_right-b">
@@ -85,17 +84,17 @@
     width: 445,
     height: 82,
   });
-  const emit = defineEmits(['itemClick']);
+  const emit = defineEmits(['itemClick', 'edit', 'delete']);
   function handleClick(data) {
     emit('itemClick', data);
   }
   // 编辑
   function handleEdit(data) {
-    console.log('🚀 ~ file: handleEdit List.vue:70 ~ data:', data);
+    emit('edit', data);
   }
   // 删除
   function handleDel(data) {
-    console.log('🚀 ~ file: handleDel List.vue:74 ~ data:', data);
+    emit('delete', data);
   }
 </script>
 
@@ -128,6 +127,13 @@
 
         &-t {
           margin-bottom: 6px;
+          display: inline-flex;
+          align-items: center;
+
+          .iconfont {
+            font-size: 14px;
+            margin-right: 2px;
+          }
         }
 
         &-btn {

+ 1 - 1
src/views/biz/archives/detail/data.ts

@@ -7,7 +7,7 @@ export const BasicTab = [
   { key: 'patrolward', value: 5, title: '查房记录' },
   { key: 'patientBasic5', value: 6, title: '诊断记录' },
   { key: 'patientBasic6', value: 7, title: '化验项' },
-  { key: 'patientBasic7', value: 8, title: '医疗文书' },
+  { key: 'medicalDocuments', value: 8, title: '医疗文书' },
   { key: 'patientReturn', value: 9, title: '转归' },
   { key: 'patientBasic9', value: 10, title: '个人评估' },
 ];

+ 15 - 1
src/views/biz/archives/detail/index.vue

@@ -5,7 +5,12 @@
     </div>
     <div class="py-2 bg-white">
       <a-tabs v-model:activeKey="activeKey" :destroyInactiveTabPane="true">
-        <a-tab-pane v-for="item in tabData" :key="item.key" :tab="item.title">
+        <a-tab-pane
+          v-for="item in tabData"
+          :key="item.key"
+          :tab="item.title"
+          :class="'tab-' + item.key"
+        >
           <!-- 基础病历 0 -->
           <div v-if="item.value == 0 && info.id">
             <PatientBasic :info="info" />
@@ -26,6 +31,10 @@
           <div v-if="item.value == 6 && info.id">
             <DiagnosisHistory :info="info" />
           </div>
+          <!-- 医疗文书 8 -->
+          <div v-if="item.value == 8 && info.id">
+            <MedicalDocuments :info="info" />
+          </div>
           <!-- 转归 9 -->
           <div v-if="item.value == 9 && info.id">
             <PatientReturn :info="info" />
@@ -45,6 +54,7 @@
   import Patrolward from '../patrolward/index.vue';
   import DiagnosisHistory from '../diagnosisHistory/index.vue';
   import PatientReturn from '../patientReturn/index.vue';
+  import MedicalDocuments from '../medicalDocuments/index.vue';
   import { useRoute } from 'vue-router';
   import { XTTitle } from '/@/components/XTTitle/index';
 
@@ -70,4 +80,8 @@
   ::v-deep(.ant-tabs-tabpane) {
     padding: 12px;
   }
+
+  .tab-medicalDocuments {
+    padding: 0;
+  }
 </style>

+ 5 - 0
src/views/biz/archives/diagnosisHistory/data.ts

@@ -102,6 +102,7 @@ export const columnsAllergic: BasicColumn[] = [
         showSearch: true,
         placeholder: '请选择',
         getPopupContainer: () => document.body,
+        filterOption: false,
       };
     },
   },
@@ -197,6 +198,8 @@ export const columnsContagious: BasicColumn[] = [
       },
       placeholder: '请选择',
       getPopupContainer: () => document.body,
+      filterOption: false,
+      showSearch: false,
     },
   },
   {
@@ -294,6 +297,8 @@ export const columnsMulti: BasicColumn[] = [
         options: record.typeOptions,
         placeholder: '请选择',
         getPopupContainer: () => document.body,
+        filterOption: false,
+        showSearch: false,
         // 尽量不要在 此处使用 onChange,不然会有 warning 错误
         // onChange: async data => {
         //   console.log('🚀 ~ onChange file: data.ts:99 ~ data:', data);

+ 1 - 0
src/views/biz/bed/memo/data.ts

@@ -51,6 +51,7 @@ export const dataFormSchema: FormSchema[] = [
         api: archivesPatientBasicQueryPage,
         params: {
           name: formModel.patientBasicName,
+          pageSize: 999,
         },
         labelField: 'name',
         valueField: 'id',

+ 33 - 0
src/views/biz/bed/person/FormModalDetail.vue

@@ -0,0 +1,33 @@
+<template>
+  <BasicModal
+    v-bind="$attrs"
+    destroyOnClose
+    @register="registerModal"
+    :title="getTitle"
+    :width="width"
+    :showOkBtn="false"
+    :showCancelBtn="true"
+    :showFooter="true"
+  >
+    <div class="!px-6 !pt-4">详情{{ tableData }}</div>
+  </BasicModal>
+</template>
+<script lang="ts" setup>
+  import { ref } from 'vue';
+  import { BasicModal, useModalInner } from '/@/components/Modal';
+  // import { useMessage } from '/@/hooks/web/useMessage';
+  import { bedScheduledPersonDetail } from '/@/api/biz/bed/scheduledPersonApi';
+  const getTitle = ref();
+  const width = '45%';
+  const tableData = ref(null);
+
+  // const { createMessage } = useMessage();
+
+  const [registerModal, { setModalProps }] = useModalInner(async data => {
+    setModalProps({ confirmLoading: false });
+    getTitle.value = `排班详情 ( ${data.record.patientName} | ${data.record.gender} | ${data.record.age}岁 )`;
+    const resData = await bedScheduledPersonDetail(data.record.id);
+    console.log('🚀 ~ file: FormModalDetail.vue:29 ~ resData:', resData);
+    tableData.value = resData;
+  });
+</script>

+ 1 - 0
src/views/biz/bed/person/data.ts

@@ -130,6 +130,7 @@ export const columns: BasicColumn[] = [
     dataIndex: 'specialNeed',
     align: 'left',
     // width: 300,
+    ellipsis: true,
   },
 ];
 

+ 17 - 7
src/views/biz/bed/person/index.vue

@@ -5,7 +5,7 @@
       <div class="flex justify-between my-4">
         <XTTab
           type="illness"
-          :width="158"
+          :width="170"
           :selected="activeKey"
           :data="tabData"
           @item-click="callTab"
@@ -14,9 +14,9 @@
       </div>
       <BasicTable @register="registerTable">
         <template #bodyCell="{ column, record }">
-          <template v-if="column.key === 'name'">
+          <template v-if="column.key === 'patientName'">
             <span :class="['table-dot', 'table-dot--' + record.status]" />
-            <span>{{ record.name }}</span>
+            <span>{{ record.patientName }}</span>
           </template>
           <template v-if="column.key === 'patientGender'">
             <span
@@ -82,17 +82,17 @@
             <TableAction
               :actions="[
                 {
-                  auth: 'sys:log:query',
+                  auth: 'bed:scheduledPerson:edit',
                   icon: 'icon-xt-details_edit_default|iconfont',
                   tooltip: '编辑',
                   onClick: handleEdit.bind(null, record),
                 },
                 {
-                  auth: 'sys:log:query',
+                  auth: 'bed:scheduledPerson:query',
                   disabled: !record.frequency,
                   icon: 'icon-xt-bed_default|iconfont',
                   tooltip: '排班',
-                  onClick: handleEdit.bind(null, record),
+                  onClick: handleDetail.bind(null, record),
                 },
                 // {
                 //   auth: 'sys:log:query',
@@ -111,6 +111,7 @@
       </BasicTable>
     </div>
     <FormModal @register="registerModal" @success="callSuccess" />
+    <FormModalDetail @register="registerModalDetail" @success="callSuccess" />
   </div>
 </template>
 
@@ -131,6 +132,7 @@
   import { onMounted, reactive } from 'vue';
   import { useModal } from '/@/components/Modal';
   import FormModal from './FormModal.vue';
+  import FormModalDetail from './FormModalDetail.vue';
   // import { useMessage } from '@/hooks/web/useMessage';
   const bizDictOptions = reactive<any>({});
   const bizDictData = ref([
@@ -141,6 +143,7 @@
   const activeKey = ref(BasicTabActive);
   const tabData = ref(BasicTab);
   const [registerModal, { openModal }] = useModal();
+  const [registerModalDetail, { openModal: openModalDetail }] = useModal();
   // const { createMessage } = useMessage();
 
   onMounted(async () => {
@@ -209,7 +212,7 @@
   function handleBeforeFetch(params) {
     return {
       ...params,
-      // queryType: activeKey.value == '0' ? '0' : activeKey.value,
+      queryType: activeKey.value == '0' ? '0' : activeKey.value,
       patientName: formValue.patientName,
       orders: [{ field: formValue.tableSort, direction: 'DESC' }],
     };
@@ -242,6 +245,13 @@
       record,
     });
   }
+  function handleDetail(record: Recordable) {
+    console.log('🚀 ~ file: index.vue:206 ~ handleView ~ record:', record);
+    record.gender = formatDictValue(bizDictOptions.gender, record.patientGender);
+    openModalDetail(true, {
+      record,
+    });
+  }
   // 删除按钮事件
   // async function handleDelete(record: Recordable) {
   //   await bedScheduledPersonRemove([record.id]);