-
磁盘占比
+
磁盘占用率
{{ systemData.sysFilesPercentage }}%
@@ -221,7 +221,7 @@ export default {
font-size: 30px !important;
color: #0C0E1E;
&::before {
- content: 'CPU占比';
+ content: 'CPU占用率';
width: 100%;
position: absolute;
top: -85%;
diff --git a/src/views/components/echarts/serverProgress2.vue b/src/views/components/echarts/serverProgress2.vue
deleted file mode 100644
index 074f4ed..0000000
--- a/src/views/components/echarts/serverProgress2.vue
+++ /dev/null
@@ -1,275 +0,0 @@
-
-
-
-
-
-
-
diff --git a/src/views/components/hkVideo.vue b/src/views/components/hkVideo.vue
index 371aaf6..fdc2cab 100644
--- a/src/views/components/hkVideo.vue
+++ b/src/views/components/hkVideo.vue
@@ -35,12 +35,7 @@ export default {
// this.controlVolume()
},
mounted() {
- // video:需要绑定的video控件ID
- // 127.0.0.1:8000:启动webrtc-streamer的设备IP和端口,默认8000
- // eslint-disable-next-line no-undef
- this.webRtcServer = new WebRtcStreamer('video', location.protocol + '//' + this.camera_ip)
- // 需要查看的rtsp地址,根据自己的摄像头传入对应的rtsp地址即可。注意:视频编码格式必须是H264的,否则无法正常显示,编码格式可在摄像头的后台更改
- this.webRtcServer.connect('rtsp://' + this.hkConfig.username + ':' + this.hkConfig.password + '@' + this.hkConfig.ip + ':' + this.hkConfig.port + '/h264/ch1/main/av_stream')
+
},
// 销毁视频流
beforeDestroy() {
@@ -53,6 +48,14 @@ export default {
this.$refs.video1.volume = 0
this.$refs.video2.volume = 0
})
+ },
+ initVideo() {
+ // video:需要绑定的video控件ID
+ // 127.0.0.1:8000:启动webrtc-streamer的设备IP和端口,默认8000
+ // eslint-disable-next-line no-undef
+ this.webRtcServer = new WebRtcStreamer('video', location.protocol + '//' + this.camera_ip)
+ // 需要查看的rtsp地址,根据自己的摄像头传入对应的rtsp地址即可。注意:视频编码格式必须是H264的,否则无法正常显示,编码格式可在摄像头的后台更改
+ this.webRtcServer.connect('rtsp://' + this.hkConfig.username + ':' + this.hkConfig.password + '@' + this.hkConfig.ip + ':' + this.hkConfig.port + '/h264/ch1/main/av_stream')
}
}
}
diff --git a/src/views/components/serveTerminal.vue b/src/views/components/serveTerminal.vue
new file mode 100644
index 0000000..863edda
--- /dev/null
+++ b/src/views/components/serveTerminal.vue
@@ -0,0 +1,302 @@
+
+
+
AI处理终端
+
+
+
所有服务均正常运行,请放心使用
+
请尽快联系系统维护人员进行恢复
+
+
+
+
AI处理终端连接超时,请检查配置是否正确或终端是否运行成功!
+
请尽快联系系统维护人员进行恢复
+
+
+
+
+
+
+
diff --git a/src/views/home.vue b/src/views/home.vue
index dadf79e..4c9b073 100644
--- a/src/views/home.vue
+++ b/src/views/home.vue
@@ -60,8 +60,33 @@
-
+
+
+
+
+
+
+
+
+
+
+
+ {{ GPUName }}
+
+
+
+
+
+
@@ -128,10 +153,16 @@ import taskStockLogEcharts from '@/views/components/echarts/taskStockLog.vue'
import bookSwiper from '@/views/components/bookSwiper.vue'
import checkSwiper from '@/views/components/checkSwiper.vue'
import serverProgress from '@/views/components/echarts/serverProgress.vue'
+import serverGpu from '@/views/components/echarts/serverGpu.vue'
+import serverGpuUse from '@/views/components/echarts/serverGpuUse.vue'
+import serverGpuOther from '@/views/components/echarts/serverGpuOther.vue'
+import serveTerminal from '@/views/components/serveTerminal.vue'
import { FetchInitHomeInfo, FetchInitStockInfo } from '@/api/stockTask/index'
import { FetchInitStockLogList } from '@/api/stockTaskLog/index'
import { FetchSystemInfo } from '@/api/home/cpu/index'
import { mapGetters } from 'vuex'
+import { swiper, swiperSlide } from 'vue-awesome-swiper'
+import 'swiper/dist/css/swiper.css'
export default {
name: 'Dashboard',
@@ -143,7 +174,13 @@ export default {
bookSwiper,
checkSwiper,
// typePie,
- serverProgress
+ serverProgress,
+ serverGpu,
+ serverGpuUse,
+ serverGpuOther,
+ serveTerminal,
+ swiper,
+ swiperSlide
},
data() {
return {
@@ -179,13 +216,33 @@ export default {
addArcivesMonth: [],
addArcivesNum: [],
addArcivesNumFile: []
- }
+ },
+ swiperActiveIndex: 0,
+ swiperOptionServer: {
+ autoplay: {
+ delay: 8000,
+ disableOnInteraction: false
+ },
+ slidesPerView: 'auto',
+ pagination: {
+ el: '.swiper-pagination',
+ clickable: true
+ }
+ },
+ memoryFree: 0,
+ memoryTotal: 0,
+ GPUName: '',
+ temperature: 0,
+ utilization: 0
}
},
computed: {
...mapGetters([
'user'
- ])
+ ]),
+ swiperServer() {
+ return this.$refs.swiperServer.$el.swiper
+ }
},
created() {
this.handleMainData()
@@ -200,6 +257,8 @@ export default {
} else {
this.$refs.bookSwiperRefs.getInitHotShelfList()
}
+
+ this.$refs.serveTerminalRefs.initData()
})
},
mounted() {
@@ -240,6 +299,12 @@ export default {
// 内存占比 使用的memUsed/总的memTotal
this.systemData.memPercentage = Math.round(res.memUsed / res.memTotal * 100)
+ this.memoryFree = res.memoryFree
+ this.memoryTotal = res.memoryTotal
+ this.GPUName = res.GPUName
+ this.temperature = res.temperature
+ this.utilization = res.utilization
+
// 磁盘占比 多个磁盘 使用总和sysFiles[i].used的和/总的总和sysFiles[i].total的和
let sysFilesTotalUsed = 0
let sysFilesTotal = 0
@@ -256,7 +321,14 @@ export default {
memPercentage: 0,
sysFilesPercentage: 0
}
+ this.memoryFree = 0
+ this.memoryTotal = 0
+ this.GPUName = ''
+ this.temperature = 0
+ this.utilization = 0
+
this.getSystemInfo()
+ this.$refs.serveTerminalRefs.initData()
},
getStockLog() {
FetchInitStockLogList().then(res => {
@@ -294,7 +366,7 @@ export default {
position: relative;
.chart-wrapper {
- height: calc(100% - 55px);
+ height: calc(100% - 120px);
}
}
@media (max-width: 1024px) {
@@ -374,4 +446,30 @@ export default {
font-size: 12px;
line-height: 30px;
}
+.swiper-server{
+ position: relative;
+ height: 300px;
+ ::v-deep .swiper-wrapper{
+ height: 344px;
+ }
+ .swiper-pagination{
+ bottom: 80px;
+ }
+}
+
+.cpu-echarts{
+ position: relative;
+ display: flex;
+ justify-content: flex-start;
+ align-items: center;
+ // background-color: #000;
+ .cpu-right{
+ flex: 1;
+ height: 100%;
+ display: flex;
+ justify-content: flex-start;
+ // flex-direction: column;
+ // flex-wrap: wrap;
+ }
+}
diff --git a/src/views/visualCheck/venueDevice/bookshelfPosition/index.vue b/src/views/visualCheck/venueDevice/bookshelfPosition/index.vue
index 8f0b859..eff8333 100644
--- a/src/views/visualCheck/venueDevice/bookshelfPosition/index.vue
+++ b/src/views/visualCheck/venueDevice/bookshelfPosition/index.vue
@@ -155,7 +155,7 @@
-
+
@@ -474,6 +474,9 @@ export default {
'port': res.rtsp
}
this.hkVideoVisible = true
+ this.$nextTick(() => {
+ this.$refs.hkVideoRef.initVideo()
+ })
}
})
},
diff --git a/src/views/visualCheck/venueDevice/device/index.vue b/src/views/visualCheck/venueDevice/device/index.vue
index 12f6ba8..979badc 100644
--- a/src/views/visualCheck/venueDevice/device/index.vue
+++ b/src/views/visualCheck/venueDevice/device/index.vue
@@ -97,7 +97,8 @@
-
+
+
@@ -426,6 +427,17 @@ export default {
this.crud.query.deviceType = this.optionVal
},
[CRUD.HOOK.afterRefresh](crud) {
+ crud.data.forEach(element => {
+ element.deviceState = null
+ this.getDeviceState(element)
+ })
+ },
+ getDeviceState(element) {
+ crudDevice.FetchPingIP({ ip: element.ipv4 }).then((data) => {
+ element.deviceState = data === true ? 1 : 0
+ }).catch((error) => {
+ console.error(error)
+ })
},
handleNodeClick(data) {
this.$nextTick(() => {
@@ -450,6 +462,7 @@ export default {
}
this.crud.toQuery()
+
const params = {
'floorId': this.crud.query.floorId,
'regionId': this.crud.query.regionId