Skip to content

Commit

Permalink
[MIG] account_fiscal_year: Migration to 12.0
Browse files Browse the repository at this point in the history
  • Loading branch information
rven committed Oct 2, 2018
1 parent d365ac9 commit cc2de25
Show file tree
Hide file tree
Showing 6 changed files with 487 additions and 27 deletions.
67 changes: 44 additions & 23 deletions account_fiscal_year/README.rst
@@ -1,11 +1,30 @@
.. image:: https://img.shields.io/badge/licence-AGPL--3-blue.svg
:target: https://www.gnu.org/licenses/agpl-3.0-standalone.html
:alt: License: AGPL-3

===================
Account Fiscal Year
===================

.. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png
:target: https://odoo-community.org/page/development-status
:alt: Beta
.. |badge2| image:: https://img.shields.io/badge/licence-AGPL--3-blue.png
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
:alt: License: AGPL-3
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Faccount--financial--tools-lightgray.png?logo=github
:target: https://github.com/OCA/account-financial-tools/tree/12.0/account_fiscal_year
:alt: OCA/account-financial-tools
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/account-financial-tools-12-0/account-financial-tools-12-0-account_fiscal_year
:alt: Translate me on Weblate
.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png
:target: https://runbot.odoo-community.org/runbot/92/12.0
:alt: Try me on Runbot

|badge1| |badge2| |badge3| |badge4| |badge5|

This module extends `date.range.type` to add `fiscal_year` flag.

Override official `res_company.compute_fiscal_year_dates` to get the
Expand All @@ -15,48 +34,50 @@ encloses the give date.
If it does not find it, it falls back on the standard Odoo
technique based on the day/month of end of fiscal year.

Usage
=====

.. image:: https://odoo-community.org/website/image/ir.attachment/5784_f2813bd/datas
:alt: Try me on Runbot
:target: https://runbot.odoo-community.org/runbot/92/11.0
**Table of contents**

.. contents::
:local:

Bug Tracker
===========

Bugs are tracked on `GitHub Issues
<https://github.com/OCA/account-financial-tools/issues>`_. In case of trouble, please
check there if your issue has already been reported. If you spotted it first,
help us smashing it by providing a detailed and welcomed feedback.
Bugs are tracked on `GitHub Issues <https://github.com/OCA/account-financial-tools/issues>`_.
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us smashing it by providing a detailed and welcomed
`feedback <https://github.com/OCA/account-financial-tools/issues/new?body=module:%20account_fiscal_year%0Aversion:%2012.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.

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

Credits
=======

Images
------
Authors
~~~~~~~

* Odoo Community Association: `Icon <https://github.com/OCA/maintainer-tools/blob/master/template/module/static/description/icon.svg>`_.
* Camptocamp SA

Contributors
------------
~~~~~~~~~~~~

* Damien Crier <damien.crier@camptocamp.com>
* Laurent Mignon <laurent.mignon@acsone.eu>
* Lorenzo Battistini <lorenzo.battistini@agilebg.com>
* Raf Ven <raf.ven@dynapps.be>

Maintainer
----------
Maintainers
~~~~~~~~~~~

This module is maintained by the OCA.

.. image:: https://odoo-community.org/logo.png
:alt: Odoo Community Association
:target: https://odoo-community.org

This module is maintained by the OCA.

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.

To contribute to this module, please visit https://odoo-community.org.
This module is part of the `OCA/account-financial-tools <https://github.com/OCA/account-financial-tools/tree/12.0/account_fiscal_year>`_ project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
4 changes: 2 additions & 2 deletions account_fiscal_year/__manifest__.py
Expand Up @@ -3,11 +3,11 @@
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
{
'name': 'Account Fiscal Year',
'version': '11.0.1.0.0',
'version': '12.0.1.0.0',
'category': 'Accounting',
'author': 'Camptocamp SA,'
'Odoo Community Association (OCA)',
'website': 'http://www.camptocamp.com',
'website': 'https://github.com/OCA/account-financial-tools',
'depends': [
'account',
'date_range'
Expand Down
3 changes: 1 addition & 2 deletions account_fiscal_year/models/date_range_type.py
Expand Up @@ -21,5 +21,4 @@ def unlink(self):
_('You cannot delete a date range type with '
'flag "fiscal_year"')
)
else:
super(DateRangeType, rec).unlink()
return super(DateRangeType, self).unlink()
4 changes: 4 additions & 0 deletions account_fiscal_year/readme/CONTRIBUTORS.rst
@@ -0,0 +1,4 @@
* Damien Crier <damien.crier@camptocamp.com>
* Laurent Mignon <laurent.mignon@acsone.eu>
* Lorenzo Battistini <lorenzo.battistini@agilebg.com>
* Raf Ven <raf.ven@dynapps.be>
8 changes: 8 additions & 0 deletions account_fiscal_year/readme/DESCRIPTION.rst
@@ -0,0 +1,8 @@
This module extends `date.range.type` to add `fiscal_year` flag.

Override official `res_company.compute_fiscal_year_dates` to get the
fiscal year date start / date end for any given date.
That methods first looks for a date range of type fiscal year that
encloses the give date.
If it does not find it, it falls back on the standard Odoo
technique based on the day/month of end of fiscal year.

0 comments on commit cc2de25

Please sign in to comment.