Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
glsx
/
gl_tape
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
3
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit b95f055b
authored
Oct 21, 2025
by
cen
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
fix: 更改父id
1 parent
b7886b4c
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
6 deletions
pages/equity/detail/components/History.vue
pages/equity/detail/components/History.vue
View file @
b95f055
...
@@ -342,21 +342,21 @@ export default {
...
@@ -342,21 +342,21 @@ export default {
})
})
}
else
if
(
item
.
level
===
3
)
{
}
else
if
(
item
.
level
===
3
)
{
// 当level为3时,先按parentId分组
// 当level为3时,先按parentId分组
const
parent
Id
=
item
.
parentId
const
parent
CategoryType
=
item
.
parentCategoryType
if
(
level3Map
.
has
(
parent
Id
))
{
if
(
level3Map
.
has
(
parent
CategoryType
))
{
// 如果parentId已存在,则将当前categoryType添加到数组中
// 如果parentId已存在,则将当前categoryType添加到数组中
level3Map
.
get
(
parent
Id
).
push
(
item
.
categoryType
)
level3Map
.
get
(
parent
CategoryType
).
push
(
item
.
categoryType
)
}
else
{
}
else
{
// 如果parentId不存在,则创建新数组
// 如果parentId不存在,则创建新数组
level3Map
.
set
(
parent
Id
,
[
item
.
categoryType
])
level3Map
.
set
(
parent
CategoryType
,
[
item
.
categoryType
])
}
}
}
}
})
})
// 然后将分组后的level3数据添加到historyOrderGoodsTypes中
// 然后将分组后的level3数据添加到historyOrderGoodsTypes中
level3Map
.
forEach
((
categoryTypes
,
parent
Id
)
=>
{
level3Map
.
forEach
((
categoryTypes
,
parent
CategoryType
)
=>
{
this
.
historyOrderGoodsTypes
.
push
({
this
.
historyOrderGoodsTypes
.
push
({
secondaryGoodsType
:
parent
Id
,
secondaryGoodsType
:
parent
CategoryType
,
thirdLevelGoodsTypes
:
categoryTypes
thirdLevelGoodsTypes
:
categoryTypes
})
})
})
})
...
...
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment