Commit Graph
18015 Commits
Author SHA1 Message Date
Leonardo Pavan Rocha 7dd6e5d1a5 [IMP] calendar: revamp views
This commit changes how the calendar module calendar views look, as well as the
 quick create form view for adding a new event.

task-3455051
task-3389317

Part-of: odoo/odoo#138670
2023-10-23 20:07:23 +00:00
Leonardo Pavan Rocha 2afce22326 [IMP] web: start saving the calendar scale during sessions
This commit adds the feature of saving the calendar scale in the user’s session
storage. This allows the user to refresh the page and land in the same scale as
he had before. Also, if you switch apps, the calendar views will use the scale
saved in the session storage (unless a default scale is set using the mode
attribute).

task-3455051
task-3389317

Part-of: odoo/odoo#138670
2023-10-23 20:07:23 +00:00
dhrs-odoo 11c843b3d9 [FIX] web: fix user name overflowing
In this commit we have fixed that when we give long user name then in task list
view it was overflowing so we have added mw-100 in span and text-truncate in the
div element.

task-3248965

closes odoo/odoo#139180

X-original-commit: b10053bdfbc95e2f587b451c2b4337a96a3ddb27
Related: odoo/enterprise#49193
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
2023-10-23 17:48:54 +00:00
Mathieu Duckerts-Antoine 0ff4fa07cf [REF] web: use pseudo constructors to create (condition) trees
We define some helpers to easily create condition trees and use them
where it is possible.

closes odoo/odoo#139377

