Commit Graph
160124 Commits
Author SHA1 Message Date
kais-odoo 9b2c19b945 [IMP] project: improve generic UX of project
In this commit made following changes:
- added copy writing content in project form view for
  access_instruction_message field.

task-3067151

Part-of: odoo/odoo#106233
2023-04-11 11:33:29 +02:00
Rémy Voet (ryv) 016f26a931 [FIX] base: wrong value profiled
closes #odoo/odoo#88276

Signed-off-by: Christophe Matthieu (chm) <chm@odoo.com>
2023-03-13 11:03:46 +01:00
Denis Ledoux 536e670f8c [FIX] http: ensure values of session are serializable when stored
closes odoo/odoo#86015
Signed-off-by: Julien Castiaux <juc@odoo.com>
2023-02-07 09:12:32 +01:00
niyasraphy 40be0ebf9b [IMP] website_forum: remove milli seconds from vote datetime
before this commit, in the votes tab in the website
user profile, the date time is shown including the
milli seconds in it.

* open forum
* open own user profile
* click votes tab and see the date time

after this commit, the milli seconds info will be
removed from the date time.

closes odoo/odoo#118152

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2023-04-11 09:21:23 +02:00
amdi-odoo 6bd14cd39a [FIX] web: fix phone field button text alignment
Fix the phone field buttons text alignment
("Call", "SMS", ...) which is currently rendering
the letters on different lines because of a text-break
css class introduced by: odoo/odoo#114442

Override this text-break class for the phone field
buttons links.

Task-3258943

closes odoo/odoo#118109

X-original-commit: 012f97b7e6811bfa4804ba49696811f7f6b98582
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2023-04-11 09:21:21 +02:00
niyasraphy 85fc6e09d8 [FIX] website_profile: remove duplicated import in init
before this commit, the controllers directory is
imported twice in the init file.

after this commit, the duplicated import is
removed.

closes odoo/odoo#118105

X-original-commit: 3496c25b677dfe8695b00cea0cd5eff095941321
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2023-04-11 09:21:19 +02:00
oco-odoo 4f93fd0800 [FIX] account_reports: aggregation engine: properly expand aggregation expressions when using an if_other_expr_[above|below] subformula
The if_other_expr_[above|below] subformulas were introduced in stable by https://github.com/odoo/enterprise/commit/f39862263c7e2332468a69736589a35d66d87b16. They basically allow displaying the value of an aggregation expression if another line's amount is above/below a provided bound. When using an expression with such a subformula to compute a carryover value (hence giving the expression a _carryover_... label) on a tax report, the posting of the said tax report's closing entry looped forever. No report from Odoo falls into this use case at the moment, but the issue occured on a development branch (for l10n_ma).

This was due to the fact the tax closing expands only the aggregation expressions needed in the computation of the carryover to compute its value, hence not providing all the expressions of the report. Doing so, _get_aggregation_terms_details was called, and it neglected to include the expression used as comparison term by the subformula into the dependencies of the aggregation to expand. As a result, the comparison term could never be evaluated, and the loop went on forever, waiting for the comparison term to receive a value.

closes odoo/odoo#118104

X-original-commit: 76288d1fd654c9ff4c721cc1d96596b6adbf95d0
Related: odoo/enterprise#39535
Signed-off-by: John Laterre (jol) <jol@odoo.com>
2023-04-11 09:21:13 +02:00
Fabien Meghazi 5cbb0738be [IMP] sql_db: allow to customize pg connection's application_name
This is an improvement over commit f6c13d7 in order to allow full
customization of postgresql connection's `application_name`.

In a PID linux namespace the containers processes IDs might not be relevant
for a system administrator and one might want to customize the content of the
`application_name` just like it was possible to do before commit f6c13d7
using the `PGAPPNAME` environment variable.

This commit allows to expose an `ODOO_PGAPPNAME` environment variable whose
content will be interpolated with the PID (optional)

closes odoo/odoo#117921

X-original-commit: a4108eee91f8e9bf82be5a4be4b91bab16baa0df
Signed-off-by: Olivier Dony (odo) <odo@odoo.com>
2023-04-11 09:21:08 +02:00
rhe-odoo 7db7b3ef04 [FIX] pos_sale: show correct shipping address
When creating a quotation in the sales app with a different shipping address, this is not shown on the invoice report from the point of sale.
Before it was always using the pos order partner address.
Now we check if the sale order had a different shipping address before setting the address on the report.

closes odoo/odoo#117603

Task-id: 3258679
X-original-commit: f12abb338501a745716480e055e9a8d33229bb0c
Signed-off-by: Joseph Caburnay (jcb) <jcb@odoo.com>
2023-04-11 09:21:05 +02:00
Kartik Chavda a457785920 [IMP] sale_project: improve generic UX
Purpose of this PR to do generic improvement.

So in this PR done following improvements:

- add context in partner fields in various places to display
customer partner first in selection of partner field.
task-3099758

closes odoo/odoo#107913

Related: odoo/enterprise#34950
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
2023-04-11 09:21:00 +02:00
kais-odoo 829a7a31e4 [IMP] rating: update rating template content
This commit replaces 'write a feedback' into 'share feedback'
in the feedback content of rating portal page to share a feedback.

task-3079119

closes odoo/odoo#107590

Related: odoo/enterprise#34838
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
2023-04-11 09:20:55 +02:00
valeriobelcastro a33dbdb5c7 [IMP] handle query parameters on /web route
closes odoo/odoo#117987

Signed-off-by: Julien Castiaux (juc) <juc@odoo.com>
2023-04-09 12:57:40 +02:00
Đào Nam 0f8cbcb5a1 [IMP] barcodes: Allow other modules to add the COMMANDS option.
closes odoo/odoo#118123

X-original-commit: 2daa8361373f2308c9efe571d0901699b7a73262
Signed-off-by: Géry Debongnie <ged@odoo.com>
2023-04-09 08:03:45 +02:00
Abdelouahab (abla) 7e53bd296f [FIX] account: origianl bills with encrypted PDF
To reproduce
============
- Accounting > Vendor Bills > create a vendor bill and upload the pdf (attached on this ticket)
- back to list view, select the created bill and print the original bills a user error is raised

Problem
=======
when trying to add the banner we read the PDF and we found out that it's encrypted so we raise the error

Solution
========
if the PDF is encrypted, we log warning and carry on downloading the original bill.

opw-3221796

closes odoo/odoo#118134

X-original-commit: 900418d9bc7bd260cac67769be77f8e818eed814
Signed-off-by: John Laterre (jol) <jol@odoo.com>
Signed-off-by: abla001 <abla@odoo.com>
2023-04-09 05:46:43 +02:00
Julien Van Roy b9e223c15a [FIX] account_edi_ubl_cii: UBLVersionID should not be present for Bis 3
Tag UBLVersionID should not be present for UBL Bis 3 and its inheriting
formats.

The fonction infering the format from an xml etree needed to be apdated
too, since we can no longer rely on the `UBLVersionID` node for UBL Bis
3 and its inheriting formats. The `CustomizationID` node is used.

opw-3249153

closes odoo/odoo#118125

X-original-commit: 8b1fc42af5471872da4ff0b335d04e769e286628
Signed-off-by: Josse Colpaert <jco@odoo.com>
Signed-off-by: Julien Van Roy <juvr@odoo.com>
2023-04-08 17:09:08 +02:00
Denis Ledoux a2acf91958 [IMP] core: models __repr__ should show when ids is wrong
As a developer,
when you craft your records set manually,
and wrongly use the API and set something weird in `ids`,
something else than a tuple of integers,
`repr` should help you to understand you did something wrong.

e.g.

before
```py
In [1]: env['res.partner']._browse(self.env, '(1,)', 'bar')
Out[1]: res.partner(1,)
```

after
```py
In [1]: env['res.partner']._browse(self.env, '(1,)', 'bar')
Out[1]: res.partner'(1,)'
```

We could put an assert in `_browse` to make sure `ids`
is a tuple of integers, but this is considered a non-stable
change, as it will suddenly crashes when you will update
Odoo while it wasn't the case before.

closes odoo/odoo#118119

X-original-commit: f689c4f53fc4663b17c57bd1d704b9ffb9f11f8d
Signed-off-by: Denis Ledoux (dle) <dle@odoo.com>
2023-04-08 14:38:46 +02:00
tsm-odoo c0ce422935 [FIX] bus: solve indeterministic error in TestWebsocketCaryall
This PR fixes the `15350`runbot issue that was due to the
websocket subscribe not being properly awaited before logging
out.When the log out occurred before the subscribe was received,
the `odoo_ws` variable was `None`.

closes odoo/odoo#118097

X-original-commit: 59af91840c3ed7253c1c3c9dd80a4919ebdee593
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2023-04-07 21:48:48 +02:00
Habib (ayh) 34149617a3 [FIX] account: broken no content helper
doAction does not convert the action help html to markup resulting in the display of an html string.

To replicate:
- Journal Items List view or Analytic Items
- Click a link to the bank recon widget
- In bank recon widget, search for something that returns no records
- The no content helper displays html string

After this PR:
By using the doActionButton instead, noConentHelper is marked up and displays correctly.

closes odoo/odoo#118093

X-original-commit: 8cedb020f2bcd2115fdaf0fb44abbeb936ced3c0
Related: odoo/enterprise#39531
Signed-off-by: Laurent Smet <las@odoo.com>
Signed-off-by: Ayob Habib (ayh) <ayh@odoo.com>
2023-04-07 20:44:28 +02:00
Rahul Prajapati 10620c0caf [FIX] base: fix validation for co-model field in ir_field view
The co-model field in `IrField` view is accepting Related Model name
even if it is invalid. And replaces the invalid model name with `_unknown`.
This causes KeyError `display_name` when trying to create or read a record.

To fix that we are adding Validations for the Related Model field when it gets
updated from UI side.

sentry-3933471439

closes odoo/odoo#118052

X-original-commit: e4f7798fd5a5cccd5d385f535fbc21264cb6948b
Signed-off-by: Rémy Voet <ryv@odoo.com>
2023-04-07 19:43:33 +02:00
Mathieu (mano) abd5ea645b [FIX] website_sale: fix wrong ribbon text color
Since Bootstrap 5, bg- classes behave differently. On the website
e-commerce shop the ribbon for the states "Sale, Sold out, Out of stock,
New!" still uses bg- classes therefore having the wrong text color by
default, making it difficult to read.

This commit fixes the default text color by using new bootstrap 5 class
text-bg-* instead of bg-*

task-3096035

closes odoo/odoo#118051

X-original-commit: e6ecb4f72e9610bd5e3f81264c8278fbb7a6d5a3
Signed-off-by: Antoine Vandevenne (anv) <anv@odoo.com>
2023-04-07 19:43:30 +02:00
Alexandre Kühn d9bb64f1e9 [FIX] mail: show email_from if message has no author
closes odoo/odoo#118038

Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2023-04-07 19:43:28 +02:00
Alexandre Kühn 804d3786e8 [FIX] mail: do not auto-open chat window with odoobot on login
closes odoo/odoo#117978

Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2023-04-07 19:43:25 +02:00
Mathieu Duckerts-Antoine d0b9c092bd [IMP] web: new field service
We move the function loadFields from the view service to a newly created
field service. That service can also be used to load model fields for a
given path (loadPath), i.e. load all model fields for the models
traversed by the given path.
We use loadPath in useModelField and DomainSelector.

closes odoo/odoo#117882

Related: odoo/enterprise#39418
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2023-04-07 19:43:20 +02:00
Mathieu Duckerts-Antoine 6c5d54e1d9 [IMP] web: cache: new clear and invalidate methods
We introduce two new methods for Cache:
    - a method "clear" that can be used to delete a specific path
    - a method "invalidate" that can be used to delete all paths

Part-of: odoo/odoo#117882
2023-04-07 19:43:20 +02:00
Mathieu Duckerts-Antoine 57a04c4aa3 [IMP] web: utils: zip and zipWith functions
We introduce in utils/arrays.js, the two classical functions zip and zipWith.

Part-of: odoo/odoo#117882
2023-04-07 19:43:19 +02:00
Louis (loco) abda2bb60a [FIX] website_blog: adjust the width of the border when inside column
Steps to reproduce the bug:
- Go on the blog of the website.
- Edit.
- In the "Customize" section, apply the "List" "Layout" and activate
the "Sidebar".

-> The sidebar appears at the bottom of the page instead of on the
side.

The situation looks like this:
```html
<div class="container">
    <div class="row">
        <div class="col"></div>
        <div class="border-end"></div>
        <div class="col-12"></div>
    </div>
</div>
```
The bug comes from the fact that the `div` with the `border-end` class
is inside a `row` class. Due to that, a bootstrap 5 css rule applies
and puts the `width` of the `div.border-end` element to `100%`. Because
the element tries to fill the entire width of the `div.row`, it is put
at the bottom of the page as well as its following elements (in this
case, the sidebar). This bug is fixed by removing the `div.border-end`
element.

opw-3217775

closes odoo/odoo#117849

X-original-commit: 9d8b895b934e5b0986c932837fd043cf847a8992
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
2023-04-07 19:43:16 +02:00
zel-odoo 21b6ef38cf [IMP] mail: activity visual update
1. always show the name of the assignee.
2. replace the icon with avatar
3. bold the time info.

task-3142628

closes odoo/odoo#116349

Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2023-04-07 19:43:13 +02:00
Maryam Kia 7248178d19 [IMP] mail: Add message reaction menu
This commit adds a menu to see reaction on a message.
It can be accessed from message options or from long press in mobile.

Task-2641441

closes odoo/odoo#116022

Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2023-04-07 19:43:10 +02:00
Bastien (bvdn) f50c7c16ab [REF] web: add a hook on Many2XAutocomplete orm promise
closes odoo/odoo#115943

Related: odoo/enterprise#38027
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
2023-04-07 19:43:02 +02:00
Carlos Carral 0b30d1d266 [CLA] Update Vauxoo's CLA
Incorporate Carlos Carral (carralc) as Vauxoo's contributor.

closes odoo/odoo#118040

X-original-commit: 0472569febd557a9956b196e840dd996309c9f9c
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2023-04-07 18:44:01 +02:00
Lucas Lefèvre fccbc91cc8 [FIX] spreadsheet_dashboard_account: display unpaid amount absolute value
In the Invoicing dashboard, the upper-left most scorecard displays the total
invoiced amount.
The baseline "X unpaid" is wrong. It was displaying the difference between
the key value (total invoiced amount) and the unpaid amount.
That means if not a single invoice was paid (everything unpaid), it would
display "0 unpaid". That obviously not correct.

opw-3248761

closes odoo/odoo#118030

X-original-commit: 2b795ee59ef063b5b7298382008ebd61c51de36e
Signed-off-by: Lucas Lefèvre (lul) <lul@odoo.com>
2023-04-07 17:46:42 +02:00
Touati Djamel (otd) 79f85ab312 [FIX] purchase: add the supplier list of the product in each company
Steps to reproduce the bug:
- Create a storable product “P1”
1:/
- Select the company A
- Create a purchase order:
    - product: “P1”
    - vendor: “V1”
    - confirm the PO
The vendor “V1” is added to the supplier list of “P1”

2:/
- Select the company B
- Create a purchase order:
    - product: “P1”
    - vendor: “V2”
    - confirm the PO

Problem:
The vendor “V2” is added to the list but “V1” is deleted from the list
in company A

The “seller_ids” field is in the “product.template” model, we try to
modify it in the “_add_supplier_to_product” function from the
“product_id”(product.product) field which inherits from the
“product.Template” model:
https://github.com/odoo/odoo/blob/3b88ed5ea458a37ee4d440f83bab45bd0fb13845/addons/purchase/models/purchase.py#L531-L532

So the function “inverse_related” will be called, in which the function
“__set__” will be triggered: In the values, the command for the create
will be added but the command for the set will be added as well while
it shouldn't. So in the `write_real` function a search will be done to
get all `product.supplierinfo` with the same product_tmpl_id:

https://github.com/odoo/odoo/blob/36544651f2049bcf18777091dbf02c9631b33243/odoo/fields.py#L4415-L4417

but as we are in sudo, those of company “A” will also be recovered, so
they will be unlinked since they are not in the command.set

opw-3251941

closes odoo/odoo#117985

X-original-commit: 78f803f3c1963711e2a5541f913f030da4f06fb7
Signed-off-by: William Henrotin (whe) <whe@odoo.com>
Signed-off-by: Djamel Touati (otd) <otd@odoo.com>
2023-04-07 17:46:39 +02:00
bosaeed 1d81c2fb8c [CLA] add signature for bosaeed
add signature CLA for bosaeed

closes odoo/odoo#117893

X-original-commit: 07396fd40157c2b020472e05a80acd4a67e9efe8
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
2023-04-07 16:40:53 +02:00
Pratik Awasthi 28b093e6b6 [IMP] project: test onboarding tour for project
This will improve the testing of the onboarding tour
 - earlier when we change the class and don't update the class in the tour it goes unnoticed
 - to prevent failure of the tour we called onboarding tour from python to test the flow
 - Because it helps users to understand the flow so we can let the tour fail

task-3235684

closes odoo/odoo#115672

Related: odoo/enterprise#38333
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
2023-04-07 16:40:48 +02:00
Bastien (bvdn) 0c2060eab9 [IMP] project, web: sort burndown chart legend
Before this commit:

- The burndown chart displayed the stage in order of the data fetching which wasn't logical especial for a chart that supposed to represent the evolution of the tasks in the project
- When sorting all/my tasks by stage, It was possible to select any project in any quickcreate of the stages which didn't make much sense

After this commit:

The burndown chart legend is now ordered according to the stage sequence (previously was ordered randomly by comming data)
Modified the burndownChartModel, simply makes a RPC to get the stages and sequences then sort the legend elements (one by stage) with it
Display only the projects which uses the stage in the dropdown menu of the task kanban quickcreate (when grouping by stage)

When sorting by all/my tasks by stage, the quickcreate now only display the projects which contains the stage selected
done by adding a domain in the quickcreate form
(shoutout to LTU and AUON who actually found the fix)

Task-3067445

closes odoo/odoo#105694

Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
2023-04-07 15:31:52 +02:00
tsm-odoo d2e5969e3e [FIX] mail: indeterministic guest tour
This PR fixes the `19916` issue on the `test_mail_channel_public_page_as_guest`
test.

The messaging service subscribes to bus notifications before it is fully
initialized. This test is composed of two tours. In the first one, the guest joins
the channel and receives the "guest has joined the channel" message. Then, the second
tour starts and the local storage is cleared. Since the local storage has been cleared,
the guest receives this message again, potentially before messaging has been initialized
which leads to a `channel_pin` rpc. This RPC fails with `SessionExpired` error and the tour
is stuck and eventually, fails.

closes odoo/odoo#118000

Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2023-04-07 11:37:30 +02:00
Xavier Morel 8932d447aa [FIX] core: table_kind semantics (incorrect classification of toast as temp)
17c4f47b0a updated table_kind to return
`pg_class.relkind`, however the semantics are *not* the same, and that
was ignored: `relkind = t` is for *toast* tables, not *temporary*
tables. In `pg_class` the temporary-ness is instead signaled by
`relpersistence` (which applies to both tables and sequences), temp
(and unlogged) tables have `relkind = r`. `existing_tables` does that
correctly, possibly unwittingly.

While at it, upgrade `table_kind` to return an `enum` (whose value is
the old discriminant).

closes odoo/odoo#117444

Related: odoo/enterprise#39185
Signed-off-by: Xavier Morel (xmo) <xmo@odoo.com>
2023-04-07 11:37:25 +02:00
Joseph Caburnay 762aefc455 [REM] point_of_sale,pos_restaurant: remove marked up headers
Currently, the "receipt_header" and "receipt_footer" text fields of the
'pos.config' model can be used to render html in the receipt using qweb by
putting `<!DOCTYPE QWEB` as the first line of the text. In the previous
versions, it is converted to a markup so it is rendered as html in the
receipt. Rendering it as markup poses security issues therefore we are
removing this feature in this commit.

After this commit, we now only allow regular string to be added in the
receipt and footer headers.

If user wants to introduce custom markup in the headers, they can
properly do so by extending the `OrderReceipt` template from other addons.

closes odoo/odoo#117336

Task-id: 3256208
Signed-off-by: Trinh Jacky (trj) <trj@odoo.com>
2023-04-07 11:37:20 +02:00
Abderraouf Ghrissi (abgh) bd6428515a [IMP] project: Improve UX
Before this commit:
- project tasks view: when we group by company, milestone, customer,
worksheet template or any m2o field, the KanbanColumnQuickCreate is
displayed for that field, we can add a new one or apply examples,
but thoses examples are stages.
That doesn't make any sens to add them in a project or milestone context,
then if you add a new column manually or via the apply examples, it will
disappear once refreshing the page.
To summarize, stage is the only valid group by that can have the
KanbanColumnQuickCreate.

- all tasks view: same problem as the previous point + quick creating
is also not valid for group by stage as we are in all tasks context that
are linked to different project and the examples are mainly applied for a specific
project, if you try to add manually or via the examples and refresh they are going
to disappear as they are not linked to any project.

- my tasks view, same problem for previous point + quick creating when grouping
by personal stage is valid but apply examples  button is displayed to show stages and if
used, it will not add anything, so it should be hidden.

- Project Kanban examples stages are all created as not folded.
Some users don't know that 'folded in kanban' option is available on the stages,
and that tasks in a folded stage are considered as done.

After this commit:
- project tasks: KanbanColumnQuickCreate and applying examples are only available
when grouping by stage.

- all tasks: KanbanColumnQuickCreate is not available.

- my tasks: KanbanColumnQuickCreate is only available when grouping by personal stages.
applying examples is not available.

- some example stages are folded..

task-3092925

closes odoo/odoo#107633

Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
2023-04-07 11:37:03 +02:00
niyasraphy 5eb49e3712 [FIX] web: calendar filter not showing selection values
before this commit, in the calendar view, if there is
a field of selection field, instead of showing the
filter value, currently it is shown as undefined.

after this commit, the filter will show the selection
value instead of undefined.

closes odoo/odoo#118007

X-original-commit: edf838d791ee02f41af2bff32dc20b5657ef0d81
Signed-off-by: Bruno Boi (boi) <boi@odoo.com>
2023-04-07 10:32:59 +02:00
flvr-odoo 3c180713fd [FIX] web: blocked pop-up warning always shows
partial revert of https://github.com/odoo/odoo/pull/117205

Since there was no link between the odoo instance and the new tab,
it was impossible to determine if it was really open and the test
afterward would always trigger

closes odoo/odoo#117973

X-original-commit: 5717eeec9eb8d5cc9cd684e6b147919d808f5db1
Signed-off-by: Vranckx Florian (flvr) <flvr@odoo.com>
2023-04-07 10:32:57 +02:00
Soukéina Bojabza 1ef31c2822 [FIX] web_editor: fix history of a drag and drop after a resize
Steps to reproduce:
​- In a snippet in grid mode, resize a column.
- Drag and drop this column in a non-grid dropzone. 
​- Undo.
​=> The column is back in the grid but is still a normal column. The same
happens when doing these steps with a normal column to a grid. 

This happens because the class changes are not observed in these cases.
When fixing the drag and drop history in [1], only the style changes
were observed because the class changes are automatically recorded. But
it is not the case after a resize.

This commit fixes that by also observing the class changes.

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

task-3151207

closes odoo/odoo#117854

X-original-commit: 48b3683c4753f1e385ea1692db9c1a15d32cae30
Signed-off-by: Arthur Detroux (ard) <ard@odoo.com>
2023-04-07 10:32:54 +02:00
Soukéina Bojabza 33dd221b45 [FIX] web_editor: fix some grid layout mistakes/oversights
This commit fixes some mistakes that were found in the code of the grid
layout option. More precisely:

- When a column was dropped near a grid dropzone (so not inside it), and
if its height was bigger than the grid, the `rowCount` attribute of the
row was not updated to the correct number of rows => there was one extra
row.

- When we start dragging a grid item, if we do not go over the starting
grid at all (it happens if the move handle is placed outside of the
row), the `rowCount` of the starting grid was never updated. This is
because the resize is done at the "out" of the dropzone so if there was
no "over", it cannot be done.
=> As a fix, the starting grid is now always resized when we drop the
column.

- When dropping a grid item inside a non-grid dropzone, its `z-index`
CSS property was not removed.

- When a grid item becomes a normal column, when dropping it in a non-
grid dropzone or when toggling the normal mode, the resize classes
(`g-col-lg-*` and `g-height-*`) were not removed from it.

- When a normal column becomes a grid item, the padding and offset
classes were not removed and the `col-` class was not systematically
synchronized with the `g-col-lg-*` class.

