Package org.fenixedu.academic.util

Examples of org.fenixedu.academic.util.Money.subtract()


            Money installmentAmount =
                    installment.calculateAmount(this.event, this.currentTransactionDate, this.discountPercentage,
                            isToApplyPenalty(this.event, installment));

            if (hasDiscountValue()) {
                installmentAmount = installmentAmount.subtract(this.discountValue);
                this.discountedValue = this.discountValue;
            }

            if (hasMoneyFor(installmentAmount)) {
                this.amount = this.amount.subtract(installmentAmount);
View Full Code Here


                result = result.add(installment.getAmount());
            }
        }

        if (result.isPositive()) {
            result = result.subtract(getTotalDiscount());
        }

        return result.isPositive() ? result.add(getPayedAmountLessInstallments()) : getPayedAmountLessInstallments();
    }
View Full Code Here

        Money result = super.calculateAmountToPay(whenRegistered);
        if (result.isZero()) {
            return result;
        }

        result = result.subtract(getPerson().hasInsuranceEventFor(getExecutionYear()) ? getInsuranceAmount() : Money.ZERO);

        return result.isPositive() ? result : Money.ZERO;
    }

    @Override
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.