Wednesday, October 30, 2024
58 changes · 18.0
Enhancements to existing features
Kitchen tickets in Point of Sale now show clearer order updates, including notes, add-ons, staff member, table or takeaway details, and timing. This helps restaurant teams understand what changed in an order faster and reduces delays or mistakes in kitchen preparation.
Original PR description
In this commit:
-------------------
- We have changed the entire kitchen ticket structure added many important data
to make it more usefule such as
- Diferent title related to the order changes.
- Proper orderline formation with internal notes and addons.
- Who has taken the order.
- Floor, table name with order number and time of order changes.
- Also adapted sitting mode (Dine in, Take out) changes.
- Changed the getOrderChanges functionas below
- Identified and separated only note updates in line
- Added some required informations like comboline and attributes.
- Enabled Order button when sitting mode updated (Dinein <-> Takeout)
- For this we have saved the sittingMode data in last order changes.
Task: 4264433Combo products now behave more consistently in online sales: shoppers will not see unnecessary configuration steps, combo products are excluded from wishlists, and combo items follow the intended display order. Analytics reporting for combo prices is also corrected, improving sales tracking accuracy.
Original PR description
- Don't open the combo configurator in eCommerce if there's nothing to configure, - Don't allow combo products in the wishlist, - Order combo items by combo sequence instead of by selection order, - Fix the Google Analytics tracking price for combos. task-4264135 Closes https://github.com/odoo/odoo/issues/182464
PDF files encoded in base64 are now recognized and displayed with the standard PDF icon in the web interface. This makes file previews more consistent and helps users identify PDF attachments more easily.
Original PR description
In the o_image scss, add support for the 'application/pdf;base64' mimetype so that these files are also represented with the pdf background image. Task-4263142 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
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
Original PR description
Description of the issue/feature this PR addresses: Current behavior before PR: Desired behavior after PR is merged: --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
The Projects kanban view no longer counts linked documents just to decide whether to show the Documents menu item. This greatly improves loading performance for projects with many tasks, while the Documents menu may now appear even when no documents are present for users with folder access.
Original PR description
## Description Following a32825ee00f2b330d99113f4d8c1488903fe744e, the "Documents" menu-item is hidden when there are no documents in it. The presence of the field `document_count` in the view triggers `_compute_documents`, which is relatively slow for projects with a lot of tasks. It's not worth to incure the cost at each load of this view (which is a hot path) just for hiding a button in a sub-menu. ## Spec Change The menu-item "Documents" is present even if there are no document and you have differnet than `'none'` permission on the folder. ## Benchmark Loading "Projects" kanban view with 5 favourite projects, one of which has 1M+ tasks on next.odoo.com | | Before | After | Speedup | |---------------|--------|-------|---------| | Timings (hot) | 10.2s | 790ms | 12.9x |
Portal users now see only the document actions they are allowed to use, reducing confusion from unavailable options. Internal users also gain smoother uploading in the company documents area, while unavailable duplicate actions are hidden when not permitted.
Original PR description
We disable for portal user, the actions they cannot perform. In the "New" drop down button: - hide "Folder" (create Folder) - hide "Link" (create link) In the cog menu: - hide "Move to trash" - hide "Add shortcut" when the parent folder is not editable In the configure form: - hide lock/pinned toggle buttons - hide owner and partner_id - hide create_activity_option (alias) - hide Email Upload (alias) We also authorize internal user to upload in "My company" folder (which actually upload in the personal drive of the user). Task-4216243
The Documents app now shows selected pin-related menu actions with a standard checkmark instead of a pin icon. This makes the drop-down menu more consistent and easier to scan for users.
Original PR description
Specs: Replace the pin icons with the 'v' tick icon from the drop-down items. Technical: Remove the '<i class='fa fa-thumb-tack me-1'/>' pin icon and, based on a condition, add the 'selected' class to the existing 'o-dropdown-item dropdown-item' element. Task-4266470
The Documents app now uses a simpler and more consistent rule for identifying company folders: items owned by Odoobot with no parent folder. This makes the folder list and document view behave more consistently, while removing the older pinned-folder concept behind the scenes.
Original PR description
Purpose ======= Simplify the company folder domain. Now the domain is just the documents owned by Odoobot, and without a parent folder. The search panel now use the same domain, and so the only difference now between the kanban view and the search panel is that the search panel only show folders. Technical ========= Because the old `is_pinned_folder` is used in access rule, we can not just set it to False, it needs to reflect the owner_id / folder_id values (it will be cleaned in master). Task-4293841
The Documents list now shows clear icons for folders, links, and file types next to document names. This makes it easier for users to quickly recognize document types, with shortcuts highlighted in blue for better visibility.
Original PR description
Purpose ======= Show the documents types (folder, url and files mimetypes) using icons in the list view. Specification ============= Creating a new 'documents_type_icon" widget that can be displayed alongside the documents names. Reducing the 'type' column's width and removing the column title to make the type icon feel like a part of the document name. Also coloring the shortcuts in blue in the list view. Task-4263142
Resolved issues and error corrections
Removed leftover records and assets for a module that no longer exists. This prevents obsolete module data from appearing or causing confusion during system maintenance and upgrades.
Original PR description
The module was removed in odoo/enterprise@53098e18 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Features or functions removed from Odoo
The module was removed in odoo/enterprise@53098e18
Original PR description
The module was removed in odoo/enterprise@53098e18
Miscellaneous changes
When model selection field is used in a form, its default value is always one of the available values. Because of this, if the field is required, it does not force the user to pick a value, but it provides a possibly incorrect default value. This commit makes an empty value available for selection if no default value is chosen. The behavior is also made available on custom fields, if such an empty value had been manually created, it will be replaced by this implementation. Steps to
Original PR description
When model selection field is used in a form, its default value is always one of the available values. Because of this, if the field is required, it does not force the user to pick a value, but it provides a possibly incorrect default value. This commit makes an empty value available for selection if no default value is chosen. The behavior is also made available on custom fields, if such an empty value had been manually created, it will be replaced by this implementation. Steps to reproduce: - Install website_form_project - Add a form in a page - Select the "Create a Task" action - Add the "Analytic Account" field to the form - Make the field required => There was no way to have no default value by default. opw-4268164 Forward-Port-Of: odoo/odoo#185532 Forward-Port-Of: odoo/odoo#184842
Fixes an intermittent issue where manufacturing work orders could keep the wrong expected duration after producing serial-tracked items in batches. This helps production planning stay accurate and consistent for manufacturing teams.
Original PR description
This is a non-deterministic bug. Setup: - install mrp, enable workorders and serial numbers - create a storable product A with serial tracking - create a BOM with 1 operation for product A Steps: -…
This is a non-deterministic bug. Setup: - install mrp, enable workorders and serial numbers - create a storable product A with serial tracking - create a BOM with 1 operation for product A Steps: - create a MO for 2 units of product A -> the duration expected on the WO should be 120 minutes. - confirm then plan the MO - produce all -> you'll see a wizard for batch production (2nd wizard) - generate serials then produce or prepare MO (doesn't matter which) Issue: Sometimes the duration of the initial workorder is correctly computed -> 60 minutes, sometimes it is not (left as is). This is a mix of 2 'bugs': First, we have the `self.env['mrp.production'].browse` via a set(). Because it's a set, the productions received are not always in order, so the loop just after may process the last MO first. This triggers the 2nd 'bug'. Second, the first MO (that was planned) won't trigger `_compute_duration_expected` at https://github.com/odoo/odoo/blob/014ed907a2fab280e9fa6dd93b23a6a852700796/addons/mrp/wizard/mrp_batch_produce.py#L116 when changing `qty_producing` because of `is_planned`: https://github.com/odoo/odoo/blob/014ed907a2fab280e9fa6dd93b23a6a852700796/addons/mrp/models/mrp_production.py#L730-L731 instead, it will go through the compute later because the second MO (created in the split, but not planned) will trigger the compute for both ids via `recompute` because the original MO id was still in the pending transactions: https://github.com/odoo/odoo/blob/014ed907a2fab280e9fa6dd93b23a6a852700796/odoo/fields.py#L1413 However, the first workorder will already have its qty_producing set to 1 so won't pass in `_get_duration_expected`. Fix: Use `OrderedSet` instead of set along with `reversed()` so that the loop will process the last MO first. This way the pending compute for the original MO will correctly compute the duration because it's WO's qty_producing will still be zero. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Fixes an issue where previewing a canceled invoice with no invoice lines could show an error instead of opening the preview. The system now handles missing invoice line data safely, improving reliability for users reviewing incomplete or canceled invoices.
Original PR description
Currently, an error occurs when the user attempts to preview an invoice, and invoice has no invoice lines. Step to produce: - Install the ```account``` module. - Create a new invoice, add a customer name, and 'Cancel' this invoice. - Click on 'Preview' button(ensure that no invoice lines have been added). ```ValueError: Expected singleton: account.move()``` An error occurs when the system tries to get installment data from the move line at [1], and the move lines are not available in the invoice. Link [1]: https://github.com/odoo/odoo/blob/430656132044f8d675712d5b6cbfef807880d024/addons/account/models/account_move.py#L5411-L5412 To handle this issue, pass empty data for installments if the move line is not available in the invoice. Sentry-5978934688 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr
Fixed an issue where adding a down payment from purchase matching could reset a purchase order line back to the vendor’s default price. This preserves the price negotiated on the purchase order and helps avoid billing and reconciliation discrepancies.
Original PR description
### Steps to reproduce the issue: 1. Create a Product and add a Vendor Price under the Purchase tab 2. Create a Request for Quotation from the Vendor with the Product, change the Unit Price 3.…
### Steps to reproduce the issue: 1. Create a Product and add a Vendor Price under the Purchase tab 2. Create a Request for Quotation from the Vendor with the Product, change the Unit Price 3. Confirm Order 4. Create a Vendor Bill from the Vendor with one Invoice Line, click on "Purchase Matching" 5. Select the Invoice Line and click on "Add to PO" 6. Select the PO previously created and Add Down Payment 7. On the PO, the Unit Price on the Product Line has reverted to the Vendor Price ### Explanation: During `_create_downpayments`, `purchase.order.line` created from `account.move.line` are added to `purchase.order.order_line` through a concatenation operator (here a `+`, but `|` would have the same effect). With this operation, `purchase.order.order_line` is flagged as a modified value and needs to be totally recomputed. In the triggered recomputation methods is `_compute_price_unit_and_date_planned_and_name`, which affects multiple values including `unit_price` and uses `product_product.seller_ids`. https://github.com/odoo/odoo/blob/d0e7be7832672d476f1b289af52d3a425990d719/addons/purchase/models/purchase_order_line.py#L313-L318 https://github.com/odoo/odoo/blob/d0e7be7832672d476f1b289af52d3a425990d719/addons/purchase/models/purchase_order_line.py#L351-L358 ### Fix reasoning: With `Command.link`, only the added lines are flagged as new values and `purchase.order.order_line` is not recomputed. opw-4275163
This fixes a payroll/time off issue where changing an accrual allocation start date could leave old carryover expiration values in place, causing the displayed accrued days to become incorrect. Employees and HR teams will now see consistent, accurate time off balances when allocation dates are adjusted.
Original PR description
Steps to Reproduce: Create an accrual allocation: - Carryover date on allocation start date. - Has 1 level: * Start 0 days after allocation start date. * Accrues 1 day monthly on 1st day of the…
Steps to Reproduce:
Create an accrual allocation:
- Carryover date on allocation start date.
- Has 1 level:
* Start 0 days after allocation start date.
* Accrues 1 day monthly on 1st day of the month.
* Carryover policy all accrued time carried over.
* Carryover validity 1 month.
* Leave other options as is.
- Leave other options as is.
Create an allocation:
- Allocation type: accrual allocation.
- Accrual plan: use the one defined above.
- The following dates are in mm/dd/YYYY
- Set allocation start date 08/01/2023.
Number of days becomes 2 days (as expected).
- Set allocation start date 09/01/2023.
Number of day becomes 12 days (as expected).
- Set allocation start date 08/01/2023.
Number of days becomes 13 days (wrong).
The issue is that the expiration date of carried over days and the number of expiring days aren't reset when the start date of the allocation changes.
The fix is to reset these values when the start date of the allocation changes.
task-4208024This fix prevents an unexpected error screen when users save a customized view that contains an invalid context value. Instead of a technical traceback, the system can handle the invalid input more safely, improving reliability during view editing.
Original PR description
When the user edits the view and adds context with invalid syntax, a traceback will appear. Steps to reproduce the error: - Go to Settings > Technical > Views > Open any view - Add context = ``"[]"``…
When the user edits the view and adds context with invalid syntax,
a traceback will appear.
Steps to reproduce the error:
- Go to Settings > Technical > Views > Open any view
- Add context = ``"[]"`` or context = ``"{a}"`` like this in the view
- Save
Traceback:
```
UnboundLocalError: cannot access local variable 'err' where it is not associated with a value
File "odoo/http.py", line 2365, in __call__
response = request._serve_db()
File "odoo/http.py", line 1892, in _serve_db
return self._transactioning(
File "odoo/http.py", line 1955, in _transactioning
return service_model.retrying(func, env=self.env)
File "odoo/service/model.py", line 137, in retrying
result = func()
File "odoo/http.py", line 1922, in _serve_ir_http
response = self.dispatcher.dispatch(rule.endpoint, args)
File "odoo/http.py", line 2169, in dispatch
result = self.request.registry['ir.http']._dispatch(endpoint)
File "odoo/addons/base/models/ir_http.py", line 329, in _dispatch
result = endpoint(**request.params)
File "odoo/http.py", line 728, in route_wrapper
result = endpoint(self, *args, **params_ok)
File "home/odoo/src/enterprise/18.0/industry_fsm_report/controllers/main.py", line 10, in edit_view
action = super().edit_view(view_id, studio_view_arch, operations, model, context)
File "odoo/http.py", line 728, in route_wrapper
result = endpoint(self, *args, **params_ok)
File "home/odoo/src/enterprise/18.0/worksheet/controllers/main.py", line 10, in edit_view
action = super().edit_view(view_id, studio_view_arch, operations, model, context)
File "odoo/http.py", line 728, in route_wrapper
result = endpoint(self, *args, **params_ok)
File "home/odoo/src/enterprise/18.0/web_studio/controllers/main.py", line 695, in edit_view
self._set_studio_view(view, new_arch)
File "home/odoo/src/enterprise/18.0/web_studio/controllers/main.py", line 456, in _set_studio_view
studio_view.arch_db = arch
File "odoo/fields.py", line 1402, in __set__
records.write({self.name: write_value})
File "home/odoo/src/enterprise/18.0/web_studio/models/studio_mixin.py", line 33, in write
res = super(StudioMixin, self).write(vals)
File "odoo/addons/base/models/ir_ui_view.py", line 535, in write
res = super(View, self).write(self._compute_defaults(vals))
File "odoo/models.py", line 4750, in write
real_recs._validate_fields(vals, inverse_fields)
File "odoo/models.py", line 1599, in _validate_fields
check(self)
File "odoo/addons/base/models/ir_ui_view.py", line 413, in _check_xml
elif err.__context__:
```
https://github.com/odoo/odoo/blob/69b404c7109ff689381f56520aad758424ec01aa/odoo/addons/base/models/ir_ui_view.py#L413-L418
Here, the ``err`` variable is referenced before the assignment,
So, it will lead to the above traceback.
sentry-5993638522
---
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-prUnmerging multiple charts of accounts for the same company no longer fails with an unexpected error. This helps accounting users complete account structure changes reliably without manual workarounds.
Original PR description
Currently an error occurs when the user unmerges two or more charts of accounts with the same company. error: `ValueError: Expected singleton: account.account(1249, 1252, 163, 164, 165, 754)` This is because at [1] `self` used to display name here `self` contains multiple records. This commit will fix the above issue by looping records of self and using `display_name` of account, which is needed. [1]- https://github.com/odoo/odoo/blob/0bac60a7085c51ac8cb4f793b013dbea927d180c/addons/account/models/account_account.py#L1108 sentry-5985600163
Restoring a file from the trash now shows the correct error when its original folder was also moved to the trash. This helps users understand why the restore cannot be completed and keeps the message consistent with other document restore cases.
Original PR description
**Steps to reproduce:** Create a folder in 'My Drive' e.g: "New". Add 2 files in New folder. Open the folder and only select those 2 files and move them to trash. Now, go back to My drive, select that empty New folder and move it to Trash. Go to Trash workspace. Select one of the file and try to restore it. **Technical:** The folder whose parent has a folder_id 'False'. In the domain, we check the id and active status for the folder_id but since there is no folder_id, that record will not be considered as archived_top_parent_documents. **Specifications:** Show the appropriate error message when restoring from TRASH, consistent with the error for other documents. Task-4274176
The subscription customer portal now shows and uses the correct upcoming billing amount after an internal field name changed. This prevents customers from seeing an incorrect or missing next payment amount when managing subscription payments online.
Original PR description
Since #69952 the name of the final amount has been changed in the dict from `amount_total` to `total_amount` but not in the get. task-id: 4242134
Shared spreadsheet links now use the standard public documents page setup, preventing crashes when opened by viewers in debug mode or customized environments. This makes publicly shared spreadsheets more reliable and better aligned with other public document pages.
Original PR description
Steps to reproduce: - insert a pivot or a list in a spreadsheet - click on the Share button to share the spreadsheet - Choose "Viewer" for "Anyone with the link" - Copy the link and open it in an incognito window - in the URL, add ?debug=assets => boom This rendered page doesn't have `odoo.__session_info__` which crashes any code trying to read it. In standard, the view validation (only enabled in debug mode) reads it crash. On the saas, some custo also reads it and crashes. Two observations: - this page doesn't need the asset `documents.webclient` (in which is included the backend view stuff and the saas custo) - we can use the `documents.public_page_layout` which already includes `odoo.__session_info__` and the design is more aligned with the other documents public pages Note that I can't really write a test because nothing breaks in standard (except in debug mode) Task: 4297246
A test for Sendcloud delivery pickup locations now creates the required partner email information when demo data is not available. This prevents false test failures and helps keep delivery-related validation reliable across environments.
Original PR description
when running this test in no-demo mode, test was breaking as there was no email information created during test. Creating email information for partner fixes the issue. [link to runbot build errors](https://runbot.odoo.com/web#id=102115&menu_id=424&cids=1&action=573&model=runbot.build.error&view_type=form)
This fixes an issue where Odoo Studio could incorrectly combine two separate layout edits: adding a field in one group and removing another group. The change helps ensure Studio saves form customizations accurately, reducing the risk of unexpected layout changes for users.
Original PR description
…ifferent trees
Add a field at the end of the "left" subgroup and remove the "right" subgroup.
```xml
<form>
<group>
<group>
<field name="display_name" />
[ADD A FIELD]
</group>
[ REMOVE THIS GROUP
<group>
</group>
]
</group>
</form>
```
Before this commit, when "normalizing" the xpaths, the add field operation was aggregated with the remove operation because no unchanged node was found in between.
We were left with the inheriting view:
```xml
<xpath expr="[..]/group[2]" position="replace">
<field name="added_field" />
</xpath>
```
After this commit, this flow works and the two operations are independent.
part of task-4207793Use normalized emails for comparison to avoid issues linked to formatting. Task-4281171: [mail] {email/smtp}_from normalized comparison Forward-Port-Of: odoo/odoo#185766 Forward-Port-Of: odoo/odoo#185749
Original PR description
Use normalized emails for comparison to avoid issues linked to formatting.
Task-4281171: [mail] {email/smtp}_from normalized comparison
Forward-Port-Of: odoo/odoo#185766
Forward-Port-Of: odoo/odoo#185749Before this commit, opening the paid orders and searching for an existing order would not fetch the orders from the database. opw-4276187 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#185528
Original PR description
Before this commit, opening the paid orders and searching for an existing order would not fetch the orders from the database. opw-4276187 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#185528
On a stock move, when using a lot from a sub-location, the created SML will still start from SM's source location instead of lot's location To reproduce the issue: 1. In Settings, enable "Storage Locations" 2. Create a tracked-by-sn product P 3. Update its qty: - SN01 at WH/Stock - SN02 at WH/Stock/Shelf 1 4. Confirm a delivery with 1 x P 5. Enable the column "Serial Number" - SN01 should be present 6. Remove SN01, set SN02 7. Validate the transfer 8. Open the detailed op
Original PR description
On a stock move, when using a lot from a sub-location, the created SML will still start from SM's source location instead of lot's location To reproduce the issue: 1. In Settings, enable "Storage…
On a stock move, when using a lot from a sub-location, the created SML will still start from SM's source location instead of lot's location To reproduce the issue: 1. In Settings, enable "Storage Locations" 2. Create a tracked-by-sn product P 3. Update its qty: - SN01 at WH/Stock - SN02 at WH/Stock/Shelf 1 4. Confirm a delivery with 1 x P 5. Enable the column "Serial Number" - SN01 should be present 6. Remove SN01, set SN02 7. Validate the transfer 8. Open the detailed operations Result: SN02 has been taken from WH/Stock, but the user probably wanted to use the existing one, in WH/Stock/Shelf 1. An onchange already exists to make sure that the user is not using a lot that already exists somewhere else. Before Odoo 17.2, we were considering the sub locations as not expected: https://github.com/odoo/odoo/blob/d5a7a3d02e3e2b4e47977abc8b9fc0d5d6135937/addons/stock/models/stock_move.py#L1167 But since Odoo 17.2 (via [1]), we now also accept the sub locations: https://github.com/odoo/odoo/blob/60b0bafc8abd1893c9cdd9913617c234692369cf/addons/stock/models/stock_move.py#L1242 This is a bit confusing because we don't display any warning anymore, but we don't select the correct source location neither. The commit should help the user and avoid that confusion [1] https://github.com/odoo/odoo/commit/99b39b72c7e65e85af6f06dcb6b02867623f3f69 OPW-4231749 Forward-Port-Of: odoo/odoo#185796
Steps to reproduce: - Install `website_event_sale` - Go to an event and for one ticket set maximum as 1 - Open event page and purchase a ticket, but don't complete the payment - Do the same in private navigation - Click on pay on the two page Issues: If you check with stripe payment is processed meaning that the two people are charged however one of them can't get a ticket as there isn't enough tickets available. Fix is to check before sending payment to provider and return error if the
Original PR description
Steps to reproduce: - Install `website_event_sale` - Go to an event and for one ticket set maximum as 1 - Open event page and purchase a ticket, but don't complete the payment - Do the same in private navigation - Click on pay on the two page Issues: If you check with stripe payment is processed meaning that the two people are charged however one of them can't get a ticket as there isn't enough tickets available. Fix is to check before sending payment to provider and return error if there's not enough seats. Concurrency issue is not fully solved but would require much more precise timing, and a proper solution wouldn't be stable. opw-3772093 Forward-Port-Of: odoo/odoo#185698 Forward-Port-Of: odoo/odoo#173809
Update branding logo and icon in windows installer. Old forgotten task Task-2862802 Forward-Port-Of: odoo/odoo#185650
Original PR description
Update branding logo and icon in windows installer. Old forgotten task Task-2862802 Forward-Port-Of: odoo/odoo#185650
**Current behavior before PR:** Public channels were not being fetched when users clicked channel mentions, causing chat window title to display "New message" instead of their actual names. Additionally, bus channels were not added every time when threads were opened, preventing real-time messaging in some cases. **Desired behavior after PR is merged:** Implemented channel fetching on mention clicks and added bus channel subscription when opening threads, enabling proper channel nam
Original PR description
**Current behavior before PR:** Public channels were not being fetched when users clicked channel mentions, causing chat window title to display "New message" instead of their actual names. Additionally, bus channels were not added every time when threads were opened, preventing real-time messaging in some cases. **Desired behavior after PR is merged:** Implemented channel fetching on mention clicks and added bus channel subscription when opening threads, enabling proper channel name display and real-time messaging functionality. Task:[3899453](https://www.odoo.com/odoo/project/1519/tasks/3899453) --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#185697 Forward-Port-Of: odoo/odoo#174473
Currently, a traceback occurs when the user deletes a module which is having a gamification goal record. To reproduce this issue: 1) Install `sale` and `gamification` 2) Create a new `gamification challenge` record 3) Create a new `goal` in the gamification challenge 4) Make sure the goal has the definition as `Automatic: sum on a field` 5) Select the model as `account` 6) Uninstall the invoicing module and start the `challenge` of that gamification. Error:- ``` KeyError: Fals
Original PR description
Currently, a traceback occurs when the user deletes a module which is having a gamification goal record. To reproduce this issue: 1) Install `sale` and `gamification` 2) Create a new `gamification…
Currently, a traceback occurs when the user deletes a module which is having a gamification goal record. To reproduce this issue: 1) Install `sale` and `gamification` 2) Create a new `gamification challenge` record 3) Create a new `goal` in the gamification challenge 4) Make sure the goal has the definition as `Automatic: sum on a field` 5) Select the model as `account` 6) Uninstall the invoicing module and start the `challenge` of that gamification. Error:- ``` KeyError: False ``` The value of the model_id became `False` when the user deletes a module used in goal. This leads to a traceback as model_id is used for the reference of obj https://github.com/odoo/odoo/blob/d9603e93d2ab5e0b9fd1948dfd3e3bee20ede599/addons/gamification/models/gamification_goal.py#L164-L165 We can resolve this issue by adding `ondelete='cascade'` in the field definition. Where the record will be deleted if the corresponding model is uninstalled. sentry-4089991441 Forward-Port-Of: odoo/odoo#180307
When archiving an operation in a bom, currently it will unlink if from bom lines that had it set as their `Consumed in Operation`. However, it's not the case for byproducts, meaning that the byproducts lines will still display the now archived operation. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#185390 Forward-Port-Of: odoo/odoo#185093
Original PR description
When archiving an operation in a bom, currently it will unlink if from bom lines that had it set as their `Consumed in Operation`. However, it's not the case for byproducts, meaning that the byproducts lines will still display the now archived operation. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#185390 Forward-Port-Of: odoo/odoo#185093
Adds default value to a few required selection fields as currently a value is apparently set in the form (as the select field will pick the first value) but without having the value really set in the field, meaning that on save, the field will appear as invalid. Also, to be able to select the "almost default" value, you'd need to select another value then pick the first value again to properly set it in the field and be able to save the form. To avoid those issue, we can add a default value t
Original PR description
Adds default value to a few required selection fields as currently a value is apparently set in the form (as the select field will pick the first value) but without having the value really set in the field, meaning that on save, the field will appear as invalid. Also, to be able to select the "almost default" value, you'd need to select another value then pick the first value again to properly set it in the field and be able to save the form. To avoid those issue, we can add a default value to those fields corresponding to the current "default" value in the form. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#185477 Forward-Port-Of: odoo/odoo#184939
Issue: ====== clipboard data has ufeff characters in it. Steps to reproduce the issue: ============================= - Create a new note/todo - Add a link - Copy it - Visualise the data copied - It contains ufeff characters of the link Solution: ========= for web_editor: We remove the characters fron the text and html we put in the clipboard data. for html_editor: We dispatch a CLEAN command before selecting the content and we handle it by link_selection_plugin and we norm
Original PR description
Issue: ====== clipboard data has ufeff characters in it. Steps to reproduce the issue: ============================= - Create a new note/todo - Add a link - Copy it - Visualise the data copied - It contains ufeff characters of the link Solution: ========= for web_editor: We remove the characters fron the text and html we put in the clipboard data. for html_editor: We dispatch a CLEAN command before selecting the content and we handle it by link_selection_plugin and we normalize after after cloning the content opw-4029722 Forward-Port-Of: odoo/odoo#184372 Forward-Port-Of: odoo/odoo#182596
Currently the `report_stock_quantity` view third `UNION ALL` does a `generate_series` between the moves date and `now()` in case the move is not in done. This can lead to significant slowdowns when querying the view in case some databases have old moves not in done, cancel, draft. In that case, the report will generate a row for each day between the move.date and `now()`, leading to thousands of rows for 1 stock.move. To alleviate that, this commit uses the `report_period` as a lower bound
Original PR description
Currently the `report_stock_quantity` view third `UNION ALL` does a `generate_series` between the moves date and `now()` in case the move is not in done. This can lead to significant slowdowns when querying the view in case some databases have old moves not in done, cancel, draft. In that case, the report will generate a row for each day between the move.date and `now()`, leading to thousands of rows for 1 stock.move. To alleviate that, this commit uses the `report_period` as a lower bound. This greatly reduces the number of rows generated by the third `UNION ALL` without losing forecasted accuracy since the moves are not in done. #### speedup In a v17 database where `all_sm` returns 600 000 rows, querying the `report_stock_quantity` view goes from 20s -> 7s. --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#184998 Forward-Port-Of: odoo/odoo#179359
Currently it can happen that slightly changing the amount in (document) currency (field `amount_currency`) i.e. on a tax line can lead to an unbalanced move. (See example and "Reproduce" below.) The issue is the syncing (function `_sync_invoice`) between - amount in currency (document currency; field `amount_currency`) and - balance (company currency; field `balance`). There we update the amount in currency in case the balance is changed and the amount in currency is not changed. But
Original PR description
Currently it can happen that slightly changing the amount in (document) currency (field `amount_currency`) i.e. on a tax line can lead to an unbalanced move. (See example and "Reproduce" below.) The…
Currently it can happen that slightly changing the amount in (document)
currency (field `amount_currency`) i.e. on a tax line can lead to an
unbalanced move. (See example and "Reproduce" below.)
The issue is the syncing (function `_sync_invoice`) between
- amount in currency (document currency; field `amount_currency`) and
- balance (company currency; field `balance`).
There we update the amount in currency in case the balance is changed
and the amount in currency is not changed.
But this is problematic in case we want (in the same write) set
a different amount in currency but explicitly set the same balance
(and not just not write anything to the `balance` field).
Since we write the same balance it is not detected as a
change and we update the balance based on the amount in currency.
But this should not happen; the balance should be "protected"
from being updated (since it is the value we explicitly want).
This can i.e. cause the balance of the receivable line to receive the wrong value
I.e. consider the following case; with currency rate = 2 (also see "Reproduce" below)
Journal Items:
- product 1: amount in currency = -1000.00 €, balance = -500.00
- product 2: amount in currency = -200.00 €, balance = -100.00
- tax line 1: amount in currency = -180.03 €, balance = -90.02
- tax line 2: amount in currency = -30.00 €, balance = -15.00
- Receivable: amount in currency = -1410.03 €, balance = 705.02
And we modify tax line 2: amount in currency = -29.99 €.
Then first we set the correct values because we basically compute the
receivable line by summing the other lines:
Journal Items:
- product 1: amount in currency = -1000.00 €, balance = -500.00
- product 2: amount in currency = -200.00 €, balance = -100.00
- tax line 1: amount in currency = -180.03 €, balance = -90.02
- tax line 2: amount in currency = -29.99 €, balance = -15.00
- Receivable: amount in currency = -1410.02 €, balance = 705.02
So we have set the balance to the same as before but changed the
amount in currency. So then we recompute the balance on the receivable
line from the amount in currency due to the syncing (`_sync_invoice`)
Journal Items:
- product 1: amount in currency = -1000.00 €, balance = -500.00
- product 2: amount in currency = -200.00 €, balance = -100.00
- tax line 1: amount in currency = -180.03 €, balance = -90.02
- tax line 2: amount in currency = -29.99 €, balance = -15.00
- Receivable: amount in currency = -1410.02 €, balance = 705.01
But now the move is not balanced (the sum of the balances should be 0)
-500.00 + -100.00 + -90.02 + -15.00 = -705.02 (and not -705.01)
After this commit we "protect" the balance and amount in currency from
being updated by `_sync_invoice` in case the surrounding `write`
sets the balance (`balance`) or amount in currency (`amount_currency`)
respectively.
Reproduce: (c.f. example above)
1. Select company "My Company (San Francisco)"
2. Ensure EUR currency is activated and has value 2 unit per USD
(at the time of the invoice that will be created further below)
3. Copy the 15% tax
4. Create a new invoice in EUR with 2 lines
(1) qty = 1, unit price = 1000, taxes = 15%
(2) qty = 1, unit price = 200, taxes = 15%, 15% (Copy)
5. There should be 2 tax lines in the "Journal Items" tab
(1) amount in currency = -180.00 €, credit = 90.00 USD
(2) amount in currency = -30.00 €, credit = 90.00 USD
6. Modify tax line (1); set amount in currency to -180.03 €
and save.
The credit will be updated to 90.02 USD.
7. Modify tax line (2); set amount in currency to -29.99 €
and try to save
8. An "Invalid Operation" error is raised:
The move (Draft Invoice ) is not balanced.
The total of debits equals $ 705.01 and the total of credits equals $ 705.02.
Forward-Port-Of: odoo/odoo#185757
Forward-Port-Of: odoo/odoo#171705
**Note**
Compared to previous versions the `amount_currency` is not updated
anymore in `_sync_invoice` (only the `balance`).Before this commit, when a payable account was used on a customer invoice, or a receivable account on a vendor bill, an error message was raised saying "Any journal item on a receivable/payable account must have a due date and vice versa.". This was unclear, and caused for example confusion when importing the accounting history. Therefore, we now handle this case with a new error message. opw-4196597 Forward-Port-Of: odoo/odoo#185696 Forward-Port-Of: odoo/odoo#182979
Original PR description
Before this commit, when a payable account was used on a customer invoice, or a receivable account on a vendor bill, an error message was raised saying "Any journal item on a receivable/payable account must have a due date and vice versa.". This was unclear, and caused for example confusion when importing the accounting history. Therefore, we now handle this case with a new error message. opw-4196597 Forward-Port-Of: odoo/odoo#185696 Forward-Port-Of: odoo/odoo#182979
Steps to reproduce: 1. Go to a website page (in edit mode) > Switch the header template to `"Menu with Search Bar"`. 2. Set a highlight effect on the text element in the top section of the header. 3. The highlight keeps adapting itself infinitely. Technical details: After [1], two header navbars were added in the DOM (for the desktop view and mobile). Which means that the targeted text field is also duplicated and every change on it in Desktop will be reflected in the "invisib
Original PR description
Steps to reproduce: 1. Go to a website page (in edit mode) > Switch the header template to `"Menu with Search Bar"`. 2. Set a highlight effect on the text element in the top section of the header. 3.…
Steps to reproduce:
1. Go to a website page (in edit mode) > Switch the header template to
`"Menu with Search Bar"`.
2. Set a highlight effect on the text element in the top section of the header.
3. The highlight keeps adapting itself infinitely.
Technical details:
After [1], two header navbars were added in the DOM (for the desktop
view and mobile). Which means that the targeted text field is also
duplicated and every change on it in Desktop will be reflected in the
"invisible" mobile version.
When the text is highlighted, the highlight observers are also adapting
the content on both navbars... To understand the conflict, here is an
example of the behaviour causing the infinite loop:
**a.** DESKTOP TEMPLATE > Set a highlight on the text field:
```xml
<span class="o_text_highlight">
<span class="o_text_highlight_item">
Text content.
<svg.../> // SVG adapted to text dimensions.
</span>
```
**b.** MOBILE TEMPLATE > The "field observer" will set the same content on
the "invisible" mobile version:
```xml
<span class="o_text_highlight">
<span class="o_text_highlight_item">
Text content.
<svg.../> // SVG adapted to the desktop text dimensions.
</span>
```
**c.** MOBILE TEMPLATE > The "highlights adaptation system" detects the
changes on the hidden mobile field and adapts the highlight:
```xml
<span class="o_text_highlight">
<span class="o_text_highlight_item">
Text content.
<svg.../> // SVG adapted to the mobile text dimensions (0×0).
</span>
```
**d.** DESKTOP TEMPLATE > The "field observer" will set the same content on
the desktop version, which automatically triggers the highlight size adaptations...
**e.** Same as [**b**].
Infinitely...
In this very specific case, the text content is the same, only the
highlight path is different (because one of the field duplicates is
visible, and the other is hidden).
The goal of this commit is to fix this behaviour by preventing the
highlight's mutation observer from adapting invisible content.
This way, the field synchronization mechanism will always set the same
highlight SVG on the hidden duplicate too (*).
[1]: https://github.com/odoo/odoo/pull/119650
(*): Remarks:
- This won't have an impact on the saved content: We remove all size
related DOM (SVG paths, line breaks,...) before the "save" and we
only keep minimal information needed to rebuild the highlights.
- Also, having a non-adapted effect on the hidden copy of the field is
not an issue here since the "highlight resize observer" will immediately
fix it once displayed (e.g. when switching to mobile preview).
opw-4183587
task-4270159
Forward-Port-Of: odoo/odoo#183414Payments initiated by the customer from the payment form could sometimes lead to multiple charges if a webhook notification would arrive at the same time as the payment request's response. This is due to the webhook acquiring a lock in the database when updating the transaction's state, followed by the processing of the payment request's response trying to do the same and thus encountering a concurrent access error. The payment request is thus retried and a new charge is created on Adyen side.
Original PR description
Payments initiated by the customer from the payment form could sometimes lead to multiple charges if a webhook notification would arrive at the same time as the payment request's response. This is due to the webhook acquiring a lock in the database when updating the transaction's state, followed by the processing of the payment request's response trying to do the same and thus encountering a concurrent access error. The payment request is thus retried and a new charge is created on Adyen side. This commit fixes the issue by passing an idempotency key with the payment request. If a payment request is inadvertently retried, Adyen silently ignores it and returns the same response as for the initial request. The response is processed again in Odoo and the customer is smoothly redirected to the payment landing page. Forward-Port-Of: odoo/odoo#185720 Forward-Port-Of: odoo/odoo#184919
When being order-based, several registrations are used to create a new lead. In some cases we might end up with several possible langs due to multiple visitors. We should take the first found one, as lang is a m2o on lead model. When running on registrations without linked SO, registrations are grouped by "event" in case of group-based lead generation. We should also group by create_date, as same event - same create_date indicates tickets belong to the same "group". Task-3940853 C
Original PR description
When being order-based, several registrations are used to create a new lead. In some cases we might end up with several possible langs due to multiple visitors. We should take the first found one, as lang is a m2o on lead model. When running on registrations without linked SO, registrations are grouped by "event" in case of group-based lead generation. We should also group by create_date, as same event - same create_date indicates tickets belong to the same "group". Task-3940853 Co-Authored-By: Jeremy Hennecart <jeh@odoo.com> Forward-Port-Of: odoo/odoo#185154 Forward-Port-Of: odoo/odoo#182138
Steps to reproduce ================== - Install stock,mrp,web_studio - Go to Inventory > Delivery Orders - Open WH/OUT/00001 - Open studio - On the x2many field, click on "Edit form" -> Studio switches to that view, - Click on "Edit form" again for the new lines - Exit studio - Click on the hamburger button -> The styling is broken Cause of the issue ================== When clicking on "Edit form", studio inlines the selected form view. The nosheet form style is only applied if
Original PR description
Steps to reproduce ================== - Install stock,mrp,web_studio - Go to Inventory > Delivery Orders - Open WH/OUT/00001 - Open studio - On the x2many field, click on "Edit form" -> Studio switches to that view, - Click on "Edit form" again for the new lines - Exit studio - Click on the hamburger button -> The styling is broken Cause of the issue ================== When clicking on "Edit form", studio inlines the selected form view. The nosheet form style is only applied if the form contains no sheet element. In this case, there is a sheet element, but inside a nested form. Solution ======== Only consider sheets if they are part of the current form view. opw-4130337 Forward-Port-Of: odoo/odoo#185616 Forward-Port-Of: odoo/odoo#185504
The password reset email was not being translated according to the receiver's language. This caused the template to render in the website language, leading to confusion for receivers with different language. The problem came form Convert the "Reset Password" template into QWeb view in https://github.com/odoo/odoo/pull/125874, Before, to sent the email `mail.send_mail()` function was used, and it has a check for the receiver language. and after https://github.com/odoo/odoo/pull/125874 th
Original PR description
The password reset email was not being translated according to the receiver's language. This caused the template to render in the website language, leading to confusion for receivers with different…
The password reset email was not being translated according to the receiver's language. This caused the template to render in the website language, leading to confusion for receivers with different language. The problem came form Convert the "Reset Password" template into QWeb view in https://github.com/odoo/odoo/pull/125874, Before, to sent the email `mail.send_mail()` function was used, and it has a check for the receiver language. and after https://github.com/odoo/odoo/pull/125874 the function wasnt used any more. it replaces with `mail.send()` that send the rendered content directly. To resolve this issue, the language of the receiver user is explicitly set in the context before rendering the email template. This ensures the email content is translated based on the user's preferred language then calling the function that send it. Now the template is rendered using the receiver's language (`user.lang`), or falls back to the website language `self.env.lang` if the receiver's language is not set. Or falls back to 'en_US' if the language is not set. owp-4149894 --- I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr Forward-Port-Of: odoo/odoo#182635
Currently, when sending a Bis 3 xml to Pagero, which in turn sends it to Chorus Pro, the invoice is rejected by Chorus. This is because the `PartyIdentification` tag for the `AccountingSupplierParty` should be filled with the siret of the supplier if it is located in France, or with the VAT if it is located in the EU. Surprisingly, the xml received by Chorus contains a `PartyIdentification` that has most probably be added by Pagero, but it is filled with a VAT, and causes a rejection from
Original PR description
Currently, when sending a Bis 3 xml to Pagero, which in turn sends it to Chorus Pro, the invoice is rejected by Chorus. This is because the `PartyIdentification` tag for the `AccountingSupplierParty` should be filled with the siret of the supplier if it is located in France, or with the VAT if it is located in the EU. Surprisingly, the xml received by Chorus contains a `PartyIdentification` that has most probably be added by Pagero, but it is filled with a VAT, and causes a rejection from Chorus since the supplier is french. opw-4139689 Forward-Port-Of: odoo/odoo#184871
**Current behavior:** Selling a kit bom product will result in inaccurate journal entries in the stock output and expense accounts, the amount_currency field will only reflect the price unit of the kit's components. **Expected behavior:** The price unit should reflect the total cost of the components on the BoM: e.g., if a kit product needs 4 of some component1, the price unit should be 4 * component1.standard_price. **Steps to reproduce:** 1. Create a kit product with 2 components, bot
Original PR description
**Current behavior:** Selling a kit bom product will result in inaccurate journal entries in the stock output and expense accounts, the amount_currency field will only reflect the price unit of the…
**Current behavior:** Selling a kit bom product will result in inaccurate journal entries in the stock output and expense accounts, the amount_currency field will only reflect the price unit of the kit's components. **Expected behavior:** The price unit should reflect the total cost of the components on the BoM: e.g., if a kit product needs 4 of some component1, the price unit should be 4 * component1.standard_price. **Steps to reproduce:** 1. Create a kit product with 2 components, both with qty > 1 2. Assign dropshipping to the kit 3. Create a sale order and confirm -> confirm the purchase order 4. Validate the dropship transfer, invoice the sale order and post it 5. See the 2 inaccurate journal entries, where the debit/credit respectively only total to one instance of each component's cost added together **Cause of the issue:** The price unit calculation didn't look at the bom line product qty, only using the price unit 1 time per component. **Fix:** Multiply the value by the quantity of it required on its line in the BoM. opw-4253827 Forward-Port-Of: odoo/odoo#185247 Forward-Port-Of: odoo/odoo#183916
As VISA added more mandatory fields to perform payments, the holder's name is required now for the customer to fill when paying with adyen. opw-4085163 Forward-Port-Of: odoo/odoo#185489 Forward-Port-Of: odoo/odoo#185253
Original PR description
As VISA added more mandatory fields to perform payments, the holder's name is required now for the customer to fill when paying with adyen. opw-4085163 Forward-Port-Of: odoo/odoo#185489 Forward-Port-Of: odoo/odoo#185253
Add support for connecting to the MyInvois API, in order to send and receive E-Invoices. see https://github.com/odoo/iap-apps/pull/849 Task id # 3953659 Forward-Port-Of: odoo/odoo#174813
Original PR description
Add support for connecting to the MyInvois API, in order to send and receive E-Invoices. see https://github.com/odoo/iap-apps/pull/849 Task id # 3953659 Forward-Port-Of: odoo/odoo#174813
Issue found at commit: https://github.com/odoo/odoo/commit/0e8f3d5c42b4f219e4e7db6915dd1dd7ec45e4b4 After the above mentioned commit when using eWaybill with e-Invoicing the log note of ewaybill i.e. ``` E-wayBill Sent Number -> 0 Validity -> None ```  where as in the response attachment of eWaybill, the ewaybill number does exist In this commit, we resolve the above issue and the correct ewaybil
Original PR description
Issue found at commit: https://github.com/odoo/odoo/commit/0e8f3d5c42b4f219e4e7db6915dd1dd7ec45e4b4 After the above mentioned commit when using eWaybill with e-Invoicing the log note of ewaybill i.e. ``` E-wayBill Sent Number -> 0 Validity -> None ```  where as in the response attachment of eWaybill, the ewaybill number does exist In this commit, we resolve the above issue and the correct ewaybill number gets logged opw-4280093 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#185680
Version: 17.0+ Issue: In the Deferred Expense Report, there is a missing check for if the `period_end` is before the `period_start` for when the deferred method is 'day'. If the `period_end` is in the same month as selected month of the report, the later column will compute the amount to be negative of the `amount_per_day` times the difference of days. For example, if the end date is 2024-11-04 and we look at the month of November, the later column will display the negative amount of 26
Original PR description
Version: 17.0+ Issue: In the Deferred Expense Report, there is a missing check for if the `period_end` is before the `period_start` for when the deferred method is 'day'. If the `period_end` is in the same month as selected month of the report, the later column will compute the amount to be negative of the `amount_per_day` times the difference of days. For example, if the end date is 2024-11-04 and we look at the month of November, the later column will display the negative amount of 26 days. In this example the amount is expected to be 0. Purpose of this PR: To add an additional condition, if the `period_end` is before the `period_start` then the amount should be 0. opw-4231549 Forward-Port-Of: odoo/enterprise#72644
Before this commit, next appointment was shown on a table even if this appointment was not for today. We not only allow to show today's appointment on the floor screen. task-id: 4285487 Forward-Port-Of: odoo/enterprise#72762
Original PR description
Before this commit, next appointment was shown on a table even if this appointment was not for today. We not only allow to show today's appointment on the floor screen. task-id: 4285487 Forward-Port-Of: odoo/enterprise#72762
This pr is created to help de user to know the origin of the afip error 10016. The error 10016 can be caused by different origins, so here we give the user more precision about the origin. The objective of this pr is to be able to differentiate what is the origin of error 10016 and to be able to give a more precise message to the client. 1) If the last afip invoice validated has a higher date than the date of the invoice that is being validated then the message shown to the user is '10016-
Original PR description
This pr is created to help de user to know the origin of the afip error 10016. The error 10016 can be caused by different origins, so here we give the user more precision about the origin. The…
This pr is created to help de user to know the origin of the afip error 10016.
The error 10016 can be caused by different origins, so here we give the user more precision about the origin. The objective of this pr is to be able to differentiate what is the origin of error 10016 and to be able to give a more precise message to the client.
1) If the last afip invoice validated has a higher date than the date of the invoice that is being validated then the message shown to the user is '10016-1': 'The invoice date cannot be after the last invoice validated in AFIP.'
2) If the last afip invoice number is higher than the current invoice number being validated in Odoo, then the message shown to the user is '10016-2': 'There may have been a mismatch in the numbering of this type of document between Odoo and AFIP.'
3) If any other reason cause the error '10016' then the message shown to the user is:
* Please note that if you are trying to validate an invoice with a date other than today, you must verify if it falls within the date range according to the AFIP concept or document type:
a) If it is Product: N+5 or N-5 with N being today's date.
b) If it is Services or Products and services: N+10 or N-10 with N being today's date.
c) If it is a MiPyme Invoice: N-5 0 N+1 with N being today's date. For Debit Note or Credit Note only N-5"
Task Adhoc side: 37771
Task latam side: 1194
This pr replaces https://github.com/odoo/enterprise/pull/65675
Forward-Port-Of: odoo/enterprise#72901
Forward-Port-Of: odoo/enterprise#72656When this report contained too many lines (~6000), the browser couldn't handle the load and did not manage to render it. This is a known case, which normally only happens with line expansion, for which the prefix groups and load more features have been made. In this case, though, it's a bit different, as those lines are directly at the root of the report (they don't come from a line expansion). We make the choice here to use the load_more_limit anyway as a means to put a limit to the number of l
Original PR description
When this report contained too many lines (~6000), the browser couldn't handle the load and did not manage to render it. This is a known case, which normally only happens with line expansion, for…
When this report contained too many lines (~6000), the browser couldn't handle the load and did not manage to render it. This is a known case, which normally only happens with line expansion, for which the prefix groups and load more features have been made. In this case, though, it's a bit different, as those lines are directly at the root of the report (they don't come from a line expansion). We make the choice here to use the load_more_limit anyway as a means to put a limit to the number of lines that are shown. When this limit is reached, we just don't display the exceeding lines, and replace them by a summary line. To avoid confusion, a warning is now shown on top of the report when some lines need to be hidden. Since such a warning requires a module update (because it's a template, and needs to exist in db), we only apply our new trimming mechanism if the warning template exists (and can hence be displayed). This way, we won't change the behavior on existing databases without being sure the user is properly notified. Plus, thanks to that, we're sure the old load_more_limit value (originally 80 by default) set on the VAT Book will have been increased to a value fitting our use case more, so we won't bother people with excessive trimming. Original fix suggestion raised here by Adhoc: https://github.com/odoo/enterprise/pull/45936 Forward-Port-Of: odoo/enterprise#72836 Forward-Port-Of: odoo/enterprise#72096
**Current behavior:** Return labels are being generated with the `shipper` field set to the partner defined on the delivery picking (i.e., customer). **Expected behavior:** `shipper` should match the `ship_to` field (the original sender) as this field informs who gets billed for the return shipment. **Steps to reproduce:** Generate a return label with `delivery_ups_rest`. **Cause of the issue:** The return label is generated with `shipper=picking.partner_id`. **Fix:** Set it to
Original PR description
**Current behavior:** Return labels are being generated with the `shipper` field set to the partner defined on the delivery picking (i.e., customer). **Expected behavior:** `shipper` should match the `ship_to` field (the original sender) as this field informs who gets billed for the return shipment. **Steps to reproduce:** Generate a return label with `delivery_ups_rest`. **Cause of the issue:** The return label is generated with `shipper=picking.partner_id`. **Fix:** Set it to `shipper=picking.picking_type_id.warehouse_id.partner_id` (which matches the `ship_to` argument). opw-4147118 Forward-Port-Of: odoo/enterprise#72482
Before this commit currently when creating a new app using Studio the previous button icon in the navbar appears in the wrong direction After this commit The previous button icon should appear in the right direction Task - 3845561 Forward-Port-Of: odoo/enterprise#72674 Forward-Port-Of: odoo/enterprise#61835
Original PR description
Before this commit currently when creating a new app using Studio the previous button icon in the navbar appears in the wrong direction After this commit The previous button icon should appear in the right direction Task - 3845561 Forward-Port-Of: odoo/enterprise#72674 Forward-Port-Of: odoo/enterprise#61835
Steps to reproduce: - Switch to 'FR company' > New employee > New contract (Use defaults) - Payroll app > Payslips > All Payslips - New Payslip for your employee using a french structure (like 'cadre') - Compute sheet > Salary computation tab - (Maybe set 'Salary Journal' in Configuration > Structures if needed) Salary rule codes were translated leading to confusion in the fields to fetch when computing payroll sheets. opw-4240326 Forward-Port-Of: odoo/enterprise#72872
Original PR description
Steps to reproduce: - Switch to 'FR company' > New employee > New contract (Use defaults) - Payroll app > Payslips > All Payslips - New Payslip for your employee using a french structure (like 'cadre') - Compute sheet > Salary computation tab - (Maybe set 'Salary Journal' in Configuration > Structures if needed) Salary rule codes were translated leading to confusion in the fields to fetch when computing payroll sheets. opw-4240326 Forward-Port-Of: odoo/enterprise#72872
**Steps to reproduce:** - Install Accounting - Go to Accounting settings - Disable "Checks" option (A warning pops up infoming that "account_check_printing" module will be uninstalled) - Save **Issue:** A traceback is raised because it tries to access some fields that are defined in "account_check_printing" module. **Cause:** After uninstallation of "account_check_printing" module, the settings page is reloaded. However, this reload is performed with an old version of the env where
Original PR description
**Steps to reproduce:** - Install Accounting - Go to Accounting settings - Disable "Checks" option (A warning pops up infoming that "account_check_printing" module will be uninstalled) - Save…
**Steps to reproduce:** - Install Accounting - Go to Accounting settings - Disable "Checks" option (A warning pops up infoming that "account_check_printing" module will be uninstalled) - Save **Issue:** A traceback is raised because it tries to access some fields that are defined in "account_check_printing" module. **Cause:** After uninstallation of "account_check_printing" module, the settings page is reloaded. However, this reload is performed with an old version of the env where the fields defined in the uninstalled module are still there. It's coming from an override of "execute" method of "res.config.settings" defined in Accounting module. This override is checking if "sign_invoice" field is enable in order to install Sign module. This action is performed after the "execute" on "super()". If the "execute" is uninstalling a module, the "env" is reset as some models or fields may not be present anymore. However, in the override of the "execute" method, the old "env" is still used and non-existent fields are prefetched. **Solution:** Check to install Sign module in the override of "execute" method before executing the one from "super()" to prevent using an expired "env". opw-4251932 Forward-Port-Of: odoo/enterprise#72227
**Steps to reproduce:** 1. In the Sign app, create a sign request for a partner. 2. From the sign request email, cancel the request as the public user (partner). 3. The cancellation log is created without a partner assigned. **Issue:** When a public user (partner) cancels a sign request, the cancellation log entry does not have a partner_id. **Cause:** The partner_id was set as none when there was a public user **Solution:** Assign the partner_id to the sign log during the cre
Original PR description
**Steps to reproduce:** 1. In the Sign app, create a sign request for a partner. 2. From the sign request email, cancel the request as the public user (partner). 3. The cancellation log is created without a partner assigned. **Issue:** When a public user (partner) cancels a sign request, the cancellation log entry does not have a partner_id. **Cause:** The partner_id was set as none when there was a public user **Solution:** Assign the partner_id to the sign log during the creation. task-4213637 Forward-Port-Of: odoo/enterprise#71335
This commit aims to fix an issue in the sanitize_communication function and move its logic to the account_batch_payment module to improve reusability and testability. The function trims the communication text after removing the '/' characters. However, if the communication text contains '/' and is truncated, the '/' could end up at the end of the string (see tests for more examples). The solution is to remove the '/' after truncating the text. Additionally, the sanitize_communication funct
Original PR description
This commit aims to fix an issue in the sanitize_communication function and move its logic to the account_batch_payment module to improve reusability and testability. The function trims the communication text after removing the '/' characters. However, if the communication text contains '/' and is truncated, the '/' could end up at the end of the string (see tests for more examples). The solution is to remove the '/' after truncating the text. Additionally, the sanitize_communication function has been moved to the account_batch_payment module, since this module is a dependency for both account_sepa and account_sepa_direct_debit, these two modules can now use it as well. The functions sanitize_communication and _sanitize_communication have been marked as deprecated and will be removed in the master branch. opw-4220421 Forward-Port-Of: odoo/enterprise#72883 Forward-Port-Of: odoo/enterprise#71552
Some reports have been edited to have qweb default content that was meant to only be used from within studio. ```xml <t t-field="some_field">studio placeholder</t> ``` This content is displayed if the evaluated value is either False or None. This can also happen outside studio, if the field is not required. An attribute `data-oe-demo` was introduced for t-fields. ```xml <t t-field="some_field" data-oe-demo="studio placeholder"/> ``` This attribute was introduced for t-field no
Original PR description
Some reports have been edited to have qweb default content that was meant to only be used from within studio. ```xml <t t-field="some_field">studio placeholder</t> ``` This content is displayed if the evaluated value is either False or None. This can also happen outside studio, if the field is not required. An attribute `data-oe-demo` was introduced for t-fields. ```xml <t t-field="some_field" data-oe-demo="studio placeholder"/> ``` This attribute was introduced for t-field nodes in order to only display placeholder content inside the report editor. We didn't introduce it for `t-out` as it was possible to change the expression `<t t-out="obj.prop"/>` -> `<t t-out="obj.prop or ''"/>` While this definitely works, the attribute better signals the intent of the change. We thus add support for the attribute on t-out. Forward-Port-Of: odoo/enterprise#72967
Steps to reproduce: 1. Go to documents on mobile 2. Click on doc thumbnail 3. The inspector open where preview should open When the preview is open, click on an arrow to see the previous or the next doc 1. The inspector opens again where the previous or next should Technical Reason: In 'documents_inspector.js' file, a condition set only open the inspector if there is only one selected element, so every time it get executed and opens the inspector. After this commit: 1. Click on a
Original PR description
Steps to reproduce: 1. Go to documents on mobile 2. Click on doc thumbnail 3. The inspector open where preview should open When the preview is open, click on an arrow to see the previous or the next doc 1. The inspector opens again where the previous or next should Technical Reason: In 'documents_inspector.js' file, a condition set only open the inspector if there is only one selected element, so every time it get executed and opens the inspector. After this commit: 1. Click on a doc thumbnail, the preview will open. 2. When the preview is open, click on an arrow to see the previous or the next doc will not open the inspector. Task-3919285 Forward-Port-Of: odoo/enterprise#72677 Forward-Port-Of: odoo/enterprise#62957