AaronBruin 3 月之前
父節點
當前提交
d285742f1d

+ 2 - 3
src/layout/components/AppMain.vue

@@ -35,11 +35,10 @@ function addIframe() {
 
 <style lang="scss" scoped>
 .app-main {
-  /* 50= navbar  50  */
-  min-height: 100vh;
+  // min-height: 100vh;
+  height: 100%;
   width: 100%;
   position: relative;
-//   overflow: auto;
   overflow: hidden;
 }
 

+ 5 - 7
src/layout/index.vue

@@ -1,15 +1,13 @@
 <template>
-    <div class="app">
-
-        <div :class="classObj" class="app-wrapper">
-            <dv-full-screen-container>
+    <dv-full-screen-container>
+        <div class="app">
+            <div :class="classObj" class="app-wrapper">
                 <logo :collapse="isCollapse" class="fixed-header" />
                 <app-main />
                 <sidebar v-if="!sidebar.hide" class="fixed-bottom" />
-            </dv-full-screen-container>
-
+            </div>
         </div>
-    </div>
+    </dv-full-screen-container>
 </template>
 
 <script setup>

+ 2 - 1
src/views/index.vue

@@ -14,7 +14,8 @@ import reightDesk from './index/reightDesk.vue'
 .home {
   position: relative;
   width: 100%;
-  height: 100vh;
+  // height: 100vh;
+  height: 100%;
   padding-top: 45px;
   overflow: hidden;
 }

+ 4 - 4
src/views/system/entranceguard/inbreak.vue

@@ -37,7 +37,7 @@ const initAccess = () => {
         }
         return newParamsName
     }
-    let xData = ['“专精特新” 母基金', '职能制造 产业基金', '半导体材料 产业基金', '精密制造装备 产业基金', '现代消费与 医疗产业基金']
+    let xData = ['12.20', '12.30', '12.40', '12.50', '13.00']
     let y1Data = [110, 90, 120, 70, 60]
     let y2Data = [15, 22, 13, 22, 13]
     chartDom = echarts.init(chartDistrict.value);
@@ -63,7 +63,7 @@ const initAccess = () => {
             },
         },
         legend: {
-            data: ['项目数量', '总投资额'],
+            data: ['非法入侵', '非法入侵1'],
             right: 'center',
             top: '6%',
             itemWidth: 11,
@@ -149,7 +149,7 @@ const initAccess = () => {
         },
         ],
         series: [{
-            name: '项目数量',
+            name: '非法入侵',
             yAxisIndex: 0,
             color: 'rgba(208, 222, 238, .5)',
             lineStyle: {
@@ -159,7 +159,7 @@ const initAccess = () => {
             data: y1Data,
         },
         {
-            name: '总投资额',
+            name: '非法入侵1',
             type: 'bar',
             label: {
                 normal: {

+ 7 - 3
src/views/system/entranceguard/index.vue

@@ -16,16 +16,19 @@
         </div>
         <div class="right_guard_flow">
             <div class="flex_spection">
-                <HeadlineTag type="right" value="门禁系统"></HeadlineTag>
+                <HeadlineTag type="right" value="今日通行数据概览"></HeadlineTag>
+                <div class="box_arch">
+                    <passable></passable>
+                </div>
             </div>
             <div class="flex_spection">
-                <HeadlineTag type="right" value="出入口管理"></HeadlineTag>
+                <HeadlineTag type="right" value="出入记录统计"></HeadlineTag>
                 <div class="box_arch">
                     <alleyway></alleyway>
                 </div>
             </div>
             <div class="flex_spection">
-                <HeadlineTag type="right" value="门禁系统"></HeadlineTag>
+                <HeadlineTag type="right" value="实时告警与通知"></HeadlineTag>
             </div>
         </div>
     </div>
@@ -36,6 +39,7 @@ import HeadlineTag from '@/components/HeadlineTag'
 import alleyway from './alleyway'
 import equipment from './equipment'
 import inbreak from './inbreak'
+import passable from './passable'
 </script>
 
 <style scoped lang="scss">

+ 495 - 0
src/views/system/entranceguard/passable.vue

@@ -0,0 +1,495 @@
+<template>
+    <div class="person_box">
+        <dv-border-box-1>
+            <div class="box_monitoring">
+                <div class="flex_spection box_tion_zx">
+                    <div class="line_blue">
+                        <div class="blue_dot"></div>
+                    </div>
+                    <div class="monit_title">在线</div>
+                    <span class="monit_num">83</span>
+                </div>
+                <div class="camera">
+                    <div class="entry-box">
+                        <div class="entry-box-item">
+                            <div class="item-center-line"></div>
+                            <div class="item-center-pie"></div>
+                        </div>
+                    </div>
+                    <div class="img_camera">
+                        <div ref="chartDistrict" style="width: 100%;height: 100%;"></div>
+                    </div>
+                </div>
+                <div class="flex_spection box_tion_lx">
+                    <div class="line_green">
+                        <div class="green_dot"></div>
+                    </div>
+                    <div class="monit_title">离线</div>
+                    <span class="monit_num">23</span>
+                </div>
+            </div>
+        </dv-border-box-1>
+    </div>
+</template>
+
+<script setup>
+import * as echarts from 'echarts'
+defineProps({
+    title: {
+        type: String,
+        default: '暂无数据'
+    }
+})
+const chartDistrict = ref(null);
+let chartDom = null;
+const initAccess = () => {
+    chartDom = echarts.init(chartDistrict.value);
+    let option = {
+        graphic: {
+            elements: [
+                {
+                    zlevel: 101,
+                    type: 'rect',
+                    left: 'center',
+                    top: 396,
+                    shape: {
+                        x: 0, // 矩形的 x 坐标
+                        y: 0, // 矩形的 y 坐标
+                        width: 28, // 矩形的宽度
+                        height: 3, // 矩形的高度
+                    },
+                    style: {
+                        fill: '#005AFF', // 设置背景颜色为半透明白色
+                        stroke: 'none',
+                    },
+                },
+                {
+                    zlevel: 101,
+                    type: 'text',
+                    left: 'center',
+                    top: 410,
+                    style: {
+                        text: '完成率',
+                        textAlign: 'center',
+                        fill: '#75AFFC',
+                        fontSize: 12,
+                    },
+                },
+            ],
+        },
+        series: [
+            {
+                title: {
+                    show: false,
+                    offsetCenter: [0, '60%'],
+                    padding: [5, 10],
+                    fontSize: 12,
+                    color: '#E9F7FF',
+                },
+                zlevel: 100,
+                name: '外部',
+                type: 'gauge',
+                radius: '100%',
+                center: ['50%', '50%'],
+                itemStyle: {
+                    color: new echarts.graphic.LinearGradient(0, 1, 0, 0, [
+                        {
+                            offset: 0,
+                            color: '#030C1D',
+                        },
+                        {
+                            offset: 0.5,
+                            color: '#005AFF',
+                        },
+                        {
+                            offset: 1,
+                            color: '#005AFF',
+                        },
+                    ]),
+                },
+                progress: {
+                    show: true,
+                    width: 13,
+                    roundCap: false,
+                },
+                axisLine: {
+                    lineStyle: {
+                        width: 2,
+                        type: 'dashed',
+                        color: [[1, '#a3b3d0']],
+                    },
+                },
+                sartAngle: 225,
+                endAngle: -45,
+                clockwise: true,
+                min: 0,
+                max: 100,
+                splitNumber: 10,
+                axisLabel: {
+                    textStyle: {
+                        color: '#75AFFC',
+                        fontSize: 20,
+                    },
+                },
+                pointer: {
+                    show: false,
+                    icon: 'triangle',
+                    width: '40%', //指针的宽度
+                    length: '170%', //指针长度,按照半圆半径的百分比
+                },
+                detail: {
+                    valueAnimation: true,
+                    // width: '60%',
+                    // lineHeight: 1,
+                    // borderRadius: 8,
+                    offsetCenter: [0, '-3%'],
+                    fontSize: 24,
+                    color: '#E9F7FF',
+                    textStyle: {
+                        fontFamily: 'MyFont2',
+                    },
+                    formatter: function (val) {
+                        let str = val + '{a|%}'
+                        return str
+                    },
+                    rich: {
+                        a: {
+                            color: '#E9F7FF',
+                            fontSize: 19,
+                            padding: [6, 0, 0, 0],
+                        },
+                    },
+                },
+                offsetCenter: [0, 10],
+                markPoint: {
+                    symbol: 'circle',
+                    symbolSize: 80,
+                    data: [
+                        {
+                            x: 'center',
+                            y: '50%',
+                            itemStyle: {
+                                color: ' rgba(23,39,90,0.54)', // 指针颜色,默认(auto)取数值所在的区间的颜色
+                                borderWidth: 1, // 描边线宽,默认 0。为 0 时无描边。
+                                borderType: 'solid', // 柱条的描边类型,默认为实线,支持 'solid', 'dashed', 'dotted'。
+                                borderColor: '#3375E8', // 图形的描边颜色,默认 "#000"。支持的颜色格式同 color,不支持回调函数。
+                                shadowBlur: 5, // (发光效果)图形阴影的模糊大小。该属性配合 shadowColor,shadowOffsetX, shadowOffsetY 一起设置图形的阴影效果。
+                                shadowColor: '#08398b',
+                                opacity: 1,
+                            },
+                        },
+                    ],
+                },
+                data: [
+                    {
+                        name: '完成率',
+                        value: 82,
+                    },
+                ],
+            },
+            {
+                name: '内部刻度',
+                type: 'gauge',
+                backgroundColor: '#071d3f',
+                center: ['50%', '50%'],
+                itemStyle: {
+                    shadowBlur: 10, // (发光效果)图形阴影的模糊大小。该属性配合 shadowColor,shadowOffsetX, shadowOffsetY 一起设置图形的阴影效果。
+                    shadowColor: '#08398b',
+                    color: new echarts.graphic.LinearGradient(0, 1, 0, 0, [
+                        {
+                            offset: 0,
+                            color: '#0548c3',
+                        },
+                        {
+                            offset: 1,
+                            color: '#005afe',
+                        },
+                    ]),
+                },
+                progress: {
+                    show: true,
+                    width: 2,
+                },
+                radius: '78%',
+                axisTick: {
+                    //一个一个的小刻度
+                    show: false,
+                },
+                axisLabel: {
+                    //周围刻度线的数字
+                    show: false,
+                },
+                splitLine: {
+                    show: false,
+                },
+                detail: {
+                    show: false,
+                },
+                axisLine: {
+                    show: false,
+                },
+                pointer: {
+                    icon: 'triangle',
+                    width: '60%', //指针的宽度
+                    length: '70%', //指针长度,按照半圆半径的百分比
+                },
+                data: [
+                    {
+                        name: '',
+                        value: 82,
+                    },
+                ],
+            },
+            {
+                name: '内部圆圈',
+                type: 'gauge',
+                center: ['50%', '50%'],
+                itemStyle: {
+                    shadowBlur: 10, // (发光效果)图形阴影的模糊大小。该属性配合 shadowColor,shadowOffsetX, shadowOffsetY 一起设置图形的阴影效果。
+                    shadowColor: '#08398b',
+                    color: new echarts.graphic.LinearGradient(0, 1, 0, 0, [
+                        {
+                            offset: 0,
+                            color: '#061d3e',
+                        },
+                        {
+                            offset: 0.5,
+                            color: '#073b97',
+                        },
+                    ]),
+                },
+                progress: {
+                    show: true,
+                    width: 2,
+                },
+                radius: '55%',
+                axisTick: {
+                    //一个一个的小刻度
+                    show: false,
+                },
+                axisLabel: {
+                    //周围刻度线的数字
+                    show: false,
+                },
+                splitLine: {
+                    show: false,
+                },
+                detail: {
+                    show: false,
+                },
+                pointer: {
+                    show: false,
+                },
+                axisLine: {
+                    show: false,
+                },
+                data: [
+                    {
+                        name: '',
+                        value: 100,
+                    },
+                ],
+            },
+            {
+                name: '遮罩',
+                tooltip: {
+                    show: false,
+                },
+                type: 'pie',
+                radius: '36%',
+                center: ['50%', '50%'], // 默认全局居中
+                hoverAnimation: false,
+                itemStyle: {
+                    normal: {
+                        color: '#071d3f',
+                    },
+                    emphasis: {
+                        color: '#071d3f',
+                    },
+                },
+                labelLine: {
+                    normal: {
+                        show: false,
+                    },
+                },
+                animation: false,
+                data: [1.9],
+            },
+        ],
+    };
+    chartDom.setOption(option)
+};
+// 生命周期
+onMounted(() => {
+    initAccess()
+});
+// 窗口自适应
+window.addEventListener('resize', () => {
+    chartDom?.resize();
+});
+</script>
+
+<style scoped lang="scss">
+.person_box {
+    width: 100%;
+    height: 100%;
+    // padding: 0px;
+    display: flex;
+    align-items: center;
+}
+
+.box_monitoring {
+    display: flex;
+    align-items: center;
+    height: 100%;
+    padding: 20px;
+}
+
+.line_blue {
+    position: relative;
+    height: 5px;
+    width: 70%;
+    background-color: rgba(5, 125, 230, .5);
+    margin-bottom: 10px;
+}
+
+.blue_dot {
+    position: absolute;
+    left: 5px;
+    top: 0;
+    bottom: 0;
+    width: 20px;
+    border-left: 5px solid #000;
+    border-right: 5px solid #000;
+    background-color: rgba(5, 125, 230, 1);
+}
+
+.line_green {
+    position: relative;
+    height: 5px;
+    width: 70%;
+    background-color: rgba(5, 227, 227, .5);
+    margin-bottom: 10px;
+}
+
+.green_dot {
+    position: absolute;
+    left: 5px;
+    top: 0;
+    bottom: 0;
+    width: 20px;
+    border-left: 5px solid #000;
+    border-right: 5px solid #000;
+    background-color: rgba(5, 227, 227, 1);
+}
+
+.img_camera {
+    position: absolute;
+    width: 120px;
+    height: 120px;
+    top: calc(50% - 60px);
+    left: calc(50% - 60px);
+    border-radius: 50%;
+    border: 1px solid rgb(15, 39, 66);
+    box-shadow: inset 0px 0px 20px 2px rgb(78, 207, 220);
+}
+
+.flex_spection {
+    flex: 1;
+}
+
+.camera {
+    width: 190px;
+    height: 100%;
+    display: flex;
+    position: relative;
+
+    .entry-box {
+        width: 100%;
+        height: 100%;
+        object-fit: fill;
+        position: absolute;
+        top: 0;
+        left: 0;
+        display: flex;
+        align-items: center;
+        justify-content: center;
+    }
+
+    .entry-box-item {
+        width: 100%;
+        height: 180px;
+        color: #fff;
+        display: flex;
+        justify-content: center;
+        align-items: center;
+        position: relative;
+        background: radial-gradient(circle,
+                rgba(51, 149, 233, 0) 100px,
+                rgba(51, 149, 233, 0) 100px);
+
+        .item-center-line {
+            width: 180px;
+            height: 180px;
+            background-color: transparent;
+            border-top: 3px solid rgb(22, 110, 191);
+            border-bottom: 3px solid rgb(22, 110, 191);
+            border-radius: 50%;
+            box-sizing: border-box;
+            position: absolute;
+            top: calc(50% - 90px);
+            left: calc(50% - 90px);
+            animation: rotate 8s infinite linear;
+        }
+
+        .item-center-pie {
+            width: 150px;
+            height: 150px;
+            background-color: transparent;
+            border-top: 2px solid rgb(22, 110, 191);
+            border-bottom: 2px solid rgb(22, 110, 191);
+            border-radius: 50%;
+            box-sizing: border-box;
+            position: absolute;
+            top: calc(50% - 75px);
+            left: calc(50% - 75px);
+            animation: rotate1 8s infinite linear;
+        }
+    }
+}
+
+/* 定义中间球体顺时针转动 */
+@keyframes rotate {
+    from {
+        transform: rotate(0deg);
+    }
+
+    to {
+        transform: rotate(360deg);
+    }
+}
+
+/* 定义中间圆逆时针转动 */
+@keyframes rotate1 {
+    from {
+        transform: rotate(0deg);
+    }
+
+    to {
+        transform: rotate(-360deg);
+    }
+}
+
+.monit_title {
+    font-size: 16px;
+    background-image: -webkit-linear-gradient(bottom, rgb(120, 173, 221), rgb(229, 232, 236));
+    -webkit-background-clip: text;
+    -webkit-text-fill-color: transparent;
+    padding: 6px 0px;
+}
+
+.monit_num {
+    font-size: 30px;
+    font-weight: bold;
+}
+</style>