Commit Graph
164380 Commits
Author SHA1 Message Date
tsm-odoo a6bc6d00da [FIX] mail, im_livechat: fix channel member wrap
Both language and country are displayed in the channel member list. Before this
commit, this was displayed in one line when available which looked bad. This
commit allow those items to wrap for a better display.

closes odoo/odoo#130220

Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2023-08-01 22:30:51 +02:00
Sébastien Theys f9aedceb9f [REF] mail, im_livechat, *: move code and remove patches from sidebar
* = hr_holidays

Part of task-3265211

closes odoo/odoo#130003

Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2023-08-01 22:30:47 +02:00
Géry Debongnie 600bd9c81f [IMP] web: only display technical tooltips if debug is set in url
This commit aims to minimize a very annoying issue that comes up
frequently: it is often necessary to go in debug mode to configure odoo
for a demo. Then, if we don't explicitely remove debug mode, it will
persist (because it is stored in the session). As a result, technical
tooltips will be visible during the demo, which may be distracting and
give a bad impression, because these tooltips are designed to provide a
lot of technical information.

It is not clear how we could solve the problem. Many questions arise
when discussing the issue:
- splitting technical and debug mode
- removing debug mode from the session
- but still making sure tests works
- what information should be displayed in ui?
- if debug mode is not persistant, find a way to make it temporarily
active

There are a lot of different opinions and needs that are not easily
solved.  This commit does not pretend to solve them, it is just a quick
way to reduce the issue mentioned above, by changing the JS code to only
use debug mode if it is explicitely set from the url.

Concretely, it means that the "js" specific debug features are
configured only with the debug parameter in the url:
- technical tooltips
- owl props validation
- displaying the debug menu

The rest will keep working as before:
- debug=assets
- debug=tests
- additional menu items/fields

Again, this commit is just a quick fix, until someone can find a spec
that get enough traction.

closes odoo/odoo#130060

Taskid: #3255925
X-original-commit: 59f49d6a8c856a5d8ca28dcfd7840baaa1c7672f
Related: odoo/enterprise#44783
Signed-off-by: Géry Debongnie <ged@odoo.com>
2023-08-01 17:56:45 +02:00
Nicolas Bayet 1feeeda8b8 [FIX] web_editor: synchronise fields with oe_unremovable
When the mechanism that synchronise odoo fields contained an
unremovable, even though no unremovable got removed, the Odoo editor
would rollback as the syncing mechanism would set innerHTML to the
synced nodes, which would remove the unremovable. To prevent the
rollback in that kind of circumstance, this commit introduce a new
method on the OdooEditor `withoutRollback`.

task-3436834

closes odoo/odoo#129320

Signed-off-by: David Monjoie (dmo) <dmo@odoo.com>
2023-08-01 15:09:24 +02:00
Deependra Solanki 0c4d747aaf [IMP] web_editor: different numbered list marker at each level
Purpose:

To make the marker of a ordered list different at each level.
- Numbers for first level.
- Alphabets for second level.
- Roman numbers for the third level.
looping back to numbers if nested further.

To make the marker of a unordered list different at each
level.
- Disc for first level.
- Circle for second level.
- Square for the third level.
looping back to disc if nested further.

task-3412826

closes odoo/odoo#128532

Signed-off-by: David Monjoie (dmo) <dmo@odoo.com>
2023-08-01 15:09:17 +02:00
Valentin Vallaeys (vava) b610f2502d [FIX] (stock_)delivery: move test for real invoice on back order
In this commit*, the forward-ported test was not moved with the fix on
stock.picking from delivery to stock_delivery, although the test relies
on real invoicing, which is defined in stock_delivery.

Fixes build error 22434

* e1e04f3a176e15fdce81ce3036093d3951401f52

closes odoo/odoo#130217

X-original-commit: 5518daae14aa91e3c2c6723c6059f337c6ee0914
Signed-off-by: Antoine Vandevenne (anv) <anv@odoo.com>
Signed-off-by: Vallaeys Valentin (vava) <vava@odoo.com>
2023-08-01 13:51:47 +02:00
Valentin Vallaeys (vava) feb15f6be6 [FIX] website_sale: fix tour on free delivery
The tour was using a payment provider that was not installed. This
commit makes sure the test only runs when the payment provider is
installed.

