Commit 3a228dc9 authored by 李维's avatar 李维

过滤单元页关卡状态的confgItem

parent 7ccbfed0
......@@ -46,7 +46,8 @@ export default class MissionPageClass extends PageComponentBaseClass {
userInfo = null
nameLblStr = "";
handleClickBackBtn() {
async handleClickBackBtn() {
await this.hideTeacherAvatar();
const vc = this.Viewer.getComponent("PageViewer");
vc.toView({
name: "UnitPage",
......@@ -87,7 +88,7 @@ export default class MissionPageClass extends PageComponentBaseClass {
this.headNode.getComponent(cc.Sprite).spriteFrame = spr.spriteFrame;
spr.node.destroy()
setSprNodeMaxLen(this.headNode, this.headNode.width, this.headNode.height);
this.showHeaderAnimation()
this.showTeacherAvatar()
});
}
......@@ -351,7 +352,7 @@ export default class MissionPageClass extends PageComponentBaseClass {
}
}
showHeaderAnimation() {
showTeacherAvatar() {
const width = cc.find("/Canvas").width / 2;
this.headNode.x = -width / 2 - this.headNode.parent.width;
this.headNode.active = true;
......@@ -360,6 +361,18 @@ export default class MissionPageClass extends PageComponentBaseClass {
}, { easing: "cubicOut" }).start()
}
hideTeacherAvatar() {
return new Promise(resovle => {
const width = cc.find("/Canvas").width / 2;
cc.tween(this.headNode).to(0.3, {
x: -width / 2 - this.headNode.parent.width
}, { easing: "cubicOut" }).call(()=>{
this.headNode.active = false;
resovle(true)
}).start()
})
}
onClickOpenLessonPreview() {
this.LessonPreview.active = true
this.LessonPreview.getComponent("LessonPreview").setData(this.getConfigData())
......
......@@ -291,6 +291,9 @@ export default class UnitPageClass extends PageComponentBaseClass {
pointBase.opacity = 0;
for (let k = 0; k < subData.children.length; k++) {
const clsData = subData.children[k];
if (clsData.name == "config") {
continue
}
const pointNode = cc.instantiate(pointBase);
pointNode.opacity = 255;
if (clsData) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment