Commit Graph
154774 Commits
Author SHA1 Message Date
Julien Alardot (jual) eaee797afd [FIX] account: Clarify lock date message
The current message may make you believe the date on
the invoice will be changed when it's the accounting date
This aims to clarify that the move.invoice_date will stay
the same when it's the move.date that will be changed

closes odoo/odoo#101820

X-original-commit: 5f5dbbcc66f4ded1388949386faf90e0d406a4b2
Signed-off-by: Julien Alardot (jual) <jual@odoo.com>
Signed-off-by: William André (wan) <wan@odoo.com>
2022-10-01 13:58:41 +02:00
Habib (ayh) 346a75d5ef [FIX] analytic: distribution widget plans
There are a few issues solved in this commit
1. Fetch plans is called too many times (Journal items List view). This is not necessary as plans are only required if editing
2. Plans are not fetched again if the product/account changes. This is because the record referenced by props and nextProps is the same, hence a change is not detected.
3. In list views - analytic account data is retrieved for each instance of the widget. To reduce the calls, a batched read is used instead

Improve test

closes odoo/odoo#101803

X-original-commit: 01d7579cfc8bf441f03d4467ef34a2d3bae015a4
Signed-off-by: William André (wan) <wan@odoo.com>
2022-10-01 13:01:52 +02:00
Michael (mcm) 9087b3c2d8 [FIX] web: display "Oh snap" dialog when needed
Before this commit, the "Oh snap!" dialog could be displayed anytime
a server validation error was returned by an RPC. Also, clicking
on the "discard" button in this dialog always triggered an `historyBack`
even when we open a new action.

Now, this dialog is only opened on error while saving and does not
`historyBack` anymore.

closes odoo/odoo#101802

X-original-commit: 31c6ecb7f9ad68d337cbc7f0fd3b4d682c088b85
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2022-10-01 13:01:50 +02:00
Arnold Moyaux 1b1fa9ee95 [FIX] mrp: MTO - decrease the post production when decreasing the SO
Use case to reproduce:
- Create a product with manufacture and MTO route
- Set the warehouse in 3 steps manufacturing
- Confirm a SO for 5 units
- Update the quantity to 4 units

Current behavior
Each picking has a quantity to 4 units. Except for the post
production to stock that still for 5 units but a return is
created.

Expected behavior
Each picking has 4 units

It happens due to `_run_pull` that will create a new procurement
group in post production location (the purpose is to avoid a merge
between semi-finished product and finished product). But in the case
of a negative procurement, we want to decrease a picking and not
create a production order. So create a new procurement group with the
next MO sequence will aslo create another issue because
`_run_manufacture` will skip the MO creation since the quantity is
negative and it will be a gap in the sequence number.

Instead of creating a new procurement group, search for an existing
in sibbling moves, so `_search_picking_for_assignation` could find
a picking to merge the negative procurement and decrease an existing
move.

closes odoo/odoo#100439

X-original-commit: c5e8adaa2b364e3ff4625e080df4c523a9673668
Signed-off-by: Arnold Moyaux (arm) <arm@odoo.com>
2022-10-01 12:05:52 +02:00
snd bafbd6cd19 [FIX] sale_mrp: do not use template bom
Consider this case:
Template A has 2 variants: KIT and NOKIT
KIT has a total cost of 100, NOKIT costs 50
When selling NOKIT, the current code will select the bom of KIT
to calculate the price_unit of NOKIT, which means that when
reconciling the aml of the invoice (amount = 100) with the aml of
the cogs move (amount = 50), it will be partial due to the difference
in amount. This alse messes with the balance sheet report.

This fix ensures that only boms directly related to the product
or for the generic template are selected.

opw-2918080

closes odoo/odoo#98676

