diff --git a/.env.dev b/.env.dev index e1d74744..669fa835 100644 --- a/.env.dev +++ b/.env.dev @@ -4,8 +4,9 @@ NODE_ENV=production VITE_DEV=true # 请求路径 -VITE_BASE_URL='http://192.168.0.74:48080' +# VITE_BASE_URL='http://192.168.0.66:48080' # VITE_BASE_URL='http://192.168.0.189:48080' +VITE_BASE_URL='http://192.168.0.74:48080' # 文件上传类型:server - 后端上传, client - 前端直连上传,仅支持S3服务 VITE_UPLOAD_TYPE=server diff --git a/.env.local b/.env.local index f0650411..a3752946 100644 --- a/.env.local +++ b/.env.local @@ -4,7 +4,7 @@ NODE_ENV=development VITE_DEV=true # 请求路径 -VITE_BASE_URL='http://192.168.0.66:48080' +VITE_BASE_URL='http://192.168.0.74:48080' # VITE_BASE_URL='http://192.168.0.189:48080' # 文件上传类型:server - 后端上传, client - 前端直连上传,仅支持 S3 服务 diff --git a/package-lock.json b/package-lock.json index 1727efe8..e058cf2c 100644 --- a/package-lock.json +++ b/package-lock.json @@ -51,9 +51,11 @@ "qs": "^6.12.0", "sortablejs": "^1.15.3", "steady-xml": "^0.1.0", + "swiper": "^8.4.7", "url": "^0.11.3", "video.js": "^7.21.5", "vue": "3.5.12", + "vue-awesome-swiper": "^5.0.1", "vue-dompurify-html": "^4.1.4", "vue-i18n": "9.10.2", "vue-router": "4.4.5", @@ -16573,6 +16575,42 @@ "integrity": "sha512-dn6wd0uw5GsdswPFfsgMp5NSB0/aDe6fK94YJV/AJDYXL6HVLWBsxeq7js7Ad+mU2K9LAlwpk6kN2D5mwCPVow==", "dev": true }, + "node_modules/swiper": { + "version": "8.4.7", + "resolved": "https://registry.npmmirror.com/swiper/-/swiper-8.4.7.tgz", + "integrity": "sha512-VwO/KU3i9IV2Sf+W2NqyzwWob4yX9Qdedq6vBtS0rFqJ6Fa5iLUJwxQkuD4I38w0WDJwmFl8ojkdcRFPHWD+2g==", + "funding": [ + { + "type": "patreon", + "url": "https://www.patreon.com/swiperjs" + }, + { + "type": "open_collective", + "url": "http://opencollective.com/swiper" + } + ], + "hasInstallScript": true, + "dependencies": { + "dom7": "^4.0.4", + "ssr-window": "^4.0.2" + }, + "engines": { + "node": ">= 4.7.0" + } + }, + "node_modules/swiper/node_modules/dom7": { + "version": "4.0.6", + "resolved": "https://registry.npmmirror.com/dom7/-/dom7-4.0.6.tgz", + "integrity": "sha512-emjdpPLhpNubapLFdjNL9tP06Sr+GZkrIHEXLWvOGsytACUrkbeIdjO5g77m00BrHTznnlcNqgmn7pCN192TBA==", + "dependencies": { + "ssr-window": "^4.0.0" + } + }, + "node_modules/swiper/node_modules/ssr-window": { + "version": "4.0.2", + "resolved": "https://registry.npmmirror.com/ssr-window/-/ssr-window-4.0.2.tgz", + "integrity": "sha512-ISv/Ch+ig7SOtw7G2+qkwfVASzazUnvlDTwypdLoPoySv+6MqlOV10VwPSE6EWkGjhW50lUmghPmpYZXMu/+AQ==" + }, "node_modules/synckit": { "version": "0.8.8", "resolved": "https://registry.npmmirror.com/synckit/-/synckit-0.8.8.tgz", @@ -17918,6 +17956,15 @@ } } }, + "node_modules/vue-awesome-swiper": { + "version": "5.0.1", + "resolved": "https://registry.npmmirror.com/vue-awesome-swiper/-/vue-awesome-swiper-5.0.1.tgz", + "integrity": "sha512-mWjFJzUqA4lG+DmsmibvMpoiBnl+IH2SSeiiQ3i5M0t1y9FknTxnGT0DsMb2YdJLgjYMEK3sYOWzqgLnZMH8Lg==", + "peerDependencies": { + "swiper": "^7.0.0 || ^8.0.0", + "vue": "3.x" + } + }, "node_modules/vue-dompurify-html": { "version": "4.1.4", "resolved": "https://registry.npmmirror.com/vue-dompurify-html/-/vue-dompurify-html-4.1.4.tgz", @@ -30293,6 +30340,30 @@ } } }, + "swiper": { + "version": "8.4.7", + "resolved": "https://registry.npmmirror.com/swiper/-/swiper-8.4.7.tgz", + "integrity": "sha512-VwO/KU3i9IV2Sf+W2NqyzwWob4yX9Qdedq6vBtS0rFqJ6Fa5iLUJwxQkuD4I38w0WDJwmFl8ojkdcRFPHWD+2g==", + "requires": { + "dom7": "^4.0.4", + "ssr-window": "^4.0.2" + }, + "dependencies": { + "dom7": { + "version": "4.0.6", + "resolved": "https://registry.npmmirror.com/dom7/-/dom7-4.0.6.tgz", + "integrity": "sha512-emjdpPLhpNubapLFdjNL9tP06Sr+GZkrIHEXLWvOGsytACUrkbeIdjO5g77m00BrHTznnlcNqgmn7pCN192TBA==", + "requires": { + "ssr-window": "^4.0.0" + } + }, + "ssr-window": { + "version": "4.0.2", + "resolved": "https://registry.npmmirror.com/ssr-window/-/ssr-window-4.0.2.tgz", + "integrity": "sha512-ISv/Ch+ig7SOtw7G2+qkwfVASzazUnvlDTwypdLoPoySv+6MqlOV10VwPSE6EWkGjhW50lUmghPmpYZXMu/+AQ==" + } + } + }, "synckit": { "version": "0.8.8", "resolved": "https://registry.npmmirror.com/synckit/-/synckit-0.8.8.tgz", @@ -31306,6 +31377,12 @@ } } }, + "vue-awesome-swiper": { + "version": "5.0.1", + "resolved": "https://registry.npmmirror.com/vue-awesome-swiper/-/vue-awesome-swiper-5.0.1.tgz", + "integrity": "sha512-mWjFJzUqA4lG+DmsmibvMpoiBnl+IH2SSeiiQ3i5M0t1y9FknTxnGT0DsMb2YdJLgjYMEK3sYOWzqgLnZMH8Lg==", + "requires": {} + }, "vue-dompurify-html": { "version": "4.1.4", "resolved": "https://registry.npmmirror.com/vue-dompurify-html/-/vue-dompurify-html-4.1.4.tgz", diff --git a/package.json b/package.json index 436629f5..47eef7ed 100644 --- a/package.json +++ b/package.json @@ -67,9 +67,11 @@ "qs": "^6.12.0", "sortablejs": "^1.15.3", "steady-xml": "^0.1.0", + "swiper": "^8.4.7", "url": "^0.11.3", "video.js": "^7.21.5", "vue": "3.5.12", + "vue-awesome-swiper": "^5.0.1", "vue-dompurify-html": "^4.1.4", "vue-i18n": "9.10.2", "vue-router": "4.4.5", diff --git a/src/api/car/index.ts b/src/api/car/index.ts new file mode 100644 index 00000000..34b7f398 --- /dev/null +++ b/src/api/car/index.ts @@ -0,0 +1,56 @@ +import request from '@/config/axios' + +//agv 下载 +export const agvDownload = async (params) => { + return await request.download({ url: `/system/position-map/agvDownload`, params }) +} +//点位地图列表 +export const getPositionMapList = async (params) => { + return await request.get({ url: `/system/position-map/list`, params }) +} + +//删除车辆信息 +export const deleteRobotInformation = async (id: number) => { + return await request.delete({ url: `/system/robot/information/delete?id=` + id }) +} + +//查询所有车辆 +export const getAllRobot = async (data) => { + return await request.post({ url: `/system/robot/information/getAllRobot`, data }) +} +//获得车辆信息 详情 +export const getRobotInformation = async (params) => { + return await request.get({ url: `/system/robot/information/get`, params }) +} + +//分页查询车辆列表 看板信息车辆目前用的是这个 +export const robotInformationPage = async (params) => { + return await request.get({ url: `/system/robot/information/page`, params }) +} +//统计车辆待命-任务中-离线 +export const robotInformationStatistics = async (data) => { + return await request.post({ url: `/system/robot/information/statistics`, data }) +} + +// 创建车辆信息 +export const robotInformationCreate = async (data) => { + return await request.post({ url: `/system/robot/information/create`, data }) +} +// 编辑车辆信息 +export const robotInformationUpdate = async (data) => { + return await request.put({ url: `/system/robot/information/update`, data }) +} +//分页查询车辆列表 看板信息车辆目前用的是这个 +export const robotGetAllModel = async (params) => { + return await request.get({ url: `/system/robot/model/getAllModel`, params }) +} +// 范围选择 +export const robotPositionGetMap = async (params) => { + return await request.get({ url: `/system/position-map/getMap`, params }) +} +// 完整范围选择 +export const robotPositionGetMapAll = async (params) => { + return await request.get({ url: `/system/position-map/getAllMap`, params }) +} + + diff --git a/src/api/carError/index.ts b/src/api/carError/index.ts new file mode 100644 index 00000000..7edb71fd --- /dev/null +++ b/src/api/carError/index.ts @@ -0,0 +1,11 @@ +import request from '@/config/axios' + + +//获得机器人告警信息分页 +export const getRobotWarnMsgPage = async (params) => { + return await request.get({ url: `/system/robot/warn-msg/page`, params }) +} + + + + diff --git a/src/assets/imgs/chache.jpg b/src/assets/imgs/chache.jpg new file mode 100644 index 00000000..e50129da Binary files /dev/null and b/src/assets/imgs/chache.jpg differ diff --git a/src/main.ts b/src/main.ts index 72ff7c67..7b427dcc 100644 --- a/src/main.ts +++ b/src/main.ts @@ -43,10 +43,13 @@ import Logger from '@/utils/Logger' import VueDOMPurifyHTML from 'vue-dompurify-html' // 解决v-html 的安全隐患 import VueDragResizeRotate from '@gausszhou/vue3-drag-resize-rotate' import '@gausszhou/vue3-drag-resize-rotate/lib/bundle.esm.css' +import * as ElementPlusIconsVue from '@element-plus/icons-vue' // 创建实例 const setupAll = async () => { const app = createApp(App) - + for (const [key, component] of Object.entries(ElementPlusIconsVue)) { + app.component(key, component) + } await setupI18n(app) setupStore(app) @@ -68,6 +71,7 @@ const setupAll = async () => { app.use(VueDOMPurifyHTML) app.use(VueDragResizeRotate) app.mount('#app') + } setupAll() diff --git a/src/views/board/carBoard/createEditDialog.vue b/src/views/board/carBoard/createEditDialog.vue new file mode 100644 index 00000000..276213c0 --- /dev/null +++ b/src/views/board/carBoard/createEditDialog.vue @@ -0,0 +1,292 @@ + + + + + + + + + + + + + + + + + + + + % + + % + + + + + + + + + + + 确 定 + 取 消 + + + + + + diff --git a/src/views/board/carBoard/index.vue b/src/views/board/carBoard/index.vue new file mode 100644 index 00000000..d0e68c06 --- /dev/null +++ b/src/views/board/carBoard/index.vue @@ -0,0 +1,481 @@ + + + + + 新增车辆 + + + + + + + + + + + + + + + + 地图定位 + {{ item.robotNo || '' }} + + + + + + + + 编辑 + {{ item.status == 0 ? '解锁' : '锁定' }} + 删除 + + + + + + + + + + + + 电量 + + {{ item.electricity || '' }} % + 无电量数据 + + + 状态 + + + {{ + item.status == 0 + ? '暂停且无任务' + : item.status == 1 + ? '暂停(有处理中的任务)' + : item.status == 2 + ? '任务中' + : '待命' + }} + + + + 楼层 + 1 + + + 区域 + A + + + 信息 + 车辆正在待命 + + 日志查看 + + + + + + + + + + + + + + + + + + + + + 地图定位 + {{ item.robotNo || '' }} + + + + + + + + 编辑 + {{ item.status == 0 ? '解锁' : '锁定' }} + 删除 + + + + + + + + + + + + 电量 + + {{ item.electricity || '' }} % + 无电量数据 + + + 状态 + + + {{ + item.status == 0 + ? '暂停且无任务' + : item.status == 1 + ? '暂停(有处理中的任务)' + : item.status == 2 + ? '任务中' + : '待命' + }} + + + + 楼层 + {{ item.floor || '未知' }} + + + 区域 + {{ item.area || '未知' }} + + + 信息 + {{ item.msg || '' }} + + 日志查看 + + + + + + + + + + 待命中: + + {{ carStatistics.standby || 0 }} + + + + 任务中: + + {{ carStatistics.inTask || 0 }} + + + + 充电中: + + {{ carStatistics.charge || 0 }} + + + + 离线: + + {{ carStatistics.offline || 0 }} + + + + + + + + + + + + diff --git a/src/views/carError/index.vue b/src/views/carError/index.vue new file mode 100644 index 00000000..e221bbd8 --- /dev/null +++ b/src/views/carError/index.vue @@ -0,0 +1,188 @@ + + + + + + + + + + + + 搜索 + 重置 + + + + + + + + + + + + + + + {{ formatDate(scope.row.createTime, 'YYYY-MM-DD HH:mm:ss') }} + + + + + + + + + + +