修改冲突和首页异常信息

This commit is contained in:
xhf 2025-03-05 14:56:33 +08:00
commit 377eee0940
2 changed files with 25 additions and 9 deletions

View File

@ -31,7 +31,7 @@
class="relative flex-1 p-30px dark:bg-[var(--login-bg-color)] lt-sm:p-10px overflow-x-hidden overflow-y-auto"
>
<!-- 右上角的主题语言选择 -->
<!-- <div
<div
class="flex items-center justify-between at-2xl:justify-end at-xl:justify-end"
style="color: var(--el-text-color-primary)"
>
@ -41,9 +41,9 @@
</div>
<div class="flex items-center justify-end space-x-10px h-48px">
<ThemeSwitch />
<LocaleDropdown />
<!-- <LocaleDropdown /> -->
</div>
</div> -->
</div>
<!-- 右边的登录界面 -->
<Transition appear enter-active-class="animate__animated animate__bounceInRight">
<div

View File

@ -276,6 +276,7 @@
effect="dark"
:content="item.sortNum || '节点未保存'"
placement="top"
trigger="click"
>
<div
v-if="item.type === 1 && item.layerSelectionShow"
@ -294,6 +295,7 @@
src="https://api.znkjfw.com/admin-api/infra/file/4/get/库位库存_png_179_1739326653035.png"
alt=""
:style="{
verticalAlign: 'top',
width: item.locationWidePx + 'px',
height: item.locationDeepPx + 'px',
border: state.currentItemIndex === index ? '1px dashed #000' : 'none'
@ -308,6 +310,7 @@
"
alt=""
:style="{
verticalAlign: 'top',
width: item.locationWidePx + 'px',
height: item.locationDeepPx + 'px',
border: state.currentItemIndex === index ? '1px dashed #000' : 'none'
@ -319,6 +322,7 @@
src="https://api.znkjfw.com/admin-api/infra/file/4/get/停车场-01_png_179_1739326933020.png"
alt=""
:style="{
verticalAlign: 'top',
width: item.locationWidePx + 'px',
height: item.locationDeepPx + 'px',
border: state.currentItemIndex === index ? '1px dashed #000' : 'none'
@ -330,6 +334,7 @@
src="https://api.znkjfw.com/admin-api/infra/file/4/get/区域_png_179_1739327151876.png"
alt=""
:style="{
verticalAlign: 'top',
width: item.locationWidePx + 'px',
height: item.locationDeepPx + 'px',
border: state.currentItemIndex === index ? '1px dashed #000' : 'none'
@ -341,6 +346,7 @@
src="https://api.znkjfw.com/admin-api/infra/file/4/get/等待点_png_179_1739326991439.png"
alt=""
:style="{
verticalAlign: 'top',
width: item.locationWidePx + 'px',
height: item.locationDeepPx + 'px',
border: state.currentItemIndex === index ? '1px dashed #000' : 'none'
@ -380,7 +386,7 @@
:x2="Number(state.currentDrawX)"
:y2="Number(state.currentDrawY)"
stroke="#00329F"
stroke-width="5"
stroke-width="4"
/>
<template v-if="state.mapRouteList.length > 0">
<template v-for="(curve, index) in state.mapRouteList" :key="index">
@ -405,7 +411,7 @@
:stroke="curve.isSelected ? '#f48924' : '#00329F'"
:marker-start="curve.direction === 2 ? 'url(#double-arrow-start)' : ''"
marker-end="url(#single-arrow)"
stroke-width="5"
stroke-width="4"
@click="handleChooseRoute(curve, index)"
@dblclick="handleEditRoute(curve, index)"
/>
@ -426,7 +432,7 @@
<path
:d="getCurvePath(curve)"
:stroke="curve.isSelected ? '#f48924' : '#00329F'"
stroke-width="5"
stroke-width="4"
fill="none"
:marker-start="curve.direction === 2 ? 'url(#double-arrow-start)' : ''"
marker-end="url(#single-arrow)"
@ -711,6 +717,8 @@ const dragEnd = (locationX, locationY, item, index) => {
let x = Number(locationX) + Number(item.locationWidePx) / 2
let y = Number(locationY) + Number(item.locationDeepPx) / 2
console.log(x, y)
if (x === item.locationX && y === item.locationY) return
let actualPoint = disposeEventPoint(x, y)
state.allMapPointInfo[index].locationX = x
@ -1352,7 +1360,7 @@ const toolbarClick = async (item) => {
break
case 'larger':
//
if (state.imageChangeMultiple < 3) {
if (state.imageChangeMultiple < 4) {
state.imageChangeMultiple += 0.2
} else {
message.warning('不能在放大了')
@ -1360,7 +1368,7 @@ const toolbarClick = async (item) => {
break
case 'smaller':
//
if (state.imageChangeMultiple > 0.3) {
if (state.imageChangeMultiple > 0.2) {
state.imageChangeMultiple -= 0.2
} else {
message.warning('不能在缩小了')
@ -2212,7 +2220,15 @@ const disposeEventPoint = (x, y) => {
}
}
//
const convertActualToBrowser = (pointX, pointY) => {}
const convertActualToBrowser = (x, y) => {
let browserX = Math.max(Number(x) - imgBgObj.origin[0], 0)
let browserY = Math.max(
imgBgObj.origin[1] + Number(imgBgObj.height) * imgBgObj.resolution - Number(y),
0
)
console.log(browserX, browserY)
}
//cmpx
const cmConversionPx = (cWidth, cHeight) => {
let pWidth = Number(cWidth) / imgBgObj.resolution / 100