Package org.fenixedu.academic.domain.accounting

Examples of org.fenixedu.academic.domain.accounting.Installment


    public ActionForward prepareEditInstallment(ActionMapping mapping, ActionForm form, HttpServletRequest request,
            HttpServletResponse response) {

        PaymentPlan paymentPlan = getDomainObject(request, "paymentPlanId");
        Installment installment = getDomainObject(request, "installmentId");

        request.setAttribute("paymentPlan", paymentPlan);
        request.setAttribute("installment", installment);
        request.setAttribute("installmentBean", new InstallmentBean(installment));
View Full Code Here


    }

    public ActionForward editInstallment(ActionMapping mapping, ActionForm form, HttpServletRequest request,
            HttpServletResponse response) {
        try {
            Installment installment = getDomainObject(request, "installmentId");
            InstallmentBean bean = getRenderedObject("installmentBean");

            InstallmentService.edit(installment, bean);
        } catch (final DomainException e) {
            addErrorMessage(request, "error", e.getKey(), new String[] {});
View Full Code Here

    }

    public ActionForward editInstallmentInvalid(final ActionMapping mapping, final ActionForm form,
            final HttpServletRequest request, final HttpServletResponse response) {
        PaymentPlan paymentPlan = getDomainObject(request, "paymentPlanId");
        Installment installment = getDomainObject(request, "installmentId");
        InstallmentBean bean = getRenderedObject("installmentBean");

        request.setAttribute("paymentPlan", paymentPlan);
        request.setAttribute("installment", installment);
        request.setAttribute("installmentBean", bean);
View Full Code Here

        }

        GratuityEventWithPaymentPlan gratuityEventWithPaymentPlan =
                getStudentCurricularPlan().getGratuityEvent(getForExecutionYear(), GratuityEventWithPaymentPlan.class);

        Installment firstInstallment = gratuityEventWithPaymentPlan.getInstallments().iterator().next();

        /*
         * iterate the non adjusting accounting transactions until its paid
         */
        Money paidForFirstInstallment = Money.ZERO;
        for (AccountingTransaction accountingTransaction : gratuityEventWithPaymentPlan.getNonAdjustingTransactions()) {
            paidForFirstInstallment = paidForFirstInstallment.add(accountingTransaction.getAmountWithAdjustment());

            if (paidForFirstInstallment.greaterOrEqualThan(firstInstallment.getAmount())) {
                return accountingTransaction.getWhenRegistered().toLocalDate();
            }
        }

        return firstInstallment.getEndDate().toLocalDate();
    }
View Full Code Here

    private Person getPerson() {
        return AccessControl.getPerson();
    }

    private void createInstallment(final GratuityEvent event, final PaymentPlan paymentPlan, final Money amount) {
        new Installment(paymentPlan, amount, event.getStartDate().toYearMonthDay(), event.getLastPaymentDate().toYearMonthDay());
    }
View Full Code Here

                    new InstallmentWithMonthlyPenalty(paymentPlan, each.getAmount(), each.getStartDate(), each.getEndDate(),
                            each.getMontlyPenaltyPercentage(), each.getWhenToStartApplyPenalty(),
                            each.getMaxMonthsToApplyPenalty());

                } else {
                    new Installment(paymentPlan, each.getAmount(), each.getStartDate(), each.getEndDate());
                }
            }

        }
    }
View Full Code Here

TOP

Related Classes of org.fenixedu.academic.domain.accounting.Installment

Copyright © 2018 www.massapicom. 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.