Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
W
wfc13
Project
Project
Details
Activity
Releases
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
wildfirecode13
wfc13
Commits
5163e0f6
Commit
5163e0f6
authored
Sep 27, 2021
by
wildfirecode13
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
11
parent
6b9e17c8
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
28 additions
and
6 deletions
+28
-6
index.do.json
project/mock/webNet/dazzle/index.do.json
+3
-3
IndexScene.ts
project/src/scenes/IndexScene.ts
+25
-3
No files found.
project/mock/webNet/dazzle/index.do.json
View file @
5163e0f6
...
...
@@ -3,10 +3,10 @@
"data"
:
{
"needPop"
:
0
,
"activityOver"
:
false
,
"surplusCount"
:
1
,
"credits"
:
10
,
"surplusCount"
:
0
,
"credits"
:
222
,
"needCredits"
:
111
,
"type"
:
1
,
"type"
:
2
,
"options"
:
[{
"degree"
:
null
,
"icon"
:
"//yun.duiba.com.cn/images/202108/ma00scey0f.png"
,
...
...
project/src/scenes/IndexScene.ts
View file @
5163e0f6
...
...
@@ -8,6 +8,8 @@ import getQueryParams from "../common/getQueryParams";
import
TestButton
from
"../common/TestButton"
;
import
{
isMember
}
from
"../isMember"
;
import
{
getTimesPanel
}
from
"../panels/getTimes"
;
import
{
notEnoughMoneySharePanel
}
from
"../panels/notEnoughMoneyShare"
;
import
{
notEnoughMoneyShareHasTimesPanel
}
from
"../panels/notEnoughMoneyShareHasTimes"
;
import
{
RulePanel
}
from
"../panels/RulePanel"
;
import
{
SharePanel
}
from
"../panels/share"
;
import
{
timesNotEnoughPanel
}
from
"../panels/timesNotEnough"
;
...
...
@@ -185,10 +187,29 @@ export class IndexScene extends Scene {
}
handleShare
=
async
()
=>
{
if
(
indexData
.
data
.
type
==
2
&&
indexData
.
data
.
surplusCount
<=
0
)
{
showPanel
(
timesNotEnoughPanel
);
// if (indexData.data.type == 2 && indexData.data.surplusCount <= 0) {
// showPanel(timesNotEnoughPanel);
// } else {
// showPanel(getTimesPanel);
// }
if
(
indexData
.
data
.
type
==
1
)
{
if
(
indexData
.
data
.
surplusCount
<=
0
)
{
//没次数
showPanel
(
notEnoughMoneySharePanel
);
}
else
{
if
(
indexData
.
data
.
needCredits
>
indexData
.
data
.
credits
)
{
showPanel
(
notEnoughMoneyShareHasTimesPanel
);
}
else
{
}
}
}
else
{
if
(
indexData
.
data
.
surplusCount
>
0
)
{
//有次数
}
else
{
showPanel
(
getTimesPanel
);
}
}
}
...
...
@@ -228,6 +249,7 @@ export class IndexScene extends Scene {
getBoxButton
.
visible
=
true
;
shareButton
.
visible
=
false
;
if
(
result
.
data
.
needCredits
>
result
.
data
.
credits
)
{
hand
.
visible
=
true
;
getBoxButton
.
visible
=
false
;
shareButton
.
visible
=
true
;
}
...
...
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