diff options
| author | Mathieu Duckerts-Antoine <dam@odoo.com> | 2018-06-12 17:11:13 +0200 |
|---|---|---|
| committer | Adrien Dieudonne <adr@odoo.com> | 2018-07-06 14:09:09 +0200 |
| commit | 097464de6f85020ad1e56bbc253837a7d60e47e4 (patch) | |
| tree | a33c5fbe25cedfd2b0ac378b13ac2d47f38f393b /addons/web/static/src/scss/dropdown_menu.scss | |
| parent | 9756109e670cef01b4d475c8cb6687fecdab2cd2 (diff) | |
[IMP] web: easy selection of a period in filters menu
This commit allow to create easily a range of periods (related to a field
of date or datetime type) to select in the filters menu.
Two new attributes on elements with tag 'filter' are now usable
in combination in a search view arch:
- date: string.
A valid field name with associated type date or datetime
- default_period: string (optional).
To choose in the following list:
- 'today'
- 'this_week'
- 'this_month' (default)
- 'this_quarter'
- 'this_year'
- 'yesterday'
- 'last_week'
- 'last_month'
- 'last_quarter'
- 'last_year'
- 'last_7_days'
- 'last_30_days'
- 'last_365_days'
Example:
<filter string="Creation Date" name="period_generator" date="create_date" default_period="this_quarter"/>
Note: the attribute 'domain' can not be used for such filters.
The generated domains are dynamic and can be saved as such
via the favorites menu.
Diffstat (limited to 'addons/web/static/src/scss/dropdown_menu.scss')
| -rw-r--r-- | addons/web/static/src/scss/dropdown_menu.scss | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/addons/web/static/src/scss/dropdown_menu.scss b/addons/web/static/src/scss/dropdown_menu.scss index c32779271bc..8024783d3c2 100644 --- a/addons/web/static/src/scss/dropdown_menu.scss +++ b/addons/web/static/src/scss/dropdown_menu.scss @@ -43,8 +43,16 @@ } } } + li.divider:first-child { + display: none; + } .o_item_option { + color: $o-main-text-color; padding-left: 20px; + &:hover { + color: darken($o-main-text-color, 10%); + background-color: $dropdown-link-hover-bg; + } } } } |
