Open the link dialog from the wysiwyg with the label input.
Task-2704538
closesodoo/odoo#83454
X-original-commit: f7a0c321d94f84ed7daf4f6abff0740ad81024bb
Signed-off-by: David Monjoie (dmo) <dmo@odoo.com>
Steps to reproduce:
- install ecommerce - sales
- sales > settings > enable coupons/promotion program
- create a promotion program that applies on the first n orders
- make orders with the promo code applied until order no. n-1
- order no. n will fail when you add the promo code without giving an
error message
Bug:
The currently applied promotion program will not be applied if this is
the last order allowed in the program
Fix:
Include currently applied promotion program if it was the last order
allowed in it
opw-2737423
closesodoo/odoo#84031
X-original-commit: c397ed01019fc891d7b6e620c66f06deb2a13c69
Signed-off-by: Romain Derie (rde) <rde@odoo.com>
When combining the context for an RPC, the
additional context is being added before the raw
context.
Because of this, a use case such as:
- A o2m field with a context {'field': 'a'}
with a tree editable view below it
- That view defines controls to create lines,
which would change the context key 'field' to
another value.
=> The field context key would take precedence on
the creates key, making it impossible to override
that key in specific circumstances.
closesodoo/odoo#83996
Signed-off-by: Aaron Bohy (aab) <aab@odoo.com>
Current behavior :
"Learn More" link redirects to 404 page
Steps :
- Go to Apps
- Search for Invoicing
- Click on "LEARN MORE"
OPW-2743304
closesodoo/odoo#84030
X-original-commit: 8d6fbe78cc820579f978d883050027eafbcbd259
Signed-off-by: Grazioso Andrea (agr) <agr@odoo.com>
Signed-off-by: Claude Thibault (thcl) <thcl@odoo.com>
Step to reproduce:
- Create a website form with its action set to 'create a task'
- Set a project for the task to be created in
- Submit the form while logged in as a portal user
Current Behaviour:
- Task is created but the data from fields is not take into account
This lead to the task not being linked to the project and ending as 'Private'
- Due to the changes of sudo in V15, authorized fields are not fetched
and thus cannot be set properly.
Behaviour after PR:
- The data is fetch via the SUPERUSER instead of sudo to ensure correct data
- The fields are correctly set and the task is created
in the corresponding project.
opw-2743065
closesodoo/odoo#84020
X-original-commit: de03ee2198e039e14d0852d2346cb8aaf3885b5b
Signed-off-by: Romain Derie (rde) <rde@odoo.com>
Signed-off-by: Damhaut Florian (flda) <flda@odoo.com>
Before this commit,
When editing a mass mailing in "wide" mode, the emoji widget
is outside of the subject field, which is not optimum for
several reasons like:
- It makes it harder to understand what it will do
- It is hidden under the tour bubble
After this commit,
Like in "not-wide" mode, emoji widget is now inside the
subject field.
task- 2730477
closesodoo/odoo#83995
X-original-commit: 9195a28dc19b3f0f29aa103e3a1fd62ee32216bd
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
Step to reproduce:
Change the validation type of the hr.leave.type with id 1 (hlt1) to no_validation
Create a new time off request with a time off type different from hlt1
Current Behaviour:
Time off state is 'draft'
Behaviour After PR:
Default time off state is correctly computated.
opw-2713600
closesodoo/odoo#84007
X-original-commit: 5a26f3402d5760f7860897f2c64d359c7af7d14b
Signed-off-by: Kevin Baptiste <kba@odoo.com>
For this case is wrong use the company of the user, because you may in other company at this moment and the search is not
working properly.
The way to solve this is use the "env" company as use in the computed method.
closesodoo/odoo#84037
X-original-commit: ee264787841395a95162ae809928ee71fd1b7c84
Signed-off-by: William André (wan) <wan@odoo.com>
Steps :
Create a project and a task.
Share editable with Deco Addict.
Collaborators > Deco Addict > Grant Portal Access.
Users > Deco Addict : change password.
Log in with Deco Addict.
Go to the task.
Issue :
You can assign yourself to the task.
This doesn't make sens as even an internal cannot assign a portal.
Fix :
Make this button available only for base.group_user.
closesodoo/odoo#84036
Opw: 2753908
X-original-commit: d8f83379ceb1f718c7ccbed33d3cd4d8f4d37c6f
Signed-off-by: Laurent Stukkens (ltu) <ltu@odoo.com>
Strikethrough option was missing in the editor toolbar.
* Added the option in the toolbar.
* Added the keyboard shortcut (CTRL+5)
task-2754007
closesodoo/odoo#84029
X-original-commit: 9808073c22eacf9f2bcc55aa96eaec56f55597cc
Signed-off-by: Antoine Guenet <age@odoo.com>
In some cases load_new_partners returns a rejected promise
with an argument of type string, which causes a crash in
the catch which considers that it is an rpc error using
error.message.code and this is an error because error is
a string in the case of a reject on load_new_partners
opw-2679837
closesodoo/odoo#84019
X-original-commit: c1ab58324f22ec51a63e1428072eea293d6ae99d
Signed-off-by: Joseph Caburnay (jcb) <jcb@odoo.com>
Signed-off-by: Achraf <abz@odoo.com>
The aim of this commit is to:
- correct the implementation of the restaurationMoms
- add a price_include version of restauraionMoms
- make a better implementation of the energy tax
before this commit:
The implementation of the restaurationMoms is completly false.
The implementation of tax energy is quite complicated and makes
the UI display a "0 tax value".
after this commit:
2 restaurationMoms version and both are correct.
Tax energy implementation is more user-friendly and more correct
regarding information displayed by the UI.
closes odoo/odoo#84004
Task: #2748309
Pr: https://github.com/odoo/odoo/pull/83666
X-original-commit: 7d4dcf7944cf776d74d31c80f2df15c8d44e3c5c
Signed-off-by: Josse Colpaert <jco@odoo.com>
Signed-off-by: Brice Bartoletti <bib@odoo.com>
It is currently not possible to update the quantity of a product from
the inventory report
To reproduce the issue:
1. Create a storable product P
2. Update its on hand quantity to 100
3. Inventory > Reporting > Inventory Report
4. On the line for P, update to quantity to 75
Error: The quantity becomes 0 instead of 75
When setting the quantity from the inventory report, the client calls
the `write` method with the context key `inventory_report_mode` defined
and equal to `True`
This `write` leads to `_set_inventory_quantity` which triggers
`action_apply_inventory` (without disabling the context key!):
https://github.com/odoo/odoo/blob/8b155b695823dfa954464ad0d5dd07445ece2471/addons/stock/models/stock_quant.py#L150-L158
At the end of the inventory update, it resets the field
`inventory_quantity` to 0:
https://github.com/odoo/odoo/blob/8b155b695823dfa954464ad0d5dd07445ece2471/addons/stock/models/stock_quant.py#L592
To do so, the `write` method is called again and here is the issue:
https://github.com/odoo/odoo/blob/8b155b695823dfa954464ad0d5dd07445ece2471/addons/stock/models/stock_quant.py#L244-L248
Once `inventory_quantity` is updated, since `inventory_report_mode` is
still in the context and equal to `True`, `action_apply_inventory` is
called again. Then, when applying again the inventory, it will consider
the value of `inventory_quantity` (i.e., `0`) to define the new
quantity.
OPW-2737437
OPW-2746201
closesodoo/odoo#84002
X-original-commit: 6500e99cbfda44ebd1931acd657e86841ac2342a
Signed-off-by: Arnold Moyaux <arm@odoo.com>
Signed-off-by: Adrien Widart <awt@odoo.com>
If a user without Administration/Settings rights tries to share a
project in edit mode with a collaborator, an access rights error is
currently raised when creating the portal user. We should not create
any user instead, as there is a signup link sent to the partner anyway.
He can then set up his password without having to click on Reset
password, which was not user-friendly anyway.
closesodoo/odoo#84001
X-original-commit: 8de8c196a137f4ebbf67d7c7c83fee36f873f5c8
Signed-off-by: Laurent Stukkens (ltu) <ltu@odoo.com>
When creating a new invoice by giving it an invoice_line_ids list for
which the last line is a note, the tax line may be created wrongfully
without partner_id, which is totally wrong.
To reproduce :
Create a SO
Set a customer
Insert a product with tax
Insert a note
Deliver the product
Invoice the SO and confirm the invoice
The partner_id is not set on the created tax line
While the issue only arises in 15.0, it brings to light that the partner
is not in the grouping keys while it should, so it will be changed in 13.0+
opw-2750851
closesodoo/odoo#83999
X-original-commit: 2ce994d279126aa0356b86d3fa38b699e9035e54
Signed-off-by: Laurent Smet <las@odoo.com>
Signed-off-by: Nicolas Viseur <vin@odoo.com>
- Go to Email Marketing and create a new mailing
- Add Masonry snippet in mail body
- Send a test mail
The picture of the Masonry snippet is missing.
The masonry image is displayed with CSS via background-image attribute.
There are 2 causes for this issue:
1) The relative url cannot be converted to an absolute one.
This is due to the " entity used to surround the url that is not detected.
style="background-image: url("/web/image/mass_mailing.s_masonry_block_default_image_1");"
2) html_sanitize is applied to mail body, but html_sanitize doesn't allow
background-image style attribute.
opw-2735636
closesodoo/odoo#83998
X-original-commit: cdcef228aa30d7dd4081fa25a1aab4811acda3ad
Signed-off-by: Antoine Guenet <age@odoo.com>
When there are multiple projects and many tasks the compute of
project.project.doc_count may raise a `MemoryError` on access to the
projects kanban view.
This issue may appear since the addition on 642fb2e6 of docs_count field
to the kanban view `view_project_kanban`.
https://github.com/odoo/odoo/blob/136808203545eb5d7056d941f3fc250f2871f95b/addons/project/views/project_views.xml#L613
This provokes too much information to be prefetched by the ORM, in
particular the `description` fields of the tasks which may be big (e.g.
contain embedded images).
This issue was observed during upg-101057
closesodoo/odoo#83997
X-original-commit: 6c207ed1027d9b39eecd19886932b17f1a79dccd
Signed-off-by: Laurent Stukkens (ltu) <ltu@odoo.com>
Before this commit the phone fields inside forms did start in a blank
state.
After this commit the empty phone fields are pre-filled with "+" and the
country phone code.
The country is determined based on the IP address with the GeoIP
database. The phone code is obtained from `res.country` where it is
kept in cache.
task-2463563
closesodoo/odoo#78068
Signed-off-by: Romain Derie (rde) <rde@odoo.com>
Co-authored-by: Benoit Socias <bso@odoo.com>
When printer of type Epson are created for kitchen the pos model is not
passed, and so the rendering of the receipt does not working for
printers added that way.
We are now correctly passing the pos model.
OPW-2745009
closesodoo/odoo#83976
X-original-commit: 00713acce939df99016bdc71a8e9132fb564e978
Signed-off-by: Quentin Lejeune (qle) <qle@odoo.com>
In the for view of account.payment, when creating an inbound one, the partner_bank_id field was always labeled either "Customer Bank Account" or "Vendor Bank Account". This was wrong, as this field contains the bank accounts receiving the payment, so in case of an inbound operation, it's the company account. We hence add a third possible label for it in that case.
closesodoo/odoo#83974
X-original-commit: c55f2e6aa88d01bc4f26bee7c6303f53e5bb8e48
Signed-off-by: Laurent Smet <las@odoo.com>
Signed-off-by: Olivier Colson <oco@odoo.com>
Before this Commit,
While creating a custom appointment, The appointment name has 'Username'
and invitation email also has 'Username'. When a customer receives the
invitation email, The 'username' gets twice.
After this Commit,
We have removed the 'With username' part from the default email template.
Task-2713963
closesodoo/odoo#82894
Related: odoo/enterprise#23197
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
Enterprise PR - odoo/enterprise#23980
Upgrade PR - odoo/enterprise#3206
- UI improvements/changes
- Taxes
Before this commit, in case taxes were defined on expense,
the tax amount was added on top of a product price.
For example, in case product price was 100$, and tax - 15%,
then expense.total_amount would be 115$.
Now, tax amount is included in expense.total_amount. To accommodate
this change, we set following domain - ('price_include', '=', True)
on tax_ids on expense.
For the same example, expense.total_amount would be 100$, tax amount
would be 13.04$ and untaxed amount - 86.96$.
But, tax amount can be set for non-zero expenses (in case expense.product_id.standard_price !=0).
For the above example, one could set tax amount to 15$.
As a result untaxed amount will be 85$ and total amount - 1OO$.
- Journal entry
Previously, in case journal entry was reset to draft, canceled,
reversed - it changed the state of the linked expense report.
Now, actions done on accounting by accountant does not impact expense reports.
task - 2687999
closesodoo/odoo#81904
Related: odoo/upgrade#3206
Signed-off-by: Kevin Baptiste <kba@odoo.com>
Purpose
=======
"True" and "False" are not very user-friendly, especially for
non-technical people. Instead, we want to have "Yes" or "No" which have
more sens for non-technical people.
This change is done for the the custom filter and the tracking messages.
Task-2648390
closesodoo/odoo#79911
Related: odoo/enterprise#23863
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
Purpose
=======
When we group the record based on a boolean fields, we want to show
"Yes/No" instead of "True/False".
This has been done for the list view, the pivot view and the kanban
view.
Task-2648390
Part-of: odoo/odoo#79911
Purpose
=======
When the value of a tracked boolean field change, we can see in the
chatter "True -> False". It doesn't have that much sens for
non-technical people, and instead we want to use "Yes -> No".
Task-2648390
Part-of: odoo/odoo#79911
Purpose
=======
"True" and "False" are not very user-friendly, especially for
non-technical people. Instead, we want to have "Yes" or "No" for the
custom filters, when we search on a view, which have more sens for
non-technical people.
Task-2648390
Part-of: odoo/odoo#79911
Part of the overall v16 SCSS optimization/restyle (task-2704984).
task-2731819
closesodoo/odoo#82590
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Some recent changes have evidenced that the modification of the activity
type of an 'upload_file' activity was not properly covered by the tests.
This commit adds a new test for this specific case.
Part of task-2730667
closesodoo/odoo#82498
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
When clicking on a mention (or a link) within the preview of the
message we're replying to, there was a traceback because we tried
to update a component which has already been deleted.
closesodoo/odoo#83912
Task-id: 2747321
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
When searching sale order lines from another model (e.g. task), the
order number was not being considered.
The technical reason for the above is the resulting domaing was like this:
[
'|',
('order_id.name', 'ilike', 'SO name'),
('name', 'ilike', 'SO name'),
# The below line is added by _name_search of base model
('name', 'ilike', 'SO name'),
])
So, even though the order number is added to the domain, an extra
condition was forcing the line description to be the only field to be
considered.
closesodoo/odoo#83911
X-original-commit: b5d45d6cae3579970ed55bc65d52c2de2377c381
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
To reproduce :
- Create a new documentation course from front-end
- Add a content there
- Edit the course in backend
=> any attempt to save the record or exiting it will trigger an error
as the specific option is set and no content has been manually set.
This has been introduced in 2597345
=> We restore the default 'latest created' that makes it work all the time.
Task-2731468
closesodoo/odoo#83910
X-original-commit: 1973944c0cdd0ea3f706280875acedfbd190333e
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
Shipping insurance is a service which may reimburse senders whose parcels are
lost, stolen, and/or damaged in transit. Since most shipping connectors
provide it, it makes sense to put it in the base directory.
task-2701459
closesodoo/odoo#83896
Signed-off-by: Arnold Moyaux <arm@odoo.com>
When trying to set up a new bank account using the bank account wizard,
there is an issue with the check company on the linked_journal_id field.
The check will make sure that the company on that field is either false
or the same as the company on the record. But with a recent change in
68f4534aa5 the bank account company_id will be the one from the linked partner.
As the partners for companies have an empty company_id, this check does
not make a lot of sense anymore, as it would be wrong in most cases.
(We expect a journal with the currently selected company, but the bank
account will in most cases have an empty company_id)
closesodoo/odoo#83852
Signed-off-by: Josse Colpaert <jco@odoo.com>
In 9f7e6d2bb6ae0a6b0257edf26a5aa069cd00d78e , when start a workorder, we
always suggest the qty to produce to be the full qty to produce on MO.
If the previous WO produced less than the full qty to produce on MO,
user won't aware of that when start the WO. We revert it in this committ
Task-2678388
closesodoo/odoo#83389
Related: odoo/enterprise#23961
Signed-off-by: Arnold Moyaux <arm@odoo.com>
Storno accounting is the term used to described the process of recording
a reverse action as a negative amount on the same site instead of a
positive amount on the opposite site of the credt/debit.
For instance, when one creates a credit note for an invoice, the values
of debit and credit will be kept in the same column with negative signs
instead of swapping columns like in non-Storno accounting.
It is a business practice commonly used in Eastern European countries.
Countries where Storno accounting is mandatory or considered as best
practice would be :
Czech Republic, Poland, Romania, Russia, Slovakia, Ukraine, Croatia,
Bosnia and Herzegovina, Serbia, Romania, China, Russia, Slovenia
It is available as an option in the settings and is automatically
activated for some countries which use this type of accounting.
otask-2064899
closesodoo/odoo#79581
Related: odoo/upgrade#3212
Signed-off-by: William André (wan) <wan@odoo.com>
Co-authored-by: william-andre <wan@odoo.com>
Co-authored-by: qdp-odoo <qdp@odoo.com>