X-original-commit: 8ce71352886442f3a75999fe39856f82651314e5
Signed-off-by: Steve Van Essche <svs@odoo.com>
2022-10-01 12:05:49 +02:00
Ricardo Gomes Rodrigues (rigr) d16ce493a4 [IMP] account: improve fiduciary mode
This commit improves the fiduciary mode by:
- removing message error about the change of sequence format
- suggesting the Customer Invoice / Vendor Bill date according to the following heuristic:
	- Last day of the month of the most recent Customer Invoice / Vendor Bill (ignoring drafts) OR today (whichever is the smallest)
	- If this date falls before a Lock Date, pick the last day of the first month that is not locked
	- Examples:
		- Example 1 :
			We are June 17th 2022. No Lock date. Bill Date of the most recent Vendor Bill : March 15th 2022
			==> Default New Vendor Bill date = March 31st 2022 (last day of March 2022)
		- Example 2 :
			We are June 17th 2022. No Lock date. Bill Date of the most recent Vendor Bill : March 31st 2022
			==> Default New Vendor Bill date = March 31st 2022 (last day of March 2022)
		- Example 3 :
			We are June 17th 2022. No Lock date. Bill Date of the most recent Vendor Bill : June 2nd 2022
			==> Default New Vendor Bill date = June 17th 2022 (today is the smallest)
		- Example 4 :
			We are June 17th 2022. Lock date : April 30th 2022. Bill Date of the most recent Vendor Bill : April 30th 2022
			==> Default New Vendor Bill date = May 31st 2022 (last day of the first month not locked)
- renaming the invoice according to the suggested date

Task id: 2887007

closes odoo/odoo#101799

X-original-commit: 179f4f83db0d029850375012bbf80dedc6679505
Signed-off-by: William André (wan) <wan@odoo.com>
2022-09-30 22:54:47 +02:00
Ivan Yelizariev 552ef6533c [FIX] website_sale: allow setting name for delivery
Fixup for d823033ad67702b1b92d27a3f66c7a4ec304c644

Portal user should not modify partner's name if an invoice for this partner is
already issued. However, delivery address contact may have empty name, while
eCommerce UI requires filling out the name. This blocks checkout process. Fix it
by allowing name changes, when it's not set.

opw-2981455

closes odoo/odoo#101796

X-original-commit: 781dbeaccac76a6ec4f4b8cac1b607810697e394
Signed-off-by: William Braeckman (wbr) <wbr@odoo.com>
2022-09-30 21:14:53 +02:00
Aaron Bohy 96c590504b [REF] web: remove toggle_button field from registry
This field widget is no longer used in form, list or kanban views,
so it hasn't been converted to owl. This commit removes its legacy
implementation from the registry, s.t. we ensure nobody use it
again. Moreover, we adapted a new view test using it to use another
field widget instead, to remove the dependency and ease the removal
that should happen soon.

closes odoo/odoo#101787

X-original-commit: 68cfd4b08bc9ab0305ae9033e42820370b52bdf3
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2022-09-30 18:42:37 +02:00
Aaron Bohy 91e7dfd63a [FIX] web: FieldTooltip: display component description in debug
In debug, we want to see the field component description in its
tooltip. For instance, for a many2one: `Widget: Many2one (many2one)`,
`Many2one` being the `displayName` attribute of the Component, and
`many2one` the key in the registry (to use with `widget="many2one"`
in archs).

X-original-commit: 39fbb4620b5e846cd597ecbbfefdbda8bc4cb8e1
Part-of: odoo/odoo#101787
2022-09-30 18:42:37 +02:00
luvi efad2b1a10 [FIX] sms: fix sms_button in form views
This commit brings back the Send SMS button, which was no longer
visible in form views since they are now displayed in edition by
default.

It also solves the missing enable_sms option, which was not yet
ported from the legacy implementation.

A test file has been added to the sms module to verify the presence
of the button in the view.

closes odoo/odoo#101786

X-original-commit: fdb38657904202d9bfa75817289a53596b914406
Related: odoo/enterprise#32108
Signed-off-by: Michaël Mattiello <mcm@odoo.com>
Signed-off-by: Luca Vitali <luvi@odoo.com>
2022-09-30 18:42:32 +02:00
luvi 909a510120 [FIX] web: add a send email button to field in edit mode
This commit brings back the functionality to send e-mails when using
the EmailField in form views. Since they are displayed in edition by
default, the link was no longer available and the feature was missing.

A test has been adapted to assert the presence of the button.

X-original-commit: dbaa1c1083803f31d932445fed8d6324c5191c4b
Part-of: odoo/odoo#101786
2022-09-30 18:42:31 +02:00
luvi e8a9868605 [FIX] web: add a Go to URL button to UrlField in edition
This commit adds a Go to Url button next to the UrlField input. Since form
views are always set in edition mode, it was no longer possible to open
URLs by clicking on the link. Now, a button has been added directly after
the input to bring back the original feature.

Tests assert the right behavior regarding this button.

X-original-commit: e97215e78500a7b36aa0da073c767f5f96198d3f
Part-of: odoo/odoo#101786
2022-09-30 18:42:31 +02:00
luvi aea8a49a35 [FIX] web: adapt Call button for PhoneField
Since form views are always visible in edition mode, it was no longer
possible to click on the phone number to start a call. Now, a button
is displayed next to the input, allowing the call to start despite
the state of the view.

Tests have been adapted to assert the presence of the button.

Enterprise PR: https://github.com/odoo/enterprise/pull/31954

X-original-commit: 4ac2f17ce6279aa745b1a930f52b86635a04753c
Part-of: odoo/odoo#101786
2022-09-30 18:42:31 +02:00
MerlinGuillaume 849856843a [FIX] mrp: write with multiple workorders in self
This PR https://github.com/odoo/odoo/pull/97805 wrongly assumed that
self contained a single workorder. This would raise an error if there
were multiple records in self.

Solution:
Modify calls on `self` to `workorder` (as we already iterate through
them)

closes odoo/odoo#101775

X-original-commit: 26cb902e603d6d576957d1d329d3eef4e76af5f8
Signed-off-by: William Henrotin (whe) <whe@odoo.com>
Signed-off-by: Guillaume Merlin (megu) <megu@odoo.com>
2022-09-30 16:42:57 +02:00
Pierre Paridans a89c3b3893 [REV] web_editor: toolbar should be scrollable on smaller screens
This reverts commit 3a7349d02b6b667c890af2f197a3640d875b804e.

This toolbar being more accessible in mobile (scrolling to access all
the buttons), sadly it broke the toolbar's dropdown...

closes odoo/odoo#101766

X-original-commit: 253152d93f381ba0e55787818294aaee24383e0a
Signed-off-by: David Monjoie (dmo) <dmo@odoo.com>
2022-09-30 16:42:54 +02:00
Odoo's Mergebot 331bb5ae69 [FW][MERGE] (various): adapt tours to always edit
Always edit mode comes with several layout and behavioral changes that may necessitate changes in tours (both in terms of selectors for the tips and in terms of content, e.g. since "Save" steps are now kind of redundant).

closes odoo/odoo#101729

Forward-port-of: odoo/odoo#101328
Signed-off-by: Bouvy Damien (dbo) <dbo@odoo.com>
2022-09-30 15:33:07 +02:00
Damien Bouvy 8d0ecae0c9 [FIX] account: fix tour
Some events might not bubble up to a tour tip because the owl template
will have a on.click.stop handler, which prevents propagation up the
tree.

Bypass this limitation (before we find, perhaps, a better solution)
by carefully choosing a selector that works for both legacy and owl
fields (since some fields might still be legacy right now).

X-original-commit: de2942131fb7777e78e9f2d0bbda4dc98f2ba230
Part-of: odoo/odoo#101729
2022-09-30 15:33:06 +02:00
Damien Bouvy a25fe005b2 [IMP] hr_expense: resuscitate tour and adapt to always edit
Slightly modify the view as well, including now showing the
'attach receipt' button before the first save (as it will trigger
a save a work properly since its migration to owl).

X-original-commit: 283779a8999b6ae93996bafb46b879dc6a3e0112
Part-of: odoo/odoo#101729
2022-09-30 15:33:05 +02:00
Damien Bouvy dc797aead0 [IMP] project: adapt tour to always edit
X-original-commit: 454f82e39e1cb4fb7b48db9470a58f304992a0c1
Part-of: odoo/odoo#101729
2022-09-30 15:33:05 +02:00
Damien Bouvy f1c822cde2 [IMP] crm: adapt tour to always edit
X-original-commit: abd8a5ce0b5f30b70f9524587fdbeb0f7ab670d7
Part-of: odoo/odoo#101729
2022-09-30 15:33:05 +02:00
Younn Olivier fa4cc2f969 [FIX] web, portal: re-introduce w-0 and h-0 utility classes
When updating bootstrap to bootstrap 5 with [1], the h-0 and w-0
extended utility classes were lost.

This commit adds them back, using the Utility API of Bootstrap described
here [2], and the $utilities-sizes from [3]. Therefore, the code
introduced in [4] is not needed anymore (those classes are now available
in all Odoo instead of just the frontend).

This commit fixes the footer "scroll to top" option of the website
builder.

[1]: https://github.com/odoo/odoo/commit/971e5a91aab9
[2]: https://getbootstrap.com/docs/5.0/utilities/api/
[3]: https://github.com/odoo/odoo/commit/e377a084174d
[4]: https://github.com/odoo/odoo/commit/da55072a6935

closes odoo/odoo#101691

X-original-commit: 3a2ad02962fdea254ca46af1f7728b537a6af9cd
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2022-09-30 15:33:00 +02:00
Arthur Detroux (ard) cc8e69d97c [FIX] website: gracefully reject events
Prior to this commit, the WysiwygAdapter would crash with a TB if an
event reached the wysiwyg_adapter when the websiteRootInstance was no
longer accessible (in case of a PageReload while an event in the mutex
is still trying to fire events).

Note that normally, events should not be sent when the
websiteRootInstance is gone as the editor should be destroyed. But
since "widgets_start_request" triggers also implement a "onFailure", it
seems right to use that in such case.

closes odoo/odoo#101687

X-original-commit: 0cc206f94151e2da646064e265e14a341daff58a
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2022-09-30 15:32:58 +02:00
Arthur Detroux (ard) 05857f8d5c [FIX] web_editor: avoid updating ui if a page reload is required
This commit solves an issue detailed below, where an action would be
scheduled while the page is meant to be reloaded, creating a deadlock.

Commit [1] reviewed the hamburger option and introduced a hack so that
if the no-hamburger option is selected while a template which requires
a hamburger is also selected, the option for the default hamburger is
automatically selected.

This is done with a hack that clicks on a button when the ui of the
option is updated. The issue is that the click creates a subsequent ui
update, and since the value will only be updated once the page reloads,
a second click occurs, which triggers a second save request.

With [2] that save request locks the editor because the wysiwyg_adapter
does not expect a second save_request, and starts a second blockUI which
is never removed once the iframe is reloaded.

This commit ensures that the auto-update click happens only once.

Steps to reproduce:
- Edit your website
- Click on the navbar
- Select the Mobile Menu option "Same as desktop"
- Change the header template for one with a hamburger menu
- Click on the navbar => the editor is locked forever.

[1]: https://github.com/odoo/odoo/commit/6854ff8026999a2de20d163ff7118a59c33064c8
[2]: https://github.com/odoo/odoo/commit/03c552690b15cbf2e7d6b7812386ac64042219af

X-original-commit: 15dc96bdf626940b3493e02998f9534d9f393a70
Part-of: odoo/odoo#101687
2022-09-30 15:32:57 +02:00
Arthur Detroux (ard) ebd73104e6 [IMP] web_editor: hide SnippetEditor when no options are shown
Commit [1] moved the switchable views inside a SnippetOption. The
implementation of that ended up creating empty page options
SnippetEditors displayed on every page.

This commit makes sure that if a SnippetEditor doesn't have any options,
it is not displayed.

[1]: https://github.com/odoo/odoo/commit/69af7dcfeb3ff95c40b00ef0cc7c5c0e4021f9d2

task-2687506

X-original-commit: 39d073ccafddf4b3fbe9ec9f5f11849d77c9bdaa
Part-of: odoo/odoo#101687
2022-09-30 15:32:57 +02:00
kanda999 92fae623d4 [FIX] website_sale: add support for custom Authorize Message
closes odoo/odoo#101741

X-original-commit: caa78b880bd256fada8bb106dbc1006b25d29be8
Signed-off-by: William Braeckman (wbr) <wbr@odoo.com>
2022-09-30 14:34:43 +02:00
Soukéina Bojabza d6ce5157ab [FIX] web_editor: fix the resizing history
This commit fixes the issue where the undo of the resizing of an
element is not done in one step.

Steps to reproduce:
- drop a snippet (like text-image)
- resize the image
- undo
=> you have to click multiple times before going back to the initial
size.

task-2968749

closes odoo/odoo#101693

X-original-commit: c4b8a2a6a7548e8a81d1ded58e6bc0e309b02975
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2022-09-30 13:35:59 +02:00
Laurent Stukkens (LTU) be207ca132 [FIX] hr_timesheet: add a space between calendar icon and the date.
task-3000399

