fix:优化看不
This commit is contained in:
@@ -11,6 +11,12 @@ export const constantRouterMap = [
|
||||
component: (resolve) => require(['@/views/login'], resolve),
|
||||
hidden: true
|
||||
},
|
||||
{
|
||||
path: '/screen/fullscreen',
|
||||
meta: { title: 'AGV监控看板', noCache: true },
|
||||
component: (resolve) => require(['@/views/layout/screen/fullscreen'], resolve),
|
||||
hidden: true
|
||||
},
|
||||
{
|
||||
path: '/404',
|
||||
component: (resolve) => require(['@/views/features/404'], resolve),
|
||||
|
||||
1010
acs/nladmin-ui/src/views/layout/screen/fullscreen.vue
Normal file
1010
acs/nladmin-ui/src/views/layout/screen/fullscreen.vue
Normal file
File diff suppressed because it is too large
Load Diff
@@ -22,6 +22,10 @@
|
||||
<i :class="autoRefresh ? 'el-icon-video-play' : 'el-icon-video-pause'" />
|
||||
{{ autoRefresh ? '自动刷新' : '已暂停' }}
|
||||
</el-button>
|
||||
<el-button size="small" type="primary" @click="toggleFullscreen">
|
||||
<i class="el-icon-full-screen" />
|
||||
全屏展示
|
||||
</el-button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -148,7 +152,7 @@
|
||||
class="agv-vehicle"
|
||||
:class="{
|
||||
active: selectedAgv && selectedAgv.carId === agv.carId,
|
||||
'status-normal': agv.status === 2 && !isRequestAction(agv.action),
|
||||
'status-normal': agv.status === 2,
|
||||
'status-rest': agv.status === 1,
|
||||
'status-error': agv.status === 3,
|
||||
'status-request': isRequestAction(agv.action)
|
||||
@@ -289,9 +293,9 @@ export default {
|
||||
const stats = { total: 0, normal: 0, rest: 0, error: 0 }
|
||||
this.agvList.forEach(agv => {
|
||||
stats.total++
|
||||
if (agv.status === 1) stats.rest++
|
||||
else if (agv.status === 2) stats.normal++
|
||||
else if (agv.status === 3) stats.error++
|
||||
if (agv.status == "1") stats.rest++
|
||||
else if (agv.status =="2") stats.normal++
|
||||
else if (agv.status == "3") stats.error++
|
||||
})
|
||||
return stats
|
||||
},
|
||||
@@ -478,6 +482,20 @@ export default {
|
||||
},
|
||||
handleMouseUp() {
|
||||
this.isDragging = false
|
||||
},
|
||||
toggleFullscreen() {
|
||||
// 构建全屏页面URL,传递当前选中的地图ID
|
||||
const baseUrl = window.location.origin + window.location.pathname.replace(/\/[^/]*$/, '')
|
||||
const fullscreenUrl = `${baseUrl}/#/screen/fullscreen?mapId=${this.selectedMapId || ''}`
|
||||
|
||||
// 打开新窗口,设置为全屏
|
||||
const width = window.screen.width
|
||||
const height = window.screen.height
|
||||
window.open(
|
||||
fullscreenUrl,
|
||||
'_blank',
|
||||
`width=${width},height=${height},left=0,top=0,toolbar=no,menubar=no,location=no,status=no`
|
||||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user