Numbers should be alinged on the right in rtl langauge same as ltr langs
Steps to reproduce the isse :
1- Change the language to arabic
2- To to the list of invoices in accounting and you can see that the numbers are aligned to the left
The origin of the problem is that rtlcss reverse the alignment from right to left
opw-3295573
closesodoo/odoo#122196
X-original-commit: 180139cd9244b6d6c7fc3b22e37d691215790359
Signed-off-by: Bruno Boi (boi) <boi@odoo.com>
Signed-off-by: Mahdi Cheikh Rouhou (macr) <macr@odoo.com>
Before this PR:
The only way to neutralize the database is running cli command neutralize
After this PR:
There is a new checkbox "neutralize database" in Duplicate database and Restore database dialog that neutralize the database after duplication/restore.
I also moved the neutralization code to the external module so it can be called also outside the cli .
closesodoo/odoo#122185
X-original-commit: 616740e9d09b3d0376be43ed1489e390f6f5823e
Signed-off-by: Julien Castiaux (juc) <juc@odoo.com>
In Knowledge, the scrollParent for the `Y` axis of an embedded ungrouped Kanban
view is the article body, which contains the draggable `container` (which is
itself contained in the scrollParent for the `X` axis).
This commit introduce 2 fixes related to the `draggable_hook_builder`:
- In `draggable_hook_builder`, `updateRects` was modifying values of the
`containerRect` from values of the `scrollParent`. Then, the `containerRect`
was used in `handleEdgeScrolling` to compute a scroll value to apply on the
`scrollParent`, and when updating the dragged element position, to compute the
boundaries for the dragged element. This commit stores values for
`scrollParent` in `scrollParentRect` alongside the modified `containerRect`.
`scrollParentRect` will be used to compute the scroll value based only on the
dimensions of the scrollParent, and the modified `containerRect` will be used
to compute the boundaries.
- The `scrollParent` in the `X` axis can be different from the `scrollParent` in
the `Y` axis. This commit stores both of them individually so that one is not
neglected when higher in the DOM than the other.
Task-3291771
closesodoo/odoo#122211
X-original-commit: 1f784652f9431c8716329f284133df215656c4b9
Signed-off-by: Julien Mougenot (jum) <jum@odoo.com>
Signed-off-by: Abeloos Damien (abd) <abd@odoo.com>
Steps to reproduce:
- Open Odoo on small screen
- Go to "Project" app
- Select project > Traceback
The Kanban progress bar's refactoring [1] didn't completely took into
account the fact that, on smaller screen, the "folded" columns aren't
actually folded (like on dekstop-like screen sizes) but instead their
records aren't loaded by default. As a result, in one case the progress
bar is shown (small screen) and in the other hidden.
As the progressbar's information is memoized in `getGroupInfo`, this
getter should have been called wherever those information are read.
This commit fixes the issue by properly calling the `getGroupInfo`
getter instead of using the "private" `_groupsInfo` object (which may
not yet have been populated, due to the memoization).
task-3336233
[1] https://github.com/odoo/odoo/commit/58ca40b03215ef4c6c575267494dc8bccc30a033closesodoo/odoo#122214
X-original-commit: c2efa7f059c92298ae5fb22b83e812453e2eb8ea
Signed-off-by: Pierre Paridans (app) <app@odoo.com>
If the button box exists but contains nothing (or nothing visible), it
will be displayed as the string 'null' in the control panel
This commit changes this behaviour to show nothing and remove the
culprit view (an invisible button should simply not be there)
X-original-commit: 0089b302bf30efb324c80f74f058d6d64f686e4c
Part-of: odoo/odoo#122111
The hover effect is rather strong and has low usefulness (the "chevron"
icon still appears) and can interfere with the current "sorting column"
decoration. We can safely remove it.
X-original-commit: f70fcbc8d1971c68546242c59caaae7f8481acf2
Part-of: odoo/odoo#122111
These tooltips contain very little information ("0 record", "2 records",
etc.) but their content usually have their own tooltips or title
attributes that interfere with this tooltip.
Remove them completely.
X-original-commit: 226829653495294044c2b88008e89a9cd2edffac
Part-of: odoo/odoo#122111
This commit removes a non-used, and non-tested method that was
mistakenly left on the progress bar hook.
closesodoo/odoo#122112
X-original-commit: 04c105fa244ea0a335023393e560153d669a7f2e
Signed-off-by: Bruno Boi (boi) <boi@odoo.com>
In previous commit (https://github.com/odoo/odoo/pull/119214),
this line was added to make the block onchange and check
if the view was rerendered correctly,
but having `await nextTick()` inside an RPC doesn't make sense.
So we use `makeDeferrer()` which is the tool provided for that matter.
closesodoo/odoo#122110
X-original-commit: a1056b1299f1edae736ea1ac00b6895e1c758104
Signed-off-by: Georis François (fge) <fge@odoo.com>
This commit removes whitespace below iframes in reports, which also caused an
unnecessary vertical scrollbar to appear.
task-3334745
closesodoo/odoo#122052
Signed-off-by: Bruno Boi (boi) <boi@odoo.com>
In this commit we add the makeServerError utility which allows you
to easily create a valid RPCError in the tests.
We have added this utility to prevent the use of invalid or incomplete
errors. We will give default values for all the parameters needed for
a valid RPCError.
For example, in some tests, we only check the presence of an error
dialog and not the expected one. So there was a set of tests that were
green because the failure was in the RPCError handling. So we had an
error dialog but it was not the right one. In general, the crash occurred
because the RPCError contained no data.
closesodoo/odoo#121932
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Since the attachement viewer was moved to core, this renames it to file
viewer to decouple it from the Attachment model/concept from the mail
module.
Part-of: odoo/odoo#119625
The `mail` module's `attachment_viewer` is useful for more than `mail`
alone. In order to be able to use it in the `web_editor` module (which
doesn't depend on `mail`), we move it to the `web` module.
task-3109331
Part-of: odoo/odoo#119625
As the ChromeBrowser API was simplified in 2b0d9fa6a9, the
terminate_browser method was removed but the shiny author forgot to
remove the call in the click_everywhere test.
closesodoo/odoo#122038
Signed-off-by: Xavier Morel (xmo) <xmo@odoo.com>
This issue only occurs on Firefox because ´has´ is not supported
and the following rule is not applied:
https://github.com/odoo/odoo/commit/2cd0106e63785dd34553c2b4747d72b93b9a7afd
Anyway, there is an existing css rule that is applied if the field
class is correclty added.
Steps to reproduce:
- Open Sale
- Add some content in the sale order line
opw-3201461
opw-3285854
opw-3266130
opw-3244581
closesodoo/odoo#121979
X-original-commit: add1df806157c074fd1a3224d1d8bdf1922481fb
Signed-off-by: Pierre Paridans (app) <app@odoo.com>
Prior to this commit, the color of the tooltip arrow didn't match the
popover background when it was a tooltip (white arrow and black popover
content).
However, the css adaptation was already present in `tooltip.scss` using
the css variable `--popover-arrow-color`, but the selector wasn't
correct since the arrow was always BEFORE the content.
This commit fixes the issue by placing the arrow after the popover
content.
task-3329927
Part of task-3326263
closesodoo/odoo#121975
X-original-commit: 0f1fb80ac6e36b8230ffaf3c7c2608d527b451a2
Signed-off-by: Pierre Paridans (app) <app@odoo.com>
Have a record with a field displayed with the aceField.
That field should have a value of false (ie: unset).
Display that record on a form view.
With the pager, go on to the next record.
Before this commit, a write was triggered because the aceField considered itself as changed
even though we did not do anything.
This was because the value of false was compared to the ace value (empty string) when leaving the record.
Being different, this triggered the current record to be updated and saved.
After this commit, a false value is locally transformed to the empty string when checking if the field has
some changes. Hence, there is no write triggered.
opw-3326914
closesodoo/odoo#121969
X-original-commit: 74e8d60a6ae19199ae5d0f9d66ca0748f068782f
Signed-off-by: Lucas Perais (lpe) <lpe@odoo.com>
Initialize a DB. Install website when it is initialized.
Launch tests of the class TestBaseDocumentLayout
Before this commit, there was a crash because those tests render the report_layout and its
assets.
The full explanation is that, the module website adds an ir.asset `website.s_badge_000_variables_scss`
that the report wants to fetch. But, the class of tests is executed at_install. Given the topological order
and the order of the modules installation, website is not in the registry at that point, but the ir.asset is retrieved
from the database.
The ir.asset algorithm determines at that point that `/website/` is not an admissible path and raise an exception.
This commit solves the problem by tagging this class of test "post_install" and not "at_install".
runbot-error-21203
runbot-error-21204
runbot-error-21205
runbot-error-21206
runbot-error-21207
runbot-error-21208
runbot-error-21352
runbot-error-21353
runbot-error-21354
runbot-error-21355
runbot-error-21356
runbot-error-21357
closesodoo/odoo#121998
X-original-commit: 48b833513ac8f76febbc4ca7b935260d7ea85522
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Signed-off-by: Lucas Perais (lpe) <lpe@odoo.com>
Currently, only stable releases see their translations updated. This has
resulted in master accumulating outdated stuff for years, which can be
confusing for users testing master on runbot.
This one-shot commit resynchronizes master translations based on the
content from 16.0 and removes empty PO files (i.e. no longer containing
translations).
closesodoo/odoo#121629
Related: odoo/enterprise#41171
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
Steps to reproduce the issue:
1. Go to any of the contacts with partner ledger option.
2. Make the browser window small and observe the text in the partner ledger button box.
Current Behaviour:
The text in the button box does not get ellipsized, rather stays the same and may get out of the button box if the box becomes smaller
Desired Behaviour:
The text in the button should be ellipsized
OPW-3266235
closesodoo/odoo#121167
X-original-commit: ec642f9caba7c6a7a21d9e65ffa0e305ff06678d
Related: odoo/enterprise#40948
Signed-off-by: Adrien Dieudonné (adr) <adr@odoo.com>
Signed-off-by: Pierre Paridans (app) <app@odoo.com>
Before this revision, when you pass `context` in the arguments
of a JSON routes, this one gets automatically injected
in the environment context.
This is not the case for regular HTTP routes.
It makes sense to propagate the context for the JSONRPC protocol,
JSON routes used by the backend, such as `call_kw`,
but it doesn't make sense to pass this context automatically
for any other kind of routes, such as front-end routes
or routes used by custom Javascript widgets.
This change brings a more unified behavior for routes
of types HTTP and JSON.
In addition, most developers were not aware of this "feautre",
that passing `context` in the arguments of a JSON route leaded
to the injection of this context in the environment context.
This is actually reflected by the diff size this changes required,
only a dozens of routes needed to be adapted, to manually
add the context in their route arguments and to inject it
in their environment context.
closesodoo/odoo#121726
X-original-commit: a7a5655631e6d5b05fd2ba3d0c80617aae6d9cfe
Related: odoo/enterprise#41229
Signed-off-by: Denis Ledoux (dle) <dle@odoo.com>
There is no notification telling which field are invalid when we try to
save a form in a dialog
Steps to reproduce:
1. Install Survey
2. Go to Survey and open any survey
3. Add a question in the survey and try to save it (without entering a
title)
4. There is no notification. Although the invalid field is highlighted
in red, it could be tricky to see it if the field is in a tab
Solution:
Create a method in Record that sends the notification and call it when
the record is not valid in X2ManyFieldDialog
opw-3196166
closesodoo/odoo#121705
X-original-commit: 58f89915c0ad447f0c5896739219f0812cfd4a6a
Signed-off-by: Guillaume Merlin (megu) <megu@odoo.com>
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
One of the most costly part of a page loading when the ormcache is cold
is computing the assets node, the unique identifier of an attachment to
validate whether the existing attachment is still valid with the current
version of the static files.
This operation needs to glob assets path in the filesystem,
get the modification date, check attachments, ...
Right now this task is not really optimized and can take some time
because of an excessive number of glob on the filesystem, unnecessary
exists to define absolute path, double computation of file list and
modified times when getting js and css bundle separately, ...
A list of modifications mainly discussed in the pr message are made
with this commit to speedup things.
- split css and js unique
- prepare api for an in memory glob
- change api to propagate absolute path and meta information through
`ir.asset._get_paths`-> _get_asset_paths -> `_get_asset_content` ->
`AssetsBundle`
closesodoo/odoo#121159
Signed-off-by: Xavier Dollé (xdo) <xdo@odoo.com>
Purpose
=======
Never select the white color for the properties tags, it should be
selected manually, because usually the white color is used to not show
a tag in the kanban view (and that color is never automatically
selected for normal many2many_tags widget).
Fix the alignment of the property label.
Task-3208449
closesodoo/odoo#114200
Related: odoo/enterprise#38944
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
Purpose
=======
Like standard avatar widget, we want to open the chat window of a user
when clicking on a many2many / many2one avatar property.
Task-3208449
Part-of: odoo/odoo#114200
Steps to reproduce:
In the kanban view of projects, modify the `is_favorite` field
of a project and apply the "My Favorites" filter.
Cause:
No change is saved.
Solution:
Add autosave for the boolean favorite field.
opw-3291991
closesodoo/odoo#121499
X-original-commit: d1d6f016331c69441c9d3ec7927ed7224c06feec
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Signed-off-by: Lefebvre Thomas (thle) <thle@odoo.com>
Steps:
Material Resources list view.
On a record, set roles A and B, default role A.
Now, delete role A from roles.
Issue:
Default role should be set to B, but remains A.
Cause:
The onchange return the right response.
The StaticList data is updated properly.
The issue is that this function is async, and we don't wait
for all that to be done before notifying the model.
Fix:
Wait for the result (await).
task-2959882
closesodoo/odoo#119214
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
There is no action that uses the search models/components available in
the legacy control panel. We remove those.
closesodoo/odoo#121433
Related: odoo/enterprise#41078
Signed-off-by: Géry Debongnie <ged@odoo.com>
1. Display avatar in top bar next to channel name and description.
2. Edit icon appears on hover.
3. Clicking on the Edit icon opens file browser to upload a new avatar.
4. Certain file types are allowed.
5. Avatar can only be changed for group chat by any member of the channel.
6. For channel it can be done with admin rights.
7. Disable uploading text from file uploader in this case.
Also show avatar of channel/chat conversation in chat window.
Author avatar in message list no longer shown im status.
Chat window header color matches new systray color.
task-2684679
[FIX] mail: make chat window header match systray color
Part-of: odoo/odoo#117357
In 14.0 the menu items in the navbar sections menu could have any level.
Since the webclient refactoring landed in 15.0 0573aca this feature has
been unintentionnally limited to two levels.
More sub menus would simply not be displayed.
**Before this commit**
- Have a menu item with the following path:
`App/Menu/Group/Sub-group/Item`
- The `Sub-group` is displayed as an item. It is clickable but nothing happens.
- The `Item` is not displayed.
**After this commit**
Works properly as it should. See screenshots on the PR description.
closesodoo/odoo#121422
X-original-commit: 708d17ba3a9d12e153069ecb7ae6c8e3d6187dd0
Signed-off-by: Mathieu Duckerts-Antoine <dam@odoo.com>
Signed-off-by: Bruno Boi (boi) <boi@odoo.com>
Co-authored-by: Mathieu Duckerts-Antoine <dam@odoo.com>
This test has been adapted by the milk PR, but it only passed with
all modules installed, because it relied on some items added to the
action menu. This commit makes it more robust by changing the
selector to target the "Delete" item.
closesodoo/odoo#121435
Signed-off-by: Romeo Fragomeli (rfr) <rfr@odoo.com>
pos*: point_of_sale, pos_restaurant, pos_sale
Previously the pos would rerender the entire UI when the window was
resized. In practice, most components do not care about the size of the
UI for their rendering, and so we're doing a lot of needless work, and
also using an owl feature (deep renders) whose perennity is not certain
(we may want to remove the ability to do deep renders completely in the
future).
This commit changes the pos code to use the ui service `isSmall` field,
makes the ui service reactive so that components can subscribe to
changes inside of it with `useState`, and makes the ui service update
its internal state at most once per animation frame, instead of after
100ms without resizing, so that resizing the viewport results in a
smoother user experience.
closesodoo/odoo#121343
Signed-off-by: adgu-odoo <adgu@odoo.com>
This PR aims to change the target of the email widget to _blank. Indeed depending on
your mail provider, it can open the mail editor in your current tab and might not be
practical for the user if he needs information that was present on the previous tab
to compose the mail.
task-3324948
closesodoo/odoo#121277
Signed-off-by: Luca Vitali <luvi@odoo.com>
The fact that callback recorders are put in the env by the action
service has a serious disadvantage. A view using itself some View component
can have easily its own local state and global state polluted by that
subview (views use useSetupView). This would lead to very subtle
problems hard to detect and understand. Moreover, we view the callback
recorders as rather technical stuff and we would like the developers not
to have to think about them. For that reason we pass the callback
recorders as (optional) props to the View component that make them
available in the env. Note that the situation remains unchanged for
client actions (we do not have a View analog component for the actions).
closesodoo/odoo#121050
Related: odoo/enterprise#40901
Signed-off-by: Géry Debongnie <ged@odoo.com>
When importing data and checking the possible values of a field,
clicking on one of the records to open it throws an error
Steps to reproduce:
1. Install Projects
2. Go to Project > My Tasks and trigger the list view
3. Select any record and export it (check the import-compatible export
option)
4. Open the exported file and modify the `project_id` to a non-existing
project name
5. Click on Favorites > Import records
6. Upload the modified file and click on 'TEST'
7. In the `project_id` field, click on 'See possible values'
8. Click on any project, an error is thrown
Solution:
Prevent the form from being opened when the action is in target "new"
Problem:
Opening the record in a target new throws the error `switchView
called but the current controller isn't a view`
opw-3161777
closesodoo/odoo#121384
X-original-commit: 63d43713ea5b2efba2e63b1735954bb2069bc6f4
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Signed-off-by: Guillaume Merlin (megu) <megu@odoo.com>
== ISSUE ==
The search component is using a `.bg-200` class which renders a grey
darker than the one of the `o_web_client`. Since we already define
a `background-color` for the web client, we do not need a custom one
on top of it.
== After this commit ==
We remove the `bg-*` class applied to the element so it matches the
`.o_web_client background.`
task-3326289
part of task-3326263
closesodoo/odoo#121347
Signed-off-by: Pierre Paridans (app) <app@odoo.com>
The aim of this commit is to remove the specific complexity of the
kanban's progress bar from the relational model, and put it into the
kanban view itself.
This commit prepares and is part of the task that aim to refactor the
relational model and migrate it to owl.
part-of task-id 3179751
closesodoo/odoo#119781
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Co-authored-by: Aaron Bohy <aab@odoo.com>
In this commit, we add the list of rpc calls done in the progress bar
tests, this is done to avoid to add more rpc's doing the refactoring.
Part-of: odoo/odoo#119781
Commit [1] commented the second half of a pivot test (I guess it
was done to debug it, and we forgot to uncomment it afterwards).
This small diff was then lost in the huge diff of the Milk PR.
This commit re-enables the full test, which luckily still pass.
[1] odoo/odoo@a1e05c8357closesodoo/odoo#121346
Signed-off-by: Pierre Paridans (app) <app@odoo.com>
Before this commit, when the user wants to self assign to a task for
instance, he has to write his name to be able to select himself.
This commit displays the current user first in the result of
`name_search` (the method called by relational widgets in JS).
If the current user does not satisfy the search condition then
he will not be in the result of the `name_search`.
task-3291745
closesodoo/odoo#121146
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Before this commit : The library underscore.js and
underscore.string.js were used in the ODOO solution.
After this commit : Every usages of a function from
underscore.js lib has been replaced with native javascript.
The goal is to remove all usages of underscore.js and to
not use anymore this library in ODOO.
---
TaskId : 3246238
closesodoo/odoo#120437
Signed-off-by: Géry Debongnie <ged@odoo.com>
== ISSUE ==
If you go to the Payroll Module, you can see that the checkboxes on the
main dashboard have a different color for the `background`
and the `border`.
This is due to inconsistencies in the color theme.
There was also an issue with the checkboxes in Accounting.
If you go to Accounting > Configuration > Currencies
and hover a checkbox, the checkboxes have a different background than
the one in Payroll which is not consistent.
== After this commit ==
The `background` and `border` color of the inputs are set
to the enterprise one. We also handle this in dark mode.
task-2818586
Part-of: odoo/odoo#116641
[FIX] *: selectors in tours
[FIX][TMP] account: CogMenu selector in tours
[FIX][TMP] web*: Breadcrumb targetting in tours
Adds a `o_breadcrumb` class to target the whole breadcrumb, no matter
how much elements it contains (collapsed parts, visible path, single
name...).
add classname on last breadcrumb item
[FIX][TMP] project: View buttons selector in tours (moved away from CP)
[FIX][TMP] project: Kanban selectors in tours (quick create)
[FIX][TMP] *: SearchBar selectors in tours (toggle menu)
[FIX][TMP] *: ButtonBox selector in tours
[WIP][IMP] web: add toggleSearchBarMenu in search helpers
adapt and unskip 3 list tests
adapt and unskip calendar tests
unskip web_tour test that actually pass
post rebase fix
allow to lose cell focus after multi edition (given to searchbar) - bug reported, to check later
post rebase fixes
fix
Part-of: odoo/odoo#116641