Fixes build error 19829

closes odoo/odoo#130214

X-original-commit: ba75b1c023988e17852821ddaf32163c2e2f9d6e
Signed-off-by: Antoine Vandevenne (anv) <anv@odoo.com>
Signed-off-by: Vallaeys Valentin (vava) <vava@odoo.com>
2023-08-01 13:51:44 +02:00
Rodolpho Lima cdc8e4daad [FIX] web_editor: images stored as base64-encoded sources
Commit [1] introduced an option in the Wysiwyg widget to save pasted
and dropped images as attachments instead of keeping them as inline
base64-encoded sources.

In order to prevent records from having excessively large sizes in their
html field content, this commit makes such option the default one for
the Wysiwyg class.

task-3289061

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

closes odoo/odoo#130213

X-original-commit: 7e06b40ea58f58069729f881f7d4559d17778fe7
Signed-off-by: David Monjoie (dmo) <dmo@odoo.com>
2023-08-01 13:51:40 +02:00
Rodolpho Lima eca5bfae0f [FIX] website: missing super call in _getEditorOptions
Since the refactor done in [1], the default Wysiwyg options is not
applied to the final options object when the website's
WysiwygAdapterComponent is instantiated. This happened because the
`_getEditorOptions` method is overriden without calling `super`.

As a result, before this commit, commands like "video" or "image" were
no longer available when editing text in website, as the options that
enable such commands were missing.

This commit fixes it by calling super in the overriding method.

[1]: https://github.com/odoo/odoo/pull/118966/commits/fed6569c9671c61269ed7ffa3bfcdb919a0daf14

X-original-commit: 9f2ebb7ffa3742d7da369f5020d57317c5a1794a
Part-of: odoo/odoo#130213
2023-08-01 13:51:40 +02:00
Victor Feyens f5de88f3b5 [FIX] sale: failing test with localizations
The test verifying the values of the sale report in a multi-comp & multi-curr
environment relies on the fact that the main company is by default in USD.
Nevertheless, the test fails when a localization is installed (if it changes
the currency of the main company).

This commit makes sure the tests always works, and resurrects the right tool
for that, which was dropped in commit 3752b3166e.

Cf runbot build error 22351

closes odoo/odoo#130201

X-original-commit: a73b5fce4fb02eefc681c55eab8f57cd35105226
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
2023-08-01 13:51:32 +02:00
Pierre Pulinckx (pipu) 60fe2e9b17 [REF] *: remove _lt()
In a previous commit 8bfa76a, _lt() returns _t().
So, in this commit, all usages of _lt() are replaced by _t().

task-3292454

closes odoo/odoo#130179

Related: odoo/enterprise#44906
Signed-off-by: Luca Vitali (luvi) <luvi@odoo.com>
2023-08-01 13:51:17 +02:00
Aaron Bohy 9ed6036861 [REF] web: RelationalModel: add option to display invalid notif
This commit removes a function from the Record datapoint, and
replaces it by an option to checkValidity, as we want Record to
have a few public methods as possible.

Part of task~3179751

closes odoo/odoo#130170

Signed-off-by: Jorge Pinna Puissant (jpp) <jpp@odoo.com>
2023-08-01 10:55:51 +02:00
Aaron Bohy 9d81cff6fd [REF] *: remove always_reload many2one option from archs
This option is no longer necessary since [1] as the value is now
reloaded by default.

[1] odoo/odoo#114024
Part of task~3179751

closes odoo/odoo#130169

Related: odoo/enterprise#44838
Signed-off-by: Jorge Pinna Puissant (jpp) <jpp@odoo.com>
2023-08-01 09:40:55 +02:00
Leloup Loïc (lole) b3740bc5ce [FIX] mail : fix activitycell date
When on helpdesk app (or any app with an activity view), if you go on the
activity view while having activities due on a previous year it will
cause a traceback "TypeError: date.toLocaleDateString is not a function"

This happens because the function tries to call toLocaleDateString on a
datetime variable, not a date one.

opw-3432005

closes odoo/odoo#130090

X-original-commit: 81ec723b3956f198d5de99a5a4214359f67b8327
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2023-08-01 08:39:24 +02:00
FrancoisGe 6424edb254 [FIX] *: convert record.data.id => record.resId
Since the relational model was rewritten (PR 114024), the record id is
no longer present in data by default. The correct way to access the id of
a record is to do record.resId.

closes odoo/odoo#130061

Related: odoo/enterprise#44785
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2023-08-01 07:04:57 +02:00
miad-odoo 7bc89a1c34 [FIX] base: fix traceback install demo data
This commit fixes a traceback when trying to install demo data from the UI.

Steps to reproduce:
	- create a database with website_event_track_live installed and without demo data
	- load demo data from the UI (settings)
	- odoo.exceptions.AccessError: You are not allowed to create 'Website Visitor'
(website.visitor) records.

There is a traceback because the installer can't create `website_visitor`
records because there are no groups that have create access rights for that
model.

This is because xml_import used to get an environment with root privileges, that
can bypass access rights, but now the environment is a parameter passed to the
function and doesn't necessarily have sudo

This change was introduced in
5bf1207#diff-8e4705d5ab335a8dfc2c70eeedc502a92695989f97c4f19184b49634c2c4ad55L583-R583
; with this commit, the environment used by xml_import doesn't necessarily have
sudo, so we simply make sure `load_demo` loads data with sudo.

Task-3202914

closes odoo/odoo#129946

X-original-commit: 85834371e0eede05858cb2dc33412396c6e5c5bf
Signed-off-by: Denis Ledoux (dle) <dle@odoo.com>
Signed-off-by: Adrien Milis (miad) <miad@odoo.com>
2023-08-01 07:04:53 +02:00
Thomas Beckers 6176d14500 [FIX] l10n_es_edi_sii: trim DescripcionOperacion for complience
Based on the SII documentation, DescripcionOperacion should have max 500
characters. Since it's based on invoice_origin field it can exceed this limit.

Now this value will be trimmed to the first 500 characters.

opw-3421094

closes odoo/odoo#130184

X-original-commit: 876d1a216eda4eb9ea1b3eb15a94cea10c4f25f9
Signed-off-by: Florian Gilbert (flg) <flg@odoo.com>
2023-08-01 05:59:54 +02:00
Jurgen (jugj) f05bfd6d52 [IMP] hr : Add job_id to employee form view
task-3373010

closes odoo/odoo#130182

X-original-commit: 0ec1d07fc3dce383efb709b0067939bd13e5e2eb
Signed-off-by: Sofie Gvaladze (sgv) <sgv@odoo.com>
Signed-off-by: Jurgen Gjini (jugj) <jugj@odoo.com>
2023-08-01 05:59:51 +02:00
Alexandre Kühn d1dbff25eb [FIX] mail: mention suggestions at bottom on editing chatter message
Before this commit, when editing a message in chatter and
typing `@` to display mention suggestions, the list changed
position between `top` and `bottom` based on content size of
suggestion list.

This happens because by default suggestion list in composer are
positioned `top`, as most composers are at the bottom of screen,
and message to be edited are recent messages, which are usually
at the bottom of screen.

Chatter is special in that composer is at the top of the screen,
and recent messages are shown at the top of screen too. The better
position in this configuration is `bottom`.

Condition was on composer being linked to chatter thread, which is
the case when posting a message for the 1st time. While editing a
message however, the composer is linked to a message and not a
thread, therefore the condition `thread?.type === 'chatter'` was
falsy and default position `top` was chosen. Due to position being
a recommendation and placement of composer at the top of screen,
with many mentions it was displayed at `bottom`, and with few
suggestions it changed to `top`.

This commit fixes the issue by relying on the context of the
composer with `env.inChatter`, which covers all chatter used in the
displaying of chatter with composer at the top, including when
editing a message.

closes odoo/odoo#130106

X-original-commit: a03705d0f55e887ec05cb41d7cf86db748f77955
Signed-off-by: Matthieu Stockbauer (tsm) <tsm@odoo.com>
2023-08-01 04:32:07 +02:00
Maximilien (malb) b59e4f73b9 [FIX] account: automatic entries crash
When having a python format in the ref (or memo) of a payment, going to journal
items, select the move and doing an automatic entries, when changing the account
 a traceback appears.

 In the _format_new_transfer_move_log, we create a format that will be put in
 the chatter. In this message we use python format without considering the
 possibility that we can have one in the link of the move.

 By putting the python format before formatting the link, the issues is solved.

 task: 3434131

closes odoo/odoo#130091

X-original-commit: 12e0e6a492a010d61a8a1f763c72e25765654511
Signed-off-by: Laurent Smet (las) <las@odoo.com>
Signed-off-by: Maximilien La Barre (malb) <malb@odoo.com>
2023-08-01 04:31:56 +02:00
FrancoisGe 9d2656720c [REF] *: remove model.notify()
Since the relational model was rewritten (PR 114024), it is now reactive,
so it is no longer necessary to use model.notify() to render the view.

closes odoo/odoo#130058

Related: odoo/enterprise#44781
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2023-07-31 23:21:18 +02:00
tsm-odoo b5896c9d03 [IMP] *: add generic make_jsonrpc method in tests
*: bus, crm_livechat, crm_mail_plugin, im_livechat, payment, payment_demo,
pos_online_payment, test_discuss_full, test_mail_full, tests, website_livechat,
website_sale.

Several python tests have their own way to make jsonrpc requests. This PR adds a
generic `make_jsonrpc_request` method to the `HttpCase` in order to provide a
generic way to do so.

At the same time, calls to `_open_livechat_channel` are removed in favor of
jsonrpc request to `get_session`. This makes the tests more realistics (some
incoherences were present like passing `country_id` to the open channel method
while the user country id is not set...)

Finally, this will ease the diff in the PR introducing livechat visitors as mail
guests.

part of task-3332628

closes odoo/odoo#130036

Related: odoo/enterprise#44840
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2023-07-31 23:21:10 +02:00
Samuel Degueldre 8f68a146bf [IMP] web: check for undesirable module dependencies
Previously, we have accidentally made some core modules depend on some
modules outside of the core folder (eg views), this is undesirable as it
can make assets bundle hard to write using globs, and can make it easy
to introduce circular dependencies, it also doesn't make sense from a
code-organisation perspective.

This commit introduces a QUnit test that checks the modules in some
folders only depend on other whitelisted folders.

closes odoo/odoo#129982

Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2023-07-31 20:54:01 +02:00
Julien Alardot (jual) 55f8f3b1c0 [FIX] hr_expense: fix create report button
On the hr.expense.tree view the create report button
raises an error since some recent framework refactor
This applies the related changes missed during the refactoring

related commit: 8723f020c3

closes odoo/odoo#129910

Task-id: None
Signed-off-by: Brice Bartoletti (bib) <bib@odoo.com>
2023-07-31 20:53:58 +02:00
Pierre Rousseau 036307ba26 [REM] web, *: remove legacy dialog
OwlDialog is not used anymore, therefor we can remove it.

Task-id 3439226

closes odoo/odoo#129774

Related: odoo/enterprise#44634
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2023-07-31 19:02:58 +02:00
Pierre Rousseau 3b2ba11b20 [REF] website_sale_product_configurator: remove legacy dialog
This commit replaces the legacy dialog by the new one.

Part of task-id 3439226

Part-of: odoo/odoo#129774
2023-07-31 19:02:58 +02:00
Pierre Rousseau 72dbb75d4d [REF] web, barcodes: remove legacy dialog
This commit replaces the legacy dialog by the new one.

Part of task-id 3439226

Part-of: odoo/odoo#129774
2023-07-31 19:02:57 +02:00
niyasraphy 83ed99d973 [IMP] account: remove unused function
before this commit, the create_cash_statement function
defined in the journal model is not called from any
where.

left over in:  https://github.com/odoo/odoo/commit/9299f81f19a87d6e6eb9ee19a79d96d3fb1050b2

after this commit, the function will be removed from
code.

closes odoo/odoo#129304

Related: odoo/enterprise#44453
Signed-off-by: John Laterre (jol) <jol@odoo.com>
2023-07-31 19:02:49 +02:00
Pierre Pulinckx (pipu) 3bc94e52ce [REF] *:Replace moment usages with luxon
luxon and moment are both used in the solution,
but these two libraries facilitate the manipulation
of dates. It was decided to replace all uses of
moment with luxon so we can then remove
moment.js from the code and lighten the assets.

task-3391739

closes odoo/odoo#128752

Signed-off-by: Bruno Boi (boi) <boi@odoo.com>
2023-07-31 19:02:45 +02:00
Odoo's Mergebot f97e704fb4 [MERGE][IMP] web: improve properties selection options ordering
This merge commits contains 2 improvements aiming to simplify the ordering of
selection options for property fields:

- Correctly insert the new element at the right position when pressing enter
- Allow to drag & drop property values

See underlying commits for details.

Task-3338157

closes odoo/odoo#123216

Signed-off-by: Warnon Aurélien (awa) <awa@odoo.com>
2023-07-31 19:02:30 +02:00
std-odoo dab3771377 [IMP] web: allow to drag-and-drop properties selection options
Purpose
=======
Allow drag-and-drop properties selection options in order to
re-arrange them.

Task-3338157

Part-of: odoo/odoo#123216
2023-07-31 19:02:28 +02:00
std-odoo 9348dfd70d [IMP] web: properties selection, insert after the focused option
Purpose
=======
Currently, when we want to add a properties selection option, we need
to focus another option and press enter. This will add the new option
at the end, but we want to add it just after the focused option.

Task-3338157

Part-of: odoo/odoo#123216
2023-07-31 19:02:28 +02:00
Mahamadasif Ansari 19f06f9c86 [FIX] account: don't execute the query when the wizard has no moves
Currently, errors occur when the 'Send invoices automatically' cron
is run this is because the related invoice is deleted and we receive an
empty record in move_to_lock when executing the query.

Step to produce an error:
- Install 'Invoicing'
- Create an invoice e.g. 'INV/2023/00001'
- Click on confirm > Click send & print
- Now in wizard don't click 'Send & print'
- Now go to home screen or close current window
- Open 'INV/2023/00001' invoice and click 'Reset to draft' and delete it
- Go to scheduled action and open 'Send invoices automatically'
- Click on 'Run Manually' >> error occur

This commit fixed the above issue by not the query
from executing when move_to_lock has an empty record.

sentry-4291237277

closes odoo/odoo#130021

X-original-commit: a2c855970ab56f5ef7acf08eeaf8ff45c1eca8c9
Signed-off-by: Laurent Smet (las) <las@odoo.com>
2023-07-31 16:11:16 +02:00
FrancoisGe fd98a3f4a0 [FIX] web: uses the right activeFields based on the view of an x2m
This commit allows the correct activeFields to be used depending on the
view used to open an x2many field.

Before this commit, if we had an x2many field with a list view and a form
inline view with the same field containing a different context depending
on the view. The context of the form view will always be used.

This is a problem:
If we have an inline form view with fields common to the list view,
the context of the activeFields in the form view will always be used
and we will try to combine the different modifiers (required, readonly, etc.).
We don't want to do this, we want to use the activeFields of the list view
when we open the record in the list and the activeFields of the form view
when we open the record in the form view.

Solution:
When we create the activeFields, we'll use the activeFields from the
list view and complete them with those from the form view. We will
therefore no longer replace or merge them.
Then, when we open a record in form view, we'll use the activeFields
from the form view and when the form view closes, we'll restore the
activeFields from the list view.

closes odoo/odoo#129989

Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2023-07-31 16:11:13 +02:00
FrancoisGe e6f987ed18 [FIX] web: onchange create a record in an invisible x2m
Before this commit, in a form view with an x2many that contains an
invisible x2many, if an onchange returns a create command for the
invisible x2many field, a crash is displayed.

