Friday, July 9, 2021
32 changes · master
New functionality added to Odoo
Mailing lists are now separated from internal discussion channels, making email-based groups easier to manage and less tied to chat features. Users get a dedicated portal to subscribe or unsubscribe, while moderation workflows such as accepting, rejecting, allowing, or banning messages remain available for mailing lists.
Original PR description
RATIONALE Discussion channels currently have two main operating modes: Discuss channels (classic, chat, livechat) and Mailing lists (activated through "send email" checkbox). This current model has…
RATIONALE
Discussion channels currently have two main operating modes: Discuss channels
(classic, chat, livechat) and Mailing lists (activated through "send email"
checkbox). This current model has several drawbacks
* mailing lists are meant to be used by external people. Discuss/Inbox
display has no use for external people;
* mailing lists have a frontend page (website_mail_channel) that also
displays private channels (if people have access) content, which makes
no sense;
* moderation is available only on mailing lists, meaning the moderation
mechanism is useless for a majority of channels;
* incoming Discord-like behavior of channels will further make mailing
lists different from chat channels;
PURPOSE
Split mailing list from discussion channels. Purpose of this new module
is to manage the mailing lists. Now they are no more <mail.channel>
with email_send set to True but instead use their own model.
SPECIFICATIONS
The mailing list is basically a public discussion that users can have
by email. They can respond to email, send new messages, etc... All the
members of the mailing list will receive the message by email.
Users can moderate the emails of the mailing list in the same way as
they did with the "email" mail channel.
- *accept*, will accept the emails and send it to the members of the
mailing list
- *discard*, will drop the email without warning the author
- *reject*, will drop the email and send a notification email to the
author
- *allow*, will accept the email and all other pending emails of the
same author and create a whitelist for him
- *ban* will drop the email and all other pending emails of the same
author and create a blacklist for him
Now a portal view is available (in /groups) and replace the old module
"Website Mail Channel" that was removed in the previous commit. In this
view, users can subscribe / unsubscribe to the mailing lists and some
links to this portal view are added in the footer of the emails of the
mailing list.
As before with mail channels, you can send guidelines to the members,
notify the moderators whose an action is required (in a CRON), send back
an email to the author of an email to say "Your message is waiting
moderation"...
LINKS
Task-2510267
See odoo/odoo/pull/71599
See odoo/enterprise/pull/19296
See odoo/upgrade/pull/2600Enhancements to existing features
This update standardizes how Odoo apps access session information by requiring them to use a shared web module. It helps keep user and session data handling more consistent across features such as mail, point of sale, website, and autocomplete.
Original PR description
* google_recaptcha, mail, partner_autocomplete, point_of_sale, website Now, to read session information, the module "@web/session" must be imported. Not that, there is also the user service with all the user information
Resolved issues and error corrections
This fix prevents old-style help popups from lingering on screen after a user clicks a button while hovering over it. It improves the web interface by keeping the page cleaner and avoiding confusing leftover popups.
Original PR description
Before this commit, when hovering a button with a bootstrap tooltip set on it (form view with header button in debug mode) and then clicking while staying hover the tooltip was not destroyed and there was no easy means to destroy it. After this commit, any click within a legacy context remove any bootstrap tooltip from the DOM, since popper and tooltip are not meant to be used in the future in a wowl setting. 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
Code cleanup and technical improvements
This pull request restructures internal XML import handling to make the code easier to maintain. It does not introduce new features or remove existing behavior, so business impact should be minimal while improving future development reliability.
Original PR description
Follows odoo/odoo#27383 with more refactorings & cleanups of `import_xml.rng` and the corresponding Python code. As of the PR creation, this only contains (incomplete/wip) refactorings, not new features or deprecations/removals.
Miscellaneous changes
- Install Sales > Configuration > Settings and activate Delivery Methods - Create a SO as followed: * Add a section (i.e. Section 1) * Add a product (i.e. Product A) * Add a product (i.e. Product B) * Add a shipping (i.e. Delivery X) * Add a section (i.e. Section 2) * Add a product (i.e. Product C) - Move (drag & drop) Delivery X to the first place SO lines are reordered, but Product B is moved after Section 2. It comes from the fact that some lines have the same sequence
Original PR description
- Install Sales > Configuration > Settings and activate Delivery Methods - Create a SO as followed: * Add a section (i.e. Section 1) * Add a product (i.e. Product A) * Add a product (i.e. Product B)…
- Install Sales > Configuration > Settings and activate Delivery Methods - Create a SO as followed: * Add a section (i.e. Section 1) * Add a product (i.e. Product A) * Add a product (i.e. Product B) * Add a shipping (i.e. Delivery X) * Add a section (i.e. Section 2) * Add a product (i.e. Product C) - Move (drag & drop) Delivery X to the first place SO lines are reordered, but Product B is moved after Section 2. It comes from the fact that some lines have the same sequence and that only the lines between the source and the destination position are re-sequenced. Before the move, the sequencing is as followed: 1) Section 1: 10 2) Product A: 10 3) Product B: 10 4) Delivery X: 11 5) Section 2: 12 6) Product C: 13 After the move, only lines from 1 to 4 are re-sequenced. Leading to the following sequencing: 1) Delivery X: 10 2) Section 1: 11 3) Product A: 12 4) Product B: 13 5) Section 2: 12 6) Product C: 13 As Product B has now a greater sequence than Section 2, it will be moved after it. If some lines between the source and the destination position have the same sequence, all lines should be re-sequenced to prevent such a behavior. opw-2531524 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#73423 Forward-Port-Of: odoo/odoo#73085
Odoo now uses its own response system for redirects across many apps, making redirects more consistent and easier to customize. This also improves handling of language-aware website links and standardizes redirect behavior for login, email, calendar, payment, and related flows.
Original PR description
This branche replace werkeug.utils.redirect into odoo.http.redirect. odoo.http.redirect now use an http.Response type, and it become easy to add an override like 'set_cookies' e.g. 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
The settings menu item previously labeled “Template” is now labeled “Email Templates.” This makes it easier for users to distinguish email templates from other template types in Odoo, reducing confusion when navigating settings.
Original PR description
Description of the issue/feature this PR addresses: Rename the menu item 'Template' from the settings to 'Email template' . -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Dynamic product snippets on the website now show discounted prices consistently with regular product listings. Customers can see both the reduced price and the original strikethrough price in relevant snippets, making promotions clearer while browsing.
Original PR description
Show discount on product for the dynamic product snippet. The discount is displayed the same way it is for website_sale.product_item: the price with the discount and the price without discount in red and strikethroughed next to the other price. The discount is displayed for all the snippet templates displaying a price: 'Add Product to Cart', 'Detailed Product' and 'Image with price'. task-2519662 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
Tour guidance popups now center on the actual text content rather than the surrounding container. This makes onboarding and walkthrough tips look more precise when text is left- or right-aligned.
Original PR description
Before, the tour tip was centered on the container tag instead of the text content. That asymmetry was visible for text with a text-align different than center. Therefore the _reposition method of the tip has been modified to better handle such text elements. If its anchor element has inner text we use a range to get the width of the text. task-2477212 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
The web editor code has been brought directly into the main Odoo codebase instead of being maintained in a separate repository. This reduces coordination overhead for future updates and should make maintenance of website editing tools simpler, with no major immediate change expected for end users.
Point of Sale payments now store the related company information directly, making company-based checks much faster on large databases. This improves performance for payment total calculations without changing the user workflow.
Original PR description
it speeds up checking multi-company rule, partically, computed field `total_payments_amount` works faster in large databases: 2,8 sec -> 0,01 sec (see fe3e84085fc9446fb2b745d99df341de980a92c0 ) 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
This update prevents keyboard shortcuts tied to hidden page elements from being triggered, reducing accidental actions. It also makes the shortcut overlay key configurable, giving administrators and developers more flexibility in how shortcuts are displayed and used.
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
The enterprise mail tests were updated to stop relying on an old email sending field on mail channels. This supports the platform change that moves that behavior into a dedicated mail group area, reducing future maintenance risk without affecting day-to-day users.
Original PR description
Purpose ======= Remove the usage of the "email_send" field on the <mail.channel>. Links ===== Task-2510267 See odoo/odoo/pull/71599 See odoo/enterprise/pull/19296 See odoo/upgrade/pull/2600
Several Odoo Enterprise areas now read session information through a shared session module. This keeps session-dependent behavior more consistent across documents, mobile mail, timesheet synchronization, Enterprise web menus, and Studio, reducing maintenance risk without changing normal user workflows.
Original PR description
* documents, mail_mobile, project_timesheet_synchro, web_studio Now, to read session information, the module "@web/session" must be imported. Not that, there is also the user service with all the user information.
The asset Kanban view now shows more useful information in a layout better suited to mobile screens. This helps users review and manage asset records more easily when working away from a desktop.
Original PR description
This task aims to improve the Kanban view of the assets for its use on mobile, by giving more relevant information to the user. Task id #2531143
Website page creation now correctly handles content containing ampersands during setup. This prevents installation failures in the website configurator when page text includes characters like '&'.
Original PR description
`_render('<h1> quick & flupke </h1>') `=>` '<h1> quick & flupke </h1>'`
what cannot be parsed in xml after.
Before this commit, if you try to install a page that contains a '&' via
the configurator, you had a traceback:
xmlParseEntityRef: no name, line 1, column 13
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-prThis change reorganizes part of Odoo's web client action handling to make the code easier to maintain and evolve. It should not noticeably change day-to-day user workflows, but it can help reduce future development complexity in the web interface.
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
Context * postgres 12.5 * Odoo 14 DB Stats * pos.payment: 645 K * pos.order by company: 379 K, 1 K, 973 K, 19 K total_payments_amount ===================== Result: 0.02 sec vs 33.6 sec POS Session Stats: * pos.order: 27 K * pos.payment: 39 K BEFORE 22 33.467 0.123 (number of queries, query time, rest time) AFTER read_group refactoring: 4 3.952 0.006 AFTER read_group + session_id index 4 2.770 0.009 AFTER read_group + session_id i
Original PR description
Context * postgres 12.5 * Odoo 14 DB Stats * pos.payment: 645 K * pos.order by company: 379 K, 1 K, 973 K, 19 K total_payments_amount ===================== Result: 0.02 sec vs 33.6 sec POS Session…
Context * postgres 12.5 * Odoo 14 DB Stats * pos.payment: 645 K * pos.order by company: 379 K, 1 K, 973 K, 19 K total_payments_amount ===================== Result: 0.02 sec vs 33.6 sec POS Session Stats: * pos.order: 27 K * pos.payment: 39 K BEFORE 22 33.467 0.123 (number of queries, query time, rest time) AFTER read_group refactoring: 4 3.952 0.006 AFTER read_group + session_id index 4 2.770 0.009 AFTER read_group + session_id index + store company_id 4 0.009 0.006 _compute_cash_balance ===================== Result: 0.1 sec vs 9.2 sec POS Session Stats: * pos.order: 59 K * pos.payment: 82 K BEFORE 399 1.695 7.587 AFTER 21 0.123 0.016 _compute_picking_count ====================== Result: 0.7 sec vs 3.5 sec POS Session stats * pos.order: 107 K * stock.picking: 60 K BEFORE 126 1.007 2.452 AFTER 5 0.723 0.011 --- opw-2514640 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#69933
Printing a kitchen ticket with arabic product name lead to bad css layout. The layout has been switched to make it no matter language is used. -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#73427
Original PR description
Printing a kitchen ticket with arabic product name lead to bad css layout. The layout has been switched to make it no matter language is used. -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#73427
When adding several PO to a bill, if they don't have the same currency, it will lead to incorrect amounts To reproduce the error: 1. In Settings, enable "Multi-Currencies" 2. Invoicing > Configuration > Currencies: - EUR: Active, Current Rate = 2 - USD: Active, Current Rate = 1 3. Create a PO: - Currency: USD - Products: - One product, no taxes, unit price 1000 4. Confirm PO 5. Edit PO: - Qty Received: 1 6. Repeat 3 -> 5 with EUR instead of USD 7. Ope
Original PR description
When adding several PO to a bill, if they don't have the same currency,
it will lead to incorrect amounts
To reproduce the error:
1. In Settings, enable "Multi-Currencies"
2. Invoicing > Configuration > Currencies:
- EUR: Active, Current Rate = 2
- USD: Active, Current Rate = 1
3. Create a PO:
- Currency: USD
- Products:
- One product, no taxes, unit price 1000
4. Confirm PO
5. Edit PO:
- Qty Received: 1
6. Repeat 3 -> 5 with EUR instead of USD
7. Open a new Bill
8. Add the first PO to the field "Auto-Complete"
9. Add the second PO to the field "Auto-Complete"
Error: Both invoice lines are now expressed in EUR and both subtotals
are equal to 1000 even though the exchange rate isn't 1
This commit suggests not to change the currency of the account move if
the latter already has some AML. Moreover, the amounts must be converted
if they come from a PO that uses another currency
OPW-2573748
Forward-Port-Of: odoo/odoo#73247Steps to reproduce the bug: - Go to Accounting > Vendors > Bills - Create a new Bills - Delete the contents of the 'Accounting Date' field. - Click off that field. Problem: -An AttributeError is triggered because we try to recalculate a new name via the function `"_compute_name"` and we base ourselves on the date field, but we do not check if it is null or not before accessing it. This field is only used for purchase receipts, vendor bills, vendor credit notes, payments and regular
Original PR description
Steps to reproduce the bug: - Go to Accounting > Vendors > Bills - Create a new Bills - Delete the contents of the 'Accounting Date' field. - Click off that field. Problem: -An AttributeError is triggered because we try to recalculate a new name via the function `"_compute_name"` and we base ourselves on the date field, but we do not check if it is null or not before accessing it. This field is only used for purchase receipts, vendor bills, vendor credit notes, payments and regular journal entries. Other move types are unaffected here. opw-2511799 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#73465
Description of the issue/feature this PR addresses: - In POS with pos_six installed - create an order - add a payment with SIX, paid - Click on reversed - Pay in cash --> Issue on the receipt the payment and refund by SIX doesn't appear on the ticket @pimodoo -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#71262
Original PR description
Description of the issue/feature this PR addresses: - In POS with pos_six installed - create an order - add a payment with SIX, paid - Click on reversed - Pay in cash --> Issue on the receipt the payment and refund by SIX doesn't appear on the ticket @pimodoo -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#71262
*: web_editor, website In this PR, the following changes have been made: - Disable link edition (Popover) in snippet navigation. - The first element is selected once the snippet is visible at the bottom of screen. task-2431484 Forward-Port-Of: odoo/odoo#72509
Original PR description
*: web_editor, website In this PR, the following changes have been made: - Disable link edition (Popover) in snippet navigation. - The first element is selected once the snippet is visible at the bottom of screen. task-2431484 Forward-Port-Of: odoo/odoo#72509
Actually only one payment method is allowed by iot device type because we take only the first one found by iot device type With this fix we loop on all payment method to instantiate the terminal proxy on each payment method Forward-Port-Of: odoo/enterprise#19561 Forward-Port-Of: odoo/enterprise#19536
Original PR description
Actually only one payment method is allowed by iot device type because we take only the first one found by iot device type With this fix we loop on all payment method to instantiate the terminal proxy on each payment method Forward-Port-Of: odoo/enterprise#19561 Forward-Port-Of: odoo/enterprise#19536
On the module installation all values are empty, no need to fetch all `account.move.line` just to set zero value to subscription_mrr. This commit prevents memory limit error. --- opw-2579185 Forward-Port-Of: odoo/enterprise#19436
Original PR description
On the module installation all values are empty, no need to fetch all `account.move.line` just to set zero value to subscription_mrr. This commit prevents memory limit error. --- opw-2579185 Forward-Port-Of: odoo/enterprise#19436
This reverts commit d5ae2245ee5b3c9b70a384608542041ed8218fba Package dimensions are encoded with integers and in meters, so users are forced to use packages of minimum 1x1x1 meter. Without the fix, the UoM used in the requests sent to UPS will be the one configured on the carrier's form. Forward-Port-Of: odoo/enterprise#19534 Forward-Port-Of: odoo/enterprise#19517
Original PR description
This reverts commit d5ae2245ee5b3c9b70a384608542041ed8218fba Package dimensions are encoded with integers and in meters, so users are forced to use packages of minimum 1x1x1 meter. Without the fix, the UoM used in the requests sent to UPS will be the one configured on the carrier's form. Forward-Port-Of: odoo/enterprise#19534 Forward-Port-Of: odoo/enterprise#19517
When the tests are executed, we should not contact the web-service and therefore mock the calls to the web-services. Before this commit, not all tests were correctly mocked. Forward-Port-Of: odoo/enterprise#19522
Original PR description
When the tests are executed, we should not contact the web-service and therefore mock the calls to the web-services. Before this commit, not all tests were correctly mocked. Forward-Port-Of: odoo/enterprise#19522
Before this commit, we were using the first bank account set on the partner associated to the payment for which we are generating the XML file. We should use the bank account set on the payment itself to avoid inaccuracies in case multiple bank accounts are set on the partner. opw-2573113 Forward-Port-Of: odoo/enterprise#19540 Forward-Port-Of: odoo/enterprise#19463
Original PR description
Before this commit, we were using the first bank account set on the partner associated to the payment for which we are generating the XML file. We should use the bank account set on the payment itself to avoid inaccuracies in case multiple bank accounts are set on the partner. opw-2573113 Forward-Port-Of: odoo/enterprise#19540 Forward-Port-Of: odoo/enterprise#19463
- Have a [DEMO] product: - Tracket by SN - Manufactured - The BOM for [DEMO] has: - product [COMPONENT] tracked by lot - At least an operation - Add at least 1 lot with 2 units to [COMPONENT] - Create a manufacturing order for [DEMO], specifying 2 units to produce - Confirm, check availability - In Workorders tab start the production and go to tablet mode - Assign the serial to [DEMO], change the lot of [COMPONENT] to a new lot, then mark as done Error will raise opw-257
Original PR description
- Have a [DEMO] product: - Tracket by SN - Manufactured - The BOM for [DEMO] has: - product [COMPONENT] tracked by lot - At least an operation - Add at least 1 lot with 2 units to [COMPONENT] - Create a manufacturing order for [DEMO], specifying 2 units to produce - Confirm, check availability - In Workorders tab start the production and go to tablet mode - Assign the serial to [DEMO], change the lot of [COMPONENT] to a new lot, then mark as done Error will raise opw-2577094 Forward-Port-Of: odoo/enterprise#19490
The format for this export changed in 2021. The specification of what changed can be found here: https://www.agenciatributaria.es/AEAT.internet/Inicio/Ayuda/Disenos_de_registro/Modelos_300_al_399/Modelos_300_al_399.shtml The file format should be fixed without even updating the module. For a more complete feature, people can update l10n_es_reports, to view the new report lines, and install the new module l10n_es_reports_2021 (which will have to be merged with l10n_es_reports in master later o
Original PR description
The format for this export changed in 2021. The specification of what changed can be found here: https://www.agenciatributaria.es/AEAT.internet/Inicio/Ayuda/Disenos_de_registro/Modelos_300_al_399/Modelos_300_al_399.shtml The file format should be fixed without even updating the module. For a more complete feature, people can update l10n_es_reports, to view the new report lines, and install the new module l10n_es_reports_2021 (which will have to be merged with l10n_es_reports in master later on). This module adds fields in the BOE and mod 303 wizards to allow manually setting of the new report lines' value. OPW 2496289, 2411661 Forward-Port-Of: odoo/enterprise#19480 Forward-Port-Of: odoo/enterprise#19052
Forward-Port-Of: odoo/enterprise#19510 Forward-Port-Of: odoo/enterprise#18914
Original PR description
Forward-Port-Of: odoo/enterprise#19510 Forward-Port-Of: odoo/enterprise#18914
Problem: Traceback occurs when in projects - tasks - Gant View if you group by assigned to then project. This only occurs if there is no tasks that are unassigned if 1 task is unassigned it works as it should. Solution: Use an empty array by default instead of sending undefined OPW-2587882 Forward-Port-Of: odoo/enterprise#19515 Forward-Port-Of: odoo/enterprise#19445
Original PR description
Problem: Traceback occurs when in projects - tasks - Gant View if you group by assigned to then project. This only occurs if there is no tasks that are unassigned if 1 task is unassigned it works as it should. Solution: Use an empty array by default instead of sending undefined OPW-2587882 Forward-Port-Of: odoo/enterprise#19515 Forward-Port-Of: odoo/enterprise#19445