closes odoo/odoo#101674

X-original-commit: 4d42ce44b6a1d00490a35ee5ebed6c23e8e30233
Related: odoo/enterprise#32052
Signed-off-by: Xavier <xbo@odoo.com>
2022-09-30 13:35:53 +02:00
Vishnu Vanneri 3f5f534edd [CLA] Vishnu Vanneri
closes odoo/odoo#101649

X-original-commit: 0dd3bfc1f973a71c0e889a3b5c5807c066875422
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2022-09-30 11:36:16 +02:00
Nicolas (vin) 84ac486524 [IMP] account: Add a form view for tax groups
The tax group model doesn't have a form view leading to a left side
bigger than the right side and some fields showing that we don't
want to see.
Thus, we add a form view and hide the field country_code, that is
not needed here since we already see the country_id.

closes odoo/odoo#101519

Signed-off-by: Olivier Colson (oco) <oco@odoo.com>
2022-09-30 11:36:13 +02:00
Odoo's Mergebot 197332697b [FW][MERGE] web(_editor): prepare knowledge embed views support
Prepare support of embed views and complete owlification of commands by
adding preparatory commits. See sub commits for more details.

Prepares Task-2796156
Prepares https://github.com/odoo/enterprise/pull/29423

closes odoo/odoo#101694

Forward-port-of: odoo/odoo#101566
Related: odoo/enterprise#32062
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2022-09-30 10:33:03 +02:00
abd-msyukyu-odoo e6497fb0e8 [IMP] web_editor: ignore data-behavior-props for sanitize
DOMPurify.sanitize removes an attribute that contains a ">" for security
reasons. Make an exception for `data-behavior-props`.

That exception allows Embedded views in Knowledge to store a JSON object
containing the act_window data used to render it as an attribute of the
HTMLElement where it is supposed to be rendered (The view contents are
not saved in the html_field value).

More generally, data-behavior-props should be used when storing properties for a
Behavior Component (see Knowledge module) is required.

Prepares Task-2796156
Prepares odoo/enterprise#29423

X-original-commit: aeb9df5247a3936b1397d8056c1725a1de660b6a
Part-of: odoo/odoo#101694
2022-09-30 10:33:02 +02:00
abd-msyukyu-odoo 62a8aec2b5 [IMP] web_editor: embedded_view requirements
Add a custom class in web_editor to prevent the selection in an embedded view
(or another bloc using that class) from being moved out in multiple situations.
(onselectionchange, onkeyup, onmouseup, ...).

This is related to the block being contentEditable=False.

Prepares Task-2796156
Prepares odoo/enterprise#29423

X-original-commit: 86c14110294c5ff986ee88bb010dbc7513bf8b01
Part-of: odoo/odoo#101694
2022-09-30 10:33:01 +02:00
Nicolas Bayet d8cf028714 [IMP] web_editor: do not alter code pasted from editor
Purpose

Allow users to copy/paste specific elements that are generated by Odoo instead
of sanitizing it on paste. It allows to keep structured data in DOM.

Prepares Task-2796156
Prepares odoo/enterprise#29423

X-original-commit: 36ed4db2b378543d51e6e3eb03962707dbf15b1d
Part-of: odoo/odoo#101694
2022-09-30 10:33:01 +02:00
Damien Abeloos 1f6005070f [IMP] tools: keep additional data when sanitizing
Purpose is to allow to have ``data-behavior-props`` and ``data-prop-name``
on HTML nodes and keep it even when HTML content is sanitized. Those attributes
will be used notably in Knowledge application to store some structured content
e.g. used to populate props.

Prepares Task-2796156
Prepares odoo/enterprise#29423

X-original-commit: 7ddb4685567c115ca4e14fa7e5f845b0cb33fd7c
Part-of: odoo/odoo#101694
2022-09-30 10:33:01 +02:00
Damien Abeloos 7871c75f75 [FIX] mail, web_editor: fix image download links
dowload is actually download.

Prepares Task-2796156
Prepares odoo/enterprise#29423