Problem:
The getCommands function for processing CREATE commands needs the
activeField of the x2many to be present with activeFields and fields.
Currently, the activeField of an invisible x2many has no related fields.

Solution:
All x2many fields have "related" in the activeField by default.

Part-of: odoo/odoo#129989
2023-07-31 16:11:12 +02:00
Odoo's Mergebot 5a9fe7a7d0 temp rebasing PR 129864 (5cf55f7f33) 2023-07-31 16:11:02 +02:00
Nasreddin Boulif (bon) cbff652b10 [FIX] website[_slides]: Unhide conditional elements in fullscreen
Steps to reproduce:

  - Install `website_slides` module
  - Create a course and add a slide of type `Article`
  - Go to frontend and edit the slide
  - Add a text element and edit conditional visibility
    (e.g. visible only if user logged in)
  - Save and open the slide in fullscreen mode (with any logged user)

Issue:

  The text block is missing.

Cause:

  The slide is rendered in lazy load after that the code that unhide
  conditional elements is already executed (on event `DOMContentLoaded`)

Solution:

  Extract the concerned code so it can be called and re-executed after
  the slide is rendered also in fullscreen.

opw-3225444

closes odoo/odoo#129646

X-original-commit: 553702c99cbd90edfb509ca9e7ab0c99c73a96e6
Signed-off-by: Nasreddin Boulif (bon) <bon@odoo.com>
2023-07-31 16:10:58 +02:00
flvr-odoo db984cb696 [FIX] website, test_website: make reset_template a json route
task-3439417

closes odoo/odoo#129611

Signed-off-by: Romain Derie (rde) <rde@odoo.com>
2023-07-31 16:10:54 +02:00
Jorge Pinna Puissant 5cf55f7f33 [FIX] web: Kanban progressbar update count after domain change
- open a grouped kanban view with progressbar;
- select a progressbar;
- the records are filtered and the count/aggregate is updated;
- change the filter/domain that will reduce/increase the filtered
  records.

Before this commit, the records are correctly update but the
count/aggregate is not update.

Now, the count/aggregate of a selected progressbar is updated if the
domain changes.

task-3422009

X-original-commit: 95a94e0d928729bbbc80a627f816f9e575121f8d
2023-07-31 09:36:15 +02:00
tsm-odoo f2bd7ec027 [FIX] mail: fix link previews overflowing chat window
This PR fixes an issue were link previews could overflow
the chat window.

closes odoo/odoo#129829

X-original-commit: 24de4e1adc9ad427daa7319480fc8004cde626dc
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2023-07-27 05:18:51 +02:00
Alexandre Kühn 29ca8f806a [FIX] mail: chat window state should sync crosstab
Before this commit, chat windows state (open/close/folded) was not
syncing between browser tabs. This lack of feature makes using chat
in crosstab quite inconvenient.

This feature exist in 16.2 and was mistakenly removed from rewritting
of Discuss code in 16.3. This commit reimplements as it was in 16.2.

Task-3435120

closes odoo/odoo#129812

X-original-commit: 8f27d1f254e79becf6886cdb90a1af14b28e9946
Signed-off-by: Matthieu Stockbauer (tsm) <tsm@odoo.com>
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2023-07-27 05:18:49 +02:00
Louis Wicket (wil) 8d4650e673 [I18N] l10n_it_edi: restore missing translation
closes odoo/odoo#129754

X-original-commit: 1d316430b77e6efc7dc4501f2e8cfc78d6da9a39
Signed-off-by: Louis Wicket (wil) <wil@odoo.com>
2023-07-27 05:18:46 +02:00
momegahed 2c072ccf91 [FIX] account: Automatic Entries wizard on invoice with date in the past
Steps to reproduce:
1. Create an invoice with an Invoice Date in the past
2. Confirm the invoice
3. In Journal Items tab, click cut-off and then create journal entries
4. Traceback

opw-3369709

closes odoo/odoo#129689

