diff options
| author | Aaron Bohy <aab@odoo.com> | 2019-02-05 12:36:17 +0000 |
|---|---|---|
| committer | Mathieu Duckerts-Antoine <dam@odoo.com> | 2019-02-13 12:23:28 +0000 |
| commit | 3a5f6bfa9f74a0f038df4f22b97061c436c01281 (patch) | |
| tree | 72a9fa8362ac46fdbceb59fe9d53756c9bbd0884 /doc/reference | |
| parent | 33207ed452cb1f3f2dc05a447a137b8cc8cee9ed (diff) | |
[IMP] web: add kanban searchPanel
This rev. defines a searchPanel widget used in Kanban views to
refine search according to specific dimensions. This wigdet is
displayed as a sidebar to the left of the kanban view.
Part of task 1892462
Co-authored-by: Aaron Bohy <aab@odoo.com>
Co-authored-by: Mathieu Duckerts-Antoine <dam@odoo.com>
Co-authored-by: Raphael Collet <rco@odoo.com>
Diffstat (limited to 'doc/reference')
| -rw-r--r-- | doc/reference/views.rst | 51 |
1 files changed, 51 insertions, 0 deletions
diff --git a/doc/reference/views.rst b/doc/reference/views.rst index c38c5019df2..fbac4763ecb 100644 --- a/doc/reference/views.rst +++ b/doc/reference/views.rst @@ -1111,6 +1111,57 @@ Possible children of the view element are: * kanban-specific CSS * kanban structures/widgets (vignette, details, ...) +``searchpanel`` + allows to display a search panel on the left of the kanban view. + This tool allows to quickly filter data on the basis of given fields. The fields + are specified as direct children of the ``searchpanel`` with tag name ``field``, + and the following attributes: + + * ``name`` (mandatory) the name of the field to filter on + + * ``select`` determines the behavior and display. Possible values are + + ``one`` (default) at most one value can be selected. Supported field types are + many2one and selection. + + ``multi`` several values can be selected (checkboxes). Supported field + types are many2one, many2many and selection. + + * ``groups``: restricts to specific users + + * ``string``: determines the label to display + + * ``icon``: specifies which icon is used + + * ``color``: determines the icon color + + Additional optional attributes are available in the ``multi`` case: + + * ``domain``: determines conditions that the comodel records have to satisfy. + + A domain might be used to express a dependency on another field (with select="one") + of the search panel. Consider + + .. code-block:: xml + + <searchpanel> + <field name="department_id"/> + <field name="manager_id" select="multi" domain="[('department_id', '=', department_id)]"/> + <searchpanel/> + + In the above example, the range of values for manager_id (manager names) available at screen + will depend on the value currently selected for the field ``department_id``. + + * ``groupby``: field name of the comodel (only available for many2one and many2many fields). Values will be grouped by that field. + + * ``disable_counters``: default is false. If set to true the counters won't be computed. + + This feature has been implemented in case performances would be too bad. + + Another way to solve performance issues is to properly override the + ``search_panel_select_multi_range`` method. + + If you need to extend the Kanban view, see :js:class::`the JS API <KanbanRecord>`. .. _reference/views/calendar: |
