Commit dc83688f authored by liujiangnan's avatar liujiangnan

feat: 这里不提示购买

parent 8ade9f79
import { asyncDelay, onHomeworkFinish, asyncCallNetworkApiGet, asyncCallNetworkApiPost, buttonOnClick, jumpToCourseWare } from "../script/util";
import { asyncCallNetworkApiGet, buttonOnClick, jumpToCourseWare } from "../script/util";
import { MyCocosSceneComponent } from "../script/MyCocosSceneComponent";
const { ccclass, property } = cc._decorator;
......@@ -91,14 +91,14 @@ export default class SceneComponent extends MyCocosSceneComponent {
bookNode.attr({syllabus_id: book.id, pid: book.pid});
buttonOnClick(bookNode, async () => {
const kidInfo = await this.getKidInfo();
const activeLevels = kidInfo ? kidInfo.active_levels : [];
const activeItem = activeLevels.find(item => item.syllabus_id == data.id);
if (middleLayer && !activeItem) {
// 弹出激活码
middleLayer.getComponent('middleLayer').showActiveWindow();
return;
}
// const kidInfo = await this.getKidInfo();
// const activeLevels = kidInfo ? kidInfo.active_levels : [];
// const activeItem = activeLevels.find(item => item.syllabus_id == data.id);
// if (middleLayer && !activeItem) {
// // 弹出激活码
// middleLayer.getComponent('middleLayer').showActiveWindow();
// return;
// }
if (middleLayer) {
const middleLayerComponent = middleLayer.getComponent('middleLayer');
const row = book.children.find(row => row.name == '索引页');
......
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