Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
任超
/
js.CadastralSystem
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
0ac9f2de
authored
2020-11-27 17:03:05 +0800
by
杨威
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
楼盘表层户高度计算
1 parent
b54d20d2
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
5 deletions
src/views/zrz/lpb/bjlp/lpbContent/index.vue
src/views/zrz/lpb/bjlp/lpbContent/index.vue
View file @
0ac9f2d
...
...
@@ -9,7 +9,7 @@
<div
class=
"ljz-zdy"
:style=
"
{'min-height':ljzzdyHeight+40+'px'}" ref="ljzzdy" v-show="ljzs.zdys.length>0" v-for="(zdys,zdyIndex) in ljzs.zdys" :key="zdyIndex" >
<!-- 循环幢单元下的层户 -->
<!--
<div
class=
"chTable-wrap"
>
-->
<table
class=
"chTable"
border=
"1"
cellspacing=
"0"
cellpadding=
"0"
v-show=
"zdys.cs.length>0"
>
<table
class=
"chTable"
:style=
"
{'top':(ljzzdyHeight-1-zdys.cs.length*65)+'px'}"
border="1" cellspacing="0" cellpadding="0" v-show="zdys.cs.length>0">
<tr
v-for=
"(cs,csIndex) in zdys.cs"
:key=
"csIndex"
>
<!-- 显示层数 -->
<td
class=
"floor"
@
contextmenu
.
prevent=
"openMenu($event, cs,'c')"
@
click=
"handleClickC($event,cs)"
>
{{
cs
.
sjc
}}
层
</td>
...
...
@@ -25,7 +25,7 @@
</div>
<!-- 循环逻辑幢下的层户 -->
<div
class=
"ljz-ch"
:style=
"
{'min-height':ljzzdyHeight+40+'px'}" v-if="ljzs.cs.length>0">
<table
class=
"chTable"
border=
"1"
cellspacing=
"0"
cellpadding=
"0"
>
<table
class=
"chTable"
:style=
"
{'top':(ljzzdyHeight+40-1-ljzs.cs.length*65)
<0
?
0:
(
ljzzdyHeight
+
40-1-ljzs
.
cs
.
length
*
65
)
+'
px
'}"
border=
"1"
cellspacing=
"0"
cellpadding=
"0"
>
<tr
v-for=
"(cs) in ljzs.cs"
:key=
"cs.bsm"
>
<!-- 显示层数 -->
<td
class=
"floor"
@
contextmenu
.
prevent=
"openMenu($event, cs,'c')"
@
click=
"handleClickC($event,cs)"
>
{{
cs
.
sjc
}}
层
</td>
...
...
@@ -199,9 +199,11 @@ export default {
//计算自然幢下的幢单元高度,如果有比层户高的幢单元,则幢单元高度设为最高的幢单元高度,如果没有,则设为层户高度
higher
=
highest
>
this
.
$refs
.
ch
.
offsetHeight
?
true
:
false
;
this
.
zdyHeight
=
higher
?
highest
:
this
.
$refs
.
ch
.
offsetHeight
;
highest
=
0
;
this
.
zdyWidth
+=
this
.
$refs
.
ch
.
offsetWidth
;
}
else
{
this
.
zdyHeight
=
highest
;
highest
=
0
;
}
}
else
{
// this.zdyWidth = 124;
...
...
@@ -224,13 +226,21 @@ export default {
if
(
this
.
$refs
.
ljzch
!=
undefined
)
{
//计算自然幢下的幢单元高度,如果有比层户高的幢单元,则幢单元高度设为最高的幢单元高度,如果没有,则设为层户高度
higher
=
highest
>
this
.
$refs
.
ljzch
.
offsetHeight
?
true
:
false
;
this
.
ljzzdyHeight
=
higher
?
highest
:
this
.
$refs
.
ljzch
.
offsetHeight
;
this
.
$nextTick
(()
=>
{
this
.
ljzzdyHeight
=
higher
?
highest
:
this
.
$refs
.
ljzch
.
offsetHeight
;
highest
=
0
;
})
}
else
{
this
.
ljzzdyHeight
=
highest
;
this
.
$nextTick
(()
=>
{
this
.
ljzzdyHeight
=
highest
;
highest
=
0
;
})
}
}
else
{
// this.zdyWidth = 124;
}
},
//户单击事件
handleTdClick
(
e
,
bsm
)
{
...
...
@@ -497,7 +507,7 @@ export default {
background-color
:
blanchedalmond
;
}
td
{
width
:
124px
;
min-
width
:
124px
;
height
:
64px
;
line-height
:
64px
;
text-align
:
center
;
...
...
Please
register
or
sign in
to post a comment