public function isApplyInterest($installments)
    {
        $return = true;

        $interestRate = $this->getInterestRate();
        $paymentAmount = $this->getPaymentAmount();

        if (($installments > 1) && ($interestRate > 1)) {
            # If we're not dealing with a one time payment and the interest rate is defined, interest will always be
            # applied, except when the payment total is higher than the minimum order value for no interest setting
            $minimumOrderValueNoInterest = $this->getMinimumAmountNoInterest($installments);
            if ( ($paymentAmount > $minimumOrderValueNoInterest) && ($minimumOrderValueNoInterest !== null) ) {
                $return = false;
            }
        }

        return $return;
    }
public function isApplyInterest($installments)
    {
        $return = true;

        $interestRate = $this->getInterestRate();
        $paymentAmount = $this->getPaymentAmount();

        if (($installments > 1) && ($interestRate > 1)) {
            # If we're not dealing with a one time payment and the interest rate is defined, interest will always be
            # applied, except when the payment total is higher than the minimum order value for no interest setting
            $minimumOrderValueNoInterest = $this->getMinimumAmountNoInterest($installments);
            if ( ($paymentAmount > $minimumOrderValueNoInterest) && ($minimumOrderValueNoInterest !== null) ) {
                $return = false;
            }
        }

        return $return;
    }
public function isApplyInterest ( $ installments ) { $ return = true ; $ interestRate = $ this -> getInterestRate ( ) ; $ paymentAmount = $ this -> getPaymentAmount ( ) ; if ( ( $ installments > 1 ) && ( $ interestRate > 1 ) ) { # If we're not dealing with a one time payment and the interest rate is defined, interest will always be # applied, except when the payment total is higher than the minimum order value for no interest setting $ minimumOrderValueNoInterest = $ this -> getMinimumAmountNoInterest ( $ installments ) ; if ( ( $ paymentAmount > $ minimumOrderValueNoInterest ) && ( $ minimumOrderValueNoInterest !== null ) ) { $ return = false ; } } return $ return ; }
Decides whether interest should be applied to the current payment
@param int $installments
@return bool $return
Decides whether interest should be applied to the current payment