Merge branch 'shenzhen-dev' into cjw-dev
This commit is contained in:
commit
caacd541cf
@ -104,7 +104,7 @@
|
||||
</script>
|
||||
<script type="module" src="/src/main.ts"></script>
|
||||
<script
|
||||
src="https://webapi.amap.com/maps?v=1.4.14&key=8d7b8cd643454bec7737b3423647be21&plugin=AMap.Autocomplete,AMap.PlaceSearch,AMap.MouseTool,AMap.Geocoder,AMap.Driving"
|
||||
src="https://webapi.amap.com/maps?v=2.0&key=8d7b8cd643454bec7737b3423647be21&plugin=AMap.Autocomplete,AMap.PlaceSearch,AMap.MouseTool,AMap.Geocoder,AMap.Driving"
|
||||
defer="defer"></script>
|
||||
<script src="/jquery-1.12.4.min.js"></script>
|
||||
<!-- 用于前端与插件交互 -->
|
||||
|
||||
@ -10,6 +10,7 @@ export const GlobalStore = defineStore({
|
||||
id: "GlobalState",
|
||||
// state: 返回对象的函数
|
||||
state: (): GlobalState => ({
|
||||
globalScale: 1,
|
||||
sn: "",
|
||||
// token
|
||||
token: "",
|
||||
|
||||
@ -1,5 +1,6 @@
|
||||
/* GlobalState */
|
||||
export interface GlobalState {
|
||||
globalScale: number | null;
|
||||
sn: string | null;
|
||||
Message: Object | null;
|
||||
token: string | null;
|
||||
|
||||
@ -372,6 +372,14 @@ let formRules = ref({
|
||||
}
|
||||
]
|
||||
});
|
||||
const resetMapSize = () => {
|
||||
console.log(666)
|
||||
setTimeout(() => {
|
||||
let mapContent = document.getElementById("mapContainer");
|
||||
console.log(mapContent)
|
||||
mapContent.style.transform = `scale(${1/store.globalScale})`;
|
||||
}, 200);
|
||||
};
|
||||
onMounted(() => {
|
||||
choiceMonth.value = formatMonthTime(dayValue.value);
|
||||
console.log("当前月份", choiceMonth.value);
|
||||
@ -380,6 +388,15 @@ onMounted(() => {
|
||||
getCrewListData();
|
||||
getFenceList();
|
||||
getFenceType();
|
||||
resetMapSize()
|
||||
window.addEventListener("resize", e => {
|
||||
resetMapSize()
|
||||
});
|
||||
});
|
||||
onBeforeMount(() => {
|
||||
window.removeEventListener("resize", e => {
|
||||
resetMapSize()
|
||||
});
|
||||
});
|
||||
// computed: {
|
||||
// //Uploader实例
|
||||
@ -1317,9 +1334,9 @@ function echoPersonMarker(item) {
|
||||
</style>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
// :deep(.h-card .content) {
|
||||
// background: none;
|
||||
// }
|
||||
:deep(.h-card .content) {
|
||||
overflow: hidden;
|
||||
}
|
||||
// 多边形表单
|
||||
.fence-shape {
|
||||
display: flex;
|
||||
|
||||
@ -404,6 +404,14 @@ let addEditForm = ref({
|
||||
type: 1,
|
||||
driver: ""
|
||||
});
|
||||
const resetMapSize = () => {
|
||||
console.log(666)
|
||||
setTimeout(() => {
|
||||
let mapContent = document.getElementById("mapContainer");
|
||||
console.log(mapContent)
|
||||
mapContent.style.transform = `scale(${1/store.globalScale})`;
|
||||
}, 200);
|
||||
};
|
||||
onMounted(() => {
|
||||
choiceMonth.value = formatMonthTime(dayValue.value);
|
||||
// console.log("当前月份", choiceMonth.value);
|
||||
@ -412,6 +420,15 @@ onMounted(() => {
|
||||
getCrewListData();
|
||||
getFenceList();
|
||||
getFenceType();
|
||||
resetMapSize()
|
||||
window.addEventListener("resize", e => {
|
||||
resetMapSize()
|
||||
});
|
||||
});
|
||||
onBeforeMount(() => {
|
||||
window.removeEventListener("resize", e => {
|
||||
resetMapSize()
|
||||
});
|
||||
});
|
||||
// computed: {
|
||||
// //Uploader实例
|
||||
@ -1502,9 +1519,9 @@ function echoPersonMarker(item) {
|
||||
</style>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
// :deep(.h-card .content) {
|
||||
// background: none;
|
||||
// }
|
||||
:deep(.h-card .content) {
|
||||
overflow: hidden;
|
||||
}
|
||||
// 多边形表单
|
||||
.fence-shape {
|
||||
display: flex;
|
||||
@ -1712,8 +1729,8 @@ function echoPersonMarker(item) {
|
||||
.itemBox42 {
|
||||
width: 60%;
|
||||
display: flex;
|
||||
justify-content: start;
|
||||
align-items: start;
|
||||
justify-content: flex-start;
|
||||
align-items: flex-start;
|
||||
color: black;
|
||||
margin-right: 50%;
|
||||
}
|
||||
|
||||
@ -2014,8 +2014,8 @@ function echoPersonMarker(item) {
|
||||
.itemBox42 {
|
||||
width: 60%;
|
||||
display: flex;
|
||||
justify-content: start;
|
||||
align-items: start;
|
||||
justify-content: flex-start;
|
||||
align-items: flex-start;
|
||||
color: black;
|
||||
margin-right: 50%;
|
||||
}
|
||||
|
||||
@ -110,7 +110,6 @@ let nowDate = ref("2023.11.16" as any);
|
||||
let projectPassDay = ref(0 as any);
|
||||
//获取项目信息
|
||||
const projectTimeInfo = ref({} as any);
|
||||
const scaleValue = ref(1);
|
||||
const contentWidth = ref(0);
|
||||
const contentHeight = ref(0);
|
||||
const calculateAspectRatio = () => {
|
||||
@ -137,7 +136,7 @@ const calculateAspectRatio = () => {
|
||||
console.log('contentHeight',contentHeight.value)
|
||||
};
|
||||
const scaleChange = (data:any) => {
|
||||
scaleValue.value = data;
|
||||
store.globalScale = data;
|
||||
}
|
||||
const getProjectInfo = async () => {
|
||||
getNowDate();
|
||||
|
||||
@ -47,7 +47,7 @@
|
||||
<ysyPlayAndPlayback :ref="'ysy'" :ysyParams="ysyParams"></ysyPlayAndPlayback>
|
||||
</div>
|
||||
<!-- 播放海康 -->
|
||||
<div ref="playWndBox" style="width: 90%; height: 100%; margin: 0 5% 2% 5%">
|
||||
<div ref="playWndBox" style="width: 96%; height: 100%;margin: 0 2% 0% 2%">
|
||||
<div id="playWnd" class="playWnd" style="width: 100%; height: 100%"></div>
|
||||
<!-- :style="{
|
||||
height: playWndHeight + 'px',
|
||||
@ -168,18 +168,25 @@ onMounted(async () => {
|
||||
// 监听scroll事件,使插件窗口尺寸跟随DIV窗口变化
|
||||
window.addEventListener("scroll", () => {
|
||||
if (oWebControl.value == undefined) {
|
||||
oWebControl.JS_Resize(tagDomObj?.clientWidth, tagDomObj?.clientHeight);
|
||||
setTimeout(function(){
|
||||
oWebControl.JS_Resize(playWndWidth.value * store.globalScale, playWndHeight.value * store.globalScale);
|
||||
},200)
|
||||
}
|
||||
});
|
||||
|
||||
// 监听resize事件,使插件窗口尺寸跟随DIV窗口变化
|
||||
window.addEventListener("resize", e => {
|
||||
if (oWebControl.value == undefined) {
|
||||
// console.log("wwwww", e);
|
||||
oWebControl.JS_Resize(tagDomObj?.clientWidth, tagDomObj?.clientHeight);
|
||||
// oWebControl.JS_Resize(playWndHeight.value, playWndWidth.value);
|
||||
// setWndCover();
|
||||
setTimeout(function(){
|
||||
oWebControl.JS_Resize(playWndWidth.value * store.globalScale, playWndHeight.value * store.globalScale);
|
||||
},200)
|
||||
}
|
||||
// if (oWebControl.value == undefined) {
|
||||
// // console.log("wwwww", e);
|
||||
// oWebControl.JS_Resize(tagDomObj?.clientWidth, tagDomObj?.clientHeight);
|
||||
// // oWebControl.JS_Resize(playWndHeight.value, playWndWidth.value);
|
||||
// // setWndCover();
|
||||
// }
|
||||
});
|
||||
// 初始化播放器插件
|
||||
nextTick(async () => {
|
||||
@ -313,7 +320,7 @@ const init = (callback: (() => void) | undefined) => {
|
||||
})
|
||||
})
|
||||
.then(function (oData: any) {
|
||||
oWebControl.JS_Resize(playWndWidth.value, playWndHeight.value); // 初始化后resize一次,规避firefox下首次显示窗口后插件窗口未与DIV窗口重合问题
|
||||
oWebControl.JS_Resize(playWndWidth.value * store.globalScale, playWndHeight.value * store.globalScale);; // 初始化后resize一次,规避firefox下首次显示窗口后插件窗口未与DIV窗口重合问题
|
||||
|
||||
if (callback) {
|
||||
callback();
|
||||
@ -431,8 +438,8 @@ const previewVideo = (data: string | null) => {
|
||||
height: 100%;
|
||||
|
||||
.videoPlayerBig {
|
||||
width: 90%;
|
||||
height: 90%;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
position: relative;
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user