Przeglądaj źródła

电子病历自定义按钮的排列

xiaochan 1 rok temu
rodzic
commit
ecdb1a279c

+ 89 - 4
src/layout/function-list/Theme.vue

@@ -6,12 +6,11 @@
 
     <el-drawer v-model="drawer" title="系统设置" class="system_user-config">
       <el-form>
-
         <el-collapse v-model="activeNames">
           <el-collapse-item title="医嘱录入" name="0">
             <el-form-item :label="`默认查询【${userConfig.yz_orderTimeDay}】天前医嘱`">
               <el-input-number
-                  :min="1"
+                  :min="-1"
                   v-model="userConfig.yz_orderTimeDay"/>
             </el-form-item>
             <el-form-item label="医嘱排序">
@@ -41,6 +40,10 @@
             </el-form-item>
           </el-collapse-item>
           <el-collapse-item title="电子病历" name="2">
+            <el-alert
+                title="电子病历设置完成后需要刷新电子病历页面"
+                style="margin-bottom: 5px"
+            />
             <el-form-item label="侧边栏按钮大小">
               <el-select v-model="userConfig.emr_size"
                          :disabled="userConfig.emr_function_button_show_text"
@@ -66,6 +69,16 @@
                 <xc-el-option :data="[{code: 0 , name: '关闭'}, {code: 1, name: '卡片'}, {code: 2, name: '嵌入'}]"/>
               </el-select>
             </el-form-item>
+            <el-form-item label="功能按键布局">
+              <div class="system_emr_function"
+                   ref="emrFunctionRef">
+                <div v-for="(item,index) in emrFunctionLayout"
+                     :key="`item${index}`"
+                     class="system_emr_function-item">
+                  {{ emrFunctionKey[item] }}
+                </div>
+              </div>
+            </el-form-item>
           </el-collapse-item>
         </el-collapse>
       </el-form>
@@ -83,9 +96,11 @@ import {SystemConfig, useSystemStore} from "@/pinia/system-store";
 import XEUtils from 'xe-utils'
 import {Ref, ref} from "vue";
 import XcElOption from "@/components/xiao-chan/xc-el-option/XcElOption.vue";
+// @ts-ignore
+import Sortable from 'sortablejs'
 
 const tabsHook = {
-  setItem: function (val) {
+  setItem: function (val: any) {
     localStorage.setItem('theme', JSON.stringify(val))
   },
   getItem: function () {
@@ -96,19 +111,65 @@ const tabsHook = {
 const systemStore = useSystemStore()
 const drawer = ref(false)
 const activeNames = ref(['0', '1', '2'])
+// @ts-ignore
 const userConfig: Ref<SystemConfig> = ref({})
+const emrFunctionKey = {
+  "baocun": "保存",
+  "tijiao": "提交",
+  "shenhe": "审核",
+  "shanchu": "删除",
+  "huanyuan": "还原",
+  "huishouzhan": "回收站",
+  "shujutongbu": "数据同步",
+  "zancun": "暂存",
+  "chexiao": "撤销",
+  "chongzuo": "重做",
+  "shenyue": "审阅",
+  "daying": "打印",
+  "fangda": "放大",
+  "suoxiao": "缩小",
+  "bingchengjilupaixu": "排序",
+  "fenyefu": "分页符",
+  "xianshifenyefu": "显示分页",
+  "liaotianshi": "聊天室",
+  "jiesuobinglixianzhi": "解锁限制",
+  "huanzheliebiao": "患者列表"
+}
+const emrFunctionRef = ref<HTMLDivElement | null>(null)
 
 function openDrawer() {
   userConfig.value = XEUtils.clone(systemStore.userConfig, true)
   drawer.value = true
+  sortEmrFunction()
 }
 
+async function sortEmrFunction() {
+  await nextTick()
+  const ops = {
+    animation: 200,
+    handle: '.system_emr_function-item',
+    onEnd({newIndex, oldIndex}: { newIndex: number, oldIndex: number }) {
+      const currRow = emrFunctionLayout.value.splice(oldIndex, 1)[0];
+      emrFunctionLayout.value.splice(newIndex, 0, currRow)
+    },
+  }
+  Sortable.create(emrFunctionRef.value, ops)
+}
+
+const emrFunctionLayout = computed(() => {
+  if (drawer.value) {
+    return userConfig.value.emr_function_layout.split(",");
+  }
+  return []
+});
+
 function saveUserConfig() {
+  userConfig.value.emr_function_layout = emrFunctionLayout.value.join(",")
   systemStore.postUserConfig(userConfig.value)
   drawer.value = false
 }
 
-function handelEmrfunctionButtonShowText(val) {
+function handelEmrfunctionButtonShowText(val: boolean) {
   if (val) {
     userConfig.value.emr_size = 'large'
   }
@@ -117,6 +178,7 @@ function handelEmrfunctionButtonShowText(val) {
 watch(() => theme.value, () => {
   const el = document.documentElement
   for (let key in theme.value) {
+    // @ts-ignore
     el.style.setProperty(key, theme.value[key])
   }
   tabsHook.setItem(theme.value)
@@ -126,6 +188,7 @@ watch(() => theme.value, () => {
 onMounted(() => {
   const el = document.documentElement
   for (let key in theme.value) {
+    // @ts-ignore
     el.style.setProperty(key, theme.value[key])
   }
   if (localStorage.getItem('theme') == null) {
@@ -143,4 +206,26 @@ onMounted(() => {
     margin-bottom: 10px !important;
   }
 }
+
+.system_emr_function {
+  width: 100%;
+  min-height: 200px;
+  box-shadow: var(--el-box-shadow);
+  border: 1px solid var(--el-border-color);
+  display: grid;
+  padding: 10px;
+  grid-template-columns: repeat(5, 1fr);
+  grid-column-gap: 5px;
+
+  .system_emr_function-item {
+    user-select: none;
+    text-align: center;
+    width: 100%;
+    padding: 5px;
+    border: 1px solid var(--el-border-color);
+    height: max-content;
+    cursor: all-scroll;
+  }
+}
+
 </style>

+ 2 - 0
src/pinia/system-store.ts

@@ -21,6 +21,7 @@ export interface SystemConfig {
     emr_size: 'default' | 'large';
     emr_function_button_show_text: boolean,
     emr_review_mode: number;
+    emr_function_layout: string
 }
 
 const userConfig: SystemConfig = {
@@ -31,6 +32,7 @@ const userConfig: SystemConfig = {
     emr_size: 'large',
     emr_function_button_show_text: true,
     emr_review_mode: 1,
+    emr_function_layout: "baocun,tijiao,shenhe,shanchu,huanyuan,huishouzhan,shujutongbu,zancun,chexiao,chongzuo,shenyue,daying,fangda,suoxiao,bingchengjilupaixu,fenyefu,xianshifenyefu,liaotianshi,jiesuobinglixianzhi,huanzheliebiao"
 }
 
 export const useSystemStore = defineStore('system', {

+ 0 - 8
src/views/hospitalization/zhu-yuan-yi-sheng/electronic-medical-record/emr-editor/EmrHeader.vue

@@ -49,14 +49,6 @@ emrMitt.on('setHeaderFunction', (value) => {
           {{ item.name }}
         </button>
       </div>
-      <div class="mac_item">
-        <button @click="useLiftingRestrictions">
-          解锁限制
-        </button>
-      </div>
-      <div class="mac_item">
-        <button @click="usePatientList">患者列表</button>
-      </div>
       <div class="mac_item"
            v-if="patientInfo.dischargeDays > 0">
         <button>出院天数({{ patientInfo.dischargeDays }})</button>

+ 240 - 212
src/views/hospitalization/zhu-yuan-yi-sheng/electronic-medical-record/emr-editor/components/emr-function/EmrFunctionList.vue

@@ -8,12 +8,14 @@ import {
   RefreshRight,
   SortDown,
   Avatar,
-  FolderChecked
+  FolderChecked,
+  Unlock,
+  UserFilled
 } from "@element-plus/icons-vue";
 import {
   emrConfig,
   emrMitt,
-  query,
+  query, useLiftingRestrictions, usePatientList,
   useRecoveryEmr
 } from "@/views/hospitalization/zhu-yuan-yi-sheng/electronic-medical-record/emr-editor/emr-init";
 import {
@@ -21,13 +23,12 @@ import {
   Button,
   PopoverButton
 } from "./useEmrFunction";
-import {xcMessage} from "@/utils/xiaochan-element-plus";
 import {
   emrRootContextKey
 } from "@/views/hospitalization/zhu-yuan-yi-sheng/electronic-medical-record/emr-func/useEmrStore";
 import {useSystemStore} from "@/pinia/system-store";
 import {RevisionShowMode} from "@/utils/emr/emr-init-v2";
-import XEUtils from "xe-utils";
+import {isDev} from "@/utils/public";
 
 interface EmrFunctionListProps {
   openRecovery: Function;
@@ -41,7 +42,8 @@ const props = defineProps<EmrFunctionListProps>()
 let zoom = 1;
 
 const size = useSystemStore().userConfig.emr_size
-const buttonSize = size === 'default' ? '28px' : '48px'
+const buttonSize = size === 'default' ? '28px' : '49px'
+const useFunctionLayout = ref<FunctionList[]>([])
 
 const emits = defineEmits(['update:isOpenPage', 'update:reviewMode'])
 
@@ -50,8 +52,8 @@ function setRevisionShowMode(value: number) {
   emrMitt.emit('editor')?.setRevisionShowMode(value);
 }
 
-const businessFunctions = [
-  {
+const emrFunction: { [key: string]: FunctionList } = {
+  baocun: {
     iconfontName: 'baocun',
     title: '保存正在编写的电子病历 快捷键 Ctrl + S',
     name: '保存',
@@ -60,7 +62,7 @@ const businessFunctions = [
       emrMitt.emit('clickSaveData')
     }
   },
-  {
+  tijiao: {
     iconfontName: 'tijiao',
     title: '标识病历为提交,提交不是保存,该功能只是在病历的前面加上一个🔒的样式',
     name: '提交',
@@ -69,7 +71,7 @@ const businessFunctions = [
       emrMitt.emit('clickToSubmitTheMedicalRecord')
     },
   },
-  {
+  shenhe: {
     iconfontName: 'huizhenshenqing',
     title: "由上级医生点击,上级医生审核完成病历后需要点击该按钮。",
     name: '审核',
@@ -78,7 +80,7 @@ const businessFunctions = [
       emrMitt.emit('auditClick')
     }
   },
-  {
+  shanchu: {
     iconfontName: <Delete/>,
     title: '删除当前病历,可在回收站恢复,出院患者无法删除,需要把出院患者召回才行',
     name: '删除',
@@ -87,14 +89,14 @@ const businessFunctions = [
       emrMitt.emit('clickDelete')
     },
   },
-  {
+  huanyuan: {
     iconfontName: 'huanyuan',
     title: '还原当前病历上一次保存的状态',
     name: '还原',
     disabled: !emrConfig.value.editor,
-    click: props.openRecovery,
+    click: () => props.openRecovery(),
   },
-  {
+  huishouzhan: {
     iconfontName: 'huifushanchu',
     title: '恢复已被删除的病历',
     name: '回收站',
@@ -102,164 +104,174 @@ const businessFunctions = [
     click() {
       useRecoveryEmr()
     },
-  }
-];
-
-const functionList = ref<FunctionList[][]>([
-  [
-    {
-      name: '数据同步',
-      title: "数据同步,患者基本信息只会在空的时候填充,从病历提取的数据会强制替换,如入院诊断,鼠标右键可选择性填充数据",
-      iconfontName: 'tongbu',
-      disabled: !emrConfig.value.editor,
-      click() {
-        emrMitt.emit('syncEmrPatientData')
-      },
-      contextmenu() {
-        emrMitt.emit('selectFill')
-      },
+  },
+  shujutongbu: {
+    name: '数据同步',
+    title: "数据同步,患者基本信息只会在空的时候填充,从病历提取的数据会强制替换,如入院诊断,鼠标右键可选择性填充数据",
+    iconfontName: 'tongbu',
+    disabled: !emrConfig.value.editor,
+    click() {
+      emrMitt.emit('syncEmrPatientData')
     },
-    {
-      title: window.indexedDB ? '病历暂存点击后页面刷新不会导致病历消失,重新打开病历会自动触发恢复的方法。' : '你的电脑不支持暂存',
-      iconfontName: <FolderChecked/>,
-      name: '暂存',
-      disabled: !window.indexedDB,
-      click() {
-        root?.store.cache.saveCache()
-      }
-    }
-  ],
-  businessFunctions,
-  [
-    {
-      iconfontName: <RefreshLeft/>,
-      title: '撤销 快捷键 Ctrl + Z',
-      name: '撤销',
-      click() {
-        emrMitt.emit('editor')!.execute('undo')
-      }
+    contextmenu() {
+      emrMitt.emit('selectFill')
     },
-    {
-      iconfontName: <RefreshRight/>,
-      title: '重做 快捷键 Ctrl + Y',
-      name: '重做',
-      click() {
-        emrMitt.emit('editor')!.execute('redo')
-      }
+  },
+  zancun: {
+    title: window.indexedDB ? '病历暂存点击后页面刷新不会导致病历消失,重新打开病历会自动触发恢复的方法。' : '你的电脑不支持暂存',
+    iconfontName: <FolderChecked/>,
+    name: '暂存',
+    disabled: !window.indexedDB,
+    click() {
+      root?.store.cache.saveCache()
+    }
+  },
+  chexiao: {
+    iconfontName: <RefreshLeft/>,
+    title: '撤销 快捷键 Ctrl + Z',
+    name: '撤销',
+    click() {
+      emrMitt.emit('editor')!.execute('undo')
     }
-  ],
-  [
-    {
-      title: "",
-      name: '审阅',
-      iconfontName: 'shenyue',
-      dropdown: [
-        {
-          name: '嵌入模式',
-          title: '开启后会在病历中会有其他医生的修改痕迹,默认开启',
-          click() {
-            setRevisionShowMode(RevisionShowMode.嵌入)
-          }
-        },
-        {
-          name: '卡片模式',
-          title: '病历右侧会以列表的形式显示 添加,删除,更新的记录,可以通过该模式消除痕迹,选择 √ 或 X即可。',
-          click() {
-            setRevisionShowMode(RevisionShowMode.卡片)
-          }
+  },
+  chongzuo: {
+    iconfontName: <RefreshRight/>,
+    title: '重做 快捷键 Ctrl + Y',
+    name: '重做',
+    click() {
+      emrMitt.emit('editor')!.execute('redo')
+    }
+  },
+  shenyue: {
+    title: "",
+    name: '审阅',
+    iconfontName: 'shenyue',
+    dropdown: [
+      {
+        name: '嵌入模式',
+        title: '开启后会在病历中会有其他医生的修改痕迹,默认开启',
+        click() {
+          setRevisionShowMode(RevisionShowMode.嵌入)
         }
-      ]
-    },
-    {
-      iconfontName: <Printer/>,
-      title: "",
-      name: '打印',
-      click() {
-        emrMitt.emit('getEditMain')?.print()
       },
-      dropdown: [
-        {
-          name: '页面',
-          title: '页面打印',
-          click() {
-            emrMitt.emit('getEditMain')?.print()
-          }
-        },
-        {
-          name: '服务',
-          title: '服务打印',
-          click() {
-            emrMitt.emit('getEditMain')?.print('server')
-          }
-        },
-      ]
-    },
-    {
-      iconfontName: <ZoomIn/>,
-      title: '放大病历',
-      name: '放大',
-      click() {
-        emrMitt.emit('editor')!.execute('zoom', {value: zoom += 0.1})
-      }
-    },
-    {
-      iconfontName: <ZoomOut/>,
-      title: '缩小病历',
-      name: '缩小',
-      click() {
-        emrMitt.emit('editor')!.execute('zoom', {value: zoom -= 0.1})
-      }
-    },
-  ],
-  [
-    {
-      iconfontName: <SortDown/>,
-      title: '仅在病程记录中生效,根据病程记录的时间来进行排序,从小到大。',
-      name: '排序',
-      click() {
-        emrMitt.emit('diseaseCourseSequencing')
-      }
-    },
-    {
-      iconfontName: 'chaifenyemian',
-      title: "为页面添加分页标识符,分页符后强制为新页面。",
-      name: '分页符',
-      click() {
-        emrMitt.emit('editor')!.execute('insertContents', {value: [{type: 'pagebreak'}]})
+      {
+        name: '卡片模式',
+        title: '病历右侧会以列表的形式显示 添加,删除,更新的记录,可以通过该模式消除痕迹,选择 √ 或 X即可。',
+        click() {
+          setRevisionShowMode(RevisionShowMode.卡片)
+        }
       }
+    ]
+  },
+  daying: {
+    iconfontName: <Printer/>,
+    title: "",
+    name: '打印',
+    click() {
+      emrMitt.emit('getEditMain')?.print()
     },
-    {
-      iconfontName: 'xianshifenye',
-      title: '病历中显示分页',
-      name: '显示分页',
-      activation: false,
-      click(value) {
-        value.activation = !value.activation
-        emits('update:isOpenPage', value.activation)
-        emrMitt.emit('editor')!.setPaginate(value.activation)
-      }
+    dropdown: [
+      {
+        name: '页面',
+        title: '页面打印',
+        click() {
+          emrMitt.emit('getEditMain')?.print()
+        }
+      },
+      {
+        name: '服务',
+        title: '服务打印',
+        click() {
+          emrMitt.emit('getEditMain')?.print('server')
+        }
+      },
+    ]
+  },
+  fangda: {
+    iconfontName: <ZoomIn/>,
+    title: '放大病历',
+    name: '放大',
+    click() {
+      emrMitt.emit('editor')!.execute('zoom', {value: zoom += 0.1})
     }
-  ],
-  [
-    {
-      title: "点击可以打开聊天室",
-      name: '聊天室',
-      iconfontName: <Avatar/>,
-      click() {
-        emrMitt.emit('openChatRoom')
-      }
+  },
+  suoxiao: {
+    iconfontName: <ZoomOut/>,
+    title: '缩小病历',
+    name: '缩小',
+    click() {
+      emrMitt.emit('editor')!.execute('zoom', {value: zoom -= 0.1})
     }
-  ]
-]);
+  },
+  bingchengjilupaixu: {
+    iconfontName: <SortDown/>,
+    title: '仅在病程记录中生效,根据病程记录的时间来进行排序,从小到大。',
+    name: '排序',
+    click() {
+      emrMitt.emit('diseaseCourseSequencing')
+    }
+  },
+  fenyefu: {
+    iconfontName: 'chaifenyemian',
+    title: "为页面添加分页标识符,分页符后强制为新页面。",
+    name: '分页符',
+    click() {
+      emrMitt.emit('editor')!.execute('insertContents', {value: [{type: 'pagebreak'}]})
+    }
+  },
+  xianshifenyefu: {
+    iconfontName: 'xianshifenye',
+    title: '病历中显示分页',
+    name: '显示分页',
+    activation: false,
+    click(value: FunctionList) {
+      value.activation = !value.activation
+      emits('update:isOpenPage', value.activation)
+      emrMitt.emit('editor')!.setPaginate(value.activation)
+    }
+  },
+  liaotianshi: {
+    title: "点击可以打开聊天室",
+    name: '聊天室',
+    iconfontName: <Avatar/>,
+    click() {
+      emrMitt.emit('openChatRoom')
+    }
+  },
+  jiesuobinglixianzhi: {
+    title: '解锁病历限制',
+    name: '解锁限制',
+    iconfontName: <Unlock/>,
+    click() {
+      useLiftingRestrictions()
+    }
+  },
+  huanzheliebiao: {
+    title: '患者列表',
+    name: '患者列表',
+    iconfontName: <UserFilled/>,
+    click() {
+      usePatientList()
+    }
+  }
+}
 
-onMounted(() => {
-  const data = []
+if (isDev) {
+  let a: any = {};
+  for (let emrFunctionElement in emrFunction) {
+    a[emrFunctionElement] = emrFunction[emrFunctionElement].name
+  }
+  console.log(a)
+}
 
-  functionList.value.forEach((item) => {
-    data.push(...item)
+onMounted(() => {
+  const data: FunctionList[] = [];
+  const layout = useSystemStore().userConfig.emr_function_layout.split(",")
+  layout.forEach(item => {
+    data.push(emrFunction[item])
   })
-
-  emrMitt.emit('setHeaderFunction', data)
+  useFunctionLayout.value = data
+  emrMitt.emit('setHeaderFunction', useFunctionLayout.value)
 })
 
 
@@ -269,24 +281,17 @@ onMounted(() => {
   <div
       class="emr_function-content">
     <el-scrollbar>
-      <template v-for="(item , itemIndex) in functionList">
-        <div class="emr_function-action-group"
-             :style="{marginTop:itemIndex === 0 ?  0 : null}"
-        >
-          <div
-              v-for="(child,index) in item"
-              v-title="child.title"
-          >
-            <PopoverButton
-                v-if="child.dropdown && child.dropdown.length >0"
-                :child="child"
-                :index="index"
-            />
-            <Button
-                v-else
-                :child="child"
-                :index="index"/>
-          </div>
+      <template v-for="(item,itemIndex) in useFunctionLayout">
+        <div class="button_item">
+          <PopoverButton
+              v-if="item.dropdown && item.dropdown.length >0"
+              :child="item"
+              :index="itemIndex"
+          />
+          <Button
+              v-else
+              :child="item"
+              :index="itemIndex"/>
         </div>
       </template>
     </el-scrollbar>
@@ -298,55 +303,78 @@ onMounted(() => {
   width: max-content;
   background-color: white;
   padding: 4px;
+  display: flex;
+  flex-direction: column;
+  align-items: center;
+  justify-content: center;
+  height: 100%;
+  cursor: pointer;
 
-  .emr_function-action-group {
-    margin: 8px 0;
+  .el-button:hover {
+    background-color: #f5f7fa;
+  }
 
-    .el-button:hover {
-      background-color: #f5f7fa;
-    }
+  .el-button:active {
+    background-color: #f5f7fa;
+    border: 1px solid var(--el-border-color);
+  }
 
-    .el-button:active {
-      background-color: #f5f7fa;
-      border: 1px solid var(--el-border-color);
-    }
+  button {
+    width: v-bind(buttonSize);
+    height: v-bind(buttonSize);
+    font-size: 12px;
+    padding: 5px;
+    border-radius: 0;
 
-    .emr-function-button-upright {
+    &.activation {
+      background-color: var(--el-button-hover-bg-color);
+      color: var(--el-button-active-border-color);
+    }
 
-      > span {
-        display: flex;
-        flex-direction: column;
-        align-items: center;
-        justify-content: center;
-        height: 100%;
-        cursor: pointer;
+    .el-icon {
+      i {
+        width: 16px;
+        height: 12px;
       }
+    }
+  }
 
-      .el-icon {
-        margin-bottom: 6px;
-      }
+  // 显示文字就要竖着排列
+  .emr-function-button-upright {
+    > span {
+      display: flex;
+      flex-direction: column;
+      align-items: center;
+      justify-content: center;
+      height: 100%;
+      cursor: pointer;
     }
 
-    button {
-      width: v-bind(buttonSize);
-      height: v-bind(buttonSize);
-      font-size: 12px;
-      padding: 5px;
-      border-radius: 0;
+    .el-icon {
+      margin-bottom: 6px;
+    }
+  }
 
-      &.activation {
-        background-color: var(--el-button-hover-bg-color);
-        color: var(--el-button-active-border-color);
-      }
+  button {
+    width: v-bind(buttonSize);
+    height: v-bind(buttonSize);
+    font-size: 12px;
+    padding: 5px;
+    border-radius: 0;
 
-      .el-icon {
-        i {
-          width: 16px;
-          height: 12px;
-        }
+    &.activation {
+      background-color: var(--el-button-hover-bg-color);
+      color: var(--el-button-active-border-color);
+    }
+
+    .el-icon {
+      i {
+        width: 16px;
+        height: 12px;
       }
     }
   }
+
 }
 
 .el-popper.emr_function-popper {

+ 2 - 2
src/views/hospitalization/zhu-yuan-yi-sheng/electronic-medical-record/emr-editor/components/emr-function/useEmrFunction.tsx

@@ -14,8 +14,8 @@ export declare type FunctionList = {
     name?: string;
     iconfontName?: string | any,
     title: string,
-    contextmenu?: (value?: FunctionList) => void,
-    click?: (value?: FunctionList) => void,
+    contextmenu?: (value: FunctionList) => void,
+    click?: (value: FunctionList) => void,
     disabled?: boolean;
     activation?: boolean;
     dropdown?: {

+ 5 - 3
src/views/hospitalization/zhu-yuan-yi-sheng/public-js/zhu-yuan-yi-sheng.ts

@@ -472,9 +472,11 @@ const userConfig = useSystemStore().userConfig
 let newDate = ''
 getServerDate().then((res) => {
     newDate = res
-    const {start, end} = elDateRangeAddTime(aFewDaysAgo(res, userConfig.yz_orderTimeDay));
-    queryParam.value.startTime = start;
-    queryParam.value.endTime = end;
+    if (userConfig.yz_orderTimeDay >= 0) {
+        const {start, end} = elDateRangeAddTime(aFewDaysAgo(res, userConfig.yz_orderTimeDay));
+        queryParam.value.startTime = start;
+        queryParam.value.endTime = end;
+    }
 })
 
 // 医嘱查询条件