[ADD] basic implementation of get_context and get_domain on filters

bzr revid: xmo@openerp.com-20110324162335-l622nm8pyjb31pfh
This commit is contained in:
Xavier Morel 2011-03-24 17:23:35 +01:00
parent c96b91e690
commit 4756756f81
1 changed files with 12 additions and 0 deletions

View File

@ -609,6 +609,18 @@ openerp.base.search.Filter = openerp.base.search.Input.extend({
$(this).toggleClass('enabled');
$view_form.submit();
});
},
get_context: function () {
if (!this.$element.hasClass('enabled')) {
return;
}
return this.attrs.context;
},
get_domain: function () {
if (!this.$element.hasClass('enabled')) {
return;
}
return this.attrs.domain;
}
});
openerp.base.search.Field = openerp.base.search.Input.extend({