Commit Graph
148577 Commits
Author SHA1 Message Date
Adrien Widart 56719fc380 [FIX] stock: select dest location of a SML
On a SML, when setting the done quantity, the onchange may change the
destination location selected by the user

To reproduce the issue:
1. In Settings:
    - Enable "Storage Locations"
    - (Then, ensure "Storage Categories" is disabled)
2. Inventory > Operations Types, edit "Internal Transfers":
    - Enable "Show Detailed Operations"
3. Create an internal transfer IT:
    - From: WH/Stock
    - To: WH/Stock
4. Add a detailed operations to IT:
    - Product: anyone
    - To: WH/Stock/Shelf 1
    - Done: 1

Error: One the field "Done" is modified, the "To" changes and becomes
"WH/Stock". This location should not change (it should be
"WH/Stock/Shelf 1")

When setting the done quantity, an onchange recomputes the destination
location of the SML. To do so, it uses a initial location and searches
among its children. Here is the issue: when "Storage Categories" is
disabled, this initial location should be the one selected by the user.

OPW-2704665

closes odoo/odoo#85151

X-original-commit: 4202e46a8313fa9f1487d372ef0cb771f769be8d
Signed-off-by: Arnold Moyaux <arm@odoo.com>
Signed-off-by: Adrien Widart <awt@odoo.com>
2022-02-22 17:11:05 +00:00
Goffin Simon 39b15d6283 [FIX] sale_crm: Typo error
Introduced by https://github.com/odoo/odoo/commit/d675dbaa4c7174591e0e7c1a3caf3e76877312ce

opw:2746271

closes odoo/odoo#83853

X-original-commit: 02ef4bc1eb8479ba0a3faa6b6429fc18a54a592e
Signed-off-by: Simon Goffin <sig@odoo.com>
2022-02-22 17:11:01 +00:00
Ronald Portier f278589d2a [FIX] cli: support export of pot files
The export_translation method supports the "new language" option but
it was not possible if giving a .pot file.

closes odoo/odoo#85141

X-original-commit: 93e23025252784f39f37a7ffd109425ae56b1d36
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2022-02-22 16:16:40 +00:00
Antoine Guenet b8176448c3 [FIX] web_editor: ensure uploaded images in backend are not public
When uploading an image in the editor, we go through
`_attachment_create`, which sets the image to public if `res_model` is
`ir.ui.view` (the default if none was passed). Because of a wrong
reference to the editable DOM element (which contains the `res_model` as
data), when instantiating the media dialog, we were passing no
`res_model`. As a result, when saving an attachment, no `res_model` was
passed to `_attachment_create` and the attachment was made public.
Attachments in the backend should not be public and should be linked to
the proper model.

task-2759034

closes odoo/odoo#85132

X-original-commit: 5b664f0c04433091c3d6f85f245887d1808c308f
Signed-off-by: David Monjoie (dmo) <dmo@odoo.com>
2022-02-22 16:16:35 +00:00
Tiffany Chang (tic) f4fde9ec58 [FIX] mrp: allow adding byproducts to confirmed MO
Steps to reproduce:
- Create + confirm a MO
- Add a byproduct with a Produced (qty) > 1
- Change the `qty_producing` to a non-zero qty

Expected result:
  Byproduct's "Produced" qty stays unchanged and its "To Produce" is 0
