Tuesday, January 4, 2022
27 changes · master
Enhancements to existing features
Installing event-related sales and track features is now less likely to fail if optional default event records were previously removed. This helps keep setup smoother for businesses adding event capabilities later.
Original PR description
This PR makes the installation process for event dependent modules more robust by updating data records using write method (in xml, with help of `<function>` tag), so that if the record is available, it will be updated otherwise no traceback will be thrown. TaskID-2584092
Adds richer demo data across Helpdesk-related apps to make testing and demonstrations quicker to prepare. This helps teams showcase support, sales timesheet, stock, and forum integrations with less manual setup.
Original PR description
The purpose of the task is to add demo data to ease the testing of tasks, reduce the time to set up a database for a demo, and showcase our features. task-2677843
The project demo data has been adjusted so task dates better match the rest of the sample data. Task names were also reorganized by project, making demo scenarios easier to understand and maintain.
Original PR description
This PR will change some tasks dates to make them more consistent with the rest of the demo data Related: https://github.com/odoo/odoo/pull/80102/ Task 2669762
Code cleanup and technical improvements
This update renames an internal mail calling field to make it clear when a participant has muted themselves. It prepares the system to distinguish self-muting from other muted states in future call features, with no expected change for users today.
Original PR description
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
Miscellaneous changes
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 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#82140
Original PR description
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 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#82140
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 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#82136
Original PR description
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 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#82136
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 Forward-Port-Of: odoo/odoo#80744
Original PR description
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 Forward-Port-Of: odoo/odoo#80744
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 Forward-Port-Of: odoo/odoo#82092 Forward-Port-Of: odoo/odoo#82069
Original PR description
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 Forward-Port-Of: odoo/odoo#82092 Forward-Port-Of: odoo/odoo#82069
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 -- I confirm I have signed the CLA and read the PR guidelines at www.odo
Original PR description
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 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#82183 Forward-Port-Of: odoo/odoo#82131
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 6
Original PR description
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 Forward-Port-Of: odoo/odoo#82102
Forward-Port-Of: odoo/odoo#81988
Original PR description
Forward-Port-Of: odoo/odoo#81988
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
Original PR description
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) -…
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
3beb454.
opw-2702036
Forward-Port-Of: odoo/odoo#82056
Forward-Port-Of: odoo/odoo#81685Forward-Port-Of: odoo/odoo#81391
Original PR description
Forward-Port-Of: odoo/odoo#81391
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
Original PR description
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 Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#82149 Forward-Port-Of: odoo/odoo#81594
Description of the issue/feature this PR addresses: 1. create a fresh db in version 14.0 with the website module and a theme installed. 2. upgrade the db to version 15.0 when I click the "Pick a theme" button the error is occurring Current behavior before PR: ``` TypeError: Cannot read properties of undefined (reading 'value') at Engine.eval (eval at _render (http://localhost:8069/web/assets/12013-adfcf1f/web.assets_common.min.js:4490:73), :16:119) at Engine._render (http://localhost:
Original PR description
Description of the issue/feature this PR addresses: 1. create a fresh db in version 14.0 with the website module and a theme installed. 2. upgrade the db to version 15.0 when I click the "Pick a…
Description of the issue/feature this PR addresses: 1. create a fresh db in version 14.0 with the website module and a theme installed. 2. upgrade the db to version 15.0 when I click the "Pick a theme" button the error is occurring Current behavior before PR: ``` TypeError: Cannot read properties of undefined (reading 'value') at Engine.eval (eval at _render (http://localhost:8069/web/assets/12013-adfcf1f/web.assets_common.min.js:4490:73), :16:119) at Engine._render (http://localhost:8069/web/assets/12013-adfcf1f/web.assets_common.min.js:4489:296) at Engine.render (http://localhost:8069/web/assets/12013-adfcf1f/web.assets_common.min.js:4489:151) at Class._render (http://localhost:8069/web/assets/12014-9673983/web.assets_backend.min.js:5171:222) at Class.start (http://localhost:8069/web/assets/12014-9673983/web.assets_backend.min.js:5160:1453) at Class.prototype. [as start] (http://localhost:8069/web/assets/12013-adfcf1f/web.assets_common.min.js:4712:488) at http://localhost:8069/web/assets/12013-adfcf1f/web.assets_common.min.js:5050:52 at async Promise.all (index 8) ``` Desired behavior after PR is merged: The error is resolved and we can pick a theme. -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#82156 Forward-Port-Of: odoo/odoo#81578
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
Original PR description
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 Forward-Port-Of: odoo/odoo#82169
Current behavior: You had a traceback when trying to pay with Stripe and a specific modified Quotation template Steps to reproduce: 1. Set stripe as the payment acquirer (with default test values ) 2. Modify the Quotation Template "4 person Desk" - Uncheck "Online signature" - Put "Confirmation Mail" as "Sales Order: Confirmation Email" 3. Create a SO 4. Set it's quotation template as "4 person Desk" 5. Action > Generate Payment link 6. Use the link as the public user (in incognito f
Original PR description
Current behavior: You had a traceback when trying to pay with Stripe and a specific modified Quotation template Steps to reproduce: 1. Set stripe as the payment acquirer (with default test values ) 2. Modify the Quotation Template "4 person Desk" - Uncheck "Online signature" - Put "Confirmation Mail" as "Sales Order: Confirmation Email" 3. Create a SO 4. Set it's quotation template as "4 person Desk" 5. Action > Generate Payment link 6. Use the link as the public user (in incognito for instance) 7. Pay with Stripe => Traceback opw-2721526 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#82151 Forward-Port-Of: odoo/odoo#82077
Steps to reproduce the bug: - Install inventory and sales - Create a SO > Confirm - Click on the delivery > print > delivery slip or picking operation Problem: Only the name and phone number are in the report opw-2697221 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#80540
Original PR description
Steps to reproduce the bug: - Install inventory and sales - Create a SO > Confirm - Click on the delivery > print > delivery slip or picking operation Problem: Only the name and phone number are in the report opw-2697221 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#80540
Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#80380
Original PR description
Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#80380
Currently, report lines in the BS, P&L and General Ledger that are unfoldable, need to be clicked twice in order to unfold (after scrolling). This is not supposed to be the case. This happens because a clone of the report table is made in order to improve the management of the width of columns with ellispis in the reports. task-2711352 Forward-Port-Of: odoo/enterprise#23235
Original PR description
Currently, report lines in the BS, P&L and General Ledger that are unfoldable, need to be clicked twice in order to unfold (after scrolling). This is not supposed to be the case. This happens because a clone of the report table is made in order to improve the management of the width of columns with ellispis in the reports. task-2711352 Forward-Port-Of: odoo/enterprise#23235
Currently, when mentioning another user, the regex will break at a "." character. This character is allowed in user names and should thus be taken into account. e.g: @odoo.official will now be correctly recognized and linked. (And will turn into a link to https://instagram.com/odoo.official) A test case was modified to ensure that behavior. Task-2717346 Forward-Port-Of: odoo/enterprise#23213 Forward-Port-Of: odoo/enterprise#22963
Original PR description
Currently, when mentioning another user, the regex will break at a "." character. This character is allowed in user names and should thus be taken into account. e.g: @odoo.official will now be correctly recognized and linked. (And will turn into a link to https://instagram.com/odoo.official) A test case was modified to ensure that behavior. Task-2717346 Forward-Port-Of: odoo/enterprise#23213 Forward-Port-Of: odoo/enterprise#22963
Currently when this modules is installed/udpated we setup the accounting info using the new account codes for the EA's CoA in 15.0 https://github.com/odoo/odoo/commit/8d6bd85d2ba9f1aee414734372c0ea684cbd6aa5 Before this patch we used to fail the setup with a message to the user. Here we silently skip the setup if the necessary accounts are not found. This is far from ideal, and the user will need to manually setup the account codes. It is, nonetheless, necessary to allow the upgrade of
Original PR description
Currently when this modules is installed/udpated we setup the accounting info using the new account codes for the EA's CoA in 15.0 https://github.com/odoo/odoo/commit/8d6bd85d2ba9f1aee414734372c0ea684cbd6aa5 Before this patch we used to fail the setup with a message to the user. Here we silently skip the setup if the necessary accounts are not found. This is far from ideal, and the user will need to manually setup the account codes. It is, nonetheless, necessary to allow the upgrade of older DBs with the AE CoA already installed. Forward-Port-Of: odoo/enterprise#23119
Create a negative line with a discount. The remaining amount to distribute wasn't computed correctly. Forward-Port-Of: odoo/enterprise#23077
Original PR description
Create a negative line with a discount. The remaining amount to distribute wasn't computed correctly. Forward-Port-Of: odoo/enterprise#23077
Before this commit: rating with 'no rating' is shown in customer ratings After this commit: it won't show ratings which has 'no ratings yet' Task-2655411 Forward-Port-Of: odoo/enterprise#22667
Original PR description
Before this commit: rating with 'no rating' is shown in customer ratings After this commit: it won't show ratings which has 'no ratings yet' Task-2655411 Forward-Port-Of: odoo/enterprise#22667
The continuation_contract was not properly populated as the original contract was time_credit. Forward-Port-Of: odoo/enterprise#23211
Original PR description
The continuation_contract was not properly populated as the original contract was time_credit. Forward-Port-Of: odoo/enterprise#23211
PR #23098 introduced new CO² values for 2022, this commit adapts the test for them. Forward-Port-Of: odoo/enterprise#23210
Original PR description
PR #23098 introduced new CO² values for 2022, this commit adapts the test for them. Forward-Port-Of: odoo/enterprise#23210
…appraisal In test_appraisal_next_appraisal_date_uppcoming_appraisal, a search is done the employees to check the appraisal date based on the number of appraisal the employee had. If the appraisal count is 0, the domain checks if the create_date of the employee is within the month of the duration_after_recruitment. Since a relativedelta is applied to the current date, if the current date has 30 days and the create_date is on the 31st of a month, it won't find the employee. Instead,
Original PR description
…appraisal In test_appraisal_next_appraisal_date_uppcoming_appraisal, a search is done the employees to check the appraisal date based on the number of appraisal the employee had. If the appraisal count is 0, the domain checks if the create_date of the employee is within the month of the duration_after_recruitment. Since a relativedelta is applied to the current date, if the current date has 30 days and the create_date is on the 31st of a month, it won't find the employee. Instead, the create_date is checked against a date range starting from the first of the month to the last day task-2726422 Forward-Port-Of: odoo/enterprise#23215