Thursday, July 17, 2025
2 changes · saas-18.1
Enhancements to existing features
The Point of Sale now loads only the product attribute information it actually needs instead of pulling in all related attribute data. This reduces unnecessary data processing and helps keep PoS responsive for businesses with large product catalogs.
Original PR description
Before this commit, all product attributes were loaded, which in turn loaded all corresponding product template attribute values (PTAVs), regardless of whether they were actually needed. This behavior led to significant performance issues, particularly in databases with a large number of attributes and PTAVs, causing the PoS to become slow and unresponsive. opw-4895204 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#218548
This change prevents approved Saudi invoice PDF attachments from being deleted once invoices are posted or accepted by ZATCA, supporting auditability and compliance requirements. It still allows deletion of PDFs created before a rejected invoice was later resubmitted and accepted, so users can clean up outdated documents when appropriate.
Original PR description
Task ID: 4730762 Description of the issue/feature this PR addresses: - As per ZATCA's auditability principles (clause 3 sub-heading C, paragraph 2): The Compliant E-Invoice solution must be able to…
Task ID: 4730762 Description of the issue/feature this PR addresses: - As per ZATCA's auditability principles (clause 3 sub-heading C, paragraph 2): The Compliant E-Invoice solution must be able to protect the generated Electronic Invoices and Electronic Notes from alteration or deletion. - This PR aims to restrict the deletion of valid invoice PDFs once the invoice has been generated & sent to ZATCA. Current Behavior before PR: - Invoice PDF attachments were allowed to be deleted in l10n_sa, even when the invoice is posted. - For l10n_sa_edi, if and invoice PDF is generated during a rejected state, it is kept there unless you reset to draft. Desired behavior after PR is merged: - in l10n_sa, deleting an attached invoice PDF raises a user error (reset to draft is required to detach the invoice first) - For l10n_sa_edi, if the invoice PDF is generated during a rejected state, but the invoice is resubmtited to ZATCA and accepted. The creation & write dates of the attachment linked & edi_documents respectively are compared and the deletion of the pdf attachment is allowed to be deleted in the case where the creation date was less than the write date. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#211192