Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
marketing
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
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
marketing-web
marketing
Commits
c90d88d6
Commit
c90d88d6
authored
Jun 07, 2022
by
crushh
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update: 查看中奖率
parent
1eebe72f
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
1 additions
and
4 deletions
+1
-4
info.vue
src/views/game/cmh/info.vue
+1
-2
prize-config.vue
src/views/game/cmh/prize-config.vue
+0
-2
No files found.
src/views/game/cmh/info.vue
View file @
c90d88d6
...
...
@@ -285,10 +285,9 @@ export default {
item
.
prizeRate
=
prizeRate
.
toFixed
(
2
);
}
}
);
const
rateTotal
=
this
.
form
.
gamePrizeList
.
map
(
item
=>
(
item
.
prizeType
!=
0
?
item
.
prizeRate
:
0
)).
reduce
((
pre
,
current
)
=>
Number
(
pre
)
+
Number
(
current
));
let
prizeArr
=
this
.
form
.
gamePrizeList
.
filter
(
item
=>
item
.
prizeType
==
0
);
prizeArr
.
forEach
(
item
=>
{
const
prizeRate
=
(
100
-
rateTotal
)
/
prizeArr
.
length
||
0
;
const
prizeRate
=
(
100
-
this
.
form
.
gameRuleInfo
.
winChance
)
/
prizeArr
.
length
||
0
;
item
.
prizeRate
=
prizeRate
.
toFixed
(
2
);
}
);
this
.
form
.
gamePrizeList
=
this
.
form
.
gamePrizeList
.
splice
(
0
);
...
...
src/views/game/cmh/prize-config.vue
View file @
c90d88d6
...
...
@@ -401,10 +401,8 @@ export default {
item
.
prizeRate
=
prizeRate
.
toFixed
(
2
);
}
});
let
prizeArr
=
this
.
prizeForm
.
gamePrizeList
.
filter
(
item
=>
item
.
prizeType
==
0
);
prizeArr
.
forEach
(
item
=>
{
console
.
log
(
item
);
const
prizeRate
=
(
100
-
this
.
prizeForm
.
winChance
)
/
prizeArr
.
length
||
0
;
item
.
prizeRate
=
prizeRate
.
toFixed
(
2
);
});
...
...
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