@@ -20,7 +20,14 @@ const routes: Array<RouteRecordRaw> = [
meta: {
title: '宜宾市12345坐席监控中心',
}
- }
+ },{
+ path: '/home',
+ name: 'home',
+ component: () => import('@/views/home/index.vue'),
+ meta: {
+ title: '',
+ }
+ },
]
const router = createRouter({
history: createWebHistory(import.meta.env.BASE_URL),
@@ -0,0 +1,10 @@
+<template>
+12321
+</template>
+<script setup lang="ts" name="home">
+
+</script>
+<style scoped lang="scss">
+</style>
@@ -187,7 +187,6 @@ export const optionHandle = (regionCode: string,
position: 'left',
formatter: function (params: any) {
if (params.data) {
- console.log(params); //params是echarts的属性
const res = params.data; //res等于params下的数据
//return回调一个模板字符串,自定义提示框的形状
return `
@@ -202,8 +202,14 @@ watch(()=>props.content,(val:any)=>{
setOption(data);
}, 100);
});
+watch(
+ () => props.data,
+ (newData:any) => {
+ seatsList.value = newData;
+ { immediate: true }
+);
onMounted(() => {
- seatsList.value = props.data;
mittBus.on('SeatState', (res: any) => {
const item = seatsList.value.find((item: any) => item.telNo === res.telNo);
if (item) {