[FIX] Handle correctly webclient's show_application execution in web_analytics

bzr revid: vta@openerp.com-20130110084700-curkkezb5333edai
This commit is contained in:
vta vta@openerp.com 2013-01-10 09:47:00 +01:00
parent ab20d92da8
commit d9faa7c095
1 changed files with 4 additions and 2 deletions

View File

@ -78,6 +78,7 @@ openerp.web_analytics = function(instance) {
return instance.session.rpc("/web/webclient/version_info", {})
.done(function(res) {
_gaq.push(['_setCustomVar', 5, 'Version', res.server_version, 3]);
_gaq.push(['_trackPageview']);
return;
});
},
@ -271,9 +272,10 @@ openerp.web_analytics = function(instance) {
},
show_application: function() {
var self = this;
instance.web_analytics.setupTracker(self).always(function() {
self._super();
$.when(this.subscribe_deferred).then(function() {
instance.web_analytics.setupTracker(self);
});
this._super();
},
});
}