-
- Downloads
[IMP] ir.filters: new filters are local to the menu/action by default
Allow binding an optional `action_id` to filters. The web client will try to identify the specific action ID when saving new filters. If no contextual action exists, the filter is saved globally for the model. This will automatically keep filters within their original menu when there are several menus/actions leading to a given list of documents. In some cases the action_id will not match the filter model, which should be fine (e.g. when opening a many2one completion popup for model `foo` within a menu of model `bar`). It is also still be possible to have a filter apply to all actions/menus for a given model by manually deleting the action_id value in the filter (e.g. via the Manage Filters debug menu). When updating a filter the action_id value is ignored so that old global filters will be gradually replaced by new "local" filters. Also added an _order to ensure stable ordering of the filters.
Showing
- addons/web/static/src/js/search.js 9 additions, 3 deletionsaddons/web/static/src/js/search.js
- addons/web/static/test/search.js 1 addition, 0 deletionsaddons/web/static/test/search.js
- openerp/addons/base/ir/ir_filters.py 43 additions, 15 deletionsopenerp/addons/base/ir/ir_filters.py
- openerp/addons/base/ir/ir_filters.xml 2 additions, 0 deletionsopenerp/addons/base/ir/ir_filters.xml
- openerp/addons/base/tests/test_ir_filters.py 3 additions, 4 deletionsopenerp/addons/base/tests/test_ir_filters.py
Loading
Please register or sign in to comment