* use the latest translation API (with fallback on english text if
translation doesn't include expected placeholders)
* indent/split translations to avoid excessive line lengths
closesodoo/odoo#91743
Signed-off-by: Julien Castiaux <juc@odoo.com>
The pa index should only be XXXXXXX when the foreign partner is not
identified. In this commit we change the condition on the template such
that if the pa index is defined, we always utilise it. If the pa index
is not defined but the partner is italian, we use '0000000', and when it
is not defined and the partner is not italian, we use 'XXXXXXX'.
closesodoo/odoo#91871
Task-id: 2858092
X-original-commit: bf468affa2d86967b3b63a0be62063061b7b263c
Signed-off-by: Josse Colpaert <jco@odoo.com>
Signed-off-by: Daniel Kosky (dako) <dako@odoo.com>
Add move_reverse_cancel=cancel back to context when reconciling moves with reverse moves.
Bug introduced in commit https://github.com/odoo/odoo/commit/e9262bfc8c775953ebe150f36ce0ab8dcb04d4bd
Database : Reproducible in v14, v15
On a Mexican company (with l10n_mx) with multi currencies enabled.
- Set rates for USD to be different at invoice and at payment date
- Create an invoice at date 1 in USD
- Create a payment at date 2 in USD for invoice generating a difference exchange move
- Try to reset the payment to draft
-The traceback (ZeroDivisionError: float division by zero) will appear.
Tickets : 2857549, 2856162, 2855038, 2852663, 2852859, 2857381
closesodoo/odoo#91841
X-original-commit: 7be0fc1d611d54f27ebd7e7b1fef9b1842cc9ae2
Signed-off-by: William André (wan) <wan@odoo.com>
Signed-off-by: de Wouters de Bouchout Jean-Benoît (jbw) <jbw@odoo.com>
Since Chromium 97, folded `<details>` content has non-zero computed
width and height which returns false-positive QUnit
`assert.isNotVisible()` calls.
In a nutshell, this was introduced in https://bugs.chromium.org/p/chromium/issues/detail?id=1185950
when Chromium implemented the ability for "Find in page" to search in folded
`<details>`. To do so, the `content-visibility` rule was used instead of
`display: none` which, even if functionally similar, has an impact on the
values returned by `getBoundingClientRect()` (i.e. used in
`assert.isNotVisible()`.
A regression report was filled in https://bugs.chromium.org/p/chromium/issues/detail?id=1276028
to highlight this change of behavior. What emerged from this report's
discussion is that Chromium has no intent to revert this change and
instead put the emphasis on avoiding to use `getBoundingClientRect()`
and similar methods for visibility check (even pushing a proposal for a
`Element.isVisible()` API; cf. https://github.com/w3c/csswg-drafts/issues/6850).
This commit works around this issue by forcing the content to `display:
none`, like in the previous Chromium versions.
closesodoo/odoo#91833
X-original-commit: b718e7eb5ceb827f59ac395577408b7bc54aa3f9
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Signed-off-by: Pierre Paridans (app) <app@odoo.com>
Purpose of this commit to improve generic usage of project
app.
So, in this commit done following changes:
- change the placeholder of the name to 'e.g. Monthly review' in
project_update_view_form
- set the 'analytic account' of the project on the tasks by default
- change the placeholder to 'e.g. Product Launch' in project_milestone_view_form
- the 'cabinets' milestone should be linked to a milestone service,
not a manual one so change data to milestone in demo data
- rename the 'rating' stat button into 'last rating' in view_task_form2
- set another employee than Mitchell for the 'customer care (prepaid hours)'
SOL field in sale_service_demo_data
- display a separator on the right of the stat button so remove unwanted
properties in project_rightpanel.scss
- add the 'name' field to the 'fields to export' when 'i want to update data'
is set to true
- remove the 'Getting Things Done (GTD)' example from kanban examples wizard
- add a 'tasks due today' filter that should return tasks whose deadline falls on
today's date in view_task_search_form
task-2809188
closesodoo/odoo#88271
Signed-off-by: Laurent Stukkens (ltu) <ltu@odoo.com>
Profiling: creation of ir.profile records for each models population
Rollback: allow triggering multiple times the same population,
without any risk of records conflicts (& having to recreated a clean database)
Note: those two options are mostly recommended for small models population.
Indeed, profiling slows down the population, and large/medium population is
already quite slow for some models (and it seems that the rollback breaks as well
for some advanced models).
Part-of: odoo/odoo#85537
When moving some products between two warehouses thanks to an internal
transfer, the forecasted inventory becomes incorrect
To reproduce the issue:
1. In Settings, enable "Multi-Warehouses"
2. Let WH01 be the existing warehouse. Create a second one WH02
3. Create a storable product P
4. Update the quantity of P:
- 3 in WH01/Stock
5. Create a planned and internal transfer T:
- Source: WH01/Stock
- Destination: WH02/Stock
- Ignore the warning
- Operations:
- 1 x P
6. Mark T as todo
7. Open the Forecasted Inventory:
- Filters:
- Forecasted Stock
- Product: P
- Group By: Warehouse
Error: The report is incorrect, it says there are 3 P in WH01 and 0 in
WH02 (should be 2 and 1). It becomes worst if T is done (the quantities
in the past become incorrect)
We should be able to move a product between two warehouses thanks to an
internal transfer (so the warning of the step 5 should be removed).
Moreover, the `report.stock.quantity` should consider that use case.
When processing a stock move, the SQL view translates it as an in-move
or out-move for a specific warehouse. For instance, if the SM comes from
a warehouse and goes to a location without any warehouse (e.g., customer
location), the SM is considered as an out-move. But here is the issue:
in case of an inter-warehouse SM, both source and destination have a
defined warehouse.
Therefore, we need to:
- Duplicate the inter-warehouses SM (so we have one in and one out)
- Fake the values (no destination warehouse for the out move, no source
warehouse for the in move)
Also, before duplicating all SM, we filter out some useless SM:
- Draft and cancelled ones
- SM done more than 3 months ago (because the report only works for [-3
months; +3 months])
Considering some tests:
(SM are confirmed. Each test has been repeated 5 times to get an
average)
| | |
|:-------------------------------------:|:--------:|
| 5000 SM, 0% inter-wh, without the fix | ~715 ms |
| 5000 SM, 0% inter-wh, with the fix | ~710 ms |
| Impact | 0.99x |
| | |
| 6666 SM, 0% inter-wh, without the fix | ~911 ms |
| 5000 SM, 33% inter-wh, with the fix | ~999 ms |
| Impact | 1.10x |
| | |
| 7500 SM, 0% inter-wh, without the fix | ~1004 ms |
| 5000 SM, 50% inter-wh, with the fix | ~1097 ms |
| Impact | 1.09x |
The impact is not that significant
OPW-2752017
task-2822157
closesodoo/odoo#91772
X-original-commit: b1efc0243bbf886bbef42a32587f4a818fa34e64
Signed-off-by: Arnold Moyaux <arm@odoo.com>
Signed-off-by: Adrien Widart <awt@odoo.com>
When creating a quiz, the answers were not displayed in the
many2many_tags and void tags were displayed.
This commit ensures that the answers is always displayed even
if the record is not yet created.
task-2849896
closesodoo/odoo#91770
X-original-commit: d9223a280ad386e671359a9633efddf424b371d6
Signed-off-by: Warnon Aurélien (awa) <awa@odoo.com>
Until now, when we add to patch the ui size, we would have patched one of the following:
- config.device.{isMobile,size_class}
- (wowl) env.isSmall / env.services.ui.{isSmall/size}
- (legacy) env.device.isMobile
- (legacy/wowl) browser.innerWidth
The issue is that patching one does not affect the others resulting in an incoherent state.
In order to ease ui size patching, the `patchUiSize` method has been introduced. This method
take either a size or a width as parameter (eg. SIZES.SM, 1920) and affect all the properties above.
task-2582313
closesodoo/odoo#91540
Related: odoo/enterprise#27428
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Improves UX by adding placeholders to clarify the purpose of some inputs and
changing some field layout to ease the edition (with the use of multi-lined
editor).
Details:
Some placeholders have been added:
- description field of survey.question
- default_note field of mail.activity.type
- summary of mail_activity_type_view_form
Some field layout have been turned into multi-lined editor:
- default_note field of mail.activity.type
- write a message in mass mail mode (email_compose_message_wizard_form)
added border for field help of edit action (class oe-bordered-editor)
Task-2766291
closesodoo/odoo#85046
Related: odoo/enterprise#24599
Signed-off-by: Warnon Aurélien (awa) <awa@odoo.com>
Prior to this commit an user could try to add a product to cart that does not
exist anymore because it was deleted while the user /shop page wasn't refreshed.
This commit avoids this (rare) use case to happen.
TaskId-2835736
closesodoo/odoo#91752
X-original-commit: 7aeec2921d7159f0c7fa4c8caf2d00f802c69264
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
Signed-off-by: William Braeckman (wbr) <wbr@odoo.com>
Steps to reproduce:
- Have two companies set up
- In settings, check for company 2 the Files Centralization
- For a Product, upload a document
Issue:
The document will not appear in Documents.
It will only appear if the option is checked for company 1
Cause:
The company_id is not fetched correctly throughout the process.
There is a similar solution for the specific `documents` upload route:
https://github.com/odoo/enterprise/blob/bdf712d66c3e5cee70a6b424b69a618fe655a39f/documents/controllers/main.py#L147-L149
Solution:
Get the id directly from the cookies
opw-2774365
closesodoo/odoo#91751
X-original-commit: 46db92d5211c215d07448676e619154390b7147f
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
Signed-off-by: yosa-odoo <yosa@odoo.com>
Revert the possibility to install languages from the form views
of opportunity/lead and partner.
We consider that the quick installation of languages is too
advanced and admin people can go through the dedicated menu if
need be.
task-2839020
closesodoo/odoo#91750
X-original-commit: 5a616997659b2359ec946883b620e2fae6d6c39d
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
This commit adds a unit test to check if the value of
`analytic_account_balance` field in a project is the one expected when a
timesheet is added into this project.
The analytic account balance value expected should be equal to
`timesheet_cost * timesheet_unit_amount * -1`, where:
- `timesheet_cost`: the employee cost or the cost set on an employee mapping
defined in the project.
- `timesheet_unit_amount`: the number of hours/days set on the timesheet.
task-2783686
closesodoo/odoo#87405
Related: odoo/enterprise#25006
Signed-off-by: Laurent Stukkens (ltu) <ltu@odoo.com>
This fix will try to write a new amount value on the tax when an
invoice is created from POS, that will raise a user error preventing the
creation of the order.
This reverts commit 2b9592cb0ecef235d708ed7810d0613ccd946124
OPW-2855694
closesodoo/odoo#91719
X-original-commit: d3cce0e3ae13859954d6907a3cb16fb0e1a95f86
Signed-off-by: Masereel Pierre <pim@odoo.com>
Before this commit, iframes DOM mutations were not taken into account to
update the tour manager. So in the context of mass_mailing, displaying
the web editor in an iframe, the tours were updated at the right moment
by chance (no mutations for 750ms in the global document and in the
iframe document).
This commit adds an o_iframe class, used to define an iframe that will
render a part of Odoo. An observer is added in the tour service to
monitor the addition of such iframe, and sets an observer on that iframe
to correctly update the tour manager, counting the iframe DOM mutations
for the 750ms delay.
In addition to this observer, the iframe's HTML content is added to the
final document HTML log when a tour crashes (directly between the
<iframe></iframe> for convenience, copy/pasting it in a browser just
ignores what's in between).
Also, when the tour_service is initialized in an o_iframe, it will not
run the tours.
This fix targets the saas-15.3 as it is needed to avoid a race condition
introduced with [1] (introducing a tour which relies on DOM updates
inside the mass mailing iframe). This could be backported if the need
ever rise (it should really have been the case since [2]).
[1]: https://github.com/odoo/odoo/commit/52d32e26c34bef10823582ef5c1f840492b73d7a
[2]: https://github.com/odoo/odoo/commit/971629b9fe40911c3a9765c9fb746ea1c55d3560closesodoo/odoo#91718
X-original-commit: ea35bd06c84b7101224c3b3dd24d1780e13232a9
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
There is 2 issues regarding the responsiveness of the cookiebar:
==== Problem n°1: ====
======================
By default, `.modal-dialog` receive a O.5rem margin.
```css
.modal-dialog {
margin: 0.5rem;
}
```
But it only takes effect in small resolution, as starting from SM (576px,
see _breakpoints.scss), the margin is set to 0. `.modal-dialog` receive:
```css
@media (min-width: 576px)
.modal-dialog {
margin: 0 auto;
}
```
On top of that, the `.modal-dialog` has a `min-height` of 100%, which is
getting too big in XS, as there is a 0.5rem margin, which adds up on top
of the 100%
```css
.s_popup[data-vcss='001'] .modal-dialog {
height: auto;
min-height: 100%;
}
```
It results in a modal height bigger than the screen size, ultimately
creating a scrollbar for just a few pixels (2 * 0.5rem margin), making
the cookies bar partly hidden by the screen.
==== Problem n°2: ====
======================
The buttons from the cookies bar "discrete" template are simple `<a/>`
elements inside a `div.col`.
Those links have no bottom margin like a paragraph would have.
In LG screen, it is fine as the col containing those links is next to
the other col containing the paragraph which adds the margin bottom,
making elements not stuck to the bottom edge of the screen:
------------------------------
| COL-LG | COL-LG |
| <p/> | <a/> <a/> |
| | <-- bottom margin set on <p/>
------- screen edge ----------
But in lower resolution, as both col would be on top of each other, the
`<a/>` would be stuck to the bottom screen border.
--------------
| COL-LG |
| <p/> |
| | <-- bottom margin set on <p/>
--------------
-----------------
| COL-LG |
| <a/> <a/> | <-- Against the screen bottom edge
-- screen edge --
======================
Steps to reproduce:
- Install Website
- Enable cookie bar in the Settings
- Go on the Website with a mobile screen width
opw-2784233
closesodoo/odoo#91712
X-original-commit: 843e57694dd73ed4b7fca0460a4cf9b166820843
Signed-off-by: Romain Derie (rde) <rde@odoo.com>
Signed-off-by: Claude Thibault (thcl) <thcl@odoo.com>
Co-authored-by: thcl-odoo <thcl@odoo.com>
How to reproduce:
Have 2 different tabs open on the same draft invoice
Tab 1: add a new invoice line
Tab 2: change the partner
Tab 1: save
Tab 2: save
Before the fix:
The new invoice line from tab 1 has the partner from before the change,
but the other lines have been updated to the new partner.
Expected:
All invoice lines have the same partner as the invoice itself
This use case can be reproduced like this manually, but it can happen
easily even on one tab because the OCR acts like the second tab if users
start to edit the invoice before it is scanned.
Note that in a perfect world, a warning would be raised to prevent any
loss/mischief due to concurrent editions of the same record but that's
beyond the scope of a bugfix made on a stable version.
opw-2777390
opw-2762347
opw-2741859
closesodoo/odoo#91705
X-original-commit: 2c5450af8d6f5934e6ab2095c3307b432fa3036a
Signed-off-by: William André (wan) <wan@odoo.com>
If applied, this commit will fix the following bug by fixing
the url used to ping the server
Steps to reproduce:
1- open apps with debug mode
2- click on updates
3- the server is read as if it is offline
Bug:
in ecfe85db84 all links are changed
static/src/(img|fonts) => static/(img|fonts) however in this specific
case the server is remote
(https://apps.odoo.com) and it still needs /src/
Fix:
add /src to the url
OPW-2791531
closesodoo/odoo#91112
X-original-commit: bf629cf3063119a5c819f74329a51a0e1a7c172f
Signed-off-by: Géry Debongnie <ged@odoo.com>
Prior to this commit the 1024px image was always used regardless of the
space used on the page.
We will now use the 512px image when it is worth it without reducing
overall quality.
This should improve the page loading experience as well as reduce the
overall bandwidth required to load the page.
task-id : 2823110
related : https://github.com/odoo/odoo/pull/86294closesodoo/odoo#89992
Signed-off-by: William Braeckman (wbr) <wbr@odoo.com>
Purpose
=======
This commit rework the design of the Kanban view of the mailing list.
There are now 2 styles for this Kanban view
- Grouped, for this one we keep the same "card design" as before
- Ungrouped, we use a "list style" view, and the card take the all
width of the screen
Add some actions to be able to import quickly contacts from this view
or to send a mailing to the mailing contact list.
Task-2737782
closesodoo/odoo#86587
Signed-off-by: Warnon Aurélien (awa) <awa@odoo.com>
Purpose
=======
Allow the users to themselves mark their course as "done" or "not done"
Specifications
==============
When the course is a "Training" in fullscreen or in non-fullscreen, or
when the course is a "Documentation" in fullscreen mode, allow the user
to click on the "done" button in the sidebar.
When the course is a "Documentation" in non-fullscreen mode, add a
button "Mark Not Done" when the slide is done.
The quiz and the certification cannot be marked as done manually, the
user has to complete the questions for that.
A certification cannot be marked as "Not Done" (but a quiz can).
Technical
=========
As the fullscreen view and the non-fullscreen view will share a lot of
code, make a common class to avoid redundancy.
Task-2604792
closesodoo/odoo#75561
Related: odoo/upgrade#3108
Signed-off-by: Warnon Aurélien (awa) <awa@odoo.com>
Purpose
=======
Allow the users to themselves mark their course as "done" or "not done"
Specifications
==============
When the course is a "Training" in fullscreen or in non-fullscreen, or
when the course is a "Documentation" in fullscreen mode, allow the user
to click on the "done" button in the sidebar.
When the course is a "Documentation" in non-fullscreen mode, add a
button "Mark Not Done" when the slide is done.
The quiz and the certification cannot be marked as done manually, the
user has to complete the questions for that.
A certification cannot be marked as "Not Done" (but a quiz can).
In the non-fullscreen view, mark content as done automatically like we
do for the fullscreen view.
Technical
=========
As the fullscreen view and the non-fullscreen view will share a lot of
code, make a common class to avoid redundancy.
Task-2604792
Part-of: odoo/odoo#75561
Purpose
=======
In preparation to the next commit, we split the course sidebar template
to be able to re-use some part of it in other templates.
Task-2604792
Part-of: odoo/odoo#75561
This is an attempt at fixing a runbot "race" condition.
A first attempt was done in [1] but the selector introduced to make
sure the page was reloaded after the assets were changed was wrong.
This commit fixes that selector.
During the investigation of the problem, it was also discovered that the
SCSS change could take quite a long time on a busy server becasue it
triggers the SCSS compilation each time.
To reproduce that problem locally, run the `stress` command while
executing the `test_html_editor_scss` test.
E.g.:
```sh
$ stress --cpu 32 --timeout 120
```
The error that shows up in that case is misleading because it makes it
look like the confirmation popup was not clicked on.
What is actually happening is the following:
- the Reset button is clicked on
=> the confirmation popup is shown
- the confirmation is clicked
=> the popup is closed and the RPC call is made
- the RPC does not respond within the tour step's timeout
=> the last step is not shown as succesful and the screenshot shows the
non-reset state since the server response did not arrive yet
To be safe on busy servers this commit also increases the timeouts
related to steps that follow updates of SCSS files so that they can be
recompiled on time.
[1]: https://github.com/odoo/odoo/commit/b35f127c86c1d271a76dae7186a96190e8558c73
runbot-3744
closesodoo/odoo#91725
X-original-commit: e04c4f06086ff4287ef4acfc65d5b3d957396ae7
Signed-off-by: Romain Derie (rde) <rde@odoo.com>
Signed-off-by: Benoit Socias (bso) <bso@odoo.com>
The boolean_toggle should only be disabled when there is a readonly
modifier, not when the view is in readonly mode.
Cause of the issue
The input was disabled but the `_onClick` was registered on the
widget root node.
Solution
- Listen for clicks on the input element
- Override the render method to set the disabled prop according to the
readonly modifier.
opw-2739468
closesodoo/odoo#91601
X-original-commit: 29a2402153dc95414dad8c833487e7dd18c8a222
Signed-off-by: Michaël Mattiello <mcm@odoo.com>
Signed-off-by: Hubert Van De Walle <huvw@odoo.com>
In the settings view, we need to display the technical tip below the
setting header (h2 tag). For example, we display such tip under the
'Developer Accounts' header in social media settings.
However, when we search something in the settings, this tip is not
hidden. It happens because the hiding and showing parts of the settings
page are managed with js using some special classes or tags (like h2
tag, `.o_setting_box` class etc).
This commit fixes the issue by introducing a new class `.o_setting_tip`
specific for such technical tips, and with help of that we now hide or
show the tips based on the user search.
Note: We could have used .o_setting_box without any side-effect, but
rules linked to this class can be changed in the future and can mess
with layout of the technical tips. As those are usually small blocks of text
that give a hint to the user and not directly associated with setting box
styling, making the overall code more robust / flexible.
enterprise PR - https://github.com/odoo/enterprise/pull/25907
task-2810617
closesodoo/odoo#88117
Related: odoo/enterprise#25907
Signed-off-by: Warnon Aurélien (awa) <awa@odoo.com>
This commit introduces models that define records being 1:1 map with components,
as a step to move further to having essentially all business code in models.
Having code in models is desirable to have very maintainable code, thanks to
robust and declarative code with an ORM-like architecture.
Task-2831082
closesodoo/odoo#91698
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
This commit add the way to specify the Plausible shared key auth token and
the plausible domain on your website to have the Plausible Dashboard integrated
in your Website > Dashboard > Analytics menu.
Some custom event are already pre-configured as:
Push an event 'Shop' on confirmation on ecommerce (with amount bucket +/- 50)
Push an event 'Lead Generation' on:
'Thank you' page of contactus
Confirmation of subscription for an event
From this way, the end user can just add a goal 'Lead Generation'
or 'Shop' on Plausible to have the Goal values visible.
closesodoo/odoo#91058
Related: odoo/documentation#2007
Signed-off-by: Romain Derie (rde) <rde@odoo.com>
Instead of having 4 buttons to select a view in calendar, we start using a
dropdown button with the framework data-hotkey approach.
task-2704432
closesodoo/odoo#81705
Related: odoo/enterprise#23131
Signed-off-by: Arnaud Joset <arj@odoo.com>
The mailing html converter uses the `reduce` method of `Array` to
compute column size when converting Bootstrap grids to tables. However,
if that array is empty, given that no initial value was passed, the call
caused a traceback. This is fixed by providing an initial value of zero
as should be expected.
task-2853723
closesodoo/odoo#91683
X-original-commit: 4504d1a880032829fb46dbdeab996bd4e0f9ee97
Signed-off-by: David Monjoie (dmo) <dmo@odoo.com>
Prior to this commit cancelled time off were included in the leave
report calendar model and were shown as regular time offs.
They will now be hidden.
closesodoo/odoo#91675
X-original-commit: c8d17c760e27736d0cb809b59e9945f808b1138e
Signed-off-by: Kevin Baptiste <kba@odoo.com>
When a non-logged in visitor tried to validate answers on a quiz page but had
not answered all questions, the button seemed unresponsive.
In fact, the place was not there to show the error message; likely introduced
by 4a329da6a0.
However, instead of restoring the error message for this corner-case, we
considered it was acceptable to change the behavior a little and not block the
visitor who'd like to sign-in/join at this point, as the validation of the quiz
will still be blocked if not all questions are answered with an error message.
Also, as the quiz does get validated when the button is used even though
the user is not yet logged in, it makes sense to also label it 'Join & Submit'
instead of only 'Sign-in'.
Task-2821644
Part of Task-2663320
closesodoo/odoo#91674
X-original-commit: 1e568dab391db809235615a3a2b0dbe3fabc97cc
Signed-off-by: Warnon Aurélien (awa) <awa@odoo.com>
Since the migration from owl1 to owl2, a crash occured when clicking
save or discard in the partner dialog opened from mail composer's
suggested recipient.
This commit fixes the issue by simplifying the way we open that
dialog. With owl2, we introduced a standaloneAdapter which allows
to directly instantiate legacy dialogs inside owl components.
Task 2817547
closesodoo/odoo#91671
X-original-commit: 0c397eacb8784e2a127b1371f3e787dbccbda068
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Before this commit, when we click on the tag field in mobile view
it will display all the tags because in mobile view it will open
the kanban view on click of m2m field so 'search_read' called
instead of '_name_search'.
So in this commit, fixes the issue by applying the same filter
domain in search_read.
task-2790019
closesodoo/odoo#91670
X-original-commit: f23089f1fc14852fdd67916d38881746b15ebd19
Signed-off-by: Laurent Stukkens (ltu) <ltu@odoo.com>
The commit 6bf4d3cdceeb972733c1f680f2ad8a11495e6e9c
introduces an issue where the ChatWindow was hidden by the MessagingMenu
in mobile.
This commit fixes this issue.
task-2857078
closesodoo/odoo#91665
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
In some cases, `test_replenishment` fails "for no reason".
Two notions are needed to understand the issue:
The class of the method `test_replenishment` is a `TransactionCase`. So,
once initialized, a SQL transaction is started and is the same for all
tests:
https://github.com/odoo/odoo/blob/3d9a835379d07142748a366285894a5d0f6ded71/odoo/tests/common.py#L693-L696
Also, in a SQL request, the method `now()` does not really return the
current date:
> Notice that NOW() and its related functions return the start time of
the current transaction. In other words, the return values of the
function calls are the same within a transaction.
(https://www.postgresqltutorial.com/postgresql-date-functions/postgresql-now/)
So, suppose it's the end of day D01 and we start all the tests of the
class `TestBoM`. A SQL transaction is created and the tests are executed
one by one so it takes time: it is now the next day D02 and
`test_replenishment` is executed. At some point, it leads to:
https://github.com/odoo/odoo/blob/9ca9bcc51fa289ddb0548f81a795755d196e31ca/addons/stock/models/stock_orderpoint.py#L328-L333
i.e., we are reading the report `'report.stock.quantity'` at date
"`today()` + 3 months", which means "D02 + 3 months". However, the
report is a SQL view and is defined on an interval of "today +- 3
months". Here is the issue: we use `now()` to get the value of today.
For instance:
https://github.com/odoo/odoo/blob/2f0ad2c150e65806c5f0f3ca66f702cc74619074/addons/stock/report/report_stock_quantity.py#L96-L104
As explained above, `now()` returns the start time of the current
transaction: D01. Therefore, the report is defined until D01 + 3 months.
As a result, D02 + 3 months is outside of the range, the `read_group`
does not return anything, there isn't any need and the orderpoint is not
created -> the test will fail.
closesodoo/odoo#91602
X-original-commit: f3e4eeb8412fba5ee36679eece4cba9f51df543d
Signed-off-by: Arnold Moyaux <arm@odoo.com>
Purpose
=======
This commit brings a new community application to allow recycling
automatically/manually the existing records. Here is some business
examples that could be achieved using this tool:
- Delete all livechat sessions without any messages for more than
1 week.
- Archive all tasks on a given support project that are in Cancelled
stage for more than 2 years.
- Delete all applications that we refused 6 months ago.
The tools allows to delete/unlink spotted records based on a widget
domain (stage.name='Cancelled') and temporal fields (last_stage_update
is passed since 2 years). Either the recycling is done automatically
by a cron, or a notification report is sent to specified users letting
them know how many untreated records have been found.
This application is regrouped with the enterprise features of
data cleaning and data merging under the same application set.
closesodoo/odoo#89312
Taskid: 2827911
Related: odoo/enterprise#26568
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>