fixed a global scope issue on LessonController | fixed the listenTo yntax for goatRouter.js
This commit is contained in:
parent
da5a63453b
commit
68d952eb5d
@ -132,7 +132,7 @@ define(['jquery',
|
|||||||
};
|
};
|
||||||
|
|
||||||
this.restartLesson = function() {
|
this.restartLesson = function() {
|
||||||
self=this;
|
var self=this;
|
||||||
$.ajax({
|
$.ajax({
|
||||||
url:'service/restartlesson.mvc',
|
url:'service/restartlesson.mvc',
|
||||||
method:'GET'
|
method:'GET'
|
||||||
|
@ -5,8 +5,9 @@ define(['jquery',
|
|||||||
'goatApp/controller/MenuController',
|
'goatApp/controller/MenuController',
|
||||||
'goatApp/view/LessonContentView',
|
'goatApp/view/LessonContentView',
|
||||||
'goatApp/view/MenuView',
|
'goatApp/view/MenuView',
|
||||||
'goatApp/view/TitleView'
|
'goatApp/view/TitleView',
|
||||||
], function ($,_,Backbone,LessonController,MenuController,LessonContentView,MenuView,TitleView) {
|
'goatApp/model/MenuData'
|
||||||
|
], function ($,_,Backbone,LessonController,MenuController,LessonContentView,MenuView,TitleView, MenuModel) {
|
||||||
|
|
||||||
var lessonView = new LessonContentView();
|
var lessonView = new LessonContentView();
|
||||||
var menuView = new MenuView();
|
var menuView = new MenuView();
|
||||||
@ -43,7 +44,7 @@ define(['jquery',
|
|||||||
});
|
});
|
||||||
|
|
||||||
Backbone.history.start();
|
Backbone.history.start();
|
||||||
this.listenTo('menu:reload',this.reloadMenu)
|
this.listenTo(this.menuController, 'menu:reload',this.reloadMenu)
|
||||||
},
|
},
|
||||||
|
|
||||||
reloadMenu: function (curLesson) {
|
reloadMenu: function (curLesson) {
|
||||||
|
File diff suppressed because one or more lines are too long
Loading…
x
Reference in New Issue
Block a user