Commit f37a6473 authored by liujiangnan's avatar liujiangnan

feat

parent 94699344
...@@ -10,11 +10,17 @@ const levels = { ...@@ -10,11 +10,17 @@ const levels = {
@ccclass @ccclass
export default class NewClass extends cc.Component { export default class NewClass extends cc.Component {
orgId = 507;
start() { start() {
} }
async loadSyllabusTree() { async loadSyllabusTree() {
const res: any = await asyncCallNetworkApiGet("/api/syllabus/v1/list", { orgid: 507 }); const middleLayer = cc.find('middleLayer');
if (middleLayer) {
this.orgId = middleLayer.getComponent('middleLayer').ORG_ID || 507;
}
const res: any = await asyncCallNetworkApiGet("/api/syllabus/v1/list", { orgid: this.orgId });
const rows = JSON.parse(res).rows; const rows = JSON.parse(res).rows;
for (let i = 0; i < rows.length; i++) { for (let i = 0; i < rows.length; i++) {
const row = rows[i]; const row = rows[i];
......
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