Saturday, February 3, 2024
3 changes · 17.0
Enhancements to existing features
The send and print flow now shows clearer warning messages with direct links to fix missing or incorrect invoice data before sending. This helps users resolve Italian e-invoicing issues faster and reduces failed submissions or confusion during invoice processing.
Original PR description
The new ActionableErrors widget new widget is meant to be a warnings header for wizards and forms, where flows like EDI can list a series of errors and actions for the users to fix the roadblocks.…
The new ActionableErrors widget new widget is meant to be a warnings header for wizards and forms, where flows like EDI can list a series of errors and actions for the users to fix the roadblocks.
The HTML result is a `<div>` list with a point for each warning and a link to a given action. Clicking the link will fire the execution of a Python method on the backend, also passing back to it a series of parameters the component has stored on setup time.
During setup, ActionableErrors accepts this structure as incoming data:
```py
{
'error_key' : {
'message': _("Description of the warning"),
'action_text': _("Text of the link"),
'action': {
'type': 'ir.actions.act_window',
'res_model': 'model.to.be.opened',
'views': [(False, 'list'), (False, 'form')],
'target': 'current',
'res_id': res_ids[0],
},
}, ...
}
```
A map is used instead of an array, so that the Owl framework could be more precise in rendering changes in future development, thanks the `t-foreach`'s `t-key` check. (i.e. remove a warning after clicking the action link without re-rendering the whole widget)
In `l10n_it_edi`'s Send&Print flow, we removed the old code from the view, we changed the compute from HTML to Json, and adapted the compute function's output to fit the ActionableErrors widget format.
All the pre-sending checks that were done on the before sending are now split by model, so that there's more separation.
The actions will get created by `base/ir_ui_view.py/Model`.[get_records_action](https://github.com/odoo/odoo/pull/142596/commits/48bb284b33f9939eb68bfb9a8484dc588e2fa0df#diff-dfebe5a93e1b8880e88268b024be4c6f106d144b20298d7bb6c4ae09a18bafd0R2703), which will enable us to **remove a lot of action-building methods** scattered through Odoo.
<details><summary><b>Images preview ←←←←← </b></summary>
<p>
Before:

After:

</p>
</details>This update adds detailed logging of IoT Box version information, including Odoo version and git branch details. This improvement makes it easier for support teams and developers to diagnose and troubleshoot IoT Box issues by having complete version history available in logs.
Original PR description
Before the current PR, the version of Odoo along with the git branch of the IoT Box and the associated image were never logged. Adding this information to logs allow to to debug / inspect issues more easily task-3716879 Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#152361 Forward-Port-Of: odoo/odoo#152291
When importing invoices in UBL/CII XML format, the system now automatically extracts and populates bank account details (account numbers and BIC codes) from the XML file. This eliminates manual data entry and ensures accurate bank information is captured during the invoice import process.
Original PR description
Problem --------- Currently, when importing a UBL/CII xml, the bank account details remain empty while we usually have the bank account number and the BIC code provided in the XML. Objective…
Problem
---------
Currently, when importing a UBL/CII xml, the bank account details remain empty while we usually have the bank account number and the BIC code provided in the XML.
Objective
---------
Autofill the partner_bank_id field on the invoice using the values provided in the UBL/CII XML.
Solution
---------
Currently, UBL XML are organized as such:
PaymentMeans(0..n)
|-PayeeFinancialAccount
|-ID
|-FinancialInstitutionBranch
|-ID
And CII as such:
SpecifiedTradeSettlementPaymentMeans(0..n)
|-PayeePartyCreditorFinancialAccount
| |-IBANID (for SEPA)
| |-ProprietaryID (for national payment)
|
|-PayeeSpecifiedCreditorFinancialInstitution
|-BICID
We first fetch the account numbers from the XML (several may be present) and store them as a list.
This list is sent to the edi_common which will attempt to find one account that match the given values. If none are found, we create one bank account for each piece of bank data found in the xml.
task-3636150
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#152448
Forward-Port-Of: odoo/odoo#147153