吉安感知网项目-前端
罗广辉
2026-02-03 35401373bbe0f608ee3bb7f7c54ebeef5e5dc8d2
Merge remote-tracking branch 'origin/master'
4 files modified
2 files deleted
1005 ■■■■■ changed files
applications/drone-command/env/.env.development 4 ●●●● patch | view | raw | blame | history
applications/drone-command/src/views/areaManage/partition/FormDiaLog.vue 67 ●●●● patch | view | raw | blame | history
applications/drone-command/src/views/basicManage/deviceStock/FormDiaLog.vue 9 ●●●● patch | view | raw | blame | history
applications/task-work-order/src/views/orderView/appConfiguration/inventory/接口文档.txt 537 ●●●●● patch | view | raw | blame | history
applications/task-work-order/src/views/orderView/appConfiguration/materials/index.vue 67 ●●●●● patch | view | raw | blame | history
applications/task-work-order/src/views/orderView/appConfiguration/materials/接口文档.txt 321 ●●●●● patch | view | raw | blame | history
applications/drone-command/env/.env.development
@@ -2,7 +2,7 @@
 # @Author       : yuan
 # @Date         : 2026-01-31 14:34:31
 # @LastEditors  : yuan
 # @LastEditTime : 2026-02-02 16:39:41
 # @LastEditTime : 2026-02-03 09:34:48
 # @FilePath     : \applications\drone-command\env\.env.development
 # @Description  : 
 # Copyright 2026 OBKoro1, All Rights Reserved. 
@@ -16,7 +16,7 @@
#开发环境代理地址(推荐本地新建文件 .env.development.local 来进行覆盖)
# VITE_APP_URL=https://wrj.shuixiongit.com/api
VITE_APP_URL=http://192.168.1.33
VITE_APP_URL=http://192.168.1.168
#新大屏地址
VITE_APP_DASHBOARD_URL='https://wrj.shuixiongit.com/command-center-dashboard/'
applications/drone-command/src/views/areaManage/partition/FormDiaLog.vue
@@ -160,7 +160,8 @@
                    </el-form-item>
                    <el-form-item label="关联派出所" prop="policeStationId">
                        <el-select class="command-select" popper-class="command-select-popper"
                            v-model="formData.policeStationId" placeholder="请选择" clearable>
                            v-model="formData.policeStationId" placeholder="请选择" clearable filterable remote
                            :remote-method="handlePoliceStationSearch" :loading="policeStationLoading">
                            <el-option v-for="item in policeStationOptions" :key="item.id" :label="item.stationName"
                                :value="item.id" />
                        </el-select>
@@ -285,6 +286,10 @@
const searchName = ref('')
const selectedDeviceRows = ref([])
const policeStationOptions = ref([]) // 关联派出所
const policeStationAllOptions = ref([])
const policeStationLoading = ref(false)
const policeStationSearchTimer = ref(null)
const policeStationSearchKeyword = ref('')
const deviceOptions = ref([]) // 关联设备
const dictObj = inject('dictObj')
const mapRef = ref(null)
@@ -421,6 +426,10 @@
            if (deviceListTimer) {
                clearTimeout(deviceListTimer)
                deviceListTimer = null
            }
            if (policeStationSearchTimer.value) {
                clearTimeout(policeStationSearchTimer.value)
                policeStationSearchTimer.value = null
            }
            viewEntity && viewer?.entities?.remove(viewEntity)
            viewEntity = null