Signed-off-by: Michaël Mattiello (mcm) <mcm@odoo.com>
2023-10-23 13:11:23 +00:00
Mathieu Duckerts-Antoine bbf80b16c3 [REM] web: remove some unused search helpers
With a lot of legacy code removed and the introduction of the
SearchBarMenu component (https://github.com/odoo/odoo/pull/116641), some
search helpers have become unused. We remove them.

Part-of: odoo/odoo#139377
2023-10-23 13:11:23 +00:00
nda 25e4fcdd1d [FIX] web: disable export button during data export
steps to reproduce:
in a tree view export a large amount of data (or add a sleep in
/web/export/xlsx)

before this commit:
button is not disabled, allowing users to spam the button

after this commit:
button is disabled, informing the user that we're processing
his request

closes odoo/odoo#139392

X-original-commit: 56853574e10e8cf7d1dcec450db79d96d790f231
Signed-off-by: Bruno Boi (boi) <boi@odoo.com>
Signed-off-by: Nicolas Danhier (nda) <nda@odoo.com>
2023-10-20 23:37:51 +00:00
Sébastien Theys c955327c50 [FIX] account_edi, web, mail: add attachment delete in public tour
This allows better coverage of the feature and in particular its access
check.

Follow-up of https://github.com/odoo/odoo/pull/118701

closes odoo/odoo#139359

Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2023-10-20 23:37:46 +00:00
Hubert Van de Walle (huvw) a026a9e9b1 [FIX] web: missing pivot measures when using favorites
Steps to reproduce
==================

- Go to budget analysis
- Switch to the pivot view
- Unselect the first three measures
- Save the current search and set it as default
- In the measures dropdown, there is only two measures remaining

Cause of the issue
==================

- When `context.pivot_measures` is used, the measures are computed from
  it and those that comes from the metaData are missing.

opw-3544823

closes odoo/odoo#139315

X-original-commit: b11266cc377fa4753a0ee609258d9919f1ba5496
Signed-off-by: Julien Mougenot (jum) <jum@odoo.com>
Signed-off-by: Hubert Van De Walle <huvw@odoo.com>
2023-10-20 18:06:41 +00:00
Jorge Pinna Puissant 7adde63d69 [MOV] web,*: move record.js to model folder
This commit is part of a serie of commits which aims at simplifying and
reorganizing js files in the web addon

closes odoo/odoo#139156

Task-id: 3508223
Related: odoo/enterprise#49212
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2023-10-20 11:22:17 +00:00
Jorge Pinna Puissant ed3b4c5ab5 [FIX] web: clickbot set all filters
Since the new milk theme, the clickbot for click everywhere, didn't set
the filters on the views.

Now, the clickbot set all the filters on the views. This commit also add
a test suit, to avoid future downgrades. This commit transform the
clickbot to a module ES6.

task-id 3535596

X-original-commit: e2f531ec47e4f946cc37afee6b65531a637b5dfe
Part-of: odoo/odoo#139032
2023-10-20 11:22:13 +00:00
71c81e605b [IMP] *: expression edition
The PR https://github.com/odoo/odoo/pull/104741 have recently modify how the modifiers required, readonly,
invisible, and column_invisible are defined. They are now given by Python
expressions instead of domains. In this PR we introduce two main new
components ExpressionEditor and ExpressionEditorDialog that allow to
edit/view a Python expression in a way similar to what is done in the
DomainSelector/DomainSelectorDialog. For this we have extracted the main
logic found in DomainSelector and moved it to a new component TreeEditor
that is used by both ExpressionEditor and DomainSelector. For this we had
to add a new type of leaf we call "complex condition" that allows us to
represent indecomposable (sub)expressions, i.e. expressions we cannot
(or don't want) to express as conditions of the form (path, operator, value).

The main mappings allowing to transform trees, domains, expressions into
one another (when possible) are to be found in
@web/core/tree_editor/condition_tree.js.

closes odoo/odoo#136258

Related: odoo/enterprise#48512
Signed-off-by: Michaël Mattiello (mcm) <mcm@odoo.com>
Co-authored-by: Julien Carion <juca@odoo.com>
Co-authored-by: Mathieu Duckerts-Antoine <dam@odoo.com>
Co-authored-by: Christophe Matthieu <chm@odoo.com>
Co-authored-by: Pierre Pulinckx <pipu@odoo.com>
2023-10-20 11:22:05 +00:00
Adrien Schoffeniels 75868ae30e [IMP] web: rename "view_in_kanban" key in properties definition
Purpose:
--------
The "KanbanPropertiesField" has been renamed to "CardPropertiesField".
For consistency, the key "view_in_kanban" of the properties definition
is renamed to "view_in_cards"

Task-3458627

Part-of: odoo/odoo#132578
2023-10-20 11:21:56 +00:00
Adrien Schoffeniels c2ad855b26 [IMP] web: change kanban properties field to card properties field
Purpose:
--------
This commit rewords the "KanbanPropertiesField" to "CardPropertiesField"
and add it as widget to use for properties fields in calendar views.

The rationale is that the "Show in cards" option of properties should
allow to enable the visibility of properties in kanban cards and in
calendar popovers (as it is currently the case in knowledge).

Task-3458627

Part-of: odoo/odoo#132578
2023-10-20 11:21:56 +00:00
Adrien Schoffeniels b8b450544c [IMP] web: remove hideKanbanOption from properties field
Purpose:
--------
This commit removes the "hideKanbanOption" from the properties field.
This option allowed to prevent users to make properties visible on cards
(kanban cards and calendar popovers).
The rationale being that there is no reason to prevent users of adding
properties on cards now that they have been redesigned (see commit [1]).

Task-3458627

[1]: https://github.com/odoo/odoo/commit/25e8fbe0a1327c289df826cf6eb7882098a4c325

Part-of: odoo/odoo#132578
2023-10-20 11:21:56 +00:00
Rémy Voet (ryv) cae4e1b1cf [FIX] web: add fallback of display_name in formatMany2one.
Since https://github.com/odoo/odoo/pull/137098, we add a fallback for
false display_name in the form view, but we didn't add it for the list
view which doesn't instantiate the Many2one component. It uses
`formatMany2one` instead. Fix it to be consistent with the Many2one

closes odoo/odoo#139215

Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Signed-off-by: Rémy Voet (ryv) <ryv@odoo.com>
2023-10-20 09:35:23 +00:00
Rémy Voet (ryv) c3bbba7cdd [FIX] web: fix extraLines for false display_name
Since https://github.com/odoo/odoo/pull/137098, in
`Accounting > Bank > Tree View`, you get a traceback if one of the bank
statements in the view has a false as `display_name` (name is only
required in the view not in the model). The traceback comes from the
`extraLines` accessor in the Many2one component. The fix is the same
as in https://github.com/odoo/odoo/pull/138061 (FW of the first PR).

Part-of: odoo/odoo#139215
2023-10-20 09:35:23 +00:00
Michael (mcm) 8cf98fbe67 [IMP] *: remove core.bus
This commit removes the legacy global bus (core bus) and the places
where it was used.
The main users of this bus were the public widgets, they now use the bus
on Component.env.
Some of the uses were dead code and has been removed.

closes odoo/odoo#139076

Task: 3439226
Related: odoo/enterprise#49131
Signed-off-by: Francois Georis (fge) <fge@odoo.com>
2023-10-20 09:35:21 +00:00
Arthur Detroux (ard) 7594d71ca8 [IMP] *: remove jQueryUI draggable and droppable
*: mass_mailing, test_website, web, web_editor, website, website_event,
   website_sale

This commit removes jQueryUI draggable and droppable component to
instead use our own implementation of the feature. This replaces the
last use of the lib: the web_editor drag and drop. This takes advantage
of the code that was already written for other features of the backend.

task-3079246

closes odoo/odoo#136793

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2023-10-19 22:01:48 +00:00
Adrien Dieudonné 1158c45e4a [REF] *: remove .oe_left and .oe_right
The first intention of this commit was to remove ´@extend´ but
it actually makes sense to remove ´.oe_left´ and ´.oe_right´ classes.

Since grid we can avoid "float" elements (see .oe_subtotal_footer)
and we only have to remove this class.
For the other case, we have to use ´.float-start' and ´float-end´
to replace ´oe_left´ and ´oe_right´.

closes odoo/odoo#139199

Related: odoo/enterprise#49211
Signed-off-by: Pierre Paridans (app) <app@odoo.com>
2023-10-19 18:02:21 +00:00
Julien Mougenot 8b5c9723d1 [FIX] web: remove arrow from statusbar side dropdowns
This commit removes the caret from the statusbar side dropdowns as it
was not intended to appear and causes the buttons to be misaligned.

closes odoo/odoo#139168

Signed-off-by: Mathieu Duckerts-Antoine (dam) <dam@odoo.com>
2023-10-19 18:02:15 +00:00
FrancoisGe f0efa1dca8 [FIX] web, im_livechat: click twice on a record in a x2many
Before this commit, if you click twice on a record in x2many, two dialogs
are opened containing the same record.

Solution:
=========
Prevent a record from being opened as long as a record in this x2many
is already open.

How to reproduce:
=================
Go to a form view with an x2many
Click on the first record in the x2many
Click a second time on the record of the x2many (before the dialog is opened)

Before this commit:
-------------------
Two dialogs are opened with the selected record

After this commit:
------------------
Only one dialog is opened with the selected record

closes odoo/odoo#138984

X-original-commit: 31a9b13
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Signed-off-by: Francois Georis (fge) <fge@odoo.com>
2023-10-19 14:47:29 +00:00
Bastien PIERRE 38260f3262 [FIX] web: prevent command palette to lose focus
The command palette has the priority when useAutoFocus is call.
Like that, the command palette will not lose focus when clicking
on an app on the home menu and then directly opening the command
palette before the app mounting

TASK ID: 3338117

closes odoo/odoo#139124

X-original-commit: 660d27ac38c225559ea3697a24a34ac70ede8ec1
Signed-off-by: Florent Dardenne (dafl) <dafl@odoo.com>
2023-10-19 02:28:10 +00:00
Abderraouf Ghrissi (abgh) b9532e7549 [IMP] project: Improve ux
Before this commit:
- project.task > list view: Currently, the progress is displayed
in purple if less than 100% and in red if above. The two colors
don't contrast a lot, making it hard to read. In addition, it
is not coherent with the color we usually apply for the remaining
hours in the rest of the app.
- onbording tour: the manual saving step is no longer necessary
as records are now automatically saved. In addition, showing it
doesn't provide a wow effect and is an extra opportunity to lose
people in the process

After this commit:
- the following color code was applied for the progress bar:
*if progress < 80 -> green
*if progress is between 80 and 100 included -> orange
*if progress > 100 -> red

- step removed.

task-3475170

closes odoo/odoo#132854

Related: odoo/enterprise#46162
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
2023-10-18 18:27:25 +00:00
Hubert Van de Walle (huvw) b87e54bce4 [FIX] web: no_create option ignored for many2one + many2many_tags fields
Steps to reproduce
==================

- Install purchase_product_matrix,web_studio
- Go to purchase
- Click on a record
- Open studio
- Click on the "Products" tab > Edit List view
- Edit the product field
- Widget: Many2one
- Disable creation: enabled
- Close studio
- Create a new record
- Add a new line
- Type some random text in the product field

-> The option create is available

Cause of the issue
==================

When the can_create attribute is not passed, the `canCreate` ends up
undefined. This means the default value of true is used and the
`no_create` option is ignored.

The can_create attribute should actually be passed and there is a bug in
python in the `_editable_tag_field` function, but it is not something we
can change in stable due to the fact it it requires an explicit change
in some views to pass the validation and thus, this requires an addon
upgrade (`-u ...`).
See https://github.com/odoo/odoo/pull/138032

opw-3432903

closes odoo/odoo#139068

X-original-commit: 4b6756e1775488e230bc25767adf5744f0ea9149
Signed-off-by: Denis Ledoux (dle) <dle@odoo.com>
Signed-off-by: Hubert Van De Walle <huvw@odoo.com>
2023-10-18 16:52:06 +00:00
Dylan Kiss (dyki) 747a9fac78 [FIX] web: show branch hierarchy in switcher when no access to parent
Currently, when a user has access to a branch of a company, but not to
the company itself, the branch will not show up in the company switcher.
As a result, the user is not able to switch back to that branch when
logged in to another company.

To fix this, we now show the whole hierarchy of the branches you have
access to, disabling the companies/branches you don't have access to.

task-3503204

Part-of: odoo/odoo#138942
2023-10-18 12:05:25 +00:00
Mélanie de0f97e08e [FIX] Fix focus view with searchpanel
Before this commit, if a view contained a searchPanel the scrollbar went at the top automatically; now the behavior of the scrollbar with or without a searchPanel is the same.

closes odoo/odoo#138341

X-original-commit: b8f881de82ab931ed8bf45e67dd8b28f943e733f
Signed-off-by: Julien Mougenot (jum) <jum@odoo.com>
2023-10-18 12:05:13 +00:00
Pierre Rousseau 3d0a6c87fd [FIX] web: fix pager when using a many2many field
Before this commit, adding more records to a many2many field than the
limit of the pager did not update the pager. This commit fixes this
issue by updating the limit of the pager.

closes odoo/odoo#138883

Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2023-10-18 10:49:50 +00:00
FrancoisGe bb09cf76e3 [REF] *: remove legacy time.js
The purpose of this commit is to delete the legacy/js/core/time.js file.
We have therefore replaced all calls to time.js with the l10N/date.js utilities.

Part of task 3439226

closes odoo/odoo#138609

Related: odoo/enterprise#48918
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2023-10-18 08:56:06 +00:00
Zelong Lin 7ac121b54d [FIX] web,mail: correspondent can be null
Correspondent in thread can be null and lead into crash
when getting thread action and im status.

Replace correspondent with chatPartner when type is chat.

The fix is to solve the problem so that it is not blocking
systray and chatWindow tests related.

Also, this fix small issue of systray overflowing issue.

closes odoo/odoo#138913

Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2023-10-18 07:51:41 +00:00
Mathieu (mano) a036f69882 [FIX] web: document_layout color reset glitch
The color refresh button in the document layout configuration modal is
misaligned and moves the content when clicked

This commit adapts the CSS to have a proper absolute placement and
apply a height on the o_field_widget in this view to fix the issue.

task-3378759

part of: task-3326263

closes odoo/odoo#138774

X-original-commit: 907373d6e7556ecd17b0c0a87b3705e242f9d628
Signed-off-by: Pierre Paridans (app) <app@odoo.com>
2023-10-17 11:19:55 +00:00
mano-odoo 2495bfa725 [FIX] web: kanban card focus outline bottom
The kanban card do not display their outline on the bottom side of the
card. This is due to a negative margin (used to compensate for the
border bottom of the card).

This commit removes the border top if the kanban_record as a prior
kanban_record sibling, using its sibling border_bottom as its border
top and getting rid of the negative margin.

task-3488451

closes odoo/odoo#138772

X-original-commit: bf89d4ec951c77f5c7a01ccbad5edf0f7110f706
Signed-off-by: Pierre Paridans (app) <app@odoo.com>
2023-10-16 13:11:15 +00:00
Serge Bayet (seba) c584fa8de0 [FIX] web: correct the tiktok font url
This updates the relative url of the 'woff' font that was
one parent too far. Bug introduced in [1]

[1]: https://github.com/odoo/odoo/commit/47c5a092196054359d82edbc79dea0caf213dd9f

task-3477965

closes odoo/odoo#137710

Signed-off-by: Romain Derie (rde) <rde@odoo.com>
2023-10-16 13:11:09 +00:00
luvi cc0ca70428 [IMP] mail, web: call the installation prompt from the notification area
The NotificationItem component has been modified to support a new slot
allowing to display some content at the right of the notification item.
It is used in this commit to display an additional 'Install button',
inviting the user to click on the notification. Note that the entire
notification is still clickable, it is only a visual indicator.

Once the notification is clicked, the installation process is triggered:

- In case the system supports the native installation prompt, we now
display it, and the user is free to install the PWA from there.

- On Apple devices, a custom popup is displayed to the user, explaining
the steps to install the website as an application, since iOS and macOS
don't support a native prompt, and won't be using one anytime soon, since
it's a design decision from their side.

Some tests have been added to mock and test the display of the notification.
patchBrowserWithCleanup has been adapted to also remove any BeforeInstallPromptEvent
for every tests by default. This allows to test without the risk of issues with
messaging tests reading the number of notifications, or clicking the first
notification item when the service checks whether the prompt can be shown
or not (depending the availability of a native prompt, the OS, or the
localStorage, etc.).
To test the service correctly, you need to patch the test accordingly.

task-3275275

closes odoo/odoo#135866

Related: odoo/enterprise#48968
Signed-off-by: Pierre Paridans (app) <app@odoo.com>
2023-10-16 10:39:56 +00:00
Julien Mougenot 1c56280382 [IMP] web,*: status bar auto-resize
Before this commit, the status bar field could be displayed in 2 ways:
- in small screens: as a dropdown
- in larger screens: as an inline list of buttons

This commit centralizes both of these approaches into a dynamic display
that fits the available space:
- the current stage is always displayed;
- previous stages are displayed behind or contained in a dropdown if not
enough space;
- next stages are displayed behind or contained in a dropdown if not
enough space.

Task 3336856

closes odoo/odoo#124267

Related: odoo/enterprise#48706
Signed-off-by: Mathieu Duckerts-Antoine (dam) <dam@odoo.com>
2023-10-16 10:39:53 +00:00
Brieuc-brd b4e96e7230 [FIX] board, web: fix dashboard icon SVG
Prior to this commit the knowledge icon from the same dropdown was
turned into an inline-svg but the dashboard one was not.

This commit aims to use an inline-svg for that icon and ensure it
renders correctly.

task-3072562

closes odoo/odoo#138279

X-original-commit: 4df55bbc7bfe0bbe62605cd88887d45460814964
Related: odoo/enterprise#48734
Signed-off-by: Pierre Paridans (app) <app@odoo.com>
2023-10-16 09:21:17 +00:00
Odoo's Mergebot 60f6fa8fef [MERGE] web_hierarchy,hr_org_chart: add hierarchy view for employees and departments
Purpose
=======

The goal is to be able to have a hierarchy view to see the organisation of a company, that is, to have organisation chart for `hr.employee` model.
To do that, a new view will be introduced in `web_hierarchy` module, called `Hierarchy` view and it will first be used in `hr_org_chart` module for `hr.employee`, `hr.employee.public` and `hr.department` models.

Implementation details
----------------------

- A new python method will be introduced in the models when `web_hierarchy` module is 
  installed. That method, called `hierarchy_read`, is created to fetch the data for the
  hierarchy view when the view will be loaded.
- The definition of hierarchy view is inspired to the definition of the kanban, 
  that is, a template called `hierarchy-box` has to be defined in the arch to draw the card
  displayed in the node of the hierarchy view.
    - Some attributes can be defined on the `hierarchy` tag:
        - `parent_field` (default='parent_id') contains the parent field name 
          to use to fetch the parent record and to be able to fetch the hierarchy.
        - `child_field` (optional attribute) contains the child field name
          to use to find the child records (it is in fact the one2many field).
          If that field is defined then some queries can be avoided since we
          directly fetch the children when a read/search_read is done.
        - `icon` (default='fa-share-alt o_hierarchy_icon') icon displayed inside the 
          `Unfold` button (to show the child nodes) in hierarchy node.
        - `draggable` (default=False) True to allow the user to drag and drop a 
          node (= record) into a row or another node to update its parent node.

task-3376776

closes odoo/odoo#131162

Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2023-10-16 07:58:37 +00:00
Xavier Bol (xbo) 1048111a18 [IMP] hr_org_chart,web: define icon class on i tag for view button icon
Before this commit, the icon of the hierarchy view should be rotate
of 90 deg to have an appropriate icon for the view. The problem is
since the icon class is added on button classes, the button will
also be rotated with the icon instead of just the icon.

This commit defines a `i` tag inside the `button` element to select
the view to be able to apply css rotation only on the icon instead
of the whole button.

task-3376776
2023-10-16 08:17:31 +02:00
Xavier Bol (xbo) e28e1e5b25 [IMP] hr_org_chart,web: extend kanban compiler for hierarchy view
This commit extends the kanban compiler for the hirarchy view. Some
changes has been done in the kanban compiler to be able to reuse the
existing code.

task-3376776
2023-10-16 08:17:31 +02:00
Xavier Bol (xbo) adbcf6e1da [FIX] web: remove border-end-0 in search view
Before this commit, when search menu is not displayed in the
search view, then the border right is missing.

This commit removes `border-end-0` class added in the search view
to always have a border. Even with the search menu, it does not
seem to have an extra border.

task-3376776
2023-10-16 08:17:30 +02:00
Xavier Bol (xbo) c143f1dca2 [IMP] web: manage parent_of operator in domain in mockServer
Before this commit, `child_of` operator is managed in the mockServer
but not the `parent_of` one.

This commit manages `parent_of` operator in mockServer to be able
to find the record when the domain used contains that operator

task-3376776
2023-10-16 08:17:30 +02:00
Bruno Boi 25423820ed [REF] web,mail: add popover props: arrow,animation
Better API as the arrow was not displayed when the fixedPosition
prop was true, which is as we were mixing apples and pears.

And as for the animation prop, it permits to remove the hacky
"o-fast-popover" class usages.

closes odoo/odoo#135188

Signed-off-by: Michaël Mattiello (mcm) <mcm@odoo.com>
2023-10-13 21:11:52 +00:00
Bruno Boi b449ae6036 [IMP] web: improve usePosition API
**Before this commit**
The usePosition hook takes two arguments:
- the target element (could be a function returning an element)
- the positioning options, which are optional.

This API is a bit weird for these reasons:
- the target argument's type is variable
- the "popper" option is not very meaningful and has a
  default value of "popper", which is not clearly stated

**After this commit**
The usePosition hook now takes three different arguments:
- first is "refName", which is the reference to the element to position
  in the template
- then is "getTarget", a callback that must return the target element,
- finally the "options"

Part-of: odoo/odoo#135188
2023-10-13 21:11:52 +00:00
Pierre Paridans 35122d5c7c [REF] *: use raw CSS rules instead of extend utility classes
*:mail,portal,project,web

task-3546717

closes odoo/odoo#138615

Related: odoo/enterprise#48920
Signed-off-by: Adrien Dieudonné (adr) <adr@odoo.com>
2023-10-13 11:46:30 +00:00
Pierre Paridans daf05c241e [IMP] calendar,web: extract static CSS rules out of loops
This commit seperates the static and color dependent rules for the
Calendar view and app to avoid duplicating the static ones.

task-3546717

Part-of: odoo/odoo#138615
2023-10-13 11:46:30 +00:00
Aaron Bohy c5f92537fc [FIX] web: search view: evaluate invisible attrs
Since [1], invisible attributes on views are no longer evaluated
server-side. In search views, field and filter nodes can have an
invisible attribute which can be static ("1" or "True") or dynamic,
depending on the context (e.g. "context.get('something')"). Before
[1], in the arch received by the client, the value of the invisible
attribute was always static as "context.get(...)" expressions were
evaluated server-side. This is no longer the case, and we thus have
to evaluate the expression client side.

Before this commit, the invisible attributes in search archs were
simply ignored if they weren't static. This could be observed for
instance in Project > open a project: the "Private tasks" filter
was available even though it is dynamically invisible, and shouldn't
be there.

This commit ensures the invisible attributes are always taken into
account and evaluated.

[1] odoo/odoo@ba1a5509fa

closes odoo/odoo#138590

Signed-off-by: Mathieu Duckerts-Antoine (dam) <dam@odoo.com>
2023-10-13 11:46:28 +00:00
Pierre Rousseau 29e301fe32 [IMP] web: multi record selector: add keyboard navigation
This commit adds keyboard navigation to the multi record selector.

Part of task-id 3433922

Part-of: odoo/odoo#138464
2023-10-13 11:46:21 +00:00
Pierre Rousseau d949e001c9 [IMP] web: introduce useTagNavigationHook
Currently, the newly created component `MultiRecordSelector` (https://github.com/odoo/odoo/commit/bd0f2c6d799961b0a41222652eae7214c01dc5fe)
does not support the keyboard navigation between its tags (selecting or
deleting a tag). This behavior is currently implemented in the
`Many2ManyTagsField` component. This commit extract this behavior from
the `Many2ManyTagsField` component into a new hook that will be used by
the `MultiRecordSelector` component.

Part of task-id 3433922

Part-of: odoo/odoo#138464
2023-10-13 11:46:21 +00:00
Pierre Rousseau 78a859e0a1 [IMP] web: support placeholder for record selectors
This commit introduces the support for placeholder in record selectors.

Part of task-id 3433922

Part-of: odoo/odoo#138464
2023-10-13 11:46:21 +00:00
Michael (mcm) e062e6f483 [IMP] web,*: remove legacy env
This commit removes all the legacy envs (common_env, env, public_env)
as well as the files used to set up them.

task 3439226

closes odoo/odoo#138348

Related: odoo/enterprise#48781
Signed-off-by: Mathieu Duckerts-Antoine (dam) <dam@odoo.com>
2023-10-13 09:17:45 +00:00
Michael (mcm) 94824d8767 [IMP] *: remove legacy notification service mapper
This commit removes the mapper to the notification service and adapts
widgets that display notifications.

task 3439226

Part-of: odoo/odoo#138348
2023-10-13 09:17:45 +00:00