X-original-commit: 219f9f929bb18f60a85e7fa3eb6868f954931f55
Signed-off-by: Habib Ayob (ayh) <ayh@odoo.com>
Signed-off-by: Mohamed Megahed Abbas Megahed SALLAM (mome) <mome@odoo.com>
2023-07-27 05:18:44 +02:00
Xavier-Do fd8ec5001d [FIX] tests: reset sequence at the end of test
Some test may perform a request without being in test_mode

In this case, a check signaling could be called and since the sequence
was incremented the registry may be reloaded.

This is a simple fix to avoid this issue waiting for a stronger check.

closes odoo/odoo#129814

X-original-commit: 41bb17b3046e8f1605d6f893ca1807d77ed21173
Signed-off-by: Xavier Dollé (xdo) <xdo@odoo.com>
2023-07-27 03:50:53 +02:00
Laurent Smet 8bdb52c26d [FIX] account: Send & Print only for sales documents
We are currently able to open the send & print for a vendor bill.
It doesn't make any sense to ask to a vendor to pay its own invoice.

closes odoo/odoo#129793

X-original-commit: b3e8229d16be074a719fa07e3b2d5488ace66492
Signed-off-by: John Laterre (jol) <jol@odoo.com>
Signed-off-by: Laurent Smet (las) <las@odoo.com>
2023-07-27 02:21:34 +02:00
Arthur Jochems (ajoc) 74f6e4e886 [IMP] stock: products created from replenishment default to storable
The current default is "consumable". This is at odds with the nature of
replenishable products, as "consumable" does not keep track of stock
numbers.

task-3439196

closes odoo/odoo#129775

Signed-off-by: Arnold Moyaux (arm) <arm@odoo.com>
2023-07-27 02:21:29 +02:00
Louis Wicket (wil) 8b5f022a51 [IMP] mail: don't convert iterables to arrays in t-foreach
As of Owl 2.2, it is now possible to use iterable directly in t-foreach
without having to convert it to array first.

This commit takes advantage of this new feature to remove the
unnecessary array conversions from the Discuss code.

closes odoo/odoo#129765

Signed-off-by: Louis Wicket (wil) <wil@odoo.com>
2023-07-27 00:55:07 +02:00
Xavier Bol (xbo) 51fa29dabd [FIX] sale_{project,timesheet}: display allow_billable in sale_project
Before this commit, when `sale_project` module is installed and not
`sale_timesheet` module, `allow_billable` field is displayed in
Settings tab in form view of project but not in the form view
simplified. In the simplified one, `allow_billable` field is  only
displayed when `sale_timesheet` is installed.

This commit displays `allow_billable` field in form view simplified
of `project.project` when `sale_project` is installed to be coherent
with the main form view.

closes odoo/odoo#129584

X-original-commit: ae203aa3cccc1187197ff0be98a884ca8ce6d6d1
Related: odoo/enterprise#44566
Related: odoo/upgrade#4975
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
2023-07-27 00:54:56 +02:00
Xavier Bol (xbo) 83706f4d00 [FIX] {sale_}project: move project_enterprise_tour in project
Before this commit, the `project_enterprise_tour` has a step to
check `allow_billable` field in project to make the new project
billable to get partner field visible. The problem is this step
cannot be achieved if `sale_project` module is not installed.

This commit moves `project_enterprise_tour` is project module
to easily override it in `sale_project` and `project_enterprise`
modules to be sure the tour works when `sale_project` is not installed
and also when that module is installed.

X-original-commit: f09245f4dae4c3503630c9cd92b9d9ab5bfb6e78
Part-of: odoo/odoo#129584
2023-07-27 00:54:56 +02:00
vlst 669b9fcc2f [IMP] point_of_sale: add product combos
In this PR we introduce the ability to create product combos.

Now any product can be turned into a combo meal by defining
the different combo choices it contains.

In this PR, we add the backend logic and the backoffice views
needed for this feature. Afterwards, different modules will be
able to use the platform provided by this PR in order to integrate
`product combos` in their flows. Such modules are the `point_of_sale`
and `pos_self_order`.

closes odoo/odoo#128857

Task: 3430635
Signed-off-by: Joseph Caburnay (jcb) <jcb@odoo.com>
2023-07-26 23:15:05 +02:00