A mega-tour was introduced with [1] to test every single snippet.
This tour, despite being very useful as it tests the core behavior of the
website builder, is creating a lot of race conditions.
This commit won't fix anything but will actually reduce the tour length,
hopefully also reducing the amount of race condition while those are fixed.
Indeed, some snippets were tested multiple times, as a snippet might include
another snippet in its DOM, the xpath query would return multiple times the
same snippet.
Duplicates: s_card (5), s_banner (2), s_donation_button (2),
s_dynamic_snippet_products (2), s_newsletter_subscribe_form (3),
s_searchbar_input (2), s_text_block (3), s_hr (2).
[1]: https://github.com/odoo/odoo/commit/460d5ecb926c13a79ba363f8f86442433d91bf6f
task-2726529
X-original-commit: 6f6ace0f0b09f6ad8b497f89e331e43a18e00471
Part-of: odoo/odoo#82214
This commit renames the isMuted variable into isSelfMuted to reflect the
user action of self muting, as opposed to the state of being mute,
which will be distinct in an upcoming commit.
part of task-2720026
closesodoo/odoo#82199
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
Currently, we allow the user to press CTRL+Enter to force the submission of his
answer for that question when the focus is within a textarea.
However, we do not want to submit the question if CTRL+Arrow-right is pressed
(since you may use CTRL+arrows to navigate within your text).
In the same fashion, we don't want to select "option C" if you use CTRL+C to
copy some text in the textarea.
This commit fixes these use cases by only allowing the shortcut handling when
the focus is within a textarea when the pressed key is 'Enter' (code 13).
Task-2716078
closesodoo/odoo#82203
X-original-commit: 69de8e29053119195266379facb8231ba4f51944
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
Signed-off-by: Warnon Aurélien (awa) <awa@odoo.com>
Do not fetch products attributes specifications if there is no
custom/no_variant attributes specified on the SOline.
Also update query counters according to recent performance changes
(batched followers insertion and other things)
closesodoo/odoo#81585
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
Since [1] whenever the image of a `product.template` is updated, the
write date of all its related `product.product` is updated. This was
done to force a change of the unique parameter on image fields, which is
based on the last update field.
After this commit the `product.product`'s last update is instead
computed by also taking the `product.template`'s last update into
account. This avoids the need for updating the write date when the
image is changed, but on the other hand it also forces product images to
be reloaded whenever any other field of the `product.template` is
changed.
[1] https://github.com/odoo/odoo/pull/71139
Related to https://github.com/odoo/odoo/pull/76309
task-2477438
closesodoo/odoo#78356
Signed-off-by: Romain Derie (rde) <rde@odoo.com>
Co-authored-by: Benoit Socias <bso@odoo.com>
Before this PR, the guest that just connect wouldn't receive the longpolling
message before the current one expire.
task-2664831
closesodoo/odoo#82170
X-original-commit: 0006123dba46d32d062a581e9a16f433f3ce05f3
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
With a 308 redirection from `/url` to `/new_url`:
Links like `/url?a=a` should be rewritten to `/new_url?a=a` and not
`/new_url?a=a&a=a`.
closesodoo/odoo#82099
X-original-commit: bae72fd70c4d3682bff9e148cac1408ca5603b76
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
Signed-off-by: Romain Derie (rde) <rde@odoo.com>
Reproduction:
- have 308 redirection from /shop to /boutique and refresh routes
- go in incognito on /boutique?order=name+asc (don't go on
/boutique first, or restart odoo to clear ORM cache)
- select a sorting option eg. price
=> we are redirected to /boutique?order=name+asc?order=list_price+asc
and this error is shown:
Invalid "order" specified (is_published desc, name asc?order=list_price
asc, id desc).
This is happening because url_rewrite is keeping current query string
(see ir.http()._slug_matching) and caching it. So if the first call
caches:
url_rewrite('/boutique') => /boutique?order=name+asc
all other url_rewrite('/boutique') calls will give you
/boutique?order=name+asc even if the query string has changed.
In addition to that, url_for may append query_string to url_rewrite
return value, so you may get a double query_string such as:
?order=name+asc?order=list_price+asc
which causes the error.
In this fix, we restore the removal of query string that was removed in
3beb4545c4.
opw-2702036
X-original-commit: 5dcf6e91fed769f4ab22ac63d3e5078cdd352e86
Part-of: odoo/odoo#82099
Before this commit: a notification asking to reload the current window
appeared as soon as the server detected a change in one of the assets
bundles, even on first load.
To fix this problem and make the feature more meaningful, it has been
decided to only notify the client when the server version (not the
bundle version) is outdated (i.e. on database upgrades, when the changes
in the code are actually relevant).
closesodoo/odoo#82032
X-original-commit: a3b5a9d715be6a93c7f2859074b916f3249f97c3
Signed-off-by: Antony Lesuisse <al@odoo.com>
Signed-off-by: Julien Mougenot (jum) <jum@odoo.com>
A company name >50 chars leads to:
Authorize.Net: Received data with status code "3" and error code "The
'AnetApi/xml/v1/schema/AnetApiSchema.xsd:company' element is invalid -
The value XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX is
invalid according to its datatype 'String' - The actual length is
greater than the MaxLength value."
This limits the company name to the specified 50 chars [1][2]. Cutting
off the company name should be fine for the same reasons as outlined in
64b86f36264c2e655681c7b6bed69e89891107bf.
[1] https://developer.authorize.net/api/reference/index.html#payment-transactions-charge-a-credit-card
[2] https://api.authorize.net/xml/v1/schema/AnetApiSchema.xsd
opw-2725246
closesodoo/odoo#82171
X-original-commit: 412e50290524ed0edc0317b141a296a883b173d3
Signed-off-by: Antoine Vandevenne (anv) <anv@odoo.com>
test_leave_whole_company_07 test was failing due ot the hr_leave_date_check2
constraint.
This constraint check that date_from <= date_to for a leave.
date_from and date_to were not assigned any value before and had a default value
of fields.Datetime.now. Depending on which date_from or date_to is created first,
a few second difference can exist and this violates the hr_leave_date_check2 constraint
task-2726143
closesodoo/odoo#82192
X-original-commit: c51553405b727e0187c0cf27b0ef9e0cb6023056
Signed-off-by: Kevin Baptiste <kba@odoo.com>
While investigating an issue with the x2many tracking, we found a
better way that to track those field while also fixing the issue.
Fixes an issue with `default_*` context keys that are used in the
project app upon writing on tasks.
TaskId-2725014
closesodoo/odoo#82189
X-original-commit: a281a18fc84a09177f7b5e8aab98b8dc34dcc3b8
Signed-off-by: Xavier <xbo@odoo.com>
Signed-off-by: Laurent Stukkens (ltu) <ltu@odoo.com>
In the event app, we have few email templates ('event.type') defined
in the data file so that when app is installed, user can have some basic
information readily available.
When needed, this data records are updated in few dependent modules
to provide more meaning to them. However, if these data records are
deleted, and someone tries to install it's dependent modules, it will
throw traceback because `<record>` tag won't be able to find the
linked record.
This commit makes the installation process more robust for such
modules by using write method with help of `<function>` tag, so
that if the record is available, it will be updated otherwise
no traceback will be thrown.
TaskID-2584092
closesodoo/odoo#80826
Signed-off-by: Warnon Aurélien (awa) <awa@odoo.com>
Before this commit:
kanban click on time value does not open the form view.
After this commit:
kanban click on time value will open the form view.
Task-2655411
closesodoo/odoo#82191
X-original-commit: 33b5e71aecc43b373ab7c863e1a1fe7a7dc8f7cb
Related: odoo/enterprise#23232
Signed-off-by: Laurent Stukkens (ltu) <ltu@odoo.com>
In test_limited_type_days_left, a time off was created with:
- 'date_from': (datetime.today() - relativedelta(days=2)),
- 'date_to': datetime.today(),
The test fails beginning of January as the allocation created at the
beginning of the test is valid between Jan 1 and Dec 31
task-2726171
closesodoo/odoo#82179
X-original-commit: df71862e59943b83584c36b08acd9700998716e1
Signed-off-by: Kevin Baptiste <kba@odoo.com>
In test_01_leave_request_flow_limited, a time off was created with:
- 'date_from': (datetime.today() + relativedelta(days=2)),
- 'date_to': datetime.today() + relativedelta(days=3),
The test fails during the end of December because no allocation is found.
The time is now frozen in the test
task-2726308
closesodoo/odoo#82178
X-original-commit: 1d6e736832b56a4c2bf1b9e335ed2bd8f929507a
Signed-off-by: Kevin Baptiste <kba@odoo.com>
Prior to this commit:
- When no user_id were set on the project, a with blank space was shown at
the bottom right of the kanban card.
After this commit:
- When no user_id is set on the project, the kanban status is move at the
bottom right of the kanban card.
task-2703632
closes odoo/odoo#82190
Closes: #80691
X-original-commit: 5bfea889d46ff66d4f2edd56449203943d7d040c
Signed-off-by: Xavier <xbo@odoo.com>
Signed-off-by: Laurent Stukkens (ltu) <ltu@odoo.com>
Before this commit temporary id could match an existing attachment id and
replace that attachment by the new uploaded one.
Even if this is very unlikly, using a negative id avoid it completly.
closesodoo/odoo#82185
X-original-commit: c18705d1ced6a9b1d6bb8c33049a1248ae83cf18
Signed-off-by: Alexandre Kühn (aku) <aku@odoo.com>
Before this commit, the `test_05_google_analytics_tracking` tour would often
fail, due to some race condition. It was introduced with [1].
Rewritting the test to make it (a lot) simpler, should get rid of the race
condition.
[1]: https://github.com/odoo/odoo/commit/78bc86cbeccfc5df16218aee2b0d7c501e5c05b5
task-2726482
closesodoo/odoo#82184
X-original-commit: 4bb6e3f38d8a5843cf82f889ac4eef7daf3da717
Signed-off-by: Romain Derie (rde) <rde@odoo.com>
*: web_editor, point_of_sale, pos_restaurant
The grab cursor is currently not working on all browsers (at least
Chrome Linux). The fallback rule does not even work, meaning that if
you type:
```
cursor: move;
cursor: grab;
```
Those browsers does not even use "move" as they see "grab" as valid but
use the "default" cursor.
This commit replaces our "grab" uses with a local cursor ensuring it
works.
Related to task-2431469
closesodoo/odoo#82093
X-original-commit: 23ebcca902781f2fa0f2381997be4f3d375385b5
Related: odoo/enterprise#23193
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
Signed-off-by: Romain Derie (rde) <rde@odoo.com>
Purpose
=======
Some trainees (eg: CIP) have a signed contract when they are paid.
X-original-commit: 5fe0f732fe7d0b27b649e9bfd6bec0a1ef2732de
Part-of: odoo/odoo#81927
Before this commit:
- The name of the company was appended to the name of the Internal Project,
having it even when only one Company was in the database.
After this commit:
- The name of the company will only be appended by the name_get when more than
one company is present in the database.
task-2608812
Closes: #79926
Related: odoo/enterprise#20514
Signed-off-by: Laurent Stukkens (ltu) <ltu@odoo.com>
Prior to this commit, the company of the invoices generated through the use
of the `sale.advance.payment.inv` wizzard were not forced to the one of the
related sales orders. From the compute method on account.move the company would
then be either the one of the journal or the current company.
It seems that context_keys were used 'at least in industry_fsm_sale' in order
to ensure that the company was correctly set (although the one of the task
was used instead of the one of the SO).
This commit ensures that invoices created through the wizzard now takes the company
of the SO they are generated from.
Finaly this commit adds a multicompany test in the sale module in order to ensure
that the `sale.advance.payment.inv` wizzard is not impacted by the multicompany.
task-2608812
Closes: #79926
Prior to this commit it was not possible to get a hook from
sale.advance.payment.inv in order to get the created invoices.
The create_invoices def returns either an action or an ir.actions.act_window_close
The introduction of the _create_invoices def will allow to get the created invoices
from the wizzard.
task-2608812
Closes: #79926
Automated action with a many2many field and reference evaluation can be created but don't work
Steps to reproduce:
1. Install Automated Action Rules module and Contacts app
2. Create an automated action for model 'Contact' with trigger 'On Creation' and action 'Update the Record'
3. Add a line to the automated action 'Data to Write' for the field 'Tags (res.partner)' with evaluation type 'Reference'
4. Go to Contacts, create and save a new one
5. An error is raised when trying to execute the automated action
Solution:
Raise an error when a many2many field is of evaluation type 'Reference'
OPW-2673939
(This PR is a duplicate of https://github.com/odoo/odoo/pull/82035 which for some reason couldn't do the forward ports)
closesodoo/odoo#82168
X-original-commit: 8d45823f2dda24c03b427ecbe7003a64b63d01b7
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
Signed-off-by: Guillaume Merlin (megu) <megu@odoo.com>
Right now, for the survey that has scoring enabled, when we try to
add scored question, the label 'Scored' is displayed twice, which
looks odd.
With this commit we rearrange the 'is_scored_question' and
'answer_score' field, and display them next to each other to
improve the view of survey question form view.
task-2704057
closesodoo/odoo#82161
X-original-commit: c5c8f5ddfc3c89b92288fa9a72977835b7614ae4
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
During the refactoring in pricelists made in PR:https://github.com/odoo/odoo/pull/79605
the signature of the function _price_get has changed and needs to get a
recordset of product instead of an ID.
So we know pass the product record
closesodoo/odoo#81161
Signed-off-by: Masereel Pierre <pim@odoo.com>
Currently, the fact that PoS displays to any PoS users the margins & costs
of product (new information popup) makes it difficult to sell in LATAM countries.
In this commit we address this issue by adding the 'Margins & Costs' field
in the settings of each PoS terminal. When this field is disabled, only PoS users
with manager access rights will be able to view the margins & costs data in the
information popup. In order to be compatible with previous behaviour this option
is enabled by default. For this reason, default behaviour is that every PoS user
will have access to the margins and costs of the products.
task-2672063
Part-of: odoo/odoo#81161
Before the PR, when replying to an empty (only attachment) nothing was display
in the message reply preview. This PR introduce a placeholder to handle this
case.
Also taking to opportunity to add missing translations.
task-2664815
closesodoo/odoo#81996
X-original-commit: 60f68512fdc9ebfb2d9331790be5884a86cce67b
Signed-off-by: Sébastien Theys (seb) <seb@odoo.com>
When reversing the CABA entry, the CABA tax account was replaced by the transition tax account if not set on the repartition line.
To reproduce:
Set up a CABA tax with ACC1 as transition tax account and ACC2 as tax account.
When creating the CABA entry, there is a line on ACC1 and another on ACC2.
When reversing the CABA entry, both lines are now on ACC1.
Introduced by https://github.com/odoo/odoo/pull/79556closesodoo/odoo#82004
Issue: 2718413
X-original-commit: 2f6a35eb73978ce0638765fd0981c7e95d9df696
Signed-off-by: Laurent Smet <las@odoo.com>
Step to reproduce:
- Duplicate expense with a uom != of Unit
Current behaviour :
- Error telling that the unit is not correctly chosen
Behaviour After PR:
- The uom is copied on duplication and no error
opw-2714136
closesodoo/odoo#81973
X-original-commit: bd4db173284aa45d141cc3736ecef511738dd8e3
Signed-off-by: Damhaut Florian (flda) <flda@odoo.com>
Steps to reproduce:
- Install Fleet
- Go on report-cost
- Click on a specifi vehicles
-> The cost associated are not correct
Solution:
Correction of the SQL-query which was not correct (id not unique)
closesodoo/odoo#81688
X-original-commit: e06114b3b7e188d8ce293f77d8395592193eb83d
Signed-off-by: yosa-odoo <yosa@odoo.com>
Signed-off-by: Kevin Baptiste <kba@odoo.com>
When running test tours logging a message to console.error causes the
test tour to fail. Only one such message can cause the tour to fail, if
other message are written on the console they are simply logged in the
odoo logs. The offending message, however, is only shown at the end of
run, as part of the failing test logs. Arguably, it is better to
include it in the browser logs as well.
closesodoo/odoo#75197
Signed-off-by: Christophe Monniez (moc) <moc@odoo.com>
Current behavior :
When creating payment from invoice, the payment had the wrong sales team id
Steps to reproduce :
- Create atleast 2 invoices with different sales team and same partner
- Register payments for every invoice
- Go in payments list view
- Filter on partner and group by sales team
- All the payments are grouped in the same sales team
opw-2681041
closesodoo/odoo#82114
X-original-commit: 2f3ebe86b2d520dd9c7570f60056f200bb091aab
Signed-off-by: Engels Robin (roen) <roen@odoo.com>
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
This commit properly formats the domain attribute of few fields so that
the technical tooltips for them do not show '\n' within the domain.
Below are the improved fields:
- 'triggering_question_id' (for model 'survey.question')
- 'partner_ids' (for model 'survey.invite')
Taskid-2704057
closesodoo/odoo#81631
Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
* Move specific actions to their place of use (as they are not expected
to be used anywhere else)
* order actions by use/importance in sale_order_views.xml, and server
actions in a specific "section"