@@ -1191,17 +1200,45 @@
}
// 获取派出所列表
async function getPoliceStationList () {
async function getPoliceStationList (keyword = '') {
    if (!visible.value) return
    const res = await fwPoliceStationListApi()
    policeStationOptions.value = res?.data?.data ?? []
    await nextTick()
    const matched = policeStationOptions.value.find(
        item => String(item.id) === String(formData.value.policeStationId)
    )
    if (!matched) {
        formData.value.policeStationId = ''
    policeStationLoading.value = true
    try {
        const res = await fwPoliceStationListApi({
            stationName: keyword || undefined,
        })
        const list = res?.data?.data ?? []
        policeStationOptions.value = list
        if (!keyword) {
            policeStationAllOptions.value = list
        }
        await nextTick()
        if (!keyword) {
            const matched = policeStationOptions.value.find(
                item => String(item.id) === String(formData.value.policeStationId)
            )
            if (!matched) {
                formData.value.policeStationId = ''
            }
        }
    } finally {
        policeStationLoading.value = false
    }
}
function handlePoliceStationSearch (query) {
    policeStationSearchKeyword.value = (query || '').trim()
    if (!policeStationSearchKeyword.value) {
        policeStationOptions.value = [...policeStationAllOptions.value]
        return
    }
    if (policeStationSearchTimer.value) {
        clearTimeout(policeStationSearchTimer.value)
    }
    policeStationSearchTimer.value = setTimeout(() => {
        policeStationSearchTimer.value = null
        void getPoliceStationList(policeStationSearchKeyword.value)
    }, 300)
}
// 获取设备列表
@@ -1306,6 +1343,12 @@
    selectedDeviceRows.value = []
    deviceOptions.value = []
    policeStationOptions.value = []
    policeStationAllOptions.value = []
    policeStationSearchKeyword.value = ''
    if (policeStationSearchTimer.value) {
        clearTimeout(policeStationSearchTimer.value)
        policeStationSearchTimer.value = null
    }
    shapeList.value = []
    activeShapeId.value = null
    activeAreaType.value = ''
@@ -1363,6 +1406,10 @@
        clearTimeout(deviceListTimer)
        deviceListTimer = null
    }
    if (policeStationSearchTimer.value) {
        clearTimeout(policeStationSearchTimer.value)
        policeStationSearchTimer.value = null
    }
    hideTypePanel()
})
applications/drone-command/src/views/basicManage/deviceStock/FormDiaLog.vue
@@ -272,9 +272,16 @@
    const isValid = await formRef.value?.validate().catch(() => false)
    if (!isValid) return
    submitting.value = true
    let deviceSet = {}
    try {
        await fwDeviceSubmitApi(formData.value)
        const actionText = dialogMode.value === 'add' ? '建档' : '编辑'
        deviceSet = dialogMode.value === 'add' ? { status: 0 } : {}
        await fwDeviceSubmitApi({
            ...formData.value,
            ...deviceSet
        })
        saveOperationLog({
            requestUri: route.path,
            title: `${route.name || '设备出入库'}-${actionText}`,
applications/task-work-order/src/views/orderView/appConfiguration/inventory/接口文档.txt
File was deleted
applications/task-work-order/src/views/orderView/appConfiguration/materials/index.vue
@@ -11,24 +11,6 @@
                />
            </el-form-item>
            <!-- <el-form-item label="所属区划" prop="areaCode">
                <el-tree-select
                    class="gd-select gray"
                    popper-class="gd-tree-select-popper"
                    v-model="searchParams.areaCode"
                    node-key="id"
                    :props="treeSelectProps"
                    placeholder="请选择"
                    clearable
                    filterable
                    @change="handleSearch"
                    :check-strictly="true"
                    lazy
                    :load="loadRegionNode"
                    :render-after-expand="false"
                />
            </el-form-item> -->
            <el-form-item class="gd-search-actions">
                <el-button :icon="RefreshRight" @click="resetForm"></el-button>
                <el-button class="search-btn" :icon="Search" @click="handleSearch"></el-button>
@@ -59,7 +41,6 @@
                            {{ getDictLabel(String(row.isAllScenario), dictObj.isAllScenario) }}
                        </template>
                    </el-table-column>
                    <!-- <el-table-column prop="areaName" show-overflow-tooltip label="所属区域" /> -->
                    <el-table-column label="操作" class-name="operation-btns" width="200">
                        <template v-slot="{ row }">
                            <el-link type="primary" @click="openForm('view', row)">查看</el-link>
@@ -91,13 +72,12 @@
import { onMounted, ref, provide, nextTick } from 'vue'
import { ElMessage, ElMessageBox } from 'element-plus'
import FormDiaLog from './FormDiaLog.vue'
import { materialsPageApi, materialsRemoveApi, regionLazyTreeApi } from './materialsApi'
import { materialsPageApi, materialsRemoveApi } from './materialsApi'
import { getDictLabel } from '@ztzf/utils'
// 初始化查询参数
const initSearchParams = () => ({
    materialName: '', // 材料名称
    areaCode: '', // 所属区划
    current: 1, // 当前页
    size: 10, // 每页大小
})
@@ -112,17 +92,6 @@
    necessity: [],
    isAllScenario: [],
}) // 字典对象
// 树形选择器配置
const treeSelectProps = {
    value: 'id',
    label: 'name',
    children: 'children',
    // 判断叶子节点
    isLeaf: (data, node) => {
        return data.leaf === true
    },
}
provide('dictObj', dictObj)
@@ -139,40 +108,6 @@
        { dictKey: '1', dictValue: '是' },
        { dictKey: '0', dictValue: '否' },
    ]
}
// 懒加载获取区域节点数据
async function loadRegionNode(node, resolve) {
    try {
        // 限制只加载两级,当前节点 level >= 1 时不加载子节点
        if (node.level >= 2) {
            resolve([])
            return
        }
        // 初始化加载时传递 code 参数,加载子节点时传递 parentCode 参数
        const params = node.data?.id ? { parentCode: node.data.id } : { code: '360800000000' }
        const res = await regionLazyTreeApi(params)
        const nodes = res?.data?.data || []
        // 处理返回的节点数据
        const processedNodes = nodes.map(item => {
            // 判断是否为叶子节点:如果是第二级(node.level === 1)则为叶子节点
            const isLeaf = node.level === 1
            return {
                id: item.id || item.value,
                name: item.name || item.title || item.label,
                hasChildren: item.hasChildren || false,
                leaf: isLeaf,
            }
        })
        resolve(processedNodes)
    } catch (error) {
        console.error('获取区域数据失败:', error)
        resolve([])
    }
}
// 获取列表
applications/task-work-order/src/views/orderView/appConfiguration/materials/接口文档.txt
File was deleted