Merge branch 'main' of http://123.132.248.154:10000/HC_YFZX/CaiYuanYiTiHua
commit
f128873f57
|
|
@ -90,6 +90,9 @@
|
|||
tableSpan.value = 0;
|
||||
mapSpan.value = 24;
|
||||
searchFormSchema.value = searchFormSchema_map;
|
||||
setTimeout(() => {
|
||||
mapboxComponentRef.value.resize();
|
||||
}, 200);
|
||||
}
|
||||
// 半屏
|
||||
function exitScreen() {
|
||||
|
|
@ -97,6 +100,9 @@
|
|||
tableSpan.value = 12;
|
||||
mapSpan.value = 12;
|
||||
searchFormSchema.value = searchFormSchema_table;
|
||||
setTimeout(() => {
|
||||
mapboxComponentRef.value.resize();
|
||||
}, 200);
|
||||
}
|
||||
|
||||
// 左侧表格的搜索、表格和分页数据------------------------------------------------------------
|
||||
|
|
@ -282,8 +288,8 @@
|
|||
type: 'FeatureCollection',
|
||||
features: [],
|
||||
};
|
||||
let lngList: any = [];
|
||||
let latList: any = [];
|
||||
// let lngList: any = [];
|
||||
// let latList: any = [];
|
||||
tasklist?.forEach((item, index) => {
|
||||
// lngList.push(parseFloat(item.gemo.x));
|
||||
// latList.push(parseFloat(item.gemo.y));
|
||||
|
|
@ -364,7 +370,12 @@
|
|||
const handleOpen = (path) => {
|
||||
modalOpen.value = true;
|
||||
modalTitle.value = '';
|
||||
modalImage.value = VITE_GLOB_API_URL_VAR.value + path;
|
||||
// 正则表达式验证函数
|
||||
if (isValidUrl(path)) {
|
||||
modalImage.value = path;
|
||||
} else {
|
||||
modalImage.value = VITE_GLOB_API_URL_VAR.value + path;
|
||||
}
|
||||
};
|
||||
// 关闭窗口
|
||||
const handleCancel = () => {
|
||||
|
|
@ -372,6 +383,12 @@
|
|||
modalTitle.value = '';
|
||||
modalImage.value = '';
|
||||
};
|
||||
// 正则表达式验证函数
|
||||
function isValidUrl(url: string): boolean {
|
||||
const regex =
|
||||
/^(?:http|ftp)s?:\/\/(?:(?:[A-Z0-9](?:[A-Z0-9-]{0,61}[A-Z0-9])?\.)+(?:[A-Z]{2,6}\.?|[A-Z0-9-]{2,}\.?)|localhost|\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}|\[?[A-F0-9]*:[A-F0-9:]+\]?)(?::\d+)?(?:\/?|[\/?]\S+)$/i;
|
||||
return regex.test(url);
|
||||
}
|
||||
|
||||
onMounted(() => {
|
||||
handleReset();
|
||||
|
|
|
|||
|
|
@ -231,6 +231,7 @@
|
|||
|
||||
// 航飞图片-图层
|
||||
function AchievementManageRaster(taskLayerGeoJson, lngLat, zoom) {
|
||||
// resize();
|
||||
// 清除图层
|
||||
clearTaskLayer('AchievementManageRaster');
|
||||
// 县区边界
|
||||
|
|
@ -297,6 +298,11 @@
|
|||
}
|
||||
}
|
||||
|
||||
// 重新计算地图大小
|
||||
function resize() {
|
||||
map.resize();
|
||||
}
|
||||
|
||||
onMounted(() => {
|
||||
mapboxgl.accessToken = MAPBOX_TOKEN;
|
||||
map = initMap();
|
||||
|
|
@ -313,6 +319,7 @@
|
|||
GeoserverManagementRaster,
|
||||
GeoTiffManagerRaster,
|
||||
AchievementManageRaster,
|
||||
resize,
|
||||
});
|
||||
</script>
|
||||
<style type="less" scoped>
|
||||
|
|
|
|||
Loading…
Reference in New Issue