Openbravo Issue Tracking System - POS2
View Issue Details
0057277POS2POSpublic2024-09-05 17:072024-11-26 11:39
hbrasme 
radhakrishnan 
normalmajorhave not tried
closedfixed 
5
24Q3 
24Q4.124Q4 
No
0057277: Contribution Module - No contribution recalculation after a line split or deletion
When a product with contribution is splitted, the contribution line is not recalculate
Use a contribution (Product subtype) defined like as follow :

Checkbox Linkable To Product selected
Checkbox Forced in returns selected
Price Calculation > By Product multiplicator
Quantity Rule > As per product
Allocation Type > mandatory

---------
This contribution is assigned to a product

----

Select product with quantity of 3

When the line is splitted the contribution line is not recalculate


----

When 2 of the previous lines are deleted, the contribution is not recalculated for the only line present.

The result shlould be a contribution (Gestion APE) with an 6.02 € like amount







1. Include property 'preventSplit' at line level for the main product line when adding a contribution to the ticket
2. Modify the conditional to check for contributions similar to how ticket.hasServices is used in https://gitlab.com/openbravo/product/pmods/org.openbravo.pos2/-/merge_requests/3065/diffs?file=02be15b3fb317b5ce80c75e279ae19fd221914ca#02be15b3fb317b5ce80c75e279ae19fd221914ca_41_49 [^]

I think solution 1 is the better option.
No tags attached.
related to backport 005727824Q3.3 closed radhakrishnan Contribution Module - No contribution recalculation after a line split or deletion 
blocks defect 0056386 closed radhakrishnan Contribution Module - No contribution recalculation after a line split or deletion 
Issue History
2024-11-26 10:44jonaeTypedefect => backport
2024-11-26 10:44jonaeTarget Version => 24Q4.1
2024-11-26 11:05hgbotNote Added: 0172593
2024-11-26 11:38hgbotNote Added: 0172596
2024-11-26 11:38hgbotResolutionopen => fixed
2024-11-26 11:38hgbotStatusscheduled => closed
2024-11-26 11:38hgbotFixed in Version => 24Q4
2024-11-26 11:38hgbotNote Added: 0172597
2024-11-26 11:39frank_gonzalezRelationship addedrelated to 0057278

Notes
(0172593)
hgbot   
2024-11-26 11:05   
Merge Request created: https://gitlab.com/openbravo/product/pmods/org.openbravo.pos2/-/merge_requests/3156 [^]
(0172596)
hgbot   
2024-11-26 11:38   
Merge request merged: https://gitlab.com/openbravo/product/pmods/org.openbravo.pos2/-/merge_requests/3156 [^]
(0172597)
hgbot   
2024-11-26 11:38   
Directly closing issue as related merge request is already approved.

Repository: https://gitlab.com/openbravo/product/pmods/org.openbravo.pos2 [^]
Changeset: f95fc5cb5e5fa19f9f4c31b1c26db41dee128a74
Author: Radhakrishnan Seeman <r.seeman@external.orisha.com>
Date: 26-11-2024 10:38:10
URL: https://gitlab.com/openbravo/product/pmods/org.openbravo.pos2/-/commit/f95fc5cb5e5fa19f9f4c31b1c26db41dee128a74 [^]

Fixed ISSUE-57277: Blocked split action of a line

---
M web-jspack/org.openbravo.pos2/src/model/ticket/__test__/ContributionHooks.test.js
M web-jspack/org.openbravo.pos2/src/model/ticket/actions/ContributionHooks.js
---