X-original-commit: d1c130386cbf79c721793c866fcdec47fdaef2bf
Part-of: odoo/odoo#101694
2022-09-30 10:33:00 +02:00
Romain Estievenart 63e3afb783 [FIX] web: DnD a record increment the width of a folded kanban columns
When we introduced the `useSortable` hook [1] and [2], the kanban column
fit the size of the kanban record when the DnD record hovers the column.
This behavior is not desired when the record is hovering over a folded
column, so we apply now a `display:none` value on the record to avoid
the resize of the column.

Steps to reproduce:

1. Go to project
2. Open Office design
3. Try to drag and drop a record to a folded column
   The width of the folded column is incremented to the width of the
   record => bug

Links:
1. https://github.com/odoo/odoo/commit/ebb410accbe3aac051e73031384f640a40544efc
2. https://github.com/odoo/odoo/commit/cf4a8f198fd2daa2b4d9f9f69c5c769c21ff13c5

closes odoo/odoo#101690

X-original-commit: 94e4d6fb432fe64dedf1e65a6ab021855d4c955e
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2022-09-30 09:32:34 +02:00
Ahmad Khanalizadeh 91a3bfc34a [FIX] base: use time zone aware display field for currency rates
Steps to reproduce:

1. change system and admin's time zone to one with a different
date than UTC
2. enable multi-currency in the accounting module
3. add rates for the current date in local time zone and UTC
4. go to settings > currencies
5. the rate for the UTC date is displayed

To fix this, we should use a time zone aware field in `res_currency`.

opw-2945108

closes odoo/odoo#101686

X-original-commit: 2f1d8d6db4efab86d35f362138e80e03692537dd
Signed-off-by: William André (wan) <wan@odoo.com>
Signed-off-by: Khanalizadeh Ahmad (khah) <khah@odoo.com>
2022-09-30 09:32:29 +02:00
Ricardo Gomes Rodrigues (rigr) 6d20a149cc [FIX] account_edi_ubl_cii: fallback on item name if no description
If a user imports a FacturX where an item has a name but no description, the invoice is not created.

We now use the item name as a fallback in case there is no description.

opw-2951705

closes odoo/odoo#101682

X-original-commit: 8826993ffb658d6df513a3ce4a316c1aa09d428e
Signed-off-by: Josse Colpaert <jco@odoo.com>
Signed-off-by: Ricardo Gomes Rodrigues (rigr) <rigr@odoo.com>
2022-09-30 09:32:27 +02:00
William Braeckman bca87fd5ab [IMP] hr_fleet: migrate hr_fleet_kanban to wowl2
closes odoo/odoo#101681

X-original-commit: 443123b64e2984026541c44c524f20c7f08eda0b
Signed-off-by: Kevin Baptiste <kba@odoo.com>
Signed-off-by: William Braeckman (wbr) <wbr@odoo.com>
2022-09-30 09:32:23 +02:00
aliya 4e07c2c788 [FIX] account: accrued entries width should be 100%
Preview of accrued entries should occupy full width.

closes odoo/odoo#101680

X-original-commit: 046dbe3ed48054b0c390ae1edb2e1dea9315acfb
Signed-off-by: Cedric Snauwaert <csn@odoo.com>
2022-09-30 09:32:20 +02:00
Bruno Boi 7e1304c137 [FIX] web: color edition of many2many_tags_field
Before this commit
Can display the color list picker event if no color_field has been set.
This could lead to a traceback if a color is selected.

After this commit
The field does not allow to show the color list without a color_field.

closes odoo/odoo#101679

X-original-commit: 160ba4b4edfde052d9881a23294ceafc0ceec278
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2022-09-30 09:32:18 +02:00
Didier (did) e62c11bafa [FIX] mail: avoid generation link preview on internal link
If website is installed, the login page of Odoo has opengraph meta that will be
used to create link preview on mention and channel link.
This PR add a xpath condition to always ignore mention and channel link in the
message body.

Part of task-3000274

closes odoo/odoo#101678

X-original-commit: eb032a5c36af6402b79ae768ce29b3d84eacf3b7
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Signed-off-by: Debondt Didier (did) <did@odoo.com>
2022-09-30 09:32:15 +02:00
Aaron Bohy ba82155b8a [IMP] web: add legacy view logging in debug mode
This helps tracking views that still need to be converted, like we
already do for fields.

closes odoo/odoo#101676

