From 53cacb507c9e261c41a1a7e4934501adfb73353f Mon Sep 17 00:00:00 2001 From: wangwenhua <12345678> Date: Fri, 26 Sep 2025 19:44:54 +0800 Subject: [PATCH 1/2] a --- .env.development | 4 +- .env.production | 2 +- public/config.js | 6 +- src/views/subsystem/model/index.vue | 49 +++++++++- src/views/subsystem/scene/index.vue | 107 +++++++++++++++++++++- src/views/subsystem/scene/presetting.vue | 112 ++++++++++++++++++++++- vue.config.js | 2 +- 7 files changed, 270 insertions(+), 12 deletions(-) diff --git a/.env.development b/.env.development index 60617e5..041ec31 100644 --- a/.env.development +++ b/.env.development @@ -1,6 +1,6 @@ NODE_ENV=development VUE_APP_PREVIEW=true VUE_APP_API_BASE_URL=/api -VUE_APP_API_URL=http://192.168.0.53:8099 +VUE_APP_API_URL=http://192.168.0.225:8099 VUE_APP_MAP_BASE_URL=/map -VUE_APP_MAP_URL=http://192.168.0.53:8090 +VUE_APP_MAP_URL=http://192.168.0.225:8090 \ No newline at end of file diff --git a/.env.production b/.env.production index 7d88973..b3cfff7 100644 --- a/.env.production +++ b/.env.production @@ -1,4 +1,4 @@ NODE_ENV=production VUE_APP_PREVIEW=true VUE_APP_API_BASE_URL=/api -VUE_APP_API_URL=http://192.168.0.53:8099 +VUE_APP_API_URL=http://192.168.0.225:8099 diff --git a/public/config.js b/public/config.js index c8b0cba..82f5d57 100644 --- a/public/config.js +++ b/public/config.js @@ -5,7 +5,7 @@ window._CONFIG = { TerrainProviderUrl: '/map/mapTerrain/', thirdLoginUrl: 'http://127.0.0.1:8080/thirdLogin', clientId: '0123456789', - evaluationSrc: 'http://192.168.0.53:8088/thirdLogin/thirdLoginPage?username=admin', - VUE_APP_API_URL: 'http://192.168.0.53:8099', - VUE_APP_WEBSOCKET_URL: 'ws://192.168.0.53:8099', + evaluationSrc: 'http://192.168.0.189:8088/thirdLogin/thirdLoginPage?username=admin', + VUE_APP_API_URL: 'http://192.168.0.225:8099', + VUE_APP_WEBSOCKET_URL: 'ws://192.168.0.225:8099', } diff --git a/src/views/subsystem/model/index.vue b/src/views/subsystem/model/index.vue index b6fe91f..e0b4e01 100644 --- a/src/views/subsystem/model/index.vue +++ b/src/views/subsystem/model/index.vue @@ -58,12 +58,12 @@ - + –> key === item.key); + if (target) { + target[column] = value; + this.data = newData; + } + }, + edit(key) { + const newData = [...this.data]; + const target = newData.find(item => key === item.key); + if (target) { + target.editable = true; + this.data = newData; + } + }, + save(key) { + const newData = [...this.data]; + const target = newData.find(item => key === item.key); + if (target) { + delete target.editable; + this.data = newData; + } + }, + cancel(key) { + const newData = [...this.data]; + const target = newData.find(item => key === item.key); + if (target) { + Object.assign(target, this.cacheData.find(item => key === item.key)); + delete target.editable; + this.data = newData; + } + }, + handleDelete(key) { + this.data = this.data.filter(item => item.key !== key); + }, + handleAdd() { + this.data.push({ + key: Date.now(), + name: '', + age: null, + address: '', + editable: true + }); + }, getTree(target, treeData, showKeys) { treeData.forEach((item) => { const newChildren = [] diff --git a/src/views/subsystem/scene/index.vue b/src/views/subsystem/scene/index.vue index 87ace9f..8637a8b 100644 --- a/src/views/subsystem/scene/index.vue +++ b/src/views/subsystem/scene/index.vue @@ -56,7 +56,45 @@ - + + + 新增 + + + + handleChange(e.target.value, record.key, col)" + /> + {{ text }} + + + + + + 保存 + + 取消 + + + 编辑 + + handleDelete(record.key)"> + 删除 + + + + + + + { this.childWindow && this.childWindow.close() return true // 必须设置 returnValue 才能显示确认框 @@ -276,6 +327,60 @@ export default { }) }, methods: { + getWeathers(){ + this.$http({ + url: `/baseData/weatherResource/list`, + method: 'get', + params: { scenarioId: this.scenarioId}, + }).then(res => { + this.data = res.data + }) + }, + handleChange(value, key, column) { + const newData = [...this.data]; + const target = newData.find(item => key === item.key); + if (target) { + target[column] = value; + this.data = newData; + } + }, + edit(key) { + const newData = [...this.data]; + const target = newData.find(item => key === item.key); + if (target) { + target.editable = true; + this.data = newData; + } + }, + save(key) { + const newData = [...this.data]; + const target = newData.find(item => key === item.key); + if (target) { + delete target.editable; + this.data = newData; + } + }, + cancel(key) { + const newData = [...this.data]; + const target = newData.find(item => key === item.key); + if (target) { + // Object.assign(target, this.newData.find(item => key === item.key)); + delete target.editable; + this.data = newData; + } + }, + handleDelete(key) { + this.data = this.data.filter(item => item.key !== key); + }, + handleAdd() { + this.data.push({ + key: Date.now(), + name: '', + age: null, + address: '', + editable: true + }); + }, getTree(target, treeData, showKeys) { treeData.forEach((item) => { const newChildren = [] diff --git a/src/views/subsystem/scene/presetting.vue b/src/views/subsystem/scene/presetting.vue index eb35543..229baf6 100644 --- a/src/views/subsystem/scene/presetting.vue +++ b/src/views/subsystem/scene/presetting.vue @@ -84,7 +84,45 @@ - + + + 新增 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 作战分队 @@ -188,7 +226,6 @@ import Zoom from './components/Zoom.vue' import BlbzModal from './components/BlbzModal.vue' import Jcsx from './components/Jcsx.vue' import Zzxd from './components/Zzxd.vue' - export default { name: 'SubsystemScenePresetting', components: { @@ -203,6 +240,20 @@ export default { scenarioName: '', cesium: null, scenarioDetail: null, + weatherData:[ + { key: '1', weatherType: '张三', lastBegTime: 32, editable: false }, + { key: '2', weatherType: '李四', lastBegTime: 42, editable: false } + ], + columns: [ + { title: '天气类型', dataIndex: 'weatherType',key: 'weatherType' }, + { title: '持续开始时间', dataIndex: 'lastBegTime',key: 'lastBegTime' }, + { title: '持续结束时间', dataIndex: 'lastEndTime',key: 'lastEndTime' }, + { + title: '操作', + dataIndex: 'operation', + scopedSlots: { customRender: 'operation' } + } + ], zzbzll: { loading: false, treeData: [], @@ -270,7 +321,9 @@ export default { }, created() { this.scenarioId = this.$route.params.scenarioId + console.log("============="+this.$route.params.scenarioId) this.scenarioName = this.$route.params.scenarioName + this.getWeathers() window.addEventListener('beforeunload', (e) => { this.childWindow && this.childWindow.close() return true // 必须设置 returnValue 才能显示确认框 @@ -283,6 +336,61 @@ export default { this.getFdListData() }, methods: { + getWeathers(){ + this.$http({ + url: `/baseData/weatherResource/list`, + method: 'get', + params: { scenarioId: this.scenarioId}, + }).then(res => { + this.weatherData = res.data + console.log("================="+JSON.stringify(this.weatherData)) + }) + }, + handleChange(value, key, column) { + const newData = [...this.data]; + const target = newData.find(item => key === item.key); + if (target) { + target[column] = value; + this.data = newData; + } + }, + edit(key) { + const newData = [...this.data]; + const target = newData.find(item => key === item.key); + if (target) { + target.editable = true; + this.data = newData; + } + }, + save(key) { + const newData = [...this.data]; + const target = newData.find(item => key === item.key); + if (target) { + delete target.editable; + this.data = newData; + } + }, + cancel(key) { + const newData = [...this.data]; + const target = newData.find(item => key === item.key); + if (target) { + // Object.assign(target, this.newData.find(item => key === item.key)); + delete target.editable; + this.data = newData; + } + }, + handleDelete(key) { + this.data = this.data.filter(item => item.key !== key); + }, + handleAdd() { + this.data.push({ + key: Date.now(), + name: '', + age: null, + address: '', + editable: true + }); + }, getTree(target, treeData, showKeys) { treeData.forEach((item) => { const newChildren = [] diff --git a/vue.config.js b/vue.config.js index 6bc037e..8e4913a 100644 --- a/vue.config.js +++ b/vue.config.js @@ -123,7 +123,7 @@ const vueConfig = { }, }, '/map': { - target: process.env.VUE_APP_MAP_URL + '/map', + target: process.env.VUE_APP_MAP_URL + '/', ws: false, changeOrigin: true, pathRewrite: { From 1103f9ee9c894551a800c2aea748439783a12f30 Mon Sep 17 00:00:00 2001 From: wangwenhua <12345678> Date: Sat, 18 Oct 2025 12:50:00 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E7=B3=BB=E7=BB=9F=E5=90=8D=E7=A7=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- public/config.js | 4 ++-- public/index.html | 2 +- src/config/defaultSettings.js | 2 +- src/config/router.config.js | 2 +- src/views/user/Login.vue | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/public/config.js b/public/config.js index 2d1e4c9..02d9207 100644 --- a/public/config.js +++ b/public/config.js @@ -19,7 +19,7 @@ window._CONFIG = { evaluationSrc: 'http://192.168.0.53:8088/thirdLogin/thirdLoginPage?username=admin', // 服务端地址 - VUE_APP_API_URL: 'http://192.168.0.53:8099', + VUE_APP_API_URL: 'http://192.168.0.225:8099', // websocket服务地址 - VUE_APP_WEBSOCKET_URL: 'ws://192.168.0.53:8099', + VUE_APP_WEBSOCKET_URL: 'ws://192.168.0.225:8099', } diff --git a/public/index.html b/public/index.html index 1625d89..e44d585 100644 --- a/public/index.html +++ b/public/index.html @@ -5,7 +5,7 @@ - 某仿真分析方法工具 + 中印边境自卫作战联合反击后装保障效能全业务全链路仿真系统 diff --git a/src/config/defaultSettings.js b/src/config/defaultSettings.js index df3d8ee..ed302b2 100644 --- a/src/config/defaultSettings.js +++ b/src/config/defaultSettings.js @@ -23,7 +23,7 @@ export default { menu: { locale: true }, - title: '某仿真分析方法工具', + title: '中印边境自卫作战联合反击后装保障效能全业务全链路仿真系统', pwa: false, iconfontUrl: '', production: process.env.NODE_ENV === 'production' && process.env.VUE_APP_PREVIEW !== 'true' diff --git a/src/config/router.config.js b/src/config/router.config.js index 010faf1..5abd827 100644 --- a/src/config/router.config.js +++ b/src/config/router.config.js @@ -18,7 +18,7 @@ export const constantRouterMap = [ path: '/', name: 'index', component: RouteView, - meta: { title: '某仿真分析方法工具' }, + meta: { title: '中印边境自卫作战联合反击后装保障效能全业务全链路仿真系统' }, redirect: '/user/welcome', }, { diff --git a/src/views/user/Login.vue b/src/views/user/Login.vue index 298e5f8..46a343f 100644 --- a/src/views/user/Login.vue +++ b/src/views/user/Login.vue @@ -1,6 +1,6 @@ - 某仿真分析方法工具 + 中印边境自卫作战联合反击后装保障效能全业务全链路仿真系统