Daily updates from Odoo
Navigate
Branch
Tuesday, July 11, 2023
19 changes
Security fixes and vulnerability patches
This update replaces broad default access permissions with explicit group-based access across several enterprise modules. It helps ensure that only the intended user groups can access each area, reducing ambiguity in permissions without changing normal access for employees or portal users where it already existed.
Original PR description
enterprise part of odoo/odoo#125216 Specify groups explicitly website_appointment: employee already had access website_knwoledge: portal and employee already had access TO VERIFY: - l10n_co_edi, l10n_mx_edi_extended : only employees ?
Enhancements to existing features
Automatic follow-ups no longer stop immediately when selected customers are missing required contact information. Instead, users see a guided screen that identifies the affected customers and lets them open an editable list to complete the missing details, reducing interruptions in the collection workflow.
Original PR description
Before this commit: in the followup reports, the "Process Automatic Follow-ups" action raises a UserError in case at least one of the selected partners has no mail address Now: when there are partners that have no email, a wizard will be shown with the ability to edit their emails in-place. Task-id #3273020
Managers can now view an employee's next appraisal date directly on the public employee profile. This makes appraisal planning easier by giving managers quick access to upcoming review timing without navigating elsewhere.
Original PR description
The next appraisal date is shown to the manager on the public employee profile. task-2882052
Signing option values can now be viewed and archived without disrupting existing templates or completed signing requests. Archived options are hidden when users edit templates, but remain visible where needed to preserve past document history and avoid inconsistencies.
Original PR description
This commit adds a tree view for sign item options, changes the model to allow archiving records. It was decided to hide archived options in most occasions, however we show them when rendering readonly sign.requests, as it is possible to archive an option that was already selected in a sign.request. task-3233643
The Documents app now offers a clearer and more flexible way to select, activate, preview, and split PDF pages. Users can navigate pages with shortcuts, select ranges or areas, and better understand which pages are active or selected, making document preparation faster and less error-prone.
Original PR description
General improvements of split tools. Refactor of the code. The following features have been added : - Introduction to activation + selection system. - An active page will undo the following actions :…
General improvements of split tools. Refactor of the code. The following features have been added : - Introduction to activation + selection system. - An active page will undo the following actions : - Adding/Removing splitters - Selection of activate pages on space key pressed - A selected page will undo the following actions : - Delete pages - Split button - Applicable rules buttons - Activate pages are displayed has transparent blue whereas selected pages have a selector icon displayed on the top of the page - Navigation between pages with the arrows - Bottom area of each page activates on click - Range activation/selection between 2 pages if shift key is pressed - Area activation of pages when clicking and moving the clicked mouse - If no key is pressed, every click desactivates all activated pages - If shift key is pressed when area selecting : current activated pages stay activated and targetted pages are desactivated - If control key is pressed when area selecting, current activated pages stay activated and targetted pages are also activated - Opens previewer when clicking on page - Shortcuts are introduced TaskId: 3179166
Quality checks now show the related work order operation from the quality point. This helps teams track quality control by specific manufacturing operation when multiple checks exist for one manufacturing order.
Original PR description
Before commit: ================ - work order operation is defined in a quality point, meanwhile the same is not shown on the quality check. After commit: =============== When there are multiple quality points defined on one MO, it would be helpful to have work order operations also defined on the quality checks so one can keep track of QC on each operation specifically within one MO. - Added a work order operation field from the quality point on the quality check. - Also added field 'work order operation' field on the list view of quality check. task: 3283169
Resolved issues and error corrections
Sales orders scheduled in Planning now show the correct allocated hours when adding or editing shifts. This prevents confusing zero-hour displays and avoids unnecessary validation errors when users save planned shifts.
Original PR description
Steps: - Go to the planning module and find the scheduled sales order where the allocated hours is already completed. - now if we add a new shift the allocated hours by default shows 0. - click on save it shows a validation error. Fix: correctly show the allocated hour for slots. task-3183771
The Gantt view now consistently uses touch-friendly interaction events for dragging and related actions. This fixes incomplete behavior introduced by an earlier change, making planning timelines more reliable on tablets and other touch devices.
Original PR description
Since [this commit](b85fdb60807a469d1457be7851ccd8068d680177), the draggable hooks in the views make use of pointer events instead of mouse events to support touch devices. However the gantt view was not entirely adapted to these changes (the draggable hook builder was changed but the other listeners in the gantt view were not). This PR properly switches all event listeners in the gantt view to listen to pointer events. Community PR: https://github.com/odoo/odoo/pull/126772
Code cleanup and technical improvements
The VoIP call transfer action has been reorganized to use the newer application structure instead of older legacy code. This helps keep the calling feature easier to maintain and test without changing the expected user experience.
Original PR description
task-3416597
Miscellaneous changes
Create an expense for [EMPLOYEE] Create the report Submit to Manager > Approve > Report in next payslip Create a new payslip batch including the date of the expense Add [EMPLOYEE] > create payslips Generate draft entries then mark the payslip as paid Issue: expense sheet payment status will not be marked as paid opw-3292560 Forward-Port-Of: odoo/enterprise#43677 Forward-Port-Of: odoo/enterprise#42916
Original PR description
Create an expense for [EMPLOYEE] Create the report Submit to Manager > Approve > Report in next payslip Create a new payslip batch including the date of the expense Add [EMPLOYEE] > create payslips Generate draft entries then mark the payslip as paid Issue: expense sheet payment status will not be marked as paid opw-3292560 Forward-Port-Of: odoo/enterprise#43677 Forward-Port-Of: odoo/enterprise#42916
before this commit, for the pos_preparation_display module, the license is added as LGPL-3 after this commit, license of the modules will be updated to OEEL-1. Forward-Port-Of: odoo/enterprise#43709
Original PR description
before this commit, for the pos_preparation_display module, the license is added as LGPL-3 after this commit, license of the modules will be updated to OEEL-1. Forward-Port-Of: odoo/enterprise#43709
In order to make it possible to use hotkeys in an embedded view, we need to allow events to propagate above the embedded view. The issue with that is that their propagation was stopped in the first place because we don't want to let the editor handle those events as it would in a normal edition context. The solution proposed in this commit is twofold: Let any event initiated in an element inside the embedded view bubble, but skip over the editor. This is done by stopping the propagati
Original PR description
In order to make it possible to use hotkeys in an embedded view, we need to allow events to propagate above the embedded view. The issue with that is that their propagation was stopped in the first…
In order to make it possible to use hotkeys in an embedded view, we need to allow events to propagate above the embedded view. The issue with that is that their propagation was stopped in the first place because we don't want to let the editor handle those events as it would in a normal edition context. The solution proposed in this commit is twofold: Let any event initiated in an element inside the embedded view bubble, but skip over the editor. This is done by stopping the propagation of the original event like before, but creating a clone that will be re-dispatched from the parent of the editable so that it can be catched by other elements, the window or the document. Then, to make the ui service (and by extension the hotkey service) aware that the hotkey comes from and concerns the embedded view, we make it possible for the anchor of the embedded view to capture focus related events (`focusin` and `focusout`), and when the focus is in the embedded view, we manually set its anchor to be the `activeElement` that the ui service (and the hotkey service) use to limit the scope of the hotkey targets. task-3302786 Forward-Port-Of: odoo/enterprise#43710 Forward-Port-Of: odoo/enterprise#41008
This commit is the counter-part of odoo/odoo#127974. I couldn't find a smarter way to ensure that the clickbot really enters Studio. Indeed, there may be apps for which we do not enter Studio at all, and it doesn't mean the selector is wrong. As the click_everywhere test runs the clickbot app by app, we can't simply assert at the end that we entered Studio at least once. Forward-Port-Of: odoo/enterprise#43892
Original PR description
This commit is the counter-part of odoo/odoo#127974. I couldn't find a smarter way to ensure that the clickbot really enters Studio. Indeed, there may be apps for which we do not enter Studio at all, and it doesn't mean the selector is wrong. As the click_everywhere test runs the clickbot app by app, we can't simply assert at the end that we entered Studio at least once. Forward-Port-Of: odoo/enterprise#43892
How to reproduce: - Create an asset - Modify -> disposal - Put the asset's depreciation account as the loss account - Dispose it => You have a weird error saying that the remaining value on the last line is different than 0 (while the values are right). You should not select the same account. So we remove the asset's depreciation account from the domain of the loss account. We also raise an explicit error if the user does it without the wizard. Forward-Port-Of: odoo/enterprise#40279
Original PR description
How to reproduce: - Create an asset - Modify -> disposal - Put the asset's depreciation account as the loss account - Dispose it => You have a weird error saying that the remaining value on the last line is different than 0 (while the values are right). You should not select the same account. So we remove the asset's depreciation account from the domain of the loss account. We also raise an explicit error if the user does it without the wizard. Forward-Port-Of: odoo/enterprise#40279
*: sale_renting_sign Steps to reproduce: - login as admin - install sale_renting_sign - activate debug mode - sign > 3 dots menu on Rental Agreement > properties - Who can sign: All Users - Template access group: Sign / User: Own and Shared Templates - Save - logout and login with user who has Sign / User privilege - Rental Agreement > Send Issue: User gets error message: `Sorry, you are not allowed to access this document.` If we repeat the same process on another exist
Original PR description
*: sale_renting_sign Steps to reproduce: - login as admin - install sale_renting_sign - activate debug mode - sign > 3 dots menu on Rental Agreement > properties - Who can sign: All Users - Template access group: Sign / User: Own and Shared Templates - Save - logout and login with user who has Sign / User privilege - Rental Agreement > Send Issue: User gets error message: `Sorry, you are not allowed to access this document.` If we repeat the same process on another existing template, such as `Non-Disclosure Agreement.pdf`, the user will not get an error when clicking Send. This happens because the `check` function will raise an error if the template does not have a `res_model` and `res_id`. opw-3250596 Forward-Port-Of: odoo/enterprise#43589
Currently the asset depreciation moves computation does not take the lock dates into account. It might thus create journal entries (in draft) before the lock date, causing an error when trying to post them or when you want to change the computation on the Asset form. This fix checks whether there are any moves generated with a date before the lock date and sets the date for these moves to the end of the first period after the lock date (or containing the lock date if it's not the last day of
Original PR description
Currently the asset depreciation moves computation does not take the lock dates into account. It might thus create journal entries (in draft) before the lock date, causing an error when trying to post them or when you want to change the computation on the Asset form. This fix checks whether there are any moves generated with a date before the lock date and sets the date for these moves to the end of the first period after the lock date (or containing the lock date if it's not the last day of the period). [opw-3305506](https://www.odoo.com/web#id=3305506&cids=1&menu_id=4720&action=333&active_id=49&model=project.task&view_type=form) Forward-Port-Of: odoo/enterprise#43226 Forward-Port-Of: odoo/enterprise#43081
When the user schedules a resource shift at that time, "End Date" will be null a traceback will appear. Steps to produce: - Install the planning module. - Go to the "Planning" menu, then the Gantt view will open. - Click on the "New" button, and the Add Shift wizard will open. - Set the "End Date" as null and apply it. Error: TypeError: unsupported operand type(s) for -: 'bool' and 'datetime.datetime' This PR will resolve the issue when the user sets the "End Date" to null. In th
Original PR description
When the user schedules a resource shift at that time, "End Date" will be null a traceback will appear. Steps to produce: - Install the planning module. - Go to the "Planning" menu, then the Gantt…
When the user schedules a resource shift at that time, "End Date" will be null a traceback will appear.
Steps to produce:
- Install the planning module.
- Go to the "Planning" menu, then the Gantt view will open.
- Click on the "New" button, and the Add Shift wizard will open.
- Set the "End Date" as null and apply it.
Error: TypeError: unsupported operand type(s) for -: 'bool' and
'datetime.datetime'
This PR will resolve the issue when the user sets the "End Date" to null. In that case, the "End Date" field value will return zero.
Sentry Traceback:
```TypeError: unsupported operand type(s) for -: 'bool' and 'datetime.datetime'
File "odoo/http.py", line 2123, in __call__
response = request._serve_db()
File "odoo/http.py", line 1699, in _serve_db
return service_model.retrying(self._serve_ir_http, self.env)
File "odoo/service/model.py", line 133, in retrying
result = func()
File "odoo/http.py", line 1726, in _serve_ir_http
response = self.dispatcher.dispatch(rule.endpoint, args)
File "odoo/http.py", line 1927, in dispatch
result = self.request.registry['ir.http']._dispatch(endpoint)
File "addons/website/models/ir_http.py", line 234, in _dispatch
response = super()._dispatch(endpoint)
File "odoo/addons/base/models/ir_http.py", line 190, in _dispatch
result = endpoint(**request.params)
File "odoo/http.py", line 716, in route_wrapper
result = endpoint(self, *args, **params_ok)
File "addons/web/controllers/dataset.py", line 30, in call_kw
return self._call_kw(model, method, args, kwargs)
File "addons/web/controllers/dataset.py", line 26, in _call_kw
return call_kw(request.env[model], method, args, kwargs)
File "odoo/api.py", line 461, in call_kw
result = _call_kw_multi(method, model, args, kwargs)
File "odoo/api.py", line 448, in _call_kw_multi
result = method(recs, *args, **kwargs)
File "odoo/models.py", line 6695, in onchange
todo = [
File "odoo/models.py", line 6698, in <listcomp>
if name not in done and snapshot0.has_changed(name)
File "odoo/models.py", line 6495, in has_changed
return self[name] != record[name]
File "odoo/models.py", line 6122, in __getitem__
return self._fields[key].__get__(self, type(self))
File "odoo/fields.py", line 1155, in __get__
self.recompute(record)
File "odoo/fields.py", line 1365, in recompute
apply_except_missing(self.compute_value, recs)
File "odoo/fields.py", line 1338, in apply_except_missing
func(records)
File "odoo/fields.py", line 1387, in compute_value
records._compute_field_value(self)
File "odoo/models.py", line 4486, in _compute_field_value
fields.determine(field.compute, self)
File "odoo/fields.py", line 99, in determine
return needle(*args)
File "home/odoo/src/enterprise/saas-16.3/planning/models/planning.py", line 271, in _compute_allocated_hours
slot.allocated_hours = slot._calculate_slot_duration() * ratio
File "home/odoo/src/enterprise/saas-16.3/planning/models/planning.py", line 1436, in _calculate_slot_duration
period = self.end_datetime - self.start_datetime
```
Sentry-4292022755
Forward-Port-Of: odoo/enterprise#43604…d on old renewal quotes. Before this commit, when an account move was posted it could trigger a trceback when it tries to update renewal quotes if they have no start_date. We should also avoid updating canceled quotes. Forward-Port-Of: odoo/enterprise#43871 Forward-Port-Of: odoo/enterprise#43853
Original PR description
…d on old renewal quotes. Before this commit, when an account move was posted it could trigger a trceback when it tries to update renewal quotes if they have no start_date. We should also avoid updating canceled quotes. Forward-Port-Of: odoo/enterprise#43871 Forward-Port-Of: odoo/enterprise#43853
Steps to produce the traceback ============================== 1. Install website_helpdesk. 2. Open Website --> Site menu --> Pages --> Click on ticket received page title. Technical ========= If the 'ticket' variable value is null then the same value is being used in t-attf-href="/helpdesk/ticket/#{ticket.id}" that causes the view to be broken and causes the traceback. After this Commit ================= The conditional rendering of the tag based on 'ticket' value resolves the trace
Original PR description
Steps to produce the traceback
==============================
1. Install website_helpdesk.
2. Open Website --> Site menu --> Pages --> Click on ticket received page title.
Technical
=========
If the 'ticket' variable value is null then the same value is being used in t-attf-href="/helpdesk/ticket/#{ticket.id}" that causes the view to be broken and causes the traceback.
After this Commit
=================
The conditional rendering of the tag based on 'ticket' value resolves the traceback.
Task-3366890
Forward-Port-Of: odoo/enterprise#42589