Before this commit
==================
all the settings of Indian integration like E-waybill,and e-invoice were
having different setting blocks.
After this commit
=================
all the Indian integration settings will be shown in one setting block.
closesodoo/odoo#111175
Related: odoo/enterprise#36382
Signed-off-by: Nicolas Viseur (vin) <vin@odoo.com>
Before this PR, all this localisation was written in Norwegian, but all the localisation have to be written in english and then translated back in the native language. This PR correct that.
closesodoo/odoo#110986
Task-id: 3149392
Related: odoo/enterprise#36280
Signed-off-by: Nicolas Viseur (vin) <vin@odoo.com>
Warnings show up when using a recent pylint. It's only a fraction of
what e.g. pycharm flags as "local variable might be referenced before
assignment" but seems a good idea to fix anyway in prevision of
possibly eventually updating the reference pylint.
closesodoo/odoo#107968
Signed-off-by: Xavier Morel (xmo) <xmo@odoo.com>
Doesn't seem like it could hurt, and should only make CORB more
reliable by avoiding sniffing. Worst case scenario requires fixing a
few mimetypes, but aside from CORB it looks like modern (non-IE)
browsers only try to guess document mimetypes in very limited
contexts.
closesodoo/odoo#107957
Signed-off-by: Xavier Morel (xmo) <xmo@odoo.com>
Since [1], a race condition would be faced as the dict order is not
guaranteed, sometimes failing because:
```
AssertionError: Lists differ: ['/demo', '/admin'] != ['/admin', '/demo']
```
[1]: https://github.com/odoo/odoo/commit/a87b4142dd4a2c05e3e1885b2c54f5e0d3c7ac47
runbot-15727
closesodoo/odoo#111417
X-original-commit: 3e9a1dd76ce5172c4797bc92f0351e107589c3a5
Signed-off-by: Christophe Monniez (moc) <moc@odoo.com>
Previously, when a database had a large amount of partners and they were
loading in the background, the PoS became progressively more slugglish
to the point of being unusable after ~10.000 partners were loaded and
for as long as all partners were not loaded. This was caused by the
client side database building a large string of text containing all
partner information to use for local searching of the partners. Any time
a batch of partner was loaded, this string would be reconstructed from
scratch, and this string would be around ~1MB by the time 10k partners
were loaded, causing a significant slowdown after every partner loading
request came back.
This commit fixes that by chunking the string by batch of 1000 partners
and only updating the string for the batches of the partners that were
just loaded, instead of updating the entire string, which brings brings
the performance of the PoS back into usable territory.
There were also some reactivity-related issues which have been fixed in
owl separately.
closesodoo/odoo#111388
X-original-commit: 4974782c61d7e283875da6ea40149072b1a36cdc
Signed-off-by: Samuel Degueldre <sad@odoo.com>
Add the field disable_shrinking in the report.paperformat form view. This
field has been added recently (see odoo/odoo@9e4c8d61ea / odoo/odoo#68188)
but only in the model.
In this commit we add it in view so that it is controllable.
Followup of task-2483393
closesodoo/odoo#111393
X-original-commit: 6fdf517ea219a021521e3fbdad540d21b5e3ba76
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
An attachment has complex access rights. If there is no res_model/res_id, the access rights are admin (not exactly but let's say that).
When an EDI like Facturx/E-FFF generates an attachment not linked to any model, you don't have access to it except if you are admin.
However, here we have a security issue since everyone is able to write any 'id' on the 'attachment_id' field.
If you do that using Facturx, knowing this EDI will embed its attachment inside the invoice PDF report in sudo mode, you have now a way to extract any attachment from the database including the ones you shouldn't have access to.
Furthermore, a different api introduced by OWL makes the form view of account.edi.document popping from the one2many inside the invoice form.
Instead of "options={'no_open': '1'}", the new api is now to put directly "no_open='1'" on the root node.
If you combine both issues above, you currently have a way to extract any 'attachment_id' from the database and odoo is kind enough to give you the form view to do it.
closesodoo/odoo#111210
Solution: "account.edi.document.attachment_id" is now accessible to the admin only.
X-original-commit: 44a4cdb3944a4b722dcfbca5e2947a4372b8501d
Signed-off-by: Olivier Colson (oco) <oco@odoo.com>
Since [1] when the translations becames stored as JSONB, the
translations of website-specific views were lost when adding a new
language.
[2] did fix a similar problem when installing an App, but did not
solve this.
This commit makes sure to only change the requested translations
without impacting the existing ones when a language is added.
Steps to reproduce:
- Add French language to the website
- Add the number snippet on the homepage
- Translate "Useful options" -> "Options utiles"
- Go to setting -> Languages -> Activate any language (not even on a
website)
=> French translation disappeared.
[1]: https://github.com/odoo/odoo/commit/ef00294e7189359c47638c4a71626f1937395edb
[2]: https://github.com/odoo/odoo/commit/91a9c870eede96040ac49d2375fe0e18342342e1
opw-3120079
closesodoo/odoo#111378
X-original-commit: 52fd577de8e270f84e8ca23c9350f2fb3ab5a7d8
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
The placeholder on the partner name was working for a partner that is
an individual but not company. This will fix that.
Task id #3138441closesodoo/odoo#111324
X-original-commit: 00256249f880b1b6de3fc768beb0a2bc56191ada
Related: odoo/enterprise#36452
Signed-off-by: Quentin De Paoli <qdp@odoo.com>
Signed-off-by: Nicolas Viseur (vin) <vin@odoo.com>
Improve the partner view by reorganising the city/state/zip row, making
the order of the fields dependant of the country address_format.
This is done to ease the use of these view for our users by displaying
a format they are already used to.
Task id #3138441
X-original-commit: c646f7bb80cb7f9af689082752608b554f1a648b
Part-of: odoo/odoo#111324
The accounting date was only visible in list view for misc entries.
For fiduciaries, we would like to have it also visible in these views.
As there is no simple way to only have the column visible when quick
edit mode is enabled, we compromise by having it always available, but
with optional=hide
Task id #3138441
X-original-commit: c208a91e926ec2a98bfbaee068284222fbc0ff05
Part-of: odoo/odoo#111324
A common use case for fiduciary is to use the available tax edition tool
on the tax total of an invoice to round the total of an invoice.
This is not supported by ubl, which will re-compute the taxes upon import
and thus lose that manual rounding.
This change aims to correct that, by post-processing the invoice after
creation in order to correct the tax amount to the one in the XML if the
different isn't superior to 0.05.
Task id #3138441
X-original-commit: 5bc87804bf5bba49ffd939c844439b87e08b499e
Part-of: odoo/odoo#111324
This was until now blocked by the_unlink_forbid_parts_of_chain ondelete.
It was still possible to do it manually by removing the
sequence name before deleting the invoice, and will now
be possible without that extra step.
Task id #3138441
X-original-commit: 6112f4f59aeb5dc5a3b698edd861b19f25da7017
Part-of: odoo/odoo#111324
To that end, we will now do the VIES and regular VAT
check separately.
The VAT check stays as a constrains, while the VIES
check will now be done in an onchange and simply
display a warning if it fails.
We will also now allow VAT with a single character to
ignore the checks. This will allow users to better
distinguish partners for which they didn't enter VAT
against partners which are not subject to VAT by setting
the later's VAT to '/' or any other characters.
Task id #3138441
X-original-commit: eff3b140cc88dd48b77948a577f195f2e1910fd8
Part-of: odoo/odoo#111324
Since the migration from bootsrap 4 to bootstrap 5 and more precisely
since [this commit], the tooltips on too-long titles are not displayed
anymore in the mail editor.
Steps to reproduce the bug:
- Go to the email marketing application
- Create a new mail (other than plain text)
- Go to the design tab of the editor
- Put your mouse over the title "Secondary Butt..."
=> The tooltip to display the entire title does not appear. This commit
allows to correct this bug and to display the tooltip as it was the case
before the change of version of bootstrap.
[this commit]: https://github.com/odoo/odoo/commit/23facbfb76c6e8b23137cddda5f5113273555498
task-2777738
closesodoo/odoo#111032
X-original-commit: 1e5c945f462e4a9903f64fd59c89319f9f2589c1
Signed-off-by: Romain Derie (rde) <rde@odoo.com>
All the localisation should be written in english and then translated to the native language of the country. In this case, the Guatemala localisation was written is Spanish, this PR translate the module in english and add the corresponding PO file in spanish.
closesodoo/odoo#110661
Task-id: 3145295
Signed-off-by: Nicolas Viseur (vin) <vin@odoo.com>
- Ignore anchors, those are not sent to the server anyway, no way to
compare even if we wanted to
- Ensure query string (qs) are the same to be considered equals
On top of that, it also fixes the case when the user inserted an
absolute URL instead of a relative one, it will now match.
task-3096367
opw-3091427
closesodoo/odoo#107782
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
- `clean_url` method was wrongly flag as `api.model`
- the `unslug_url` was not called for the URL comparison in the dropdown
case, meaning that `/shop/prod-1` would not match `/shop/product-1` as
it should (and as it does for regular non dropdown menu)
- the `active` class was actually never working for the dropdown case,
as the class was added on the wrong element (`li` instead of `a`)
The code was hard to read (mainly because huge python conditions in XML)
and kinda redundant, going through an util method should be clearer and
help reading the template XML.
task-3096367
opw-3091427
Part-of: odoo/odoo#107782
Due to the end part of the regex `(?=$|/)`, it will not find and thus
not unslug string if they end up with a query string or and anchor
except if there is a trailing slash before.
First, it's unlikely that there will be a trailing slash as it's not
common and on top of that, Odoo try to enforce non trailing slash in
URL.
Second, it's not that hard to makes those cases work.
Before this commit, the following string would "match" and be unslug:
- /blog-1
- /blog-1/
- /blog-1/register
- /blog-1/?qs=2
- /blog-1/#anchor
But those would not:
- /blog-1?qs=2
- /blog-1#anchor
Part-of: odoo/odoo#107782
Steps to reproduce the bug:
- Go to the warehouse and enable the “2 steps” in the
“Outgoing Shipments”
- Create a So:
- add a storable product
- 2 pickings are created (pick and a delivery)
- Go to pos and open a session:
- Select the created quotation
- Click on payment
- select “Cash”
- Click on Validate
Problem:
The delivery order linked to the SO is correctly cancelled, but the
pick order remains in the “ready” state
opw-3117002
closesodoo/odoo#111270
X-original-commit: 7f7668db9d015464c629bb4d617199993dbfcdd8
Signed-off-by: Trinh Jacky (trj) <trj@odoo.com>
Signed-off-by: Djamel Touati (otd) <otd@odoo.com>
When trying to duplicate a service in sale > products with "Subcontract
Service" enabled, a error message will appear. This is due to the fact
that when you are duplicating a product, every vendor in the purchase
tab are not carried over to the copy. To fix this easily, we need to
disable the "Subcontract Service" on duplicates entry during their
creations.
opw-3115827
closesodoo/odoo#111221
X-original-commit: 731e1ec09839129f8d7ab3fa71257974e68263ec
Signed-off-by: William Henrotin (whe) <whe@odoo.com>
Before this PR, all this localisation was written in spanish, but all the localisation have to be written in english and then translated back in the native language. This PR correct that.
closesodoo/odoo#110938
Task-id: 3149182&
Signed-off-by: Nicolas Viseur (vin) <vin@odoo.com>
The fiscal device is refered to as the 'fiscal device' in some places,
and 'control unit' in others. This commit changes the references to the
fiscal device to always be 'fiscal device'.
This commit was accidentaly dropped when fixing a forward-port rebase
https://github.com/odoo/odoo/pull/109434, and has thus been reintroduced
in v16 in its own PR.
closesodoo/odoo#110182
X-original-commit: 9049516a0d45ae537f976622f2709e0c098a3003
Signed-off-by: Josse Colpaert <jco@odoo.com>
Signed-off-by: Daniel Kosky (dako) <dako@odoo.com>
When unlinking or writing a tax report line, the related tags that are no longer relevant were not archived.
We now archive tags if they are still used in account.move.line and display a banner
in report that let the user know there might be a problem and invite him to correct tax tags.
closesodoo/odoo#111287
Task: 3084028
X-original-commit: 8fb35df6225f8c8f7c3aa7fec56acb3bec23d25f
Related: odoo/enterprise#36432
Signed-off-by: Josse Colpaert <jco@odoo.com>
Signed-off-by: Olivier Colson (oco) <oco@odoo.com>
Signed-off-by: Claire Bretton <clbr@odoo.com>
In the forward-port to 15.0 of https://github.com/odoo/odoo/commit/b4cd54a3c9227370667913ff2e170e24539c6328 the migration folder was renamed from 5.1 to 15.0.5.1, which causes the forward-port to 16.0 to not take into account this migration.
This change renames the folder back to 5.1, such that the migration will run in 16.0 as well.
Related to task-2993087
closesodoo/odoo#111280
X-original-commit: 86343618a4d6bd7f8e30c30fefdc0f1c2c73f315
Signed-off-by: Christophe Simonis <chs@odoo.com>
Signed-off-by: Dylan Kiss (dyki) <dyki@odoo.com>
Install MX CoA
"Cash" and "Bank Suspense Account" are missing the tag
"Transferencias bancarias moneda extranjera" account is using the wrong
tag
opw-3033611
closesodoo/odoo#111273
X-original-commit: 4860a77a51f72bbb51b435766733b3c0a74c9a32
Related: odoo/enterprise#36422
Signed-off-by: Olivier Colson (oco) <oco@odoo.com>
Signed-off-by: Grazioso Andrea (agr) <agr@odoo.com>
Prior to this commit and on Firefox 109, clicking on a link while in
edit mode on the website app would trigger a traceback.
This is caused by the fact that the LinkPopover widget is contained
inside the iframe while use the ClipboardJS global defined in the top
window.
Indeed, ClipboardJS checks if the target (the button to copy the link)
is an HTMLElement. To do so, it uses the "instanceof" keyword. However,
the __proto__ (what is used for computing instanceof) of the target is
different depending on the browser.
For Chrome, the HTMLElement's __proto__ depends on which "document" it
was created. On Firefox, when attaching an element to a parent, it will
switch __proto__ to the one from the frame from which it is attached.
To fix this, we use the ClipboardJS from the element's instance window.
In any case, using instanceof when working with iframe is a bad idea,
see [1]. In this case, the fix is made because ClipboardJS is an
external library.
Steps to reproduce:
- Download Firefox 109+
- Go on Website and switch to edit mode
- Click on a Link : A traceback appears.
[1]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/instanceof#instanceof_and_multiple_realmsclosesodoo/odoo#111266
X-original-commit: 732848f2b52bea4ebae18cb5adedf581d5112aa6
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
Signed-off-by: Arthur Detroux (ard) <ard@odoo.com>
Checking company_id=False on records having a required company is useless and leads to more complex queries.
closesodoo/odoo#111197
Signed-off-by: Quentin De Paoli <qdp@odoo.com>
Update of taxes could create name collision due to uniqueness of
(name, company, scope, type) on taxes.
We add "[old]" before the tax name to avoid this problem.
closes odoo/odoo#111124
Related: #108571
X-original-commit: e50be0ed9d8ae32f85380b9239de7f3c93d71a93
Signed-off-by: Olivier Colson (oco) <oco@odoo.com>
Signed-off-by: Claire Bretton <clbr@odoo.com>
Before this PR, all this localisation was written in spanish, but all the localisation have to be written in english and then translated back in the native language. This PR correct that.
closesodoo/odoo#109147
Task-id: 3119934
Signed-off-by: Laurent Smet <las@odoo.com>
Before this PR, all this localisation was written in Danish, but all the localisation have to be written in english and then translated back in the native language. This PR correct that.
closesodoo/odoo#111044
Task-id: 3151027
Related: odoo/enterprise#36310
Signed-off-by: Nicolas Viseur (vin) <vin@odoo.com>
when bill to is registered person but ship to is unregistered person then we need to set this
X-original-commit: c53ff49428df2ae02183f7d0eb2c3fbf7f2d108f
Part-of: odoo/odoo#111248
The previous commit solved the issues for the Belgian, ... case, but not
for l10n_latam_invoice_document.
We saw two extra problems we solved:
- As the name is readonly you can not even store the new name easily, so
we needed a force_save on that field.
- As the _compute_name is inherited in this module as well, there is a
logic that recomputes the name when the document type is changed and the
invoice is in draft to recompute that initial value.
However, when you confirm and the date gets set, that logic
is also triggered, while we do not want to recompute but keep
our old document number.
closesodoo/odoo#111294
X-original-commit: 7edee80545daf29b3a46947838a23e1f4458f12d
Related: odoo/enterprise#36434
Signed-off-by: William André (wan) <wan@odoo.com>
Before:
- Create a new sales journal
- Create a new first invoice
- Do not put an invoice date yet
- Change the name from 2023/000001 to e.g. 2023/000010
- Confirm the invoice
- The name will change back to 2023/000001 (which is not the wanted behaviour)
After:
We avoid the change back by adding a condition in the _compute_name, which
is triggered by the invoice_date being set while confirming.
X-original-commit: e31c5767c894a92d22fa8201bc1ccf34b052a336
Part-of: odoo/odoo#111294
This commit adds an attribute in kanban and list archs that
fixes performance issues.
Some tables are very huge and depending of the searched domain,
the search_count made in web_search_read takes much more time
than the search_read. For 10M records, the search_count could take
more than 10x the time of search.
This commit allows to set the count_limit in the arch to override
the hardcoded 10k value.
closesodoo/odoo#111284
X-original-commit: 699215ec9a71b8c9b6a53fe96e924a400d216729
Related: odoo/enterprise#36431
Signed-off-by: Géry Debongnie <ged@odoo.com>
Co-authored-by: Aaron Bohy <aab@odoo.com>
The aim of this commit is to fix an issue where the settings fields for the Indonesian localization were visible in all companies of a database.
Context:
In a multi-company environment, a company may have its fiscal country set to Indonesia and have the Indonesian localization activated, but this should only affect the options shown in the accounting settings for that specific company.
Previous to this commit:
When a user activates the Indonesian localization, the settings fields for the localization would be visible in the accounting settings for all companies of the database.
After this commit:
The settings fields for the Indonesian localization will now only be visible in the accounting settings for the specific companies located in Indonesia.
closesodoo/odoo#111285
Task-id: 2854025
X-original-commit: 045e18a624e9261b8650c71cc9999126320648ff
Signed-off-by: Brice Bartoletti (bib) <bib@odoo.com>
Before this commit, when the user wants to edit the parent task and
clicks on Search more button, the search view has no project by default
however, the default project to display in the search view could be the
one set on the task.
This commit adds a default project in the search view and this project
will be the one set on the task in which the user wants to set a parent
task.
closesodoo/odoo#111125
X-original-commit: 8c3a4e7dff719b8f47ed289aabb4405a401655a4
Related: odoo/enterprise#36348
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
Since odoo#106015, the "Project" field is missing from the list view
opened when clicking on "Add a line" in the "Sub-tasks" or "Blocked By"
tabs in the task form view.
This commit readds this field.
X-original-commit: 925a57a41c335f76a0f2c354b3bb2999e0d970bf
Part-of: odoo/odoo#111125
Before this commit, the default group by on task list view in Field
Service app is stage as it is the case in Project app, this behavior is
not wanted, the list view in Field Service app should have no group by
by default. Also, the default group by in My tasks should be personal
stages and no default group by should be in the list view of All Tasks
menu. Finally, the parent task has been removed in the main list view
instead of displaying in debug mode.
This commit fixes the list view in Field Service to avoid having any group
by by default and also changes the default group by `My Tasks` and `All
tasks` menu. It also adds the parent task field in the main list view
of task and that field will be displayed if the "Sub-tasks" feature and
the debug mode is enabled.
X-original-commit: e8aa2177d5640e9c366fa685651de1b85416705c
Part-of: odoo/odoo#111125
This is a step closer to a goal of avoiding dependence on asynchronous
modules. Starting from this commit, new tour definition should be
registered to `registry.category("web_tour.tours")` registry.
So, instead of the following:
```js
import tour from "web_tour.tour";
tour.register(name, options, steps);
```
We now do:
```js
import { registry } from "@web/core/registry";
registry.category("web_tour.tours").add(name, optionsWithSteps);
```
Notice the `options` and `steps` params are merged when registering
the tour definition. It should look something like so:
```js
registry.category("web_tour.tours").add("account_tour", {
test: true,
steps: [ ... ],
});
```
And if the `TourManager` instance is needed, one can get it from the
registry like so `registry.get("tourManager")`. Note however that
this instance is only available when the `TourManager` has been
instantiated -- so it's not available at top level of the module.
closesodoo/odoo#111103
Related: odoo/enterprise#36335
Signed-off-by: Géry Debongnie <ged@odoo.com>
To reproduce the issue:
1. Install [Accounting] on Apps
2. On [Settings],
- [Users & Companies]>[Companies]: add a company with country Belgium
- Set the company to the Belgian one
- add French, set the language to it
- [General Settings] - check the [Companies] section
Desired behavior: Correction of VAT label
Impacted versions: 14.0 up to master
opw-3104416
closesodoo/odoo#111243
X-original-commit: f740cbeed106b5e04538128c861151039751ac1d
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
Signed-off-by: Lee, Hansun (hale) <hale@odoo.com>
With the new 16.0 feature that open any form in edit mode, the html
editor was trying to connect in collaboration each time a record was
opened in a form view that has a collaborative html field.
The peer to peer connection could trigger a lot of rpc because of it's
communication through the bus.
This commit reduces the number of rpc by only trying to connect to
the collaboration network when the user focus the html editor.
task-3151577
closesodoo/odoo#111247
X-original-commit: 9d7aecec811699199e270a5096f00d5cb6f0b15d
Signed-off-by: Antoine Guenet (age) <age@odoo.com>
Co-authored-by: Nicolas Bayet <nby@odoo.com>
Co-authored-by: Antoine Guenet <age@odoo.com>
RATIONALE
Remove _onchange_template_id / defaults usage for composer fields. It
lacks control and make value computation hard to understand and predict.
SPECIFICATIONS
Remove _onchange_template_id / defaults usage for composer fields. It
lacks control and make value computation hard to understand and predict.
Split _onchange_template_id + default_get + get_record_data usage into editable
computed stored fields. Each field should have its own method with its triggers
(template, composition mode, ...).
OTHER CHANGES
Improve 'message_notify' to behave like 'message_post' with attachments.
Add some parameters to the notification process to lessen a bit context
usage.
Improve wording of recently added features.
Improve test coverage of recently modified features.
Cleanup hr_recruitment_survey field naming and file organization, done when
fixing a bug not really related to this branch.
Fixup mail template preview wizard, some rare bugs when previewing notably
attachments.
LINKS
This PR is build on previously merged content that originated form this PR.
See notably odoo/odoo#99482 / Task-2710804 (Mail: Clean MailThread API).
Task-3093257 (Mail: The Composer Update)
Task-2088884 (Mail: Use editable computed stored fields in compose
Prepares Task-3149286 (Account: Cleanup account.invoice.send wizard)
closesodoo/odoo#107356
Related: odoo/upgrade#4243
Related: odoo/enterprise#36387
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
Followup of odoo/odoo#95623 (introduce scheduled message notification) as well
as odoo/odoo#99482 (support scheduled datetime from template to composer in
both comment and mailing modes).
Task-3093257 (Mail: The Composer Update)
Part-of: odoo/odoo#107356
It is still using some outdated classes for margin. Layout was a bit
broken, especially the "Preview as PDF" helper-like line.
Task-3093257 (Mail: The Composer Update)
Task-3149286 (Account: Cleanup account.invoice.send wizard)
Part-of: odoo/odoo#107356
Due to new composer, it is a bit less necessary to create them on the fly
randomly. Some quick code cleaning is performed to better understand code
and variables. Notably 'default_get' override was a bit messy and should
not return unwanted values.
Task-3093257 (Mail: The Composer Update)
Task-3149286 (Account: Cleanup account.invoice.send wizard)
Part-of: odoo/odoo#107356