Saturday, April 6, 2024
3 changes · 17.0
Resolved issues and error corrections
This fix corrects how the Indonesian e-Invoice module retrieves company information from invoices. Previously, it was pulling data from the invoice's partner contact, which caused errors when that contact was a subsidiary of a larger company. The system now correctly retrieves the information from the main commercial partner instead, ensuring all required tax and company details are properly captured for e-Invoice generation.
Original PR description
At the moment, the partner being used to get the information for the efaktur module is the partner set on the invoice. This is wrong, since if the partner set on the invoice is a child record of a company partner you cannot set most of these fields. To fix this issue, we will update in order to fetch the efaktur related fields from the commercial partner instead. (vat, along with all efaktur specific information used in the process) --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#160192 Forward-Port-Of: odoo/odoo#160108
This update fixes two issues with the autocomplete feature that were preventing dropdown lists from closing properly and causing selected options to not be applied. Users will now experience more reliable autocomplete behavior when selecting options from dropdown lists, particularly when using drag-and-drop or clicking on suggestions in contact forms.
Original PR description
First commit fixes an issue introduced by https://github.com/odoo/odoo/pull/154203 which could keep the autocomplete options list opened even after a click away when the user would "drag and drop" an…
First commit fixes an issue introduced by https://github.com/odoo/odoo/pull/154203 which could keep the autocomplete options list opened even after a click away when the user would "drag and drop" an option out of the list instead of simply clicking on it. This is caused by the fact that the onInputBlur code is directly terminated in this case (because of ignoreBlur) while it is the only way for the autocomplete list to be closed in this case. The solution is therefore to add an external listener on pointer down which will always close the autocomplete list when clicking away from it. Steps to reproduce: - go to any autocomplete (crm salesperson for example) - click on the input - drag and drop a result outside of the list - try to close the autocomplete list by clicking away Before the fix, the autocomplete list would only close by scrolling or clicking on the input once again. Second commit fixes an issue regarding unwanted interaction between the regular autocomplete option click selection and the onChange handler from the input field hook used in the PartnerAutoCompleteCharField component. This became an issue starting from https://github.com/odoo/odoo/pull/154203 because of the disappearance of the t-on-mousedown.prevent handler placed on the autocomplete options list which would prevent the onChange event from being triggered when clicking on an option. The issue would be that the onChange handler from the input field hook would take precedence over the option click handler of the autocomplete which would most of the time be ignored afterwards. The solution found for this problem is to prevent the immediate propagation of the change event in the autocomplete handler when an option has been clicked on so that it will never be propagated to the input field hook handler in this case. Steps to reproduce: - Go to contacts and open a company contact - Type in the name field a few characters (at least 3) - Click on any autocomplete option Most of the time, the option will not be applied and the name won't change Forward-Port-Of: odoo/odoo#159765 Forward-Port-Of: odoo/odoo#159333
This fix resolves an issue where users would see an error message when clicking the confirm button on time off requests that don't require validation. The confirm button was incorrectly visible during the creation process, and clicking it would trigger an unnecessary error. After this fix, users can confirm time off requests without encountering this error message.
Original PR description
Description of the issue/feature this PR addresses: In odoo V17 if a user is creating a holiday request for a time of type that requires no validation, the confirm button is visible during the…
Description of the issue/feature this PR addresses: In odoo V17 if a user is creating a holiday request for a time of type that requires no validation, the confirm button is visible during the creation process due to this line https://github.com/odoo/odoo/blob/2876b8300d1f9a740deb0faa02399df2426df402/addons/hr_holidays/views/hr_leave_views.xml#L248 in prior versions this was not the case https://github.com/odoo/odoo/blob/391a427620b6aec690481fe7c7d0b0326b95ee8c/addons/hr_holidays/views/hr_leave_views.xml#L238 So due to this change in Odoo V17 the confirm button is visible to the user while creating (before saving) so if the user clicks on the confirm button the behavior is it will save the record then set its state to confirm then will call action validate (all in the create function) after the execution of the create is finished it will call `action_confirm` which in turn will raise the user error. I added a check in the action confirm function to check if the time off requires no validation. alternatively I can revert the changes and add the `id == False` in the condition for the `action_confirm` button action. Current behavior before PR: A user error message is raised if the user clicks on the confirm button. see issue #160831 Desired behavior after PR is merged: No user error message that happens if the user clicks on the confirm button. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr