瀏覽代碼

添加项目的规格查看 和 优化点击体验

DESKTOP-MINPJAU\Administrator 3 年之前
父節點
當前提交
c8884a3faf

+ 16 - 10
src/components/inpatient/XiangMuLuRu.vue

@@ -123,6 +123,7 @@
               <el-table-column label="录入日期" prop="chargeDate" width="70px"></el-table-column>
               <el-table-column label="项目编码" prop="chargeCodeMx"></el-table-column>
               <el-table-column label="项目名称" prop="chargeName"></el-table-column>
+              <el-table-column label="规格" v-if="feiYongLeiXingCode !== 1" prop="specification"></el-table-column>
               <el-table-column v-if="feiYongLeiXingCode === 1" label="药品名称" prop="drugname"></el-table-column>
               <el-table-column label="执行科室" prop="execDept"></el-table-column>
               <el-table-column label="申请科室" prop="deptCode"></el-table-column>
@@ -376,7 +377,7 @@ import {ElMessage, ElMessageBox} from 'element-plus'
 import {getDateRangeFormatDate, getDatetime} from '@/utils/date'
 import {clone} from '@/utils/clone'
 import {getPatientInfo} from '@/api/inpatient/patient'
-import {feiYongLeiXing, tuiFeiLeiXin, yiZhuTuiFeiLeiXing} from '@/data/index'
+import {feiYongLeiXing, tuiFeiLeiXin, yiZhuTuiFeiLeiXing} from '@/data'
 import HuoQuMuBan from '@/components/med-tec-mod/HuoQuMuBan.vue'
 import {getDept} from '@/api/public-api'
 import {baseinfo} from '@/data/inpatient'
@@ -400,7 +401,7 @@ const chaoZuoZhiNan = ref(false)
 const xmlrTabs = ref('ylrxm')
 const inpatientNo = ref('')
 const zhiXingKeShi = ref('')
-const dateRange = ref(shortcuts[2].value)
+const dateRange = ref([])
 // DESC 降 ASC 升
 const riQiPaiXu = ref('DESC')
 
@@ -454,7 +455,7 @@ const chaXunHuanZheXinXi = () => {
         patient.value.currentPage = 1
         patient.value.pageSize = 40
         patient.value.total = 0
-        patient.value.orderNo = 0
+        patient.value.orderNo = 2
         patient.value.deptCode = store.state.user.info.deptCode
         queryFeiYong()
         if (patient.value.ward === store.state.user.info.deptCode) {
@@ -483,7 +484,6 @@ const total = ref(0)
  * 查询
  */
 const queryFeiYong = () => {
-
   let dateR = getDateRangeFormatDate(dateRange.value);
   patient.value.startTime = dateR.startTime
   patient.value.endTime = dateR.endTime
@@ -492,7 +492,10 @@ const queryFeiYong = () => {
   patient.value.currentPage = 1
   patient.value.total = 0
   getHuanZheFeiYong(patient.value)
-      .then((res) => {
+      .then(async (res) => {
+        tableDataHuanZheFeiYong.value = []
+        cptTableDataHuanZheFeiYong.value = []
+        await Sleep(100)
         tableDataHuanZheFeiYong.value = res
         cptTableDataHuanZheFeiYong.value = res.records
         total.value = res.total
@@ -515,7 +518,10 @@ const handleQueryFeiYong = () => {
   patient.value.feiYongLeiXingCode = feiYongLeiXingCode.value
   patient.value.total = total.value
   getHuanZheFeiYong(patient.value)
-      .then((res) => {
+      .then(async (res) => {
+        tableDataHuanZheFeiYong.value = []
+        cptTableDataHuanZheFeiYong.value = []
+        await Sleep(100)
         tableDataHuanZheFeiYong.value = res
         cptTableDataHuanZheFeiYong.value = res.records
         if (patient.value.admissWard === store.state.user.info.deptCode) {
@@ -835,8 +841,8 @@ onMounted(() => {
     patient.value.currentPage = 1
     patient.value.pageSize = 40
     patient.value.total = 0
-    patient.value.tuiFeiFlag = 0
-    patient.value.orderNo = 0
+    patient.value.tuiFeiFlag = 3
+    patient.value.orderNo = 2
     patient.value.deptCode = store.state.user.info.deptCode
     zhiXingKeShi.value = patient.value.zkWard
     jinRuPanDuanSFXieDaiHuanZheXinXi()
@@ -845,8 +851,8 @@ onMounted(() => {
     patient.value.currentPage = 1
     patient.value.pageSize = 40
     patient.value.total = 0
-    patient.value.tuiFeiFlag = 0
-    patient.value.orderNo = 0
+    patient.value.tuiFeiFlag = 3
+    patient.value.orderNo = 2
     patient.value.deptCode = store.state.user.info.deptCode
     panDuanSFTongGuoBingShiJinRu.value = true
     zhiXingKeShi.value = patient.value.zkWard

+ 4 - 3
src/components/med-tec-mod/HuoQuMuBan.vue

@@ -12,8 +12,8 @@
                 </el-button>
               </template>
               <!-- 这里是弹出框中的数据 -->
-              <el-table :data="muBanXiangQing" :height="windowSize.h - 170" class="eltable"
-                        @selection-change="xuanZeXiangMuTable">
+              <xc-table :data="muBanXiangQing" is-array :height="170"
+                        @selection-change="xuanZeXiangMuTable" :open-paging="false">
                 <el-table-column type="selection"></el-table-column>
                 <el-table-column label="项目名称" prop="chargeName"></el-table-column>
                 <el-table-column label="国家编码" prop="nationalCode"></el-table-column>
@@ -27,7 +27,7 @@
                 </el-table-column>
                 <el-table-column label="编码" prop="chargeCodeMx"></el-table-column>
                 <el-table-column label="规格" prop="descriptions"></el-table-column>
-              </el-table>
+              </xc-table>
             </el-popover>
           </template>
         </el-table-column>
@@ -67,6 +67,7 @@ import {onMounted, ref} from 'vue'
 import {getMuBan, getMuBanXinXi, shanChuMuBan} from '@/api/inpatient/xiang-mu-lu-ru'
 import store from '@/store'
 import {ElMessageBox} from 'element-plus'
+import XcTable from "@/components/xc/xc-table/XcTable.vue";
 
 const emit = defineEmits(['selectionFeiYong'])
 

+ 11 - 1
src/components/xc/xc-table/XcTable.vue

@@ -3,7 +3,7 @@
       ref="tableRef"
       :data="tableData"
       style="width: 100%"
-      :height="!props.height ? windowSize.h - 100 :props.height"
+      :height="windowSize.h - props.height  "
       @selection-change="selectionChange"
       @row-click="rowClick"
       highlight-current-row
@@ -48,6 +48,7 @@ const props = defineProps({
   },
   height: {
     type: Number,
+    default: 0
   },
   localPaging: {
     type: Boolean,
@@ -68,6 +69,10 @@ const props = defineProps({
     type: Array,
     default: [10, 20, 30, 100]
   },
+  isArray: {
+    type: Boolean,
+    default: false
+  }
 })
 const emit = defineEmits([
   'currentChange',
@@ -85,6 +90,11 @@ const windowSize = computed(() => {
 })
 
 const tableData = computed(() => {
+
+  if (props.isArray) {
+    return props.data
+  }
+
   if (props.localPaging) {
     return props.data.data.slice((props.data.currentPage - 1) * props.data.pageSize, props.data.currentPage * props.data.pageSize)
   } else {