Skip to content

[14.0][ADD] document_page_archive_reason - #923

Open
eantones wants to merge 1 commit into
14.0from
14.0-add-document_page_archive_reason
Open

[14.0][ADD] document_page_archive_reason#923
eantones wants to merge 1 commit into
14.0from
14.0-add-document_page_archive_reason

Conversation

@eantones

@eantones eantones commented Jun 2, 2026

Copy link
Copy Markdown
Member

Supersedes #920

Split from #920. Odoo task: nuobit15-prod #2633 - [Qualitat] CONOCIMIENTO 5 - Arxiu amb motiu i nota automàtica.

@codecov

codecov Bot commented Jun 2, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 98.43750% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 51.53%. Comparing base (e066126) to head (74db489).

Files with missing lines Patch % Lines
...cument_page_archive_reason/models/document_page.py 92.85% 1 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             14.0     #923      +/-   ##
==========================================
+ Coverage   51.26%   51.53%   +0.27%     
==========================================
  Files        1180     1187       +7     
  Lines       20388    20516     +128     
  Branches     4298     4309      +11     
==========================================
+ Hits        10451    10573     +122     
- Misses       9683     9687       +4     
- Partials      254      256       +2     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@eantones eantones left a comment

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Review published with the requested changes in the line comments. Main points to address before merge:

  • keep the archive flow on the normal action_archive() path instead of writing active directly;
  • add and maintain the internal current archive reason field;
  • revalidate and sanitize the reason at confirm time, including escaping chatter HTML;
  • keep unarchive aligned with standard Odoo behavior while clearing the stored reason only where needed;
  • avoid exposing a generic context bypass for no-reason archiving;
  • align tests with the natural wizard workflow;
  • align wizard ACLs with users who can actually modify document pages;
  • update the source README behavior description and regenerate derived artifacts after the code changes.

Please address the requested changes before merge.

Comment thread document_page_archive_reason/wizards/document_page_archive_reason.py Outdated
Comment thread document_page_archive_reason/models/document_page.py
Comment thread document_page_archive_reason/models/document_page.py Outdated
Comment thread document_page_archive_reason/models/document_page.py Outdated
Comment thread document_page_archive_reason/wizards/document_page_archive_reason.py Outdated
Comment thread document_page_archive_reason/models/document_page.py Outdated
Comment thread document_page_archive_reason/models/document_page.py Outdated
Comment thread document_page_archive_reason/readme/DESCRIPTION.rst Outdated
Comment thread document_page_archive_reason/wizards/document_page_archive_reason.py Outdated
Comment thread document_page_archive_reason/security/ir.model.access.csv Outdated
@eantones

eantones commented Jun 4, 2026

Copy link
Copy Markdown
Member Author

@deeniiz I published the review as COMMENT because this split PR is under my account, so GitHub does not let me use the normal REQUEST_CHANGES flow here.

Please treat the review as request changes: address the line comments before merge, and ping me again once the PR is updated for re-review.

@deeniiz
deeniiz force-pushed the 14.0-add-document_page_archive_reason branch from 4bc0714 to 8c04bc3 Compare June 8, 2026 07:55
@deeniiz

deeniiz commented Jun 8, 2026

Copy link
Copy Markdown
Collaborator

@eantones , can you please review it?

@deeniiz
deeniiz force-pushed the 14.0-add-document_page_archive_reason branch from 028f70a to 4792b1f Compare June 10, 2026 09:08
@deeniiz
deeniiz force-pushed the 14.0-add-document_page_archive_reason branch from 4792b1f to 74db489 Compare June 10, 2026 09:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants