Friday, May 26, 2023
51 changes · master
Enhancements to existing features
The link tracking form now uses clearer placeholder text for campaign, medium, and source fields. This helps marketing users choose the right values more consistently and reduces confusion when creating tracked links.
Original PR description
With the current placeholders, the marketing team always confuses Campaign, medium & source. This PR rewords the placeholders. Task-3329960
The website module now uses a more suitable icon for the New Blog Post option in the user navigation bar. This makes the action easier to recognize and improves the content creation experience for website editors.
Original PR description
This commit changes the current 'fontawesome' icon, applied to the 'New Blog Post' view, activated after pressing the 'New' button in the 'User Navbar' of the 'website' module. This change is made since the current icon does not properly represent a blog post icon. -- Task 2448475 -- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
The warehouse form now gives the name field the full available width. This makes longer warehouse names visible without extra scrolling, improving day-to-day usability for inventory users.
Original PR description
before this commit, in the warehouse form view the name field was short and name cannot be read fully without scrolling after this commit, the field will utilize the full available space and end users can read the name easily. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Approval category icons in Approvals and Purchase Approvals have been redesigned with a cleaner, more modern visual style. This improves the look and consistency of the approval experience without changing business workflows.
Original PR description
Old icons from 'approvals' and 'approvals_purchase' modules, in 'odoo-enterprise', used FontAwesome instances and looked outdated, so they have been improved by redesigning them using a more stylised approach with simple lines and the Odoo primary purple colour. -- task-2197513
Resolved issues and error corrections
The signature dialog now opens on the automatic signature option instead of forcing users to the drawing option after selecting a signature field. This makes signing smoother for users who prefer the prefilled automatic signature and aligns the dialog with its intended default behavior.
Original PR description
This commit improves the behavior of the signature dialog. Now, we don't force the display of the dialog to the draw tab after a click has been made on a field with the signature widget. The dialog has already supported the management of the default tab when no defaultName props is given. A test has been adapted to test this new behavior. This test used the full_name attribute to verify the presence of the 'Auto' button. Now, this button is selected by default. task-3259468.
Code cleanup and technical improvements
Miscellaneous changes
After the removal of the `balance` line in payment terms in 16.2, the behavior was not the same as it was before when using a fixed line. Example: $ 1000 | Amount | Type | Example Value | | ------ | ------- | ------------- | | 50 | Percent | $ 475 | | 50 | Fixed | $ 50 | | 50 | Percent | $ 475 | We used to remove the fixed lines, then split the remaining amount according to the percentages, and finally insert the fixed lines again. Since
Original PR description
After the removal of the `balance` line in payment terms in 16.2, the behavior was not the same as it was before when using a fixed line. Example: $ 1000 | Amount | Type | Example Value | | ------ |…
After the removal of the `balance` line in payment terms in 16.2, the behavior was not the same as it was before when using a fixed line. Example: $ 1000 | Amount | Type | Example Value | | ------ | ------- | ------------- | | 50 | Percent | $ 475 | | 50 | Fixed | $ 50 | | 50 | Percent | $ 475 | We used to remove the fixed lines, then split the remaining amount according to the percentages, and finally insert the fixed lines again. Since this behavior is both different than before (where we had a balance line) and not clear to the user, we changed it so that the last line in a payment term (no matter the type) is behaving as a balance line. After this fix, our example looks as follows. Example: $ 1000 | Amount | Type | Example Value | | ------ | ------- | ------------- | | 50 | Percent | $ 500 | | 50 | Fixed | $ 50 | | 50 | Percent | $ 450 | [task-3270971](https://www.odoo.com/web#id=3270971&cids=1&menu_id=4720&action=4043&model=project.task&view_type=form) --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#121505
This update replaces custom styling that prevented text selection with a standard shared class across many Odoo apps. It keeps the user experience consistent while simplifying future maintenance, with no expected change to business workflows.
Original PR description
[REF] *: `user-select-none` refactoring
*{
base,
calendar,
crm,
event,
fleet,
hr_contract,
hr_holiday,
hr_recruitment,
hr_work_entry,
mail,
maintenance,
mass_mailing,
mrp,
note,
portal,
project,
stock,
survey,
utm,
web,
web_editor,
website,
website_event,
website_event_exhibitor,
website_event_meet,
website_event_track,
website_event_track_quiz,
website_forum,
website_profile,
website_sale,
website_slides
}
This PR deletes every CSS assignation in Odoo of `user-select: none`
and replaces it by a newly added BS5 `user-select-none` class either in
its template, JS component, controller or renderer.
Enterprise:
- https://github.com/odoo/enterprise/pull/27160
task-2848355
--
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-prThis update standardizes how Odoo prevents text selection in many interface elements by using a shared styling class instead of repeated custom rules. It should not change business workflows, but it makes the interface code easier to maintain and more consistent across apps.
Original PR description
[REF] *: `user-select-none` refactoring
*{
account_accountant,
account_consolidation,
account_followup,
account_intrastat,
account_reports,
appointments,
approvals,
documents,
documents_spreadsheet,
helpdesk,
hr_appraisal,
hr_payroll,
industry_fsm_report,
industry_fsm_sale,
mrp_mps,
mrp_plm,
planning,
sale_subscription_dashboard,
sign,
social,
social_crm,
social_facebook,
social_linkedin,
social_push_notifications,
social_twitter,
spreadsheet,
web_cohort,
web_dashboard,
web_enterprise,
web_gantt,
web_studio,
website_helpdesk
}
This PR deletes every CSS assignation in Odoo of `user-select: none`
and replaces it by a newly added BS5 `user-select-none` class either in
its template, JS component, controller or renderer.
Community:
- https://github.com/odoo/odoo/pull/90931
task-2848355- (rounded) buttons in header - header buttons keep grayscale filter regardless of active - search bar is rounded - section in emoji content show the icon and the name of category - less dark color in dark mode Before / After (white) <img width="343" alt="before-white" src="https://github.com/odoo/odoo/assets/6569390/332b32d7-281a-4203-a689-7253e8c840ec"> <img width="338" alt="after-white" src="https://github.com/odoo/odoo/assets/6569390/af55c304-f9c9-49c0-8d25-c17585223d3d"> Before /
Original PR description
- (rounded) buttons in header - header buttons keep grayscale filter regardless of active - search bar is rounded - section in emoji content show the icon and the name of category - less dark color in dark mode Before / After (white) <img width="343" alt="before-white" src="https://github.com/odoo/odoo/assets/6569390/332b32d7-281a-4203-a689-7253e8c840ec"> <img width="338" alt="after-white" src="https://github.com/odoo/odoo/assets/6569390/af55c304-f9c9-49c0-8d25-c17585223d3d"> Before / After (dark) <img width="347" alt="before-dark" src="https://github.com/odoo/odoo/assets/6569390/55c9b113-5599-4bc4-800c-eb450981579c"> <img width="342" alt="after-dark" src="https://github.com/odoo/odoo/assets/6569390/8fc47cc1-a4d2-480c-bad3-c0dd2e21cd4a"> Forward-Port-Of: odoo/odoo#122338
qty_received_method is not recomputed if the product type change, and can lead to issues on existing purchases when trying to generate a Vendor Bill. https://watch.screencastify.com/v/xMquB4CYJ1tQDivFQj7c # HOW TO REPRODUCE: - Create product P, type: Service, Control Policy: 'On Received Qty' - Create PO for 1 unit of P (do not confirm) - Update type of P to Storable - Confirm PO, Receive Products => Qty Received is 0, not able to generate Bill --- OPW-3245210 Forward-Port-Of: o
Original PR description
qty_received_method is not recomputed if the product type change, and can lead to issues on existing purchases when trying to generate a Vendor Bill. https://watch.screencastify.com/v/xMquB4CYJ1tQDivFQj7c # HOW TO REPRODUCE: - Create product P, type: Service, Control Policy: 'On Received Qty' - Create PO for 1 unit of P (do not confirm) - Update type of P to Storable - Confirm PO, Receive Products => Qty Received is 0, not able to generate Bill --- OPW-3245210 Forward-Port-Of: odoo/odoo#122199 Forward-Port-Of: odoo/odoo#119622
Steps to reproduce: - activate qr-code - create a contact with a valid account and activate "send money" - create a bill for this customer - register the payment - view the payment Issue: The QR-code is displayed as plain text Cause: The commit https://github.com/odoo-dev/odoo/commit/688986f888f2fe2371d58b74ded81315ba6bb353 deleted the use of markup and the field qr_code is still as char and cannot be Markup'ed by the ORM opw-3293289 Forward-Port-Of: odoo/odoo#122306
Original PR description
Steps to reproduce: - activate qr-code - create a contact with a valid account and activate "send money" - create a bill for this customer - register the payment - view the payment Issue: The QR-code is displayed as plain text Cause: The commit https://github.com/odoo-dev/odoo/commit/688986f888f2fe2371d58b74ded81315ba6bb353 deleted the use of markup and the field qr_code is still as char and cannot be Markup'ed by the ORM opw-3293289 Forward-Port-Of: odoo/odoo#122306
When user enters empty space in name field instead of entering an actual name and confirm their billing, shipping address then when they click on paynow to confirm order they will face the issue 'list index out of range'. Note : Do the paypal configuration in 'payment providers' before following below steps. Steps to produce: 1) Vist the website as a public user. 2) Create a sale order by adding some products to the cart. 3) While entering shipping and billing address, in the name f
Original PR description
When user enters empty space in name field instead of entering an actual name and confirm their billing, shipping address then when they click on paynow to confirm order they will face the issue…
When user enters empty space in name field instead of entering an actual name and
confirm their billing, shipping address then when they click on paynow to confirm
order they will face the issue 'list index out of range'.
Note : Do the paypal configuration in 'payment providers' before following below steps.
Steps to produce:
1) Vist the website as a public user.
2) Create a sale order by adding some products to the cart.
3) While entering shipping and billing address, in the name field enter some space.
4) Click on next button.
5) Now a sale order is created.
6) Go to orders through 'website' module.
7) Open the order created and generate a payment link.
8) Paste that payment link in another tab or browser .
9) Click on pay
By following above steps you will encounter the error.
```
Traceback (most recent call last):
File "/home/odoo/odoo/odoo/odoo/http.py", line 1987, in call
response = request._serve_db()
File "/home/odoo/odoo/odoo/odoo/http.py", line 1583, in _serve_db
return service_model.retrying(self._serve_ir_http, self.env)
File "/home/odoo/odoo/odoo/odoo/service/model.py", line 134, in retrying
result = func()
File "/home/odoo/odoo/odoo/odoo/http.py", line 1610, in _serve_ir_http
response = self.dispatcher.dispatch(rule.endpoint, args)
File "/home/odoo/odoo/odoo/odoo/http.py", line 1807, in dispatch
result = self.request.registry['ir.http']._dispatch(endpoint)
File "/home/odoo/odoo/odoo/addons/website/models/ir_http.py", line 235, in _dispatch
response = super()._dispatch(endpoint)
File "/home/odoo/odoo/odoo/odoo/addons/base/models/ir_http.py", line 154, in _dispatch
result = endpoint(request.params)
File "/home/odoo/odoo/odoo/odoo/http.py", line 696, in route_wrapper
result = endpoint(self, *args, params_ok)
File "/home/odoo/odoo/odoo/addons/payment/controllers/portal.py", line 246, in payment_transaction
return tx_sudo._get_processing_values()
File "/home/odoo/odoo/odoo/addons/payment/models/payment_transaction.py", line 457, in _get_processing_values
rendering_values = self._get_specific_rendering_values(processing_values)
File "/home/odoo/odoo/odoo/addons/payment_paypal/models/payment_transaction.py", line 38, in _get_specific_rendering_values
partner_first_name, partner_last_name = payment_utils.split_partner_name(self.partner_name)
File "/home/odoo/odoo/odoo/addons/payment/utils.py", line 148, in split_partner_name
return " ".join(partner_name.split()[:-1]), partner_name.split()[-1]
IndexError: list index out of range
```
This commit will prevent the above error.
sentry - 4177783431
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#122229Description 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#122441
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#122441
Before this commit, attachment cards overflow in chat window when attachment name is very long. Text is properly flagged for truncate, but the container had neither `overflow-auto` or `min-width: 0` to allow flex to shrink below its content size. Also add some horizontal spacing in attachment list so the attachment cards do not have any contact with composer border. Before / After <img width="347" alt="before" src="https://github.com/odoo/odoo/assets/6569390/58e33f79-a989-4ac1-a41f-167
Original PR description
Before this commit, attachment cards overflow in chat window when attachment name is very long. Text is properly flagged for truncate, but the container had neither `overflow-auto` or `min-width: 0` to allow flex to shrink below its content size. Also add some horizontal spacing in attachment list so the attachment cards do not have any contact with composer border. Before / After <img width="347" alt="before" src="https://github.com/odoo/odoo/assets/6569390/58e33f79-a989-4ac1-a41f-1675a3e99c12"> <img width="337" alt="after" src="https://github.com/odoo/odoo/assets/6569390/6a172789-aac0-46aa-8de1-e2ea726d3bd7"> Forward-Port-Of: odoo/odoo#122497
Forward-Port-Of: odoo/odoo#122303
Original PR description
Forward-Port-Of: odoo/odoo#122303
Since #121268 it was discovered in the nightly builds, when all tests are done in a single build, that at_install tests were re-run during the post_install tests ... After some investigations, it was found that some routes were called before the start of a test method and that the registry was not in test mode at that time. In this case, in `TestWebsiteLinksRussian` , when creating a `link.tracker` during the setUpClass, a call to `_get_title_from_url`, causing an invalidation of the regi
Original PR description
Since #121268 it was discovered in the nightly builds, when all tests are done in a single build, that at_install tests were re-run during the post_install tests ... After some investigations, it was found that some routes were called before the start of a test method and that the registry was not in test mode at that time. In this case, in `TestWebsiteLinksRussian` , when creating a `link.tracker` during the setUpClass, a call to `_get_title_from_url`, causing an invalidation of the registry while not in test mode. Incidentally it was found that TestMailRenderMixin was not an HttpCase while the call to Forward-Port-Of: odoo/odoo#122482
Since _search return a query object, we cannot slice it. So we listify it. Thanks to XMO and RYV for their very valuable input. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#122495
Original PR description
Since _search return a query object, we cannot slice it. So we listify it. Thanks to XMO and RYV for their very valuable input. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#122495
With this commit, we improve the usability of foreign bank transactions. When capturing a new bank transaction (account.bank.statement.line) - when capturing a new transaction we compute the amount currency based on the transaction date, amount in journal/company currency, and foreign currency - when the foreign currency is removed, the amount_currency is cleared Task-3338560 Task-3338532 Description of the issue/feature this PR addresses: Current behavior before PR: Desired behav
Original PR description
With this commit, we improve the usability of foreign bank transactions. When capturing a new bank transaction (account.bank.statement.line) - when capturing a new transaction we compute the amount currency based on the transaction date, amount in journal/company currency, and foreign currency - when the foreign currency is removed, the amount_currency is cleared Task-3338560 Task-3338532 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#122499
This PR brings in several fixes and improvements (details can be checked in each separate commit). All of these have been grouped in the same PR as a follow-up of https://github.com/odoo/odoo/pull/112171 and target the same version to avoid ending up with different implementations and behaviors. - a fix related to a change in list views to allow tabbing between date ranges that did not account for semantically-incorrect dropdown buttons; - the removal of the keyboard navigation in datetime p
Original PR description
This PR brings in several fixes and improvements (details can be checked in each separate commit). All of these have been grouped in the same PR as a follow-up of…
This PR brings in several fixes and improvements (details can be checked in each separate commit). All of these have been grouped in the same PR as a follow-up of https://github.com/odoo/odoo/pull/112171 and target the same version to avoid ending up with different implementations and behaviors. - a fix related to a change in list views to allow tabbing between date ranges that did not account for semantically-incorrect dropdown buttons; - the removal of the keyboard navigation in datetime pickers; - the removal of a mistakenly introduced local date comparison method in date utilities; - a fix to open datetime pickers on click instead of focus ([3323594](https://www.odoo.com/web#id=3323594&cids=1&menu_id=4720&action=333&active_id=133&model=project.task&view_type=form)); - better visual cues when selecting dates in datetime pickers: * Before:  * After:  --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#121145
Steps to reproduce: - Install fleet - Switch to mobile view - Create new vehicle - Click on model field > Select a model Issue: Clicking on a car model does not perform any action. Solution: Add class `oe_kanban_global_click` to kanban items in order to capture user clicks. opw-3188104 Forward-Port-Of: odoo/odoo#122380 Forward-Port-Of: odoo/odoo#121148
Original PR description
Steps to reproduce: - Install fleet - Switch to mobile view - Create new vehicle - Click on model field > Select a model Issue: Clicking on a car model does not perform any action. Solution: Add class `oe_kanban_global_click` to kanban items in order to capture user clicks. opw-3188104 Forward-Port-Of: odoo/odoo#122380 Forward-Port-Of: odoo/odoo#121148
During the refactoring of discuss in 16.3, the setting to filter the videos was wrongly observed on the settings instead of the channel. This commit fixes this issue. Forward-Port-Of: odoo/odoo#122593
Original PR description
During the refactoring of discuss in 16.3, the setting to filter the videos was wrongly observed on the settings instead of the channel. This commit fixes this issue. Forward-Port-Of: odoo/odoo#122593
Since MILK, the `bg-*` classes which used to set an appropriate text color have turned into `text-bg-*`. Some were missed which resulted in elements with low contrast between the text and the background. This commit fixes this issue. Forward-Port-Of: odoo/odoo#122594
Original PR description
Since MILK, the `bg-*` classes which used to set an appropriate text color have turned into `text-bg-*`. Some were missed which resulted in elements with low contrast between the text and the background. This commit fixes this issue. Forward-Port-Of: odoo/odoo#122594
The discuss app uses an url regex in order to find links and transform them to html before posting a message. Before this commit, some unsafe url characters were missing from this regex, resulting in incorrectly parsed url. This commit adds missing characters in order to match RFC1738 [1]. However the dot, comma and semicolon character won't be matched if they are at the end of the url since those can be used as punctuation. [1]: https://www.ietf.org/rfc/rfc1738.txt Forward-
Original PR description
The discuss app uses an url regex in order to find links and transform them to html before posting a message. Before this commit, some unsafe url characters were missing from this regex, resulting in incorrectly parsed url. This commit adds missing characters in order to match RFC1738 [1]. However the dot, comma and semicolon character won't be matched if they are at the end of the url since those can be used as punctuation. [1]: https://www.ietf.org/rfc/rfc1738.txt Forward-Port-Of: https://github.com/odoo/odoo/commit/0dc68dcc94ab9bb2e47943967fa2bc31780d20fa, https://github.com/odoo/odoo/commit/9302a237c584442f28cd6faea31a0774fa979058 Forward-Port-Of: odoo/odoo#122473 Forward-Port-Of: odoo/odoo#122427
Record `res.partner` may have empty name if it's an address record for a regular partner [1]. This may lead to error `sequence item 0: expected str instance, bool found` on computing `display_messages`. Fix it by using `display_name` [2] [1]: https://github.com/odoo/odoo/blob/c3209aec9741cda8597525add88b0a932fb7532a/odoo/addons/base/models/res_partner.py#L295 [2]: https://github.com/odoo/odoo/blob/b2f648fb3e3632e51123336850fd6ea1280925fe/odoo/addons/base/models/res_partner.py#L804-L833
Original PR description
Record `res.partner` may have empty name if it's an address record for a regular partner [1]. This may lead to error `sequence item 0: expected str instance, bool found` on computing `display_messages`. Fix it by using `display_name` [2] [1]: https://github.com/odoo/odoo/blob/c3209aec9741cda8597525add88b0a932fb7532a/odoo/addons/base/models/res_partner.py#L295 [2]: https://github.com/odoo/odoo/blob/b2f648fb3e3632e51123336850fd6ea1280925fe/odoo/addons/base/models/res_partner.py#L804-L833 https://online.sentry.io/issues/4183834755 Forward-Port-Of: odoo/odoo#121830
Current behaviour: -- When activating "Prevent Sale of Zero Priced Product", zero priced products could still be added to cart, using the wishlist. Expected behaviour: -- Zero priced products should not be added to cart Steps to reproduce: -- 1. Activate the setting "Prevent Sale of Zero Priced Product" 2. Create a product with a sales price of zero 3. Go on the product selling page, cannot be added to cart 4. Add the product to your wishlist 5. Go in the wishlist 6. The produ
Original PR description
Current behaviour: -- When activating "Prevent Sale of Zero Priced Product", zero priced products could still be added to cart, using the wishlist. Expected behaviour: -- Zero priced products should not be added to cart Steps to reproduce: -- 1. Activate the setting "Prevent Sale of Zero Priced Product" 2. Create a product with a sales price of zero 3. Go on the product selling page, cannot be added to cart 4. Add the product to your wishlist 5. Go in the wishlist 6. The product can be added to the cart Cause of the issue: -- add_to_cart_button was overriden Fix: -- Added condition on override opw-3283057 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#121531
Since commit [1], the state of the editor in the html field is only set to dirty when the user triggers an input event. This means that if the user uses the mouse to change the content of the field (eg, drag and dropping snippets), the editor is not marked as dirty so the save button will not appear and autosave will not work. This commit fixes this by checking the editor's dirty state whenever a history step event is triggered. Since this reverts commit [1], we need to ensure the bug it fixe
Original PR description
Since commit [1], the state of the editor in the html field is only set to dirty when the user triggers an input event. This means that if the user uses the mouse to change the content of the field…
Since commit [1], the state of the editor in the html field is only set to dirty when the user triggers an input event. This means that if the user uses the mouse to change the content of the field (eg, drag and dropping snippets), the editor is not marked as dirty so the save button will not appear and autosave will not work. This commit fixes this by checking the editor's dirty state whenever a history step event is triggered. Since this reverts commit [1], we need to ensure the bug it fixed does not reappear. This is done by ensuring we don't check the saved value against the modified editing value when it's empty (namely, the editor doesn't allow an empty string as a value and replaces it with `<p><br></p>`, which we need to undo in `_isDirty`). task-3263653 task-3288416 opw-3274329 [1]: https://github.com/odoo/odoo/pull/113088/commits/095bbb93d6c3b9b0b099b7ed1a6a15e8ad914e9f --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#121915 Forward-Port-Of: odoo/odoo#120593
task-3331827 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#121907
Original PR description
task-3331827 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#121907
Description of the issue/feature this PR addresses: - Purchase Agreement don't send user_id to RFQ. It should be default user_id from purchase agreement to RFQ. Reference: https://github.com/odoo/odoo/pull/46792 Current behavior before PR: - Create Purchase Agreement and select `Purchase Representative` - Click `New Quotation` for create new RFQ. - In RFQ, Purchase Representative has False value Desired behavior after PR is merged: - In RFQ, Purchase Representative has default followi
Original PR description
Description of the issue/feature this PR addresses: - Purchase Agreement don't send user_id to RFQ. It should be default user_id from purchase agreement to RFQ. Reference: https://github.com/odoo/odoo/pull/46792 Current behavior before PR: - Create Purchase Agreement and select `Purchase Representative` - Click `New Quotation` for create new RFQ. - In RFQ, Purchase Representative has False value Desired behavior after PR is merged: - In RFQ, Purchase Representative has default following Purchase Agreement --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#120219
It takes 70s to generate a receipt with 2000 serial numbers. It happens because during the loop after the `stock.move.line` in the `create`. It will update the initial demand of the move based on the new stock.move.line values (and their qty_done). Writing the initial demand of the moves will try to reassign the `stock.move` (useless in our case). But it will invalidate the state of the `stock.move.line` because it's a related and `_action_assign` write on it. So at each loop he write t
Original PR description
It takes 70s to generate a receipt with 2000 serial numbers. It happens because during the loop after the `stock.move.line` in the `create`. It will update the initial demand of the move based on the…
It takes 70s to generate a receipt with 2000 serial numbers. It happens because during the loop after the `stock.move.line` in the `create`. It will update the initial demand of the move based on the new stock.move.line values (and their qty_done). Writing the initial demand of the moves will try to reassign the `stock.move` (useless in our case). But it will invalidate the state of the `stock.move.line` because it's a related and `_action_assign` write on it. So at each loop he write the same info and he recompute the state. That make the process very slow. We fix it by writing only once the information by move. And it prevent the recompute later since the state is not write during the loop. Before the patch (70s)   After the patch (1.62s)  Forward-Port-Of: odoo/odoo#122405 Forward-Port-Of: odoo/odoo#121919
- Add group bys, columns, and filters to Bank Reconciliation models for better navigation and organization - Trigger auto-validate cron on saving Reconciliation model with auto-validate enabled - Restore pre-filled elements when creating Reconciliation model through bank reconciliation widget (V15.2 functionality) - Remove text ellipsis from Reconciliation model buttons in bank reconciliation widget for better readability Task-id: 3253304 Enterprise-PR: https://github.com/odoo/enterp
Original PR description
- Add group bys, columns, and filters to Bank Reconciliation models for better navigation and organization - Trigger auto-validate cron on saving Reconciliation model with auto-validate enabled - Restore pre-filled elements when creating Reconciliation model through bank reconciliation widget (V15.2 functionality) - Remove text ellipsis from Reconciliation model buttons in bank reconciliation widget for better readability Task-id: 3253304 Enterprise-PR: https://github.com/odoo/enterprise/pull/39393 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#117822
**Description of the issue/feature this PR addresses:** There are missing translations in fr.po file of these terms: - msgid "Invoicing and Shipping Address:" - msgid "Shipping Address:" - msgid "Invoicing Address:" Steps to reproduce: - Set report layout to DIN5008 - Activate French language - Have a customer A with language set to French - Create invoice to A - Print invoice - Some terms in the document are left in English **Current behavior before PR:** If you print I
Original PR description
**Description of the issue/feature this PR addresses:** There are missing translations in fr.po file of these terms: - msgid "Invoicing and Shipping Address:" - msgid "Shipping Address:" - msgid "Invoicing Address:" Steps to reproduce: - Set report layout to DIN5008 - Activate French language - Have a customer A with language set to French - Create invoice to A - Print invoice - Some terms in the document are left in English **Current behavior before PR:** If you print Invoice in French, some terms are in English. **Desired behavior after PR is merged:** Missing terms in french Invoice will be translated. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#120331
ZeroDivsionError: float division to Zero is generated because for assigning value to 'factor' of uom in method '_set_ratio', it tries to divide value by Zero for uom_type 'Bigger'. ``` ZeroDivisionError: float division by zero File "odoo/http.py", line 2115, in __call__ response = request._serve_db() File "odoo/http.py", line 1698, in _serve_db return service_model.retrying(self._serve_ir_http, self.env) File "odoo/service/model.py", line 134, in retrying result = fun
Original PR description
ZeroDivsionError: float division to Zero is generated because for assigning value to 'factor' of uom in method '_set_ratio', it tries to divide value by Zero for uom_type 'Bigger'. ```…
ZeroDivsionError: float division to Zero is generated because for assigning value to 'factor' of uom in method '_set_ratio', it tries to divide value by Zero for uom_type 'Bigger'.
```
ZeroDivisionError: float division by zero
File "odoo/http.py", line 2115, in __call__
response = request._serve_db()
File "odoo/http.py", line 1698, in _serve_db
return service_model.retrying(self._serve_ir_http, self.env)
File "odoo/service/model.py", line 134, in retrying
result = func()
File "odoo/http.py", line 1725, in _serve_ir_http
response = self.dispatcher.dispatch(rule.endpoint, args)
File "odoo/http.py", line 1922, in dispatch
result = self.request.registry['ir.http']._dispatch(endpoint)
File "addons/website/models/ir_http.py", line 234, in _dispatch
response = super()._dispatch(endpoint)
File "odoo/addons/base/models/ir_http.py", line 154, in _dispatch
result = endpoint(**request.params)
File "odoo/http.py", line 715, in route_wrapper
result = endpoint(self, *args, **params_ok)
File "addons/web/controllers/dataset.py", line 28, in call_kw
return self._call_kw(model, method, args, kwargs)
File "addons/web/controllers/dataset.py", line 24, in _call_kw
return call_kw(request.env[model], method, args, kwargs)
File "odoo/api.py", line 461, in call_kw
result = _call_kw_multi(method, model, args, kwargs)
File "odoo/api.py", line 448, in _call_kw_multi
result = method(recs, *args, **kwargs)
File "odoo/models.py", line 3825, in write
field.write(self, value)
File "odoo/fields.py", line 4169, in write
self.write_batch([(records, value)])
File "odoo/fields.py", line 4190, in write_batch
self.write_real(records_commands_list, create)
File "odoo/fields.py", line 4370, in write_real
flush()
File "odoo/fields.py", line 4326, in flush
comodel.create(to_create)
File "<decorator-gen-163>", line 2, in create
File "odoo/api.py", line 410, in _model_create_multi
return create(self, arg)
File "addons/uom/models/uom_uom.py", line 154, in create
res = super(UoM, self).create(vals_list)
File "<decorator-gen-10>", line 2, in create
File "odoo/api.py", line 410, in _model_create_multi
return create(self, arg)
File "odoo/models.py", line 4054, in create
next(iter(fields)).determine_inverse(batch_recs)
File "odoo/fields.py", line 1377, in determine_inverse
determine(self.inverse, records)
File "odoo/fields.py", line 99, in determine
return needle(*args)
File "addons/uom/models/uom_uom.py", line 114, in _set_ratio
self.factor = 1 / self.ratio
```
Steps to reproduce:
1) Install 'Inventory' module.
2) Click on 'Configuration' > 'Settings'.
3) Activate 'Units of Measure' > click on 'Units of Measure' button under it.
4) Click on 'Create' button to create new uom category.
5) Give any name > in 'Units of Measure' page, click on 'Add a line'.
6) Enter name and select type as 'Reference unit of measure for this category'.
7) Now, add another line and select type as 'Bigger than the the Reference unit
of measure' and set the 'ratio' value to Zero, Error will be generated.
By applying this,it will check for the value of 'ratio' to prevent division by 0
sentry - 4174584503
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#122333
Forward-Port-Of: odoo/odoo#121409before this commit, on changing the product from bom is not clearing the product variant field, if the product variant feature is not activated in the database. * activate the product variant in the db * create a product and variants * open bill of material, and set the created product as product and set any variant in product variant field * now go to settings and disable product variant feature * come back to same bom and change the product * the product variant field will still have
Original PR description
before this commit, on changing the product from bom is not clearing the product variant field, if the product variant feature is not activated in the database. * activate the product variant in the…
before this commit, on changing the product from bom is not clearing the product variant field, if the product variant feature is not activated in the database. * activate the product variant in the db * create a product and variants * open bill of material, and set the created product as product and set any variant in product variant field * now go to settings and disable product variant feature * come back to same bom and change the product * the product variant field will still have the other product onchange_product_tmpl_id is written to clear the product variant field value, but as the product variant field has group the onchange value is not getting updated. after this commit, on changing the product the product variant field will get cleared even if the product variant feature is not activated. close: https://github.com/odoo/odoo/issues/121754 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#121859
The uom should be editable on new lines, independently of their state. With this commit, users will be able to change the uom on new lines of locked/cancelled/confirmed orders. Forward-Port-Of: odoo/odoo#122537 Forward-Port-Of: odoo/odoo#122246
Original PR description
The uom should be editable on new lines, independently of their state. With this commit, users will be able to change the uom on new lines of locked/cancelled/confirmed orders. Forward-Port-Of: odoo/odoo#122537 Forward-Port-Of: odoo/odoo#122246
=== ISSUE === With the new Milk design, we introduced `.border-radius` on buttons. Most of the time the render looks great, but in some cases, it would break the layout. This is due to the fact that old design sometimes used two buttons next to each other. This worked fine because they did not have any radius but now it looks like they are compressed and squished. Website's buttons were a bit specific so biggest changes happen here. **Before :**  **After :**  === AFTER === This commit tracks some of these cases to improve the global render of these buttons. - Requires : https://github.com/odoo/enterprise/pull/41260 task-3329612 part of task-332626 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#121599
- rounded avatar in member list and invitation link - improved color in selectable users in invitation link - show "Add Users" action in DM chat window - no border on panels in chat windows - slight header style adjusments on emoji picker - improved borders on chat window (shared between content and header) Before:   Before:   After:   --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#122516
- create an invoice with a CABA tax - full refund it using 'add credit note', 'cancel' mode. => No CABA entry generated but an exchange difference journal entry has been created. This is because the CABA entry is not generated in case of full refund thanks to the 'move_reverse_cancel' context key. However, this key is not preventing the generation of the exchange journal entry for CABA. opw-3321897 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-p
Original PR description
- create an invoice with a CABA tax - full refund it using 'add credit note', 'cancel' mode. => No CABA entry generated but an exchange difference journal entry has been created. This is because the CABA entry is not generated in case of full refund thanks to the 'move_reverse_cancel' context key. However, this key is not preventing the generation of the exchange journal entry for CABA. opw-3321897 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#122586 Forward-Port-Of: odoo/odoo#121597
This commit fixes the issue of having duplicate iframes when dropping a custom "s_map" snippet that has been saved by the user. This issue was introduced by this commit [1]. Steps to reproduce the bug: - Drag and drop a "s_map" snippet onto the page. - Save this "s_map" snippet by clicking on the custom snippet "save" button. - Drag and drop the saved snippet onto the page. - Observe that a duplicate iframe is created in the snippet. This commit adds a check to verify if an iframe a
Original PR description
This commit fixes the issue of having duplicate iframes when dropping a custom "s_map" snippet that has been saved by the user. This issue was introduced by this commit [1]. Steps to reproduce the bug: - Drag and drop a "s_map" snippet onto the page. - Save this "s_map" snippet by clicking on the custom snippet "save" button. - Drag and drop the saved snippet onto the page. - Observe that a duplicate iframe is created in the snippet. This commit adds a check to verify if an iframe already exists before adding it when dropping a "s_map" snippet. [1]: https://github.com/odoo/odoo/commit/88194dd94182ad1bbdcb9aa8f855f30f6369d148 task-3340644 Forward-Port-Of: odoo/odoo#122645
Since [this other commit], a traceback is displayed when the user wants to see the pages of his site when he has only one site. Steps to reproduce the bug fixed by this commit: - Launch Odoo without any app installed and without demo data - Connect to the DB - Activate the Website module - Skip the configurator - Choose a theme - Discard edit mode - Go to Site > Pages - Go to kanban view => An error is displayed because the record has no website_id. [this other commit]: https://git
Original PR description
Since [this other commit], a traceback is displayed when the user wants to see the pages of his site when he has only one site. Steps to reproduce the bug fixed by this commit: - Launch Odoo without any app installed and without demo data - Connect to the DB - Activate the Website module - Skip the configurator - Choose a theme - Discard edit mode - Go to Site > Pages - Go to kanban view => An error is displayed because the record has no website_id. [this other commit]: https://github.com/odoo/odoo/commit/f23399db1dfb816a68ecf1be4367234b6e9a28bc task-3316267 Forward-Port-Of: odoo/odoo#121016
Before this commit, the grid row height has been set to be automatically computed by the browser (the grid-template-rows property value was set to "auto"). While this is a more maintainable approach, it messes up with the virtual hook (`@web/core/virtual_hook`) which needs to know the exact height of each row. This commit ensures that the grid renderer uses its hard-coded row height in its grid layout. Part of task [3336233](https://www.odoo.com/web#id=3336233&cids=1&menu_id=4720&action=33
Original PR description
Before this commit, the grid row height has been set to be automatically computed by the browser (the grid-template-rows property value was set to "auto"). While this is a more maintainable approach, it messes up with the virtual hook (`@web/core/virtual_hook`) which needs to know the exact height of each row. This commit ensures that the grid renderer uses its hard-coded row height in its grid layout. Part of task [3336233](https://www.odoo.com/web#id=3336233&cids=1&menu_id=4720&action=333&active_id=133&model=project.task&view_type=form) Forward-Port-Of: odoo/enterprise#41291
=== ISSUE === With the new Milk design, we introduced `.border-radius` on buttons. Most of the time the render looks great, but in some cases, it would break the layout. This is due to the fact that old design sometimes used two buttons next to each other. This worked fine because they did not have any radius but now it looks like they are compressed and squished. === AFTER === This commit tracks some of these cases to improve the global render of these buttons. - Requires : ht
Original PR description
=== ISSUE === With the new Milk design, we introduced `.border-radius` on buttons. Most of the time the render looks great, but in some cases, it would break the layout. This is due to the fact that old design sometimes used two buttons next to each other. This worked fine because they did not have any radius but now it looks like they are compressed and squished. === AFTER === This commit tracks some of these cases to improve the global render of these buttons. - Requires : https://github.com/odoo/odoo/pull/121599 task-3329612 part of task-332626 Forward-Port-Of: odoo/enterprise#41260
[FIX] account_accountant: Exclude off_balance account from bank reco [FIX] account_accountant: Fix phantom exchange diff line in bank rec widget - Create a bank transaction of 3000 in company currency (make sure the rate is 3:1 at this date). - Create an invoice line of 2000 using a foreign currency with a 2:1 rate. - Mount the invoice line into the widget => an exchange diff of 1000 has been created. - Remove the invoice line => An open balance line is computed with 2000 instead of 30
Original PR description
[FIX] account_accountant: Exclude off_balance account from bank reco [FIX] account_accountant: Fix phantom exchange diff line in bank rec widget - Create a bank transaction of 3000 in company…
[FIX] account_accountant: Exclude off_balance account from bank reco [FIX] account_accountant: Fix phantom exchange diff line in bank rec widget - Create a bank transaction of 3000 in company currency (make sure the rate is 3:1 at this date). - Create an invoice line of 2000 using a foreign currency with a 2:1 rate. - Mount the invoice line into the widget => an exchange diff of 1000 has been created. - Remove the invoice line => An open balance line is computed with 2000 instead of 3000. When removing a 'new_aml' line in a multi-currency environment, the exchange difference line wasn't removed so the open balance is computed by considering the exchange difference line (here 2000). When computing lines_widget, the exchange diff are re-order to be added right after the targeted aml. Since this line no longer exists, the exchange diff is not added and then, wasn't part of the final results. So, the results was only an open balance with a wrong amount. task: 3336436 Forward-Port-Of: odoo/enterprise#41346
Add group bys, columns, and filters to Bank Reconciliation list view for better navigation and organization Trigger auto-validate cron on saving Reconciliation model with auto-validate enabled Restore pre-filled elements when creating Reconciliation model through bank reconciliation widget (V15.2 functionality) Remove text ellipsis from Reconciliation model buttons in bank reconciliation widget for better readability Task-id: 3253304 Community-PR: https://github.com/odoo/odoo/pull/117822
Original PR description
Add group bys, columns, and filters to Bank Reconciliation list view for better navigation and organization Trigger auto-validate cron on saving Reconciliation model with auto-validate enabled Restore pre-filled elements when creating Reconciliation model through bank reconciliation widget (V15.2 functionality) Remove text ellipsis from Reconciliation model buttons in bank reconciliation widget for better readability Task-id: 3253304 Community-PR: https://github.com/odoo/odoo/pull/117822 Forward-Port-Of: odoo/enterprise#39393
Steps to reproduce : - Create a Manufacturing Order with an operation - Start the operation with the current user - Log in another user and start the operation with him as well - Wait a little and finish the operation and close the MO - On the Cost Analysis report will be two line for this workcenter + operation, both containing the full duration of the operation. Following odoo/enterprise#23032, employee can be directly assigned to a workorder. This changed the purpose of the Cost Analy
Original PR description
Steps to reproduce : - Create a Manufacturing Order with an operation - Start the operation with the current user - Log in another user and start the operation with him as well - Wait a little and finish the operation and close the MO - On the Cost Analysis report will be two line for this workcenter + operation, both containing the full duration of the operation. Following odoo/enterprise#23032, employee can be directly assigned to a workorder. This changed the purpose of the Cost Analysis report a bit, since now it shows operation lines for the workcenter AND lines for their employee, to separate machine cost & labour cost. Since the purpose of this query is now to have the machine cost, there is little point of keeping the `group by` on the users in the query. This will result on having only a single ligne per (workcenter, operation). Forward-Port-Of: odoo/enterprise#41450 Forward-Port-Of: odoo/enterprise#40931
Error raised since we set context to wrong variable Forward-Port-Of: odoo/enterprise#41493
Original PR description
Error raised since we set context to wrong variable Forward-Port-Of: odoo/enterprise#41493
When creating a bank transaction (account.bank.statement.line), the user is able to choose the journal currency which then results in a user error. By adding a domain to the form and list views, we prevent the user from choosing the journal or company currency, thereby eliminating the user error. Task-3338517 Forward-Port-Of: odoo/enterprise#41503
Original PR description
When creating a bank transaction (account.bank.statement.line), the user is able to choose the journal currency which then results in a user error. By adding a domain to the form and list views, we prevent the user from choosing the journal or company currency, thereby eliminating the user error. Task-3338517 Forward-Port-Of: odoo/enterprise#41503
Forward-Port-Of: odoo/enterprise#41475
Original PR description
Forward-Port-Of: odoo/enterprise#41475
The text of the registration panel button was never translated. The _t() calls were missing. Forward-Port-Of: odoo/enterprise#41385
Original PR description
The text of the registration panel button was never translated. The _t() calls were missing. Forward-Port-Of: odoo/enterprise#41385
Somehow the letter "t" was added at the end of some strings, which is unnecessary. Test: - Go to Dashboards / Configuration / Dashboards - Go into Logistics - Edit the Manufacturing dashboard - Switch to "Data" sheet - Look the label fields in column A Forward-Port-Of: odoo/enterprise#41163
Original PR description
Somehow the letter "t" was added at the end of some strings, which is unnecessary. Test: - Go to Dashboards / Configuration / Dashboards - Go into Logistics - Edit the Manufacturing dashboard - Switch to "Data" sheet - Look the label fields in column A Forward-Port-Of: odoo/enterprise#41163
Upon changing/removing/adding the analytic account on a manufacturing order, the EMP AALs are not updated. To reproduce: - Create an MO with a workorder on a workcenter which requires login - Login as an employee with a hourly cost set and complete time on this workorder to generate the [EMP] AALs on this MO. - Change the analytic account on the MO (or delete it) Bug: The [EMP] AALs never get correctly updated. This fix corrects this behaviour and takes into account changes for the emp
Original PR description
Upon changing/removing/adding the analytic account on a manufacturing order, the EMP AALs are not updated. To reproduce: - Create an MO with a workorder on a workcenter which requires login - Login as an employee with a hourly cost set and complete time on this workorder to generate the [EMP] AALs on this MO. - Change the analytic account on the MO (or delete it) Bug: The [EMP] AALs never get correctly updated. This fix corrects this behaviour and takes into account changes for the employee cost AALs when the analytic_account of a manufacturing order is changed. Task: 3252742 Forward-Port-Of: odoo/enterprise#39108
Steps to reproduce: ------------------- - change the user's time zone to "Pacific/Auckland" (UTC +12); - go to Online Appointments; - create a slot on Monday from 9 am to 12 pm; - publish it; - go to the share link of the appointment type; - try to choose an appointment for 9 am; Remark: Set the browser timezone to "Pacific/Auckland". Issue: ------ The request will return a 404 error. Cause: ------ When comparing the slot chosen by the user and the slots available for the app
Original PR description
Steps to reproduce: ------------------- - change the user's time zone to "Pacific/Auckland" (UTC +12); - go to Online Appointments; - create a slot on Monday from 9 am to 12 pm; - publish it; - go to…
Steps to reproduce: ------------------- - change the user's time zone to "Pacific/Auckland" (UTC +12); - go to Online Appointments; - create a slot on Monday from 9 am to 12 pm; - publish it; - go to the share link of the appointment type; - try to choose an appointment for 9 am; Remark: Set the browser timezone to "Pacific/Auckland". Issue: ------ The request will return a 404 error. Cause: ------ When comparing the slot chosen by the user and the slots available for the appointment's staff user, we use the `weekday`. https://github.com/odoo/enterprise/blob/e97419a617f22fc71042061e5c0e0e1d96d50e43/appointment/models/calendar_appointment_type.py#L199-L205 Unfortunately, with a very large UTC offset, in some cases we change the day. The result is that we do not find any slots. Solution: --------- Recalculate all the slots and search in them if any correspond to the range the user has selected. opw-3267279 Forward-Port-Of: odoo/enterprise#41451 Forward-Port-Of: odoo/enterprise#40108