Compare commits
No commits in common. "main" and "dev-i18n" have entirely different histories.
@ -1,3 +1,5 @@
|
|||||||
|
import { h } from "vue";
|
||||||
|
|
||||||
// English translations
|
// English translations
|
||||||
export default {
|
export default {
|
||||||
app: {
|
app: {
|
||||||
|
|||||||
@ -2,41 +2,6 @@ import Vue from 'vue'
|
|||||||
import VueI18n from 'vue-i18n'
|
import VueI18n from 'vue-i18n'
|
||||||
import zh from './zh';
|
import zh from './zh';
|
||||||
import en from './en';
|
import en from './en';
|
||||||
|
|
||||||
export const gisLabels = {
|
|
||||||
planArea: {
|
|
||||||
zh_CN: '规划区域',
|
|
||||||
en_US: 'Plan Area'
|
|
||||||
},
|
|
||||||
planAirline: {
|
|
||||||
zh_CN: '规划航线',
|
|
||||||
en_US: 'Plan Airline'
|
|
||||||
},
|
|
||||||
startPoint: {
|
|
||||||
zh_CN: '起点',
|
|
||||||
en_US: 'Start Point'
|
|
||||||
},
|
|
||||||
endPoint: {
|
|
||||||
zh_CN: '终点',
|
|
||||||
en_US: 'end Point'
|
|
||||||
},
|
|
||||||
task: {
|
|
||||||
zh_CN: '任务',
|
|
||||||
en_US: 'Task'
|
|
||||||
},
|
|
||||||
point: {
|
|
||||||
zh_CN: '点',
|
|
||||||
en_US: 'Point'
|
|
||||||
},
|
|
||||||
line: {
|
|
||||||
zh_CN: '线',
|
|
||||||
en_US: 'Line'
|
|
||||||
},
|
|
||||||
PowerOnPoint: {
|
|
||||||
zh_CN: '开机点',
|
|
||||||
en_US: 'Power-on point'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
Vue.use(VueI18n)
|
Vue.use(VueI18n)
|
||||||
|
|
||||||
// load locale messages
|
// load locale messages
|
||||||
|
|||||||
@ -1,3 +1,4 @@
|
|||||||
|
// Chinese translations
|
||||||
export default {
|
export default {
|
||||||
app: {
|
app: {
|
||||||
title: '空域快视系统',
|
title: '空域快视系统',
|
||||||
|
|||||||
@ -4,7 +4,6 @@ import { constantRoutes } from '@/router'
|
|||||||
import { mapMutations, mapGetters, mapActions } from 'vuex'
|
import { mapMutations, mapGetters, mapActions } from 'vuex'
|
||||||
import ChangePassword from '@/layout/components/change-password/index.vue'
|
import ChangePassword from '@/layout/components/change-password/index.vue'
|
||||||
import { getTreeAllItems, judgeArrayRepeat } from '@/utils'
|
import { getTreeAllItems, judgeArrayRepeat } from '@/utils'
|
||||||
import { gisLabels } from '../../../lang'
|
|
||||||
export default {
|
export default {
|
||||||
name: 'Header',
|
name: 'Header',
|
||||||
components: { ChangePassword },
|
components: { ChangePassword },
|
||||||
@ -173,28 +172,12 @@ export default {
|
|||||||
...mapActions('app', ['reload']),
|
...mapActions('app', ['reload']),
|
||||||
...mapMutations('app', ['SET_SCENE_ID', 'SET_SCENE_INFO', 'SET_MENUS_CHOSE']),
|
...mapMutations('app', ['SET_SCENE_ID', 'SET_SCENE_INFO', 'SET_MENUS_CHOSE']),
|
||||||
...mapMutations('user', ['SET_ROLES', 'SET_USER_ID', 'SET_USERNAME']),
|
...mapMutations('user', ['SET_ROLES', 'SET_USER_ID', 'SET_USERNAME']),
|
||||||
...mapActions('dict', ['getDict']),
|
|
||||||
handleSelect(key) {
|
handleSelect(key) {
|
||||||
this.SET_MENUS_CHOSE(key)
|
this.SET_MENUS_CHOSE(key)
|
||||||
},
|
},
|
||||||
changeLocale(lang) {
|
changeLocale(lang) {
|
||||||
this.$i18n.locale = lang
|
this.$i18n.locale = lang
|
||||||
localStorage.setItem('locale', lang)
|
localStorage.setItem('locale', lang)
|
||||||
this.getDict()
|
|
||||||
// 处理gis上已添加的entity
|
|
||||||
viewer.entities.values.forEach(el => {
|
|
||||||
if (el.id.includes('area')) {
|
|
||||||
let obj = el.label.text._value.split('-')
|
|
||||||
obj[1] = gisLabels.planArea[lang]
|
|
||||||
el.label.text = obj.join('-')
|
|
||||||
}
|
|
||||||
if (el.id.includes('planLine')) {
|
|
||||||
let obj = el.label.text._value.split('-')
|
|
||||||
obj[0] = gisLabels.planAirline[lang]
|
|
||||||
obj[2] = gisLabels.startPoint[lang]
|
|
||||||
el.label.text = obj.join('-')
|
|
||||||
}
|
|
||||||
});
|
|
||||||
},
|
},
|
||||||
goHome() {
|
goHome() {
|
||||||
this.SET_MENUS_CHOSE('1')
|
this.SET_MENUS_CHOSE('1')
|
||||||
|
|||||||
@ -33,7 +33,6 @@ import PicturesUpload from '../pictures-upload/index.vue'
|
|||||||
import RightSlide from '@/components/RightSlide.vue'
|
import RightSlide from '@/components/RightSlide.vue'
|
||||||
import LeftSlide from '@/components/LeftSlide.vue'
|
import LeftSlide from '@/components/LeftSlide.vue'
|
||||||
import { debounce } from '@/utils'
|
import { debounce } from '@/utils'
|
||||||
import { gisLabels } from '@/lang/index'
|
|
||||||
let handler = undefined
|
let handler = undefined
|
||||||
let broadcastChannel = null
|
let broadcastChannel = null
|
||||||
let broadcastChannelInterval = null
|
let broadcastChannelInterval = null
|
||||||
@ -58,7 +57,6 @@ let radarSceneEntity = {}
|
|||||||
let sceneEntity = {}
|
let sceneEntity = {}
|
||||||
let taskListResource = []
|
let taskListResource = []
|
||||||
let orthoManager = null
|
let orthoManager = null
|
||||||
const lang = window.localStorage.getItem('locale') || 'zh_CN'
|
|
||||||
export default {
|
export default {
|
||||||
name: 'TwinSituation',
|
name: 'TwinSituation',
|
||||||
props: {
|
props: {
|
||||||
@ -1166,9 +1164,8 @@ export default {
|
|||||||
allPositions = allPositions.concat(positions)
|
allPositions = allPositions.concat(positions)
|
||||||
let entity = viewer.entities.add({
|
let entity = viewer.entities.add({
|
||||||
position: positions[0],
|
position: positions[0],
|
||||||
id: `${taskId}-area`,
|
|
||||||
label: {
|
label: {
|
||||||
text: `${taskName}-${gisLabels.planArea[lang]}-${index + 1}`,
|
text: `${taskName}任务-规划区域${index + 1}`,
|
||||||
disableDepthTestDistance: 10000,
|
disableDepthTestDistance: 10000,
|
||||||
font: '14px sans-serif',
|
font: '14px sans-serif',
|
||||||
fillColor: DT.Cesium.Color.RED,
|
fillColor: DT.Cesium.Color.RED,
|
||||||
@ -1196,9 +1193,8 @@ export default {
|
|||||||
allPositions.push(position)
|
allPositions.push(position)
|
||||||
let entity = viewer.entities.add({
|
let entity = viewer.entities.add({
|
||||||
position,
|
position,
|
||||||
id: `${taskId}-area`,
|
|
||||||
label: {
|
label: {
|
||||||
text: `${taskName}-${gisLabels.planArea[lang]}-${index + 1}`,
|
text: `${taskName}任务-规划区域${index + 1}`,
|
||||||
disableDepthTestDistance: 10000,
|
disableDepthTestDistance: 10000,
|
||||||
font: '14px sans-serif',
|
font: '14px sans-serif',
|
||||||
fillColor: DT.Cesium.Color.RED,
|
fillColor: DT.Cesium.Color.RED,
|
||||||
|
|||||||
@ -1327,7 +1327,7 @@
|
|||||||
position: absolute;
|
position: absolute;
|
||||||
left: 50%;
|
left: 50%;
|
||||||
top: calc(100vh - 60px);
|
top: calc(100vh - 60px);
|
||||||
width: 400px;
|
width: 360px;
|
||||||
transform: translateX(-50%);
|
transform: translateX(-50%);
|
||||||
background-color: $--color-black-1-alpha;
|
background-color: $--color-black-1-alpha;
|
||||||
padding: 6px 10px;
|
padding: 6px 10px;
|
||||||
@ -1347,10 +1347,9 @@
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
|
|
||||||
.is-label {
|
.is-label {
|
||||||
text-align: center;
|
|
||||||
flex: none;
|
flex: none;
|
||||||
color: $--color-text-1;
|
color: $--color-text-1;
|
||||||
width: 90px;
|
width: 60px;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,6 +1,5 @@
|
|||||||
import * as DT from 'dt-sdk'
|
import * as DT from 'dt-sdk'
|
||||||
import { viewer } from '@/components/dt-scene'
|
import { viewer } from '@/components/dt-scene'
|
||||||
import { gisLabels } from '@/lang/index'
|
|
||||||
export default class UavTarget {
|
export default class UavTarget {
|
||||||
planLines = new DT.Cesium.AssociativeArray()
|
planLines = new DT.Cesium.AssociativeArray()
|
||||||
uavEntity = null
|
uavEntity = null
|
||||||
@ -15,7 +14,7 @@ export default class UavTarget {
|
|||||||
this.uavId = options.uavId
|
this.uavId = options.uavId
|
||||||
this.jobName = options.jobName
|
this.jobName = options.jobName
|
||||||
this.startAltitude = options.startAltitude
|
this.startAltitude = options.startAltitude
|
||||||
this.lang = window.localStorage.getItem('locale') || 'zh_CN'
|
|
||||||
this.addPlanLine(options.airlineList)
|
this.addPlanLine(options.airlineList)
|
||||||
console.log(options, '飞机数据');
|
console.log(options, '飞机数据');
|
||||||
if (options.startLon) {
|
if (options.startLon) {
|
||||||
@ -337,7 +336,7 @@ export default class UavTarget {
|
|||||||
id,
|
id,
|
||||||
position: positions[0],
|
position: positions[0],
|
||||||
label: {
|
label: {
|
||||||
text: `${gisLabels.planAirline[this.lang]}-${index + 1}-${gisLabels.startPoint[this.lang]}`,
|
text: `规划航线${index + 1}起点`,
|
||||||
disableDepthTestDistance: 10000,
|
disableDepthTestDistance: 10000,
|
||||||
font: '14px sans-serif',
|
font: '14px sans-serif',
|
||||||
fillColor: DT.Cesium.Color.RED,
|
fillColor: DT.Cesium.Color.RED,
|
||||||
|
|||||||
@ -553,6 +553,42 @@ export default {
|
|||||||
// window.open(window.config.homeUrl + 'monitor', '_blank')
|
// window.open(window.config.homeUrl + 'monitor', '_blank')
|
||||||
// TODO
|
// TODO
|
||||||
// this.resourceClick(this.resourceList.data[0])
|
// this.resourceClick(this.resourceList.data[0])
|
||||||
|
return;
|
||||||
|
viewer.entities.add({
|
||||||
|
show: true,
|
||||||
|
id: 'image1',
|
||||||
|
name: '美女1',
|
||||||
|
rectangle: {
|
||||||
|
coordinates: DT.Cesium.Rectangle.fromDegrees(
|
||||||
|
115.914508,
|
||||||
|
40.357867,
|
||||||
|
115.916869,
|
||||||
|
40.361485
|
||||||
|
),
|
||||||
|
height: 0,
|
||||||
|
material: new DT.Cesium.ImageMaterialProperty({
|
||||||
|
image: process.env.BASE_URL + 'static/img/meinv.png',
|
||||||
|
transparent: 1
|
||||||
|
})
|
||||||
|
}
|
||||||
|
})
|
||||||
|
viewer.entities.add({
|
||||||
|
show: true,
|
||||||
|
id: 'image2',
|
||||||
|
name: '美女2',
|
||||||
|
rectangle: {
|
||||||
|
coordinates: DT.Cesium.Rectangle.fromDegrees(
|
||||||
|
115.914508,
|
||||||
|
40.357867,
|
||||||
|
115.916869,
|
||||||
|
40.361485
|
||||||
|
),
|
||||||
|
height: 100,
|
||||||
|
material: new DT.Cesium.ImageMaterialProperty({
|
||||||
|
image: process.env.BASE_URL + 'static/img/meinv.png',
|
||||||
|
})
|
||||||
|
}
|
||||||
|
})
|
||||||
},
|
},
|
||||||
beforeDestroy() {
|
beforeDestroy() {
|
||||||
if (handler) {
|
if (handler) {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user