=> The two previous points need to be fixed because after doing multiple
drag and drops, the classes could become inconsistent. This happened
especially with columns whose width changes a lot between snippets (like
with Masonry columns, because of the padding).

- When going back to normal mode, the `--grid-item-padding-*` CSS
variables were not removed from the row.

- In commit [1], a comment that should have been modified has been
forgotten.

[1]: https://github.com/odoo/odoo/commit/67d1b078329600efce414974307d74e9fa9ba9fe

task-3151207

X-original-commit: 4afd418e1a1d4231369aab08dfa5c2d10ca9a310
Part-of: odoo/odoo#117854
2023-04-07 10:32:54 +02:00
Thomas Lefebvre (thle) 421ebc45f1 [FIX] website_sale: check selector before use it
Steps to reproduce:
- install website_sale;
- with web editor add a language selector to the top bar menu;
- go to the page '/shop/cart';
- click on the cart.

Issue:
A traceback appears.

Cause:
We use the property of a HTML element without checking its presence.

opw-3246545

closes odoo/odoo#117966

X-original-commit: e6829c38ff3fc0139583be94bf6f86c9acaab8fa
Signed-off-by: Antoine Vandevenne (anv) <anv@odoo.com>
Signed-off-by: Lefebvre Thomas (thle) <thle@odoo.com>
2023-04-07 09:29:57 +02:00
arsi 8d48cb971a [FIX] l10n_in_edi: search rounding line in line_ids
Problem:
Indian edi doesn't take into account the round off.

Cause:
It is looking for rounding lines in `invoice_line_ids`, but since v16,
rounding lines are no more invoice lines.
`invoice_line_ids` is a subset only consisting of move lines
having a `display_type` in `('product', 'line_section', 'line_note')`
and a rounding line is a move line with a `display_type == 'rounding'`.

Fix:
Rounding lines must be searched in `line_ids` and not in
`invoice_line_ids`.

opw-3202845

closes odoo/odoo#117922

X-original-commit: a07d9683eae9c49cb8a36c6b1781c33d48eb03cb
Signed-off-by: Cedric Snauwaert <csn@odoo.com>
Signed-off-by: Arnaud-Sibille <arsi@odoo.com>
2023-04-07 08:24:51 +02:00
FrancoisGe afbdce664f [IMP] web: remove read in kanban grouped with group_by_tooltip
This commit introduces an optimization to reduce the number of read
operations performed in kanban views that are grouped by a field with
a group_by_tooltip. Specifically, we now fetch the required values
from group_by_tooltip only when the tooltip is first opened, instead
of performing a read every time the view is loaded.

Part of Task: 3179751

closes odoo/odoo#117758

Related: odoo/enterprise#39349
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
2023-04-07 07:28:09 +02:00
Yolann Sabaux b9f0758350 [FIX] account: enable edit taxt total on purchase receipt
Steps to reproduce:
- activate Purchase Receipt
- Create a Purchase Receipt

Issue:
- the edit tax total is not displayed as it is in Bill

opw-3253060

closes odoo/odoo#117980

X-original-commit: a7706ae581bcdb02fd72035ac67208cb4197a009
Signed-off-by: William André (wan) <wan@odoo.com>
2023-04-07 01:16:54 +02:00
Paolo Gatti (pgi) 6c19228fee [FIX] l10n_it: Fixing some account type in ITA CoA
A small part of the accounts type were incorrectly changed in Odoo 15 by odoo/83039
We are bringing the old type back.

Task link: https://www.odoo.com/web#id=3263687&model=project.task
task-3263687

closes odoo/odoo#117972

X-original-commit: 2cf512bc8785a73280b875cef332ac61447b9f3e
Signed-off-by: Josse Colpaert <jco@odoo.com>
Signed-off-by: Paolo Gatti (pgi) <pgi@odoo.com>
2023-04-06 20:13:51 +02:00
Alexandre Kühn 260e5de3df [FIX] mail: better border visual of chat window
closes odoo/odoo#117969

Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2023-04-06 19:16:56 +02:00
Alexandre Kühn 104ad53516 [FIX] mail: correct orientation of self bubble in chat window
closes odoo/odoo#117965

Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2023-04-06 19:16:53 +02:00