Commit Graph

28 Commits

Author SHA1 Message Date
sbejaoui
8e56200b56 [FIX] - as date_start is required, constraints on it become useless
[FIX] - for finished contract _get_lines_to_invoice should return False
2021-11-09 10:07:59 +07:00
Thomas Binsfeld
2b80ed5696 [REF] Contract: invoice creation
[FIX] - Fix typo

[IMP] - date start required for contract line

[REF] Gitignore: .eggs

[REF] Contract Unit Tests: base the cron check on invoice lines instead of invoices
2021-11-09 10:07:59 +07:00
sbejaoui
2d917d03bd [FIX] - contract recurring_next_date ignore canceled lines
[FIX] - fix _get_invoiced_period if recurring_next_date manually updated
2021-11-09 10:07:59 +07:00
sbejaoui
235124f118 [IMP] - don't allow to unlink uncnaceled contrac line 2021-11-09 10:07:59 +07:00
sbejaoui
0d7579f37e [IMP] - store last_date_invoiced on contract_line
Improve CRITERIA_ALLOWED_DICT

[IMP] - code improvement

[IMP] - Use last_date_invoiced to set marker in invoice description

[IMP] - add migration script to init last_day_invoiced and some other improvement

[FIX] - a contract line suspended should start a day after the suspension end
2021-11-09 10:07:59 +07:00
sbejaoui
3e28563f09 [IMP] - hide recurring_invoicing_type if recurring_rule_type is monthlylastday
for the monthlylastday case, pre-paid is logicly impossible,
if monthlylastday is set, we consider only post-paid case

[IMP] - Improve unit tests
2021-11-09 10:07:59 +07:00
sbejaoui
b46cb904ec [IMP] - improve cancel/uncancel process
[FIX] - Test if start_date is set before compute

[FIX] - date_end include in the period in auto_renew case

[FIX] - in suspension case, contract line should start a day after the end

[IMP] - confirm message on contract line cancel
2021-11-09 10:07:59 +07:00
sbejaoui
ee3baca89d [FIX] - fix stop_plan_successor case 5
contract line start in the suspension period and end after it
2021-11-09 10:07:59 +07:00
sbejaoui
07f0f44c05 [IMP] - Add primary views for contract
[IMP] - don't use related filed for partner_id and pricelist_id
2021-11-09 10:07:58 +07:00
sbejaoui
65147775ca [FIX] - invoice last period for post-paid case 2021-11-09 10:07:58 +07:00
sbejaoui
b5c38415d4 [12.0][IMP] - Add strat/stop wizard to contract line
[12.0][IMP] - Add pause button to contract line

[IMP] - Add state filed in contract line form

[FIX] - stop don't change date_end for finished contract line

[IMP] - Change contract line buttons visibility

Add renewal process with termination notice

[FIX] - don't consider stop_date If it is after the contract line end_date

[IMP] - consider more cases in stop_plan_successor

[IMP] - cancel upcoming line on stop

[IMP] - Chnage next invoice date on un-cancel

[IMP] - Post message in contract on contract line actions

[IMP] - check contract line overlap
2021-11-09 10:07:58 +07:00
sbejaoui
23d42d6974 [IMP] - Make recurrence mechanism on contract line
Make recurrence mechanism on contract line and some other refactoring

[FIX] - Keep contract_cron on account_analytic_account model

contract_cron defined with no_update option.
Changing it, will cause issue to past version installation.

[IMP] - Fix recurring_next_date default value

recurring_next_date should have start_date as default value in prepaid policy
and start_date + invoicing_interval if postpaid

[FIX] - Fix test check no journal

[IMP] - Return created invoices on recurring_create_invoice

[IMP] - Specific process to compute recurring_next_date for  monthly-last-day

fixes: #198

[ADD] - Add Post-migration script to bring recurrence info from contract to contract lines

[ADD] - Add search filter based on date_end and recurring_next_date

 - not_finished filter in contract search view
 - finished filter in contract search view
 - Next Invoice group by in contract search view

[ADD] - Add unit tests

- cases to compute first recurring next date
- contract recurring_next_date
- contract date_end

[IMP] - Improve Unit tests
2021-11-09 10:07:58 +07:00
sbejaoui
5d8b5916cb [MIG] contract: Migration to 12.0 2021-11-09 10:07:58 +07:00
Pedro M. Baeza
72ba1fa9d6 [IMP] contract: Don't depend on external data
The test as it was, leaves to the demo pricelist the control on the price of
the product, so other modules that modifies this pricelist will make the
test to fail.

This is the minimum change needed for avoiding the problem.
2021-11-09 10:07:58 +07:00
mreficent
e49941d887 [IMP] Make sure it works for sale and purchase contracts
[UPD] Update contract.pot
2021-11-09 10:07:52 +07:00
Stefan Becker
a32ba288f8 [IMP] Add type to analytic account / contract 2021-11-09 10:07:52 +07:00
Carlos Dauden
f839cb1529 [IMP] contract: Add extend existing invoice possibility 2021-10-28 14:04:11 +07:00
Pedro M. Baeza
1c2c530cc2 [IMP] contract: Automatic prices for lines 2021-10-28 14:04:11 +07:00
Pedro M. Baeza
c01b5b2070 [10.0][FIX+IMP] contract: Improve usability and don't fail on wrong data (#130)
* [FIX+IMP] contract: Improve usability and don't fail on wrong data

* Cron create invoices masked for avoiding silent errors
* New constraints for assuring data consistency
* UI helps for entering consistent data
* Spanish translation
* Remove double company_id field on form
2021-10-28 14:04:11 +07:00
Fekete Mihai
775ee4e2d7 [MIG] contract: Migration to version 11.0 2021-10-28 14:04:11 +07:00
Carlos Dauden
4237f38003 [IMP] contract: Module contract improvements (#107) 2021-10-28 14:04:11 +07:00
Pedro M. Baeza
364148f557 [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
2021-10-28 14:04:11 +07:00
Dave Lasley
6cd28264b4 [FIX] contract: Template lines handling (#92)
Update contract template lines handling to fix #80, and fix #59 #100
2021-10-28 14:04:11 +07:00
cubells
88321d1cb1 [IMP][10.0] contract: Add report + send by mail (#86)
* [IMP][9.0] contract: Add report + send by mail

* Update translation and rename contract report

* Changes requested and translation updated
2021-10-28 14:04:11 +07:00
Dave Lasley
24d3965a73 [IMP][10.0] contract: Add templating (#42)
Add template functionality for contracts
2021-10-28 14:04:11 +07:00
Pedro M. Baeza
bccedcc858 [MIG] contract: Migration to version 10.0 2021-10-28 14:04:11 +07:00
Carlos Dauden
22c4c2f22b [IMP] contract: Add past receipt type. Fix yearly. Add month last day 2021-10-28 14:04:11 +07:00
Carlos Incaser
9140314de1 [MIG] contract: from v7 to v9 improving features
* Tests added
* Filters added.
* Add _id/_ids in old property fields
* Translations
2021-10-28 14:04:11 +07:00