Files
contract/contract
Pedro M. Baeza 92d86a1a5a [FIX] contract: fix views assignment + improvement on tests + copyright in headers
**Be totally deterministic about which views to use**

Having a primary view that is not explicitly declared to be uses and w/o priority
makes Odoo to choose between one of them randomly (well, not exactly, but kind of),
so we put here which views to use.

I have also put tree view as primary and put a large priority for not being
selected on other actions that don't have this explicit views.

A friendly name in views is also assigned.

**Improvements in tests**

* Use SavepointCase for making the setup only once for all tests
* Make them inheritable, creating a base class with only the setup,
  so that it can be inherited without the need of executing all tests
  contained here each time you inherit it, and adding other class
  in the same module that inherits from the base class that actually
  performs the tests.
* Removed duplicated test method
2020-07-13 17:02:57 +02:00
..

.. image:: https://img.shields.io/badge/licence-AGPL--3-blue.svg
    :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
    :alt: License: AGPL-3

=================================
Contracts for recurrent invoicing
=================================

This module forward-port to v10 the contracts management with recurring
invoicing functions. Also you can print and send by email contract report.

In upstream Odoo, this functionality was moved into the Enterprise edition.

Configuration
=============

To view discount field set *Discount on lines* in user access rights.

Usage
=====

To use this module, you need to:

#. Go to Accounting -> Contracts and select or create a new contract.
#. Check *Generate recurring invoices automatically*.
#. Fill fields for selecting the recurrency and invoice parameters:

   * Journal
   * Pricelist
   * Period. It can be any interval of days, weeks, months, months last day or
     years.
   * Start date and next invoice date.
   * Invoicing type: pre-paid or post-paid.
#. Add the lines to be invoiced with the product, description, quantity and
   price.
#. You have the possibility to use the markers #START# or #END# in the
   description field to show the start and end date of the invoiced period.
#. Choosing between pre-paid and post-paid, you modify the dates that are shown
   with the markers.
#. A cron is created with daily interval, but if you are in debug mode, you can
   click on *Create invoices* to force this action.
#. Click *Show recurring invoices* link to show all invoices created by the
   contract.
#. Click on *Print > Contract* menu to print contract report.
#. Click on *Send by Email* button to send contract by email.

.. image:: https://odoo-community.org/website/image/ir.attachment/5784_f2813bd/datas
   :alt: Try me on Runbot
   :target: https://runbot.odoo-community.org/runbot/110/10.0

Known issues / Roadmap
======================

* Recover states and others functional fields in Contracts.

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

Bugs are tracked on `GitHub Issues
<https://github.com/OCA/contract/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.

Credits
=======

Contributors
------------

* Pedro M. Baeza <pedro.baeza@tecnativa.com>
* Carlos Dauden <carlos.dauden@tecnativa.com>
* Angel Moya <angel.moya@domatix.com>
* Dave Lasley <dave@laslabs.com>
* Vicent Cubells <vicent.cubells@tecnativa.com>

Maintainer
----------

.. 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.