Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
N
NJ_YouLeChang
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
template admin
NJ_YouLeChang
Commits
64e3c805
Commit
64e3c805
authored
Jun 08, 2022
by
liujiangnan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 跳转到上次学习
parent
424be25b
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
2 deletions
+15
-2
NJ_YouLeChang.ts
assets/NJ_YouLeChang/scene/NJ_YouLeChang.ts
+15
-2
No files found.
assets/NJ_YouLeChang/scene/NJ_YouLeChang.ts
View file @
64e3c805
...
...
@@ -137,13 +137,26 @@ export default class SceneComponent extends MyCocosSceneComponent {
jumpToBundle
(
'
NJ_menu
'
);
});
const
btn_last
=
cc
.
find
(
'
Canvas/bg_ground/bg_bottom/btn_last
'
);
buttonOnClick
(
btn_last
,
()
=>
{
buttonOnClick
(
btn_last
,
async
()
=>
{
const
kidInfo
=
await
middleLayerComponent
.
getUserInfo
();
if
(
!
kidInfo
)
{
return
;
}
if
(
!
kidInfo
.
lastgameinfo
)
{
middleLayerComponent
.
showTips
(
"
还未开始学习!
"
);
return
;
}
const
lastgameinfo
=
JSON
.
parse
(
kidInfo
.
lastgameinfo
);
middleLayerComponent
.
reSetData
(
lastgameinfo
);
const
syllabusId
=
kidInfo
.
last_syllabus
;
const
coursewareId
=
kidInfo
.
last_courseware
;
middleLayerComponent
.
loadOnlineCourseWare
(
syllabusId
,
false
,
coursewareId
);
});
const
btn_center
=
cc
.
find
(
'
Canvas/bg_ground/bg_bottom/btn_center
'
);
buttonOnClick
(
btn_center
,
()
=>
{
jumpToBundle
(
'
NJ_usercenter
'
);
});
const
avatar_border
=
cc
.
find
(
'
Canvas/avatar_border
'
);
buttonOnClick
(
avatar_border
,
()
=>
{
cc
.
find
(
'
Canvas/userInfo
'
).
active
=
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