吉安感知网项目-前端
张含笑
2026-02-03 4f63a744563959e1735f37496a43d244250ac030
Merge remote-tracking branch 'origin/master'
6 files modified
131 ■■■■ changed files
applications/drone-command/src/views/detectionCountermeasure/detectionRange/DetectionRangeDialog.vue 36 ●●●●● patch | view | raw | blame | history
applications/task-work-order/env/.env 8 ●●●● patch | view | raw | blame | history
applications/task-work-order/env/.env.development 34 ●●●● patch | view | raw | blame | history
applications/task-work-order/env/.env.production 25 ●●●●● patch | view | raw | blame | history
applications/task-work-order/env/.env.test 23 ●●●●● patch | view | raw | blame | history
applications/task-work-order/src/axiosXT.js 5 ●●●●● patch | view | raw | blame | history
applications/drone-command/src/views/detectionCountermeasure/detectionRange/DetectionRangeDialog.vue
@@ -17,6 +17,7 @@
                    :terrain="true"
                    :layer-mode="4"
                    :boundary="false"
                    :zoom-to-boundary="dialogMode === 'add'"
                />
            </div>
@@ -167,7 +168,7 @@
const formRef = ref(null) // 表单实例
const formData = ref(initForm()) // 表单数据
const visible = defineModel() // 弹框显隐
const dialogMode = ref('add') // 弹框模式
const dialogMode = ref('') // 弹框模式
const submitting = ref(false) // 提交中
const deviceOptions = ref([])
const dialogReadonly = computed(() => dialogMode.value === 'view')
@@ -334,6 +335,34 @@
    updateRangeCircle(longitude, latitude, formData.value.effectiveRangeKm)
}
function flyToRange(longitude, latitude, range) {
    if (!viewer || longitude == null || latitude == null) return
    const rangeMeters = Number(range)
    if (Number.isFinite(rangeMeters) && rangeMeters > 0) {
        const center = Cesium.Cartesian3.fromDegrees(longitude, latitude)
        const radius = Math.max(rangeMeters, 1000)
        const sphere = new Cesium.BoundingSphere(center, radius)
        console.log(viewer, longitude, latitude, radius)
        viewer.camera.flyToBoundingSphere(sphere, {
            duration: 0,
            offset: new Cesium.HeadingPitchRange(viewer.camera.heading, Cesium.Math.toRadians(-90), radius * 1.8),
        })
        return
    }
    viewer.camera.flyTo({
        destination: Cesium.Cartesian3.fromDegrees(longitude, latitude, 2000),
        orientation: {
            heading: viewer.camera.heading,
            pitch: Cesium.Math.toRadians(-65),
            roll: 0,
        },
        duration: 0,
    })
}
function parseDeployLocation(value) {
    if (!value) return null
    const [longitude, latitude] = value.split(',').map(item => Number(item.trim()))
@@ -427,6 +456,8 @@
    await nextTick()
    initMap()
    if (dialogMode.value === 'add') {
        mapRef.value?.zoomToAdminBoundary?.()
        await loadDeviceOptions()
        formData.value = initForm()
        return
@@ -449,7 +480,8 @@
        const parsed = parseDeployLocation(location)
        if (parsed) {
            setMapPoint(parsed.longitude, parsed.latitude)
            viewer.flyTo(redPointEntity, { duration: 0 })
            flyToRange(parsed.longitude, parsed.latitude, formData.value.effectiveRangeKm)
        }
    }
}
applications/task-work-order/env/.env
@@ -1,8 +1,11 @@
#接口地址
VITE_APP_API=/api
#接口地址-xt
#开发环境代理接口地址-xt
VITE_APP_API_XT=/apiXT
# xt部署到服务器后接口地址
VITE_APP_URL_XT=http://218.202.104.82:8200
#页面基础路径
VITE_APP_BASE=/task-work-order
@@ -15,9 +18,6 @@
# 是否在打包时开启压缩,支持 gzip 和 brotli
VITE_BUILD_COMPRESS=gzip
# xt接口地址
VITE_APP_URL_XT=http://218.202.104.82:8200
# 预览地址 previewURL
VITE_APP_PREVIEW_URL=http://192.168.1.204:8012
applications/task-work-order/env/.env.development
@@ -1,40 +1,20 @@
###
 # @Author       : yuan
 # @Date         : 2026-01-07 14:58:30
 # @LastEditors  : yuan
 # @LastEditTime : 2026-01-28 09:21:21
 # @FilePath     : \applications\task-work-order\env\.env.development
 # @Description  :
 # Copyright 2026 OBKoro1, All Rights Reserved.
 # 2026-01-07 14:58:30
