Tuesday, June 13, 2023
58 changes · master
Enhancements to existing features
This update makes wording in the sales reporting area more consistent. It helps users see clearer, more uniform labels without changing how the sales process works.
The web interface now better identifies when an image field has no content. This supports related enterprise improvements and helps ensure image-related behavior works more consistently for users.
Original PR description
This commit adds the isEmpty field descriptor to the image field. This is linked to the changes made in enterprise: https://github.com/odoo/enterprise/pull/40885 Task ID: 3259489
A new automated check verifies that the website setup flow receives correctly translated industry names through Odoo's online services. This helps prevent language-related issues from reaching users configuring a website in different languages.
Original PR description
This commit adds a test to check that the IAP languages work as expected for the website configurator. The test checks that the industries are translated (different than other languages). task-3343616
The Discuss app counter has been visually updated to better match the messaging menu badge. This creates a more consistent interface and helps users recognize notification counts more easily.
Original PR description
To match the visual of the messaging menu badge for its counter. https://github.com/odoo/odoo/pull/122946 Task-3345133
Odoo Studio form editing now shows form titles at a width that matches the standard form view, creating a more consistent editing experience. It also verifies that image placeholders appear correctly when adding image fields, helping users preview forms more reliably.
Original PR description
This commit adapts the width of the title to be coherent with the base one instead of being set arbitrarily to 400 px. It also tests out that the image placeholder is displayed in the edit form view of studio following changes in the linked PR in Odoo: https://github.com/odoo/odoo/pull/124668 Steps to reproduce: - go to any form view - open studio - add an image field - ensure the img placeholder is displayed and the title has the same size inside and outside studio. Task ID: 3259489
Chart side panels in spreadsheets were adjusted to stay aligned with recent spreadsheet interface changes. This helps ensure chart settings continue to display and behave correctly for users editing spreadsheet charts.
Original PR description
Adapt the xpaths of the chart side panels to the changes in o-spreadsheet. Task: 3271374
Resolved issues and error corrections
This fixes an issue where the website editor's cleanup process could accidentally affect page elements outside the area being edited. The change helps prevent unintended modifications to surrounding page structure, making editing safer and more reliable.
Original PR description
When sanitizing the content of the editor, we sometimes move up too far and sanitize nodes that are not in the editor. This adds the proper boundaries required to contain the sanitization. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Features or functions removed from Odoo
Publicly shared spreadsheet templates no longer show the “Try Odoo” advertisement. This keeps shared spreadsheets cleaner and avoids promotional content appearing to external viewers.
Original PR description
Description of the issue/feature this PR addresses: Removal of Ad 'Try Odoo' from spreadsheet template Current behavior before PR: The Ad is shown to public when sheet is shared Desired behavior after PR is merged: No Ad will be shown when sheet is shared in public Task-3347908 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Miscellaneous changes
When we create a survey and start a new session. If the session state is in progress and If the survey creater deletes a question and participant tries to answer the deleted question and submits it then participant will face the issue of 'False is not in list'. Watch this video to reproduce the error: https://bit.ly/41IPMYm This commit will raise an usererror if the survey creater tries to delete the question when the survey session is in progress. sentry-4113791861 Forward-Port-Of: o
Original PR description
When we create a survey and start a new session. If the session state is in progress and If the survey creater deletes a question and participant tries to answer the deleted question and submits it then participant will face the issue of 'False is not in list'. Watch this video to reproduce the error: https://bit.ly/41IPMYm This commit will raise an usererror if the survey creater tries to delete the question when the survey session is in progress. sentry-4113791861 Forward-Port-Of: odoo/odoo#124645 Forward-Port-Of: odoo/odoo#119943
This change corrects an internal accounting test reference that pointed to an account not defined in the shared test setup. It helps keep accounting test checks reliable, reducing the risk of false failures during development without changing customer-facing behavior.
Original PR description
Fix a reference to an account that is not defined in Common tests of accounting.
This update removes an old workaround in manufacturing work orders that was only needed because of a lower-level platform issue. With the platform issue fixed, quality-related work order behavior can rely on the standard process again, reducing the risk of inconsistent handling.
Original PR description
Companion of https://github.com/odoo/odoo/pull/124612
This fixes subscription and website sales dashboards so they use the updated sales report reference field. It keeps reports and dashboards correctly connected to sales and point-of-sale orders after the underlying reporting change.
Original PR description
The field `order_id` of `sale.report` has been modified to `order_reference` to allow `sale.report` to be linked to a `pos.order`. The change should also be repercuted in enterprise
Users can now move between document workspaces after deleting a task linked to a document. This prevents a missing record error and keeps document navigation working smoothly.
Original PR description
How to reproduce: 1. Link any document with a task. 2. Go to the task and then click on the 'documents' stat button. 3. Click on the document, then from the inspector panel on the right, click the related task. 4. Then delete the task, and now you are redirected back to the 'documents' 5. Click on the 'All' workspace. 6. You will get the 'missing record error'. Reason: We are trying to access the project from an already deleted task. After this commit: Now we can switch to other workspace, without any issue. task-3277089
Before this commit, if in the database there is a document with `data-last-history-steps` that contains a chain of history rather then the last id, the wysiwyg will not properly retrieve the last id. Subsequent call to _ensureCommonHistory will result in a conflict even when there is no conflict. task-3366800 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#124654
Original PR description
Before this commit, if in the database there is a document with `data-last-history-steps` that contains a chain of history rather then the last id, the wysiwyg will not properly retrieve the last id. Subsequent call to _ensureCommonHistory will result in a conflict even when there is no conflict. task-3366800 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#124654
The customer was having an issue where the live chat embed was unable to fetch the images for the typing animation and the chatbot avatar when using a live chat embed on an external site. Issue: The chatbot image and typing gif were being referenced with a relative URL instead of an absolute URL with the Odoo domain as the base. Solution: Pass the correct image src URL to the template and change the chatbot_is_typing.gif to also incorporate the Odoo server URL. This allows the images t
Original PR description
The customer was having an issue where the live chat embed was unable to fetch the images for the typing animation and the chatbot avatar when using a live chat embed on an external site. Issue: The chatbot image and typing gif were being referenced with a relative URL instead of an absolute URL with the Odoo domain as the base. Solution: Pass the correct image src URL to the template and change the chatbot_is_typing.gif to also incorporate the Odoo server URL. This allows the images to be properly retrieved from the Odoo server. opw-3271281 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#123982 Forward-Port-Of: odoo/odoo#123785
Improves the cash rounding visualization in the account move view. At the bottom right of the view, a widget displays the detail of taxes and the possible rounding must also be included in this display. This commit makes the 'Total' line always the total amount of the account move. There is no longer a 'Total Rounded' that is displayed when using cash rounding. Instead, a rounding line is added which is clearer for the user. The user also no longer needs to save the page to see the proper data o
Original PR description
Improves the cash rounding visualization in the account move view. At the bottom right of the view, a widget displays the detail of taxes and the possible rounding must also be included in this display. This commit makes the 'Total' line always the total amount of the account move. There is no longer a 'Total Rounded' that is displayed when using cash rounding. Instead, a rounding line is added which is clearer for the user. The user also no longer needs to save the page to see the proper data on this widget.
2 cash rounding strategy exist in Odoo. The new correct way to display data is the following: When using 'add_invoice_line':
- a rounding line is displayed at the tax details
When using 'biggest_tax':
- the biggest tax detail is incremented with the rounding amount
task-3333052
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#124561
Forward-Port-Of: odoo/odoo#122070When we create a journal and it gets one of the payment method's value as False and we input another payment method. it will give an error with the message - 'sequence item 0: expected str instance, bool found' Steps to Produce:- 1. Go to Accounting then configuration 2. Click on 'Journals' under Accounting 3. Create or click on exiting one 4. Input all required fields and select 'Type' as Cash or Bank 5. Delete value of one of either incoming payments or outgoing payments 6. Cli
Original PR description
When we create a journal and it gets one of the payment method's value as False and we input another payment method. it will give an error with the message - 'sequence item 0: expected str instance,…
When we create a journal and it gets one of the payment method's value as False and we input another payment method. it will give an error with the
message -
'sequence item 0: expected str instance, bool found'
Steps to Produce:-
1. Go to Accounting then configuration
2. Click on 'Journals' under Accounting
3. Create or click on exiting one
4. Input all required fields and select 'Type' as Cash or Bank
5. Delete value of one of either incoming payments or outgoing payments
6. Click on save
7. Remove name of one of the payment method and input other
Trace-back will be generated.
```
KeyError: <NewId origin=6>
File "odoo/api.py", line 958, in get
cache_value = field_cache[record._ids[0]]
CacheMiss: 'account.journal(<NewId origin=6>,).selected_payment_method_codes'
File "odoo/fields.py", line 1158, in __get__
value = env.cache.get(record, self)
File "odoo/api.py", line 965, in get
raise CacheMiss(record, field)
TypeError: sequence item 0: expected str instance, bool found
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 "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 6534, in onchange
todo = [
File "odoo/models.py", line 6537, in <listcomp>
if name not in done and snapshot0.has_changed(name)
File "odoo/models.py", line 6320, in has_changed
return self[name] != record[name]
File "odoo/models.py", line 5926, in __getitem__
return self._fields[key].__get__(self, type(self))
File "odoo/fields.py", line 1209, in __get__
self.compute_value(recs)
File "odoo/fields.py", line 1368, in compute_value
records._compute_field_value(self)
File "addons/mail/models/mail_thread.py", line 395, in _compute_field_value
return super()._compute_field_value(field)
File "odoo/models.py", line 4296, in _compute_field_value
fields.determine(field.compute, self)
File "odoo/fields.py", line 99, in determine
return needle(*args)
File "addons/account/models/account_journal.py", line 346, in _compute_selected_payment_method_codes
journal.selected_payment_method_codes = ',' + ','.join(codes) + ','
```
Applying these changes will resolve this issue.
sentry - 4060511885
Forward-Port-Of: odoo/odoo#119787In the website forum, we checked that the post content is not empty before posting a post or an answer. Before this commit, it was just a verification that the content is not an empty string. Users are also able to post an image and we want to allow them to create a post or an answer with only an image. This commit changes the verification to check if the content is empty or if it only contains images. Steps to reproduce the issue resolved by this commit: - Go to the website forum - C
Original PR description
In the website forum, we checked that the post content is not empty before posting a post or an answer. Before this commit, it was just a verification that the content is not an empty string. Users…
In the website forum, we checked that the post content is not empty before posting a post or an answer. Before this commit, it was just a verification that the content is not an empty string. Users are also able to post an image and we want to allow them to create a post or an answer with only an image. This commit changes the verification to check if the content is empty or if it only contains images. Steps to reproduce the issue resolved by this commit: - Go to the website forum - Create a new post - Set a title - Add an image as description - Click on "Post Your Question" => The post is not created because the content is considered as empty. --- This commit permits to enlarge the answer textarea in the forum. Steps to reproduce the "issue" resolved by this commit: - Go to /forum - Click on a thread - Click on "Answer" => The textarea is too small to write a long answer. --- task-2865782 Forward-Port-Of: odoo/odoo#124590 Forward-Port-Of: odoo/odoo#118519
Steps to reproduce: - Activate Product category on /shop page to show on the left side - Activate collapsible category - Add or modify a Category to have a name with multiple words seperated by space Issue: The label of the category in eshop always returns to the line at the last word opw-3321404 Forward-Port-Of: odoo/odoo#123718
Original PR description
Steps to reproduce: - Activate Product category on /shop page to show on the left side - Activate collapsible category - Add or modify a Category to have a name with multiple words seperated by space Issue: The label of the category in eshop always returns to the line at the last word opw-3321404 Forward-Port-Of: odoo/odoo#123718
Before this commit, the CodeEditor made Ace display infinity lines in height. This prevented Ace to be scrollable in all contexts. Specifically, when Ace was in a flex context, the scroll did not work. After this commit, Ace displays as much lines as it can, constrained by its element size. 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
Original PR description
Before this commit, the CodeEditor made Ace display infinity lines in height. This prevented Ace to be scrollable in all contexts. Specifically, when Ace was in a flex context, the scroll did not work. After this commit, Ace displays as much lines as it can, constrained by its element size. 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#124585
**Current behavior before PR:** `id` cannot be set as the dependency for a field's compute method. So, when a user configures `id` as a dependency for a studio field's compute, there is no error shown to the user, and the field is saved with `id` as a dependency. ``` NotImplementedError: Compute method cannot depend on field 'id'. File "odoo/addons/base/models/ir_model.py", line 1165, in _add_manual_fields field = self._instanciate(field_data) File "odoo/addons/base/models/i
Original PR description
**Current behavior before PR:** `id` cannot be set as the dependency for a field's compute method. So, when a user configures `id` as a dependency for a studio field's compute, there is no error…
**Current behavior before PR:**
`id` cannot be set as the dependency for a field's compute method.
So, when a user configures `id` as a dependency for a studio field's compute,
there is no error shown to the user, and
the field is saved with `id` as a dependency.
```
NotImplementedError: Compute method cannot depend on field 'id'.
File "odoo/addons/base/models/ir_model.py", line 1165, in _add_manual_fields
field = self._instanciate(field_data)
File "odoo/addons/base/models/ir_model.py", line 1155, in _instanciate
attrs = self._instanciate_attrs(field_data)
File "addons/mail/models/ir_model_fields.py", line 29, in _instanciate_attrs
attrs = super(IrModelField, self)._instanciate_attrs(field_data)
File "odoo/addons/base/models/ir_model.py", line 1150, in _instanciate_attrs
attrs['compute'] = make_compute(field_data['compute'], field_data['depends'])
File "odoo/addons/base/models/ir_model.py", line 39, in make_compute
return api.depends(*deps)(func)
File "odoo/api.py", line 264, in depends
raise NotImplementedError("Compute method cannot depend on field 'id'.")
```
**Desired behavior after PR is merged:**
It will throw a `UserError` to the user.
sentry-3979435039
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#123558
Forward-Port-Of: odoo/odoo#121745odoo/odoo#122354 added this test but didn't handle that other models might trigger systray activities. On June 12th, the test started failing because calendar has a "Pricing Discussion" demo calendar event on the 12th of every month. It probably would have also failed on the 3rd and 22nd which both have demo meetings for the admin. Fix by looking up specifically activities of the test model we're concerned with. Forward-Port-Of: odoo/odoo#124586
Original PR description
odoo/odoo#122354 added this test but didn't handle that other models might trigger systray activities. On June 12th, the test started failing because calendar has a "Pricing Discussion" demo calendar event on the 12th of every month. It probably would have also failed on the 3rd and 22nd which both have demo meetings for the admin. Fix by looking up specifically activities of the test model we're concerned with. Forward-Port-Of: odoo/odoo#124586
In follow-up https://github.com/odoo/odoo/pull/120437 PR above replaces `underscore.js` `map` by native `.map()`. The `map` of `underscore.js` accepts anything, even mapping on `FileList`. However, native `map` needs to apply on an array. This commit fixes the issue by ensuring `.map()` is applied on an array. Task-3366632 Forward-Port-Of: odoo/odoo#124665
Original PR description
In follow-up https://github.com/odoo/odoo/pull/120437 PR above replaces `underscore.js` `map` by native `.map()`. The `map` of `underscore.js` accepts anything, even mapping on `FileList`. However, native `map` needs to apply on an array. This commit fixes the issue by ensuring `.map()` is applied on an array. Task-3366632 Forward-Port-Of: odoo/odoo#124665
Before this commit, a `t` opening and closing tag mismatched. This would lead to an error when exporting the discuss app translations. ``` Traceback (most recent call last): File "/home/odoo/Desktop/odoo/odoo/odoo/tools/translate.py", line 1152, in _babel_extract_terms for extracted in extract.extract(extract_method, src_file, keywords=extract_keywords, options=options): File "/home/odoo/.local/lib/python3.8/site-packages/babel/messages/extract.py", line 322, in extract resul
Original PR description
Before this commit, a `t` opening and closing tag mismatched. This would lead to an error when exporting the discuss app translations. ``` Traceback (most recent call last): File…
Before this commit, a `t` opening and closing tag mismatched. This would lead to an error when exporting the discuss app translations.
```
Traceback (most recent call last):
File "/home/odoo/Desktop/odoo/odoo/odoo/tools/translate.py", line 1152, in _babel_extract_terms
for extracted in extract.extract(extract_method, src_file, keywords=extract_keywords, options=options):
File "/home/odoo/.local/lib/python3.8/site-packages/babel/messages/extract.py", line 322, in extract
results = func(fileobj, keywords.keys(), comment_tags,
File "/home/odoo/Desktop/odoo/odoo/odoo/tools/translate.py", line 905, in babel_extract_qweb
tree = etree.parse(fileobj)
File "src/lxml/etree.pyx", line 3521, in lxml.etree.parse
File "src/lxml/parser.pxi", line 1880, in lxml.etree._parseDocument
File "src/lxml/parser.pxi", line 1900, in lxml.etree._parseFilelikeDocument
File "src/lxml/parser.pxi", line 1795, in lxml.etree._parseDocFromFilelike
File "src/lxml/parser.pxi", line 1201, in lxml.etree._BaseParser._parseDocFromFilelike
File "src/lxml/parser.pxi", line 615, in lxml.etree._ParserContext._handleParseResultDoc
File "src/lxml/parser.pxi", line 725, in lxml.etree._handleParseResult
File "src/lxml/parser.pxi", line 654, in lxml.etree._raiseParseError
File "/home/odoo/Desktop/odoo/odoo/addons/mail/static/src/emoji_picker/emoji_picker.xml", line 60
lxml.etree.XMLSyntaxError: Opening and ending tag mismatch: t line 10 and div, line 60, column 15
```
Forward-Port-Of: odoo/odoo#124673If the company already has a currency do not change its value. This avoids errors related to existing journal items for the current company's currency. Issue observed during upgrades for MX localization. Forward-Port-Of: odoo/odoo#123735
Original PR description
If the company already has a currency do not change its value. This avoids errors related to existing journal items for the current company's currency. Issue observed during upgrades for MX localization. Forward-Port-Of: odoo/odoo#123735
Before this commit, a new unread message could contribute to unread counter of conversation twice. Steps to reproduce: 1. Log in as Demo and start a conversation with Mitchell Admin 2. Log in as Admin: if this is the first message in the conversation, counter is correct and shows (1) 3. Log out as Admin 4. Send another message to Admin 5. Log in as Admin and notice that the counter is doubled 6. If the conversation was still open, counter is correct! This happens because some notif
Original PR description
Before this commit, a new unread message could contribute to unread counter of conversation twice. Steps to reproduce: 1. Log in as Demo and start a conversation with Mitchell Admin 2. Log in as…
Before this commit, a new unread message could contribute to unread counter of conversation twice. Steps to reproduce: 1. Log in as Demo and start a conversation with Mitchell Admin 2. Log in as Admin: if this is the first message in the conversation, counter is correct and shows (1) 3. Log out as Admin 4. Send another message to Admin 5. Log in as Admin and notice that the counter is doubled 6. If the conversation was still open, counter is correct! This happens because some notification are pending dispatch before fetching messaging state initially. The counter at init_messaging fetch takes into account the notification. However, when handling the message notifcation, it's wrongly considered as a new notification, thus incrementing the counter when it shouldn't. This commit fixes the issue by fetching the last bus notification when fetching init_messaging. Doing so allow to determine whether a notification is newer or older than init_messaging state. This helps deciding whether the counter should be incremented or not. Task-3357960 Forward-Port-Of: odoo/odoo#124354
Before: - in the accounting dashboard, the graph key was confusing for sample data in cash and bank journals. - in the accounting journal dashboard, for bank and cash graph data the date comparison was done between a date object and a formatted date object resulting in them never being equal and duplicating data. Now: - if sample data is shown, the graph key is displayed as "Sample data". - both dates are formatted in the same way. Task-ID #327726333 Forward-Port-Of: odoo/odoo#12029
Original PR description
Before: - in the accounting dashboard, the graph key was confusing for sample data in cash and bank journals. - in the accounting journal dashboard, for bank and cash graph data the date comparison was done between a date object and a formatted date object resulting in them never being equal and duplicating data. Now: - if sample data is shown, the graph key is displayed as "Sample data". - both dates are formatted in the same way. Task-ID #327726333 Forward-Port-Of: odoo/odoo#120295
Steps to reproduce: 1 - activate "Print GS1 Barcodes for Lots & Serial Numbers" 2 - create a product P tracked by lot 3 - print the "Lot/Serial Number (PDF)" from the stock.lot form/list view Bug: contrary to previous versions, the current template doesn't allow the field to overflow into multiple lines Fix: change the css class `o_label_4x12` as it is only used in use cases where overflow shows be allowed OPW-3336476 Forward-Port-Of: odoo/odoo#122498
Original PR description
Steps to reproduce: 1 - activate "Print GS1 Barcodes for Lots & Serial Numbers" 2 - create a product P tracked by lot 3 - print the "Lot/Serial Number (PDF)" from the stock.lot form/list view Bug: contrary to previous versions, the current template doesn't allow the field to overflow into multiple lines Fix: change the css class `o_label_4x12` as it is only used in use cases where overflow shows be allowed OPW-3336476 Forward-Port-Of: odoo/odoo#122498
- Create invoice with default `invoice_line_ids`. In the Values both fields `invoice_line_ids` and `line_ids`, field `line_ids` is empty, filed `invoice_line_ids` not empty. function _sanitize_vals return vals with del `invoice_line_ids`, but function `_add_missing_default_values` update value default of filed `invoice_line_ids` in to values. And as a result, the invoice is generated with 2 duplicated lines. Description of the issue/feature this PR addresses:  Current behavior before PR: Desired behavior after PR is merged: https://github.com/odoo/odoo/assets/11542778/0978d1f5-8947-4aab-9324-3d9253905b97 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#124583
Images weren't shown when using predefined templates, the problem was that returned object wasn't assigned to anything, because sometimes `filename` wasn't found in `imagesInfo` object, which caused wierd behaviour. bug happened: f4f0f783183507df8227b37fe1234c256325df6d task-3328675 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.od
Original PR description
Images weren't shown when using predefined templates, the problem was that returned object wasn't assigned to anything, because sometimes `filename` wasn't found in `imagesInfo` object, which caused wierd behaviour. bug happened: f4f0f783183507df8227b37fe1234c256325df6d task-3328675 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#121873
When we confirm an invoice without adding a product in it and then click on process now then we will face the above valuerror. Steps to produce: 1) Install 'l10n_it_edi'. 2) Change the company to 'IT Company'. 3) Now go to 'Invoicing' settings and then under 'Fattura Elettronica mode' check 'Allow Odoo to process invoices' radio button. 4) Create an invoice by adding a partner. 5) While creating it click on 'Add a section' instead of 'Add a line'. 6) Click on confirm. 7) Now Click
Original PR description
When we confirm an invoice without adding a product in it and then click on process now then we will face the above valuerror. Steps to produce: 1) Install 'l10n_it_edi'. 2) Change the company to 'IT…
When we confirm an invoice without adding a product in it and then click on process now
then we will face the above valuerror.
Steps to produce:
1) Install 'l10n_it_edi'.
2) Change the company to 'IT Company'.
3) Now go to 'Invoicing' settings and then under 'Fattura Elettronica mode' check
'Allow Odoo to process invoices' radio button.
4) Create an invoice by adding a partner.
5) While creating it click on 'Add a section' instead of 'Add a line'.
6) Click on confirm.
7) Now Click on 'Process now'.
By following the above steps you will be able to produce the above error.
Traceback:
```TypeError: reduce() of empty iterable with no initial value
File "odoo/tools/safe_eval.py", line 362, in safe_eval
return unsafe_eval(c, globals_dict, locals_dict)
File "ir.actions.server(272,)", line 1, in <module>
File "addons/account_edi/models/account_edi_document.py", line 256, in _cron_process_documents_web_services
nb_remaining_jobs = edi_documents._process_documents_web_services(job_count=job_count)
File "addons/account_edi/models/account_edi_document.py", line 243, in _process_documents_web_services
self._process_job(job)
File "addons/account_edi/models/account_edi_document.py", line 197, in _process_job
edi_result = method_to_call(moves)
File "addons/l10n_it_edi/models/account_edi_format.py", line 1130, in _post_fattura_pa
return self._l10n_it_post_invoices_step_1(invoice)
File "addons/l10n_it_edi/models/account_edi_format.py", line 944, in _l10n_it_post_invoices_step_1
xml = "<?xml version='1.0' encoding='UTF-8'?>" + str(self._l10n_it_edi_export_invoice_as_xml(invoice))
File "addons/l10n_it_edi/models/account_edi_format.py", line 909, in _l10n_it_edi_export_invoice_as_xml
template_values = invoice._prepare_fatturapa_export_values()
File "addons/l10n_it_edi/models/account_invoice.py", line 258, in _prepare_fatturapa_export_values
downpayment_moves = reduce(lambda x, y: x | y, downpayment_moves)
ValueError: <class 'TypeError'>: "reduce() of empty iterable with no initial value" while evaluating
'model._cron_process_documents_web_services(job_count=20)'
File "odoo/addons/base/models/ir_cron.py", line 368, in _callback
self.env['ir.actions.server'].browse(server_action_id).run()
File "odoo/addons/base/models/ir_actions.py", line 668, in run
res = runner(run_self, eval_context=eval_context)
File "odoo/addons/base/models/ir_actions.py", line 538, in _run_action_code_multi
safe_eval(self.code.strip(), eval_context, mode="exec", nocopy=True, filename=str(self)) # nocopy allows to return 'action'
File "odoo/tools/safe_eval.py", line 376, in safe_eval
raise ValueError('%s: "%s" while evaluating\n%r' % (ustr(type(e)), ustr(e), expr))
```
Applying this commit will solve the valuerror issue.
Sentry- 4170737698
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#121799This issue occurs when the value of tax_dest_id key is missing at the time of getting fiscal localization data for a respective package. Steps to produce : 1. Install CA_accounting and invoicing module 2. Switch to CA company 3. Go to invoicing > configuration > settings > Reload Button ``` KeyError: 'tax_dest_id' 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._s
Original PR description
This issue occurs when the value of tax_dest_id key is missing at the time of getting fiscal localization data for a respective package. Steps to produce : 1. Install CA_accounting and invoicing…
This issue occurs when the value of tax_dest_id key is missing at the time of getting fiscal localization data for a respective package.
Steps to produce :
1. Install CA_accounting and invoicing module
2. Switch to CA company
3. Go to invoicing > configuration > settings > Reload Button
```
KeyError: 'tax_dest_id'
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 "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 32, in call_button
action = 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 "addons/account/models/res_config_settings.py", line 172, in reload_template
self.env['account.chart.template'].try_loading(self.company_id.chart_template, company=self.company_id)
File "addons/account/models/chart_template.py", line 141, in try_loading
return self._load(template_code, company, install_demo)
File "addons/account/models/chart_template.py", line 182, in _load
self._pre_reload_data(company, template_data, data)
File "addons/account/models/chart_template.py", line 266, in _pre_reload_data
values['tax_ids'] = [
File "addons/account/models/chart_template.py", line 272, in <listcomp>
or not self.ref(vals['tax_dest_id'], raise_if_not_found=False)
```
This commit will solve the issue by adding a get method with the default value of an empty string to get the value of tax_dest_id key, if it does not exist.
sentry-4128326643
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Forward-Port-Of: odoo/odoo#120503To reproduce: 1. Create a Sales Order for a product whose product category is set to FIFO and automated. Use route "dropship". 2. Confirm the PO created. 3. Deliver the products (DS transfer) 4. Create the customer invoice 5. Return, for example, 1 unit of product 6. Add a credit note to the invoice for that 1 unit returned (reset to draft then change qty and post) Issues: The value on the valuation layers of the returned picking is 0, posted entries for COGS and stock interim (
Original PR description
To reproduce: 1. Create a Sales Order for a product whose product category is set to FIFO and automated. Use route "dropship". 2. Confirm the PO created. 3. Deliver the products (DS transfer) 4.…
To reproduce: 1. Create a Sales Order for a product whose product category is set to FIFO and automated. Use route "dropship". 2. Confirm the PO created. 3. Deliver the products (DS transfer) 4. Create the customer invoice 5. Return, for example, 1 unit of product 6. Add a credit note to the invoice for that 1 unit returned (reset to draft then change qty and post) Issues: The value on the valuation layers of the returned picking is 0, posted entries for COGS and stock interim (delivered) account for credit note is also 0. Since https://github.com/odoo/odoo/pull/85751, When create valuation layer for return, we take all svls of origin_returned_move_id into account to calculate the price unit. However, then dropshiping, 2 svls are created for the original move, and the sum of them is 0 since there is no impact of the stock when dropshiping. So when return, the price unit will be calculated as 0. To fix, when calculate price unit for return of dropshiping, we only take non-negative svls into account. Note that we use non-negative ones instead of positive ones because when subcontract dropshiping, additional negative svls will be added for the cost of the components. opw-3283436 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#124793 Forward-Port-Of: odoo/odoo#123529
Since commit [1], we have added the "Rerun in debug" in QUnit. This link forces a specific test to be run in debug mode. This link doesn't work some time as it runs another test. This commit fixes that by using the `testId` parameter to set the id of the test like QUnit does, and we add `debugTest` to force the `Debug Mode`. Step to reproduce: * Go to the QUnit test suite * Wait to have some tests passed * Uncheck `Hide passed tests` * Select a `Rerun` on a valid test e.g. URL: `/web/t
Original PR description
Since commit [1], we have added the "Rerun in debug" in QUnit. This link forces a specific test to be run in debug mode. This link doesn't work some time as it runs another test. This commit fixes…
Since commit [1], we have added the "Rerun in debug" in QUnit. This link forces a specific test to be run in debug mode. This link doesn't work some time as it runs another test. This commit fixes that by using the `testId` parameter to set the id of the test like QUnit does, and we add `debugTest` to force the `Debug Mode`. Step to reproduce: * Go to the QUnit test suite * Wait to have some tests passed * Uncheck `Hide passed tests` * Select a `Rerun` on a valid test e.g. URL: `/web/tests/?testId=cb868a47` * Click on "Rerun in debug" e.g. URL: `/web/tests/?testId=cb868a47&debugTestId=cb868a47` * Delete from URL `testId=X` (where `X` = hash of the test) e.g. URL: `/web/tests/?debugTestId=cb868a47` * BUG => The tested test will not be the selected one. e.g. in our case, it is MockServer: performRPC (037b6d96) Note Small table of tests: | Hash | Test Module | Test Name | | -------- | ------------------- | ----------------------------------------- | | cb868a47 | utils > makeContext | evaluate strings | | 037b6d96 | MockServer | performRPC: search with active_test=false | Also, a minor fix, using URL constructor and adding search parameter through `searchParams.set()` to avoid the missing `?` in some cases. The url `http://127.0.0.1:8069/web/tests/mobile` works but not `http://127.0.0.1:8069/web/tests/mobile&testId=0e3481e3&debugTest=true` as there is no search in the first URL when we click to "Rerun in debug" it adds `&testId=0e3481e3&debugTest=true` but now it's a new page and not the QUnit mobile suite. [1]: https://github.com/odoo/odoo/commit/b7ce395a47c371d51041e2debbf8768a70532c24 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#124680
Steps to reproduce: 1) Have Barcode Installed and have Barcode Nomenclature set 2) edit 1st rule(Price Barcodes 2 Decimals) to type Quantity 3) Create a product with barcode 2380201000008 4) Open POS and scan barcode 2380201010007 Bug: error popup product not found because the callback for this rule is not set Fix: apply same callback as weight (set product quantity) opw-3213595 Forward-Port-Of: odoo/odoo#124738 Forward-Port-Of: odoo/odoo#123924
Original PR description
Steps to reproduce: 1) Have Barcode Installed and have Barcode Nomenclature set 2) edit 1st rule(Price Barcodes 2 Decimals) to type Quantity 3) Create a product with barcode 2380201000008 4) Open POS and scan barcode 2380201010007 Bug: error popup product not found because the callback for this rule is not set Fix: apply same callback as weight (set product quantity) opw-3213595 Forward-Port-Of: odoo/odoo#124738 Forward-Port-Of: odoo/odoo#123924
Prior to this commit, the `input-bg` in enterprise and in community were inconsistent. Some inputs such as the ones in list view were appearing in community with a weird white background while being hovered on. Meanwhile in enterprise, these inputs were having a transparent background. This commit sets the `input-bg` variable in `bootstrap_overridden` to transparent for the inputs in community. Since the variable is now the same in community and enterprise, this variable is now unnecess
Original PR description
Prior to this commit, the `input-bg` in enterprise and in community were inconsistent. Some inputs such as the ones in list view were appearing in community with a weird white background while being…
Prior to this commit, the `input-bg` in enterprise and in community were inconsistent. Some inputs such as the ones in list view were appearing in community with a weird white background while being hovered on. Meanwhile in enterprise, these inputs were having a transparent background. This commit sets the `input-bg` variable in `bootstrap_overridden` to transparent for the inputs in community. Since the variable is now the same in community and enterprise, this variable is now unnecessary and was removed from the enterprise branch. The boolean switch input is relying on the $form-switch-checked-color to display its SVG white circle, therefore it should be set to $o-white instead of $input-bg (its already the case in enterprise, doing so, this line can be removed from enterprise as well). $form-switch-circle-bg-color is not used anywhere in the code and can be removed since we use $form-switch-checked-color instead. Task-3094005 Enterprise PR: https://github.com/odoo/enterprise/pull/35491 Before fix:  After fix:  --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#124305 Forward-Port-Of: odoo/odoo#107385
Before this commit, if you used a tax that was using "Group of Taxes" for the "Tax Computation" in PoS, it would crash because it doesn't have Distribution for invoices. This issue also occurred for other taxes that lacked a "Distribution for invoices" line. opw-3341807 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#124004 Forward-Port-Of: odoo/odoo#122925
Original PR description
Before this commit, if you used a tax that was using "Group of Taxes" for the "Tax Computation" in PoS, it would crash because it doesn't have Distribution for invoices. This issue also occurred for other taxes that lacked a "Distribution for invoices" line. opw-3341807 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#124004 Forward-Port-Of: odoo/odoo#122925
- When creating new sales journals, it doesn't matter if you deselect the "Use Latam document" option, it is still an SRI electronic document. This error does not allow users to create non-electronic sales journals. - Add the dependency "l10n_latam_use_documents" in the _compute_edi_format_ids method, to fix the activation or deactivation of the l10n_latam_use_documents option. Forward-Port-Of: odoo/enterprise#42386
Original PR description
- When creating new sales journals, it doesn't matter if you deselect the "Use Latam document" option, it is still an SRI electronic document. This error does not allow users to create non-electronic sales journals. - Add the dependency "l10n_latam_use_documents" in the _compute_edi_format_ids method, to fix the activation or deactivation of the l10n_latam_use_documents option. Forward-Port-Of: odoo/enterprise#42386
## [FIX] web_grid: avoid reloading when edit a grid cell Before this commit, when the user edits a cell, the grid view is reloading, the problem with that method is the rows could be reordered in the grid view and so the user cannot edit many cells in a same row at the same time. This commit avoids reloading the grid view when the grid cells are editing by the user to be able to quickly edit it without any issues. ## [FIX] timesheet_grid: avoid reloading the grid view when timer stop
Original PR description
## [FIX] web_grid: avoid reloading when edit a grid cell Before this commit, when the user edits a cell, the grid view is reloading, the problem with that method is the rows could be reordered in the…
## [FIX] web_grid: avoid reloading when edit a grid cell Before this commit, when the user edits a cell, the grid view is reloading, the problem with that method is the rows could be reordered in the grid view and so the user cannot edit many cells in a same row at the same time. This commit avoids reloading the grid view when the grid cells are editing by the user to be able to quickly edit it without any issues. ## [FIX] timesheet_grid: avoid reloading the grid view when timer stopped Before this commit, when the timer is stopped by the user, the grid view is reloading, the problem by doing that is the rows in the grid view could be reordered and so the user cannot quickly start another timer in a specific row, he has to wait the timer is stopped before starting another timer. This commit avoids reloading the grid view when a timer is stopped to allow the user to directly start another timer. ## [FIX] timesheet_grid: allow to start another timer even if a timer is running Before this commit, when the user uses a shortcut letter to start a timer, he cannot use another shortcut while a timer is running. This commit fixes the issue by allowing to use the shortcut to stop the running timer or to start another timer (if another timer is started the timer is automatically stopped). task-3349578 Forward-Port-Of: odoo/enterprise#42039
Prior to this commit, the `input-bg` in enterprise and in community were inconsistent. Some inputs such as the ones in list view were appearing in community with a weird white background while being hovered on. Meanwhile in enterprise, these inputs were having a transparent background. This commit sets the `input-bg` variable in `bootstrap_overridden` to transparent for the inputs in community. Since the variable is now the same in community and enterprise, this variable is now unnecessary an
Original PR description
Prior to this commit, the `input-bg` in enterprise and in community were inconsistent. Some inputs such as the ones in list view were appearing in community with a weird white background while being hovered on. Meanwhile in enterprise, these inputs were having a transparent background. This commit sets the `input-bg` variable in `bootstrap_overridden` to transparent for the inputs in community. Since the variable is now the same in community and enterprise, this variable is now unnecessary and was removed from the enterprise branch. Task-3094005 Community PR: https://github.com/odoo/odoo/pull/107385 Before fix:  After fix:  Forward-Port-Of: odoo/enterprise#42178 Forward-Port-Of: odoo/enterprise#35491
Set current language to rtl Go to Partner Ledger Print PDF Printed report will overflow the page **Before** [partner_ledger (18).pdf](https://github.com/odoo/enterprise/files/11567101/partner_ledger.18.pdf) **After** [partner_ledger (19).pdf](https://github.com/odoo/enterprise/files/11567102/partner_ledger.19.pdf) opw-3323737 Forward-Port-Of: odoo/enterprise#41517
Original PR description
Set current language to rtl Go to Partner Ledger Print PDF Printed report will overflow the page **Before** [partner_ledger (18).pdf](https://github.com/odoo/enterprise/files/11567101/partner_ledger.18.pdf) **After** [partner_ledger (19).pdf](https://github.com/odoo/enterprise/files/11567102/partner_ledger.19.pdf) opw-3323737 Forward-Port-Of: odoo/enterprise#41517
Steps to reproduce: - Create and confirm an invoice in a foreign currency. - Register a full payment a few days later. - Open the Aged Receivable Report at the invoice date. Observed behavior: The Amout Currency column is empty. Desired behavior: The Amount Currency column should siplay the correct value. The issue comes from the fact that the query run when generating the report lines uses the `amount_residual_currency` from `account.move.line`, which is 0 once the invoice is paid
Original PR description
Steps to reproduce: - Create and confirm an invoice in a foreign currency. - Register a full payment a few days later. - Open the Aged Receivable Report at the invoice date. Observed behavior: The Amout Currency column is empty. Desired behavior: The Amount Currency column should siplay the correct value. The issue comes from the fact that the query run when generating the report lines uses the `amount_residual_currency` from `account.move.line`, which is 0 once the invoice is paid in full. The problem is that it does not take into account the date of the payment, which leads to an inconsistent report in this case. So the solution is tho use the partial reconcile amounts. A test is also added to cover this use case. task-3282980 Forward-Port-Of: odoo/enterprise#42418 Forward-Port-Of: odoo/enterprise#41131
Some formulas are not correct. Since the dashboard is unusable since it shows wrong figures, we fix it in stable even if it means breaking some translations. Note:only new database will have a fixed dashboard. For existing database, delete the dashboard and update module `spreadsheet_dashboard_account_accountant` opw-3339877 Forward-Port-Of: odoo/enterprise#42360 Forward-Port-Of: odoo/enterprise#42161
Original PR description
Some formulas are not correct. Since the dashboard is unusable since it shows wrong figures, we fix it in stable even if it means breaking some translations. Note:only new database will have a fixed dashboard. For existing database, delete the dashboard and update module `spreadsheet_dashboard_account_accountant` opw-3339877 Forward-Port-Of: odoo/enterprise#42360 Forward-Port-Of: odoo/enterprise#42161
The issue: Generating the 281.50 throws a traceback when there's some journal items without a partner. The fix: fetching just the lines needed that are in the partner_ids list opw-3301968 Forward-Port-Of: odoo/enterprise#42029 Forward-Port-Of: odoo/enterprise#41996
Original PR description
The issue: Generating the 281.50 throws a traceback when there's some journal items without a partner. The fix: fetching just the lines needed that are in the partner_ids list opw-3301968 Forward-Port-Of: odoo/enterprise#42029 Forward-Port-Of: odoo/enterprise#41996
Steps: - Install fsm app. - Go to map view in my tasks menu. - Group by Assignee. Issue: - Traceback. Cause: - When map view fetch coordinates to set partner's latitude and longitude it set string value to them and because of that adding offset to pin partner with same address in same place will have wrong value(concatenated value instead of added value) because of that it'll gives us a traceback. Fix: - Convert string to number to avoid traceback. task-3293310 Forward-Port-
Original PR description
Steps: - Install fsm app. - Go to map view in my tasks menu. - Group by Assignee. Issue: - Traceback. Cause: - When map view fetch coordinates to set partner's latitude and longitude it set string value to them and because of that adding offset to pin partner with same address in same place will have wrong value(concatenated value instead of added value) because of that it'll gives us a traceback. Fix: - Convert string to number to avoid traceback. task-3293310 Forward-Port-Of: odoo/enterprise#41380
Currently "TypeError '<' not supported between instances of 'datetime.date' and 'NoneType'" is generated when not providing date_to in payslip. Trace-back on sentry: ``` TypeError: '<' not supported between instances of 'datetime.date' and 'NoneType' 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
Original PR description
Currently "TypeError '<' not supported between instances of 'datetime.date' and 'NoneType'" is generated when not providing date_to in payslip. Trace-back on sentry: ``` TypeError: '<' not supported…
Currently "TypeError '<' not supported between instances of 'datetime.date'
and 'NoneType'" is generated when not providing date_to in payslip.
Trace-back on sentry:
```
TypeError: '<' not supported between instances of 'datetime.date' and 'NoneType'
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 "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 6515, in onchange
record.modified(todo)
File "odoo/models.py", line 6073, in modified
for field, records, create in tocompute:
File "odoo/models.py", line 6125, in _modified_triggers
records = self[invf.name]
File "odoo/models.py", line 5932, in __getitem__
return self._fields[key].__get__(self, type(self))
File "odoo/fields.py", line 4267, in __get__
return super().__get__(records, owner)
File "odoo/fields.py", line 2773, in __get__
return super().__get__(records, owner)
File "odoo/fields.py", line 1155, in __get__
self.recompute(record)
File "odoo/fields.py", line 1346, in recompute
self.compute_value(recs)
File "odoo/fields.py", line 1368, in compute_value
records._compute_field_value(self)
File "addons/mail/models/mail_thread.py", line 395, in _compute_field_value
return super()._compute_field_value(field)
File "odoo/models.py", line 4302, in _compute_field_value
fields.determine(field.compute, self)
File "odoo/fields.py", line 99, in determine
return needle(*args)
File "home/odoo/src/enterprise/saas-16.2/hr_payroll/models/hr_payslip.py", line 796, in _compute_worked_days_line_ids
generate_to = max(min(fields.Date.to_date(p.date_to), current_month_end) for p in self)
File "home/odoo/src/enterprise/saas-16.2/hr_payroll/models/hr_payslip.py", line 796, in <genexpr>
generate_to = max(min(fields.Date.to_date(p.date_to), current_month_end) for p in self)
```
This commit fixes the above issue by preventing the compute worked days
line of the payslip, which is not a valid.
sentry-4186578577
Forward-Port-Of: odoo/enterprise#42368
Forward-Port-Of: odoo/enterprise#41156Steps to reproduce: Create a Quality Control Point Control: Product Operations: Manufacturing Create an MO Pass the first QC Mark MO as done New QC created Bug: when marking MO as done action confirm is executed on stock.move.line where there's already a quality check on the move since this commit[1] lines that have a production_id and qty_done>0 are no longer filtered out Fix: filter out the lines that already have a production_id the same w
Original PR description
Steps to reproduce:
Create a Quality Control Point
Control: Product
Operations: Manufacturing
Create an MO
Pass the first QC
Mark MO as done
New QC created
Bug:
when marking MO as done action confirm is executed on stock.move.line
where there's already a quality check on the move
since this commit[1] lines that have a production_id and qty_done>0 are
no longer filtered out
Fix:
filter out the lines that already have a production_id the same way it was done
previously
[1]:https://github.com/odoo/enterprise/commit/7408938a9aa705d9d67a9cc0c2d354bfaf13e7f1
opw-3166917
Forward-Port-Of: odoo/enterprise#42293
Forward-Port-Of: odoo/enterprise#41601This part of the fix is only meant to give a better message to the user about the subscriptions behavior. Steps to reproduce: Create 2 products with recurring invoice, one with a monthly price and one with a yearly price. Go to the shop in the frontend, and add one of them to the cart. Now go to the product page of the other product. Issue: We are going to see always the same warning message telling us that 'This product has no valid combination.' which is not very specific about what
Original PR description
This part of the fix is only meant to give a better message to the user about the subscriptions behavior. Steps to reproduce: Create 2 products with recurring invoice, one with a monthly price and one with a yearly price. Go to the shop in the frontend, and add one of them to the cart. Now go to the product page of the other product. Issue: We are going to see always the same warning message telling us that 'This product has no valid combination.' which is not very specific about what is the reason we cannot add the product to the cart. Solution: Added a specific message for the products with recurring invoice that can't be added to the cart. Part of the fix is in #[109154](https://github.com/odoo/odoo/pull/109154) opw-3084520 Forward-Port-Of: odoo/enterprise#35676
Steps to reproduce ================== - Go to knowledge - Upload a file using the /file command Try downloading it using the mobile app "The odoo mobile apps only supports file downloads using ..." Cause of the issue ================== The file is downloaded as a blob. This is only supported in a real browser Solution ======== Use the download function from @web/core/network/download. It should only be used for file download from odoo, but this is the case. opw-33089
Original PR description
Steps to reproduce ================== - Go to knowledge - Upload a file using the /file command Try downloading it using the mobile app "The odoo mobile apps only supports file downloads using ..." Cause of the issue ================== The file is downloaded as a blob. This is only supported in a real browser Solution ======== Use the download function from @web/core/network/download. It should only be used for file download from odoo, but this is the case. opw-3308986 Forward-Port-Of: odoo/enterprise#42288 Forward-Port-Of: odoo/enterprise#41790
Before this commit, the `pos_sale_stock_renting` module only depended on the `point_of_sale` and `sale_stock_renting` modules, while it explicitly uses the `sale_order_line_id` field on `pos.order.line` defined in the `pos_sale` module. This problem can result in tracebacks when removing the sales application, for example, as the `pos_sale_stock_renting` module is not removed, but the `pos_sale` module is. The problem is easily fixed by adding the missing dependency. Forward-Port-Of: odoo/en
Original PR description
Before this commit, the `pos_sale_stock_renting` module only depended on the `point_of_sale` and `sale_stock_renting` modules, while it explicitly uses the `sale_order_line_id` field on `pos.order.line` defined in the `pos_sale` module. This problem can result in tracebacks when removing the sales application, for example, as the `pos_sale_stock_renting` module is not removed, but the `pos_sale` module is. The problem is easily fixed by adding the missing dependency. Forward-Port-Of: odoo/enterprise#42371 Forward-Port-Of: odoo/enterprise#42238
In sign, we call adjustSignatureSize to adapt the signature image's dimensions to match to the sign item box's. However, it is possible that, in some cases, the sign items are detached from the page elements inside PDF.js. This causes the width and height of the sign item to be 0px and the calculation is not possible. This commit checks if the sign items are detached and accordingly calls refreshSignItems to attach them back before checking the dimensions. -------------------------------
Original PR description
In sign, we call adjustSignatureSize to adapt the signature image's dimensions to match to the sign item box's. However, it is possible that, in some cases, the sign items are detached from the page…
In sign, we call adjustSignatureSize to adapt the signature image's dimensions to match to the sign item box's. However, it is possible that, in some cases, the sign items are detached from the page elements inside PDF.js. This causes the width and height of the sign item to be 0px and the calculation is not possible. This commit checks if the sign items are detached and accordingly calls refreshSignItems to attach them back before checking the dimensions. ------------------------------------------------------------------------------- In sign, when generating the complete file, there are some errors that can happen if the sign.request has invalid or wrong values. This commit adds some try/catch blocks to inform the user that something is wrong. ------------------------------------------------------------------------------- Summary: follow up on commit 1384edf applying same error handling on invalid frame values. Tested and seen on opw-3236508 Cause: malformed image data incorrectly written by adjustSignatureSize client side (data:;) in this case on the image frame (also an image) Solution: commit 84887a2 preventing erroneous values on images (Initiales, signature, data and frame) from being inserted on doc signing. Throw an error and exit gracefully, preventing a HTTP 500 on already signed documents with faulty image values opw-3272737 opw-3094675 opw-3236508 Forward-Port-Of: odoo/enterprise#42250
Before this commit, the scrap's barcode, "O-BTN.scrap", who was printed in the barcode's commands, doesn't nothing when scanned. The command was missing, this commit adds it. opw-3333165 Forward-Port-Of: odoo/enterprise#42198 Forward-Port-Of: odoo/enterprise#41698
Original PR description
Before this commit, the scrap's barcode, "O-BTN.scrap", who was printed in the barcode's commands, doesn't nothing when scanned. The command was missing, this commit adds it. opw-3333165 Forward-Port-Of: odoo/enterprise#42198 Forward-Port-Of: odoo/enterprise#41698
Before this commit, the xmlEditor was not scrollable. This was due in part to what https://github.com/odoo/odoo/pull/124585 fixes. Consequently, this commit sets the context of the CodeEditor to flex. That way we know it takes all the available space to render the lines. Forward-Port-Of: odoo/enterprise#42336
Original PR description
Before this commit, the xmlEditor was not scrollable. This was due in part to what https://github.com/odoo/odoo/pull/124585 fixes. Consequently, this commit sets the context of the CodeEditor to flex. That way we know it takes all the available space to render the lines. Forward-Port-Of: odoo/enterprise#42336
To reproduce ============ go to referral app and increase the size screen to 150% or more the buttons bellow will disappear and there is no scroll bar to reach them Solution ======== add scss style `overflow: auto visible` to the div opw-3348914 Forward-Port-Of: odoo/enterprise#42350
Original PR description
To reproduce ============ go to referral app and increase the size screen to 150% or more the buttons bellow will disappear and there is no scroll bar to reach them Solution ======== add scss style `overflow: auto visible` to the div opw-3348914 Forward-Port-Of: odoo/enterprise#42350
…mounts Currently, the OSS Sales XML export is failing validation by the tax authorities. This is due to 3 issues: 1. Greece should be using the "EL" country code instead of the ISO "GR". 2. Negative amounts cannot be declared in the regular `VatAmount` node due to a positive constraint. It can only be declared in the `CorrectionsInfo` that is added (with its required fields) here. 3. Lines (a.k.a. countries) with a tax amount of zero should not be included in the XML. A test is also
Original PR description
…mounts Currently, the OSS Sales XML export is failing validation by the tax authorities. This is due to 3 issues: 1. Greece should be using the "EL" country code instead of the ISO "GR". 2. Negative amounts cannot be declared in the regular `VatAmount` node due to a positive constraint. It can only be declared in the `CorrectionsInfo` that is added (with its required fields) here. 3. Lines (a.k.a. countries) with a tax amount of zero should not be included in the XML. A test is also added to cover these cases. task-3280962 Forward-Port-Of: odoo/enterprise#42361 Forward-Port-Of: odoo/enterprise#40019
Steps to reproduce: - Go to System Parameters, Add: key: sign.use_custom_font value: FreeSerifBold (Tested with FreeSerif and Sun-ExtA as well). - Go to Sign > Go to any template, add Text fields > Sign Now. - Paste in any Arabic language segment, Complete signing. - The signed document in Odoo shows the Arabic correctly > Download it > Issue: The Arabic is flipped and changed to be incorrect in downloaded document. Cause: The reportlab librairie don't render well arabic wor
Original PR description
Steps to reproduce: - Go to System Parameters, Add: key: sign.use_custom_font value: FreeSerifBold (Tested with FreeSerif and Sun-ExtA as well). - Go to Sign > Go to any template, add Text fields > Sign Now. - Paste in any Arabic language segment, Complete signing. - The signed document in Odoo shows the Arabic correctly > Download it > Issue: The Arabic is flipped and changed to be incorrect in downloaded document. Cause: The reportlab librairie don't render well arabic words and always use the Left-to-right writing Solution: Use of arabic-reshaper and python3-bidi to render it well but it's possible for now as the actual version of Ubuntu and Debian in Saas and Sh can handle so it will used as permanent fix in the future. As a hot fix we just reverse the text when it's arabic. The form is the right one but the meaning stays and the text can be read. opw-3111259 Forward-Port-Of: odoo/enterprise#41518 Forward-Port-Of: odoo/enterprise#36315
Steps: - Install Sign and Documents modules - Go to Sign, upload a pdf template and save - Modify the template, Show "template properties" - Try to add a Signed document tag and save Issue: - The form view doesn't close automatically (But the call to the server is done) - When closing the form the created tag doesn't appear Cause: Same to this commit: https://github.com/odoo/enterprise/pull/33440/commits/f426db5b313980d416c6890c125c5087e73bbc0f Problem with OWL2 which isn't not yet
Original PR description
Steps: - Install Sign and Documents modules - Go to Sign, upload a pdf template and save - Modify the template, Show "template properties" - Try to add a Signed document tag and save Issue: - The form view doesn't close automatically (But the call to the server is done) - When closing the form the created tag doesn't appear Cause: Same to this commit: https://github.com/odoo/enterprise/pull/33440/commits/f426db5b313980d416c6890c125c5087e73bbc0f Problem with OWL2 which isn't not yet resolved. Beside that, the PO ensured that it's not functionally correct to be able to create tags from that form view. So for now we will just disable the create and edit option for the ``documents_tags_ids`` field. https://discord.com/channels/678381219515465750/1107937721177088091/1107959665175822356 opw-3227339 Forward-Port-Of: odoo/enterprise#38475
TaskID: 3366429 Forward-Port-Of: odoo/enterprise#42348
Original PR description
TaskID: 3366429 Forward-Port-Of: odoo/enterprise#42348