main
徐景良 2026-03-13 09:23:08 +08:00
parent 31a427df9c
commit a9cf3bb372
13 changed files with 575 additions and 131 deletions

View File

@ -24,7 +24,7 @@ VITE_GLOB_COFFEE_API_URL = http://221.2.83.243:6050/coffee
VITE_GLOB_GEOSERVER_BASE_URL = http://192.168.10.163:8080
# 导航
VITE_GLOBAL_NAVIGATION_BASE_URL = http://221.2.83.243:8091
VITE_GLOB_NAVIGATION_BASE_URL = http://221.2.83.243:8091
# ANYRTC CALL
VITE_GLOB_ANYRTC_BASE_URL = https://ktdrw.wisestcity.com:6070

View File

@ -26,7 +26,7 @@ VITE_GLOB_INFO_IMAGE_URL= http://221.2.83.243:6050/core
VITE_GLOB_GEOSERVER_BASE_URL = http://221.2.83.243:6050/
# 导航
VITE_GLOBAL_NAVIGATION_BASE_URL = http://221.2.83.243:8091
VITE_GLOB_NAVIGATION_BASE_URL = http://221.2.83.243:8091
# 视频通话
VITE_GLOB_ANYRTC_BASE_URL = https://ktdrw.wisestcity.com:6070

View File

@ -77,6 +77,7 @@ enum Api {
GetInterphoneInfo = '/api/FmInterPhone/GetInterphoneInfo',
DeleteInterphoneInfo = '/api/FmInterPhone/DeleteInterphoneInfo',
AddOrUpdateInterphoneInfo = '/api/FmInterPhone/AddOrUpdateInterphoneInfo',
}
export const getPositionsTree = (params?: AccountParams) =>

View File

