Merge branch 'master' of http://192.168.1.22:3000/Web/admin-sjzx
This commit is contained in:
@@ -25,14 +25,10 @@ export const useMonitoringPoint = defineStore(
|
||||
val: any
|
||||
) => {
|
||||
state[key] = val
|
||||
|
||||
}
|
||||
const setShowCheckBox = (val: boolean) => {
|
||||
if (val && state.lineIds.length === 0) {
|
||||
state.lineIds = [state.lineId]
|
||||
// console.log('====================================')
|
||||
// console.log(state.lineIds)
|
||||
// console.log('====================================')
|
||||
}
|
||||
state.showCheckBox = val
|
||||
}
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
<el-radio-button v-for="(item, i) in dotList?.childrens" :label="item.name" :value="i" />
|
||||
</el-radio-group>
|
||||
</div>
|
||||
<div v-if="information">
|
||||
<div >
|
||||
<el-button icon="el-icon-Plus" type="primary" @click="addUser">新增</el-button>
|
||||
<el-button icon="el-icon-Edit" type="primary" @click="revise">修改</el-button>
|
||||
<el-button icon="el-icon-Delete" type="primary" @click="deletes">删除</el-button>
|
||||
|
||||
@@ -91,8 +91,10 @@ const submit = () => {
|
||||
formRef.value.validate(async (valid: boolean) => {
|
||||
if (valid) {
|
||||
if (urlList.value.length > 0) {
|
||||
|
||||
const promises = urlList.value.map(async (item: any) => {
|
||||
if (urlList.value[0].raw) {
|
||||
|
||||
return new Promise((resolve, reject) => {
|
||||
uploadFile(item.raw, '/supervision/')
|
||||
.then((res: any) => {
|
||||
|
||||
@@ -47,7 +47,7 @@ watch(
|
||||
|
||||
if (!newLineId) return
|
||||
// 在这里处理 lineId 的变化
|
||||
|
||||
console.log('newLineId')
|
||||
monitoringPoint.setValue('lineId', router.currentRoute.value.query.lineId)
|
||||
monitoringPoint.setValue('lineName', router.currentRoute.value.query.lineName)
|
||||
setTimeout(() => {
|
||||
|
||||
@@ -75,6 +75,7 @@ onMounted(() => {
|
||||
})
|
||||
const handleNodeClick = (data: any, node: any) => {
|
||||
if (data.level === 6) {
|
||||
|
||||
monitoringPoint.setValue('lineId', data.id)
|
||||
monitoringPoint.setValue('pid', data.pids)
|
||||
monitoringPoint.setValue('lineName', data.alias)
|
||||
|
||||
@@ -71,7 +71,6 @@ const handleNodeClick = (data: any, node: any) => {
|
||||
if (window.localStorage.getItem('BMAP_SECKEY') == null) {
|
||||
flag.value = false
|
||||
}
|
||||
|
||||
monitoringPoint.setValue('lineId', data.id)
|
||||
monitoringPoint.setValue('lineName', data.alias)
|
||||
}
|
||||
|
||||
@@ -246,12 +246,14 @@ const handler = async ({ BMap, map }: any) => {
|
||||
() => monitoringPoint.state.lineId,
|
||||
(newLineId, oldLineId) => {
|
||||
let value = areaLineInfo.value.find((item: any) => item.lineId == newLineId)
|
||||
|
||||
if (value == undefined) return
|
||||
|
||||
center.value.lng = value.lng
|
||||
center.value.lat = value.lat + 0.01
|
||||
infoWindowPoint.value = value
|
||||
infoWindowPoint.value.show = true
|
||||
|
||||
monitoringPoint.setValue(
|
||||
'lineName',
|
||||
value.manufacturer + '>' + value.gdName + '>' + value.subName + '>' + value.lineName
|
||||
|
||||
Reference in New Issue
Block a user