Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Z
ZheShangBank_TaoQuan_20240612
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
ZheShangBank_TaoQuan_20240612
Commits
31a52cdd
Commit
31a52cdd
authored
Jul 10, 2024
by
haiyoucuv
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
整理一下代码
parent
53049f77
Changes
8
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
195 additions
and
96 deletions
+195
-96
ChangeEquipPanel.ts
assets/Scripts/Panels/ChangeEquipPanel/ChangeEquipPanel.ts
+11
-2
TaskItem.ts
assets/Scripts/Panels/TaskPanel/TaskItem.ts
+6
-6
WebNet.ts
assets/Scripts/Utils/WebNet/WebNet.ts
+5
-4
Start.ts
assets/Start/Start.ts
+21
-0
index.html
build/web-mobile/index.html
+6
-21
equip.do.json
preview-template/mock/loop/equip.do.json
+5
-5
queryTasks.do.json
preview-template/mock/task_1/queryTasks.do.json
+140
-57
project.settings.json
project.settings.json
+1
-1
No files found.
assets/Scripts/Panels/ChangeEquipPanel/ChangeEquipPanel.ts
View file @
31a52cdd
...
...
@@ -15,6 +15,7 @@ import { CircleItem } from './CircleItem';
import
{
HandItem
}
from
'./HandItem'
;
import
{
showToast
}
from
'db://assets/Module/UIFast'
;
import
store
from
"../../../store/store"
;
import
{
toJS
}
from
"mobx"
;
const
{
ccclass
,
property
}
=
_decorator
;
...
...
@@ -297,7 +298,7 @@ export class ChangeEquipPanel extends Panel {
/** 任务栏渲染 */
taskRender
()
{
const
data
=
this
.
loopList
?.[
this
.
middleIndex
];
const
{
isUsed
,
title
,
completedSize
,
intervalLimitSize
,
loopType
}
=
data
||
{};
const
{
taskData
,
taskCode
,
isUsed
,
title
,
completedSize
,
intervalLimitSize
,
loopType
}
=
data
||
{};
/** 气泡渲染 */
if
(
loopType
==
"1"
)
{
this
.
bubble
.
active
=
false
;
...
...
@@ -306,6 +307,7 @@ export class ChangeEquipPanel extends Panel {
this
.
bubble
.
getChildByName
(
"Content"
).
getComponent
(
Label
).
string
=
`分数提升
${
BUFF
?.[
loopType
]
||
""
}
%
`
}
console.log(data);
if (!!isUsed) {
/** 已装备 */
this.mainBtnGrey.active = true;
...
...
@@ -324,7 +326,14 @@ export class ChangeEquipPanel extends Panel {
this.mainBtn.active = false;
this.taskBox.active = true;
this.taskBox.getChildByName("Title").getComponent(Label).string = strFormat(title, 22);
this.taskBox.getChildByName("Progress").getComponent(Label).string = `
完成
$
{
completedSize
}
/${intervalLimitSize}`
;
if (taskCode == "bank_2201") {
const descObj = taskData.desc ? JSON.parse(taskData.desc) : {};
const t = descObj?.progressAmount || 0;
this.taskBox.getChildByName("Progress").getComponent(Label).string = `
累计已提升金额:
$
{
t
}
元
`;
} else {
this.taskBox.getChildByName("Progress").getComponent(Label).string = `
完成
$
{
completedSize
}
/${intervalLimitSize}`
;
}
}
}
}
...
...
assets/Scripts/Panels/TaskPanel/TaskItem.ts
View file @
31a52cdd
...
...
@@ -51,16 +51,17 @@ export class TaskItem extends ScrollListItem {
if
(
code
?.
startsWith
(
"it"
))
{
this
.
title
.
string
=
strFormat
(
`
${
title
}
(
${
completedSize
}
/
${
intervalLimitSize
}
)`
,
24
);
this
.
subTitle
.
string
=
strFormat
(
subTitle
,
38
);
}
else
if
(
code
===
"bank_2202"
)
{
const
descObj
=
desc
?
JSON
.
parse
(
desc
)
:
{};
const
t
=
~~
((
descObj
?.
progressAmount
||
0
)
/
1000
);
this
.
title
.
string
=
strFormat
(
`
${
title
}
(
${
t
}
/10)`
,
30
);
const
t
=
descObj
?.
progressAmount
||
0
;
this
.
title
.
string
=
strFormat
(
`
${
title
}
(
${
~~
(
t
/
1000
)}
/10)`
,
30
);
this
.
subTitle
.
string
=
strFormat
(
`累计已提升金额:
${
t
}
元`
,
38
);
}
else
{
this
.
title
.
string
=
strFormat
(
title
,
24
);
this
.
subTitle
.
string
=
strFormat
(
subTitle
,
38
);
}
this
.
subTitle
.
string
=
strFormat
(
subTitle
,
38
);
const
btnSp
=
this
.
btn
.
getComponent
(
Sprite
);
const
{
timeStamp
}
=
getWebData
(
WebNetName
.
index
)
||
{};
...
...
@@ -79,9 +80,8 @@ export class TaskItem extends ScrollListItem {
btnSp
.
spriteFrame
=
this
.
doSf
;
}
else
{
if
(
code
===
"bank_2202"
)
{
// 特殊任务
const
descObj
=
desc
?
JSON
.
parse
(
desc
)
:
{};
// hasReceivedNum 特殊任务的已领奖次数
if
(
descObj
.
hasReceivedNum
>=
1
)
{
if
(
completedSize
>=
1
)
{
btnSp
.
spriteFrame
=
this
.
fightSf
;
}
else
{
btnSp
.
spriteFrame
=
this
.
doSf
;
...
...
assets/Scripts/Utils/WebNet/WebNet.ts
View file @
31a52cdd
...
...
@@ -6,10 +6,11 @@ import { resetBackCookie } from "../../../AppTool";
// import { isFromShare, newUser } from 'duiba-utils';
// let mergeData = {
// user_type: newUser ? '0' : '1',
// is_from_share: isFromShare ? '0' : '1',
// }
let
mergeData
=
{
// user_type: newUser ? '0' : '1',
// is_from_share: isFromShare ? '0' : '1',
// channel: getUrlParams('channel'),
}
export
const
DEFAULF_ERROR
=
'网络异常,请稍后重试'
;
//////////////星速台接口方法集成
...
...
assets/Start/Start.ts
View file @
31a52cdd
...
...
@@ -16,6 +16,7 @@ import { UIMgr } from "../Module/UIMgr";
import
{
changeScene
,
showToast
}
from
"db://assets/Module/UIFast"
;
import
{
HomeScene
}
from
"db://assets/Scripts/Scenes/HomeScene"
;
import
store
from
"../store/store"
;
import
{
appRequest
,
disableGestureReturn
}
from
"../AppTool"
;
const
{
ccclass
,
property
}
=
_decorator
;
...
...
@@ -33,6 +34,8 @@ export class Start extends Component {
@
property
(
ProgressBar
)
progressBar
:
ProgressBar
;
interval
=
null
;
onLoad
()
{
// game.frameRate = _FPS;
...
...
@@ -45,8 +48,26 @@ export class Start extends Component {
store
.
updateFrontVariable
();
disableGestureReturn
();
this
.
interval
=
setInterval
(()
=>
{
this
.
keepLive
();
},
1000
*
60
*
5
);
}
onDestroy
()
{
clearInterval
(
this
.
interval
);
}
keepLive
=
()
=>
{
appRequest
(
'/activityCommonService/duiBaKeepAlive'
,
{
method
:
'POST'
,
}).
then
(
res
=>
{
console
.
log
(
'keepLive'
,
res
);
});
};
async
start
()
{
await
this
.
preload
([
{
...
...
build/web-mobile/index.html
View file @
31a52cdd
...
...
@@ -3,22 +3,7 @@
<head>
<meta
charset=
"utf-8"
>
<title>
套圈挑战赛
</title>
<script
id=
"monitorjs"
src=
"//yun.duiba.com.cn/woodpecker/sdk/0.0.36/woodpecker_outer.js"
></script>
<script
id=
"registerMonitor"
>
// 烽火台注入前端监控脚本,请勿修改
try
{
woodpecker
.
setConfig
({
projectId
:
"pc9c1ee11"
,
developer
:
[
"fa17c4667c62b5ba014f382c0802a462"
],
});
}
catch
(
e
)
{
console
.
error
(
e
);
}
</script>
<title>
套圈挑战赛
</title>
<!--http://www.html5rocks.com/en/mobile/mobifying/-->
<meta
name=
"viewport"
...
...
@@ -54,7 +39,7 @@
<script
src=
"//yun.duiba.com.cn/polaris/SVGA.Lite.v2.1.1.d3a67cbc13c591c53c6f87ab34c57ce387010374.js"
crossorigin=
"anonymous"
></script>
<script
src=
"//yun.duiba.com.cn/aurora/assets/2403d1edf2acd15b179306b6ddaa5f0967d78a8f.js"
></script>
<link
rel=
"stylesheet"
type=
"text/css"
href=
"//yun.duiba.com.cn/db_games/ccc_game/template3d/1720
404223993
/style.css"
/>
<link
rel=
"stylesheet"
type=
"text/css"
href=
"//yun.duiba.com.cn/db_games/ccc_game/template3d/1720
511787175
/style.css"
/>
<style>
.sui-captcha
{
...
...
@@ -116,16 +101,16 @@
</script>
<!-- Polyfills bundle. -->
<script
src=
"//yun.duiba.com.cn/db_games/ccc_game/template3d/1720
404223993
/src/polyfills.bundle.js"
charset=
"utf-8"
></script>
<script
src=
"//yun.duiba.com.cn/db_games/ccc_game/template3d/1720
511787175
/src/polyfills.bundle.js"
charset=
"utf-8"
></script>
<!-- SystemJS support. -->
<script
src=
"//yun.duiba.com.cn/db_games/ccc_game/template3d/1720
404223993
/src/system.bundle.js"
charset=
"utf-8"
></script>
<script
src=
"//yun.duiba.com.cn/db_games/ccc_game/template3d/1720
511787175
/src/system.bundle.js"
charset=
"utf-8"
></script>
<!-- Import map -->
<script
src=
"//yun.duiba.com.cn/db_games/ccc_game/template3d/1720
404223993
/src/import-map.json"
type=
"systemjs-importmap"
charset=
"utf-8"
></script>
<script
src=
"//yun.duiba.com.cn/db_games/ccc_game/template3d/1720
511787175
/src/import-map.json"
type=
"systemjs-importmap"
charset=
"utf-8"
></script>
<script>
System
.
import
(
'//yun.duiba.com.cn/db_games/ccc_game/template3d/1720
404223993
/index.js'
).
catch
(
function
(
err
)
{
System
.
import
(
'//yun.duiba.com.cn/db_games/ccc_game/template3d/1720
511787175
/index.js'
).
catch
(
function
(
err
)
{
console
.
error
(
err
);
})
</script>
...
...
preview-template/mock/loop/equip.do.json
View file @
31a52cdd
{
"code"
:
null
,
"data"
:
{
"handType"
:
"
1
"
,
"handType"
:
"
3
"
,
"taskInfo"
:
[
{
"isUsed"
:
false
,
"loopType"
:
2
,
"taskCode"
:
"join_
5
"
"taskCode"
:
"join_
3
"
},
{
"isUsed"
:
false
,
...
...
@@ -16,12 +16,12 @@
{
"isUsed"
:
false
,
"loopType"
:
4
,
"taskCode"
:
"score_
10
00"
"taskCode"
:
"score_
3
00"
},
{
"isUsed"
:
false
,
"loopType"
:
5
,
"taskCode"
:
"
score_8000
"
"taskCode"
:
"
bank_2201
"
},
{
"isUsed"
:
true
,
...
...
@@ -32,5 +32,5 @@
},
"message"
:
null
,
"success"
:
true
,
"timeStamp"
:
17
18776874488
"timeStamp"
:
17
20598101102
}
\ No newline at end of file
preview-template/mock/task_1/queryTasks.do.json
View file @
31a52cdd
...
...
@@ -3,43 +3,6 @@
"data"
:
{
"endTimestamp"
:
1785495731000
,
"item"
:
[
{
"buttonText"
:
null
,
"code"
:
"bank_2202"
,
"completedSize"
:
0
,
"desc"
:
"{
\"
taskType
\"
:2,
\"
hasReceivedNum
\"
:10,
\"
progressAmount
\"
:10000}"
,
"extra"
:
null
,
"icon"
:
null
,
"id"
:
"savjpxbs"
,
"index"
:
null
,
"indexes"
:
null
,
"intervalLimitSize"
:
1
,
"intervalType"
:
0
,
"jumpUrl"
:
"/"
,
"options"
:
[
{
"degree"
:
null
,
"icon"
:
null
,
"icon2"
:
null
,
"id"
:
"sp_challenge_times"
,
"index"
:
null
,
"name"
:
"挑战次数"
,
"prizeId"
:
"sp_challenge_times"
,
"prizeType"
:
null
,
"refId"
:
null
,
"refType"
:
null
,
"sendCount"
:
3
}
],
"playwayId"
:
"task_1"
,
"prizePendingCode"
:
null
,
"prizePendingCodeList"
:
null
,
"ruleId"
:
"spPrize@sp_challenge_times@3"
,
"sendPrize"
:
null
,
"subTitle"
:
"/"
,
"taskStatus"
:
0
,
"title"
:
"资产每提升1000元得次数*1"
},
{
"buttonText"
:
"请邀请好友给你助力"
,
"code"
:
"it"
,
...
...
@@ -179,7 +142,7 @@
"id"
:
"jnu13vqb"
,
"index"
:
null
,
"indexes"
:
null
,
"intervalLimitSize"
:
10
,
"intervalLimitSize"
:
10
0
,
"intervalType"
:
1
,
"jumpUrl"
:
"https://www.baidu.com1"
,
"options"
:
[
...
...
@@ -187,20 +150,59 @@
"degree"
:
null
,
"icon"
:
null
,
"icon2"
:
null
,
"id"
:
"sp_challenge_times"
,
"index"
:
null
,
"name"
:
"挑战次数"
,
"prizeId"
:
"sp_challenge_times"
,
"prizeType"
:
null
,
"id"
:
"of05a780e"
,
"index"
:
1
,
"name"
:
"88积分测试数据"
,
"prizeId"
:
"third_ZHXYKHQ240802"
,
"prizeType"
:
1
,
"refId"
:
null
,
"refType"
:
null
,
"sendCount"
:
1
},
{
"degree"
:
null
,
"icon"
:
null
,
"icon2"
:
null
,
"id"
:
"obc9d8d93"
,
"index"
:
2
,
"name"
:
"立减金测试"
,
"prizeId"
:
"third_ZHXYKHQ240801"
,
"prizeType"
:
1
,
"refId"
:
null
,
"refType"
:
null
,
"sendCount"
:
10
},
{
"degree"
:
null
,
"icon"
:
"//yun.dui88.com/images/202211/vo9167fvxo.png"
,
"icon2"
:
null
,
"id"
:
"o02dcd829"
,
"index"
:
3
,
"name"
:
"非首次-漫漫测试实物-星速台"
,
"prizeId"
:
"sss_3"
,
"prizeType"
:
2
,
"refId"
:
"42731"
,
"refType"
:
"object"
,
"sendCount"
:
1
},
{
"degree"
:
null
,
"icon"
:
"//yun.duiba.com.cn/db-m/app/turntable/circle/images/prize/谢谢参与_6311f27.png"
,
"icon2"
:
null
,
"id"
:
"thanks"
,
"index"
:
4
,
"name"
:
"谢谢参与"
,
"prizeId"
:
"thanks"
,
"prizeType"
:
0
,
"refId"
:
null
,
"refType"
:
null
,
"sendCount"
:
1
}
],
"playwayId"
:
"task_1"
,
"prizePendingCode"
:
null
,
"prizePendingCodeList"
:
null
,
"ruleId"
:
"
spPrize@sp_challenge_times@10
"
,
"ruleId"
:
"
ru_loop
"
,
"sendPrize"
:
null
,
"subTitle"
:
"百度1副标题"
,
"taskStatus"
:
0
,
...
...
@@ -218,7 +220,7 @@
"indexes"
:
null
,
"intervalLimitSize"
:
1
,
"intervalType"
:
4
,
"jumpUrl"
:
"https://
e.czbank.com/weixinHTML/creditCardApply/creditCardFullApplyETF.html?creditPreFlag=1
"
,
"jumpUrl"
:
"https://
mobapp.czbank.com/life/mobile_recharge.html
"
,
"options"
:
[
{
"degree"
:
null
,
...
...
@@ -253,19 +255,58 @@
"id"
:
"cvzdcxpe"
,
"index"
:
null
,
"indexes"
:
null
,
"intervalLimitSize"
:
1
,
"intervalLimitSize"
:
1
0
,
"intervalType"
:
4
,
"jumpUrl"
:
"https://mobapp.czbank.com/
setUp/loginMana
ge.html"
,
"jumpUrl"
:
"https://mobapp.czbank.com/
life/mobile_rechar
ge.html"
,
"options"
:
[
{
"degree"
:
null
,
"icon"
:
null
,
"icon2"
:
null
,
"id"
:
"sp_challenge_times"
,
"index"
:
null
,
"name"
:
"挑战次数"
,
"prizeId"
:
"sp_challenge_times"
,
"prizeType"
:
null
,
"id"
:
"of05a780e"
,
"index"
:
1
,
"name"
:
"88积分测试数据"
,
"prizeId"
:
"third_ZHXYKHQ240802"
,
"prizeType"
:
1
,
"refId"
:
null
,
"refType"
:
null
,
"sendCount"
:
1
},
{
"degree"
:
null
,
"icon"
:
null
,
"icon2"
:
null
,
"id"
:
"obc9d8d93"
,
"index"
:
2
,
"name"
:
"立减金测试"
,
"prizeId"
:
"third_ZHXYKHQ240801"
,
"prizeType"
:
1
,
"refId"
:
null
,
"refType"
:
null
,
"sendCount"
:
10
},
{
"degree"
:
null
,
"icon"
:
"//yun.dui88.com/images/202211/vo9167fvxo.png"
,
"icon2"
:
null
,
"id"
:
"o02dcd829"
,
"index"
:
3
,
"name"
:
"非首次-漫漫测试实物-星速台"
,
"prizeId"
:
"sss_3"
,
"prizeType"
:
2
,
"refId"
:
"42731"
,
"refType"
:
"object"
,
"sendCount"
:
1
},
{
"degree"
:
null
,
"icon"
:
"//yun.duiba.com.cn/db-m/app/turntable/circle/images/prize/谢谢参与_6311f27.png"
,
"icon2"
:
null
,
"id"
:
"thanks"
,
"index"
:
4
,
"name"
:
"谢谢参与"
,
"prizeId"
:
"thanks"
,
"prizeType"
:
0
,
"refId"
:
null
,
"refType"
:
null
,
"sendCount"
:
1
...
...
@@ -274,7 +315,7 @@
"playwayId"
:
"task_1"
,
"prizePendingCode"
:
null
,
"prizePendingCodeList"
:
null
,
"ruleId"
:
"
spPrize@sp_challenge_times@1
"
,
"ruleId"
:
"
ru_loop
"
,
"sendPrize"
:
null
,
"subTitle"
:
"/"
,
"taskStatus"
:
0
,
...
...
@@ -321,7 +362,7 @@
"buttonText"
:
null
,
"code"
:
"bank_2201"
,
"completedSize"
:
0
,
"desc"
:
"{
\"
taskType
\"
:1}"
,
"desc"
:
"{
\"
taskType
\"
:1
,
\"
progressAmount
\"
:
\"
1
\"
}"
,
"extra"
:
null
,
"icon"
:
null
,
"id"
:
"oywi1c5s"
,
...
...
@@ -338,13 +379,55 @@
"sendPrize"
:
null
,
"subTitle"
:
"/"
,
"taskStatus"
:
0
,
"title"
:
"资产提升10000元任务"
"title"
:
"【圈圈】资产提升10000元任务"
},
{
"buttonText"
:
null
,
"code"
:
"bank_2202"
,
"completedSize"
:
1
,
"desc"
:
"{
\"
taskType
\"
:2,
\"
progressAmount
\"
:
\"
1001
\"
}"
,
"extra"
:
null
,
"icon"
:
null
,
"id"
:
"oumzgwqz"
,
"index"
:
null
,
"indexes"
:
null
,
"intervalLimitSize"
:
10
,
"intervalType"
:
4
,
"jumpUrl"
:
"/"
,
"options"
:
[
{
"degree"
:
null
,
"icon"
:
null
,
"icon2"
:
null
,
"id"
:
"sp_challenge_times"
,
"index"
:
null
,
"name"
:
"挑战次数"
,
"prizeId"
:
"sp_challenge_times"
,
"prizeType"
:
null
,
"refId"
:
null
,
"refType"
:
null
,
"sendCount"
:
3
}
],
"playwayId"
:
"task_1"
,
"prizePendingCode"
:
""
,
"prizePendingCodeList"
:
[
{
"code"
:
null
,
"index"
:
1
}
],
"ruleId"
:
"spPrize@sp_challenge_times@3"
,
"sendPrize"
:
true
,
"subTitle"
:
"/"
,
"taskStatus"
:
0
,
"title"
:
"资产每提升1000元得次数*1"
}
],
"startTimestamp"
:
1718190131000
,
"timestamp"
:
17
19490008971
"timestamp"
:
17
20597476609
},
"message"
:
null
,
"success"
:
true
,
"timeStamp"
:
17
19490009176
"timeStamp"
:
17
20597476795
}
\ No newline at end of file
project.settings.json
View file @
31a52cdd
{
"proSetting"
:{
"projectxIDs"
:{
"devId"
:[],
"testId"
:[{
"label"
:
"test"
,
"value"
:
"pa7410987"
}],
"prodId"
:[{
"label"
:
"prodTest"
,
"value"
:
"pc9c1ee11"
}]},
"skinVariables"
:[],
"mockSetting"
:{
"projectId"
:
""
,
"pageId"
:
""
}},
"envSetting"
:{},
"psdSetting"
:{
"psdFSSetting"
:
true
,
"psdCenterSetting"
:
true
}}
{
"proSetting"
:{
"projectxIDs"
:{
"devId"
:[],
"testId"
:[{
"label"
:
"test"
,
"value"
:
"pa7410987"
}],
"prodId"
:[{
"label"
:
"prodTest"
,
"value"
:
"pc9c1ee11"
}
,{
"label"
:
"prod"
,
"value"
:
"p7bdf2f84"
}
]},
"skinVariables"
:[],
"mockSetting"
:{
"projectId"
:
""
,
"pageId"
:
""
}},
"envSetting"
:{},
"psdSetting"
:{
"psdFSSetting"
:
true
,
"psdCenterSetting"
:
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