Commit Graph
163696 Commits
Author SHA1 Message Date
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
Ali Alfie (alal) 5b607e5a0b [IMP] sale: amount_to_invoice set to 0 if fully invoiced
For sale orders, if the invoice status is set to "Fully Invoiced", the mount to invoice is forced to zero.

task-3347812

closes odoo/odoo#124777

Signed-off-by: Quentin De Paoli <qdp@odoo.com>
2023-07-26 23:15:03 +02:00
Ali Alfie (alal) 8da5cdf5c0 [IMP] base: Sierra Leone currency update
- adds a new currency SLE for new leones.
- sets the default currency for Sierra Leone to the new SLE currency.

task-3355038

closes odoo/odoo#124239

Signed-off-by: Quentin De Paoli <qdp@odoo.com>
2023-07-26 23:15:00 +02:00
Julien Carion (juca) 3af4bffeee [IMP] web, mail, hr: Avatar card preview
This commit adds the possibility to see additional information about a
user with a card that appears when hovering avatar user fields for a
set amount of time. This card contains the following information:
- Avatar
- Chat status
- Name
- Email
- Button to send message
and with HR installed:
- View profile Button
- Job position
- Department
- Phone number
- Advanced chat status (when hr_holidays is installed)

Task-3167110

closes odoo/odoo#121943

Related: odoo/enterprise#44563
Signed-off-by: Mathieu Duckerts-Antoine (dam) <dam@odoo.com>
2023-07-26 19:18:49 +02:00
Xavier Luyckx (xlu) 284a0ef4dc [FIX] Mail chatter: fix followers dropdown
Before this commit, the dropdown menu lacked spacing at the top and
bottom when a user clicked on "Followers" in the chatter.

This commit addresses the issue by adding the necessary spacing and also
adjusting the hover state background color (when hovering followers
details and actions) to improve the contrast with the text color.

task-3338438
part of task task-3326263

closes odoo/odoo#129760

X-original-commit: 8f65cd97cd0127e66d51537a5fce835012dca7f0
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2023-07-26 16:11:46 +02:00
Jay Savaliya a4041a91a1 [FIX] survey: use template's email_from when sharing
Before this commit:
When the user shares a survey from the wizard and customize the field
'email_from' in the mail template configuration, the value of that field will be
ignored, and the default value will be always used.

After this commit:

The customized value of the field will be used to be rendered, or fallback on
current user's email.

Task-3336596

closes odoo/odoo#129736

X-original-commit: 0951316a8f4345e4ea1dc56fcf512a579833e812
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2023-07-26 13:22:18 +02:00
Aaron Bohy cf4e844aca [REF] web,*: remove legacy DataManager
The DataManager is no longer used as all views and models have
been converted to wowl.

Part of task~3439226

closes odoo/odoo#129725

Related: odoo/enterprise#44611
Signed-off-by: Pierre Rousseau (pro) <pro@odoo.com>
2023-07-26 13:22:13 +02:00
Aaron Bohy e9d3e27792 [REF] web,*: remove legacy web_client/pseudo_web_client
*mrp_subcontracting,project

This commit removes two legacy js modules that are no longer
necessary.

Part of task~3439226

Part-of: odoo/odoo#129725
2023-07-26 13:22:13 +02:00
Aaron Bohy f40d4dc98b [REF] web,*: remove some legacy test helpers
Part of task~3439226

Part-of: odoo/odoo#129725
2023-07-26 13:22:12 +02:00
Hubert Van de Walle (huvw) f478310d17 [FIX] web: prevent rollback in ace_field
Steps to reproduce
==================

- Enable debug mode
- Go to Settings / Technical / Automation / Automated Actions
- Set "Action To Do" to "Execute Python Code"
- In the code editor, type really quickly

The code is briefly focused and when the next input is processed,
everything is erased.

Cause of the issue
==================

The AceField makes a debounced commit with the current editor value.
This triggers an onChange event, and upon receiving the results,
we update the editor value with the resolved value.
Although the editor value may have changed in the meantime,
we still revert it to the previous value.

Solution
========

There is no need to update the record every 10ms. We can simply to that
on blur. This is also what was done in 16.2.

opw-3379740

closes odoo/odoo#129694

X-original-commit: 4047ed03117fbcd5634843e29dc82e7ffb71b910
Signed-off-by: Luca Vitali (luvi) <luvi@odoo.com>
2023-07-26 13:22:09 +02:00
Adrien Guilliams (adgu) 9268837252 [FIX] pos_restaurant: put back disappeared lines in tour
A recent PR removed some lines in the pos_restaurant tour
( odoo/odoo#124157 ). This commit put them back to avoid runbot error.

closes odoo/odoo#129155

Signed-off-by: Robin Heinz (rhe) <rhe@odoo.com>
2023-07-26 13:22:02 +02:00
Romain Derie 33ed16490e [FIX] sale_quotation_builder: add sanitize overridable
Step to reproduce:
- Be sure to have `sale_quotation_builder` installed
- Drag & drop the "Steps" snippet on a product in edit mode
- Add this product on a SO in the backend
- Click on Customer Preview
-> The step snippet will not have the connector lines anymore

This is because in Odoo 16, the step snippet connectors are now `svg`
element (see [1]) which are removed by the sanitizer.

```py
from lxml.html import clean
svg='<svg><path/></svg>'
clean.Cleaner().clean_html(svg)
```

It's not the case in the `website_description` field of the product
template as this field is defined with `sanitize_overridable=True` [2]
which make it so the users with the right to do so can bypass the
sanitation and use the Step snippet in this field.

Since the quotation description can be a copy of that field, but without
the same sanitize behavior, the connectors are lost.

Note that most of the `sale_quotation_builder` description HTML fields
were already set as `sanitize_overridable=True` with [2] and [3] but
those ones were not.

[1]: https://github.com/odoo/odoo/commit/aba31e9f2d8a44ce1586403f2a621a6caeed57b4
[2]: https://github.com/odoo/odoo/commit/44ae3f38da07c2215b1547d992f053a11829a8ac
[3]: https://github.com/odoo/odoo/commit/811cf78ee1e63a7c41efe578fb64ee2deeca1dde

opw-3380346

closes odoo/odoo#129690

X-original-commit: 7a928c92136400454e7ed53326f2cdc9173fa1b3
Signed-off-by: Romain Derie (rde) <rde@odoo.com>
2023-07-26 12:00:30 +02:00
Antoine Guenet 234385a7b6 [FIX] mass_mailing: convert base64 background images to inline images
Base64 img src were converted to inline images but background images
were omitted. This commit fixes that.

opw-3374767

closes odoo/odoo#129645

X-original-commit: a10d1d305696f7ece38e7d3446c067338c411ea2
Signed-off-by: David Monjoie (dmo) <dmo@odoo.com>
2023-07-26 12:00:27 +02:00
Géry Debongnie db5b2ade8d [IMP] web: update owl from 2.1.4 to 2.2.3
Release notes:
https://github.com/odoo/owl/releases

Commits:
[FIX] app: sync destroy everythig when app is destroyed
[FIX] tools: include proper version number in released build
[IMP] runtime: add support for Map and other iterables in t-foreach
[IMP] runtime: only destroy component in raf callback
[REF] runtime: simplify implementation of batched
[FIX] compiler: allow t-model.number to work with select
[FIX] devtools: Fix crash when no root node
[FIX] devtools: fix/imp env display
[FIX] devtools: fix symbols handling and display

closes odoo/odoo#129438

X-original-commit: b1a13ad11f7f59632dbfb7de6dae0e57b7d44b02
Signed-off-by: Géry Debongnie <ged@odoo.com>
2023-07-26 12:00:25 +02:00
tsm-odoo 405a3a4d62 [IMP] im_livechat, mail: add user from member list
This PR focuses on partner invitations for livechat channels:
- Add "invite a user" button to the member list
- Sort partners by availibility (partner is a livechat operator
and connected) then most invited users (by the current partner)
- Display partner lang of suggested partners

part of task-3332872

closes odoo/odoo#128834

Signed-off-by: Matthieu Stockbauer (tsm) <tsm@odoo.com>
2023-07-26 12:00:22 +02:00
Rob Coekaerts ddda8c9408 [IMP] hr_holidays: do not refuse leave allocation if already used
Before this commit it was possible to refuse a leave allocation even if
the employee already took leaves using time from this allocation. If
this allocation is then refused, you get a negative balance for the
allocated days, which should not be possible.

With this commit, we raise a UserError when trying to refuse such an
allocation, stating that the user should handle the problematic leaves
first.

task-3330749

closes odoo/odoo#121778

Signed-off-by: Sofie Gvaladze (sgv) <sgv@odoo.com>
2023-07-26 12:00:19 +02:00
aliya 35d8048044 [FIX] account_peppol: fix saving of the migration key
`account_peppol_migration_key` is a related field, stored on the `account_edi_proxy_client.user`.
We want to allow users to provide a migration key when they want to register as a new peppol participant,
migrating their existing peppol registration from another smp.
However, before they save and validate their registration,
there is no `account_edi_proxy_client.user` associated with the company and
hence the `migration_key` is never saved and never sent to the IAP server.
The solution in master will be to move this field to `res.company`
but in stable the workaround is to store it in `ir.config_parameter` and make it a computed field,
where the config parameter is updated in the inverse method on `account_peppol_migration_key`.

closes odoo/odoo#129691

X-original-commit: d5edca101e6a1dd751a3c95d713831e99fc18462
Signed-off-by: Laurent Smet (las) <las@odoo.com>
Signed-off-by: Aliya Tastemirova (alta) <alta@odoo.com>
2023-07-26 10:48:54 +02:00
Eteil Djoumatchoua(etdj) a1944aa4ad [FIX] website_sale_loyalty: Stop getting succes message after applying invalid coupon
Current Behaviour:
In E-commerce, when you apply a ``LoyaltyCard`` which is not applicable on the ``SaleOrder``,
in a specific case it displays a success message even if the coupon is not applied.

Expected behaviour
Don't display a success message when the coupon is not applicable

Steps:
- Create a program with 'coupon' type, a rule of 'minimum 1' and a reward on a specific product A.
- Generate a coupon
- Go to shop add product A to the cart, go to checkout and apply the coupon code(Everything goes well).
- Delete the coupon and the product, and add a product B.
- Go to checkout and try to apply the same coupon code.

Issue:
Wrong success message

Reason:
The wrong message is displayed beacause on the python side we just check if there
is 'error' in the ``Request.session`` but in this case there is also 'error_promo_code'
that should be considered.

opw-3355632

closes odoo/odoo#129663

X-original-commit: 6ee60a30e0798ce69152385b08e49b223782d785
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
Signed-off-by: Eteil Junior Djoumatchoua (etdj) <etdj@odoo.com>
2023-07-26 10:48:51 +02:00
Vincent Schippefilt ac81985126 [FIX] base: traceback when creating a user
The combination of the new basic model and this change dc4dcead6e
made it so that creating a new user would fail with a traceback.

This commit fixes the issue by making sure that the company_id that is used
withing the initial onchange is a integer, and not a new-id.

closes odoo/odoo#129590

Signed-off-by: Xavier Dollé (xdo) <xdo@odoo.com>
2023-07-26 10:48:49 +02:00
Alexandre Kühn f42927c965 [FIX] web: autoresize input correctly in Safari 16
Before this commit, autoresize input in Safari 16 had their
size underestimated, thus truncating the content.
For example, in the Discuss app, the header is a (disabled)
autoresize input, which becomes enabled when the thread can be
renamed. This is also used for threads that cannot be renamed
for consistency of style. So some screens like "Inbox" had its
name truncated to "In...".

This problem is only present in Safari, not in Chrome or Firefox.
Apparently the sizing of input and textarea is incorrect, and it is
fixed in Safari 17. Indeed, Safari 17 can be tested with Safari
Technology Preview where the bug is not present.

This commit fixes the issue by adding an offset to computing the
scroll width of autoresize input, so that it matches the Safari 17
behaviour that is correct.

closes odoo/odoo#129698

X-original-commit: cd9d900c93d22fec1c24dc3b1e77230f80191f04
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2023-07-26 09:22:41 +02:00
Alexandre Kühn 2e15b640de [FIX] mail: no empty bubble on editing message with only attachments
Follow-up of https://github.com/odoo/odoo/pull/128650

The edited label is disabled because showing the label introduces
problems that have no good solution with the current implementation
to determine a message is edited.

The label was removed but the condition to determine whether a
message has some text content was not updated accordingly.
There was a special condition for showing "(edited)" label when
a message is edited to remove the text content but has some
attachments. Since the label is no more, the presence of text
content is the only thing that matters for this getter.

closes odoo/odoo#129692

X-original-commit: c53e3e73978f7c25c457a0ad19798566f59c7864
Signed-off-by: Louis Wicket (wil) <wil@odoo.com>
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2023-07-26 09:22:33 +02:00
Alexandre Kühn 9559b113dd [FIX] mail: show message action list next to attachment
Before this commit, when a message had no text, the action list was
placed above the message content, including attachments.

This made it hard to find the action list for these messages, as
all action lists of any messages are expected to always be next to
the 1st line of the message content.

This commit fixes the issue by placing action list next to text
content if there are any (same as before), but if there are no text,
then the actions are displayed next to attachments.

The template requiring defining a shared container for text content
and attachments, so that action list comes after. Also when the
message has some text and some attachments, the action list is still
expected to come inline of text content, which is why this commit
conditionally places the action list accordingly.

Part of Task-3340653

Forward-port-of: #128940
X-original-commit: 43699aea88adbdeca43150e9659fc5571de333e0
Part-of: odoo/odoo#129692
2023-07-26 09:22:33 +02:00
Shyam Gohil f164631c4e [CLA] signed cla for Shyam Gohil
closes odoo/odoo#129688

X-original-commit: 83e903e6dd85ca2fd4870c0c05233a2ee9739a03
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2023-07-26 09:22:30 +02:00
Louis (loco) c802efd56f [FIX] web_editor: correctly adapt the image mimetype on format change
Steps to reproduce the bug:
- Go on a product image and replace it by a ".jpeg" (note that the
mimetype of the image is "image/webp" since [1]).
- Change the format of the image and put it to "Original". The mimetype
of the image is now "image/jpeg".
- Add a shape on the image.
- Change the format of the image.

-> None is displayed as its format.

Let's first recall that adding a shape on an image transforms its
mimetype into an "image/svg+xml" and that the `originalMimetype`
attribute is used to record its original mimetype. This is needed in
order to correctly reset the image mimetype when removing its shape.

The problem here was that the `originalMimetype` attribute was not used
correctly and that the mimetype of an image with a shape was not
correctly updated at format change.

[1]: https://github.com/odoo/odoo/commit/0449fe85cb0e1d639a4e1aeba26e90906f79254d

task-3431015

closes odoo/odoo#129680

X-original-commit: 40811e72c50faf146ccdf9f26c332db9ebc69fa9
Signed-off-by: Benoit Socias (bso) <bso@odoo.com>
Signed-off-by: Colin Louis (loco) <loco@odoo.com>
2023-07-26 09:22:27 +02:00
Damien Bouvy f6dea9b6fe [FIX] web: list-specific binary field design
Instead of sho-horning full buttons inside a list view cell, use inline
buttons instead.

closes odoo/odoo#129679

X-original-commit: 76a4995b5037957bb5d7b1b2e04c44267273f7fc
Signed-off-by: Bouvy Damien (dbo) <dbo@odoo.com>
2023-07-26 09:22:24 +02:00
Damien Bouvy b7a742cc7e [FIX] web: highlight search facet icon on hover
X-original-commit: 643ce1255c90e944f11ff5b4fd5e47f7bf5aff6d
Part-of: odoo/odoo#129679
2023-07-26 09:22:24 +02:00
Damien Bouvy c3742f76c7 [FIX] web: padding on collapsed breadcrumb
X-original-commit: 121a9f4ec6bcb572915be1b2e26abc9944a07f9d
Part-of: odoo/odoo#129679
2023-07-26 09:22:24 +02:00
Damien Bouvy 5662aa7c7f [FIX] project: contrast issue in milestone stat button
X-original-commit: 17cde615a6e632bca59c3606028fe7bd84832599
Part-of: odoo/odoo#129679
2023-07-26 09:22:23 +02:00
Denis Ledoux 028bf8e0ec [FIX] base: tag test_add_field_valid as post_install
This test can lead to a deadlock,
when trying to drop the constraint on `ir_model_fields`
during the registry loading,
as the test opens a second cursor in addition
to the cursor used for the registry loading,
and drop a constraint on a table which is being read by
the registry loading (`ir_model_fields`), leading to the deadlock.
See screenshot in the PR for illustration.

This has been detected in the runbot nightly builds,
which were pending indefinitely because of that deadlock.
To reproduce, just init a database with `-i base`,
then restart the server with just `--test-tags .test_add_field_valid`.

To avoid to drop the constraint during the registry loading,
and hence to avoid the deadlock,
tag the test as `post_install`.
That way, the test is executed after the registry is loaded,
not during, and the constraint can be drop safely, not leading to a deadlock.

closes odoo/odoo#129660

X-original-commit: 67bc9a9e895245a94aac064e8f5a365ee6052261
Signed-off-by: Xavier Dollé (xdo) <xdo@odoo.com>
Signed-off-by: Denis Ledoux (dle) <dle@odoo.com>
2023-07-26 09:22:19 +02:00
niyasraphy 112bc6499a [FIX] hr_work_entry_contract: reload calender from regenerate work entries
before this commit, if user try to regenerate the work entries
from the button 'Regenerate Work Entries' in the work entries
calendar view, the generated entries will not shown to the
user immediately without reloading the screen.

* payroll -> work entries -> work entries
* switch to calendar view
* click on Regenerate Work Entries button
* select employee's and click Regenerate Work Entries
* generated work entries will not be shown in calendar

after this commit, the generated work entries will be shown
in the calendar immediately.

closes odoo/odoo#129647

X-original-commit: 1ea504e6ee794be7513d8de20304527261548849
Signed-off-by: Kevin Baptiste <kba@odoo.com>
2023-07-26 09:22:17 +02:00
Elisabeth Dickinson 0f0fc727da [FIX] project_todo: fix input height and reduce notepad padding
This commit aims to give the same height to both
`o_field_many2many_tags` and `o_field_many2many_avatar_user` when side
by side.
To remove some visual clutter inside the inputs, we've removed the
input's line (and the caret; without the line it seemed to be floating).

The padding in the notepad area (`.o_form_sheet`) has been reduced.

Note that this commit does not fix the status bar issue which should be
done in a separate commit.

task-3420954
part of task-3326263

closes odoo/odoo#129630

X-original-commit: bf3fc5dc76d4cea224255149c8a71b42c37b7d48
Signed-off-by: Pierre Paridans (app) <app@odoo.com>
2023-07-26 09:22:15 +02:00
Elisabeth Dickinson f6cab04cef [FIX] web: replace calendar navigation icons
In commit c0b354e14a18667463451aa6fe768bffcbb9da9a the intention was for
the calendar navigation to look like the gantt one. The arrows have been
replaced by the same `oi` icons as the gantt view's navigation.

task-3410165
part of task-3326263

closes odoo/odoo#129568

X-original-commit: c9384d12b903850f9535ca7b82ea2ef0e04fd39b
Related: odoo/enterprise#44556
Signed-off-by: Pierre Paridans (app) <app@odoo.com>
2023-07-26 09:22:07 +02:00
Elisabeth Dickinson 41c9bccf6e [FIX] web, *: fix buttons squashing and spacing
*: calendar, google_calendar, microsoft_calendar;

task-3410165
part of task-3326263

X-original-commit: b680a6ac5769bf8e02921a9548792c7696992955
Part-of: odoo/odoo#129568
2023-07-26 09:22:07 +02:00
Antoine (anso) 51458c3704 [FIX] web: fix folded kanban header's drag and drop state
Prior this commit, there was a problem with borders that were not
displayed on the kanban header when the stage was folded and the user
was trying to drag and drop in that stage.

This commit removes the background set on `.o_kanban_header` when the
stage is folded, so it doesn't overlap and hide the border set on
`.o_kanban_group`. We can do that safely because a folded stage
can't be scrolled

task-3423682
part of task-3326263

closes odoo/odoo#129560

X-original-commit: b6cb9fed6aa46591e692e67267a7419fe15f8c68
Signed-off-by: Pierre Paridans (app) <app@odoo.com>
2023-07-26 09:22:04 +02:00
Elisabeth Dickinson 18016c4504 [IMP] web: improve calendar view
Prior to this commit, the `font-size` of the days and week numbers in
the Month view were very large.
There were also a couple of issues with the background circles
highlighting days on hover or "today". In both Month and Year view
they were oval instead of circular, and in the `ui-datepicker` they
would hide the number if they happened to be in the previous or next
month.

To fix the font issue the `font-size` styling on
`fc-day-number` and `fc-week-number` has been removed.
For the roundness of the circle, a `:before` element was needed, .
And for the `ui-datepicker`'s circle a simple `position-relative` on
both the `td` and the `a` or `span` fixed the issue.

task-3326564
part of task-3326263

closes odoo/odoo#129559

X-original-commit: 8fac3dd7dd6ffc69f989c9ec5cea225f3e919535
Signed-off-by: Pierre Paridans (app) <app@odoo.com>
2023-07-26 09:22:01 +02:00