Monday, April 21, 2025
5 changes
3 changes
Miscellaneous changes
Before thos commit, the next invoice date was updated at post invoice based on the order line properties. pre paid lines are will use the last deferred end date of the linked account move lines and post paid line simply increment the next invoice date. Before this commit, the post paid detection was faulty: we checked that all line were postpaid but if line notes or non recurring lines existed, they would not have the postpaid property. As a result, the next invoice date would be incremented
Original PR description
Before thos commit, the next invoice date was updated at post invoice based on the order line properties. pre paid lines are will use the last deferred end date of the linked account move lines and post paid line simply increment the next invoice date. Before this commit, the post paid detection was faulty: we checked that all line were postpaid but if line notes or non recurring lines existed, they would not have the postpaid property. As a result, the next invoice date would be incremented with the prepaid condition. As a result, the next invoice date would only be incremented by one day and the cron would run on these contracts every day. opw-4618947 opw-4668741 opw-4686930 Forward-Port-Of: odoo/enterprise#83756 Forward-Port-Of: odoo/enterprise#83438
Currently, a traceback is occurring when trying to approve a leave having the same time off with the refused state of another leave. <b>To reproduce this issue:</b> 1) Install planning_holidays without demo 2) Enable flexible hours for the working schedules of an employee 3) Create two time-offs for an employee with the same date and time 4) Refuse the first one and try to approve the second one <b>Issue:-</b> ``` ValueError: Expected singleton: hr.leave(5, 6) ``` When ther
Original PR description
Currently, a traceback is occurring when trying to approve a leave having the same time off with the refused state of another leave. <b>To reproduce this issue:</b> 1) Install planning_holidays…
Currently, a traceback is occurring when trying to approve a leave having the same time off with the refused state of another leave. <b>To reproduce this issue:</b> 1) Install planning_holidays without demo 2) Enable flexible hours for the working schedules of an employee 3) Create two time-offs for an employee with the same date and time 4) Refuse the first one and try to approve the second one <b>Issue:-</b> ``` ValueError: Expected singleton: hr.leave(5, 6) ``` When there are more than one leave record with different states, leave_date will search the record based on the employee, date and time only. https://github.com/odoo/enterprise/blob/747482f34ca8210d89d81b3363ec5a8fc3a4ff6f/planning_holidays/models/resource_calendar.py#L16-L24 So indeed we get multiple records, and this leads to the above traceback when accessing values from the leave_data. <b>Solution:-</b> Make the domain of leave_data more robust by including the state containing no refused leaves. opw-4712858,4700495 Forward-Port-Of: odoo/enterprise#83354
Currently a traceback is occurring when the user tries to create an invoice payment with referrer in invoice. <b>To reproduce this issue:</b> 1) Install partner_commission without demo 2) Create a commission plan from crm with a rule containing category and rate 3) Create a product with the same category used in the above commission rule 4) Create a contact with commission plan and partner level in partner assignment 5) Create a confirmed customer invoice with line as above product
Original PR description
Currently a traceback is occurring when the user tries to create an invoice payment with referrer in invoice. <b>To reproduce this issue:</b> 1) Install partner_commission without demo 2) Create a…
Currently a traceback is occurring when the user tries to create an invoice payment with referrer in invoice.
<b>To reproduce this issue:</b>
1) Install partner_commission without demo
2) Create a commission plan from crm with a rule containing category and rate
3) Create a product with the same category used in the above commission rule
4) Create a contact with commission plan and partner level in partner assignment
5) Create a confirmed customer invoice with line as above product and referrer as
above contact and register a payment.
<b>Error:- </b>
```
AttributeError: 'bool' object has no attribute 'partner_id'
```
The above traceback is occurring because we are trying to get the partner_id value from `_get_sales_representative` method.
https://github.com/odoo/enterprise/blob/313593cf176271060878dda5ebc677fa44b519db/partner_commission/models/account_move.py#L124-L125
But the above method tries to get the user_id from the sale order. Here in this case, we don't have any SO, so we the above method will return False.
https://github.com/odoo/enterprise/blob/313593cf176271060878dda5ebc677fa44b519db/partner_commission/models/account_move.py#L26-L27
This leads to the above traceback when parter_id is retrieved from the method.
<b>Solution:-</b>
Take the value of partner_id from purchase. Since the partner_id value is getting from move.referrer_id in purchase.
https://github.com/odoo/enterprise/blob/313593cf176271060878dda5ebc677fa44b519db/partner_commission/models/account_move.py#L46-L50
opw-4676967
Forward-Port-Of: odoo/enterprise#83606
Forward-Port-Of: odoo/enterprise#834822 changes
Resolved issues and error corrections
This update improves an automated check for settling rental sales orders in the point of sale flow. It helps ensure the system correctly handles orders involving tracked items, reducing the risk of test failures around rental order settlement.
Original PR description
In this commit: === - Updated the settleNthOrder function to accept a hasLot parameter to properly close the popup when settling a Sales Order. related-https://github.com/odoo/odoo/pull/197307 task-4558015
Fixed an issue where confirming an upsell could incorrectly change an already fully invoiced subscription to “Nothing to Invoice.” The subscription now keeps its correct fully invoiced status, reducing confusion for sales and billing teams while the upsell order handles any new items.
Original PR description
### Steps to Reproduce: 1) Create a fully invoiced subscription. 2) Add an upsell quote to the subscription. 3) Verify that the invoice status of the original subscription is "Fully Invoiced". 4) Confirm upsell order. 5) Verify that the invoice status of the original subscription has been updated to "Nothing to Invoice". ### Current Behavior: After confirming the upsell, the subscription status changes from Fully Invoiced to Nothing to Invoice. ### Expected Behavior: After confirming the upsell, the subscription status remains "Fully Invoiced." This is because an invoice was already created before the upsell, and the product_uom_qty and qty_invoiced are equal. Since the upsell order will handle the products added during the upsell, the invoice status of the original subscription should not be updated. opw-4508297