update 调整银川大屏和西安大屏
This commit is contained in:
@@ -1,6 +1,14 @@
|
||||
import { ref, unref } from 'vue';
|
||||
import * as echarts from 'echarts';
|
||||
|
||||
//服务详情数据弹窗参数
|
||||
export enum ServerDetailType {
|
||||
gross = '0', //最新呼入电话
|
||||
alerdyreceive = '1', //最新受理电话
|
||||
jqqz = '2', //突发重大伤病应急
|
||||
dbjy = '3', //重大伤病应急就医
|
||||
}
|
||||
|
||||
export function useStatistics() {
|
||||
const statistics = ref([
|
||||
{
|
||||
@@ -90,36 +98,36 @@ export function useSpin() {
|
||||
}
|
||||
|
||||
export const hospitalList = [
|
||||
{
|
||||
name: '泾河医院',
|
||||
key: 'zhigong',
|
||||
value: 0,
|
||||
},
|
||||
{
|
||||
name: '兴隆医院',
|
||||
key: 'tangdu',
|
||||
value: 0,
|
||||
},
|
||||
{
|
||||
name: '宁夏宝石花医院',
|
||||
key: 'yangehu',
|
||||
value: 0,
|
||||
},
|
||||
{
|
||||
name: '延安市人民医院',
|
||||
key: 'yananshi',
|
||||
value: 0,
|
||||
},
|
||||
{
|
||||
name: '西京医院',
|
||||
key: 'xijing',
|
||||
value: 0,
|
||||
},
|
||||
{
|
||||
name: '庆阳医院',
|
||||
key: 'changan',
|
||||
value: 0,
|
||||
},
|
||||
// {
|
||||
// name: '泾河医院',
|
||||
// key: 'zhigong',
|
||||
// value: 0,
|
||||
// },
|
||||
// {
|
||||
// name: '兴隆医院',
|
||||
// key: 'tangdu',
|
||||
// value: 0,
|
||||
// },
|
||||
// {
|
||||
// name: '宁夏宝石花医院',
|
||||
// key: 'yangehu',
|
||||
// value: 0,
|
||||
// },
|
||||
// {
|
||||
// name: '延安市人民医院',
|
||||
// key: 'yananshi',
|
||||
// value: 0,
|
||||
// },
|
||||
// {
|
||||
// name: '西京医院',
|
||||
// key: 'xijing',
|
||||
// value: 0,
|
||||
// },
|
||||
// {
|
||||
// name: '庆阳医院',
|
||||
// key: 'changan',
|
||||
// value: 0,
|
||||
// },
|
||||
];
|
||||
|
||||
export function useHospitalList() {
|
||||
@@ -129,11 +137,12 @@ export function useHospitalList() {
|
||||
return unref(radarList);
|
||||
}
|
||||
|
||||
function setRadarList(res = {}) {
|
||||
radarList.value.forEach((item) => {
|
||||
const { key } = item;
|
||||
item.value = res[key] || 0;
|
||||
});
|
||||
function setRadarList(res) {
|
||||
radarList.value = res;
|
||||
// radarList.value.forEach((item) => {
|
||||
// const { key } = item;
|
||||
// item.value = res[key] || 0;
|
||||
// });
|
||||
}
|
||||
|
||||
return {
|
||||
|
||||
@@ -3,7 +3,7 @@ import { get } from '/@/api/request';
|
||||
export enum Api {
|
||||
departList = '/sys/sysDepart/allSecondaryDeparts',
|
||||
server = '/health-emergency/emergency/tblUserHelp/statistics',
|
||||
getDetail = '/health-emergency/emergency/tblHealthData/getDetail',
|
||||
getDetail = '/health-medical/medical/hospital/getMedicalHospital',
|
||||
complaint = '/health-emergency/emergency/tblHelpCenter/sicknessTypeStatistic',
|
||||
}
|
||||
|
||||
@@ -14,4 +14,4 @@ export const list = (params: any) => get(Api.server, params);
|
||||
//主诉分类
|
||||
export const complaint = (params: any) => get(Api.complaint, params);
|
||||
//体检数据
|
||||
export const getDetail = (params: any) => get(Api.getDetail, params);
|
||||
export const getDetail = (params: any) => get(Api.getDetail, params);
|
||||
|
||||
@@ -54,13 +54,13 @@
|
||||
async function getList() {
|
||||
setSpin(true);
|
||||
try {
|
||||
const { code, result } = (await getDetail({})) || {};
|
||||
const { code, result } = (await getDetail({ dataType: props.setting.dataType })) || {};
|
||||
setSpin(!spinning.value);
|
||||
if (code != 200 || !Array.isArray(result)) {
|
||||
if (code != 200) {
|
||||
return;
|
||||
}
|
||||
setSession(LEFT_KEY3, JSON.stringify(result[0]));
|
||||
setValue(result[0]);
|
||||
setSession(LEFT_KEY3, JSON.stringify(result));
|
||||
setValue(result);
|
||||
} catch {
|
||||
const result = JSON.parse(getSession(LEFT_KEY3));
|
||||
setValue(result);
|
||||
@@ -76,9 +76,9 @@
|
||||
|
||||
function initChart() {
|
||||
const myChart = echarts.init(document.querySelector('.RadarCharts'));
|
||||
let countList = radarList.value.map((item) => item.value);
|
||||
let countList = radarList.value.map((item) => item?.userCount);
|
||||
let max = Math.max(...countList);
|
||||
const indicator = radarList.value.map((item) => ({ name: item.name, max: max }));
|
||||
const indicator = radarList.value.map((item) => ({ name: item?.hospitalName, max: max }));
|
||||
const option = radarCharts({ indicator, countList });
|
||||
myChart.setOption(option);
|
||||
window.addEventListener('resize', () => {
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<div>
|
||||
<public-title title="主诉分类" />
|
||||
<div class="inner">
|
||||
<div class="zc-inner">
|
||||
<div class="title">
|
||||
<div class="type-check">
|
||||
<span
|
||||
@@ -24,7 +24,7 @@
|
||||
</div>
|
||||
</template>
|
||||
<script setup lang="ts">
|
||||
import { ref, onMounted, watch } from 'vue';
|
||||
import { ref, onMounted, watch, onUnmounted } from 'vue';
|
||||
import PublicTitle from '/@/components/publicTitle.vue';
|
||||
import * as echarts from 'echarts';
|
||||
import { complaint, getDepart } from '/@/components/body-d-left/left.api.ts';
|
||||
@@ -51,8 +51,20 @@
|
||||
}
|
||||
|
||||
onMounted(() => {
|
||||
document.addEventListener('visibilitychange', checkTabState);
|
||||
init();
|
||||
});
|
||||
onUnmounted(() => {
|
||||
document.removeEventListener('visibilitychange', checkTabState);
|
||||
});
|
||||
const tabState = ref('');
|
||||
|
||||
function checkTabState() {
|
||||
console.log('checkTabState', document.hidden);
|
||||
tabState.value = document.hidden ? 'inactive' : 'active';
|
||||
if (!document.hidden) {
|
||||
}
|
||||
}
|
||||
|
||||
function init() {
|
||||
getDepartOption();
|
||||
@@ -112,8 +124,9 @@
|
||||
}
|
||||
</script>
|
||||
<style scoped lang="less">
|
||||
.inner {
|
||||
.zc-inner {
|
||||
position: relative;
|
||||
width: 100%;
|
||||
height: calc(100% - 40px);
|
||||
|
||||
.spin {
|
||||
|
||||
@@ -2,10 +2,10 @@ import { get } from '/src/api/request';
|
||||
|
||||
export enum Api {
|
||||
getMonitorList = '/health-watch/watch/watchMonitorData/getMonitorList',
|
||||
getHealthDataList = '/health-emergency/emergency/tblHealthData/getHealthDataList',
|
||||
getHealthDataList = '/health-archives/archives/groupUserA/getGroupUserAInfo',
|
||||
}
|
||||
|
||||
//健康终端报警
|
||||
export const getMonitorList = (params: any) => get(Api.getMonitorList, params);
|
||||
//长庆油田大病人数
|
||||
export const getHealthDataList = (params: any) => get(Api.getHealthDataList, params);
|
||||
export const getHealthDataList = (params: any) => get(Api.getHealthDataList, params);
|
||||
|
||||
@@ -13,6 +13,9 @@
|
||||
import { ringOption, useHealth } from '/@/components/body-d-right/bodyRightHooks.ts';
|
||||
import { useSession, caching } from '/@/hooks/autoRefresh/caching.ts';
|
||||
|
||||
const props = defineProps({
|
||||
setting: Object,
|
||||
});
|
||||
const { setSession, getSession } = useSession();
|
||||
const { RIGHT_KEY2 } = caching;
|
||||
const { setSpin, spinning } = useSpin();
|
||||
@@ -24,7 +27,7 @@
|
||||
|
||||
async function init() {
|
||||
try {
|
||||
const { code, result } = await getHealthDataList({});
|
||||
const { code, result } = await getHealthDataList({ dataType: props.setting?.dataType, orgCode: props.setting?.orgCode });
|
||||
setSpin(true);
|
||||
if (code != 200) {
|
||||
return;
|
||||
|
||||
@@ -50,11 +50,11 @@
|
||||
</div>
|
||||
<div class="center-footer">
|
||||
<div class="count-item">
|
||||
<div class="num">{{ useDetail?.alerdyreceive || '/' }}</div>
|
||||
<div class="num">{{ useDetail?.alerdyreceive || '0' }}</div>
|
||||
<div class="text">累计受理</div>
|
||||
</div>
|
||||
<div class="count-item">
|
||||
<div class="num">{{ useDetail?.totalacceptance || '/' }}</div>
|
||||
<div class="num">{{ useDetail?.totalacceptance || '0' }}</div>
|
||||
<div class="text">累计处置</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -449,4 +449,4 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
</style>
|
||||
|
||||
@@ -69,6 +69,10 @@
|
||||
const dataSource = ref([]);
|
||||
|
||||
async function getRecords() {
|
||||
if (!props.api) {
|
||||
setDataSource([{ name: '张三', department: '公司机关', sex: '男' }]);
|
||||
return;
|
||||
}
|
||||
const { code, result } = await props.api({ ...props.apiParams, pageSize: pageSize.value, pageNo: current.value });
|
||||
if (code == 200) {
|
||||
if (props.afterFetch && isFunction(props.afterFetch)) {
|
||||
@@ -92,6 +96,9 @@
|
||||
immediate: true,
|
||||
}
|
||||
);
|
||||
defineExpose({
|
||||
getRecords,
|
||||
});
|
||||
</script>
|
||||
<style scoped lang="less">
|
||||
:deep(.ant-table-thead > tr > th) {
|
||||
@@ -186,4 +193,4 @@
|
||||
:deep(.ant-table-pagination-right) {
|
||||
margin-right: 10px !important;
|
||||
}
|
||||
</style>
|
||||
</style>
|
||||
|
||||
@@ -100,7 +100,7 @@
|
||||
<style scoped lang="less">
|
||||
.dialog-con {
|
||||
background-color: #00152b;
|
||||
border: 1px solid #129bff;
|
||||
//border: 1px solid #129bff;
|
||||
min-height: 500px;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user