Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
K
kww_dayDayGetCredits_250512
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
SparkProjects
kww_dayDayGetCredits_250512
Commits
ca86ee0b
Commit
ca86ee0b
authored
May 19, 2025
by
徐士卿
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
md
parent
ecfa20a9
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
23 additions
and
12 deletions
+23
-12
challenge.ts
mock/challenge.ts
+8
-1
Check.tsx
src/pages/HomePage/Check/Check.tsx
+14
-11
store.ts
src/store/store.ts
+1
-0
No files found.
mock/challenge.ts
View file @
ca86ee0b
...
@@ -48,7 +48,7 @@ export default [
...
@@ -48,7 +48,7 @@ export default [
],
],
"hasChallengeDay"
:
5
,
"hasChallengeDay"
:
5
,
"latestChallengeSuccessTime"
:
5
,
"latestChallengeSuccessTime"
:
5
,
"boolNeedResign"
:
tru
e
,
"boolNeedResign"
:
fals
e
,
"boolNeedResignPop"
:
false
,
"boolNeedResignPop"
:
false
,
"taskInfoList"
:
[
"taskInfoList"
:
[
{
{
...
@@ -61,6 +61,7 @@ export default [
...
@@ -61,6 +61,7 @@ export default [
"intervalType"
:
-
18649400.705077305
,
"intervalType"
:
-
18649400.705077305
,
"jumpUrl"
:
''
,
"jumpUrl"
:
''
,
"boolShowCompletePop"
:
false
,
"boolShowCompletePop"
:
false
,
"id"
:
1
,
},
},
{
{
"code"
:
"xhqg_{200}"
,
"code"
:
"xhqg_{200}"
,
...
@@ -72,6 +73,7 @@ export default [
...
@@ -72,6 +73,7 @@ export default [
"intervalType"
:
69737947.09434697
,
"intervalType"
:
69737947.09434697
,
"jumpUrl"
:
''
,
"jumpUrl"
:
''
,
"boolShowCompletePop"
:
false
,
"boolShowCompletePop"
:
false
,
"id"
:
2
,
},
},
{
{
"code"
:
"xhjf_{300}"
,
"code"
:
"xhjf_{300}"
,
...
@@ -83,6 +85,7 @@ export default [
...
@@ -83,6 +85,7 @@ export default [
"intervalType"
:
15800400.399293274
,
"intervalType"
:
15800400.399293274
,
"jumpUrl"
:
''
,
"jumpUrl"
:
''
,
"boolShowCompletePop"
:
false
,
"boolShowCompletePop"
:
false
,
"id"
:
3
,
},
},
{
{
"code"
:
"yqzl"
,
"code"
:
"yqzl"
,
...
@@ -94,6 +97,7 @@ export default [
...
@@ -94,6 +97,7 @@ export default [
"intervalType"
:
-
54395962.26549375
,
"intervalType"
:
-
54395962.26549375
,
"jumpUrl"
:
''
,
"jumpUrl"
:
''
,
"boolShowCompletePop"
:
false
,
"boolShowCompletePop"
:
false
,
"id"
:
4
,
},
},
{
{
"code"
:
"yqzl_new"
,
"code"
:
"yqzl_new"
,
...
@@ -105,6 +109,7 @@ export default [
...
@@ -105,6 +109,7 @@ export default [
"intervalType"
:
-
54395962.26549375
,
"intervalType"
:
-
54395962.26549375
,
"jumpUrl"
:
''
,
"jumpUrl"
:
''
,
"boolShowCompletePop"
:
false
,
"boolShowCompletePop"
:
false
,
"id"
:
5
,
},
},
{
{
"code"
:
"scan"
,
"code"
:
"scan"
,
...
@@ -116,6 +121,7 @@ export default [
...
@@ -116,6 +121,7 @@ export default [
"intervalType"
:
-
54395962.26549375
,
"intervalType"
:
-
54395962.26549375
,
"jumpUrl"
:
''
,
"jumpUrl"
:
''
,
"boolShowCompletePop"
:
false
,
"boolShowCompletePop"
:
false
,
"id"
:
6
,
},
},
{
{
"code"
:
"browse_{x}"
,
"code"
:
"browse_{x}"
,
...
@@ -127,6 +133,7 @@ export default [
...
@@ -127,6 +133,7 @@ export default [
"intervalType"
:
-
54395962.26549375
,
"intervalType"
:
-
54395962.26549375
,
"jumpUrl"
:
'https://www.baidu.com/index.html'
,
"jumpUrl"
:
'https://www.baidu.com/index.html'
,
"boolShowCompletePop"
:
false
,
"boolShowCompletePop"
:
false
,
"id"
:
7
,
},
},
],
],
"boolNeedChallengeCompletePop"
:
false
,
"boolNeedChallengeCompletePop"
:
false
,
...
...
src/pages/HomePage/Check/Check.tsx
View file @
ca86ee0b
...
@@ -39,7 +39,8 @@ class Check extends React.Component<any, any> {
...
@@ -39,7 +39,8 @@ class Check extends React.Component<any, any> {
}
}
// 按钮
// 按钮
handlegofinish
=
async
(
type
,
n
,
code
,
title
,
jumpUrl
)
=>
{
handlegofinish
=
async
(
type
,
n
,
code
,
title
,
jumpUrl
,
id
)
=>
{
handleLogClick
(
4
,
id
)
const
{
jfNum
=
0
,
qgNum
=
0
}
=
store
?.
baseInfo
||
{};
const
{
jfNum
=
0
,
qgNum
=
0
}
=
store
?.
baseInfo
||
{};
if
(
type
===
"xhqg"
)
{
if
(
type
===
"xhqg"
)
{
if
(
n
<=
qgNum
)
{
if
(
n
<=
qgNum
)
{
...
@@ -68,7 +69,7 @@ class Check extends React.Component<any, any> {
...
@@ -68,7 +69,7 @@ class Check extends React.Component<any, any> {
handlegosign
=
_asyncThrottle
((
hasChallengeDay
,
resignJf
,
resignQg
,
type
)
=>
{
handlegosign
=
_asyncThrottle
((
hasChallengeDay
,
resignJf
,
resignQg
,
type
)
=>
{
//
if (type === 'task') handleLogClick(5)
if
(
type
===
'task'
)
handleLogClick
(
5
)
// else if (type === 'calendar') handleLogClick(6)
// else if (type === 'calendar') handleLogClick(6)
ModalCtrl
.
showModal
(
Renewmodule
,
{
hasChallengeDay
,
resignJf
,
resignQg
});
ModalCtrl
.
showModal
(
Renewmodule
,
{
hasChallengeDay
,
resignJf
,
resignQg
});
});
});
...
@@ -154,21 +155,23 @@ class Check extends React.Component<any, any> {
...
@@ -154,21 +155,23 @@ class Check extends React.Component<any, any> {
{
Array
.
isArray
(
taskInfoList
)
&&
{
Array
.
isArray
(
taskInfoList
)
&&
taskInfoList
.
length
>
0
&&
taskInfoList
.
length
>
0
&&
taskInfoList
?.
map
((
v
,
i
)
=>
{
taskInfoList
?.
map
((
v
,
i
)
=>
{
const
{
title
,
subTitle
,
icon
,
code
,
completedSize
,
intervalLimitSize
,
jumpUrl
}
=
v
||
{};
const
{
title
,
subTitle
,
icon
,
code
,
completedSize
,
intervalLimitSize
,
jumpUrl
,
id
}
=
v
||
{};
// 获取按钮状态
// 获取按钮状态
const
renderActionButton
=
(
code
,
completedSize
,
intervalLimitSize
)
=>
{
const
renderActionButton
=
(
code
,
completedSize
,
intervalLimitSize
)
=>
{
// 先判断是否为续签状态
// 先判断是否为续签状态
if
(
boolNeedResign
)
{
if
(
boolNeedResign
)
{
return
<
Button
className=
"gosign md5"
onClick=
{
()
=>
this
.
handlegosign
(
hasChallengeDay
,
resignJf
,
resignQg
,
'task'
)
}
/>
handleLogExposure
(
5
)
return
<
Button
className=
"gosign"
onClick=
{
()
=>
this
.
handlegosign
(
hasChallengeDay
,
resignJf
,
resignQg
,
'task'
)
}
/>
}
else
if
(
completedSize
<
intervalLimitSize
)
{
}
else
if
(
completedSize
<
intervalLimitSize
)
{
handleLogExposure
(
4
,
id
)
switch
(
true
)
{
switch
(
true
)
{
// 签到
// 签到
case
code
.
startsWith
(
"sign"
):
{
case
code
.
startsWith
(
"sign"
):
{
return
(
return
(
<
Button
<
Button
className=
"gofinish"
className=
"gofinish"
onClick=
{
()
=>
this
.
handlegofinish
(
"sign"
,
''
,
code
,
title
,
''
)
}
onClick=
{
()
=>
this
.
handlegofinish
(
"sign"
,
''
,
code
,
title
,
''
,
id
)
}
/>
/>
);
);
}
}
...
@@ -179,7 +182,7 @@ class Check extends React.Component<any, any> {
...
@@ -179,7 +182,7 @@ class Check extends React.Component<any, any> {
return
(
return
(
<
Button
<
Button
className=
"gofinish"
className=
"gofinish"
onClick=
{
()
=>
this
.
handlegofinish
(
"xhqg"
,
n
,
code
,
title
,
''
)
}
onClick=
{
()
=>
this
.
handlegofinish
(
"xhqg"
,
n
,
code
,
title
,
''
,
id
)
}
/>
/>
);
);
}
}
...
@@ -190,7 +193,7 @@ class Check extends React.Component<any, any> {
...
@@ -190,7 +193,7 @@ class Check extends React.Component<any, any> {
return
(
return
(
<
Button
<
Button
className=
"gofinish"
className=
"gofinish"
onClick=
{
()
=>
this
.
handlegofinish
(
"xhjf"
,
n
,
code
,
title
,
''
)
}
onClick=
{
()
=>
this
.
handlegofinish
(
"xhjf"
,
n
,
code
,
title
,
''
,
id
)
}
/>
/>
);
);
}
}
...
@@ -199,7 +202,7 @@ class Check extends React.Component<any, any> {
...
@@ -199,7 +202,7 @@ class Check extends React.Component<any, any> {
return
(
return
(
<
Button
<
Button
className=
"gofinish"
className=
"gofinish"
onClick=
{
()
=>
this
.
handlegofinish
(
"yqzl"
,
''
,
code
,
title
,
''
)
}
onClick=
{
()
=>
this
.
handlegofinish
(
"yqzl"
,
''
,
code
,
title
,
''
,
id
)
}
/>
/>
)
)
}
}
...
@@ -208,7 +211,7 @@ class Check extends React.Component<any, any> {
...
@@ -208,7 +211,7 @@ class Check extends React.Component<any, any> {
return
(
return
(
<
Button
<
Button
className=
"gofinish"
className=
"gofinish"
onClick=
{
()
=>
this
.
handlegofinish
(
"yqzl_new"
,
''
,
code
,
title
,
''
)
}
onClick=
{
()
=>
this
.
handlegofinish
(
"yqzl_new"
,
''
,
code
,
title
,
''
,
id
)
}
/>
/>
)
)
}
}
...
@@ -219,7 +222,7 @@ class Check extends React.Component<any, any> {
...
@@ -219,7 +222,7 @@ class Check extends React.Component<any, any> {
return
(
return
(
<
Button
<
Button
className=
"gofinish"
className=
"gofinish"
onClick=
{
()
=>
this
.
handlegofinish
(
"scan"
,
''
,
code
,
title
,
jumpUrl
)
}
onClick=
{
()
=>
this
.
handlegofinish
(
"scan"
,
''
,
code
,
title
,
jumpUrl
,
id
)
}
/>
/>
);
);
}
}
...
@@ -228,7 +231,7 @@ class Check extends React.Component<any, any> {
...
@@ -228,7 +231,7 @@ class Check extends React.Component<any, any> {
return
(
return
(
<
Button
<
Button
className=
"gofinish"
className=
"gofinish"
onClick=
{
()
=>
this
.
handlegofinish
(
"browse"
,
''
,
code
,
title
,
jumpUrl
)
}
onClick=
{
()
=>
this
.
handlegofinish
(
"browse"
,
''
,
code
,
title
,
jumpUrl
,
id
)
}
/>
/>
);
);
}
}
...
...
src/store/store.ts
View file @
ca86ee0b
...
@@ -171,6 +171,7 @@ class Store {
...
@@ -171,6 +171,7 @@ class Store {
resignQg
:
number
;
resignQg
:
number
;
}
>
;
}
>
;
taskInfoList
?:
Array
<
{
taskInfoList
?:
Array
<
{
id
:
string
|
number
;
code
:
string
;
code
:
string
;
icon
:
string
;
icon
:
string
;
subTitle
:
string
;
subTitle
:
string
;
...
...
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