Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
create_filter: function (filter) {
var self = this;
return rpc.query({
args: [filter],
model: 'ir.filters',
method: 'create_or_replace',
})
.then(function (filter_id) {
var key = [
filter.model_id,
filter.action_id || false,
].join(',');
self._invalidate(self._cache.filters, key);
return filter_id;
});
},
create_filter: function (filter) {
var self = this;
return rpc.query({
args: [filter],
model: 'ir.filters',
method: 'create_or_replace',
})
.then(function (filter_id) {
var key = [
filter.model_id,
filter.action_id || false,
].join(',');
self._invalidate(self._cache.filters, key);
return filter_id;
});
},