Commit Graph
168880 Commits
Author SHA1 Message Date
Mahdi Cheikh Rouhou (macr) 2b65959cdc [FIX] web_editor: sign documents with safari 15.4+ with ios
Issue:
=====
Users with IOS can't sign with safari.

Steps to reproduce the issue:
=============================
- Install sign
- Make sure you have a template which has at least one signature sign
  item.
- Share the document and open the link with ios on safari in v 15.4+
  (browserstack) for example.
- Go to the signature sign item and use auto and click sign or sign all
- Nothing will happen.

Origin of the issue:
====================
https://github.com/niklasvh/html2canvas/issues/2864

Solution:
=========
https://github.com/niklasvh/html2canvas/issues/2864#issuecomment-1111044861

opw-3660682

closes odoo/odoo#149903

X-original-commit: f11723f406f2af95090bdd13e9acb30c89014638
Signed-off-by: Jorge Pinna Puissant (jpp) <jpp@odoo.com>
2024-01-18 15:11:59 +00:00
Paul Stroobant 98b1346bb9 [FIX] product: remove extra content option on dymo format label
Steps to reproduce issue:

1. Go to Products.
2. Select a Product with an existing Barcode.
3. Click on Print Labels.
4. Select Dymo as format, add Extra Content, Confirm.
5. Extra Content is not shown.

Explanation:

The Extra Content is pushed out of the label by the other elements.

Suggested fix:

Remove Extra Content to make up for lack of space. Approved by PO (thd) and already removed on other label formats.

opw-3614842

closes odoo/odoo#149843

X-original-commit: 0cf6e768d8c307e4d6c9b85b78664dd82d8a4416
Signed-off-by: William Henrotin (whe) <whe@odoo.com>
Signed-off-by: Stroobant Paul (stpa) <stpa@odoo.com>
2024-01-18 15:11:58 +00:00
Jay Savaliya 2fa8c6e208 [FIX] website_slides: retrieve space between checkbox and label
This commit retrieves space between checkbox and label in course groups from
view which may be lost in a major owl refactor(https://github.com/odoo/odoo/commit/48ef812a635f70571b395f82ffdb2969ce99da9e) in form view.

Task-3557567

closes odoo/odoo#149811

X-original-commit: a07e63a0e511a5e382f83da3555d4a469d3f12f4
Signed-off-by: Warnon Aurélien (awa) <awa@odoo.com>
2024-01-18 13:46:51 +00:00
adsh-odoo dad42805f1 [FIX] portal_rating: keep comment section on canceling edition
Steps to Reproduce
===================
1 Open any course
2 Add a review / or edit the review
3 Go to the Reviews tab. (you will find a comment button under each review)
4 Post a comment on any one review.
5 Now from the 3 dots, click on Edit
6 Now, your mind has changed and you don't want to edit anything.
  Click on the "Cancel" button.
The whole comment section disappears, including the existing comment if any, and
the 'comment' button on the parent comment.

Technical
=========
This issue was introduced after the removal of qweb https://github.com/odoo/odoo/commit/6303a3eacdca012649a2ffda627b65c17a7217f1

After this commit
==================
The comments section appears properly after canceling the edition.

Task-3642425

closes odoo/odoo#148415

Signed-off-by: Warnon Aurélien (awa) <awa@odoo.com>
2024-01-18 13:46:50 +00:00
william-andre b4de10fdc5 [FIX] account,*: remove manual use of check_move_validity
TLDR: the context key `check_move_validity` should never be used
explicitly.

`check_move_validity` is a context key used to disable some important
integrity check in accounting: `debit=credit`, which is one of the most
fundamental rule.
It is possible to disable this in some cases, when creating and updating
lines one by one, since the constraint cannot be satisfied between each
line if the operations are not atomic.

A mechanism has been created for this, with `_check_balanced`. It is a
context manager using `_disable_recursion`, which will taint all
the contexts while inside of the context manager.
Putting any code changing lines one by one inside of that context
manager will then allow having a transient invalid state, but still
always check the validity at the end, when exiting the context.

That context key has been kept only in `point_of_sale` because a special
wizard is used there to be able to validate a session with an unbalanced
move, but a wizard is then in charge of balancing it. The check is then
done at that time.

closes odoo/odoo#146824

Signed-off-by: Brice Bartoletti (bib) <bib@odoo.com>
2024-01-18 13:46:49 +00:00
Prakash Prajapati 21927695bf [FIX] payment_razorpay: convert the TODO text into comment in redirect form
Currently, the `TODO: remove in master` is treated as a string, but it
is actually a comment. Therefore, I converted it from a string to a comment.

closes odoo/odoo#149883

Signed-off-by: Antoine Vandevenne (anv) <anv@odoo.com>
2024-01-18 12:01:07 +00:00
Serge Bayet (seba)andqsm-odoo 2b7303ca46 [FIX] website: address test tour issue with links href updating
This commit resolves an issue in the `link_tools` test, specifically
addressing a failure that arises when verifying the synchronization
between the link's href and the content of the `<a>` tag. The failure
was attributed to the oversight of not clicking outside the popup to
close it before interacting with the link.

Note: the race condition that occurs in this test was very rare and was
reduced a lot by [1], its parent commits and their related forward-port.
The last version of this commit here actually does not seem to change
much but the code speaks for itself: this is how it should be written.
Further race conditions need to be fixed in this test again anyway.

This also modifies some steps to make them clearer.
In this forward-ported version, it actually patches what was done at [2]
by adding back the "input" trigger that the original commit added with
commit [3]. It also removes the outdated wait for popup opening that was
fixed the right way with [1] and its parent commits.

Final note: in this forward-ported version, the test systematically
fails on the same step, with or without this commit. Further PR will be
made; but for now, this unify what we have in all versions, hopefully.

[1]: https://github.com/odoo/odoo/commit/9b26aafbc1576b08c409344d22ec179bd32a3bd7
[2]: https://github.com/odoo/odoo/commit/7d26c7b666033a16acfb430b6bf06235dd7d88ea
[3]: https://github.com/odoo/odoo/commit/b2a79ed9960d88d1bdf6465389f4ef720f6bc235

runbot-24929

closes odoo/odoo#149871

X-original-commit: b38b40fde5cc2396b0b8b20332a5b80935eb1814
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
Co-authored-by: qsm-odoo <qsm@odoo.com>
2024-01-18 12:01:06 +00:00
Guillaume-gdi 3467aa5927 [FIX] website_blog: change number of query expected in test
Since [this other commit], the performance test of the blog may use
less queries than before. This commit change the test to update the
number of expected queries.

[this other commit]: https://github.com/odoo/odoo/commit/7466ecd400bd27e4b612a5fcbdd779f34301982a

runbot-54860

closes odoo/odoo#149839

Signed-off-by: Romain Derie (rde) <rde@odoo.com>
2024-01-18 12:01:05 +00:00
Victor Feyens 29a8093b16 [FIX] delivery,website_sale: do not make api request on page rendering
Following a fix in 16.3 with 5052b9e4a15155c694cf005fdf330997770c6cac,
backported in 16.0+ with commit d28a8f67da06e58358b40636d1dca1f91a84e1ad,
the rates for the different carriers were computed on page loading,
to make sure unavailable carriers were hidden.

Nevertheless, this leads to significant increases of /shop/payment page
loading time depending on the enabled carriers.

This commit restricts the previous fix to the targeted type of carriers,
aka `base_on_rule` ones, whose rates do not depend on third party API
requests.

closes odoo/odoo#149657

X-original-commit: 99c8bda43f6f3bb027f8e03a753aaf2bb7ac585f
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
2024-01-18 12:01:04 +00:00
shsa-odoo fc27a3d452 [FIX] web_editor, website: text selection issue in font size dropdown
This commit addresses an issue where the text selection would disappear from
editor when clicking on the font size option from the toolbar.

Modifications:

- The issue of text selection disappearing when interacting with the font size
dropdown has been fixed.
- A new toolbar option, `customFontSize`, has been added. This option is
exclusively enabled for editor that have a toolbar in the same document.
The `readonly` attribute has been added to the input field to make it read-only
in our scenario, providing dropdown functionality for font size in the editor.
However, the functionality remains unchanged for the website.

task-3500827

closes odoo/odoo#142808

Signed-off-by: Antoine Guenet (age) <age@odoo.com>
2024-01-18 12:01:00 +00:00
Lucas Lefèvre (lul) 4f600ea6aa [FIX] spreadsheet: remove log
closes odoo/odoo#149884

Signed-off-by: Vincent Schippefilt (vsc) <vsc@odoo.com>
2024-01-18 10:28:47 +00:00
Anh Thao Pham (pta) 0a4ac677d9 [FIX] stock: fix reservation on multiple moves when validating a picking
Steps to reproduce:
- Activate developer mode
- Install Inventory and Sales
- Go to "Inventory / Configuration / Settings"
- Activate "Storage Locations" and "Multi-Steps Routes"
- Go to "Inventory / Configuration / Warehouse Management / Warehouses"
- Configure main warehouse: (e.g. San Francisco warehouse)
  * Outgoing Shipments: Send goods in output and then deliver (2 steps)
- Go to "Inventory / Configuration / Warehouse Management / Rules"
- Open the following rule:
  * Action: Pull From
  * Source Location: WH/Stock
  * Destination Location: WH/Output
  * Route: San Francisco: Deliver in 2 steps (pick + ship)
- Configure the rule:
  * Propagation of Procurement Group: Fixed
  * Fixed Procurement Group: [create a new one]
- Create a storable product (e.g. Product X)
- Update its quantity (e.g. 3) and apply
- Create a SO with 2 Product X and confirm
- Go to "Inventory / Operations / Transfers"
- Open the pick move linked to the SO (e.g. WH/PICK/00001)
- Set done quantity to 1 and validate
- Create a backorder for the remaining quantity (e.g. WH/PICK/00002)
- Create another SO with 1 Product X and confirm
=> Its pick move is merged with WH/PICK/00002, which contains now 2 Product X
- Open WH/PICK/00002, set done quantity to 2 and validate

Issue:
When validating WH/PICK/00002, the products should be reserved in the delivery moves
of both SO, but it is only done for the first one, leaving the second one in the
"Waiting Another Operation" state.

Cause:
When validating a move (i.e. WH/PICK/00002) linked to several destination moves,
the destination moves are reserved by checking the availability of the product.
For the first destination move, its origin moves are WH/PICK/00001 and WH/PICK/00002,
having an IN value of 3 and an OUT value of 2, which is correct.
When checking the availability of the second destination move, its origin move is
WH/PICK/00002, having an IN value of 2, but for the OUT value, the first destination move
is taken into account, generating an OUT value of 3.

Solution:
When computing the availability, if the origin move is linked to several destination
moves, it should take all the origin moves of all the destination moves into account.

opw-3548123

closes odoo/odoo#149867

X-original-commit: 0c8f0d14d29117e689d8e4c3331bc90b29ab1b98
Signed-off-by: Anh Thao Pham (pta) <pta@odoo.com>
2024-01-18 10:28:46 +00:00
Noe Antoine e6760d3dcc [FIX] mass_mailing: fix typo in team snippet
"He lovesto" -> "He loves to"
The msg is updated in translation file.

Task-3685546

closes odoo/odoo#149777

X-original-commit: 5ff7e350fec532a65a8bdb7fc067b1e19247be88
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2024-01-18 09:04:48 +00:00
Lucas Lefèvre (lul) dd6e6bd384 [FIX] spreadsheet: update o_spreadsheet to latest version
### Contains the following commits:

https://github.com/odoo/o-spreadsheet/commit/0f2d46e7a [REL] 17.0.8
https://github.com/odoo/o-spreadsheet/commit/518469ade [FIX] range: Support ranges with no `Rangeparts` Task: 3608941
https://github.com/odoo/o-spreadsheet/commit/676c3fb43 [FIX] config: remove latest tag
https://github.com/odoo/o-spreadsheet/commit/a0cb69a93 [FIX] Cell: Fix detection of markdown links Task: 3628780
https://github.com/odoo/o-spreadsheet/commit/82d2e774e [FIX] Datavalidation: fix checkbox style Task: 3650740

closes odoo/odoo#149726

Signed-off-by: Rémi Rahir (rar) <rar@odoo.com>
2024-01-18 09:04:47 +00:00
David (dafr) 8c5d533c8d [FIX] purchase-stock: Limit get_price_unit from invoice to 'purchase' purchase_method
# HOW TO REPRODUCE
- Create Product P, storable, AVCO
- Create Purchase Order for 100 units of P for $10 each > confirm
- Receive 40 units of P, create backorder
- Create Bill, change price to $12, confirm
- Return 10 units of P
- Receive 60 units of P
=> unit-cost in SVL is $12 instead of $10

OPW-3635451

closes odoo/odoo#149312

X-original-commit: 734149fbb3473f9a943c47d4ec13ab16afe2b35a
Signed-off-by: William Henrotin (whe) <whe@odoo.com>
Signed-off-by: David Fesquet (dafr) <dafr@odoo.com>
2024-01-18 07:10:57 +00:00
Prakash Prajapati 72c26c8c30 [FIX] web: fix color-list in the Dark Mode
Step:
 - install planning module
 - active the Dark Mode
 - open planning model
 - create shift with material resource
 - check the material resource icon

Issue:
   when dark mode active that time background and color are not proper show

Fix:
   We have fixed according the tag_list.

task-3524295

closes odoo/odoo#138391

Related: odoo/enterprise#54510
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
2024-01-18 05:12:44 +00:00
Serge Bayet (seba)andqsm-odoo 6fdb086a1f [FIX] website: resolve issue with logo transformation from text to image
This commit addresses an issue when the logo is in text mode and we
want to click on the `logo` check button under the `Header`/`Elements`
options.

The bug manifested itself in [this commit] during the redesign of the
website template headers. The logo button, initially assumed to have two
states, is, in fact, comprised of three: None, Text, and Logo. To
address this issue, a workaround has been implemented, treating None and
Text as a single state. Consequently, if the current state is Text or
None, toggling will transition to Logo, and conversely, if it is Logo,
the toggle will shift to None.

Steps to reproduce:
- Enter edit mode.
- Click on the header navbar.
- Click on the logo.
- Go to navbar brand options and choose "Text" in the dropdown Logo
  selector.
- The website is now saved. click on the button `LOGO` under the
  "Header" -> "Elements" option.
- An error occurs: the template is not well-formed or wrong.

[this commit]: https://github.com/odoo/odoo/commit/e5380a8e40be47cddf53aa24ff01e7c6802bbdb7

opw-3624285

closes odoo/odoo#146839

Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
Co-authored-by: qsm-odoo <qsm@odoo.com>
2024-01-18 03:48:00 +00:00
thco-odoo 9efafb1105 [FIX] l10n_ke_edi_tremol: Multiline invoice taxes
Before this commit:
In the case of an invoice with multiple product lines and a line has a tax amount in (16, 8, 0), a KeyError is raised while generating the message for the device.

After this commit:
The message for the device can be generated.

closes odoo/odoo#149778

X-original-commit: 00d9d3c70bc72da2f6397cb62d78231dd8f739b8
Signed-off-by: Brice Bartoletti (bib) <bib@odoo.com>
2024-01-18 01:34:18 +00:00
Tiffany Chang (tic) a7837d3cd9 [FIX] website_sale: translate cart notification
Missing _t to translate a string made it so the cart notification title
was always in English.

opw-3683578

closes odoo/odoo#149761

Signed-off-by: Valentin Chevalier <vcr@odoo.com>
2024-01-18 01:34:17 +00:00
Xavier Bol (xbo) 72f3e40a0c [FIX] sale{_timesheet}: avoid using allowed_so_line_ids
Before this commit, the `allowed_so_line_ids` has been introduced
to always use `_default_sale_line_domain` method in the domain of
`so_line` field and so instead of easing the domain in the field definition
we will be able to override the domain by overriding `_default_sale_line_domain`
method. However, since in `sale_timesheet` module, the new domain will contain
a dynamic value in the right part of a leaf
(`('order_partner_id', 'child_of', commercial_partner_id)`), the
`allowed_so_line_ids` is instead use in the domain of `so_line` field to
easily add that leaf in the domain returned `_default_sale_line_domain`
in the compute method of that field. The problem is the number of SOLs
fetched could be really huge and caused a performance issues.

This commit reverts the commit b7491b5b94 by
- deprecating the `allowed_so_line_ids`, that is, that field will
  now always get an empty recordset.
- deprecating the `_default_sale_line_domain` method, that is the method
  will no longer be used
- manually adding the domain instead of calling `_default_sale_line_domain`
- altering the domain when the `sale_timesheet` module is installed to
  get the same domain used in the `sale_line_id` of `project.task` model

closes odoo/odoo#149747

Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
2024-01-18 01:34:16 +00:00
Jorge Pinna Puissant 04a894c936 [FIX] web: kanban progressbar update aggregates compute
When clicking on a filter on a progress bar of a group, the aggregates
need to be recomputed. To do this, a web_read_group is called.
Since [1], the key groupDomain was removed, with the result that, the
web_read_group is called for all the groups and not only for the needed
one. This can be a performance issue.

Now, the key groupDomain was reintroduced and the web_read_group is done
only for the modified filter's group.

[1]: https://github.com/odoo/odoo/commit/8723f020c3587a900c811b8cc23f53fe34b98df3

closes odoo/odoo#149695

Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2024-01-18 01:34:15 +00:00
Shaan Thakkar (THSH) cd1b30e95b [FIX] portal: fix dialog box border
Before this commit
===================
1). Go to website slides.
2). Open any Course.
3). Click on 'Add a review' or 'Edit your review'.
  -> We can see that textarea and div both have a border.

After this commit
=================
When we are in the pop-up view div border will be not shown.

Task-3623765

closes odoo/odoo#149434

Signed-off-by: Warnon Aurélien (awa) <awa@odoo.com>
2024-01-17 22:38:36 +00:00
Djamel Touati 33c7235584 [FIX] mrp: unbuild the qty produced
Steps to reproduce the bug:
- Create a storable product “P1” with BoM:
    - Component: C1, Qty: 1

- Create a Mo to produce 5 units of P1
- Confirm and mark as done the MO
- Unlock the MO
- Change the qty produced to 20
- Try to unbuild the MO

Problem:
Bug 1: The wizard triggered is set with the product_qty(5) instead
of the qty_produced (20)

Bug 2: Set the product_qty to 5 and validate the unbuild, in result
the stock moves in the unbuild order are 20 units instead of 5 units

opw-3630001

closes odoo/odoo#149494

X-original-commit: e4bac3ea028c529e6f47583e7c1af02158f23c2e
Signed-off-by: William Henrotin (whe) <whe@odoo.com>
2024-01-17 20:25:02 +00:00
Lucas Lefèvre (lul) beaf1af8c5 [FIX] spreadsheet: avoid useless rpc
- define a relational global filter without any default value.
- reference that filter with `ODOO.FILTER.VALUE`
=> when loading the spreadsheet, a `read` RPC is triggered
with an empty list of ids.

This is:
- useless network call
- useless evaluation when the RPC resolves

closes odoo/odoo#149741

Signed-off-by: Rémi Rahir (rar) <rar@odoo.com>
2024-01-17 18:12:46 +00:00
roen-odoo 5783e0573d [FIX] pos_loyalty: prevent using expired eWallets
Current behavior:
It was possible to use an expired eWallet to pay for an order. It was
also possible to put money on an expired eWallet.

Steps to reproduce:
- Create an eWallet with an expiration date in the past
- Open PoS and add products to the order
- Click on the eWallet button
- You can still use the eWallet to pay for the order

opw-3568270

closes odoo/odoo#149622

X-original-commit: e3492b9192d9ca56104e0ce92371fffc1731b406
Signed-off-by: Joseph Caburnay (jcb) <jcb@odoo.com>
Signed-off-by: Robin Engels (roen) <roen@odoo.com>
2024-01-17 18:12:44 +00:00
roen-odoo e1ed78511f [FIX] pos_loyalty,pos_sale_loyalty: avoid creating 2 loyalty cards
Current behavior:
When you create an order for partner A but do not confirm it, then
settle the order in the PoS and add some product. You will have 2
loyalty cards created for partner A. This is happening because when you
confirm the order in the PoS it will confirm the sale order and create
a first loyalty card, but the PoS will not be aware of this and when it
will try to apply the point for the product added through the PoS it
will create a new loyalty card.

Steps to reproduce:
- Activate a loyalty program
- Create a partner A
- Create a sale order for partner A but do not confirm it
- Go to the PoS and settle the order
- Add some product to the order
- Pay the order
- Go to the backend and check the loyalty cards for partner A
- You will have 2 loyalty cards created

To avoid this we will check if the partner has a loyalty card before
creating a new one.

opw-3582174

closes odoo/odoo#149621

