xiaochan hai 1 ano
pai
achega
bdcce0d324

+ 131 - 0
src/components/zhu-yuan-yi-sheng/emr/auxiliary-tools/BloodSugar.vue

@@ -0,0 +1,131 @@
+<script setup lang="ts">
+import {onMounted, Ref, ref, computed} from "vue";
+import {reportQueryCenterApiByGet} from "@/api/base-data/report-center";
+import CyAutoSize from "@/components/cy/auto-size/cy-auto-size.vue";
+import XcElOption from "@/components/xiao-chan/xc-el-option/XcElOption.vue";
+import XEUtils from "xe-utils";
+import {SortBy, SortState, TableV2SortOrder} from "element-plus";
+
+const props = defineProps<{
+  patNo: string,
+  times: number
+}>()
+
+const data = ref([])
+const patInfo: Ref<{
+  name: string;
+  sex: string;
+  age: string;
+  smallDeptName: string
+  bedNo: string
+  inpatientNo: string
+}> = ref({})
+
+
+const currentType = ref('GLU')
+
+const typeList = [
+  {code: 'GLU', name: '血糖'},
+  {code: 'UA', name: '尿酸'},
+  {code: 'KB', name: '血酮'}
+]
+
+const sortState = ref<SortState>({
+  'time': TableV2SortOrder.DESC,
+})
+
+const onSort = ({key, order}: SortBy) => {
+  sortState.value[key] = order
+  if (order === 'asc') {
+    data.value = data.value.sort((a, b) => new Date(a.time) - new Date(b.time))
+  } else {
+    data.value = data.value.sort((a, b) => new Date(b.time) - new Date(a.time))
+  }
+}
+
+const columns = [
+  {
+    key: 'time',
+    title: '测试时间',
+    dataKey: 'time',
+    width: '220px',
+    sortable: true
+  },
+  {
+    key: 'resultJson.result',
+    title: '结果',
+    dataKey: 'resultJson.result',
+    width: '220px'
+  },
+  {
+    key: 'createdName',
+    title: '签名',
+    dataKey: 'createdName',
+    width: '220px'
+  }
+  ,
+  {
+    key: 'resultJson.testNutritionalTime',
+    title: '备注',
+    dataKey: 'resultJson.testNutritionalTime',
+    width: '220px'
+  }
+]
+
+const tempData = computed(() => {
+  return XEUtils.filter(data.value, (item) => {
+    return item.type === currentType.value
+  })
+})
+
+onMounted(() => {
+  reportQueryCenterApiByGet("/intergration/sannuo/bloodSugar", {
+    patNo: props.patNo,
+    times: props.times,
+    type: 'GLU'
+  }).then(res => {
+    data.value = res.data
+    patInfo.value = res.patInfo
+  })
+})
+</script>
+
+<template>
+  <div style="height: 100% ; width: 100% ; display: flex;flex-flow: column;flex-wrap: wrap;">
+    <div style="height: max-content">
+      <div style="display: grid ; grid-template-columns: 1fr 1fr 1fr 1fr 1fr 1fr ">
+        <div>
+          姓名:{{ patInfo.name }}
+        </div>
+        <div>性别:{{ patInfo.sex }}</div>
+        <div>年龄:{{ patInfo.age }}</div>
+        <div>科室:{{ patInfo.smallDeptName }}</div>
+        <div>床号:{{ patInfo.bedNo }}</div>
+        <div>住院号:{{ patInfo.inpatientNo }}</div>
+      </div>
+      <div>
+        <el-select style="width: 90px;" v-model="currentType">
+          <xc-el-option :data="typeList"/>
+        </el-select>
+      </div>
+    </div>
+    <div style="flex: 1">
+      <cy-auto-size>
+        <template #default="{width,height}">
+          <el-table-v2 :data="tempData"
+                       :height="height"
+                       v-model:sort-state="sortState"
+                       :width="width"
+                       @column-sort="onSort"
+                       :columns="columns"/>
+        </template>
+      </cy-auto-size>
+    </div>
+
+  </div>
+
+</template>
+
+<style scoped lang="scss">
+
+</style>

+ 10 - 2
src/components/zhu-yuan-yi-sheng/emr/auxiliary-tools/EmrAuxiliaryTools.vue

@@ -66,6 +66,7 @@ import {
 import EmrTestV2 from "@/components/zhu-yuan-yi-sheng/emr/auxiliary-tools/EmrTestV2/EmrTestV2.vue";
 import {useZIndex} from "element-plus";
 import {openPatientImage} from "@/views/hospitalization/zhu-yuan-yi-sheng/public-js/zhu-yuan-yi-sheng";
+import BloodSugar from "@/components/zhu-yuan-yi-sheng/emr/auxiliary-tools/BloodSugar.vue";
 
 const props = defineProps({
   patInfo: {
@@ -174,10 +175,17 @@ const drawerRange: {
       comp: () => {
         return h(EmrElectrocardiogram, {...propsPatientInfo.value})
       }
-    }, {
+    },
+    // {
+    //   name: '血糖',
+    //   comp: () => {
+    //     return h(BloodSugarQuery, {...propsPatientInfo.value})
+    //   }
+    // },
+    {
       name: '血糖',
       comp: () => {
-        return h(BloodSugarQuery, {...propsPatientInfo.value})
+        return h(BloodSugar, {...propsPatientInfo.value})
       }
     }
   ],

+ 1 - 1
src/views/examination/BloodSugarQuery/BloodSugarQuery.vue

@@ -14,7 +14,7 @@
   </page-layer>
 </template>
 
-<script setup name='BloodSugarQuery'>
+<script setup>
 import {
   getPatientLoodSugar,
 } from "@/api/blood-sugar/query";

+ 2 - 2
src/views/hospitalization/case-front-sheet/FillCaseFrontSheet.vue

@@ -145,7 +145,7 @@
             <div>
               工作单位及地址:
               <input id="unitName" v-model="patient.unitName" style="margin-right: 0; width: 145px"/>
-              /<input id="unitPlace" v-model="patient.unitPlace" style="width: 145px"/> 单位电话: <input id="unitPhone"
+              /<input id="unitPlace" v-model.trim="patient.unitPlace" style="width: 145px"/> 单位电话: <input id="unitPhone"
                                                                                                          v-model="patient.unitPhone"
                                                                                                          style="width: 80px"/>
               邮编:
@@ -167,7 +167,7 @@
               <el-button icon="Search" type="primary" v-show="showGoSearchBtn2" @click="showSearchData('contact')">
                 前往搜索
               </el-button>
-              联系人电话: <input id="contactPhone" v-model="patient.contactPhone" style="width: 90px"/>
+              联系人电话: <input id="contactPhone" v-model.trim="patient.contactPhone" style="width: 90px"/>
             </div>
             <div>
               入院途径:

+ 2 - 0
src/views/hospitalization/zhu-yuan-yi-sheng/public-js/zhu-yuan-yi-sheng.ts

@@ -871,6 +871,8 @@ export declare type AddJcParams = {
     minAgeRestriction: number;
     maxAgeRestriction: number;
     startTime?: string
+    orderType?: string;
+    isTheParentNode?: string
 }
 
 export const jyJcRestriction = (data: AddJcParams, error: boolean = true) => {