Now that the Debian 12 ("Bookworm") is out with Python 3.11 as the
default, it's time to update our requirements.
Reminder of the constraints for our requirements:
We try choose the smallest version from the Ubuntu/Debian corresponding
package (python3-...).
Also, if we find that one of the package was patched by the
Debian/Ubuntu maintainer, we choose the version from which the patch is
coming.
So, before this commit, the version were choose between Debian 11 and
Ubuntu 22.04. With this commit, we can simplify the requirements because
of a better matching between "Jammy" and "Bookworm".
About the choice of the python version:
* Ubuntu 22.04 ("Jammy") provides 3.10
* Debian 12 ("Bookworm") provides 3.11
* Some features that only exists in 3.9 will be needed in a near future
* 3.9 is a small release
Part-of: odoo/odoo#136904
Add missing '#' that prevent correct evaluation of the dynamic href
attribute.
To reproduce:
- To to /jobs
- Ensure 'Office Filter' page option is enabled
(if not edit the page and enable it)
- Click the office dropdown and hover 'All Offices'
We ends ups with a URL like:
`/jobs?{'all_countries=1' if is_remote else current_country_path}`
closesodoo/odoo#137907
X-original-commit: 8f3277c32f750a04dbfcfb3dd817b15bf0720574
Signed-off-by: Sofie Gvaladze (sgv) <sgv@odoo.com>
Signed-off-by: Xavier Alt (xal) <xal@odoo.com>
Since [1], live chat visitors are using the mail guest system for
authentication. With this change, visitors are allowed to reach the
attachment upload routes (even if nothing allows it in the frontend
for now). This commit restricts attachment upload for guest and portal
users with the `allow_visitor_upload` field that can be toggled.
At the same time, this commit enables file upload when authorized
on the frontend and for cross origin live chats.
[1]: odoo#129770
task-3332628
closesodoo/odoo#137574
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Improve following feature :
- visible if someone signed the quotation and it should be readonly on the
quotation.
- make optional field "customer reference" in list view.
- make optional field "Expiration" in list view.
- add sub-menu under the reporting menu:
1. "Sales" :- redirect to the current report.
2. "Salespeople" :- redirect to the current report but grouped by
salesperson.
3."products":- redirect to the current report with group by produts.
4."Customer":- redirect to the report with group by customers.
task-3369999
closesodoo/odoo#133780
Related: odoo/enterprise#46641
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
We do not clean the event handlers properly (because we do .bind()).
So we have another version of the handlers and they are not unbinded.
In this commit, to remedy this, we use the useBus function which
resolves this problem.
closesodoo/odoo#137885
X-original-commit: 7e2e2e0b257d44ce051a3ee8f60e9e03f5d14739
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Some strings were not translated in website_forum because translation marks
inside backticks will not be extracted to be translated.
i.e., Markup`${_t("Please translate me"}, OK` will not work.
This commit fixes the issue by explicit translation before putting it inside the
backticks.
Task-3462273
closesodoo/odoo#137857
X-original-commit: 5f33cdb8120661dad58eae9be1d6a511dc712bbd
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
Steps:
- on website or mass_mailing, insert an image via the "/image" command,
- a text node containing "[object HTMLImageElement]" is pasted instead
of the expected content.
Since [1], when inserting a node, the instanceof operator is used to
compare that node to the Editor's document global `Node` object. While
it fixed cases where there was as mismatch of `Node` objects (nodes
created by the top document x nodes created via the iframe's document),
it revealed errors elsewhere. Notably, the MediaDialog inserts an image
node created by the top document, regardless if the editor is mounted in
an iframe.
This commit makes the `insert` command more permissive when resolving if
'content' is a Node or a string.
task-3543003
[1]: https://github.com/odoo/odoo/commit/bfe0c5fedf172f4c77002a4f54803b376ada43ceclosesodoo/odoo#137872
Signed-off-by: David Monjoie (dmo) <dmo@odoo.com>
Steps to reproduce:
-------------------
- go to project form view;
- edit the sale order item of a task;
- make `is_so_line_edited` visible in Timesheet list on the form;
Issue:
------
The `is_so_line_edited` field is not set to `True`.
Solution:
---------
Use the widget designed to correctly update
the `is_so_line_edited` field.
opw-3476614
closesodoo/odoo#137854
X-original-commit: f74e8085e578820283d4be158a5156dd3d6d35c6
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
The motivation of this commit was to remove the override of owl
that disables the validateTarget check, which we believed was
necessary for the renderToString function.
Fun fact: renderToString doesn't seem to need the override, as
validateTarget is only called when mounting an app and when
completing a fiber, which renderToString doesn't do. It was instead
probably necessary for the legacy compatibily layers that have now
been removed.
So this commit removes the validateTarget override.
This commit also simplifies the setup of the renderToString fn by
lazy creating the app itself, instead of requiring the application
setup to set the main app as renderToString app (e.g. main.js in
web).
Part of task~3508223
closesodoo/odoo#137807
Related: odoo/enterprise#48514
Signed-off-by: Samuel Degueldre (sad) <sad@odoo.com>
Replace all the calls to get_resource_path to the better file_path or
directly use file_open when not needed
Doing both a get_resource_path and file_open means checking twice that
the file exists.
Doing a simple path concatenation before a file_open is safe.
If given to another method (e.g. etree.parse), calling file_path is
the prefered method.
Note that get_resource_path used to return False when the file does
not exists while file_path/file_open raises a FileNotFoundException
closesodoo/odoo#135607
Related: odoo/upgrade#5187
Related: odoo/enterprise#47475
Signed-off-by: Martin Trigaux (mat) <mat@odoo.com>
Description:
In eedf37d6e2 the index on
`create_date` was removed, but it was still left on our production
database. After recent analysis on the usage of the index over the
span of 2 months (start July 2023 -> end of August 2023), this index
was hit over *100M* times. It's heavily used in custom filters when
grouping by `create_date`. So the goal of this PR is to add it back
in standard code.
Reference:
task-3263544
closesodoo/odoo#134313
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
*: test_website_modules, website_sale
When one starts a trial with the website app, they arrive on a webpage
in edit mode. Many users struggle to understand they need to save before
accessing the Odoo navbar (app switcher, creation of new page, etc.).
Additionally, if they want to navigate through Odoo, not having to
discard could save some time.
It was therefore decided to land on the homepage without editor after
creating a website. The first step of the homepage tour should then be
to click on the edit button.
When creating an empty website (skipping the configurator), the website
loader is shown until the page is ready, to avoid the user leaving the
page before the first step is displayed.
On another related note, if one wants to try out the Odoo website
builder, they might create multiple DB, one per website, which is OK. In
such a case, the link to 'my database' is not visible from the website
app because the user profile was hidden.
The user menu is therefore added to the navbar on the website app.
In order to make sure the header and its dropdowns always stay on top of
the website's elements regardless of their z-index, `.o_website_preview`
is blocked in its own stacking context with `isolation: isolate;`.
task-3381773
closesodoo/odoo#133031
Related: odoo/enterprise#46992
Signed-off-by: Benjamin Vray (bvr) <bvr@odoo.com>
Before this commit, creating a record in Calendar view that has a
properties field in its form view causes a crash.
How to reproduce:
----------------
- Go to the Project app
- Go to a task
- Add a property
- Go to the Calendar view of the project
- Create a record
Before this commit:
An error is displayed
After this commit:
The form dialog opens so that you can create the record
closesodoo/odoo#137828
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Before this commit, when calling onchange, the mockServer returned all
the changes present in the onchanges functions defined on fields.
The expected behaviour is to return only the changes required by the view.
Part-of: odoo/odoo#137828
before this commit, if the entered attribute combination in
template is creating more than 1000 product, the operation
is prevented by raising UserError.
as of now, there is no option to increase or decrease the
limit if user need to do so.
system parameter: product.dynamic_variant_limit
after this commit, if user needs to increase or decrease
the limit, it can be done by adding a system parameter
and set the needed value
closesodoo/odoo#137783
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
Adds demo data for auto-reconcile.
We now have data that can auto reconcile:
- in both modes (zero total balance or opposite
balance one-by-one)
- on payable and receivable accounts
- by filtering on Azure Interior and/or Deco Addict
task-id:3517768
closesodoo/odoo#136252
Signed-off-by: de Wouters de Bouchout Jean-Benoît (jbw) <jbw@odoo.com>
This commit message cleans up the demo data.
First of all, it's good to have a good organization model, and secondly,
it's important for the demonstration of the org chart view
(that will be deployed in 17).
In particular, here we:
-create a department hierarchy, and assign colors to each department
-add the manager to each department
task-3510243
closesodoo/odoo#135967
Related: odoo/enterprise#48310
Signed-off-by: Sofie Gvaladze (sgv) <sgv@odoo.com>
Name can be edited more frequently than VAT, and we should
have a dedicated method to check whether it can be edited
or not.
closesodoo/odoo#118428
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
at checkout use the invoice address as billing address instead of
main address if the invoice one is defined. Add the functionality to
add new billings addresses at checkout.
task-3258835
Part-of: odoo/odoo#118428
Postgres 15.0 has started enforcing a [long-standing
recommendation][secure-schema] of the `public` schema not being
`CREATE`-granted to every user, as in users which are neither
administrators nor owners of the database can not create DDL objects
(tables, views, ...) in the schema.
As Odoo [recommends using a non-admin non-owner user][configuring]
this would be the normal deployment mode of a production Odoo system,
following which Odoo would be unable to initialize the database and
install new modules.
Although the official recommendation is to create a schema with the
same name as and owned by the low-access user, the threat model does
not really affect Odoo as it always connects to the database with the
same user (or close enough). Odoo's behaviour is much closer to usage
pattern 5.9.6 ¶ 3:
> the database has a single user or a few mutually-trusting users
It also would not really work, as one could create and possibly
initialize the database with one user (e.g. using the command line),
then per [guide][configuration] run Odoo using a different user, which
would not be able to see the schema created for the first user and
thus would have to perform their own setup in an unrelated
schema (which it would have to create first). Resulting in an unused
full installation (with the modules and configuration the original
creator wanted) and a separate empty installation at best.
Thus implement the setup for 5.9.6 ¶ 3:
> grant privileges to create in the public schema
[configuring]: https://www.odoo.com/documentation/16.0/administration/install/deploy.html#configuring-odoo
[secure-schema]: https://www.postgresql.org/docs/15/ddl-schemas.html#DDL-SCHEMAS-PATTERNSclosesodoo/odoo#116172
Signed-off-by: Xavier Morel (xmo) <xmo@odoo.com>
Motivations:
* `sequence` is not super intuitive for new devs
* It makes "useless" noise in data files
* It is redundant when what we want to see in the file is the same as
what we want to see on the user screen.
Do you understand anything related to sequences in here?
https://github.com/odoo/odoo/blob/15.0/addons/l10n_lu/data/account_tax_report_line.xml
Explicit is not always better than implicit.
* It is not implicit like using `id` it is natural and visual and saves
a lot of chore for adding and maintaining sequences.
Implementation
* It is optional, with the option set on root xml tags
Part-of: odoo/odoo#85750
before this commit, on printing the report if there is an
exception happens on rendering the header and footer,
traceback is shown to user without skipping the exception
AttributeError: 'sale.order.template' object has no
attribute '_message_log'
the exception come from _get_form_fields_mapping function,
format_date function is called by passing tz but the function
doesnt have this argument.
after this commit, if exception happens on rendering the
header or footer, a message will be added in the log and
report will be printed without traceback
closesodoo/odoo#137812
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
Steps to reproduce the bug:
- Create a storable product “P1”:
- set sales price: 10
- Go to attributes & variants tab:
- Color: red & blue
- Size: S
- Go to Red attribute and add extra price: 5
- Go to the product variant “P1 red S”
- Print label:
- ZPL with price
Problem:
The product.template price is printed instead of the product variant
because we use “list_price” instead of “lst_price”
opw-3537277
closesodoo/odoo#137786
X-original-commit: ea632652be5d4b1cbdf19f68c1a4db1ffc3cfb99
Signed-off-by: Quentin Wolfs (quwo) <quwo@odoo.com>
Signed-off-by: Djamel Touati (otd) <otd@odoo.com>
Before this commit:
-While reading chatter notifications in the chat window, SMS and email icons are
not accessible to click due to action list overlap.
-While reading a reply on any message or attachment in chat widow,
the attachment link is not accessible to click due to action list overlap.
After this commit:
-When SMS and email icons are visible, time and that icon will display to the
following line so user can click on it easily.
-Attachment links will display to the following line of mentioned so user can click
on it easily.
Task-2713371
closesodoo/odoo#137734
X-original-commit: 3ae87df6e39cb8ef279ef62f194edf14858d2edf
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
This commit:
- Changes the order of bills and how the values are displayed in the
pos_bill_view.
- Adds a 500 bill for India localisation.
- Changes the tree view of pos bill to be editable and set the bill
to all the pos_configs if no config is linked to the bill.
- To prevent inconsitancy, 'pos_default_bill_ids' field is removed from
the res.config.settings view since if no pos config is linked to the bill, the
bill is accessible to all the pos configs.
- Removes the amount in the open session button in opening cash control popup.
Task-3537655
closesodoo/odoo#137521
Signed-off-by: Joseph Caburnay (jcb) <jcb@odoo.com>
The goal of this commit is to resolve:
=====================================
1. When you edit a Char or Boolean field with an onChange that returns
the value before editing, you must display the value of the onChange.
2. In the model, html fields are always Markup fields. But when we evaluate
a modifier containing an html field, we use the server value (a string or false).
3. When we edit a field and its onChange returns an server error, we want to
revert its value to the valuea before edition.
Solution:
=========
1. Always render when applying a change, even if the value does not change,
because onChange returns the initial value. To do this, we'll apply
the changes to record.data, then apply the changes from onChange.
The value will therefore change, which will cause all the components
observing the value in record.data to render.
2. When we update an html field, its value will always be markup and
we'll store it as a string in _textValue so that we can evaluate the
modifiers without the markup. For changes coming from the onChange, we
will store the value in _textValue and apply markup on it for record.data.
3. When an onChange returns an server error, we will apply the changes and then
revert them directly. This will have the effect of triggering a rendering
on all the components observing to the record.data corresponding to
the changes and so displaying the values before editing.
How to reproduce:
=================
Case 1:
------
- Go to a form view containing a boolean field with an onChange
- Check the boolean field
- The onChange returns with the value false
Before this commit:
The boolean field is always checked
After this commit:
The boolean field is no longer checked
Case 2:
------
- Go to a form view containing an html field and an field "x" with
invisible ="not html_field" and an onChange
- Edit the field "x"
- The onChange returns the value false for "html_field".
Before this commit:
The field "x" is always displayed
After this commit
The field "x" is no longer displayed
Case 3:
------
- Go to a form view containing a char field with an onChange
- Edit the field
- onChange returns a server error
Before this commit:
The field is marked as invalid and contains the value after editing.
After this commit:
The field contains the pre-edit value
closesodoo/odoo#136924
Related: odoo/enterprise#48515
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
before this commit, on duplicating a combo product, the
combo lines are not copied to new records
after this commit, the combo lines will get copied
during the duplicate
closesodoo/odoo#135577
Signed-off-by: Vlad Stroia (vlst) <vlst@odoo.com>
Previously, the order, review and pay buttons were in btn-primary at the
same time, or not at the right time.
Changes have been made to the current behavior:
- If there is no order line, both buttons are gray
- if something needs to be sent, the Command button takes priority
- if nothing is to be sent, the Payment button takes priority
A fix has also been made to the number of items to be sent to the
kitchen, both for the category list and for the number of products.
The number of products per category was erroneous, so the number of
products has been changed to an absolute value.
closesodoo/odoo#134679
Signed-off-by: Joseph Caburnay (jcb) <jcb@odoo.com>
Replace the magic js logic applying the discount of the first line to all
the lines by a dedicated wizard, providing three kind of discounts:
* Discount on each sale order lines
* Discount on the global order amount
* Fixed discount amount
task-3369680
closesodoo/odoo#129087
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
Co-authored-by: Victor Feyens <vfe@odoo.com>
In this PR we'll add the following UX improvements :
- Drop the useless responsible_id field from hr_job
- Include applicant attachments in the meeting when scheduling an interview
- Several tooltip and default value changes
task-3380150
closesodoo/odoo#125932
Related: odoo/upgrade#4808
Signed-off-by: Sofie Gvaladze (sgv) <sgv@odoo.com>
Before this commit:
- The existing of two dates behaving as and end date for project_task
(date_deadline and planned_date_end) is confusing.
In this commit:
- The main goal is to simplify the interface by having one field/widget
that acts as both the deadline and the end date, instead of having two separate fields.
So we removed planned_date_end (changes can be seen in the enterprise related pr (link at
the end) and changed the date_deadline type from date to datetime in project_task and
report_project_task_user
Related PRs:
Enterprise: odoo/enterprise#40866
task-3084978
closesodoo/odoo#120953
Related: odoo/upgrade#4654
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
This commit adds the feature to select a date in the future
in order to see future allocations, would it be for accrual plans
granting new allocated days, lost days due to expired allocations
or allocations that are not yet available to the employee.
The date selector only appear when the employee has accrual allocation,
in which case the feature is more relevant.
This feature comes with a major refactoring of hr_holidays
methods to handle some edge cases in the management of leaves.
The refactoring also includes the removal of the 'draft' and 'cancel'
state in allocations.
This commit also removes unused imports and implements some linting fixes.
task-2675380
closesodoo/odoo#108148
Related: odoo/upgrade#4238
Related: odoo/enterprise#35157
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
__Current behavior before commit:__
When `context_today()` is in a domain, UTC is used. However this is not
consistent with [the legacy method](https://github.com/odoo/odoo/blob/81183495a07eb5928b29ae56f3f86671234d602c/addons/web/static/src/legacy/js/core/py_utils.js#L232) used before OWL migration.
This has the consequence that filters with this method in their domain
will not behave correctly and use UTC date instead of the actual date
of the user.
__Description of the fix:__
Switch the UTC methods calls to regular ones.
__To reproduce:__
(Reproducible only in Odoo 16, since the old method is still used in 15)
1. Change computer date and timezone so that UTC date is not the same as
your date (e.g. if timezone is CEST, set the hour to 1am)
1. On any record, schedule an activity with the due date to today.
1. In the Activities notifications panel, click on **1 Today**
1. The page display nothing because it will filter by the previous day.
opw-3423316
closesodoo/odoo#137798
X-original-commit: e41dcde8d66c74c8ad114c76ea6ed9c607e04455
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
**Before this commit**
1. When passing to the next step the new tour tip target stays
the same element (could happen in certain conditions through
owl's dom patching), the tour tip pointer is positionned at the
[0, 0] bottom-left coordinates instead of near its target.
2. Under certain conditions, when the tour tip pointer's content
changes, the dimensions of the opened tip is not properly stored
in the instance of the tour pointer. This lead to a weird looking
tip when you hover on it, triggering its opening state.
**After this commit**
The above issues are fixed.
closesodoo/odoo#137792
Taskid: 3502704
X-original-commit: f169130a31646dabb201cd4e1e54bbd0754b3fdf
Signed-off-by: Michaël Mattiello (mcm) <mcm@odoo.com>
Signed-off-by: Bruno Boi (boi) <boi@odoo.com>
Exact steps (or video) to reproduce the issue (on runbot):
1. Go to Website > Shop > Open a product with specifications table (Customizable Desk).
2. Open Editor > Set Specification to None > Compare button is removed from Product page
Fix:
display the compare button under add to cart if spec disabled
opw-3329219
closesodoo/odoo#137775
X-original-commit: 95e0be822fab3596b2baa8b19e0a9c1728096047
Signed-off-by: Walid Hanniche (waha) <waha@odoo.com>
The aim of this commit is to allow import of OIOUBL einvoice.
Documentation source: https://oioubl.info/classes/en/index.html
The test xml files are those provided in the OIOUBL documentation.
The testing xml files are those provided by the Danish administration
with the documentation.
You can download the documentation here: https://oioubl.info/documents/en/allpdf.zip
The xml are in the folder "Eksempelfiler".
closesodoo/odoo#137758
Task-id: 3420748
X-original-commit: b6a060b60e6755af4e6029eb7b23d417a3c4a774
Signed-off-by: Laurent Smet (las) <las@odoo.com>
Signed-off-by: Brice Bartoletti (bib) <bib@odoo.com>
I introduced a wrong variable name in commit 70f252ed99c6c9596cd909bede8ef21cdd0df718
I believed `get_resource_path` was wrongly named and retrieved a file
but `etree.parse` is actually retrieving the file by itself.
Task-id: 3420748
X-original-commit: 3954a517eab1cef6154414fa40f8c730071b987a
Part-of: odoo/odoo#137758
During the work done on OIOUBL einvoice import, we saw that the
`Percent` node is always located below a `TaxCategory` node in UBL 2.0.
Task-id: 3420748
X-original-commit: 71d8bf93be472bdcf232e25e42f818e2df89cf8b
Part-of: odoo/odoo#137758
Since commit[1] Serial number sequence rule takes priority over already
existing Serial numbers
Bug:
when disabling default Serial number sequence rule a validation error
is thrown since lot name is now empty
Fix:
fall back on the previous behaviour (get next SerialNumber) if sequence
is not set
(also added a clearer user error if neither is set)
note also updated the .pot file
opw-3514794
[1]:https://github.com/odoo/odoo/pull/134187closesodoo/odoo#137756
X-original-commit: 68d670a27be7baaaf53b0cf491234f8e0453d7f2
Signed-off-by: William Henrotin (whe) <whe@odoo.com>
Signed-off-by: Walid Hanniche (waha) <waha@odoo.com>
In order to allow in the PoS to put a partner, but
still do a simplified invoice, we added this field
l10n_es_is_simplified so you can force a ticket
instead of having to download the invoice.
This could also be used to only do the check for
a NIF when the invoice is not simplified.
Related to task 3413182
Part-of: odoo/odoo#136164
In this commit, show action helper when we had not data show in graph view.
same as we have in pivot view.
- add domain for cancelled records to not showing in reporting.
task-3500508
closesodoo/odoo#137735
X-original-commit: a50e73a2ae04fac9fcfea77cbab27e0b5de66fcc
Related: odoo/enterprise#48473
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>