@ -79,13 +79,11 @@
datasSize,
} = toRefs(props.chartConfig.option);
console.log("navsArr",navsArr.value)
const navsClick = function (item, index) {
navsIndex.value = index;
props.chartConfig.request.requestSQLContent.sql = item.sql;
console.log("SQL_123",item.sql);
useChartDataFetch(props.chartConfig, useChartEditStore, (resData: any) => {
props.chartConfig.option.sectionDatas = resData;
handlerLoadFirePoint(sectionDatas.value);
@ -215,7 +213,6 @@ const getFileImage = (type) => {
}
//
const handlerLoadFirePoint = (points: []) => {
console.log("points123",points);
points?.forEach((item, index) => {
let graphicOptions = {

View File

@ -1,19 +1,22 @@
<template>
<div class="go-title-xuncha">
<div class="selbox">
<el-tree-select
v-model="areaValue"
:data="areaOptions"
check-strictly
label-field="name"
node-key="name"
:render-after-expand="false"
placeholder="请选择行政区划"
clearable
popper-class="go-title-xuncha-select-popper"
/>
</div>
<div class="searchbox flex ai-c">
<div class="selbox">
<el-tree-select
v-model="areaValue"
:data="areaOptions"
check-strictly
label-field="name"
node-key="name"
:render-after-expand="false"
placeholder="请选择行政区划"
clearable
popper-class="go-title-xuncha-select-popper"
/>
</div>
<div class="inpbox">
<n-input
size="small"
@ -37,7 +40,7 @@
</div>
</div>
<div class="contentbox">
<div class="contentli flex" v-for="(item,index) in dataset" @click="lisClick(item)">
<div class="contentli flex" v-for="(item,index) in clockList" @click="lisClick(item)">
<div class="icons01"></div>
<div class="flex column jc-c seclisbox">
<div class="header flex ai-c">
@ -58,6 +61,13 @@
</div>
</div>
</div>
<div class="more-button">
<span @click="loadMore">
查看更多 <DoubleRightOutlined />
</span>
</div>
</div>
</div>
</template>
@ -65,6 +75,7 @@
<script setup lang="ts">
import { PropType, toRefs, ref, onMounted } from 'vue'
import { CreateComponentType } from '@/packages/index.d'
import { DoubleRightOutlined } from "@ant-design/icons-vue";
import { EventBus } from '@/utils/eventBus'
import axios from 'axios'
import * as mars3d from "mars3d";
@ -97,24 +108,29 @@ const dataset = ref([])
const optionsData = ref([])
const entityArr = ref([])
const clockList = ref([]);
const listQuery = ref({
page:1,
limit:10,
pointName:searchValue.value
})
const getListData=()=>{
console.log('areaValue',areaValue)
axios({
method: "get",
url: VITE_GLOB_API_URL + '/api/FireGrid/GetCheckPointList',
params: {
page: 1,
limit: 9999,
pointName: searchValue.value
},
params: listQuery.value,
headers: {
'X-Token': localStorage.getItem("X-Token")
}
}).then(res => {
let rel = res.data.result.items
dataset.value = rel
// dataset.value = rel
clockList.value = clockList.value.concat(rel);
})
}
const getAreaListData=(id)=>{
axios({
method: "get",
@ -144,6 +160,7 @@ const getAreaListData=(id)=>{
props.chartConfig.option.areaOptions = optionsData.value
})
}
const lisClick=(e)=>{
eventHandlerHook(
chartEditStore.getComponentList,
@ -180,6 +197,13 @@ const handlerAddEntity = (data) => {
window.graphicLayer.addGraphic(graphic);
window.globalMap.flyToGraphic(graphic,{radius:300});
}
const loadMore = () => {
listQuery.value.page++;
getListData();
}
onMounted(() => {
getListData()
getAreaListData(371300)
@ -205,16 +229,20 @@ onMounted(() => {
.jc-c{
justify-content: center;
}
.selbox{
width: 150px;
height: 35px;
background: #05231A;
border-radius: 3px;
border: 1px solid #00611A;
}
.searchbox{
height: 35px;
margin-top: 5px;
gap:10px;
.selbox{
width: 150px;
height: 35px;
background: #05231A;
border-radius: 3px;
border: 1px solid #00611A;
background: url("@/assets/images/chart/xunchaguiji/gjinputbg.png");
background-size: 100% 100%;
}
.inpbox{
width: 150px;
height: 100%;
@ -304,6 +332,16 @@ onMounted(() => {
}
}
}
.more-button{
text-align: center;
color:#fff;
line-height:40px;
cursor:pointer;
&:hover{
color:#0EB687;
}
}
}
:deep(.n-input){
background: none;

View File

@ -93,6 +93,7 @@ onMounted(() => {
}
.unitbox{
margin-top: 5px;
margin-left:12px;
color: v-bind('unitColor');
font-size: v-bind('unitSize+"px"');
}

View File

@ -97,6 +97,7 @@ onMounted(() => {
}
.unitbox{
margin-top: 5px;
margin-left:8px;
color: v-bind('unitColor');
font-size: v-bind('unitSize+"px"');
}

View File

@ -1,12 +1,51 @@
<template>
<div class="go-title-03">
<div class="searchbox flex ai-c">
<div class="selbox">
<el-tree-select
v-model="areaValue"
:data="optionsData"
check-strictly
label-field="name"
node-key="name"
:render-after-expand="false"
placeholder="请选择行政区划"
clearable
popper-class="go-title-xuncha-select-popper"
/>
</div>
<div class="inpbox">
<n-select class="transparent-select" size="small" placeholder="在线状态" v-model:value="listQuery.isOnline" value-field="label" :options="stateOptions" />
</div>
<div class="flex">
<div class="searchbtn cursor flex ai-c jc-c" @click="getListDataBySearchButton">
<img class="img" src="@/assets/images/chart/xunchaguiji/btnicons01.png" />
<span class="span">搜索</span>
</div>
<!-- <div class="tongjibtn cursor flex ai-c jc-c">
<img class="img" src="@/assets/images/chart/xunchaguiji/btnicons02.png" />
<span class="span">统计</span>
</div>
<div class="xunjianbtn cursor flex ai-c jc-c">
<img class="img" src="@/assets/images/chart/xunchaguiji/btnicons03.png" />
<span class="span">巡检</span>
</div> -->
</div>
</div>
<div class="headerbox">
<div class="headerli" v-for="item in headerData">{{item}}</div>
<div class="scopedbox headerli">操作</div>
</div>
<div class="sectionbox">
<div class="nodatabox" v-if="dataset.length<1"></div>
<div class="secli" v-for="item in dataset">
<div class="nodatabox" v-if="userList.length<1"></div>
<div class="secli" v-for="item in userList">
<div class="li">
<div class="la">{{ item.townName }}</div>
</div>
@ -30,11 +69,18 @@
</div>
</div>
</div>
<div class="more-button">
<span @click="loadMore">
查看更多 <DoubleRightOutlined />
</span>
</div>
</div>
</div>
</template>
<script setup lang="ts">
import { PropType, toRefs, ref, onMounted } from 'vue'
import { DoubleRightOutlined } from "@ant-design/icons-vue";
import { CreateComponentType } from '@/packages/index.d'
import * as mars3d from "mars3d";
import axios from 'axios'
@ -49,7 +95,56 @@ const props = defineProps({
required: true
}
})
// 线
const stateOptions = ref([
{
label: '在线',
value: '在线'
},
{
label: '离线',
value: '离线'
},
{
label: '全部',
value: '全部'
},
])
const areaValue = ref()
const optionsData = ref([])
const getAreaListData=(id)=>{
axios({
method: "get",
url: VITE_GLOB_API_URL + '/api/Orgs/LoadChildren',
params: {
parentId: id
},
headers: {
'X-Token': localStorage.getItem("X-Token")
}
}).then(res => {
let rel = res.data.result
rel.forEach(item =>{
if(item.level == 1){
item.children = []
optionsData.value.push(item)
getAreaListData(item.id)
}
if(item.level == 2){
optionsData.value.forEach(val =>{
if(val.id == item.parentId){
val.children.push(item)
}
})
}
})
})
}
const { w, h } = toRefs(props.chartConfig.attr)
const entityArr = ref([])
const polyLineArr = ref([])
@ -136,25 +231,44 @@ const rotateLine = (data)=>{
}
})
}
const userList = ref([]);
const listQuery = ref({
page:1,
limit:10,
isOnline:"全部"
})
const getListData=()=>{
axios({
method: "post",
url: VITE_GLOB_API_URL + '/api/FireManagement/GetPointUserOnLine',
data: {
page: 1,
limit: 9999,
isonline:"全部"
},
data: listQuery.value,
headers: {
'X-Token': localStorage.getItem("X-Token")
}
}).then(res => {
let rel = res.data.result.items.userinfo
props.chartConfig.option.dataset = rel
// props.chartConfig.option.dataset = rel
userList.value = userList.value.concat(rel);
})
}
const getListDataBySearchButton = ()=>{
userList.value = [];
listQuery.value.page = 1;
getListData();
}
const loadMore = () => {
listQuery.value.page++;
getListData();
}
onMounted(() => {
getListData()
getAreaListData(371300)
})
</script>
@ -189,6 +303,59 @@ onMounted(() => {
color: v-bind('textColors[0]');
}
}
.searchbox{
height: 35px;
margin-top: 5px;
margin-bottom:5px;
gap:10px;
.selbox{
width: 150px;
height: 35px;
background: #05231A;
border-radius: 3px;
border: 1px solid #00611A;
background: url("@/assets/images/chart/xunchaguiji/gjinputbg.png");
background-size: 100% 100%;
}
.inpbox{
width: 150px;
height: 100%;
background: url("@/assets/images/chart/xunchaguiji/gjinputbg.png");
background-size: 100% 100%;
margin-right: 4px;
}
.img{
width: 20px;
height: 20px;
}
.span{
color: #FFFFFF;
font-size: 14px;
margin-left: 5px;
}
.searchbtn{
width: 72px;
height: 30px;
background: linear-gradient( 95deg, #00C16B 0%, #008E39 100%), #000000;
border-radius: 3px;
margin-right: 4px;
}
.tongjibtn{
width: 72px;
height: 30px;
background: linear-gradient( 277deg, #C14000 0%, #FF8849 100%), #000000;
border-radius: 3px;
margin-right: 4px;
}
.xunjianbtn{
width: 72px;
height: 30px;
background: linear-gradient( 277deg, #125FE3 0%, #1C9DCA 100%), #000000;
border-radius: 3px;
}
}
.scopedbox{
height: 100%;
min-width: 120px;
@ -269,7 +436,19 @@ onMounted(() => {
.secli:nth-child(2n){
background: v-bind('backgroundColors[2]');
}
.more-button{
text-align: center;
color:#fff;
line-height:40px;
cursor:pointer;
&:hover{
color:#0EB687;
}
}
}
}
/* 整个滚动条的样式 */
@ -288,4 +467,97 @@ onMounted(() => {
::-webkit-scrollbar-thumb:hover {
background: #34FFE0; /* 鼠标悬停时的滑块颜色 */
}
:deep(.n-input){
background: none;
margin-left: 5px;
}
:deep(.n-input__state-border){
border-color: none;
}
:deep(.n-input .n-input__input-el, .n-input .n-input__textarea-el){
color: #fff;
}
:deep(.n-input .n-input__border, .n-input .n-input__state-border){
border: none;
}
:deep(.n-input:not(.n-input--disabled).n-input--focus .n-input__state-border){
border: none !important;
box-shadow: none !important;
}
:deep(.n-base-selection .n-base-selection-label .n-base-selection-input){
background: none;
color: #fff;
}
:deep(.n-base-selection .n-base-selection-label){
background: none;
}
:deep(.n-base-select-menu){
background: none;
}
:deep(.n-base-selection .n-base-selection__border, .n-base-selection .n-base-selection__state-border){
border: none;
}
:deep(.el-select__wrapper){
background: none;
box-shadow: none;
}
:deep(.el-select__placeholder){
color: #fff;
}
/* 1. 输入框容器透明 */
.transparent-select :deep(.n-base-selection) {
background-color: transparent !important;
border: none !important;
box-shadow: none !important;
}
/* 输入框悬浮状态 */
.transparent-select :deep(.n-base-selection:hover) {
background-color: transparent !important;
border: none !important;
}
/* 输入框聚焦状态 */
.transparent-select :deep(.n-base-selection--focus) {
background-color: transparent !important;
border: none !important;
box-shadow: none !important;
}
/* 2. 下拉菜单透明 */
.transparent-select :deep(.n-base-select-menu) {
background-color: transparent !important;
border: none !important;
box-shadow: none !important;
}
/* 3. 下拉选项透明 */
.transparent-select :deep(.n-base-select-option) {
background-color: transparent !important;
}
/* 下拉选项悬浮状态(建议保留微弱的背景,提升可用性) */
.transparent-select :deep(.n-base-select-option:hover) {
background-color: rgba(0, 0, 0, 0.05) !important;
}
/* 4. 隐藏分割线(如果有) */
.transparent-select :deep(.n-base-select-menu__action) {
border-top: none !important;
}
/* 5. 箭头图标半透明(可选) */
.transparent-select :deep(.n-base-selection__arrow) {
opacity: 0.5;
}
/* 清除图标半透明(可选) */
.transparent-select :deep(.n-base-selection__clear) {
opacity: 0.5;
}
</style>

View File

@ -1,13 +1,15 @@
import axios from "axios";
import { gcj02towgs84, wgs84togcj02 } from 'coordtransform'
import * as turf from '@turf/turf'
import { Url } from "./urlFormat";
// import { getMethodCommon } from "../../../api/common";
import { parse } from "./handleGeojson";
import { deepClone } from "./utils";
const urls = new Url()
import { getAppEnvConfig } from '@/utils/env';
const { VITE_GLOB_API_URL,VITE_GLOBAL_NAVIGATION_BASE_URL } = getAppEnvConfig();
const { VITE_GLOB_API_URL,VITE_GLOB_NAVIGATION_BASE_URL } = getAppEnvConfig();
const GD_URL = "https://restapi.amap.com/v5/direction/driving"
const GD_KEY = "6af6a87038f44c8c793aa70331f2b7ca"
import * as mars3d from 'mars3d';
@ -25,7 +27,7 @@ let pathRoadGraphicLayers2 = null
export const getMethodCommon = (url,params) => {
return axios(`${VITE_GLOBAL_NAVIGATION_BASE_URL}${url}?point=${params.startCoord}&point=${params.endCoord}&profile=car&points_encoded=false`,{
return axios(`${VITE_GLOB_NAVIGATION_BASE_URL}${url}?point=${params.startCoord}&point=${params.endCoord}&profile=car&points_encoded=false`,{
method:"GET"
})
}

View File

@ -49,7 +49,7 @@ export function getAppEnvConfig() {
VITE_GLOB_GEOSERVER_BASE_URL,
VITE_GLOB_COFFEE_API_URL,
VITE_GLOB_ANYRTC_BASE_URL,
VITE_GLOBAL_NAVIGATION_BASE_URL,
VITE_GLOB_NAVIGATION_BASE_URL,
} = ENV;
let { VITE_GLOB_API_URL } = ENV;
if (localStorage.getItem(API_ADDRESS)) {
@ -76,7 +76,7 @@ export function getAppEnvConfig() {
VITE_GLOB_APP_FLV_URL,
VITE_GLOB_SRS_API_URL,
VITE_GLOB_ANYRTC_BASE_URL,
VITE_GLOBAL_NAVIGATION_BASE_URL,
VITE_GLOB_NAVIGATION_BASE_URL,
};
}

View File

@ -1,72 +1,80 @@
<template>
<div class="user-task m-4">
<a-form
ref="formRef"
:model="addForm"
labelAlign="left"
:rules="data.rules"
:label-col="labelCol"
:wrapper-col="wrapperCol"
>
<a-form-item label="防火站点名称" name="siteName">
<a-input v-model:value="addForm.siteName" placeholder="请输入" />
</a-form-item>
<a-form-item label="防火站点地址" name="siteAddress">
<a-space>
<a-input v-model:value="addForm.siteAddress" placeholder="请输入" />
<a-button type="primary" @click="mapVisible = true">选择</a-button>
</a-space>
</a-form-item>
<a-form-item label="站点负责人姓名" name="director">
<a-input v-model:value="addForm.director" placeholder="请输入" />
</a-form-item>
<a-form-item label="负责人电话" name="phone">
<a-input v-model:value="addForm.phone" placeholder="请输入" />
</a-form-item>
<a-form-item label="是否有人值守" name="isonduty">
<a-radio-group name="radioGroup" v-model:value="addForm.isonduty">
<a-radio :value="true"></a-radio>
<a-radio :value="false"></a-radio>
</a-radio-group>
</a-form-item>
<a-form-item label="是否接收进山消息" name="isreceive">
<a-radio-group name="radioGroup" v-model:value="addForm.isreceive">
<a-radio :value="true"></a-radio>
<a-radio :value="false"></a-radio>
</a-radio-group>
</a-form-item>
<a-space>
<span>消息接收人员扫码信息消息接收人员</span>
<a-button danger @click="addPerson"></a-button>
</a-space>
<a-table :columns="data.columns" :data-source="accountList" bordered :pagination="false">
<template #bodyCell="{ column, text, record }">
<template v-if="['name'].includes(column.dataIndex)">
<div>
{{ text }}
</div>
</template>
<template v-else-if="['account'].includes(column.dataIndex)">
<div>
{{ text }}
</div>
</template>
<template v-else-if="column.dataIndex === 'operation'">
<a-button danger @click="onDelete(record.id)" size="small" class="ml-2">删除</a-button>
</template>
</template>
</a-table>
</a-form>
<a-modal
width="60%"
v-model:open="accountVisible"
title="选择人员"
@ok="handleFormulaOk"
:destroyOnClose="true"
>
<SelectAccount ref="SelectAccountRef" />
</a-modal>
<a-modal
<div class="user-task m-4 p-4">
<a-row>
<a-col :span="12">
<a-form
ref="formRef"
:model="addForm"
labelAlign="left"
:rules="data.rules"
:label-col="labelCol"
:wrapper-col="wrapperCol"
size="middle"
>
<a-form-item label="摄像头名称" name="name">
<a-input v-model:value="addForm.name" placeholder="请输入" />
</a-form-item>
<a-form-item label="功能分类" name="model">
<a-select
v-model:value="addForm.model"
placeholder="请输入"
:options="modelOptions"
>
</a-select>
</a-form-item>
<a-form-item label="摄像头类型" name="cameraType">
<a-select
v-model:value="addForm.cameraType"
placeholder="请输入"
:options="cameraTypeOptions"
>
</a-select>
</a-form-item>
<a-form-item label="设备厂商" name="manufacturer">
<a-select
v-model:value="addForm.manufacturer"
placeholder="请输入"
:options="manufacturerTypeOptions"
>
</a-select>
</a-form-item>
<a-form-item label="设备序列号" name="serialNumber">
<a-input v-model:value="addForm.serialNumber" placeholder="请输入" />
</a-form-item>
<a-form-item label="设备通道" name="channel">
<a-input v-model:value="addForm.channel" placeholder="请输入" />
</a-form-item>
<a-form-item label="平台IP" name="ip">
<a-input v-model:value="addForm.ip" placeholder="请输入" />
</a-form-item>
<a-form-item label="平台端口" name="port">
<a-input v-model:value="addForm.port" placeholder="请输入" />
</a-form-item>
<a-form-item label="APPKey" name="appKey">
<a-input v-model:value="addForm.appKey" placeholder="请输入" />
</a-form-item>
<a-form-item label="APPSecret" name="appSecret">
<a-input v-model:value="addForm.appSecret" placeholder="请输入" />
</a-form-item>
</a-form>
</a-col>
<a-col :span="12">
<Map style="height:580px;border-radius:5px;" :position="[addForm.lng,addForm.lat]" :addForm="addForm"></Map>
</a-col>
</a-row>
<!-- <a-modal
width="60%"
v-model:open="mapVisible"
title="选择位置"
@ -74,7 +82,7 @@
:destroyOnClose="true"
>
<Map ref="PostionRef" />
</a-modal>
</a-modal> -->
</div>
</template>
@ -82,9 +90,38 @@
import { SelectAccount } from './page';
import { reactive, ref, onMounted, watch, defineProps } from 'vue';
import { Map } from './page';
import axios from 'axios';
import { getAppEnvConfig } from '@/utils/env';
let { VITE_GLOB_API_URL } = getAppEnvConfig();
const labelCol = { span: 3 };
const wrapperCol = { span: 6 };
const cameraTypeOptions = ref([
{
label:"枪机",
value:0
},{
label:"半球",
value:1
},{
label:"快球",
value:2
},{
label:"带云台枪机",
value:3
}
])
const manufacturerTypeOptions = ref([
{
value: "海康",
label: '海康',
},
{
value: "大华",
label: '大华',
}
])
const labelCol = { span: 4 };
const wrapperCol = { span: 18 };
const SelectAccountRef = ref<any>();
const accountVisible = ref(false);
const mapVisible = ref(false);
@ -106,7 +143,7 @@
tableData: [],
});
const PostionRef = ref();
onMounted(() => {});
const addPerson = () => {
accountVisible.value = true;
};
@ -128,7 +165,7 @@
const createSite = () => {
const params = {
...addForm.value,
accountList: accountList.value,
// accountList: accountList.value,
};
return params;
};
@ -147,14 +184,53 @@
createSite,
validateForm,
});
const modelOptions = ref([]);
const cameraTypes = ref({});
const getCameraType = () => {
let url = "/api/SysDataItemDetail/Load";
let querys = {
code:"FMCamera"
}
axios({
method: "get",
url: VITE_GLOB_API_URL + url,
params: querys,
headers: {
'X-Token': localStorage.getItem("X-Token")
}
}).then(res=>{
res.data.result?.forEach((item,index)=>{
modelOptions.value.push({
label:item.itemName,
value:item.itemValue,
})
cameraTypes.value[item.itemValue] = item.itemName
})
})
}
getCameraType();
onMounted(() => {
});
</script>
<style scoped>
::v-deep .ant-alert-info {
margin-bottom: 20px;
margin-bottom: 0px;
}
::v-deep .ant-table-wrapper {
margin-top: 20px;
margin-top: 0px;
}
</style>

View File

@ -3,9 +3,10 @@
</template>
<script setup lang="ts">
import { ref, onMounted } from 'vue';
import { ref, onMounted, defineProps } from 'vue';
import * as mars3d from 'mars3d';
const props = defineProps(["addForm"])
let map: mars3d.Map; //
const vChartRef = ref<HTMLElement>();
onMounted(() => {
@ -245,17 +246,21 @@
});
map.addLayer(pointLayer);
map.on(mars3d.EventType.click, function (event) {
console.log('click', event);
var point = mars3d.LngLatPoint.fromCartesian(event.cartesian); //
point.format(); //
pointData.value = point;
console.log('鼠标单击坐标', point);
console.log('经度:' + point.lng + '\n' + '纬度:' + point.lat + '\n' + '高度:' + point._alt);
if (idNum.value > 0) {
pointLayer.removeGraphic(pointGraphic.value);
}
//
const coordinates = [point.lng, point.lat];
props.addForm.lng = point.lng.toString();
props.addForm.lat = point.lat.toString();
//
// Mars3D ()
pointGraphic.value = new mars3d.graphic.BillboardEntity({
@ -263,7 +268,7 @@
attr: point,
style: {
pixelSize: 100,
scale: 0.5,
scale: 1,
image: '/positioning.png',
},
});

View File

@ -27,15 +27,18 @@
</template>
</BasicTable>
<!-- 添加 编辑-->
<!-- 添加 & 编辑-->
<a-modal
v-model:visible="addModelVisible"
title="摄像头信息"
wrap-class-name="full-modal"
width="80%"
width="70%"
@ok="handleOk"
:get-container="getContainer"
wrap-class-name="modal"
:mask="true"
:keyboard="false"
>
<AddModal ref="AddModalRef" />
<AddModal ref="AddModalRef" />
</a-modal>
<!-- 详情 -->
@ -169,6 +172,9 @@
case 'btnEdit':
handleEdit();
break;
case 'btnDelete':
handleDelete();
break;
case 'btnExport':
break;
default:
@ -183,9 +189,54 @@
const handleOk = () => {
AddModalRef.value.validateForm();
const params = AddModalRef.value.createSite();
console.log('params', params);
addApi(params);
};
async function handleDelete() {
let rows = getSelectRows();
if (rows.length == 0) {
return createMessage.warn('请勾选一条数据进行删除');
}
const query = [rows[0].id];
createConfirm({
iconType: 'info',
title: '删除',
content: '确定要删除当前数据吗',
onOk: async () => {
// const data = await DeleteInterphoneInfo(query);
axios.delete(`${VITE_GLOB_API_URL}/api/Camera/Delete/${rows[0].id}`).then(res => {
if (res) {
handleSuccess();
createMessage.success('删除成功');
} else {
createMessage.error('删除失败');
}
})
},
});
}
const addApi = (params) => {
let url = "/api/Camera/Add";
axios({
method: "post",
url: VITE_GLOB_API_URL + url,
data: params,
headers: {
'X-Token': localStorage.getItem("X-Token")
}
}).then(res=>{
if(res){
addModelVisible.value = false;
}
})
}
const detailInfo = ref(null);
const viewDetail = (record: any) => {