Commit Graph
164488 Commits
Author SHA1 Message Date
Alexandre Kühn 5c2093f2a2 [REF] mail: redirect model insert in store
Part-of: odoo/odoo#133202
2023-08-28 20:14:40 +00:00
Alexandre Kühn 5a91d3e5c8 [REF] mail: change shape of store model records
In preparation of code cleaning of models in store.
Entries in store are allocated per model, using the model name.
Records of a model can be accessed from `store[ModelName].records`.

Part-of: odoo/odoo#133202
2023-08-28 20:14:40 +00:00
Eteil Djoumatchoua(etdj) 821e7b2cc9 [FIX] stock: Get the right quantity when saving a scrap order
Steps:
- Create a product tracked by serial number
- Create a new scrap order in inventory -> operations
- Add the created product, the serial number and save.

Issue:
The quantity is automatically set to 0.00 after saving.

Reason:
The ``StockScrap.scrap_qty`` field is computed and has a default value set to 0.0. On the
xml form view when ``StockScrap.tracking`` is set to 'serial' the field is readonly and is not
sent to the server when saving so the default value is used.

The problem appears because initially the ``StockScrap.scrap_qty`` was precomputed so even it wasn't
sent by the form, we already had the value. With the changes made we can't use ``precompute=True``
because ``StockScrap.scrap_qty`` depends on fields which aren't precomputed.

Solution:
In this context we have 3 cases:
- If ``StockScrap.tracking`` is 'none', ``scrap_qty`` is not readonly so sent.
- If ``StockScrap.tracking`` is 'lot', ``scrap_qty`` is not readonly so sent.
- If ``StockScrap.tracking`` is 'serial', ``scrap_qty`` is readonly so not sent.

As the only case of the issue is when the product is tracked by serial number(only one product) we can,
set the default value of ``StockScrap.scrap_qty`` to 1.

opw-3470888

closes odoo/odoo#132895

X-original-commit: 0d9fa534c3c17e87210f9d24cc90991d6dd8c0be
Signed-off-by: Adrien Widart (awt) <awt@odoo.com>
Signed-off-by: Eteil Junior Djoumatchoua (etdj) <etdj@odoo.com>
2023-08-28 16:42:07 +00:00
shsa-odoo 9d49150afa [FIX] web_editor: remove block tooltip should not stuck
Before this commit:

Remove Block tooltip gets stuck after click and mousemove.

After this commit:

Remove Block tooltip hides as mousemoves.

task-3432060

closes odoo/odoo#132888

X-original-commit: 095721a9cace476c3eae445c7abd8f8b458aea36
Signed-off-by: David Monjoie (dmo) <dmo@odoo.com>
2023-08-28 16:42:06 +00:00
Guillaume (gdi) 9063e5dd63 [REM] website_event_track_quiz: remove dead code
As it is not possible to have a `.o_wslides_home_nav` in a `o_quiz_main`
we can remove the scss dead code related to it.

task-3476128

closes odoo/odoo#132793

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2023-08-28 16:42:05 +00:00
std-odoo 8ddb558a2e [FIX] web: fix error with properties due to the relational model refactor
Bug
===
Since 8723f020c3 , they are some tracebacks
with the properties when switching the views. For example, if you open
a many2many properties record (by clicking on the badge), and then go
back to the original form view, a traceback is raised.

Task-3460126

closes odoo/odoo#131394

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2023-08-28 16:42:03 +00:00
std-odoo 5a23c4dd1e [FIX] web: fix the unity read with relational properties
Bug
===
Since 7d2baaa0c7 , we read the field
with `web_read`. We don't load the display name when calling read,
but instead we load them after.

But, since this change, the display names of the relational
properties are not loaded.

To fix that, we always load the display name of the relational
properties because it's a purely frontend field.

Task-3460126

Part-of: odoo/odoo#131394
2023-08-28 16:42:03 +00:00
Loan (LSE) 1d4cbf99fd [FIX] hw_drivers: support for TM-U escpos printer models
Before this commit:
When printing a receipt with an epson printers models TM-U2X0 (like
TM-U220), random characters will be printed instead of the receipt.

This happened as a picture of the receipt is sent to the IoT box, but
the TM-U2X0 models does not support all "Bit Image commands". We
currently use the GS v 0 one which is not supported by this printer
models. See:
https://reference.epson-biz.com/modules/ref_escpos/index.php?content_id=94

In addition, of that, the command itself is obsolete.

After this commit:
The support for another command "ESC *" is added which is not obsolete
and supported by TM-U2X0 models.

Notes:
 - Compared to "GS v 0", the receipt printed with "ESC *" is worst:
  - It take longer to print (5 seconds vs 1 second)
  - There is consistently some thin "empty white lines"
 - Most of the code is inspired from `python-escpos`:
 https://github.com/python-escpos/python-escpos/blob/master/src/escpos/escpos.py

Due to the drawbacks, making it the default way to print would be a bad
idea. As such, we can configure the mode (with other parameters) using
particular name for the printer (which can be done by adding it manually
 with cups)

opw-3351084,3341907

closes odoo/odoo#131332

X-original-commit: f30085bf673712c205e7ff318961d597297648d0
Signed-off-by: Joseph Caburnay (jcb) <jcb@odoo.com>
Signed-off-by: Loan Sens (lse) <lse@odoo.com>
2023-08-28 16:42:02 +00:00
Karnav Sojitra b0b4f7b3ad [FIX] base, tools: raise logger warning while invalid attribute added to a field
This error occurs when a user tries to add an Invalid attribute
(ex-help, searchable) to an element field.

Steps to produce:
- Install Studio.
- Open any tree view.
- Activate studio > Go to views > Click on XML.
- Add an attribute help inside any field.

So, this commit handles the case by changing the logger error to logger warning.

sentry-4377111502

closes odoo/odoo#131164

X-original-commit: 10f45eacdfd4c6fe5d86659276d145a563f60c6c
Signed-off-by: Fabien Pinckaers (fp) <fp@odoo.com>
Signed-off-by: Rémy Voet (ryv) <ryv@odoo.com>
2023-08-28 16:42:01 +00:00
ravb-odoo 0d996dc2c0 [IMP] hr_ timesheet, sale_timesheet: hide 'To invoiced' field and rename some fields
before this commit, when time and material section is visible then 'To invoiced'
field is also visible in portal.

This commit hide the 'To invoiced' field in portal when time and material
section is visible and rename some fields.

closes odoo/odoo#126053

Task: 3251754
Related: odoo/enterprise#42995
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
2023-08-28 16:41:59 +00:00
Christophe Monniez 8ad3fa51ab [FIX] account,base: fix TestIrActionsReport
With Python 3.11, PyPDF2 2.12.1 is used and the exception raised when
the encryption type is not supported is now `NotImplementedError`
instead of `PdfReadError` in previous version.

In order to support both version, this commit adds a catche for the
`NotImplementedError` too.

closes odoo/odoo#133242

X-original-commit: effff7e00d8d410106e12e7ea42c8a875a11bb8b
Signed-off-by: Christophe Monniez (moc) <moc@odoo.com>
2023-08-28 11:24:43 +00:00
Guillaume (guva) 2ea2f268c2 [FIX] account: don't auto save on boolean widget
When creating a reconciliation model line on
a new record, by activate the boolean toggle on
`force_tax_included` field, the line is save
but as the reco model is not, `check_company`
will raise an error.

Steps:

- Create a new model
- Before saving, create a line, set a tax and
  click on Tax included toggle button
-> Error is raised

opw-3473189

closes odoo/odoo#133233

X-original-commit: 796478445e5bc7da95b8a0aaab4dcbe235bb2957
Signed-off-by: Brice Bartoletti (bib) <bib@odoo.com>
Signed-off-by: Guillaume Vanleynseele (guva) <guva@odoo.com>
2023-08-28 11:24:42 +00:00
Valentin Chevalier 74ea712bab [FIX] sale: can't open catalog with product on multiple lines
In 89d5d1f, changes have been made to the catalog to ease inheritance.
Since this change, opening the catalog with products spread over
multiple lines on the SO crashes.

Now, the catalog will open even if the SO contains products spread
across multiple lines.

closes odoo/odoo#133217

Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
2023-08-28 11:24:41 +00:00
Alexandre Kühn 15d6f2f9b4 [FIX] mail: can use full composer in reply-to from mailbox
Before this commit, when replying to a message from mailbox
in the Discuss app (e.g. Inbox or History) and then clicking
on the "Full Composer" button, there was the following crash:

```
Invalid res_ids ['history'] (type <class 'str'>)
```

This happens because the full composer button was attempting to open
the full composer on the mailbox at hand, e.g. 'history', instead of
the document related to the message, i.e. the origin thread of the
message.

The code of this button assumes that it's only visible when viewing
the message in the origin thread. In this case, the shown thread
(`props.composer.thread`) matches the origin thread (`thread`) of
message. This is always the case except in mailboxes, so using
`props.composer.thread` is erroneous in mailboxes.

This commit fixes the issue by correctly opening the full composer of
the document related to the message, by using `thread` instead of
`props.composer.thread`, which is the origin thread of the message.

Also make full composer button rounded (`mx-1` => `m-1`)

opw-3453680

closes odoo/odoo#132910

X-original-commit: 69d1776513a5eff06fca84bc070c4678b84829ed
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2023-08-28 11:24:37 +00:00
Merel Geens (mege) c65fb9d198 [IMP] odoo: prevent unsafe import from file
It's possible to specify an existing module as the xml id prefix when
importing records from a file. This will result in `ir_module_data`
records being created with `noupdate` set to False. When the module is
upgraded, these records will be deleted.

This can lead to undesired side effects like journal items for
accounts imported this way being deleted.

This change prevents creating new records linked to existing modules
when importing from a file. Instead, the user should either use no
prefix or the name of a non-existent module, like `__import__`.

opw-3231987

closes odoo/odoo#133263

X-original-commit: 8f12d14c4c4354a63c94f14e7a89abc6048525f9
Signed-off-by: Merel Geens <mege@odoo.com>
2023-08-28 09:34:05 +00:00
Thomas Lefebvre (thle) 2fd34609b3 [FIX] hr_recruitment: correct count in mutli-company context
Steps to reproduce:
-------------------
- create a job position without specifying the company;
- being in the first company, create an application for this job position;
- being in the second company, create an other application;
- go to the job position kanban view;

Issue:
------
Despite the selected company, the count for this job application is still two.

Solution:
---------
Include the allowed companies in the query to count the number of applicants.

opw-3453348

closes odoo/odoo#133262

X-original-commit: 8bce129a9943448e51a0e672a1ac18a3c1221866
Signed-off-by: Sofie Gvaladze (sgv) <sgv@odoo.com>
Signed-off-by: Thomas Lefebvre (thle) <thle@odoo.com>
2023-08-28 09:34:04 +00:00
Gurupreet Singh dbc660513c [FIX] project: fix visibility of subtask assign button in kanban view
In the project, the kanban view assign button is  visible in the subtask

task-3374861

closes odoo/odoo#132986

X-original-commit: 2669881160e474459158e61e9914e3024ae75d5e
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
2023-08-28 09:34:01 +00:00
Gurupreet Singh c40b2cff80 [FIX] sale_project: fix the visibility of billable field
Project Sharing  subtasks view's notebook, hide the Billable field which is an
read-only field

task-3374861