Actual result:
  Byproduct's "To Produce" defaults to 1 and its "Produced" qty is
  updated to scale to the according to the amount `qty_producing` (i.e.
  if `product_qty` = 2 and `qty_producing` = 1, then by-product's
  "Produced" = .5

Additionally, a Missing Record error pops up because of missing
stock.move.line

Solution, don't allow byproducts added after MO is confirmed to default
to 0. Additionally allow byproducts to have 0 "To Produce" quantity and
don't sum the cost share of merged byproduct moves since when Produced
> To Produce then an extra move is created and the cost share ends up
being doubled during the merge.

closes odoo/odoo#85130

Task: 2716164
X-original-commit: 51ff14a56b909bdf22c9f1c4540347655578e1f4
Signed-off-by: Arnold Moyaux <arm@odoo.com>
Signed-off-by: Tiffany Chang <tic@odoo.com>
2022-02-22 16:16:31 +00:00
Bruno-brsy fdbbfd06d6 [FIX] account: bank suspense accounts
Step to reproduce:
- Install account_accountant
- Go to Accounting / Configuration / Accounting / Journals
- Create a Journals in Accounting
- Select a type as "Bank"

Issue:
Since this PR: https://github.com/odoo/odoo/pull/81071
The bank suspense account has been changed from "Current Liabilities"
type to "Current Assets", but isn't being correctly updated in
the journals view.

Solution:
In the domain of the "suspense_account_id", we should use
"data_account_type_current_assets" for the "user_type_id" instead  of
"data_account_type_current_liabilities"

opw-2715621

closes odoo/odoo#85105

X-original-commit: c16bc3192fe8ea033144c9cb6ab5b8c6db21d735
Signed-off-by: Quentin De Paoli <qdp@odoo.com>
Signed-off-by: Bruno-brsy <brsy@odoo.com>
2022-02-22 16:16:28 +00:00
Pouya Malekinejad b843407fed [IMP] models: small optimization in onchange
closes odoo/odoo#84865

Signed-off-by: Vincent Schippefilt (vsc) <vsc@odoo.com>
2022-02-22 16:16:24 +00:00
Vincent Schippefilt e5523f06ce [FIX] base: unique module name declared twice
before this commit, there was 2 unique indexes on module name
after this commit, only 1 unique index remains (the one declared in base/ir_module.py) to keep the error message

closes odoo/odoo#85116

Signed-off-by: Raphael Collet <rco@odoo.com>
2022-02-22 15:20:13 +00:00
Pierre-Yves Dufays 83c0e88e78 [FIX] event: improve attendee view by removing the default group by week
The default group by registration week has been removed in the attendee view  because:
- it makes the view impossible to use on mobile (too many columns)
- it makes the navigation on desktop a bit tricky

This reverts a change introduced in odoo/odoo@4bed87d.

Task 2761011

closes odoo/odoo#85113

X-original-commit: 7ebc86fd9202a0023513a2d4535f93a2d3914c1d
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2022-02-22 15:20:10 +00:00
Thanh Dodeur fb8f5169b2 [FIX] mail: prevent empty popover in the rtc call participant card
Before this commit, the popover containing the volume bar of the rtc
call participant card was rendered empty. This was because the `t-set`
was used instead of `t-set-slot`. This commit fixes this issue.

related to: https://github.com/odoo/odoo/commit/edd79ff560cf321ebd0488e4917abb7424fea1bb

closes odoo/odoo#85106

Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2022-02-22 15:20:06 +00:00
Andrius Laukavičius 99b58cb48e [FIX] account: customer_rank/supplier_rank no copy
If partner is copied, it will copy customer_rank/supplier_rank and it
will be treated as such even though such partner has no references to
invoices for example.

closes odoo/odoo#85102

X-original-commit: c0161736db4f2415e6a44674d872bf8aa2972287
Signed-off-by: William André (wan) <wan@odoo.com>
2022-02-22 15:20:02 +00:00
Paolo (pgi) 2b784e1d59 [IMP] l10n_it_edi_sdicoop: Improving behaviour after MancataConsegna
In the B2B case, after a MancataConsegna, the invoice is considered
issued, but the delivery is failed.
In the B2G case, the Exchange System will retry to send it for 10 days
and inform the Public Administration. After 10 days, it will be
considered issued but not delivered.
In both cases of failure, the user is required to send the invoice
through other means than the Exchange System.

Ref (IT): https://www.datalog.it/fattura-elettronica-cosa-fare-in-caso-di-mancata-consegna

closes odoo/odoo#85100

X-original-commit: e8e08aba971cbf688b09f39cf3b3e4bc75641e84
Signed-off-by: Florian Gilbert <flg@odoo.com>
2022-02-22 15:19:58 +00:00
tsm-odoo 609890eaa4 [IMP] mail: update notification_type to match server's default
task-2767820

closes odoo/odoo#85095

Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2022-02-22 15:19:48 +00:00
roen-odoo 0537c24f99 [FIX] pos_gift_card: giftcard popup text too long
Current behavior:
When using DE language in PoS. The text from giftcart popupbutton was tool long and was out of the button

Steps to reproduce:
- Change language to DE
- Open PoS and giftcard popup

opw-2744369

closes odoo/odoo#85090

X-original-commit: 28903717e2af5bbcb65e6be81ab0668d956ec659
Signed-off-by: Masereel Pierre <pim@odoo.com>
Signed-off-by: Engels Robin (roen) <roen@odoo.com>
2022-02-22 15:19:42 +00:00
Antoine Guenet 51c9629aa1 [FIX] web_editor: prevent traceback on apply style to empty lines
When the selection only contains empty lines, no text nodes are
selected. `applyInlineStyle` however counted on text nodes being
selected, resulting in a traceback.

task-2740204

closes odoo/odoo#85059

X-original-commit: ee6c71a3bcd6ec927acbe4eaf4c21acb28396e87
Signed-off-by: David Monjoie (dmo) <dmo@odoo.com>
2022-02-22 15:19:38 +00:00
Arthur Detroux (ard) 2e44cb41ea [FIX] website: fix editor not starting after creating a website
Commit [1] introduced an automatic start of edit mode when
selecting a theme but didn't take into account wether the frontend lang
of the user was matching that of the website that is supposed to enter
in edit mode.

Steps to reproduce:
- Create an empty database and install website.
- Add an extra lang on website (e.g FR) and visit the website in that
lang.
- Go in settings an create a new website, skiper the configurator,
  select a theme.
- Redirect is with enable_editor but nothing happens.

The editor isn't started if not in the source's lang.

This commit redirect the user to the default_lang of the website
so that editor can always be started. It also introduces a tour
to test out the flow.

[1]: https://github.com/odoo/odoo/commit/f474eac4543712ae5b1c7d614f9eff9367445107

task-2687416

closes odoo/odoo#85058

X-original-commit: 02e08af7278cd66d768fe6a4f23aa17eb816be3c
Signed-off-by: Romain Derie (rde) <rde@odoo.com>
2022-02-22 15:19:34 +00:00
Noe Antoine fe758ac69a [IMP] website_sale_slides: use total amount in course sales reporting
Before, there was a mismatch between the course's sales smart button
and the reporting it leads to. The amount shown is the total, taxed,
amount. Once in the reporting, the default measure is the subtotal,
untaxed.

This commit harmonizes both as well as course revenue reporting by
replacing the current default measure (price_subtotal) by the total
amount. This measure price_total is used in both graph and pivot views.

Task-2718756

closes odoo/odoo#83184

Signed-off-by: Warnon Aurélien (awa) <awa@odoo.com>
2022-02-22 15:19:27 +00:00
Patrick Hoste 6a67eb8ffa [IMP] website_event: improve tag visibility on frontend
PURPOSE:

Before this commit when they were a lot of tags they were all
displayed inline being hidden by the card size. This commit
fix this bug and display them nicely row after row.

LINKS

Task-2737156

Pr: odoo/odoo#83082
Signed-off-by: Warnon Aurélien (awa) <awa@odoo.com>
2022-02-22 15:19:23 +00:00
Patrick Hoste b74ed97482 [IMP] event: order event tags by category sequence / own sequence
PURPOSE

Before this commit the tags were ordered only by their own sequence
making the display quite random when several tags had the same
sequence but belonged to different categories.
After this commit the tags are ordered by their category sequence
followed by their own sequence.

LINKS

Task-2737156
Closes: odoo/odoo#83082
2022-02-22 15:19:23 +00:00
std-odoo 4dbcefb5e5 [IMP] utm: ensure the uniqueness of the names of the UTM models
Purpose
=======
Ensure that the names of the UTMs models (campaign, medium and source)
are unique.

If not, generate automatically an unique name.

The name field is no more translatable; it makes no sense to translate
a technical which will be added in the URL, and can even cause issues
(the UTM record is not recognized because of the translation).

For the campaign, we keep a "translatable" name which is called
"title".

For the UTM source, use a mixin to generate automatically the name of
the source based on the content (_rec_name) of the record. So we remove
the override of create / write / copy in the different models and
ensure consistency between those models.

Task-2245823

closes odoo/odoo#60501

Related: odoo/enterprise#21882
Related: odoo/upgrade#1863
Signed-off-by: Warnon Aurélien (awa) <awa@odoo.com>
2022-02-22 12:53:00 +00:00
William Braeckman dcf33627f5 [IMP] hr_holidays: add a test on accruals
This is a followup to odoo/odoo#3250 where a test for this case is
missing.

TaskId-2768450

closes odoo/odoo#85076

X-original-commit: 3d1f2f2d540a97506e0238f579199116aa8646dc
Signed-off-by: Kevin Baptiste <kba@odoo.com>
2022-02-22 11:59:16 +00:00
Audric Onockx (auon) a51f49a61d [FIX] project : search in all without access error
Steps :
Install project and sale_project
Log in as portal > Tasks
Search bar > Dropdown > Search in All
Type anything and search

Issue :
Access Error : You cannot read sale_order_id.name, sale_order_id.invoice_ids.name,
sale_line_id.name, message_ids.body fields in task.

Cause :
We search in every field including those portal doesn't have access to.

Fix :
Add the domain of the rule of task to the search domain, so the search
only occurs on allowed fields.

opw-2762212

closes odoo/odoo#84934

X-original-commit: 7c2855e17a85af6609a705abe50e69720f9bad75
Signed-off-by: Laurent Stukkens (ltu) <ltu@odoo.com>
2022-02-22 11:59:12 +00:00
Yannick Tivisse c6d1f71bf0 [IMP] hr: Allow plans to directly request signatures
closes odoo/odoo#84976

Related: odoo/enterprise#24577
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2022-02-22 09:41:54 +00:00
Thomas Beckers 96ee7317bd [FIX] project: translate 'assignee' for shared project with portal user
Issue :
In the kanban view related to shared project with portal user,
the term 'assignee' is not translated in the portal user language.

With this commit, this term will be translated based on the user language.

opw-2746504

closes odoo/odoo#85063

X-original-commit: 0231e1b78a3b377153c9d2e097b9d4aad9bc3b0d
Signed-off-by: Laurent Stukkens (ltu) <ltu@odoo.com>
2022-02-22 08:46:48 +00:00
Alexandre Kühn 9e515155a6 [IMP] mail: turn "Chatter/attachmentsLoaderTimeout" into field
Task-2734101

closes odoo/odoo#85012

Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2022-02-21 20:11:59 +00:00
Bruno Boi 030b1ba8d6 [REF] web: factorize some hotkey service code
- JS and DOM registrations are now shaped similarly,
  so this help to handle them with the same piece of code

- the keydown event object is now manipulated only in a single function,
  so it is clearer what it is used for and when it is eventually
  stopped or default prevented.

- some constants were converted from Sets to Arrays because they had
  no particular reason to be Sets.

closes odoo/odoo#84969

Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2022-02-21 20:11:55 +00:00
Bruno Boi d2fc219d52 [FIX] web: protect key navigation in editable
Before this commit
The hotkey service was not taking into account that a new hotkey press
may have been triggered from an editable element.
This led to unwanted behavior, i.e. pressing ArrowLeft on an input
inside a sub Dropdown closed the sub Dropdown instead of navigating
through the text written in the input.

After this commit
The hotkey service now detects if the hotkey press was triggered from an
editable element (any input, textarea or other element with
[contenteditable=true] attribute) and does not dispatch this hotkey,
unless a candidate registered handler has explicitly asked to bypass the
editable protection. In that case, its callback will still get called.

task-2764821

Part-of: odoo/odoo#84969
2022-02-21 20:11:55 +00:00
Bruno Boi d48915e285 [FIX] web: dispatch an hotkey only once
Before this commit, the hotkey service will potentially
dispatch many time the same pressed hotkey.

After this commit, it will dispatch only to the newer
registrations or the first that match in the DOM.

task-2764821

Part-of: odoo/odoo#84969
2022-02-21 20:11:55 +00:00
Bruno Boi 78f85f2725 [FIX] web: repair some keynav in dropdowns
ENCOUNTERED ISSUE:
Unable to close a dropdown with ESC when the focus has been given
to a select element inside the dropdown.

TO REPRODUCE:
i.e. in the searchpanel, go to "FilterMenu > Add Custom Filter" and
open the field select element.
Press ESC once: the field select element closes just fine.
Press ESC a 2nd time: we expect the dropdown to close but nothing occur.

REASON EXPLANATION:
Since 84715436d our Dropdown component uses the 'dropdown-menu'
bootstrap class.
But under some conditions bootstrap stops the keydown events propagation
when the event.target matches the query selector '.dropdown-menu'.

IMPLEMENTED FIX:
This commit refines this selector directly inside the bootstrap library.
This is admittedly a bad practice but:
- this modification is trivial and sensible
- the modified selector is only used locally
  in the bootstrap's 'dropdown.js' file
- the added test should prevent the lost of
  this customization in the future

task-2764821

Part-of: odoo/odoo#84969
2022-02-21 20:11:54 +00:00
Florian Damhaut 22211ec6c2 [FIX]project: traceback on project update notif
Step to reproduce:
- Schedule activity on a project update
- Access the activity

Current Behaviour:
- On Project.update, we try to compute the info related to the project_update's project
due to the project update view showing information about the project.
In case of notification, we can show multiple project and thus no project_id can be
provided.
- Traceback

Behaviour after the PR:
- If there is no set project_id when opening the project update kanban view
We do not show the RightPanel related to the project and do not compute

related PR in enterprise odoo/enterprise#24427

opw-2755473

closes odoo/odoo#85060

X-original-commit: 9e30888195db0d01f06dffa9d59ae652fe6de5f0
Signed-off-by: Laurent Stukkens (ltu) <ltu@odoo.com>
2022-02-21 19:22:04 +00:00
Alexandre Kühn dcef7d1f9c [IMP] mail: turn "ThreadView/loaderTimeout" into field
Task-2734101

closes odoo/odoo#85021

Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2022-02-21 18:30:13 +00:00
Alexandre Kühn 6f95a4327b [IMP] mail: turn "RtcCallViewer/showOverlayTimeout" into field
Task-2734101

closes odoo/odoo#85018

Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2022-02-21 18:30:09 +00:00
Yannick Tivisse daa9a1911e [FIX] core: avoid access error in (parent/child)_of_domain
Purpose
=======

Loading a view trying to retrieve the hierarchy of a record using the field
parent_path could lead to an access error if records are mixed up.

Note:
Easily achievable for an end user. It could happen in a multi company
environment (you activate 2 companies at the same time) while configuring
the departments (using _parent_store=True), and you say that you have:

R&D (company=1):
     - R&D Belgium (company=1)
     - R&D India (company=2)
Then you go back to a single-company environment, you click on the form
view of an employee and crack, since there is a multi-company rule on the
departments, and that the search panel is loading the hierarchy for
display purpose.

Use sudo to avoid access rights issues, as the forbidden records will be
filtered automatically by the constructed domain like this:

```py
parent_ids = [
    int(label)
    for rec in left_model.sudo().browse(ids)
    for label in rec.parent_path.split('/')[:-1]
]
domain = [('id', 'in', parent_ids)]
```

This actually makes the search consistent with the case where
_parent_store=False.

closes odoo/odoo#85042

X-original-commit: a7e13b32e6c47a3fdcfad8a6c6337b89580ad70a
Signed-off-by: Raphael Collet <rco@odoo.com>
2022-02-21 17:01:12 +00:00
Antoine Vandevenne (anv) a1350dc414 [FIX] payment: improve heuristic for detecting empty HTML fields
This commit uses the `is_html_empty` util method to detect empty HTML
fields in cleaner and more resilient fashion than what was done in
808cc53bb02b0f1851a2a229bd5235a5fb944408.

closes odoo/odoo#84999

X-original-commit: 89f3aa8a979c5236b587f9690595117b52f0dd63
Signed-off-by: Antoine Vandevenne (anv) <anv@odoo.com>
2022-02-21 17:01:09 +00:00
Antoine Vandevenne (anv) adf70bf9dc [FIX] *: retarget documentation links to master
closes odoo/odoo#84990

X-original-commit: 39bdf46
Related: odoo/enterprise#24582
Signed-off-by: Antoine Vandevenne (anv) <anv@odoo.com>
2022-02-21 17:01:02 +00:00
Arnold Moyaux 8d0e49ce62 [FIX] stock_picking_batch: wave take incorrect stock.move
Usecase to reproduce:
- Product A 0 unit in stock
- Product B 10 unit in stock
- Create planned delivery with product A and B
- Do a wave transfer and selected reserved `stock.move.line` from
product B

Current behavior:
The whole picking is move into the batch

Desired behavior:
The picking is splitted and only the move for product B is in a new
batch

It happens because the add_to_wave function check if all the picking
`stock.move.line` are in the `stock.move.line` to batch. If it's the
case, it moves the picking in the new batch. However in our case,
some `stock.move` are not reserve and should not be move in the new
batch. Also check if all the quantity is reserve on the `stock.move`
if it's not the case split the move to only put the reserve quantity
in the wave picking

closes odoo/odoo#85038

X-original-commit: afe2a3a7f913459d88ef197e63bc897fda5f90f8
Signed-off-by: Arnold Moyaux <arm@odoo.com>
2022-02-21 16:08:01 +00:00
Arnold Moyaux d6ecbf36a0 [FIX] stock_picking_batch: wave immediate transfer
Usecase to reproduce:
- Create an immediate transfer and enable detailed opeations on the
picking type
- Create 2 `stock.move.line` with qty_done = 5
- Add the picking to a new wave and select only one of the sml

Traceback

It happens because the move split is base on the reserved quantity.
However in the case of an immediate transfer, the reserved quantity is
zero and the split fail

X-original-commit: 709372b0160a93cb9c30d391c4b3fc6c07ea2f9a
Part-of: odoo/odoo#85038
2022-02-21 16:08:01 +00:00
Arnold Moyaux 85383f18b3 [FIX] stock_picking_batch: wave traceback
Usecase to reproduce:

Create a transfer with 3 moves for 3 products:

A - qty 60 (2 move lines, each move line has a quantity of 30)
B - qty 40 (2 move lines, each move line has a quantity of 20)
C - qty 40 (2 move lines, each move line has a quantity of 20)
Create a new wave picking containing the first move lines of each product (3 move lines)

Traceback

The error is due since it take all the `stock.move.line` from the
picking instead of the `stock.move` that is browsed

Fix #83450

X-original-commit: 788d08bb64204a0cb1c696f89228f6b4ae8d9620
Part-of: odoo/odoo#85038
2022-02-21 16:08:00 +00:00
Priyanka Kakadiya 6fb5c3d82d [FIX] mail: fix back button issue to close channel
Before this commit:

When switching to mobile view and refreshing the channel in discuss than back
arrow button is not working

After this commit:

Back arrow button will close the channel

Task-2685187

closes odoo/odoo#85034

X-original-commit: ebe56aac6d11e967d3b2fc8b57031e1b0e8ea726
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2022-02-21 16:07:54 +00:00
Josse Colpaert 8640044fb7 [FIX] l10n_es_edi_sii: registration date should not be copied when duplicating invoice
closes odoo/odoo#85030

X-original-commit: 9af5338df16579ee3d5554bb03fe6d9e9c77e025
Signed-off-by: Quentin De Paoli <qdp@odoo.com>
Signed-off-by: Josse Colpaert <jco@odoo.com>
2022-02-21 16:07:50 +00:00
Josse Colpaert 76fc8bcbac [FIX] l10n_es_edi_sii: extracommunity should be regimen 01 for purchases
See doc preguntas frecuentes 4.4:
https://sede.agenciatributaria.gob.es/Sede/impuestos-tasas/iva/iva-libros-registro-iva-traves-aeat/preguntas-frecuentes/4-libro-registro-facturas-recibidas.html?faqId=f8276c3d02bc9510VgnVCM100000dc381e0aRCRD

Add tax agency Bizkaia to the tests too as in v15, so we see that the tests
pass here as well.

opw-2746495

X-original-commit: c35f34eebf3f57a835aa9c3056cf76293c3ca8de
Part-of: odoo/odoo#85030
2022-02-21 16:07:50 +00:00
Raphael Collet 39c1ab249b [FIX] core: discard redundant code
closes odoo/odoo#85028

X-original-commit: b026f17988dfaecac41f0a350cf8cfb52aa3827c
Signed-off-by: Raphael Collet <rco@odoo.com>
2022-02-21 16:07:45 +00:00
root 2c4eeece6c [IMP] project: hooks for overriding domain/sortings/filters
Before this commit there was no easy/clean way to extend the domain, searchbar sorting and filtering.
By adding it in subfunctions we can do clean extending of the domains/filters

closes odoo/odoo#84912

Signed-off-by: Laurent Stukkens (ltu) <ltu@odoo.com>
2022-02-21 16:07:39 +00:00
roen-odoo b2ab680fc3 [FIX] payment : Wrong logo in payment portal
Current behavior :
In a multi-company environnement if you generate a payment link and access it from incognito page the company was always the logo of the first company.

Steps to reproduce :
- Get in a multicompany environnement
- Create a invoice in company B
- Generate the payment link in the action menu
- Access the link in incognito mode
- The company logo is always the logo from company A

opw-2756438

closes odoo/odoo#85000

X-original-commit: 0e2e79d055e8565e2913b30477fcfdb71e99bdae
Signed-off-by: Antoine Vandevenne (anv) <anv@odoo.com>
Signed-off-by: Engels Robin (roen) <roen@odoo.com>
2022-02-21 14:14:12 +00:00
Benoit Socias c5e96ac750 [FIX] web_editor: revert text color previews
Before this commit when a text color was applied on a text within
which an already colored text already existed, the inner coloring was
lost during preview. All text was therefore set to the initial coloring
of the external selected text.

After this commit the "reset" of the text color preview is done by
undoing the draft "in progress" history step that contains the preview
changes, but that is not stored within the history itself.

Steps to reproduce:
- drop the Text snippet
- select a word in the middle of a sentence (e.g. "personality")
- set text color to red
- select several words containing the colored one (e.g. "story with
personality for potential")
- open text color palette
- hover over colors but do not click
- leave color palette
=> colored word is not colored anymore

Steps to reproduce a secondary problem also fixed by this commit:
- drop the Text snippet
- select text surrounding some bold (e.g. "have a personality. Consider")
- open text color palette
- quickly hover through several colors (i.e. move pointer downwards)
=> text selection range changed between some of the color previews

task-2742112 (was task-2666200)

closes odoo/odoo#84998

X-original-commit: 9cb5a138244783580c2d1baa4dc01d1824ed20f4
Signed-off-by: David Monjoie (dmo) <dmo@odoo.com>
2022-02-21 14:14:09 +00:00
Victor Feyens 7337a0b99b [MOV][IMP] product: split views by models
closes odoo/odoo#84997

Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
2022-02-21 13:14:02 +00:00
Victor Feyens a3ac36c941 [MOV] product: split product views by models
Part-of: odoo/odoo#84997
2022-02-21 13:14:02 +00:00
Hoang Tran 74ea165345 [IMP] account_check_printing: improve perf of computed preferred pm
When install the module on a db with huge amount of account move,
prefetching data when accessing partner_id of first move iteration is
costly and should be avoided.

closes odoo/odoo#84989

X-original-commit: c80700ee616e5588669879fd5e020ea868665a8f
Signed-off-by: William André (wan) <wan@odoo.com>
2022-02-21 13:13:56 +00:00
Thibault Francois 4340a7e4d2 [FIX] fleet: fix search method for contract_renewal*
the search method of contract_renewal_due_soon and
contract_renewal_overdue return a domain
id in res_ids where res_ids are id of contract
not vehicle

So it return random result

Solution
--------
Get the vehicle_id from the contract record set

closes odoo/odoo#84987

X-original-commit: 975841953adaa6b7adc8016fb96cc6efc8891613
Signed-off-by: Kevin Baptiste <kba@odoo.com>
2022-02-21 13:13:52 +00:00
william b16507ae28 [FIX] account,l10n_*: always auto_install l10n_*_edi
The logic should not be made in the post init hook of account otherwise
modules will only get installed like expected during the database
initialization, based on the country set on the main company before the
installation of `account`.

closes odoo/odoo#84975

Related: odoo/enterprise#24576
Signed-off-by: Quentin De Paoli <qdp@odoo.com>
2022-02-21 12:17:06 +00:00