X-original-commit: aea1b4af1d88b19392eb9f42a42fd970017d5630
Signed-off-by: Géry Debongnie <ged@odoo.com>
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2022-09-30 09:32:11 +02:00
Didier (did) 3bef7380e0 [FIX] mail: fix link preview delete dialog size
part of task-3000274

closes odoo/odoo#101675

X-original-commit: e3773fe78f0cd652cecef0500611ac6988648e87
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Signed-off-by: Debondt Didier (did) <did@odoo.com>
2022-09-30 09:32:08 +02:00
Renaud Thiry be53351746 [FIX] web_editor: Invalid import in test
Imported unsplash in web_editor when it was not a dependency.
This caused the test to fail when web_unsplash was not installed.

As it is necessary to import it when the module is installed,
this test is moved to test_website as both modules are installed there.
(Also updated to ES6 import syntax + odoo-module style test)

task #3000801

closes odoo/odoo#101672

X-original-commit: d85ba585ec4642a507d24ab94606a65970c635f3
Signed-off-by: Stéphane Debauche (std) <std@odoo.com>
2022-09-30 09:32:03 +02:00
svs-odoo 780c00dd28 [FIX] stock: warehouse delivery steps
Since that commit: dd7f4d501a4d23b04a1899be8fd51cc583673c9d
A picking type cannot make the scan of the source location mandatory if
the scan of the destination source is optional.
An error is raised in case the user tries to edit and save a picking
types with this erronous config but there is also an issue if the user
tries to set the outgoing shipments in 2 or 3 steps.
The method `_create_or_update_sequences_and_picking_types` was the cause
of this issue because of an `update` on the `stock.picking.type`.
We try to update `restrict_scan_source_location` to "mandatory" and
`restrict_scan_dest_location` to "no" for the pick operation, the issue
is with `update`, each field is write one by one, and so, it will write
on `restrict_scan_source_location` first while `restrict_scan_dest_location`
is still set on "optional".

To fix that, we replace the `update` by a `write`.

closes odoo/odoo#101663

X-original-commit: 07fb4af8c68ae1296e796c2f3714823ed828e680
Signed-off-by: Arnold Moyaux (arm) <arm@odoo.com>
Signed-off-by: Steve Van Essche <svs@odoo.com>
2022-09-30 09:31:57 +02:00
Rémi Rahir 8f379d8ae5 [FIX] spreadsheet: Fix Odoo chart duplication
Odoo charts have a specific need of dataSources for their runtime data
(in oppostion to standard graphs). In order to link the chart with its
datasource, we injected the chart id inside its definition in order to
be able to fetch the corresponding datasource. Unfortunately, this
approach require that we can access the chartId from anywhere which is
unfortunately not the case when we copy/cut/paste a chart. The current
implementation would copy the chart while keeping a reference to the
same datasource, thereby keeping the same data and be submitted to the
same filters as the original chart dataSource.

Note that a chart should not be aware of its own id; that is, its place
in the mapping of a plugin.

This commit changes the approach to set the dataSource inside the chart
directly through a method only available on OdooChart instances.

This problem would also arise on sheet duplication but was due to a
problem in the library itself.

task 2998207

closes odoo/odoo#101660

X-original-commit: 47f7cc08bec749301001c6c4567cafbcea8bd552
Signed-off-by: Pierre Rousseau (pro) <pro@odoo.com>
Signed-off-by: Rémi Rahir (rar) <rar@odoo.com>
2022-09-30 09:31:55 +02:00
Martin Trigaux e856beb782 [I18N] *: export 16.0 source terms
closes odoo/odoo#101659

Related: odoo/enterprise#32040
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2022-09-30 09:31:52 +02:00
Lucas Lefèvre f07cd645c9 [FIX] tools: don't extract missing spreadsheet data source name
Previous versions of spreadsheet files don't have a name
for list and pivot datasources.

The spreadsheet template "pipeline dashboard" in `document_spreadsheet_crm`
is such a file.
As a consequence, exporting the source terms from this module fails
with a `KeyError: 'name'`

Part-of: odoo/odoo#101659
2022-09-30 09:31:52 +02:00
Martin Trigaux e1af8cd69c [IMP] *: correct tyspo and erors
Also clarify messages

Part-of: odoo/odoo#101659
2022-09-30 09:31:52 +02:00