Thursday, April 6, 2023
6 changes · master
Enhancements to existing features
Odoo can now handle requests to place empty values first or last when sorting records. This makes list ordering more predictable, especially for descending sorts and related records where empty values previously could appear in confusing positions.
Original PR description
Recent Odoo versions require modern postgres (e.g. use of jsonb), the `NULLS {FIRST | LAST}` clause was added in 8.3 so should be well supported. While Odoo's use of nulls is not always consistent,…
Recent Odoo versions require modern postgres (e.g. use of jsonb), the `NULLS {FIRST | LAST}` clause was added in 8.3 so should be well supported.
While Odoo's use of nulls is not always consistent, the NULLS ordering clauses can be quite useful especially when sorting `DESC`: `NULLS FIRST` and `NULLS LAST` are literal positions so they put nulls at that location regardless of sort order whereas the default Postgres ordering is to consider nulls larger than every other value so they appear first when sorting DESC, which is often undesirable (putting nulls first when sorting ASC can also be useful to fill records).
Update `_generate_order_by_inner` to correctly process `NULLS` clauses:
- Use `regex_order` to ensure we parse orderings correctly and consistently, also update `regex_order` to use named groups to make the relevant bits clearer (and VERBOSE for readability).
- Given `a_id DESC` and `_fields[a_id].relation._order = 'xxx NULLS LAST'`, reversing the clause should order by `xxx DESC NULLS FIRST` to correctly flip the original as `NULLS` clauses are not relative to the sorting order (they put the `NULL`-valued records at the specified location regardless). Therefore apply `reverse_direction` to `NULLS`.
- Manually expand `NULLS` clauses on m2o fields: propagating the clause through the join would yield unexpected and illogical results when mixing NULL m2o fields and non-NULL m2o fields with NULL `_order` fields (as they would get mixed rather than clearly layered / separated).
However because SQL booleans are ordered the usual way (`true > false`) the `NULLS` clause is fundamentally equivalent to sorting on the field being NULL (if `NULLS LAST`) or not (if `NULLS FIRST`). So we can prepend the expanded m2o's ordering with such a clause to get the correct behavior.
Replaces #116464
Supersedes #116664Call participant cards now show a clickable error indicator that lets users retry playback when browser media restrictions interrupt audio or video. This makes online calls easier to recover without leaving or restarting the call.
Original PR description
This commit improves the overlay icon that appears on call participant cards when an error in the media players occur. The icon is now clickable, which restarts an attempt to play all the `HTMLMediaElement`s of the call as a recoverable error can occur when the browser does not allow `HTMLMediaElement`s being played outside a user interaction. other related changes: * removing the `pointer-event:none` from the overlay as it was preventing hover events, and the title tooltip from appearing. * removing the try/catch around the `srcObject` assignment, as it should only crash on old browsers without support for `srcObject` for which the support of using the alternative (`URL.createObjectUrl` with `src`) is being dropped.
Project profitability now includes manually added analytic accounting lines when they clearly belong to a single project, giving managers a more complete view of costs and revenues. Portal pages also show the specific task, ticket, or project name, and task dependency notifications are clearer for users.
Original PR description
This commit purpose is - to add the all the user adds manually to the panel of project profitability if there is only project linked to the analytic account. - to remove the stage tracking for task dependencies, and instead log a note to warn the user when all the blocking tasks are closed. If one of those task is reopened, message is sent to warn that the task is blocked again - to display the name of the current task/ticket/project on the portal page instead of the generic My tasks/etc - to update the name of notification sub-types task/project dependcy task-2960753 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
Odoo’s document scanning has been upgraded to a newer OCR version for invoices, expenses, and recruitment documents. This improves compatibility with the latest extraction service and adjusts how extracted results are handled, including cases where suggested values may be missing.
Original PR description
Upgrade to the latest OCR version (app: 102, exp: 132, inv: 122). With this version, we do not send the `global_taxes` nor the `global_taxes_amount` anymore. `words` in the response were replaced by the more suitable `candidates`. It is now possible to not have `candidates` in the response, and it is also possible to have no `selected_value`.
The Helpdesk overview page now gives clearer performance context with an updated success rate explanation and color-coded performance indicators against daily targets. Urgent ticket actions also open with the urgent filter applied by default, helping teams focus on priority work faster.
Original PR description
In this PR change following UI changes in helpdesk overview page: - change the 'success rate' tooltip to - "Percentage of tickets whose SLAs have successfully been reached on time over the total number of tickets closed within the past 7 days." - 'Today' and 'Avg Last 7 days' my performance buttons in btn-success if the value is >= to their daily target else btn-warning. - set the 'urgent' filter by default in team kanban card urgent action task-3186583
Portal users can now see how many shared documents are linked to a project task even when the shared project is editable. This makes document access more consistent and reduces confusion for external users collaborating on projects.
Original PR description
**Before this commit:** Currently, documents are available to portal users when the project is shared in read-only, but not when it is shared in editable. It is inconsistent and prevents portal users from easily accessing their documents. **In this commit:** - A new computed field shared_document_count added to project.task containing the number of shared_documents_ids. - A new stat button is added to project.task in portal view showing the number of shared documents and redirecting to shared documents page. task-3092925