Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
T
taobao-mini-template
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
2
Issues
2
List
Board
Labels
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
qinhaitao
taobao-mini-template
Commits
2000cfcf
Commit
2000cfcf
authored
Aug 26, 2020
by
李硕
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
排行榜奖品逻辑删除修改
parent
9d1965ff
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
2 deletions
+9
-2
rank-table.js
client/components/rank/rank-table/rank-table.js
+5
-2
yarn.lock
yarn.lock
+4
-0
No files found.
client/components/rank/rank-table/rank-table.js
View file @
2000cfcf
...
...
@@ -55,12 +55,15 @@ Component({
},
onPrizeUpdate
(
data
,
index
)
{
const
{
onChange
,
list
,
dataName
}
=
this
.
props
;
//排行榜奖品切换不同奖品时改为逻辑删除
if
(
list
[
index
].
type
!==
data
.
type
)
{
console
.
log
(
'更换奖品的id'
);
data
.
_id
=
null
;
}
const
updatedData
=
list
.
map
((
v
,
i
)
=>
{
if
(
index
===
i
)
return
{
...
v
,
...
data
}
return
v
;
})
onChange
&&
onChange
(
updatedData
,
dataName
)
},
onPrizeAdd
(
data
)
{
...
...
yarn.lock
0 → 100644
View file @
2000cfcf
# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.
# yarn lockfile v1
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
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 comment