Skip to content

[16.0][IMP] contract documentation#1398

Open
victor-champonnois wants to merge 1 commit intoOCA:16.0from
coopiteasy:16.0-improve-readme
Open

[16.0][IMP] contract documentation#1398
victor-champonnois wants to merge 1 commit intoOCA:16.0from
coopiteasy:16.0-improve-readme

Conversation

@victor-champonnois
Copy link
Member

@victor-champonnois victor-champonnois commented Mar 6, 2026

EDIT : Help welcome to make pre-commit pass. The precommit in the CI throws an error ModuleNotFoundError: No module named 'pkg_resources'

I've been using the contract module quite intensively in the past year, and I wanted to contribute by improving the documentation. I have only a user knowledge of this module, please don't hesitate to point out any mistake I made.

I also should say that I've used mostly Customer contracts. Maybe there are some specific features in Supplier contracts that I missed.

Here are the changes I've made :

  • converted the readmes to markdown to make editing easier
  • added contents to USAGE and CONFIGURATION. More specifically, I tried to add more precisions about the different recurrence configurations.
  • updated one old screenshots.

I realized afterwards I should have made the markdown conversion in a separate commit. However I doubt there will be a lot of issues there since the rst was quite basic.

I've used mostly the v16 version. If these changes is approved and if there hasn't been major changes in v18, I will port to v18.

@victor-champonnois victor-champonnois marked this pull request as ready for review March 6, 2026 15:56
Copy link

@marcos-mendez marcos-mendez left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Automated Review -- Tests Passed

All tests for contract passed successfully on Odoo 16.0.
Environment: Minikube + K8s Job + oca-ci/py3.10-odoo16.0


Test Coverage Suggestions

Coverage Gaps

The PR primarily updates documentation and README files. The code changes appear minimal and focused on UI/UX improvements and documentation clarity, with no new functional logic introduced in the core module.

Suggested Test Cases

Since there are no new functional code paths introduced in this PR, coverage looks adequate for the current implementation.

However, if we were to consider potential future test needs based on the updated documentation (e.g., new recurrence patterns or line-level recurrence features), here are some hypothetical test cases that could be valuable:

def test_contract_line_renew_auto(self):
    """Test automatic renewal of contract lines when end date is reached."""

def test_contract_line_stop_and_successor(self):
    """Test stopping a contract line and creating a successor with new dates."""

def test_contract_line_description_markers(self):
    """Test that #START#, #END#, and #INVOICEMONTHNAME# markers are replaced correctly in descriptions."""

These tests would align with the new documentation describing enhanced recurrence and line-level features, but are not strictly required given the current code changes are limited to documentation and UI updates.

Codecov Risk

No new methods or classes were added in this PR, so there is no risk of decreased coverage from untested code.


Reciprocal Review Request

Hi everyone! Thanks for your contribution to OCA. I reviewed and approved this PR. If any of you have a moment, I would really appreciate a review on my open PR(s):

My open PRs across OCA:

Reviewing each other's work helps the whole community move forward faster. Thank you!


Automated review by OCA Neural Reviewer + qwen3-coder:30b

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants