From 06be7c0ff74c73785ef57caf040848bfc12648a0 Mon Sep 17 00:00:00 2001 From: wyuu Date: Fri, 14 Nov 2025 18:13:45 +0800 Subject: [PATCH] =?UTF-8?q?=E7=BB=9F=E8=AE=A1=E5=A4=A7=E5=B1=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package.json | 1 + src/components/elTable/index.vue | 7 + src/main.js | 2 + src/permission.js | 2 +- src/router/index.js | 12 ++ src/store/modules/user.js | 9 +- src/views/checkCode/index.vue | 17 +- src/views/checkCode/report/index.vue | 7 +- src/views/regional/statistics/bbtj/index.vue | 9 +- src/views/regional/statistics/fytj/index.vue | 7 +- .../statistics/overview/css/index.css | 32 +-- .../statistics/overview/css/public.css | 2 +- .../regional/statistics/overview/index.vue | 185 +++++++++++------- 13 files changed, 195 insertions(+), 97 deletions(-) diff --git a/package.json b/package.json index b450e9b..bfbf776 100644 --- a/package.json +++ b/package.json @@ -41,6 +41,7 @@ "vue-plugin-hiprint": "^0.0.60", "vue-router": "4.2.5", "vue3-print-nb": "^0.1.4", + "vue3-seamless-scroll": "^3.0.2", "vue3-select2-component": "^0.1.7", "vuedraggable": "^4.1.0", "vxe-pc-ui": "^4.3.2", diff --git a/src/components/elTable/index.vue b/src/components/elTable/index.vue index 58c924d..bfe57ab 100644 --- a/src/components/elTable/index.vue +++ b/src/components/elTable/index.vue @@ -390,6 +390,13 @@ defineExpose({ } +:deep(.el-table__footer-wrapper tfoot td.el-table__cell) { + color: #1f6dd3 !important; + font-weight: 700; + /* 可替换为任意颜色值 */ +} + + diff --git a/src/main.js b/src/main.js index 9bd3759..187f7c3 100644 --- a/src/main.js +++ b/src/main.js @@ -71,6 +71,7 @@ import TreeSelect from '@/components/TreeSelect' // 字典标签组件 import DictTag from '@/components/DictTag' import print from 'vue3-print-nb'; +import Vue3SeamlessScroll from 'vue3-seamless-scroll' // 引入插件 const app = createApp(App) // 全局方法挂载 @@ -97,6 +98,7 @@ app.component('Editor', Editor) //VUE3标准方法注入全局方法 app.provide('comDict', comDict); app.use(print); // 注册打印插件 +app.use(Vue3SeamlessScroll) app.provide('$vuePrint', app.config.globalProperties.$vuePrint); app.use(router) app.use(store) diff --git a/src/permission.js b/src/permission.js index 4b0a2ea..c0b1c32 100644 --- a/src/permission.js +++ b/src/permission.js @@ -21,7 +21,7 @@ NProgress.configure({ showSpinner: false }); -const whiteList = ['/login', '/register', '/report']; +const whiteList = ['/login', '/register', '/report', '/checkCode']; router.beforeEach((to, from, next) => { NProgress.start() diff --git a/src/router/index.js b/src/router/index.js index 2841ee5..85ee5d6 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -52,6 +52,12 @@ export const constantRoutes = [{ component: () => import('@/views/checkCode/report'), hidden: true }, + { + path: '/checkCode', + component: () => import('@/views/checkCode/index'), + hidden: true + }, + { path: "/:pathMatch(.*)*", component: () => import('@/views/error/404'), @@ -62,6 +68,12 @@ export const constantRoutes = [{ component: () => import('@/views/error/401'), hidden: true }, + // 大屏 + { + path: '/regional/statistics/overview', + component: () => import('@/views/regional/statistics/overview/index'), + hidden: true + }, { path: '', component: Layout, diff --git a/src/store/modules/user.js b/src/store/modules/user.js index cbbc5a1..62c2769 100644 --- a/src/store/modules/user.js +++ b/src/store/modules/user.js @@ -28,9 +28,12 @@ const useUserStore = defineStore( loginAnonymous({ username: data.name }).then(res => { - setToken(res.token) - this.token = res.token - resolve() + if (res.code == 200) { + setToken(res.token) + this.token = res.token + resolve(true) + } + }).catch(error => { reject(error) }) diff --git a/src/views/checkCode/index.vue b/src/views/checkCode/index.vue index 24bcd1f..1d133e1 100644 --- a/src/views/checkCode/index.vue +++ b/src/views/checkCode/index.vue @@ -165,9 +165,12 @@ import { usePrintStore } from '@/store/modules/printStore' import { fetchCodeList, addObj, fetchCodeDetail, fetchCodeExec, fetchCodeReqmain } from '@/api/checkCode/index' const aotuSize = classCom.useAutoSize(); //@ts-ignore +import useUserStore from '@/store/modules/user' +//@ts-ignore import { comDict } from '@/utils/dict' import { ElMessage, ElMessageBox } from 'element-plus' const router = useRouter() +const userStore = useUserStore() const printStore = usePrintStore(); const compactForm = ref(null); const heightForm = ref(90); @@ -533,12 +536,17 @@ const cancelHandle = () => { } onMounted(async () => { + // 进入页面单点登录 + const result = await userStore.loginAnonymous({ name: 'admin' }) + if (result) { + getList() + } // 初始化3天区间(今天-前两天) // const end = dayjs().format('YYYY-MM-DD HH:mm:ss'); // const start = dayjs().subtract(2, 'day').format('YYYY-MM-DD HH:mm:ss'); //add 时间往后 // queryParams.times = [start, end]; // console.log(queryParams.times); - getList() + adjustTableHeight(); // 加载病人来源字典 const dictRefs = await comDict('PT', 'HOS', 'ST'); @@ -567,8 +575,8 @@ function adjustTableHeight() { if (compactForm.value) { // 获取高度 heightForm.value = compactForm.value.offsetHeight; - tableConfig.value.height = `calc(74vh - ${heightForm.value}px)`; // 设置表格容器的高度 - rightTableConfig.value.height = `calc(74vh - ${heightForm.value}px)`; + tableConfig.value.height = `calc(80vh - ${heightForm.value}px)`; // 设置表格容器的高度 + rightTableConfig.value.height = `calc(80vh - ${heightForm.value}px)`; } } @@ -665,6 +673,7 @@ const printPdf = () => { } .right-table { + margin-top: .625rem; border: 1px solid #E1E9F7; padding-top: .3125rem; } @@ -683,6 +692,7 @@ const printPdf = () => { margin-top: .35rem; background-color: #f0f3f8; padding: .3rem 2.5rem; + margin-top: .625rem; } .time-line-item { @@ -690,6 +700,7 @@ const printPdf = () => { align-items: center; justify-content: space-around; width: 16.6%; + // padding: 0 30px; .timeline-content { diff --git a/src/views/checkCode/report/index.vue b/src/views/checkCode/report/index.vue index c5ef06c..0b30da6 100644 --- a/src/views/checkCode/report/index.vue +++ b/src/views/checkCode/report/index.vue @@ -819,6 +819,7 @@ interface DictData { // 字典数据存储 const dictData = ref({}); + onMounted(async () => { // 初始化3天区间(今天-前两天) // const end = dayjs().format('YYYY-MM-DD HH:mm:ss'); @@ -826,8 +827,10 @@ onMounted(async () => { // queryParams.times = [start, end]; // console.log(queryParams.times); // 进入页面单点登录 - userStore.loginAnonymous({ name: 'admin' }) - getList() + const result = await userStore.loginAnonymous({ name: 'admin' }) + if (result) { + getList() + } adjustTableHeight(); // 加载病人来源字典 diff --git a/src/views/regional/statistics/bbtj/index.vue b/src/views/regional/statistics/bbtj/index.vue index 3a30d77..66619c8 100644 --- a/src/views/regional/statistics/bbtj/index.vue +++ b/src/views/regional/statistics/bbtj/index.vue @@ -17,7 +17,7 @@ - + @@ -53,10 +53,13 @@ import { listhospital } from "@/api/regional/dict/hospital.js"; import { listregdict } from "@/api/regional/dict/regdict.js"; import { ElMessage } from 'element-plus'; const aotuSize = classCom.useAutoSize(); +import dayjs from 'dayjs'; +const today = dayjs().format('YYYY-MM-DD'); const queryParams: any = ref({ pageSize: 50, pageNum: 1, + times: [today, today] }) const tableData: any = ref([]) const columns: any = ref([ @@ -64,7 +67,6 @@ const columns: any = ref([ { prop: 'sampletypecode', label: '标本代码', align: 'center', visible: true, }, { prop: 'sampletypename', label: '标本类别', align: 'center', visible: true, }, { prop: 'sl', label: '数量(份)', align: 'center', visible: true, }, - { prop: 'OrderTime', label: '开单时间', align: 'center', visible: true, }, ]) const tableConfig = ref({ border: true, // 边框 @@ -119,6 +121,7 @@ const resetHandle = () => { queryParams.value = { pageSize: 50, pageNum: 1, + times: [today, today] } handleQuery() } @@ -131,7 +134,7 @@ const getList = () => { const hosList = ref([]) const regdictList: any = ref([]) onMounted(() => { - getList() + handleQuery() listhospital().then((res: any) => { hosList.value = res.rows.map((item: any) => { return { diff --git a/src/views/regional/statistics/fytj/index.vue b/src/views/regional/statistics/fytj/index.vue index bd78f59..0763c95 100644 --- a/src/views/regional/statistics/fytj/index.vue +++ b/src/views/regional/statistics/fytj/index.vue @@ -53,10 +53,12 @@ import { listhospital } from "@/api/regional/dict/hospital.js"; import { listregdict } from "@/api/regional/dict/regdict.js"; import { ElMessage } from 'element-plus'; const aotuSize = classCom.useAutoSize(); - +import dayjs from 'dayjs'; +const today = dayjs().format('YYYY-MM-DD'); const queryParams: any = ref({ pageSize: 50, pageNum: 1, + times: [today, today] }) const tableData: any = ref([]) const columns: any = ref([ @@ -128,6 +130,7 @@ const resetHandle = () => { queryParams.value = { pageSize: 50, pageNum: 1, + times: [today, today] } handleQuery() } @@ -140,7 +143,7 @@ const getList = () => { const hosList = ref([]) const regdictList: any = ref([]) onMounted(() => { - getList() + handleQuery() listhospital().then((res: any) => { hosList.value = res.rows.map((item: any) => { return { diff --git a/src/views/regional/statistics/overview/css/index.css b/src/views/regional/statistics/overview/css/index.css index c049f1e..c1c3e6c 100644 --- a/src/views/regional/statistics/overview/css/index.css +++ b/src/views/regional/statistics/overview/css/index.css @@ -6,7 +6,7 @@ width: 100%; min-height: 100vh; background: url(../images/bg2.jpg) no-repeat; - background-size: cover; + background-size: 100% 100%; padding-top: 0rem; padding: 0rem 3.125rem; @@ -113,7 +113,7 @@ font-size: 1.25rem; font-weight: 700; color: #fff; - } +} .leftMain_top ul li .liIn .shu { font-size: 1.875rem; @@ -157,7 +157,11 @@ width: 100%; min-height: 3.75rem; position: relative; - padding: 1.25rem 0.78125rem; + padding: .625rem; +} + +.leftMain_middle_leftIn_zhe { + margin-top: 2vh; } .leftMain_middle .leftMain_middle_left .leftMain_middle_leftIn h3 { @@ -180,7 +184,7 @@ width: 100%; min-height: 3.75rem; position: relative; - padding: 1.25rem 0.78125rem; + padding: .625rem; } .leftMain_middle .leftMain_middle_right .leftMain_middle_rightIn h3 { @@ -197,9 +201,11 @@ /*左边中间部分排行榜*/ .leftMain_middle .leftMain_middle_right .leftMain_middle_rightIn .biaoge_pai { width: 100%; + height: 68vh; overflow: hidden; } + .leftMain_middle .leftMain_middle_right .leftMain_middle_rightIn .biaoge_pai ul li .liIn { display: flex; display: -webkit-flex; @@ -210,15 +216,15 @@ } .leftMain_middle .leftMain_middle_right .leftMain_middle_rightIn .biaoge_pai ul li .liIn .liIn_left { - width: 25%; + width: 43%; position: relative; - padding-left: 2.1875rem; + padding-left: 1.25rem; } .leftMain_middle .leftMain_middle_right .leftMain_middle_rightIn .biaoge_pai ul li .liIn .liIn_left .bot { width: 1.25rem; height: 1.25rem; - background: #f78cf3; + background: #05d1fc; border-radius: 62.5rem; display: block; position: absolute; @@ -248,10 +254,12 @@ background: #05d1fc; } -.leftMain_middle .leftMain_middle_right .leftMain_middle_rightIn .biaoge_pai ul li .liIn .liIn_left zi {} +.leftMain_middle .leftMain_middle_right .leftMain_middle_rightIn .biaoge_pai ul li .liIn .liIn_left zi { + +} .leftMain_middle .leftMain_middle_right .leftMain_middle_rightIn .biaoge_pai ul li .liIn .liIn_line { - width: 58%; + width: 40%; height: 1.25rem; background: rgba(255, 255, 255, 0.5); border-radius: 125rem; @@ -260,7 +268,7 @@ .leftMain_middle .leftMain_middle_right .leftMain_middle_rightIn .biaoge_pai ul li .liIn .liIn_line .line_lineIn { width: 100%; height: 1.25rem; - background: #f78cf3; + background: #05d1fc; border-radius: 6.25rem; -webkit-animation: widthMove1 2s ease-in-out; } @@ -394,13 +402,14 @@ width: 100%; min-height: 3.75rem; position: relative; - padding: 1.25rem 0.78125rem; + padding: .625rem; } .rightMain .rightMain_topIn h3 { font-size: 1.25rem; color: #fff; margin-bottom: 0.78125rem; + font-weight: 700; } .rightMain .rightMain_topIn .biaoge { @@ -423,6 +432,7 @@ font-size: 1.25rem; color: #fff; margin-bottom: 0.78125rem; + font-weight: 700; } /*右下角表格*/ diff --git a/src/views/regional/statistics/overview/css/public.css b/src/views/regional/statistics/overview/css/public.css index 32fd8ac..203b98a 100644 --- a/src/views/regional/statistics/overview/css/public.css +++ b/src/views/regional/statistics/overview/css/public.css @@ -2,7 +2,7 @@ /* CSS Document */ @font-face{ font-family: 'dig'; - src : url('../fonts/DIN-Light'),url('../fonts/DIN-Medium'),url('../fonts/DIN-Bold.otf'); + src : url('../fonts/DIN-Bold.otf'); } body,p,div,h1,h2,h3,h4,h5,h6,button,input,ol,li,ul,dl,dt,dd,img,table,tr,td,th,select{ margin:0; diff --git a/src/views/regional/statistics/overview/index.vue b/src/views/regional/statistics/overview/index.vue index 9c8c6a1..b0b1c05 100644 --- a/src/views/regional/statistics/overview/index.vue +++ b/src/views/regional/statistics/overview/index.vue @@ -63,30 +63,15 @@

委托机构当月送检标本数量

-
+
- -
-
-

当日送检样本情况

-
-
- - - - -
-
- -
-
-
+

近一个月送检标本数量趋势图

-
+
@@ -95,10 +80,25 @@
-

送检项目分类占比

-
- +

委托机构当月送检标本占比

+
+
+ +
    +
  • +
    +
    {{ item.name }}
    +
    +
    +
    +

    {{ item.pre }}%

    +
    +
  • +
+
+
+ @@ -110,8 +110,8 @@
-

这里是标题

-
+

当日送检样本情况

+
@@ -120,8 +120,8 @@
-

这里是标题

-
+

送检项目分类占比

+
@@ -138,13 +138,46 @@