fix: ticket #216260 buy_recalcPrices
gitea/salix/pipeline/pr-master This commit looks good Details

This commit is contained in:
Guillermo Bonet 2024-09-04 12:45:33 +02:00
parent d52dc788c8
commit afcb590a9e
1 changed files with 2 additions and 2 deletions

View File

@ -49,8 +49,8 @@ BEGIN
b.price3 = @t3:= IF(r.rate3 = 0, b.buyingValue,ROUND((b.buyingValue + @CF + @EF + @PF) / ((100 - r.rate3 - it.promo ) /100) ,2)), -- He añadido que el coste sea igual a tarifa3 si t3 = 0
b.price2 = @t2:= round(@t3 * (1 + ((r.rate2 - r.rate3)/100)),2),
b.price2 = @t2:= IF(@t2 <= @t3,@t3 , @t2)
WHERE t.landed = vLanded
AND t.warehouseInFk = vWarehouseFk;
WHERE tr.landed = vLanded
AND tr.warehouseInFk = vWarehouseFk;
DROP TEMPORARY TABLE tmp.rate;
END LOOP;