1efa19478cc00e6335ac9bb39930f891a3cfa558
The client action that allows the user to post invoices to the Kenyan fiscal device needs adapting to utilise the current JavaScript framework. This commit refactors the existing client action defined in 'l10n_ke_edi_tremol/static/src/js/post_send.js'. The functionality is mostly factored out of the action, and into a hook and a dialog that are utilised by the action. The hook is called 'useKEProxy' and handles all of the logic related to posting an invoice to the device. It has a 'state' attribute that represents the current progress in this posting process. The dialog is called 'KEProxyDialog', and is passed to the dialog service by the client action. It makes use the useKEProxy hook and its state, which is used to update the UI to inform the user about the success/failure of posting the invoices. The dialog uses the slots from the standard dialog, removing the close 'x' button from the header, and hiding 'ok' button from the footer unless there has been an error (this gives the user time to read the error message before closing the dialog). If all invoices are successfully posted, the dialog automatically closes. Additionally, the function on the account.move model that decomposes the results and writes them to the fields of the records has been renamed to "l10n_ke_cu_responses" and its behaviour adapted to handle batched responses. closes odoo/odoo#111334 Signed-off-by: Josse Colpaert <jco@odoo.com>
…
…
Odoo
Odoo is a suite of web based open source business apps.
The main Odoo Apps include an Open Source CRM, Website Builder, eCommerce, Warehouse Management, Project Management, Billing & Accounting, Point of Sale, Human Resources, Marketing, Manufacturing, ...
Odoo Apps can be used as stand-alone applications, but they also integrate seamlessly so you get a full-featured Open Source ERP when you install several Apps.
Getting started with Odoo
For a standard installation please follow the Setup instructions from the documentation.
To learn the software, we recommend the Odoo eLearning, or Scale-up, the business game. Developers can start with the developer tutorials
Languages
Python
49.6%
JavaScript
47.8%
SCSS
2%
CSS
0.3%
HTML
0.2%