Tuesday, October 19, 2021
30 changes · master
Enhancements to existing features
The mail message composer has been reorganized so its interaction handling sits with the underlying composer logic. This makes the messaging code easier to maintain and helps support future improvements with lower risk of inconsistent behavior.
Original PR description
Part of task-2579306
Fleet managers can now record a write-off date directly on a vehicle record. This helps businesses track when vehicles are retired from service and improves lifecycle reporting for fleet assets.
Original PR description
Add the Write Off Date on vehicle. TaskID: 2657561 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
The mail app’s message composer has been reorganized so suggestion lists are managed in a reusable model instead of being tied directly to the composer. This reduces internal complexity and makes it easier to use the same suggestion behavior in other messaging areas in the future.
Original PR description
This will reduce composer model complexity and allow to reuse suggestion code inside other component. task-2447140
Newly created users will no longer automatically receive the Leave Responsible role when they do not manage any employees. This keeps leave management permissions cleaner and reduces unnecessary administrative access.
Original PR description
New users automatically received the Leave Responsible role even though they were not managing any employees. TaskID: 2635715 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
The HR Responsible field on employee contracts now only offers employees from the contract's company. This helps prevent assigning responsibility to someone outside the relevant company, reducing administrative mistakes in multi-company setups.
Original PR description
HR Responsible should be limited to the employee's of the contract's company. TaskID: 2668125 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
When helpdesk tickets are shared through the forum, users now see a clear banner to return to editing the ticket. This makes navigation smoother and avoids sending users back to the main backend by mistake.
Original PR description
…n forum purpose of this commit is to display the 'Back to Edit Mode' portal banner on the forum page when sharing tickets from the helpdesk. TaskID-2602604
Written-off company cars will no longer be offered as choices in the Belgian payroll fleet salary configurator. This helps employees and HR teams select only valid vehicles and avoids mistakes during salary package setup.
Original PR description
Do not offer Written Off Cars in the salary configurator. TaskID: 2657561
Resolved issues and error corrections
This fixes an internal issue that could prevent Odoo from correctly checking whether certain protected records exist when they are based on database queries rather than standard tables. The change helps avoid errors when users encounter records they are not allowed to read, improving reliability in core system behavior.
Original PR description
The exists method doesn't work with model without SQL table but with a table query f2ceef0e2f0efb2e47b5f595a80009184305a2c4 This method is call when we try to read a forbidden record (`forbidden = missing.exists()` in `_read`) - Fix it by using a Query object (which able the case) - Also use a partition method instead of duplicate it in the method (in master ??? WIP ) task-2633558 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
Miscellaneous changes
PURPOSE A pie chart is meant to illustrate numerical proportions. In Odoo, when hovering a piece of a pie chart, the tooltip is currently not displayed the proportion/percentage of the piece in the pie. The purpose of this task is to provide the user with the percentages of data distribution by adding them in the tooltip. SPECIFICATION in the tooltip displayed when hovering a piece of the pie chart, add the percentage between brackets TASK 2608695 Description of the issue/feature thi
Original PR description
PURPOSE A pie chart is meant to illustrate numerical proportions. In Odoo, when hovering a piece of a pie chart, the tooltip is currently not displayed the proportion/percentage of the piece in the pie. The purpose of this task is to provide the user with the percentages of data distribution by adding them in the tooltip. SPECIFICATION in the tooltip displayed when hovering a piece of the pie chart, add the percentage between brackets TASK 2608695 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#74953
The Website CRM Reveal app now explicitly depends on Website CRM, keeping required visitor data available. This prevents website pages such as the home or contact page from failing after related CRM functionality is removed.
Original PR description
PURPOSE The purpose of this commit is to minimize the AttributeError: 'website.visitor' object has no attribute 'lead_ids'. SPECIFICATIONS While installing 'website_crm_iap_reveal' module, 'website_crm' module will auto-install. But while uninstalling only the 'website_crm' module, it removes the 'lead_ids' field and when a public user is visiting the website home/contactus page, the error is coming. This adds the dependency of 'website_crm' module. This is the goal of this commit. LINKS PR #78354 Task-2655439 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
The time off calendar now shows the delete button only for requests that can still be deleted, instead of showing it for approved or refused requests. This prevents users from attempting invalid deletions and makes the calendar actions match the request status.
Original PR description
On the month, week or day time off calendar views, the delete button appears when the time off is in approved or refused state and does not when the time off is in other states. The behavior should be the opposite. https://www.awesomescreenshot.com/video/5681852?key=2b2136139c3fadd1006b98c0f4be920c task-2671598 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
If a user has access to account.move but not pos.order, it was not possible to open the invoice or the report Forward-Port-Of: odoo/odoo#78553
Original PR description
If a user has access to account.move but not pos.order, it was not possible to open the invoice or the report Forward-Port-Of: odoo/odoo#78553
What are the steps to reproduce your issue? - Create a purchase order and set whatever vendor reference (i.e: 123456) - Receive the products - Go to Vendor Bills and create a new vendor Bill. - In the Auto-Complete field, try to type the vendor reference. What is the current behavior that you observe? It's not possible to find a purchase order by vendor reference, only by Odoo sequence. What would be your expected behavior in this case? This is not very convenient in this
Original PR description
What are the steps to reproduce your issue? - Create a purchase order and set whatever vendor reference (i.e: 123456) - Receive the products - Go to Vendor Bills and create a new vendor Bill. - In the Auto-Complete field, try to type the vendor reference. What is the current behavior that you observe? It's not possible to find a purchase order by vendor reference, only by Odoo sequence. What would be your expected behavior in this case? This is not very convenient in this case, as this is the reference that we'll have in every document the supplier gives us. It used to be searchable up to v11 opw-27434 cc @Tecnativa TT27434 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#65725 Forward-Port-Of: odoo/odoo#65265
Warehouse should not be modified when the salesperson is modified on a confirmed SO Steps to reproduce : Have multiple warehouses 1, 2 and 3 Create an SO for warehouse 2 or 3 and confirm it. Edit the confirmed SO and change the salesperson, the warehouse is changed on the SO opw-2614063 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
Original PR description
Warehouse should not be modified when the salesperson is modified on a confirmed SO Steps to reproduce : Have multiple warehouses 1, 2 and 3 Create an SO for warehouse 2 or 3 and confirm it. Edit the confirmed SO and change the salesperson, the warehouse is changed on the SO opw-2614063 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#78327
There was a missing translation for ok/cancel button in daterangepicker widget. With this change, we provide the odoo translation to the library when initializing the picker. opw-2628117 Forward-Port-Of: odoo/odoo#78563 Forward-Port-Of: odoo/odoo#78518
Original PR description
There was a missing translation for ok/cancel button in daterangepicker widget. With this change, we provide the odoo translation to the library when initializing the picker. opw-2628117 Forward-Port-Of: odoo/odoo#78563 Forward-Port-Of: odoo/odoo#78518
It seems that this long dereference causes a MemoryError for accounts with many associated line_ids ``` select count(*) from account_analytic_account a join account_analytic_line l on l.account_id = a.id join account_move_line ml on ml.id = l.move_id where a.id=7 +---------+ | count | |---------| | 131672 | +---------+ ``` The solution we propose is to use search_read inverting the order of dereferences. ``` Traceback (most recent call last): File "/tmp/tmpfhzemskj/migrati
Original PR description
It seems that this long dereference causes a MemoryError for accounts with many associated line_ids ``` select count(*) from account_analytic_account a join account_analytic_line l on l.account_id =…
It seems that this long dereference causes a MemoryError for accounts
with many associated line_ids
```
select count(*) from account_analytic_account a join account_analytic_line l on l.account_id = a.id join account_move_line ml on ml.id = l.move_id where a.id=7
+---------+
| count |
|---------|
| 131672 |
+---------+
```
The solution we propose is to use search_read inverting the order of
dereferences.
```
Traceback (most recent call last):
File "/tmp/tmpfhzemskj/migrations/base/tests/test_mock_crawl.py", line 182, in crawl_menu
self.mock_action(action_vals)
File "/tmp/tmpfhzemskj/migrations/base/tests/test_mock_crawl.py", line 293, in mock_action
mock_method(model, view, fields_list, domain, group_by)
File "/tmp/tmpfhzemskj/migrations/base/tests/test_mock_crawl.py", line 319, in mock_view_form
[data] = record.read(fields_list)
File "/home/odoo/src/odoo/15.0/odoo/models.py", line 3227, in read
return self._read_format(fnames=fields, load=load)
File "/home/odoo/src/odoo/15.0/odoo/models.py", line 3247, in _read_format
vals[name] = convert(record[name], record, use_name_get)
File "/home/odoo/src/odoo/15.0/odoo/models.py", line 5867, in __getitem__
return self._fields[key].__get__(self, type(self))
File "/home/odoo/src/odoo/15.0/odoo/fields.py", line 1106, in __get__
self.compute_value(recs)
File "/home/odoo/src/odoo/15.0/odoo/fields.py", line 1265, in compute_value
records._compute_field_value(self)
File "/home/odoo/src/odoo/15.0/addons/mail/models/mail_thread.py", line 410, in _compute_field_value
return super()._compute_field_value(field)
File "/home/odoo/src/odoo/15.0/odoo/models.py", line 4249, in _compute_field_value
getattr(self, field.compute)()
File "/home/odoo/src/odoo/15.0/addons/purchase/models/analytic_account.py", line 15, in _compute_purchase_order_count
account.purchase_order_count = len(account.line_ids.move_id.purchase_order_id)
File "/home/odoo/src/odoo/15.0/odoo/fields.py", line 2605, in __get__
return self.mapped(records)
File "/home/odoo/src/odoo/15.0/odoo/fields.py", line 1176, in mapped
self.__get__(first(remaining), type(remaining))
File "/home/odoo/src/odoo/15.0/odoo/fields.py", line 2603, in __get__
return super().__get__(records, owner)
File "/home/odoo/src/odoo/15.0/odoo/fields.py", line 1106, in __get__
self.compute_value(recs)
File "/home/odoo/src/odoo/15.0/odoo/fields.py", line 1265, in compute_value
records._compute_field_value(self)
File "/home/odoo/src/odoo/15.0/odoo/models.py", line 4251, in _compute_field_value
field.compute(self)
File "/home/odoo/src/odoo/15.0/odoo/fields.py", line 615, in _compute_related
values = [first(value[name]) for value in values]
File "/home/odoo/src/odoo/15.0/odoo/fields.py", line 615, in <listcomp>
values = [first(value[name]) for value in values]
File "/home/odoo/src/odoo/15.0/odoo/models.py", line 5867, in __getitem__
return self._fields[key].__get__(self, type(self))
File "/home/odoo/src/odoo/15.0/odoo/fields.py", line 2603, in __get__
return super().__get__(records, owner)
File "/home/odoo/src/odoo/15.0/odoo/fields.py", line 1083, in __get__
recs._fetch_field(self)
File "/home/odoo/src/odoo/15.0/odoo/models.py", line 3276, in _fetch_field
self._read(fnames)
File "/home/odoo/src/odoo/15.0/odoo/models.py", line 3364, in _read
self.env.cache.update(fetched, field, values)
File "/home/odoo/src/odoo/15.0/odoo/api.py", line 893, in update
field_cache.update(zip(records._ids, values))
MemoryError
```
Observed during the upgrade of 41031
--
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#78306Bug === If you send a URL (which will be transformed into a link tracker) to an external website (e.g. in mass mailing, social, ...), the UTM values will be added in the GET parameters of the URL. The external website might crash if those parameters are not supported by it. We want to add a system parameter `link_tracker.no_external_tracking` to be able to not add those UTM values in the redirected URL. This is done only for external website, because it will never be an issue if
Original PR description
Bug === If you send a URL (which will be transformed into a link tracker) to an external website (e.g. in mass mailing, social, ...), the UTM values will be added in the GET parameters of the URL. The external website might crash if those parameters are not supported by it. We want to add a system parameter `link_tracker.no_external_tracking` to be able to not add those UTM values in the redirected URL. This is done only for external website, because it will never be an issue if the URL redirect to Odoo. Task-2657413 X-original-commit: 0b3538e50b4a5c3d9b699d5b2349cb5188d88c88 Forward-Port-Of: odoo/odoo#78594
Currently, markup-ification of the legacy notifications system display the html content in notification layout for some of the notification of document and planning since commit: https://github.com/odoo/enterprise/commit/ba44461fea337ed2e5adbdfa1e8eede00b036def So here in this commit, we make the method `makeLegacyNotificationService` always `_.escape(message)` and pass `messageIsHtml: true` to the owl notifications system so notification with html content will be displayed properly. Task
Original PR description
Currently, markup-ification of the legacy notifications system display the html content in notification layout for some of the notification of document and planning since commit: https://github.com/odoo/enterprise/commit/ba44461fea337ed2e5adbdfa1e8eede00b036def So here in this commit, we make the method `makeLegacyNotificationService` always `_.escape(message)` and pass `messageIsHtml: true` to the owl notifications system so notification with html content will be displayed properly. Task-2657391 Forward-Port-Of: odoo/odoo#78289
Before this commit Each click event triggered inside a DropdownItem is default prevented After this commit Those click events will be default prevented only when the DropdownItem receives a props.href, which will turn it into an <a href/> element. This corresponds to the initial intention: prevent the default click behavior of an <a href/> element and only keep the DropdownItem click behavior. opw-2665795 Forward-Port-Of: odoo/odoo#78559
Original PR description
Before this commit Each click event triggered inside a DropdownItem is default prevented After this commit Those click events will be default prevented only when the DropdownItem receives a props.href, which will turn it into an <a href/> element. This corresponds to the initial intention: prevent the default click behavior of an <a href/> element and only keep the DropdownItem click behavior. opw-2665795 Forward-Port-Of: odoo/odoo#78559
Steps to follow - Enable group_show_line_subtotals_tax_included - Create a repair order and add a tax to a line -> The subtotal doesn't contain the tax amount opw-2513287 Forward-Port-Of: odoo/odoo#78586 Forward-Port-Of: odoo/odoo#76427
Original PR description
Steps to follow - Enable group_show_line_subtotals_tax_included - Create a repair order and add a tax to a line -> The subtotal doesn't contain the tax amount opw-2513287 Forward-Port-Of: odoo/odoo#78586 Forward-Port-Of: odoo/odoo#76427
Before this commit, it was possible to edit scroll buttons with the editor toolbar. task-2656662 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#78562 Forward-Port-Of: odoo/odoo#78532
Original PR description
Before this commit, it was possible to edit scroll buttons with the editor toolbar. task-2656662 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#78562 Forward-Port-Of: odoo/odoo#78532
Release notes: https://github.com/odoo/owl/releases/tag/v1.4.7 fix: memory leak in some templates 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#78644
Original PR description
Release notes: https://github.com/odoo/owl/releases/tag/v1.4.7 fix: memory leak in some templates 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#78644
When you are using a fixed amount reduction in the loyalty program, it only applies one time the cost of point for this reward. To avoid having to click multiple times on the available reward, we are spending as many points as possible in the reward fixed amount and set it as quantity. This behavior consist of having a similar behavior as with the resale reward type in v 13.0 Here is the example of the wanted behavior: You want to give a reward of 10% based on what the customer purch
Original PR description
When you are using a fixed amount reduction in the loyalty program, it only applies one time the cost of point for this reward. To avoid having to click multiple times on the available reward, we are…
When you are using a fixed amount reduction in the loyalty program, it only applies one time the cost of point for this reward. To avoid having to click multiple times on the available reward, we are spending as many points as possible in the reward fixed amount and set it as quantity. This behavior consist of having a similar behavior as with the resale reward type in v 13.0 Here is the example of the wanted behavior: You want to give a reward of 10% based on what the customer purchased previously. And you want to be able to apply it at any time, not just waiting to have 5$ of reduction to give it to customer. The configration made is this one. On the program, you get 100 points/$ On the reward rule, it cost you 10 points to get a fixed amount of 0.01$ It means that based on what you get as points, you are giving 10% Before this fix, if you sold for 1$ => get 100 points, you were abe to give the reward as it cost 10 points. But you had to click 10 times, to spende the 100 points available. Now, it will apply directly 10 times the discount whent it is a fixed amount. Forward-Port-Of: odoo/enterprise#21787
Issue generation steps with video: https://drive.google.com/file/d/1NkPJnVSpciv0ADfn-MgXwst9vUjPaVbF/view?usp=sharing Opw id: https://www.odoo.com/web#id=2502061&action=333&active_id=70&model=project.task&view_type=form&cids=2&menu_id=4720 Forward-Port-Of: odoo/enterprise#21418
Original PR description
Issue generation steps with video: https://drive.google.com/file/d/1NkPJnVSpciv0ADfn-MgXwst9vUjPaVbF/view?usp=sharing Opw id: https://www.odoo.com/web#id=2502061&action=333&active_id=70&model=project.task&view_type=form&cids=2&menu_id=4720 Forward-Port-Of: odoo/enterprise#21418
…nalysis' purpose of this task is to change name of action helpdesk.team > overview > success rate to 'Tickets Analysis' ask-2657391 Forward-Port-Of: odoo/enterprise#21206
Original PR description
…nalysis' purpose of this task is to change name of action helpdesk.team > overview > success rate to 'Tickets Analysis' ask-2657391 Forward-Port-Of: odoo/enterprise#21206
Currently when appointment is installed, from the back-end of calendar app we can share the availabilities(see sidebar at the right). This sharing drop-down toggle uses a custom icon, and so we need to hide the default one that is provided by bootstrap, otherwise it displays custom icon and default caret both, and ruins the UI. To hide the default caret, we can either remove the `dropdown-toggle` class from button, or we can simply hide the default caret. The first solution might break
Original PR description
Currently when appointment is installed, from the back-end of calendar app we can share the availabilities(see sidebar at the right). This sharing drop-down toggle uses a custom icon, and so we need to hide the default one that is provided by bootstrap, otherwise it displays custom icon and default caret both, and ruins the UI. To hide the default caret, we can either remove the `dropdown-toggle` class from button, or we can simply hide the default caret. The first solution might break x-path, and it can also break the feature(if there are multi level drop-down menus). This PR simply hides the default caret and thus only shows the custom icon for sharing drop-down toggle. TaskID-2666793 Forward-Port-Of: odoo/enterprise#21615
The partner was never taken into account for predicting products and taxes, and the prediction count therefore not make the difference between partners in the history of previous lines. [task-2479202](https://www.odoo.com/web#cids=1&id=2479202&model=project.task) Forward-Port-Of: odoo/enterprise#21558
Original PR description
The partner was never taken into account for predicting products and taxes, and the prediction count therefore not make the difference between partners in the history of previous lines. [task-2479202](https://www.odoo.com/web#cids=1&id=2479202&model=project.task) Forward-Port-Of: odoo/enterprise#21558
Forward-Port-Of: odoo/enterprise#21747
Original PR description
Forward-Port-Of: odoo/enterprise#21747
Latam 555 / Adhoc ticket 39652 --- We found out an error when creating the QR code for the PDF representation of the "(19) Factura de Exportacion" document type. We check an AFIP Online generated invoice and they use CUIT PAIS as the receptor document number. Formerly we were reporting a sanitized version of the VAT number of the foreign customer because QR code specification tells us that the receptor document number is a numeric value, which was causing confusion because this one may be
Original PR description
Latam 555 / Adhoc ticket 39652 --- We found out an error when creating the QR code for the PDF representation of the "(19) Factura de Exportacion" document type. We check an AFIP Online generated invoice and they use CUIT PAIS as the receptor document number. Formerly we were reporting a sanitized version of the VAT number of the foreign customer because QR code specification tells us that the receptor document number is a numeric value, which was causing confusion because this one may be alphanumeric and we were sending a modified fiscal number. Now we are using the CUIT PAIS instead which is a generic CUIT number defined by AFIP to Identify receptors for a specific country, This way we are ensuring that the QR receptor document number is numeric. Forward-Port-Of: odoo/enterprise#18325
PURPOSE Many2one dropdown option link color is changed to black color, as we are replacing dropdown_extra.scss with fields.scss but we do not add css rule for many2one dropdown option link with enterprise specific colors. SPEC The 'Search more...' link should be displayed as a green link TASK 2622147 Forward-Port-Of: odoo/enterprise#20200
Original PR description
PURPOSE Many2one dropdown option link color is changed to black color, as we are replacing dropdown_extra.scss with fields.scss but we do not add css rule for many2one dropdown option link with enterprise specific colors. SPEC The 'Search more...' link should be displayed as a green link TASK 2622147 Forward-Port-Of: odoo/enterprise#20200