mirror of
https://github.com/codeninjasllc/codecombat.git
synced 2024-12-12 00:31:21 -05:00
Merge branch 'master' into production
This commit is contained in:
commit
59eb95c235
3 changed files with 4 additions and 0 deletions
|
@ -132,6 +132,8 @@ mixin course-instance-body(courseInstance, classroom)
|
|||
else
|
||||
- var firstLevel = stats.levels.first;
|
||||
- var levelURL = "/play/level/"+firstLevel.get('slug')+"?course="+courseInstance.get('courseID')+"&course-instance="+courseInstance.id;
|
||||
if firstLevel.get('primerLanguage')
|
||||
- levelURL += "&codeLanguage=" + firstLevel.get('primerLanguage');
|
||||
a.play-btn.btn.btn-navy.btn-lg.m-b-1(data-href=levelURL, data-level-slug=firstLevel.get('slug'), data-event-action="Students Start Course")
|
||||
span(data-i18n="courses.start")
|
||||
|
||||
|
|
|
@ -133,6 +133,7 @@ module.exports = class CourseDetailsView extends RootView
|
|||
viewArgs = viewArgs.concat ['course', @courseInstance.id]
|
||||
else
|
||||
route = @getLevelURL levelSlug
|
||||
route += "&codeLanguage=" + level.get('primerLanguage') if level.get('primerLanguage')
|
||||
viewClass = 'views/play/level/PlayLevelView'
|
||||
viewArgs = [{courseID: @courseID, courseInstanceID: @courseInstanceID, supermodel: @supermodel}, levelSlug]
|
||||
Backbone.Mediator.publish 'router:navigate', route: route, viewClass: viewClass, viewArgs: viewArgs
|
||||
|
|
|
@ -103,6 +103,7 @@ module.exports = class CourseVictoryModal extends ModalView
|
|||
link = "/play/level/#{@nextLevel.get('slug')}?course=#{@courseID}&codeLanguage=#{utils.getQueryVariable('codeLanguage', 'python')}"
|
||||
else
|
||||
link = "/play/level/#{@nextLevel.get('slug')}?course=#{@courseID}&course-instance=#{@courseInstanceID}"
|
||||
link += "&codeLanguage=" + @level.get('primerLanguage') if @level.get('primerLanguage')
|
||||
application.router.navigate(link, {trigger: true})
|
||||
|
||||
onDone: ->
|
||||
|
|
Loading…
Reference in a new issue