增加最计费重的计费逻辑
This commit is contained in:
+11
-1
@@ -544,6 +544,12 @@ public class TmsPriceQuoteServiceImpl implements ITmsPriceQuoteService
|
||||
productCode, productName, discWeight, bizDate);
|
||||
if (hit != null)
|
||||
{
|
||||
// Calc-only snap: do not persist raised min-band weight as charge_weight.
|
||||
if (discWeight != null && weight != null && discWeight.compareTo(weight) != 0)
|
||||
{
|
||||
hit.setWeight(weight);
|
||||
hit.setChargeWeight(weight);
|
||||
}
|
||||
stampRequestMeta(request, hit);
|
||||
return hit;
|
||||
}
|
||||
@@ -1027,7 +1033,11 @@ public class TmsPriceQuoteServiceImpl implements ITmsPriceQuoteService
|
||||
String msg = MessageUtils.message("price.quote.hitCustomerFixedPackageDetail") + " [" + verLabel + "]";
|
||||
if (snappedToMinBand)
|
||||
{
|
||||
msg = msg + "; chargeWeight raised to min band " + billWeight.toPlainString();
|
||||
// Calc-only snap: keep original weight/chargeWeight for persist so upstream re-sync
|
||||
// can replace them when the new weight is already in-band.
|
||||
r.setWeight(weight);
|
||||
r.setChargeWeight(weight);
|
||||
msg = msg + "; billed at min band " + billWeight.toPlainString() + " (persist original weight)";
|
||||
}
|
||||
r.setMatchMessage(msg);
|
||||
r.setCustomerId(bind.getCustomerId());
|
||||
|
||||
Reference in New Issue
Block a user