Wizard Base

This commit is contained in:
Ruud
2011-10-24 07:35:14 +02:00
parent f9d09cadab
commit 138845ca9e
2 changed files with 210 additions and 64 deletions
+9 -1
View File
@@ -33,7 +33,10 @@ var PageBase = new Class({
//p('Opening: ' +self.getName() + ', ' + action + ', ' + Object.toQueryString(params));
try {
self[action+'Action'](params);
self.el.empty();
var elements = self[action+'Action'](params);
self.el.adopt(elements);
self.fireEvent('opened');
}
catch (e){
@@ -41,6 +44,11 @@ var PageBase = new Class({
self.fireEvent('error');
}
},
openUrl: function(url){
if(History.getPath() != url)
History.push(url);
},
errorAction: function(e){
p('Error, action not found', e);