###
NODE_ENV = 'development'
NODE_ENV='development'
#开发环境配置
VITE_APP_ENV = 'development'
VITE_APP_ENV='development'
#开发环境代理地址(推荐本地新建文件 .env.development.local 来进行覆盖)
# VITE_APP_URL = https://wrj.shuixiongit.com/api
VITE_APP_URL= http://192.168.1.227
VITE_APP_URL=http://192.168.1.227
#新大屏地址
VITE_APP_DASHBOARD_URL = 'https://wrj.shuixiongit.com/command-center-dashboard/'
# 域名
VITE_APP_AREA_NAME = https://wrj.shuixiongit.com
VITE_APP_DASHBOARD_URL='https://wrj.shuixiongit.com/command-center-dashboard/'
# ws地址
VITE_APP_WS_API_URL = wss://wrj.shuixiongit.com/drone-wss/api/v1/ws
VITE_APP_WS_API_URL=wss://wrj.shuixiongit.com/drone-wss/api/v1/ws
# 航线文件地址
VITE_APP_AIRLINE_URL = https://wrj.shuixiongit.com/minio/cloud-bucket
VITE_APP_AIRLINE_URL=https://wrj.shuixiongit.com/minio/cloud-bucket
# 行政区划存放地址
VITE_APP_REGION_URL = https://wrj.shuixiongit.com/aiskyminio/cloud-bucket/ztzf_region
# 算法仓库图片地址
VITE_APP_PICTURE_URL = https://wrj.shuixiongit.com/aiskyminio/cloud-bucket
VITE_APP_REGION_URL=https://wrj.shuixiongit.com/aiskyminio/cloud-bucket/ztzf_region
# 设备ip地址
VITE_APP_DEVICE_IP = '139.196.74.78:1883'
applications/task-work-order/env/.env.production
@@ -1,32 +1,23 @@
NODE_ENV = 'production'
NODE_ENV='production'
#生产环境配置
VITE_APP_ENV = 'production'
VITE_APP_ENV='production'
# 服务地址
VITE_APP_URL = https://aisky.org.cn/api
# 域名
VITE_APP_AREA_NAME = https://aisky.org.cn
VITE_APP_URL=https://aisky.org.cn/api
#新大屏地址
VITE_APP_DASHBOARD_URL = 'https://aisky.org.cn/command-center-dashboard/'
VITE_APP_DASHBOARD_URL='https://aisky.org.cn/command-center-dashboard/'
# ws地址
VITE_APP_WS_API_URL = wss://aisky.org.cn/drone-wss/api/v1/ws
VITE_APP_WS_API_URL=wss://aisky.org.cn/drone-wss/api/v1/ws
# 航线文件地址
VITE_APP_AIRLINE_URL = https://wrj.shuixiongit.com/aiskyminio/cloud-bucket
VITE_APP_AIRLINE_URL=https://wrj.shuixiongit.com/aiskyminio/cloud-bucket
# 图片存放地址
VITE_APP_TERRAIN_URL = https://wrj.shuixiongit.com/aiskyminio/cloud-bucket/ztzf_terrain/
# 算法仓库图片地址
VITE_APP_PICTURE_URL = https://wrj.shuixiongit.com/aiskyminio/cloud-bucket
VITE_APP_TERRAIN_URL=https://wrj.shuixiongit.com/aiskyminio/cloud-bucket/ztzf_terrain/
# 行政区划存放地址
VITE_APP_REGION_URL = https://wrj.shuixiongit.com/aiskyminio/cloud-bucket/ztzf_region
# 设备ip地址
VITE_APP_DEVICE_IP = '101.132.85.201:1883'
VITE_APP_REGION_URL=https://wrj.shuixiongit.com/aiskyminio/cloud-bucket/ztzf_region
applications/task-work-order/env/.env.test
@@ -1,31 +1,24 @@
NODE_ENV = 'test'
NODE_ENV='test'
#开发环境配置
VITE_APP_ENV = 'test'
VITE_APP_ENV='test'
# 服务地址
VITE_APP_URL = https://wrj.shuixiongit.com/api
VITE_APP_URL=https://wrj.shuixiongit.com/api
#新大屏地址
VITE_APP_DASHBOARD_URL = 'https://wrj.shuixiongit.com/command-center-dashboard/'
# 域名
VITE_APP_AREA_NAME = https://wrj.shuixiongit.com
VITE_APP_DASHBOARD_URL='https://wrj.shuixiongit.com/command-center-dashboard/'
# ws地址
VITE_APP_WS_API_URL = wss://wrj.shuixiongit.com/drone-wss/api/v1/ws
VITE_APP_WS_API_URL=wss://wrj.shuixiongit.com/drone-wss/api/v1/ws
# 航线文件地址
VITE_APP_AIRLINE_URL = https://wrj.shuixiongit.com/minio/cloud-bucket
VITE_APP_AIRLINE_URL=https://wrj.shuixiongit.com/minio/cloud-bucket
# 图片存放地址
VITE_APP_TERRAIN_URL = https://wrj.shuixiongit.com/aiskyminio/cloud-bucket/ztzf_terrain/
VITE_APP_TERRAIN_URL=https://wrj.shuixiongit.com/aiskyminio/cloud-bucket/ztzf_terrain/
# 算法仓库图片地址
VITE_APP_PICTURE_URL = https://wrj.shuixiongit.com/aiskyminio/cloud-bucket
# 行政区划存放地址
VITE_APP_REGION_URL = https://wrj.shuixiongit.com/aiskyminio/cloud-bucket/ztzf_region
VITE_APP_REGION_URL=https://wrj.shuixiongit.com/aiskyminio/cloud-bucket/ztzf_region
# 设备ip地址
VITE_APP_DEVICE_IP = '139.196.74.78:1883'
applications/task-work-order/src/axiosXT.js
@@ -3,11 +3,10 @@
import { serialize } from '@/utils/util'
import { ElMessage } from 'element-plus'
// 全局未授权错误提示状态,只提示一次
const { VITE_APP_API_XT } = import.meta.env
const { VITE_APP_API_XT,VITE_APP_ENV,VITE_APP_URL_XT } = import.meta.env
const serviceXT = axios.create({
    timeout: 600000,
    baseURL: VITE_APP_API_XT,
    baseURL: VITE_APP_ENV === 'development' ? VITE_APP_API_XT : VITE_APP_URL_XT,
    //跨域请求,允许保存cookie
    withCredentials: false,
})