2015-09-03 14:04:40 -04:00
|
|
|
|
extends /templates/base
|
|
|
|
|
|
|
|
|
|
block content
|
|
|
|
|
|
2015-09-23 19:27:45 -04:00
|
|
|
|
if (noCourseInstance || noCourseInstanceSelected) && course
|
|
|
|
|
h1= course.get('name')
|
|
|
|
|
if noCourseInstance
|
2015-09-25 15:51:51 -04:00
|
|
|
|
p(data-i18n="courses.not_enrolled")
|
2015-09-23 19:27:45 -04:00
|
|
|
|
p
|
2015-09-25 15:51:51 -04:00
|
|
|
|
span.spr(data-i18n="courses.visit_pref")
|
|
|
|
|
a(href="/courses", data-i18n="courses.courses")
|
|
|
|
|
span.spl(data-i18n="courses.visit_suf")
|
2015-09-23 19:27:45 -04:00
|
|
|
|
else if noCourseInstanceSelected
|
2015-09-25 15:51:51 -04:00
|
|
|
|
p(data-i18n="courses.select_class")
|
2015-09-23 19:27:45 -04:00
|
|
|
|
.container-fluid
|
|
|
|
|
.row
|
|
|
|
|
.col-md-6
|
|
|
|
|
select.form-control.select-instance
|
|
|
|
|
each courseInstance in courseInstances
|
|
|
|
|
if courseInstance.get('name')
|
|
|
|
|
option(value="#{courseInstance.id}")= courseInstance.get('name')
|
|
|
|
|
else
|
2015-09-25 15:51:51 -04:00
|
|
|
|
option(value="#{courseInstance.id}", data-i18n="courses.unnamed")
|
2015-09-23 19:27:45 -04:00
|
|
|
|
.col-md-6
|
2015-09-25 15:51:51 -04:00
|
|
|
|
button.btn.btn-success.btn-select-instance(data-i18n="courses.select")
|
2015-09-13 01:01:59 -04:00
|
|
|
|
else if !course || !courseInstance
|
2015-09-25 15:51:51 -04:00
|
|
|
|
h1(data-i18n="common.loading") Loading...
|
2015-09-03 14:04:40 -04:00
|
|
|
|
else
|
2015-12-01 20:23:33 -05:00
|
|
|
|
p
|
|
|
|
|
// TODO: format this text all good and stuff
|
|
|
|
|
strong
|
2015-11-09 21:08:39 -05:00
|
|
|
|
if courseInstance.get('name')
|
2015-12-01 20:23:33 -05:00
|
|
|
|
span= courseInstance.get('name')
|
2015-11-09 21:08:39 -05:00
|
|
|
|
else if view.classroom.get('name')
|
2015-12-01 20:23:33 -05:00
|
|
|
|
span= view.classroom.get('name')
|
2015-11-09 21:08:39 -05:00
|
|
|
|
else
|
|
|
|
|
span(data-i18n='courses.unnamed_class')
|
2015-12-01 20:23:33 -05:00
|
|
|
|
|
|
|
|
|
if !view.owner.isNew() && view.getOwnerName()
|
|
|
|
|
span.spl.spr - Teacher:
|
2015-12-02 12:52:52 -05:00
|
|
|
|
//a(href="/user/#{view.owner.id}") // Don't link to profiles until we improve them
|
|
|
|
|
span
|
2015-10-27 20:47:48 -04:00
|
|
|
|
strong= view.getOwnerName()
|
2015-09-03 14:04:40 -04:00
|
|
|
|
|
2015-12-01 20:23:33 -05:00
|
|
|
|
h1
|
|
|
|
|
| #{course.get('name')}
|
|
|
|
|
if view.courseComplete
|
|
|
|
|
span.spl - Complete!
|
|
|
|
|
|
2015-09-03 14:04:40 -04:00
|
|
|
|
p
|
2015-09-13 01:01:59 -04:00
|
|
|
|
if courseInstance.get('description')
|
|
|
|
|
each line in courseInstance.get('description').split('\n')
|
|
|
|
|
div= line
|
2015-12-02 12:52:52 -05:00
|
|
|
|
|
|
|
|
|
if view.courseComplete && !view.teacherMode
|
|
|
|
|
.jumbotron
|
|
|
|
|
.row
|
|
|
|
|
if view.singlePlayerMode && !me.isAnonymous()
|
|
|
|
|
.col-md-3
|
|
|
|
|
.col-md-6
|
|
|
|
|
a.btn.btn-lg.btn-success(href="/play")
|
|
|
|
|
h1 Play the Campaign
|
|
|
|
|
p You’re ready to take the next step! Explore hundreds of challenging levels, learn advanced programming skills, and compete in multiplayer arenas!
|
|
|
|
|
.col-md-3
|
|
|
|
|
else if view.singlePlayerMode && me.isAnonymous()
|
|
|
|
|
.col-md-6
|
|
|
|
|
a.btn.btn-lg.btn-success.signup-button
|
|
|
|
|
h1 Create an Account
|
|
|
|
|
p Sign up for a FREE CodeCombat account and gain access to more levels, more programming skills, and more fun!
|
|
|
|
|
.col-md-6
|
|
|
|
|
a.btn.btn-lg.btn-success(href="/play")
|
|
|
|
|
h1 Preview Campaign
|
|
|
|
|
p Take a sneak peek at all that CodeCombat has to offer before signing up for your FREE account.
|
|
|
|
|
else if !view.singlePlayerMode
|
|
|
|
|
.col-md-6
|
|
|
|
|
if view.arenaLevel
|
|
|
|
|
a.btn.btn-lg.btn-success.btn-play-level(data-level-slug=view.arenaLevel.slug, data-level-id=view.arenaLevel.original)
|
|
|
|
|
h1
|
|
|
|
|
span Arena
|
|
|
|
|
| :
|
|
|
|
|
span.spl= view.arenaLevel.name
|
|
|
|
|
p= view.arenaLevel.description.replace(/!\[.*?\)/, '')
|
|
|
|
|
else
|
|
|
|
|
a.btn.btn-lg.btn-success.disabled
|
|
|
|
|
h1 Arena Coming Soon
|
|
|
|
|
p We are working on a multiplayer arena for classrooms at the end of #{course.get('name')}.
|
|
|
|
|
.col-md-6
|
|
|
|
|
if view.nextCourseInstance
|
|
|
|
|
a.btn.btn-lg.btn-success(href="/courses/#{view.nextCourse.id}/#{view.nextCourseInstance.id}")
|
|
|
|
|
h1= view.nextCourse.get('name')
|
|
|
|
|
p= view.nextCourse.get('description')
|
|
|
|
|
else if view.nextCourse
|
|
|
|
|
a.btn.btn-lg.btn-success.disabled
|
|
|
|
|
h1= view.nextCourse.get('name')
|
|
|
|
|
p
|
|
|
|
|
em NOT ENROLLED
|
|
|
|
|
p Ask your teacher to enroll you in the next course.
|
|
|
|
|
else
|
|
|
|
|
a.btn.btn-lg.btn-success(disabled=!view.nextCourse ? "disabled" : "")
|
|
|
|
|
h1 Next Course
|
|
|
|
|
p
|
|
|
|
|
em COMING SOON
|
|
|
|
|
p We are hard at work making more courses for you!
|
|
|
|
|
|
2015-12-01 17:15:18 -05:00
|
|
|
|
if !me.isAnonymous()
|
|
|
|
|
div.well.well-sm(role='tabpanel')
|
|
|
|
|
ul.nav.nav-pills(role='tablist')
|
2015-12-02 12:52:52 -05:00
|
|
|
|
if view.teacherMode
|
2015-12-01 17:15:18 -05:00
|
|
|
|
li.active(role='presentation')
|
|
|
|
|
a(href='#progress', aria-controls='progress', role='tab', data-toggle='tab', data-i18n="courses.progress")
|
|
|
|
|
li(role='presentation')
|
|
|
|
|
a(href='#levels', aria-controls='levels', role='tab', data-toggle='tab', data-i18n="nav.play")
|
|
|
|
|
else
|
|
|
|
|
li.active(role='presentation')
|
|
|
|
|
a(href='#levels', aria-controls='levels', role='tab', data-toggle='tab', data-i18n="nav.play")
|
|
|
|
|
li(role='presentation')
|
|
|
|
|
a(href='#progress', aria-controls='progress', role='tab', data-toggle='tab', data-i18n="courses.progress")
|
2015-09-13 01:01:59 -04:00
|
|
|
|
.tab-content
|
2015-12-02 12:52:52 -05:00
|
|
|
|
if view.teacherMode
|
2015-10-07 18:18:09 -04:00
|
|
|
|
.tab-pane.active#progress(role='tabpanel')
|
|
|
|
|
+progress-tab
|
|
|
|
|
.tab-pane#levels(role='tabpanel')
|
|
|
|
|
+levels-tab
|
|
|
|
|
else
|
|
|
|
|
.tab-pane.active#levels(role='tabpanel')
|
|
|
|
|
+levels-tab
|
|
|
|
|
.tab-pane#progress(role='tabpanel')
|
|
|
|
|
+progress-tab
|
2015-09-13 01:01:59 -04:00
|
|
|
|
|
|
|
|
|
mixin progress-tab
|
|
|
|
|
.container-fluid.progress-summary-container
|
|
|
|
|
.row
|
|
|
|
|
.col-md-6
|
|
|
|
|
+progress-summary-stats
|
|
|
|
|
.col-md-6
|
|
|
|
|
+progress-summary-concepts
|
|
|
|
|
+progress-members
|
|
|
|
|
|
|
|
|
|
mixin progress-summary-stats
|
2015-09-25 15:51:51 -04:00
|
|
|
|
h3(data-i18n="courses.stats")
|
2015-09-13 01:01:59 -04:00
|
|
|
|
table.progress-stats-container
|
|
|
|
|
tr
|
2015-09-25 15:51:51 -04:00
|
|
|
|
td(data-i18n="courses.total_students")
|
2015-09-13 01:01:59 -04:00
|
|
|
|
td
|
|
|
|
|
if courseInstance
|
|
|
|
|
div #{courseInstance.get('members').length}
|
2015-09-24 10:28:43 -04:00
|
|
|
|
if instanceStats
|
|
|
|
|
tr
|
2015-09-25 15:51:51 -04:00
|
|
|
|
td(data-i18n="courses.average_time")
|
2015-09-24 10:28:43 -04:00
|
|
|
|
if instanceStats.averageLevelPlaytime > 0
|
|
|
|
|
td= moment.duration(instanceStats.averageLevelPlaytime, "seconds").humanize()
|
|
|
|
|
else
|
|
|
|
|
td 0
|
|
|
|
|
tr
|
2015-09-25 15:51:51 -04:00
|
|
|
|
td(data-i18n="courses.total_time")
|
2015-09-24 10:28:43 -04:00
|
|
|
|
if instanceStats.totalPlayTime > 0
|
|
|
|
|
td= moment.duration(instanceStats.totalPlayTime, "seconds").humanize()
|
|
|
|
|
else
|
|
|
|
|
td 0
|
|
|
|
|
tr
|
2015-09-25 15:51:51 -04:00
|
|
|
|
td(data-i18n="courses.average_levels")
|
2015-09-24 10:28:43 -04:00
|
|
|
|
td #{instanceStats.averageLevelsCompleted.toFixed(2)}
|
|
|
|
|
tr
|
2015-09-25 15:51:51 -04:00
|
|
|
|
td(data-i18n="courses.total_levels")
|
2015-09-24 10:28:43 -04:00
|
|
|
|
td= instanceStats.totalLevelsCompleted
|
|
|
|
|
tr
|
2015-09-25 15:51:51 -04:00
|
|
|
|
td(data-i18n="courses.furthest_level")
|
2015-09-24 10:28:43 -04:00
|
|
|
|
td= instanceStats.furthestLevelCompleted.replace('Course: ', '')
|
2015-09-13 01:01:59 -04:00
|
|
|
|
|
|
|
|
|
mixin progress-summary-concepts
|
2015-09-25 15:51:51 -04:00
|
|
|
|
h3(data-i18n="courses.concepts_covered")
|
2015-09-13 01:01:59 -04:00
|
|
|
|
if course && courseInstance && conceptsCompleted
|
|
|
|
|
table.progress-concepts-container
|
|
|
|
|
each concept in course.get('concepts')
|
|
|
|
|
- var conceptCompletion = Math.round(parseFloat(conceptsCompleted[concept]) / courseInstance.get('members').length * 100)
|
|
|
|
|
if isNaN(conceptCompletion)
|
|
|
|
|
- conceptCompletion = 0
|
|
|
|
|
tr
|
|
|
|
|
td.progress-concept-completion-container
|
|
|
|
|
span.progress-concept-summary(style="width:#{conceptCompletion}%;")
|
|
|
|
|
span.spr(data-i18n="concepts." + concept)
|
|
|
|
|
span - #{conceptCompletion}%
|
|
|
|
|
|
|
|
|
|
mixin progress-members
|
2015-09-25 15:51:51 -04:00
|
|
|
|
h3(data-i18n="courses.students")
|
2015-09-13 01:01:59 -04:00
|
|
|
|
table.table.table-condensed
|
|
|
|
|
thead
|
|
|
|
|
tr
|
|
|
|
|
th
|
2015-09-25 15:51:51 -04:00
|
|
|
|
span.progress-member-header.spr(data-i18n="clans.name")
|
2015-09-13 01:01:59 -04:00
|
|
|
|
if memberSort === 'nameAsc'
|
|
|
|
|
span.progress-member-header.glyphicon.glyphicon-chevron-up
|
|
|
|
|
else if memberSort === 'nameDesc'
|
|
|
|
|
span.progress-member-header.glyphicon.glyphicon-chevron-down
|
|
|
|
|
th
|
2015-09-25 15:51:51 -04:00
|
|
|
|
span.progress-header.spr(data-i18n="clans.progress")
|
2015-09-13 01:01:59 -04:00
|
|
|
|
if memberSort === 'progressAsc'
|
|
|
|
|
span.progress-header.glyphicon.glyphicon-chevron-up
|
|
|
|
|
else if memberSort === 'progressDesc'
|
|
|
|
|
span.progress-header.glyphicon.glyphicon-chevron-down
|
|
|
|
|
else
|
|
|
|
|
span(style='padding-left:16px;')
|
2015-09-25 15:51:51 -04:00
|
|
|
|
span.progress-key.progress-key-complete(data-i18n="clans.complete_1")
|
|
|
|
|
span.progress-key.progress-key-started(data-i18n="clans.started_1")
|
2015-10-08 09:07:37 -04:00
|
|
|
|
if showExpandedProgress
|
|
|
|
|
span.progress-key(data-i18n="clans.not_started_1")
|
2015-09-13 01:01:59 -04:00
|
|
|
|
input.progress-expand-checkbox(type='checkbox')
|
2015-09-25 15:51:51 -04:00
|
|
|
|
span.spl.progress-expand-label(data-i18n="courses.expand_details")
|
2015-09-13 01:01:59 -04:00
|
|
|
|
tbody
|
|
|
|
|
each memberID in sortedMembers
|
|
|
|
|
tr
|
|
|
|
|
td.progress-member-cell
|
|
|
|
|
+progress-members-individual(memberID)
|
|
|
|
|
td.progress-cell
|
|
|
|
|
if showExpandedProgress
|
2015-09-25 15:51:51 -04:00
|
|
|
|
.progress-concepts-label(data-i18n="courses.concepts")
|
2015-09-13 01:01:59 -04:00
|
|
|
|
+progress-members-concepts(memberID)
|
2015-09-25 15:51:51 -04:00
|
|
|
|
.progess-levels-label(data-i18n="nav.play")
|
2015-09-13 01:01:59 -04:00
|
|
|
|
+progress-members-levels-expanded(memberID)
|
|
|
|
|
else
|
|
|
|
|
table
|
|
|
|
|
tbody
|
|
|
|
|
tr
|
2015-09-25 15:51:51 -04:00
|
|
|
|
td.progress-concepts-label(data-i18n="courses.concepts")
|
2015-09-13 01:01:59 -04:00
|
|
|
|
td.progress-condensed-cell
|
|
|
|
|
+progress-members-concepts(memberID)
|
|
|
|
|
tr
|
2015-09-25 15:51:51 -04:00
|
|
|
|
td.progess-levels-label(data-i18n="nav.play")
|
2015-09-13 01:01:59 -04:00
|
|
|
|
td.progress-condensed-cell
|
|
|
|
|
+progress-members-levels-condensed(memberID)
|
|
|
|
|
|
|
|
|
|
mixin progress-members-individual(memberID)
|
|
|
|
|
- var name = memberUserMap[memberID] ? memberUserMap[memberID].get('name') : 'Anoner'
|
|
|
|
|
a(href="/user/#{memberID}")= name || 'Anoner'
|
2015-09-24 10:28:43 -04:00
|
|
|
|
if memberStats && memberStats[memberID]
|
2015-09-25 15:51:51 -04:00
|
|
|
|
div
|
|
|
|
|
span #{memberStats[memberID].totalLevelsCompleted}
|
|
|
|
|
span.spl(data-i18n="courses.levels")
|
|
|
|
|
div
|
|
|
|
|
span.spr(data-i18n="courses.played")
|
|
|
|
|
span #{moment.duration(memberStats[memberID].totalPlayTime, "seconds").humanize()}
|
2015-09-13 01:01:59 -04:00
|
|
|
|
|
|
|
|
|
mixin progress-members-concepts(memberID)
|
|
|
|
|
if course && userLevelStateMap[memberID]
|
|
|
|
|
each concept in course.get('concepts')
|
|
|
|
|
if userConceptStateMap[memberID][concept] === 'complete'
|
|
|
|
|
span.spr.progress-concept-cell.progress-concept-cell-complete(data-i18n="concepts." + concept)
|
|
|
|
|
else if userConceptStateMap[memberID][concept] === 'started'
|
|
|
|
|
span.spr.progress-concept-cell.progress-concept-cell-started(data-i18n="concepts." + concept)
|
|
|
|
|
else if showExpandedProgress
|
|
|
|
|
span.spr.progress-concept-cell.progress-concept-cell-not-started(data-i18n="concepts." + concept)
|
|
|
|
|
|
|
|
|
|
mixin progress-members-levels-expanded(memberID)
|
|
|
|
|
if campaign && userLevelStateMap[memberID]
|
|
|
|
|
- var i = 0
|
|
|
|
|
each level, levelID in campaign.get('levels')
|
|
|
|
|
if userLevelStateMap[memberID][levelID] === 'complete'
|
2015-09-24 17:48:54 -04:00
|
|
|
|
span.progress-level-cell.progress-level-cell-complete(data-level-id=levelID, data-level-slug=level.slug, data-user-id=memberID) #{i + 1}
|
2015-09-13 01:01:59 -04:00
|
|
|
|
span.spl= level.name.replace('Course: ', '')
|
2015-11-17 19:53:57 -05:00
|
|
|
|
+progress-members-popup-completed(i, level, (view.userLevelSessionMap[memberID] || {})[levelID])
|
2015-09-13 01:01:59 -04:00
|
|
|
|
else if userLevelStateMap[memberID][levelID] === 'started'
|
2015-09-24 17:48:54 -04:00
|
|
|
|
span.progress-level-cell.progress-level-cell-started(data-level-id=levelID, data-level-slug=level.slug, data-user-id=memberID) #{i + 1} #{level.name.replace('Course: ', '')}
|
2015-11-17 19:53:57 -05:00
|
|
|
|
+progress-members-popup-started(i, level, (view.userLevelSessionMap[memberID] || {})[levelID])
|
2015-09-13 01:01:59 -04:00
|
|
|
|
else
|
|
|
|
|
span.progress-level-cell #{i + 1} #{level.name.replace('Course: ', '')}
|
|
|
|
|
- i++
|
|
|
|
|
|
|
|
|
|
mixin progress-members-levels-condensed(memberID)
|
|
|
|
|
if campaign && userLevelStateMap[memberID]
|
|
|
|
|
- var numLevels = Object.keys(campaign.get('levels')).length
|
|
|
|
|
- var levelCellWidth = 100.00
|
|
|
|
|
if numLevels > 0
|
|
|
|
|
levelCellWidth = 100.00 / numLevels
|
|
|
|
|
- var i = 0
|
|
|
|
|
each level, levelID in campaign.get('levels')
|
|
|
|
|
if userLevelStateMap[memberID][levelID] === 'complete'
|
2015-09-24 17:48:54 -04:00
|
|
|
|
span.progress-level-cell.progress-level-cell-complete(style="width:#{levelCellWidth}%;", data-level-id=levelID, data-level-slug=level.slug, data-user-id=memberID) #{i + 1}
|
2015-11-17 19:53:57 -05:00
|
|
|
|
+progress-members-popup-completed(i, level, (view.userLevelSessionMap[memberID] || {})[levelID])
|
2015-09-13 01:01:59 -04:00
|
|
|
|
else if userLevelStateMap[memberID][levelID] === 'started'
|
2015-09-24 17:48:54 -04:00
|
|
|
|
span.progress-level-cell.progress-level-cell-started(style="width:#{levelCellWidth}%;", data-level-id=levelID, data-level-slug=level.slug, data-user-id=memberID) #{i + 1}
|
2015-11-17 19:53:57 -05:00
|
|
|
|
+progress-members-popup-started(i, level, (view.userLevelSessionMap[memberID] || {})[levelID])
|
2015-09-13 01:01:59 -04:00
|
|
|
|
else
|
|
|
|
|
break
|
|
|
|
|
- i++
|
|
|
|
|
|
2015-11-17 19:53:57 -05:00
|
|
|
|
mixin progress-members-popup-completed(i, level, session)
|
2015-09-13 01:01:59 -04:00
|
|
|
|
.progress-popup-container
|
|
|
|
|
h3 #{i + 1}. #{level.name.replace('Course: ', '')}
|
2015-09-25 15:51:51 -04:00
|
|
|
|
p
|
|
|
|
|
span.spr(data-i18n="courses.play_time")
|
2015-11-17 19:53:57 -05:00
|
|
|
|
span #{moment.duration(session.get('playtime'), "seconds").humanize()}
|
2015-09-25 15:51:51 -04:00
|
|
|
|
p
|
|
|
|
|
span.spr(data-i18n="courses.completed")
|
2015-11-17 19:53:57 -05:00
|
|
|
|
span #{moment(session.get('changed')).format('MMMM Do YYYY, h:mm:ss a')}
|
2015-12-02 12:52:52 -05:00
|
|
|
|
if view.teacherMode || me.isAdmin()
|
2015-09-25 15:51:51 -04:00
|
|
|
|
strong(data-i18n="clans.view_solution")
|
2015-09-13 01:01:59 -04:00
|
|
|
|
|
2015-11-17 19:53:57 -05:00
|
|
|
|
mixin progress-members-popup-started(i, level, session)
|
2015-09-13 01:01:59 -04:00
|
|
|
|
.progress-popup-container
|
|
|
|
|
h3 #{i + 1}. #{level.name.replace('Course: ', '')}
|
2015-09-25 15:51:51 -04:00
|
|
|
|
p
|
|
|
|
|
span.spr(data-i18n="courses.play_time")
|
2015-11-17 19:53:57 -05:00
|
|
|
|
span #{moment.duration(session.get('playtime'), "seconds").humanize()}
|
2015-09-25 15:51:51 -04:00
|
|
|
|
p
|
|
|
|
|
span.spr(data-i18n="clans.last_played")
|
2015-11-17 19:53:57 -05:00
|
|
|
|
span #{moment(session.get('changed')).format('MMMM Do YYYY, h:mm:ss a')}
|
2015-12-02 12:52:52 -05:00
|
|
|
|
if view.teacherMode || me.isAdmin()
|
2015-09-25 15:51:51 -04:00
|
|
|
|
strong(data-i18n="clans.view_solution")
|
2015-09-13 01:01:59 -04:00
|
|
|
|
|
|
|
|
|
mixin levels-tab
|
|
|
|
|
table.table.table-striped.table-condensed
|
|
|
|
|
thead
|
|
|
|
|
tr
|
|
|
|
|
th
|
2015-09-25 15:51:51 -04:00
|
|
|
|
th(data-i18n="clans.status")
|
|
|
|
|
th(data-i18n="resources.level")
|
|
|
|
|
th(data-i18n="courses.concepts")
|
2015-09-13 01:01:59 -04:00
|
|
|
|
tbody
|
|
|
|
|
if campaign
|
2015-10-07 18:33:52 -04:00
|
|
|
|
- var lastLevelCompleted = true;
|
2015-11-24 11:56:28 -05:00
|
|
|
|
- var levelCount = 0;
|
2015-09-13 01:01:59 -04:00
|
|
|
|
each level, levelID in campaign.get('levels')
|
|
|
|
|
tr
|
|
|
|
|
td
|
2015-12-02 12:52:52 -05:00
|
|
|
|
if lastLevelCompleted || view.teacherMode
|
2015-11-18 17:08:25 -05:00
|
|
|
|
- var i18n = level.type === 'course-ladder' ? 'play.compete' : 'home.play';
|
|
|
|
|
button.btn.btn-success.btn-play-level(data-level-slug=level.slug, data-i18n=i18n, data-level-id=levelID)
|
2015-09-13 01:01:59 -04:00
|
|
|
|
td
|
|
|
|
|
if userLevelStateMap[me.id]
|
|
|
|
|
div= userLevelStateMap[me.id][levelID]
|
2015-10-07 18:33:52 -04:00
|
|
|
|
- lastLevelCompleted = userLevelStateMap[me.id][levelID] === 'complete'
|
|
|
|
|
else
|
|
|
|
|
- lastLevelCompleted = false
|
2015-11-24 11:56:28 -05:00
|
|
|
|
td= ++levelCount + '. ' + level.name.replace('Course: ', '')
|
2015-09-13 01:01:59 -04:00
|
|
|
|
td
|
|
|
|
|
if levelConceptMap[levelID]
|
|
|
|
|
each concept in course.get('concepts')
|
|
|
|
|
if levelConceptMap[levelID][concept]
|
|
|
|
|
span.spr.progress-level-cell.progress-level-cell-not-started(data-i18n="concepts." + concept)
|