mirror of
https://github.com/codeninjasllc/codecombat.git
synced 2024-11-27 17:45:40 -05:00
Add shareable to admin classroom levels page
This commit is contained in:
parent
9962ff83d4
commit
9ad7376edf
1 changed files with 17 additions and 6 deletions
|
@ -4,17 +4,26 @@ extends /templates/base
|
||||||
|
|
||||||
block content
|
block content
|
||||||
|
|
||||||
|
h3 Classroom Levels
|
||||||
if !me.isAdmin()
|
if !me.isAdmin()
|
||||||
div You must be logged in as an admin to view this page.
|
div You must be logged in as an admin to view this page.
|
||||||
else
|
else
|
||||||
p
|
p
|
||||||
- var levelsTotal = 0;
|
- var levelsTotal = 0;
|
||||||
|
table.table.table-striped.table-condensed
|
||||||
|
tr
|
||||||
|
th Levels
|
||||||
|
th Course
|
||||||
each course in view.courses.models
|
each course in view.courses.models
|
||||||
- var campaign = view.campaigns.get(course.get('campaignID'));
|
- var campaign = view.campaigns.get(course.get('campaignID'));
|
||||||
- var levels = campaign.getLevels().models;
|
- var levels = campaign.getLevels().models;
|
||||||
- levelsTotal += levels.length;
|
- levelsTotal += levels.length;
|
||||||
div #{levels.length} #{course.get('name')}
|
tr
|
||||||
div #{levelsTotal} levels total
|
td= levels.length
|
||||||
|
td= course.get('name')
|
||||||
|
tr
|
||||||
|
td= levelsTotal
|
||||||
|
td All
|
||||||
each course in view.courses.models
|
each course in view.courses.models
|
||||||
- var campaign = view.campaigns.get(course.get('campaignID'));
|
- var campaign = view.campaigns.get(course.get('campaignID'));
|
||||||
- var levels = campaign.getLevels().models;
|
- var levels = campaign.getLevels().models;
|
||||||
|
@ -29,6 +38,7 @@ block content
|
||||||
th Type
|
th Type
|
||||||
th Practice
|
th Practice
|
||||||
th Practice Threshold (m)
|
th Practice Threshold (m)
|
||||||
|
th Shareable
|
||||||
each level, levelIndex in levels
|
each level, levelIndex in levels
|
||||||
- var levelNumber = campaign.getLevelNumber(level.get('original'), levelIndex + 1)
|
- var levelNumber = campaign.getLevelNumber(level.get('original'), levelIndex + 1)
|
||||||
tr
|
tr
|
||||||
|
@ -37,3 +47,4 @@ block content
|
||||||
td= level.get('type')
|
td= level.get('type')
|
||||||
td= level.get('practice')
|
td= level.get('practice')
|
||||||
td= level.get('practiceThresholdMinutes')
|
td= level.get('practiceThresholdMinutes')
|
||||||
|
td= level.get('shareable')
|
||||||
|
|
Loading…
Reference in a new issue