X-original-commit: 2d932181d6c7d86b26a07d10990b453f7b86a938
Part-of: odoo/odoo#132986
2023-08-28 09:34:01 +00:00
Saurabh Mishra f1f4ef1d8f [FIX] web_editor: get image source while modifying it
If the user is using the `note` or any other module to add and modify images,
and they try to crop the image and apply the changes, they may face an error if
they try to crop it again without clicking on `apply changes` and instead click
somewhere outside the image.

steps to produce:
- Install `note`.
- Create a note, add an image in it.
- Click on image to crop it, select the portion you want to crop and then
  click on `Apply` to apply changes.
- Select the image again, click on crop icon and then click anywhere outside the
  image boundaries.

Error: `TypeError: 'bool' object is not subscriptable`.

Applying this commit will solve the issue because, after applying it, whenever
`modify_image` is called, `datas` will receive the proper source.

sentry-4185609374

closes odoo/odoo#133164

X-original-commit: 0c38bb37e720a3c06f59becbf9bcc78f9f978723
Signed-off-by: David Monjoie (dmo) <dmo@odoo.com>
2023-08-28 07:11:03 +02:00
Archana Vaghasiya fca1b3a5a4 [FIX] account_edi_ubl_cii: handle the date format while import invoices
When the user tries to import the invoice file with space on both sides
of the date value the error will be generated.

Steps to reproduce:
1. Install the `account_edi_ubl_cii` module.
2. Generate one `factur-x.xml` file or import this file
https://drive.google.com/file/d/1RCqLT37j2g6LPkauf75LpOzZt64XHd_L/view?usp=drive_link
3. Go to the invoice app and click the `upload` button.
4. Select the `factur-x.xml` file and an error will be generated at the backend
and nothing to be imported.

This commit fixes the issue by removing the extra spaces in the date value,
if user gives the spaces in the invoice file.

see-
https://github.com/odoo/odoo/blob/a0ea6302a574624604cad7d0903711b30a4802a6/addons/account_edi_ubl_cii/models/account_edi_xml_cii_facturx.py#L315

sentry-4331059603

closes odoo/odoo#132670

X-original-commit: 1f32b5ec0e1a670a879d983c45a3108f73341435
Signed-off-by: Laurent Smet (las) <las@odoo.com>
2023-08-28 04:10:52 +02:00
Krzysztof Magusiak 05baa663ff [FIX] mail: _search_message_partner_ids performance
Use the operator inselect instead of in with a read() before it.
This ensures a subquery is used instead of two separate queries.

When you have a user that is following thousands of tasks and the
security filter depends on this search, all queries are very slow. Using
a subquery prevents from reading these ids and sending back a very long
query to the database.

closes odoo/odoo#133273

X-original-commit: 7f9e98c0d7441b2103df0b89183b6949f3bc9b69
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
2023-08-27 16:59:14 +02:00
Pratik Awasthi c8ee4e645b [FIX] project: fix project tour description
Steps:

- Install project
- run project tour

Issue:

- no description while adding the column

Cause:

- the description was not present in the project tour for column

Fix:

- added description for adding a column in the tour

task-3388985

closes odoo/odoo#133047

X-original-commit: a3f12bcebf66e57212ce0e6d4b46f986ae6c9c33
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
2023-08-26 12:32:05 +02:00
Gurupreet Singh 0aab0bf13e [FIX] sale_project: fix tasks stat button traceback
steps:
-install sale module.
-create product with product type as course
-Generate a sale order containing the newly created product.
-link the sale order to any project task, and then attempt to view the tasks
 stat button  by clicking. However, encounter an unexpected traceback or error
 message during this action.

issue:
In the sale module quotation view, the traceback is occurring when clicking on
the tasks stat button

fix:
Improved action_view_task method in sale_order model to handle missing sales
order lines with 'service' products. Set default project ID when no suitable
sales order line is found, preventing errors and ensuring smooth functionality.
Refactor involved using conditional expressions for better readability and
maintaining default behavior.

task-3436556

closes odoo/odoo#132981

X-original-commit: 10838145c0981e46221b2cbf65b2c4ce84c3b8c7
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
2023-08-26 12:31:56 +02:00
Dhrumil Shah f985996acd [FIX] sale_project: fix quantity_percentage field editable in list view
Before this commit quantity_percentage field was not editable in list view

Issue:
- when trying to edit quantity field in milestone , it's not editable in list view

Fix
- when trying to edit quantity field in milestone it becomes editable by making
  field readonly false

task-3444728

closes odoo/odoo#132958

X-original-commit: 562a454731326a054f8f4c54e8350a2faf1c1c7f
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
2023-08-26 12:31:50 +02:00
Loan (LSE) 21b5508f30 [FIX] point_of_sale: cashdrawer does not open in direct device
Connecting a cashdrawer to an ePoS printer in direct device ( NOT with
an IoT box) will not automatically open the cashdrawer as it would be
intended when paying with cash.

This happens due to the fact that we check that the printer connection
is "connected" which is not the case with direct device as it use the
default value in the setup which is "disconnected".

opw-3470241

closes odoo/odoo#133216

X-original-commit: 339a76885db0f2034bae21eec76d0127d2733205
Signed-off-by: Joseph Caburnay (jcb) <jcb@odoo.com>
Signed-off-by: Loan Sens (lse) <lse@odoo.com>
2023-08-25 18:50:21 +02:00
Guillaume (guva) 701fd8538a [FIX] account: setup bank wizard validation
When adding a bank account via the setup wizard,
an User Error is raised ("Incompatible companies on records")
Since 0479b2b594,
`check_company` is set to `True` on
`SetupBarBankConfigWizard.linked_journal_id`, but
the model has no `company_id` field.
Therefore in `BaseModel._check_company()`, no
company is found and we raise the error.

Steps:

- Go to accounting dashboard
- Make sure the "onboarding" banner is not removed from the view
- Click on "Add a bank account" on the banner
- Try to create a new one (bottom right of the wizard)
- Enter an account number, select a bank and validate
-> Error is raised

opw-3473184

closes odoo/odoo#133214

X-original-commit: 8d9c0c27d389ecd21a5c32ebba1e8da14316b6c0
Signed-off-by: Brice Bartoletti (bib) <bib@odoo.com>
Signed-off-by: Guillaume Vanleynseele (guva) <guva@odoo.com>
2023-08-25 18:50:17 +02:00
Martin Maes 6ed9da235c [FIX] mrp: workorder list view traceback
When opening the list view of workorders, a traceback was triggered.
The problem was that parent was not defined when not in a view form.
Checking if parent first exists solves the problem

closes odoo/odoo#133213

Signed-off-by: William Henrotin (whe) <whe@odoo.com>
2023-08-25 18:50:12 +02:00
Antoine Guenet 5996d98e66 [FIX] mass_mailing: hide the Mail Debug tab
The Mail Debug tab is confusing for users and should only be used by
people who know what can or cannot be expected from it. It is not
providing a good preview of the e-mail's rendering since the HTML it
displays is not meant to be rendered by a browser but by all sorts of
e-mail clients. This means that some things that render properly in it
won't necessarily render properly in some e-mail clients, but also
likewise that some things that don't render properly in it will in fact
render as expected in e-mail clients. This is why it's only available in
debug mode but since many users routinely enable debug mode to get
access to hidden features, this is not enough to prevent them from
reporting issues that are not issues.

closes odoo/odoo#133208

X-original-commit: 240ee9deb898f4346a9bc66548c881fc69e8b117
Signed-off-by: David Monjoie (dmo) <dmo@odoo.com>
2023-08-25 18:50:07 +02:00
Xavier ALT aa1b4e80e7 [FIX] mail: disable fetchmail servers on neutralize
When neutralizing the database we should disactivate all
fetchmail servers to prevent data loss (ex. when using POP)

opw-2758998

closes odoo/odoo#133199

X-original-commit: f1871890b79ee45c3addf467e544a06e534d1e9e
Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
Signed-off-by: Xavier Alt (xal) <xal@odoo.com>
2023-08-25 18:50:02 +02:00
Sébastien Theys 4394618323 [FIX] mail: prevent long follower list overflow
Back-port of https://github.com/odoo/odoo/pull/130451

Adapt to 50vh instead of 95vh, as the button is quite in the middle of
the page for small heights, 95vh is still too much.

closes odoo/odoo#133193

X-original-commit: 9c3c44bcfd4bafd95428c8342abc917e0175f7e1
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
2023-08-25 18:49:58 +02:00
zel-odoo 29d169274b [FIX] mail: picker shift-selection not reset pos
task-3473164

closes odoo/odoo#133192

X-original-commit: bfb1d9809cf5b04e22e581d38f7972e33ffa74d3
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2023-08-25 18:49:48 +02:00
Thomas Lefebvre (thle) aeb63498de [FIX] hr_employee: ensure desynchronization with user
Steps to reproduce:
-------------------
- create a new employee;
- link it to an existing user;
- save (trigger a validation error);
- remove the related user;
- save;
- change the email address of this new employee;

Issue:
------
The email address of the employee linked to the user
that we tried to link is updated.

Cause:
------
We don't sync the employee with the user if the user is `False`,
i.e. we don't update the employee's `work_contact_id` if the `user_id` is `False`.

Solution:
---------
Update the `work_contact_id` in any case.

opw-3475002

closes odoo/odoo#133191

X-original-commit: c2f2dc3e49ee7cd96d4da05f2236441e65090753
Signed-off-by: Sofie Gvaladze (sgv) <sgv@odoo.com>
Signed-off-by: Thomas Lefebvre (thle) <thle@odoo.com>
2023-08-25 18:49:43 +02:00
Renilkumar Kajavadra a088edb163 [FIX] stock: multiple warehouses in replenishment
Company can have multiple warehouses,
when user open replenishment and company has multiple warehouses.
this will lead to below traceback.

Steps to reproduce the error:
- Go to 'Manufacturing' > Configuration > Settings > Enable Subcontracting
- Go to 'Contacts' > Create a Contact > Sales & Purchase >
  Open Subcontractor Location > Enable Replenish Location
- Go to 'Inventory' > Configuration > Warehouses > Create multiple warehouses
- Create a storable product > Create BoM > Set Subcontracting in BoM Type >
  Set already created contact in Subcontractors > Save
- Go to 'Purchase' > Set Subcontractor in Vendor > Add Product > Confirm Order
- Go to 'Inventory' > Operations > Replenishment

Error: A traceback appears:
'ValueError: Expected singleton: stock.warehouse(1, 2, 3, 4)'

https://github.com/odoo/odoo/blob/3864542914efcb9d4e3cabd3cfdeecb842e4f380/addons/stock/models/stock_orderpoint.py#L414
here, we can get multiple warehouses for a company.
So it will lead to above traceback.

sentry-4358838167

closes odoo/odoo#133178

X-original-commit: fd0e104c13fae2c2b34443502b88017ef98e5523
Signed-off-by: William Henrotin (whe) <whe@odoo.com>
2023-08-25 18:49:39 +02:00
Pablo Montenegro 45c378d84c [FIX] l10n_latam_check: check number if payment method is "New Third Party Checks"
Task Adhoc: 33137
Task Latam: 1073

Description of the issue/feature this PR addresses:
Check number is not required for payments when payment method "New Third Party Checks" but is needed to be required.

Current behavior before PR:
Check number is not required for payments when payment method "New Third Party Checks".

Desired behavior after PR is merged:
Check number is required for payments when payment method "New Third Party Checks".

closes odoo/odoo#133123

X-original-commit: 697f67b3c287947becf1124f98b075884ea8b444
Signed-off-by: Josse Colpaert <jco@odoo.com>
2023-08-25 18:49:34 +02:00
Jorge Pinna Puissant 0fd1790fb5 [FIX] web: kanban column counter when grouped by a date
Before this commit, if the kanban was grouped by a date field, and have
an aggregate, the column counter was always 0.