X-original-commit: ecd62dcc4b97f542c1cd10226c7c308691e97e4f
Signed-off-by: Joseph Caburnay (jcb) <jcb@odoo.com>
Signed-off-by: Robin Engels (roen) <roen@odoo.com>
2024-01-17 18:12:43 +00:00
Josse Colpaert 4d997bcfc1 [FIX] l10n_es_edi_tbai: services were put wrongly in the dict
opw-3665167

closes odoo/odoo#147987

Signed-off-by: Brice Bartoletti (bib) <bib@odoo.com>
2024-01-17 15:36:30 +00:00
Tiffany Chang (tic) f7b36faf54 [FIX] stock_account: retain assigned automated accounts
Steps to reproduce:
1- install stock_account and account_accountant
2- activate in Settings > Accounting > Automatic Accounting
3- open a Product Category > set Inventory Valuation = Automated
   [`real_time`] (optional step: can change the account stock properties
   values, but doesn't matter)
4- install mrp_account

Expected result:
- Accounts already set under the Account Stock Properties
  (i.e.: property_stock_valuation_account_id,
         property_stock_account_input_categ_id, etc)
  remain unchanged.

Actual result:
- Account stock properties for any Product Categories already set to
  Automated before installing mrp_account are wiped to nothing

Issue:
`_post_load_data` was resetting all property values (i.e. the accounts)
to False since PR odoo/odoo#119564 to ensure correct accounts were used
for `manual_periodic` valuation when stock_account and mrp_account are
first installed. This was previously not an issue because no valuations
could be set to `real_time` before stock_account was installed and
mrp_account did not run `post_load_data` (i.e. an mrp account was added)
until saas-16.3. So now we avoid wiping existing assigned accounts when
mrp_account calls `_post_load_data` at its install time

closes odoo/odoo#147958

Task: 3471065
X-original-commit: cc741525f9349077aefc7d137b6199a68fc87a23
Signed-off-by: Arnold Moyaux (arm) <arm@odoo.com>
2024-01-17 15:36:29 +00:00
Rodolpho Lima 4a7b2a5051 [FIX] web_editor: URL transformation when followed by '.'
Typing a valid http URL + SPACE transforms the URL into a link (anchor
element).

[1] broke such URL transformation if the URL is followed by punctuation
characters, e.g. "somelink.com...".

After this commit, typing "somelink.com..." + SPACE transforms
"somelink.com" into a link, restoring the behavior prior to [1].

task-3602890

[1]: https://github.com/odoo/odoo/commit/4da0608f7c7cd7a6550ec40535b9562fb35c5417

closes odoo/odoo#147845

Signed-off-by: Geelen Sébastien (sge) <sge@odoo.com>
2024-01-17 15:36:28 +00:00
Arnold Moyaux ab00d9dbcd [FIX] stock: be able to edit sml in mobile
Fine tuning of #143380

It only works for stock.move but it should also be the case for
stock.move.line

closes odoo/odoo#147597

X-original-commit: b218655990137e223f8df7977ae3ac36d93a32a7
Signed-off-by: Quentin Wolfs (quwo) <quwo@odoo.com>
Signed-off-by: Arnold Moyaux (arm) <arm@odoo.com>
2024-01-17 15:36:27 +00:00
Shaan Thakkar (THSH) deea06a2e3 [FIX] website_slides: button padding issue
How to reproduce
=================
1. Go to website slides.
2. Open any course which has quiz content.
3. Solve the quiz or open an already solved quiz.
-> Here we can see that the reset and continue buttons are overlapped.

After this commit
=================
Now there will be a space between the reset and continue buttons.

Task-3635485

closes odoo/odoo#146646

Signed-off-by: Warnon Aurélien (awa) <awa@odoo.com>
2024-01-17 15:36:26 +00:00
Pierre-Yves Dufays 6d5be6def6 [FIX] website_slide: correct spacing in quiz answer info
How to reproduce it:
- Install website_slides
- Go in the course "Basics of Gardening"
- Do the test "Test you knowledge" in fullscreen mode
- The information displayed about your answer is glued to the information icon

This fix the problem by adding space between the icon and the text.

Technical note: Although the html has not changed, the problem was not present
in previous version because the rendering process was not removing all spaces
which is now the case.

Task-3607117

closes odoo/odoo#144985

Signed-off-by: Warnon Aurélien (awa) <awa@odoo.com>
2024-01-17 15:36:25 +00:00
Soukéina Bojabza 30ec9ffa2d [FIX] web_editor, website: improve grid image code
Commit [1] added the support for images with a link set on them in grid
mode.

As a follow up, this commit does the following:
- Removes the `!important` from the grid image anchor CSS rules, as they
were not really needed.
- Checks if the image has a closest `o_grid_item_image` column instead
of checking the parent in the `GridImage` options. Indeed, this class
already guarantees that the image is well a grid image; we can therefore
simplify the code.

It also removes a comment that was forgotten in commit [2].

[1]: https://github.com/odoo/odoo/commit/085d70cea571ea80c141ac6005e8bd8333bd269f
[2]: https://github.com/odoo/odoo/commit/d8c374e3e6b31bf88aa42952aadf3379936f7600

related to opw-3580128

closes odoo/odoo#149681

X-original-commit: 9244e85ebb9e1605292698fe31ad94da7709ab86
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2024-01-17 13:04:01 +00:00
Yolann Sabaux 0412f1006f [FIX] l10n_nl: display rubriek 5 with no total
Steps to reproduce:
- Open Tax report
- Define "current fiscal year"

Issue:
Dutch tax report should not display the totaal of `Rubriek 5: Voorbelasting, kleineondernemersregeling en totaal (BTW)`

opw-3446056

closes odoo/odoo#149671

X-original-commit: 1985a0564a527d4c4ae7c40212b5b799cbfad753
Signed-off-by: Yolann Sabaux (yosa) <yosa@odoo.com>
2024-01-17 13:04:00 +00:00
sbel-odoo 0b705202dd [FIX] project_timesheet_holidays: enable selection of project in time off type
Curently when trying to select an existing/newly created project in the timesheet section of time off types, it will not recognise that the project exists and will suggest to create it.

Steps to reproduce:
-------------------
* Go to **Setting** -> Enable timesheets
* Go to **Time Off** App -> Configuration -> Time off types
* Create new type
* Go to **Project** App
* Create a new project
* Go back to the configuration of the new time off type
* Enable **developer mode**
* Under timesheet section, select project
* Try selection the new project created
* It suggests to create the project/does not recognise it is already created.

Why the fix:
------------
In multi-company this issue can be handled by going into the settings of the project and selecting the same company as the one in the time off type.

This issue is more problematic in case of single company because the field `company_id` is not available in neither the project form nor the time of type. As of currently, the `company_id` on time off type is by default the current company, while it is `False` by default for the project.

This PR introduced that behavior: https://github.com/odoo/odoo/commit/16a07ed1bfd33a193b363f3e87aab3f9bd6f8bd0

Since the `company_id` can now also be `False`, it makes sense to enlarge the filter domain on the time off type form. With that in place, the field `timesheet_task_id` also requires changes because a task created in a project with no `company_id` will not have a `company_id`.

opw-3644265

closes odoo/odoo#149620

X-original-commit: 57d5cf36e5a77ff249cf107dca41dfad89c1ed10
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
Signed-off-by: Sarah Bellefroid (sbel) <sbel@odoo.com>
2024-01-17 13:03:59 +00:00
mano-odoo ac398e42cd [IMP] website_sale: categories scrollbar hover
Issue:

The eCommerce categories scrollbar is too small/ not easy to grab with
your mouse.

Fix:

The scrollbar height is increased on hover to increase the grabbing area

task-3371760

closes odoo/odoo#126502

Signed-off-by: Antoine Vandevenne (anv) <anv@odoo.com>
2024-01-17 11:38:02 +00:00
Benjamin Vray 18263b6805 [FIX] website: fix video in Image Gallery and Images Wall
Steps to reproduce:

    bug 1:
    - Enter edit mode.
    - Drag and drop an "Image Gallery" snippet onto the page.
    - Double-click on an image within the snippet.
    - In the media dialog, click the "Video" tab.
    - Copy-paste a YouTube video URL into the URL input.
    - Save the media dialog by clicking on the "Add" button.
    - Bug: The video is very small.

    bug 2:
    - Drag and drop an "Images Wall" snippet onto the page.
    - Double-click on an image within the snippet.
    - In the media dialog, click the "Video" tab.
    - Copy-paste a YouTube video URL into the URL input.
    - Save the media dialog by clicking on the "Add" button.
    - Bug: the spacing around the video is not correct and the "spacing"
    option does not work for the video.

Note that the "image gallery" snippet (also the "image wall" snippet)
was not initially designed to handle anything other than images. When
you click on the "Add" button of the snippet, you can only add images.

However, by following the steps described above, it's possible to work
around this limitation and add a video to the snippet. Since this was
not part of the original plan, several options do not function correctly
with a video.

Instead of preventing the addition of videos, we have chosen to allow it
and focus on fixing the main issues (the small size of the video and the
"spacing" option which does not work with videos). So, if someone
specifically wants to add a video, it's currently possible, though some
features may not work as intended.

task-3597156

closes odoo/odoo#149679

X-original-commit: 73f60e97a1b534b5f8dd3759bd631f9aac095426
Signed-off-by: Guillaume Dieleman (gdi) <gdi@odoo.com>
2024-01-17 09:15:34 +00:00
Andrea Grazioso (agr-odoo) e00c7a4359 [FIX] sale_coupon: no fixed tax discount
Have a product with percent tax and fixed tax
Have a promo program applying 50% on the order
Create a sale order
- Add the product
- Add the promo

Issue: The fixed tax is discounted
We should ignore fixed taxes when applying promotions.

opw-3580170

closes odoo/odoo#149165

X-original-commit: 2acce1c84586a0f91ac3a83570d574d0ec96f1f6
Signed-off-by: Andrea Grazioso (agr) <agr@odoo.com>
2024-01-17 09:15:29 +00:00
kdeb@odoo.com 5e9918f845 [FIX] google_calendar: prevent google meet links when location is set
Issue
    When a location is set on an event, the google meet link is also
    generated, leading to confusion about the meeting format.

Steps to reproduce
    - Create an event with a location
    - Sync the Calendar with Google.
    - Observe that a Google Meet link is sent with the email.

Solution
    check if the loacation is set before generating a google meet link.

opw-3589379

closes odoo/odoo#149654

X-original-commit: 6aabe1b30598a8a616db01ae46dffece8f3f876c
Signed-off-by: Leonardo Pavan Rocha <lpr@odoo.com>
Signed-off-by: Kawtar Drissi El Bouzaidi (kdeb) <kdeb@odoo.com>
2024-01-17 07:54:45 +00:00
OmarAbosamaha 72e123e8db [FIX] l10n_ar: add missing translations
Issue: spanish_ar translation is missing for some menu items and template names in the accounting app

Steps to reproduce:
1- install l10n_ar
2- switch language to Spanish(AR)
3- Open accounting app
4- check menu items

Solution:
Issue was that the translation file was called es.po and for spanish (AR) language it should fallback to es_419
As per the translation code found here in in 'translate.py' in odoo tools

https://github.com/odoo/odoo/blob/20a3998c3073af8a5d95f8303283107363caed85/odoo/tools/translate.py#L1565-L1574

opw-3601556

closes odoo/odoo#146742

Signed-off-by: de Wouters de Bouchout Jean-Benoît (jbw) <jbw@odoo.com>
2024-01-17 07:54:44 +00:00
Khushi Vakil 574d95283f [IMP] l10n_in_pos: error on order from POS
Before commit:
If state is not set in the company,it gives error on order confirmation.

After commit:
If state is not set in the company, now it gives error when opening POS session.

task id: 3360161

closes odoo/odoo#149594

X-original-commit: 803b122585d93bf226edd40c3f184a0108e8d40a
Signed-off-by: Joseph Caburnay (jcb) <jcb@odoo.com>
Signed-off-by: Khushi Vakil (khva) <khva@odoo.com>
2024-01-17 06:25:12 +00:00
ilru-odoo 86accecf96 [FIX] project_account, project_hr_expense: prevent double counting in project upgrade report
Issue Description:
There is an issue in the project upgrade report where an expense with a related analytic account appears twice. This occurs once as "Expenses" and again as "Vendor Bills". This problem does not manifest on runbot with all apps installed, indicating a specific configuration issue.

The installation of the 'project_purchase' module resolves the issue, as the method "_get_already_included_profitability_invoice_line_ids" within both the "project_purchase" and "project_hr_expense" modules performs a check for an 'expense_sheet_id' in account moves. This check helps to exclude these entries from the profitability items, thereby preventing duplication. However, while this solution is effective, it leads to an undesirable addition of the Purchase app to the client's database, which is not acceptable for the client.
Relevant code sections: [project_hr_expense](https://github.com/odoo/odoo/blob/1fbcfdf69b503e77e1a931d23dd47df0daf8b2fe/addons/project_hr_expense/models/project_project.py#L70), [project_purchase](https://github.com/odoo/odoo/blob/1fbcfdf69b503e77e1a931d23dd47df0daf8b2fe/addons/project_purchase/models/project_project.py#L138C15-L138C15).

Steps to Reproduce:
1. Install Expense, Accounting, Project, Sales, Employees, Contacts apps on base runbot.
2. Create a service product with 'Prepaid/Fixed Price' and ensure 'Create an Order: Project & Task' is selected.
3. Create and confirm a sales order for the service product created in step 2.
4. In the Expenses app, create an employee-paid expense linked to the sales order's analytic account (e.g., Analytic Distribution: Departments > S00074).
5. Follow the process in the Expenses app by clicking on 'Create Report' > 'Submit to Manager' > 'Approve' > 'Post Journal Entries'.
6. Access Project Updates in the Projects app.
7. Observe that in the project profitability cost section, the same expense is listed twice under different labels: once as "Expenses" and once as "Vendor Bills".

Proposed Solution:
The proposed solution involves modifying the domain of the `_add_purchase_items` function within the `project_account` module, specifically at [this code section](https://github.com/odoo/odoo/blob/763f88e2d45cb7ba107db135eecd0365ba2b8c8b/addons/project_account/models/project_project.py#L14). The enhancement would entail adding a condition to the function's domain to exclude any IDs that are already present in the profitability report. This approach will efficiently prevent the double counting of expenses, ensuring that each expense is represented only once in the project profitability report, thereby maintaining accuracy and consistency in financial tracking. This solution focuses on enhancing the existing functionality with a targeted and efficient modification, ensuring minimal impact on other system components while effectively addressing the issue.

opw-3522293

closes odoo/odoo#149623

X-original-commit: 0902d57dd1653018d6ae72554b39e4e01fa4d6d7
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
Signed-off-by: Ilya Rudy (ilru) <ilru@odoo.com>
2024-01-17 00:00:48 +00:00
Wolfgang Taferner 5065f52392 [FIX] stock: add dedicated owner to move to avoid wrong quantity at date
As _compute_quantities_dict does use stock.move as a source of calculation
we need to make sure that the dedicated owner is set also on inventory
moves which was forgotten and resulted in wrongly computed quantities
in the past in case of such an use case.

closes odoo/odoo#149596

X-original-commit: 02d5c04e85e0bc1b9c0edf66969066ba4f2d769c
Signed-off-by: Arnold Moyaux (arm) <arm@odoo.com>
Signed-off-by: Wolfgang Taferner <w.taferner@wtioit.at>
2024-01-16 22:40:03 +00:00
Mathieu Walravens 5593159828 [IMP] base: neutralize webhooks
The user can define automated actions for sending data to a remote
server using a webhook.
To prevent this feature from sending unwanted data from a test database,
this commit neutralizes the field `webhook_url` to an invalid URL.
When the action is run, a warning is logged.

closes odoo/odoo#149592

Signed-off-by: Bouvy Damien (dbo) <dbo@odoo.com>
2024-01-16 22:40:02 +00:00
Alexandre Kühn 52d34b69d6 [REV] mail: revert fix line break in customer rating feedback
This reverts commit 185adf6fb487fa260bb6dfe985638bc545de7fa2.

The change was made to "fix" line breaks with rating feedback in
helpdesk. However, it's not ok to apply `inline` display layout
for all non-user made message body, as usual block display is
expected for html tags like `<div>` or `<p>`.

The correct fix should be to remove these unwanted `<br>` in the
feedback rating messages. We don't know how they appeared, but
this is a specific minor issue in helpdesk rating, so reverting
the fix is a higher priority.

closes odoo/odoo#149570

X-original-commit: 1ba04da76f391cd4543a8d3b1e6dbecf6a2cb558
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2024-01-16 22:40:02 +00:00
mano-odoo e0491c1a62 [FIX] web, mail: increase form view width
Currently the form sheet have a flex-grow-1, the chatter could use less
horizontal space to leave more space for the form sheet's content.

This commit widen the form_sheet by applying a flex-grow-2 and
reduces the chatter's top bar total width by removing the icons and
applying a sup tag on the micro information displayed aside the icons.

Since the icons are removed there is no need to test if the icon is
rendered with it's appropriate text anymore thus we can remove these
two lines. Additionally the `text-warning` on the span was unnecessary
since it's already applied on the button parent. 

task-3641988

closes odoo/odoo#147136

Related: odoo/enterprise#53208
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2024-01-16 22:39:58 +00:00
Antoine Boonen d0ed8cd287 [FIX] hr_expense: Fix auto-extraction of attachments.
Problem
---------
In the commit 24345812cb015e86f362f8c35176646239bfb803 (odoo), we
modified the extraction of attachment in such a way that mails coming in
a journal from aliases with several attachments create several invoices.
Due to the urgency of the task, the computation of whether an attachment
needs auto-extraction or not, has been skipped which failing some tests
that had been silenced. Linked PR #49816 (enterprise) fixes it. However,
as a comment on the said PR suggested, we should add a context key that
disable the auto-extraction.

Objective
---------
Add a context key that disable the auto-extraction and update commit
2bfe69be5c64743d0bf35793a427878170d0b3c6 (enterprise) to use the said
context key.

Solution
---------
1. Remove the override of the `_needs_auto_extract`
2. Manually set the main attachment of the created moves so that
`register_as_main_attachment` is not called when accessing the move.
This removes the auto-extraction without the need to use the key (we
still keep the context key as suggested by the OCR team).

closes odoo/odoo#149525

Related: odoo/enterprise#49816
Signed-off-by: Laurent Smet (las) <las@odoo.com>
2024-01-16 22:39:56 +00:00
Shubham Patel 5b284d4176 [FIX] project: project name is overflowing on the project kanban card
Steps:
- Install project.
- Go to the project.
- Create or edit the project name to excessively long.
- Then go to Kanban view.
- The project name would overflow.

Issue:
-Before this commit, in the project's kanban view, if the project's name was
 excessively long, it would overflow.

Cause:
-When the name is excessively long it would overflow out of the div element.

Fix:
-After this commit the name is now shortened by applying the 'me-5' Bootstrap
 class.

task-3676094

closes odoo/odoo#149007

Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
2024-01-16 20:17:52 +00:00
sesn-odoo 5afc1af40e [FIX] l10n_es_pos: handle missing partner in the ReceiptHeader template
Currently, if you have Spanish POS installed and create a Cash In/Out,
you are met with an error.

Steps to reproduce
------------------
* install `l10n_es_pos`
* start a POS session
* click on the hamburger button in the top-right corner > Cash In/Out
* add any amount and confirm

You should be met with an error.

Fix
---
At first glance, the original condition:
```
partner?.id !== props.data.simplified_partner_id
```

and the revised condition:
```
partner && partner.id !== props.data.simplified_partner_id
```

might seem equivalent. However, they behave differently when `partner`
is `null` or `undefined`.

In the original condition, the optional chaining operator evaluates
to `undefined`, leading to the following `undefined !==
props.data.simplified_partner_id` (which is most likely true).

The revised condition will shorcircuit when `partner` is falsy, ensuring
that the code only executes when `partner` is a truthy object.

opw-3667287

closes odoo/odoo#148688

Signed-off-by: John Laterre (jol) <jol@odoo.com>
2024-01-16 18:00:21 +00:00
Julien Castiaux 6597672736 [REV] base: use of PyOpenSSLContext in mail server
This reverts commit 6c59eea421.

smtplib is expecting the Context of ssl found in the stdlib and the
Context object of the pyOpenSSL lib isn't a drop in replacement. The
various `TLS_METHOD` constants are not the same and the Context object
of pyOpenSSL lack a `wrap_socket`-like method.

opw-3640374

closes odoo/odoo#149566

X-original-commit: 028277129897c7d49942a148a0ac295386cd2d89
Signed-off-by: Xavier Morel (xmo) <xmo@odoo.com>
2024-01-16 16:42:06 +00:00