Package org.mifosplatform.infrastructure.core.data

Examples of org.mifosplatform.infrastructure.core.data.EnumOptionData


                final String typeName = rs.getString("typeName");
                clientRelationshipType = CodeValueData.instance(clientRelationshipTypeId, typeName);
            }

            final Integer guarantorTypeId = rs.getInt("guarantorType");
            final EnumOptionData guarantorType = GuarantorEnumerations.guarantorType(guarantorTypeId);
            final Long entityId = rs.getLong("entityId");
            final String firstname = rs.getString("firstname");
            final String lastname = rs.getString("lastname");
            final LocalDate dob = JdbcSupport.getLocalDate(rs, "dateOfBirth");
            final String addressLine1 = rs.getString("addressLine1");
View Full Code Here


        return accountType(PortfolioAccountType.fromInt(type));
    }

    public static EnumOptionData accountType(final PortfolioAccountType type) {

        EnumOptionData optionData = null;

        if (type != null) {
            switch (type) {
                case INVALID:
                break;
                case LOAN:
                    optionData = new EnumOptionData(PortfolioAccountType.LOAN.getValue().longValue(), PortfolioAccountType.LOAN.getCode(),
                            "Loan Account");
                break;
                case SAVINGS:
                    optionData = new EnumOptionData(PortfolioAccountType.SAVINGS.getValue().longValue(),
                            PortfolioAccountType.SAVINGS.getCode(), "Savings Account");
                break;
            }
        }
View Full Code Here

    public static EnumOptionData recurrenceType(final Integer type) {
        return recurrenceType(AccountTransferRecurrenceType.fromInt(type));
    }

    public static EnumOptionData recurrenceType(final AccountTransferRecurrenceType type) {
        EnumOptionData optionData = null;
        if (type != null) {
            switch (type) {
                case INVALID:
                break;
                case PERIODIC:
                    optionData = new EnumOptionData(AccountTransferRecurrenceType.PERIODIC.getValue().longValue(),
                            AccountTransferRecurrenceType.PERIODIC.getCode(), "Periodic Recurrence");
                break;
                case AS_PER_DUES:
                    optionData = new EnumOptionData(AccountTransferRecurrenceType.AS_PER_DUES.getValue().longValue(),
                            AccountTransferRecurrenceType.AS_PER_DUES.getCode(), "As Per Dues Recurrence");
                break;
            }
        }
        return optionData;
View Full Code Here

    public static EnumOptionData transferType(final Integer type) {
        return transferType(AccountTransferType.fromInt(type));
    }

    public static EnumOptionData transferType(final AccountTransferType type) {
        EnumOptionData optionData = null;
        if (type != null) {
            switch (type) {
                case INVALID:
                break;
                case ACCOUNT_TRANSFER:
                    optionData = new EnumOptionData(AccountTransferType.ACCOUNT_TRANSFER.getValue().longValue(),
                            AccountTransferType.ACCOUNT_TRANSFER.getCode(), "Account Transfer");
                break;
                case LOAN_REPAYMENT:
                    optionData = new EnumOptionData(AccountTransferType.LOAN_REPAYMENT.getValue().longValue(),
                            AccountTransferType.LOAN_REPAYMENT.getCode(), "Loan Repayment");
                break;
                case CHARGE_PAYMENT:
                    optionData = new EnumOptionData(AccountTransferType.CHARGE_PAYMENT.getValue().longValue(),
                            AccountTransferType.CHARGE_PAYMENT.getCode(), "Charge Payment");
                break;
                case INTEREST_TRANSFER:
                    optionData = new EnumOptionData(AccountTransferType.INTEREST_TRANSFER.getValue().longValue(),
                            AccountTransferType.INTEREST_TRANSFER.getCode(), "Interest Transfer");
                break;
            }
        }
        return optionData;
View Full Code Here

    public static EnumOptionData standingInstructionPriority(final Integer type) {
        return standingInstructionPriority(StandingInstructionPriority.fromInt(type));
    }

    public static EnumOptionData standingInstructionPriority(final StandingInstructionPriority type) {
        EnumOptionData optionData = null;
        if (type != null) {
            switch (type) {
                case INVALID:
                break;
                case HIGH:
                    optionData = new EnumOptionData(StandingInstructionPriority.HIGH.getValue().longValue(),
                            StandingInstructionPriority.HIGH.getCode(), "High Priority");
                break;
                case LOW:
                    optionData = new EnumOptionData(StandingInstructionPriority.LOW.getValue().longValue(),
                            StandingInstructionPriority.LOW.getCode(), "Low Priority");
                break;
                case MEDIUM:
                    optionData = new EnumOptionData(StandingInstructionPriority.MEDIUM.getValue().longValue(),
                            StandingInstructionPriority.MEDIUM.getCode(), "Medium Priority");
                break;
                case URGENT:
                    optionData = new EnumOptionData(StandingInstructionPriority.URGENT.getValue().longValue(),
                            StandingInstructionPriority.URGENT.getCode(), "Urgent Priority");
                break;
            }
        }
        return optionData;
View Full Code Here

    public static EnumOptionData standingInstructionStatus(final Integer type) {
        return standingInstructionStatus(StandingInstructionStatus.fromInt(type));
    }

    public static EnumOptionData standingInstructionStatus(final StandingInstructionStatus type) {
        EnumOptionData optionData = null;
        if (type != null) {
            switch (type) {
                case INVALID:
                break;
                case ACTIVE:
                    optionData = new EnumOptionData(StandingInstructionStatus.ACTIVE.getValue().longValue(),
                            StandingInstructionStatus.ACTIVE.getCode(), "Active");
                break;
                case DELETED:
                    optionData = new EnumOptionData(StandingInstructionStatus.DELETED.getValue().longValue(),
                            StandingInstructionStatus.DELETED.getCode(), "Deleted");
                break;
                case DISABLED:
                    optionData = new EnumOptionData(StandingInstructionStatus.DISABLED.getValue().longValue(),
                            StandingInstructionStatus.DISABLED.getCode(), "Disabled");
                break;
            }
        }
        return optionData;
View Full Code Here

    public static EnumOptionData standingInstructionType(final Integer type) {
        return standingInstructionType(StandingInstructionType.fromInt(type));
    }

    public static EnumOptionData standingInstructionType(final StandingInstructionType type) {
        EnumOptionData optionData = null;
        if (type != null) {
            switch (type) {
                case INVALID:
                break;
                case DUES:
                    optionData = new EnumOptionData(StandingInstructionType.DUES.getValue().longValue(),
                            StandingInstructionType.DUES.getCode(), "Dues");
                break;
                case FIXED:
                    optionData = new EnumOptionData(StandingInstructionType.FIXED.getValue().longValue(),
                            StandingInstructionType.FIXED.getCode(), "Fixed");
                break;

            }
        }
View Full Code Here

    }

    public static LoanProductInterestRecalculationData sensibleDefaultsForNewLoanProductCreation() {
        final Long id = null;
        final Long productId = null;
        final EnumOptionData interestRecalculationCompoundingType = interestRecalculationCompoundingType(InterestRecalculationCompoundingMethod.NONE);
        final EnumOptionData rescheduleStrategyType = rescheduleStrategyType(LoanRescheduleStrategyMethod.REDUCE_EMI_AMOUNT);
        final EnumOptionData recalculationRestFrequencyType = null;
        final Integer recalculationRestFrequencyInterval = null;
        final LocalDate recalculationRestFrequencyDate = null;
        return new LoanProductInterestRecalculationData(id, productId, interestRecalculationCompoundingType, rescheduleStrategyType,
                recalculationRestFrequencyType, recalculationRestFrequencyInterval, recalculationRestFrequencyDate);
    }
View Full Code Here

        return this.toApiJsonSerializer.serialize(settings, savingProduct, SavingsApiConstants.SAVINGS_PRODUCT_RESPONSE_DATA_PARAMETERS);
    }

    private SavingsProductData handleTemplateRelatedData(final SavingsProductData savingsProduct) {

        final EnumOptionData interestCompoundingPeriodType = SavingsEnumerations
                .compoundingInterestPeriodType(SavingsCompoundingInterestPeriodType.DAILY);

        final EnumOptionData interestPostingPeriodType = SavingsEnumerations
                .interestPostingPeriodType(SavingsPostingInterestPeriodType.MONTHLY);

        final EnumOptionData interestCalculationType = SavingsEnumerations
                .interestCalculationType(SavingsInterestCalculationType.DAILY_BALANCE);

        final EnumOptionData interestCalculationDaysInYearType = SavingsEnumerations
                .interestCalculationDaysInYearType(SavingsInterestCalculationDaysInYearType.DAYS_365);

        final EnumOptionData accountingRule = AccountingEnumerations.accountingRuleType(AccountingRuleType.NONE);

        CurrencyData currency = CurrencyData.blank();
        final Collection<CurrencyData> currencyOptions = this.currencyReadPlatformService.retrieveAllowedCurrencies();
        if (currencyOptions.size() == 1) {
            currency = new ArrayList<>(currencyOptions).get(0);
View Full Code Here

    public static EnumOptionData calendarEntityType(final int id) {
        return calendarEntityType(CalendarEntityType.fromInt(id));
    }

    public static EnumOptionData calendarEntityType(final CalendarEntityType entityType) {
        final EnumOptionData optionData = new EnumOptionData(entityType.getValue().longValue(), entityType.getCode(), entityType.toString());
        return optionData;
    }
View Full Code Here

TOP

Related Classes of org.mifosplatform.infrastructure.core.data.EnumOptionData

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.