diff --git a/src/api/inspect/inspectpatient/index.ts b/src/api/inspect/inspectpatient/index.ts
index b55da69..da154e6 100644
--- a/src/api/inspect/inspectpatient/index.ts
+++ b/src/api/inspect/inspectpatient/index.ts
@@ -161,7 +161,7 @@ export const PatientApi = {
},
//获取工作量统计
getData : async (params: any) => {
- return await request.get({ url: `/inspect/patient/getworkload?dates=${params.dates[0]}&dates=${params.dates[1]}&examhosname=${params.examhosname}` })
+ return await request.get({ url: `/inspect/patient/getworkload?dates=${params.dates[0]}&dates=${params.dates[1]}&hospitalNo=${params.hospitalNo}` })
},
//导出工作量统计excel
exportData : async (params: any) => {
diff --git a/src/views/sta/index.vue b/src/views/sta/index.vue
index 6f170b9..e092aa0 100644
--- a/src/views/sta/index.vue
+++ b/src/views/sta/index.vue
@@ -20,6 +20,16 @@
size="big"
@change="changeDatePick"
/>
+
+
+
+
+
查询
@@ -131,6 +141,7 @@ import { newHiprintPrintTemplate, preparePrintData } from './printHelper'
import download from '@/utils/download'
import { getUserProfile } from '@/api/system/user/profile'
import { InspectOrgApi } from '@/api/inspect/inspectorg'
+import { hospitals } from '@/config/hospitals'
const message = useMessage() // 消息弹窗
const { t } = useI18n() // 国际化
const loading = ref(true) // 列表的加载中
@@ -172,6 +183,7 @@ const shortcuts = [
]
const dialogVisible = ref(false) // 控制对话框显示
const detailData = ref([]) // 详情数据
+const selectedHospital = ref('') // 选中的医院
/**
* 改变单选框
* @param e
@@ -197,8 +209,6 @@ const changeRadio = (e) => {
time.value = [formatDate(start, 'YYYY-MM-DD'), formatDate(end, 'YYYY-MM-DD')]
// 清空现有数据
data1.value = []
- // 重新获取数据
- getList()
}
const changeDatePick = () => {
radioType.value = null
@@ -209,16 +219,20 @@ const userInfo = ref()
* 获取统计数据
*/
const getList = async () => {
+ if (!selectedHospital.value) {
+ message.warning('请先选择机构')
+ return
+ }
// 清空现有数据
data1.value = []
// 获取用户信息和机构信息
- userInfo.value = await getUserProfile()
- const deptInfo = await InspectOrgApi.getInspectOrg(userInfo.value.deptId)
+ // userInfo.value = await getUserProfile()
+ // const deptInfo = await InspectOrgApi.getInspectOrg(userInfo.value.deptId)
const params = {
dates: [dayjs(time.value[0]).format('YYYY-MM-DD'), dayjs(time.value[1]).format('YYYY-MM-DD')],
- examhosname: deptInfo.orgName
+ hospitalNo: selectedHospital.value
}
try {
let resp = await PatientApi.getData(params)
@@ -396,9 +410,9 @@ const handleDetail = async (row) => {
enddate: time.value[1],
addname: row.districtname,
examhosname: parentNode ? parentNode.orgname : row.orgname,
- orgid: userInfo.value.deptId
+ //orgid: userInfo.value.deptId
+ hospitalNo: selectedHospital.value
}
- console.log(params)
const res = await PatientApi.getPatientDetails(params)
detailData.value = res
dialogVisible.value = true
@@ -408,7 +422,7 @@ const handleDetail = async (row) => {
}
}
onMounted(() => {
- changeRadio(3)
+ changeRadio(3)
// getList()
})