Date Range
(0)
111

Date Range

FREE

Technical name
date_range
License
LGPL-3
Secure dependencies
N/A
Date Range

Date Range

Mature License: LGPL-3 OCA/server-ux Translate me on Weblate Try me on Runboat

This module lets you define global date ranges that can be used to filter your values in tree views.

It also provides a mixin model for developers that extends the model’s search view so that date ranges can be search as any relational field.

Table of contents

Installation

The addon use the daterange method from postgres. This method is supported as of postgresql 9.2

Configuration

For regular usage, see Usage below. This section is to clarify optional functionality to developers.

To configure a model to use the Many2one style search field, make the model inherit from `date.range.search.mixin`:

class AccountMove(models.Model):
    _name = "account.move"
    _inherit = ["account.move", "date.range.search.mixin"]

This will make a Period field show up in the search view:

search_view

By default, the mixin works on the date field. If you want the mixin to work on a field with a different name, you can set a property on your model:

_date_range_search_field = "invoice_date"

Usage

To configure this module, you need to:

  • Go to Settings > Technical > Date ranges > Date Range Types where you can create types of date ranges.

    image1

  • Go to Settings > Technical > Date ranges > Date Ranges where you can create date ranges.

    image2

    It’s also possible to launch a wizard from the ‘Generate Date Ranges’ menu.

    image3

    The wizard is useful to generate recurring periods. Set an end date or enter the number of ranges to create.

    image4

  • Your date ranges are now available in the search filter for any date or datetime fields

    Date range types are proposed as a filter operator

    image5

    Once a type is selected, date ranges of this type are porposed as a filter value

    image6

    And the dates specified into the date range are used to filter your result.

    image7

  • You can configure date range types with default values for the generation wizard on the Generation tab. In the same tab you can also configure date range types for auto-generation. New ranges for types configured for this are generated by a scheduled task that runs daily.

    image8

Bug Tracker

Bugs are tracked on GitHub Issues. In case of trouble, please check there if your issue has already been reported. If you spotted it first, help us to smash it by providing a detailed and welcomed feedback.

Do not contact contributors directly about support or help with technical issues.

Credits

Authors

  • ACSONE SA/NV

Contributors

Maintainers

This module is maintained by the OCA.

Odoo Community Association

OCA, or the Odoo Community Association, is a nonprofit organization whose mission is to support the collaborative development of Odoo features and promote its widespread use.

Current maintainer:

lmignon

This module is part of the OCA/server-ux project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.

0.0 / 5.0
based on 0 ratings

Python dependencies

Package Version Secured
psycopg2_binary 2.8.6
lxml 4.6.1
odoo_test_helper 2.1.1
python_dateutil 2.9.0.post0
This app has automated tests.

Available languages

Language % translated
Italian / Italiano
100%
French / Français
50%
Portuguese / Português
50%
French / Français
50%
Chinese (Simplified) / 简体中文
50%
Dutch / Nederlands
48%
Dutch / Nederlands
48%
Arabic / الْعَرَبيّة
44%
Croatian / hrvatski jezik
40%
German / Deutsch
40%
Portuguese (BR) / Português (BR)
37%
Slovenian / slovenščina
15%
Slovak / Slovenský jazyk
13%
Croatian / hrvatski jezik
13%
Bulgarian / български език
13%
Portuguese / Português
13%
Finnish / Suomi
13%
Swedish / Svenska
12%
Spanish (MX) / Español (MX)
12%
Romanian / română
12%
French (CA) / Français (CA)
12%
Indonesian / Bahasa Indonesia
12%
Persian / فارس
12%
Mongolian / монгол
12%
French (CH) / Français (CH)
12%
English (UK)
12%
Estonian / Eesti keel
12%
Chinese (Traditional) / 繁體中文
12%
Spanish (EC) / Español (EC)
12%
Turkish / Türkçe
12%
Thai / ภาษาไทย
12%
Macedonian / македонски јазик
12%
Hebrew / עִבְרִי
12%
Spanish (CL) / Español (CL)
12%
Japanese / 日本語
12%
Hungarian / Magyar
12%
Spanish (VE) / Español (VE)
12%
Dutch (BE) / Nederlands (BE)
12%
Bosnian / bosanski jezik
12%
Vietnamese / Tiếng Việt
12%
Spanish (CO) / Español (CO)
12%
Turkish / Türkçe
12%
Polish / Język polski
12%
Spanish (AR) / Español (AR)
12%
Ukrainian / українська
12%
Spanish (DO) / Español (DO)
12%
Serbian (Latin) / srpski
12%
Latvian / latviešu valoda
11%
Spanish (PY) / Español (PY)
11%
Spanish (CR) / Español (CR)
11%
Russian / русский язык
11%
Spanish (PE) / Español (PE)
11%
Spanish / Español
11%
Spanish / Español
11%
Norwegian Bokmål / Norsk bokmål
9%
Vietnamese / Tiếng Việt
9%
Greek / Ελληνικά
9%
Lithuanian / Lietuvių kalba
8%
Lithuanian / Lietuvių kalba
8%
Galician / Galego
1%
Hindi / हिंदी
1%
Lao / ພາສາລາວ
1%
Galician / Galego
1%
English (AU)
1%
Catalan / Català
1%