Now, the column counter has the correct value.

closes odoo/odoo#133114

X-original-commit: ea3809a480c29eafd6ab8433d5ae0e378b1d9967
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Signed-off-by: Jorge Pinna Puissant (jpp) <jpp@odoo.com>
2023-08-25 18:49:30 +02:00
Maryam Kia 35ce7b9991 [FIX] mail: reduce effect duration of animation in stop recording voice message
closes odoo/odoo#133182

Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
2023-08-25 17:44:12 +02:00
niyasraphy 6fffa5e68f [REM] purchase_price_diff: remove module purchase_price_diff
before this commit, the module has been removed in this
commit: https://github.com/odoo/odoo/commit/a022fefbaf2f9c7041d2a790661d3cba64dfff51
and the translation file get left over without deleting

after this commit, the remaining file of module will be removed.

closes odoo/odoo#133166

X-original-commit: af783444ef0c149f602691a05cf32b5a8d852120
Signed-off-by: William Henrotin (whe) <whe@odoo.com>
2023-08-25 17:43:57 +02:00
mehjabinfarsana f7c3c39a59 [FIX] point_of_sale: make confirmation message translatable
before this commit, the confirmation message
to use web printer was not translatable
to user language

after this commit, confirmation message will
be shown in user's language

closes odoo/odoo#133165

X-original-commit: 916b07f467bb6dad06f452b4437f01193209ff25
Signed-off-by: Joseph Caburnay (jcb) <jcb@odoo.com>
2023-08-25 16:00:33 +02:00
Adrien Widart (awt) 4cb09b80c8 [FIX] mrp: prevent bom cycle
To reproduce the issue:
1. Create two products A, B
2. Create two BoMs:
   - Product: A
     - Component: B
   - Product: B
     - Component: A
3. On one BoM, open the report "Structure & Cost"

Error: an Odoo Server Error is raised: "[...] maximum recursion
depth exceeded while calling a Python object"

The error occurs because of the cycle between both BoMs. There is
already a check for that in `:MrpBom.explode`:
https://github.com/odoo/odoo/blob/2a73890d304476833d76bac9a36ef92f12f267a3/addons/mrp/models/mrp_bom.py#L329
But it's too late in the flow. We should not be able to configure
such BoMs.

OPW-3200969

closes odoo/odoo#132806

X-original-commit: ba66f6b2ad3ea226779af23cdb4ddf223dd7fe85
Signed-off-by: Adrien Widart (awt) <awt@odoo.com>
2023-08-25 16:00:23 +02:00
niyasraphy 397d889805 [IMP] point_of_sale: option to print sales details from session
before this commit, if user need to take the sales details
of a pos session, user cannot directly take from the session
form in the pos backend.

if needed from the backend, user has to print from the
point of sale -> reporting -> session report

after this commit, the report will be shown also in the
pos session form, so that user can print the details
by clicking the report from print button in the top
without going to reporting menu.

closes odoo/odoo#132446

Signed-off-by: Joseph Caburnay (jcb) <jcb@odoo.com>
2023-08-25 16:00:18 +02:00
Jorge Pinna Puissant c885e76152 [REF] *: remove unused parameter from record save method
Remove unused parameters from record save method :
- stayInEdition
- useSaveErrorDialog
- savePoint
- force
- closable

closes odoo/odoo#133152

Related: odoo/enterprise#46289
Signed-off-by: Pierre Rousseau (pro) <pro@odoo.com>
2023-08-25 13:59:00 +02:00
clesgow 6629bb802c [FIX] mrp: allow access to workorder tree view
Following 332c117, the list of workorders cannot be accessed from the
menu. This is due to the `parent` not being defined in this case. The
`column_invisible` clause is useful when using the tree view from within
a MO form.

Before the change, the `attrs` attribute (containing the
`column_invisible` clause) was overwritten in the inherited view that is
accessible from the menu. Now that each previously-attrs are separate,
we need to explicitely overwrite `column_invisible` to get rid of the
reference to `parent`.

closes odoo/odoo#133026

Signed-off-by: Tiffany Chang (tic) <tic@odoo.com>
2023-08-25 13:58:55 +02:00
althaf shaik 19d9473010 [FIX] account: handle error when send and print invoice without email template
This traceback raises when user tries to send an invoice without email template.

To reproduce this issue:

1) Install 'Accounting'
2) Open any existing invoice (not a draft one)
3) Click Send & Print button, an wizard will be opened
4) Make 'Use template' blank and give any subject
5) Click on 'send and print' button of wizard.

Error: "Expected singleton: mail.template()"

Note:- This traceback also appears when cron job
(model._cron_account_move_send(job_count=20)) runs.

On '_send_mails' method 'mail_template' variable is getting value from
'self.mail_template_id'. When user removes the template from wizard,
'mail_template' will be false.

See:
https://github.com/odoo/odoo/blob/ce2140fc73e46906acf3963d8bdf9694a499008a/addons/account/wizard/account_move_send.py#L461-L473

In the above usecase 'mail_template' is passed in 'get_default_email_from'
method as an argument, which is used to return
'_get_mail_default_field_value_from_template' method, in that
'mail_template' is used to 'render_field', in which ensure one is used.
It leads to above traceback.

sentry-4364692484

closes odoo/odoo#132847

X-original-commit: dde276cdac5124a5333d03e7a985a2c690d84080
Signed-off-by: Laurent Smet (las) <las@odoo.com>
2023-08-25 13:58:51 +02:00
Valentin Vallaeys (vava) f8d351aa43 [FIX] *: fix domain definition (not) in operator
* account, account_peppol, purchase_requisition, stock_delivery, base

There are some conditions in xml that uses `in` or `not in` for a check
with a string. These are replaced by `==` or `!=` operators,
respectively.

closes odoo/odoo#132798

Signed-off-by: Rémy Voet (ryv) <ryv@odoo.com>
2023-08-25 13:58:46 +02:00
divy-odoo c6f8f78115 [FIX] website_*: replace manual tour with utils
In this PR,
Replace the manual tour steps with existing tour utils.

task-3279232

closes odoo/odoo#129317

Signed-off-by: Romain Derie (rde) <rde@odoo.com>
2023-08-25 13:58:34 +02:00
Jurgen (jugj) e4ec187fcb [IMP] hr_recruitment_skills: Add skills type to configuration menu
task-3423558

closes odoo/odoo#128403

Signed-off-by: Sofie Gvaladze (sgv) <sgv@odoo.com>
2023-08-25 13:58:29 +02:00
Yannick Tivisse d6f574058e [FIX] hr: Use real group separator
closes odoo/odoo#105119

Related: odoo/upgrade#4879
Related: odoo/enterprise#32888
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
2023-08-25 13:58:25 +02:00
Yannick Tivisse a93472a4b2 [FIX] l10n_ch: Unlink res.config.settings after init
Purpose
=======

If not unlinked, it could make it impossible to create a not null
constraint on columns that are installed after l10n_ch before the
garbage collector dropped the existing wizard, leading to an error
like the following:

Table 'res_config_settings': unable to set NOT NULL on column 'ebay_currency'

Part-of: odoo/odoo#105119
2023-08-25 13:58:23 +02:00
Yannick Tivisse 33c299a4fc [FIX] hr_recruitment: Fix _track_template override in case of record deletion
Part-of: odoo/odoo#105119
2023-08-25 13:58:22 +02:00
Yannick Tivisse c0aabf3682 [FIX] hr_contract: Fix access issue on structure type
Part-of: odoo/odoo#105119
2023-08-25 13:58:21 +02:00