修复部分宽度因为动态计算导致的适配问题

master
许宏杰 6 months ago
parent dbadefa27c
commit 2020ea3a23

@ -231,6 +231,7 @@ export default {
height: 41px; height: 41px;
width: 58px; width: 58px;
background: url("~@/assets/images/ui/reset.png"); background: url("~@/assets/images/ui/reset.png");
background-size: 100% 100%;
} }
} }
.el-button { .el-button {

@ -45,6 +45,7 @@ import { getNumNew } from "@/api/taicangpop/data";
import { getBuilding } from "@/api/taicangpop/building"; import { getBuilding } from "@/api/taicangpop/building";
import colorCell from "./ColorCell/index.vue"; import colorCell from "./ColorCell/index.vue";
import { v4 as uuidv4 } from "uuid"; import { v4 as uuidv4 } from "uuid";
import { pxToVw } from "@/utils/myFuntion.js";
export default { export default {
data() { data() {
return { return {
@ -191,8 +192,11 @@ export default {
const list = document.getElementsByClassName("foldPane-bottom")[0]; const list = document.getElementsByClassName("foldPane-bottom")[0];
const build = document.getElementsByClassName("building-container")[0]; const build = document.getElementsByClassName("building-container")[0];
if (this.queryParamsXiaoqu.buildingId) { if (this.queryParamsXiaoqu.buildingId) {
list.style.left = `390px`; list.style.left = pxToVw(390);
list.style.width = `calc(100% - (390px + ${build.offsetWidth}px) )`; list.style.width = `calc(100% - (${pxToVw(390)} + ${
build.offsetWidth
}px) )`;
list.style.transform = `translateX(0)`; list.style.transform = `translateX(0)`;
} }
if (this.clickResult.id) this.clickHouse(this.clickResult); if (this.clickResult.id) this.clickHouse(this.clickResult);
@ -239,7 +243,7 @@ export default {
#95123a, #95123a,
rgba(149, 18, 58, 0.1) rgba(149, 18, 58, 0.1)
); );
padding-top: 85px;
.floor-number { .floor-number {
height: 23px; height: 23px;
width: 50px; width: 50px;

@ -585,7 +585,7 @@ import {
delPerson, delPerson,
getPerson, getPerson,
} from "@/api/taicangpop/person.js"; } from "@/api/taicangpop/person.js";
import { pxToVw, handleColor, getSb } from "@/utils/myFuntion.js"; import { pxToVw, handleColor } from "@/utils/myFuntion.js";
import ColorCell from "@/components/ColorCell"; import ColorCell from "@/components/ColorCell";
import { validateAndParseIDCard } from "@/utils/myFuntion.js"; import { validateAndParseIDCard } from "@/utils/myFuntion.js";
const moment = require("moment"); const moment = require("moment");
@ -700,7 +700,7 @@ export default {
...mapGetters(["houseItem", "queryParamsXiaoqu", "userId"]), ...mapGetters(["houseItem", "queryParamsXiaoqu", "userId"]),
handlerWidth() { handlerWidth() {
return { return {
width: pxToVw(this.houseItem.buildingWidth), width: this.houseItem.buildingWidth + "px",
zIndex: this.queryParamsXiaoqu.xiaoquId == 267 ? 2007 : 100, zIndex: this.queryParamsXiaoqu.xiaoquId == 267 ? 2007 : 100,
}; };
}, },

Loading…
Cancel
Save