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
915e3d02
authored
2020-12-10 09:19:07 +0800
by
杨威
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
宗地分割的幢信息删除
1 parent
7d247661
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
31 additions
and
50 deletions
src/views/panel/change/fg/index.vue
src/views/panel/change/fg/index.vue
View file @
915e3d0
...
...
@@ -179,10 +179,10 @@
<div
class=
"fghzxx"
>
<div
class=
"choosedZxx"
>
<span
v-for=
"(dzItem,dzIndex) in item.dz"
:key=
"dzIndex+dzItem.xmmc"
class=
"zxx"
>
{{
dzItem
.
xmmc
}}
<i
class=
"fa fa-times"
></i>
{{
dzItem
.
xmmc
}}
<i
class=
"fa fa-times"
@
click=
"delZxx(index,dzIndex,'dz')"
></i>
</span>
<span
v-for=
"(zrzItem,zrzIndex) in item.zrz"
:key=
"zrzIndex+zrzItem.xmmc"
class=
"zxx"
>
{{
zrzItem
.
xmmc
}}
<i
class=
"fa fa-times"
></i>
{{
zrzItem
.
xmmc
}}
<i
class=
"fa fa-times"
@
click=
"delZxx(index,zrzIndex,'zrz')"
></i>
</span>
</div>
<p
class=
"choose"
>
...
...
@@ -596,54 +596,35 @@
})
},
methods
:
{
mouseenter
(
event
,
index
,
dzIndex
,
type
)
{
let
range
=
document
.
createRange
();
range
.
selectNodeContents
(
event
.
target
);
let
selection
=
window
.
getSelection
();
selection
.
removeAllRanges
();
selection
.
addRange
(
range
);
var
self
=
this
;
document
.
onkeydown
=
function
(
e
){
let
key
=
e
||
window
.
event
||
arguments
.
callee
.
caller
.
arguments
[
0
];
if
(
key
&&
(
key
.
keyCode
==
'8'
||
key
.
code
==
'Delete'
))
{
let
dz
=
{};
let
len
=
self
.
zdFghData
.
newZdlist
[
index
].
fwlist
.
length
-
1
;
switch
(
type
)
{
case
"dz"
:
dz
=
self
.
zdFghData
.
newZdlist
[
index
].
dz
[
dzIndex
];
// 删除数据
self
.
zdFghData
.
newZdlist
[
index
].
dz
.
splice
(
dzIndex
,
1
);
for
(
let
i
=
0
;
i
<
len
;
i
++
){
let
fw
=
self
.
zdFghData
.
newZdlist
[
index
].
fwlist
[
i
];
if
(
fw
.
ztype
==
'dz'
&&
fw
.
zbsm
==
dz
.
bsm
){
self
.
zdFghData
.
newZdlist
[
index
].
fwlist
.
splice
(
i
,
1
);
}
}
// 添加数据
self
.
zdDzList
.
push
(
dz
)
return
;
case
"zrz"
:
dz
=
self
.
zdFghData
.
newZdlist
[
index
].
zrz
[
dzIndex
];
// 删除数据
self
.
zdFghData
.
newZdlist
[
index
].
zrz
.
splice
(
dzIndex
,
1
);
for
(
let
i
=
0
;
i
<
len
;
i
++
){
let
fw
=
self
.
zdFghData
.
newZdlist
[
index
].
fwlist
[
i
];
if
(
fw
.
ztype
==
'zrz'
&&
fw
.
zbsm
==
dz
.
bsm
){
self
.
zdFghData
.
newZdlist
[
index
].
fwlist
.
splice
(
i
,
1
);
}
}
// 添加数据
self
.
zdZrzList
.
push
(
dz
)
return
;
default
:
return
;
delZxx
(
index
,
chilInd
,
type
)
{
let
dz
=
{};
let
len
=
this
.
zdFghData
.
newZdlist
[
index
].
fwlist
.
length
-
1
;
switch
(
type
)
{
case
"dz"
:
dz
=
this
.
zdFghData
.
newZdlist
[
index
].
dz
[
chilInd
];
// 删除数据
this
.
zdFghData
.
newZdlist
[
index
].
dz
.
splice
(
chilInd
,
1
);
for
(
let
i
=
0
;
i
<
len
;
i
++
){
let
fw
=
this
.
zdFghData
.
newZdlist
[
index
].
fwlist
[
i
];
if
(
fw
.
ztype
==
'dz'
&&
fw
.
zbsm
==
dz
.
bsm
){
this
.
zdFghData
.
newZdlist
[
index
].
fwlist
.
splice
(
i
,
1
);
}
}
}
};
},
mouseleave
(
event
)
{
let
selection
=
window
.
getSelection
();
selection
.
removeAllRanges
();
break
;
case
"zrz"
:
dz
=
this
.
zdFghData
.
newZdlist
[
index
].
zrz
[
chilInd
];
// 删除数据
this
.
zdFghData
.
newZdlist
[
index
].
zrz
.
splice
(
chilInd
,
1
);
for
(
let
i
=
0
;
i
<
len
;
i
++
){
let
fw
=
this
.
zdFghData
.
newZdlist
[
index
].
fwlist
[
i
];
if
(
fw
.
ztype
==
'zrz'
&&
fw
.
zbsm
==
dz
.
bsm
){
this
.
zdFghData
.
newZdlist
[
index
].
fwlist
.
splice
(
i
,
1
);
}
}
break
;
default
:
break
;
}
},
// 重置数据
result
()
{
...
...
@@ -1240,7 +1221,7 @@
i{
display
:
none
;
position
:
absolute
;
right
:
4px
;
right
:
0
;
top
:
-6px
;
}
}
...
...
Please
register
or
sign in
to post a comment