diff --git a/app/global-translations/locale-en.json b/app/global-translations/locale-en.json index b1ff6b019b..2b21ce45ed 100644 --- a/app/global-translations/locale-en.json +++ b/app/global-translations/locale-en.json @@ -5357,5 +5357,49 @@ "label.heading.list.of.centers": "List of Centers", "label.view.principalpaymentdetail": "Principal Payment", "label.view.interestspayment": "Interest Payment", + "loanTermFrequency.periodFrequencyType.days": "Days", + "loanTermFrequency.periodFrequencyType.weeks": "Weeks", + "loanTermFrequency.periodFrequencyType.months": "Months", + "loanTermFrequency.periodFrequencyType.years": "Years", + "label.heading.on": "on", + "repaymentFrequency.nthDayType.one": "First", + "repaymentFrequency.nthDayType.two": "Second", + "repaymentFrequency.nthDayType.three": "Third", + "repaymentFrequency.nthDayType.four": "Fourth", + "repaymentFrequency.nthDayType.last": "Last", + "repaymentFrequency.weekDayType.sunday": "SUNDAY", + "repaymentFrequency.weekDayType.monday": "MONDAY", + "repaymentFrequency.weekDayType.tuesday": "TUESDAY", + "repaymentFrequency.weekDayType.wednesday": "WEDNESDAY", + "repaymentFrequency.weekDayType.thursday": "THURSDAY", + "repaymentFrequency.weekDayType.friday": "FRIDAY", + "repaymentFrequency.weekDayType.saturday": "SATURDAY", + "interestRateFrequency.periodFrequencyType.days": "Per Day", + "interestRateFrequency.periodFrequencyType.weeks": "Per Week", + "interestRateFrequency.periodFrequencyType.months": "Per month", + "interestRateFrequency.periodFrequencyType.years": "Per year", + "interestRateFrequency.periodFrequencyType.whole_term": "Whole term", + "interestRateFrequency.periodFrequencyType.invalid": "Invalid", + "interestType.flat": "Flat", + "interestType.declining.balance": "Declining Balance", + "amortizationType.equal.installments": "Equal installments", + "amortizationType.equal.principal": "Equal principal payments", + "interestCalculationPeriodType.daily": "Daily", + "interestCalculationPeriodType.same.as.repayment.period": "Same as repayment period", + "mifos-standard-strategy": "Penalties, Fees, Interest, Principal order", + "rbi-india-strategy": "Overdue/Due Fee/Int,Principal", + "principal-interest-penalties-fees-order-strategy": "Principal, Interest, Penalties, Fees Order", + "interest-principal-penalties-fees-order-strategy": "Interest, Principal, Penalties, Fees Order", + "early-repayment-strategy": "Early Repayment Strategy", + "heavensfamily-strategy": "HeavensFamily Unique", + "creocore-strategy": "Creocore Unique", + "validation.msg.loan.description.cannot.be.blank": "Description cannot be blank", + "DaysInYearType.actual": "Actual", + "DaysInYearType.days360": "360 Days", + "DaysInYearType.days364": "364 Days", + "DaysInYearType.days365": "365 Days", + "DaysInYearType.invalid": "Invalid", + "DaysInMonthType.actual": "Actual", + "DaysInMonthType.days360": "30 Days", "----End---": "--End of file--- " } diff --git a/app/global-translations/locale-es.json b/app/global-translations/locale-es.json index d2621f469f..54c6cbe7d1 100644 --- a/app/global-translations/locale-es.json +++ b/app/global-translations/locale-es.json @@ -4979,5 +4979,48 @@ "label.heading.billnumber": "Número de factura", "label.view.principalpaymentdetail": "Pago principal", "label.view.interestspayment": "Pago de intereses", + "loanTermFrequency.periodFrequencyType.days": "Días", + "loanTermFrequency.periodFrequencyType.weeks": "Semanas", + "loanTermFrequency.periodFrequencyType.months": "Meses", + "loanTermFrequency.periodFrequencyType.years": "Años", + "label.heading.on": "en", + "repaymentFrequency.nthDayType.one": "Primero", + "repaymentFrequency.nthDayType.two": "Segundo", + "repaymentFrequency.nthDayType.three": "Tercero", + "repaymentFrequency.nthDayType.four": "Cuarto", + "repaymentFrequency.nthDayType.last": "Último", + "repaymentFrequency.weekDayType.sunday": "DOMINGO", + "repaymentFrequency.weekDayType.monday": "LUNES", + "repaymentFrequency.weekDayType.tuesday": "MARTES", + "repaymentFrequency.weekDayType.wednesday": "MIÉRCOLES", + "repaymentFrequency.weekDayType.thursday": "JUEVES", + "repaymentFrequency.weekDayType.friday": "VIERNES", + "repaymentFrequency.weekDayType.saturday": "SÁBADO", + "interestRateFrequency.periodFrequencyType.days": "Por día", + "interestRateFrequency.periodFrequencyType.weeks": "Por semana", + "interestRateFrequency.periodFrequencyType.months": "Por mes", + "interestRateFrequency.periodFrequencyType.years": "Por año", + "interestRateFrequency.periodFrequencyType.whole_term": "Término completo", + "interestRateFrequency.periodFrequencyType.invalid": "Inválido", + "label.input.isequalamortization": "¿Es igual la amortización?", + "interestType.flat": "Plano", + "interestType.declining.balance": "Saldo decreciente", + "amortizationType.equal.installments": "Cuotas iguales", + "amortizationType.equal.principal": "Pagos iguales de principal", + "interestCalculationPeriodType.daily": "A diario", + "interestCalculationPeriodType.same.as.repayment.period": "Lo mismo que el período de amortización", + "mifos-standard-strategy": "Sanciones, Tarifas, Intereses, Orden principal", + "rbi-india-strategy": "Vencido/tarifa vencida/int,principal", + "principal-interest-penalties-fees-order-strategy": "Orden de capital, intereses, sanciones y comisiones", + "interest-principal-penalties-fees-order-strategy": "Intereses, Principal, Sanciones, Orden de Honorarios", + "early-repayment-strategy": "Estrategia de amortización anticipada", + "heavensfamily-strategy": "Cielos familia único", + "creocore-strategy": "Creocore único", + "validation.msg.loan.description.cannot.be.blank": "La descripción no puede estar en blanco", + "DaysInYearType.actual": "Actual", + "DaysInYearType.days360": "360 días", + "DaysInYearType.days364": "364 días", + "DaysInYearType.days365": "365 dias", + "DaysInYearType.invalid": "Invalid", "----End---": "---Fin del archivo---" } diff --git a/app/scripts/controllers/loanAccount/NewLoanAccAppController.js b/app/scripts/controllers/loanAccount/NewLoanAccAppController.js index 7801dd9e46..eafea3fc0a 100755 --- a/app/scripts/controllers/loanAccount/NewLoanAccAppController.js +++ b/app/scripts/controllers/loanAccount/NewLoanAccAppController.js @@ -220,10 +220,10 @@ } } } - scope.loandetails.interestValue = scope.loanaccountinfo.interestType.value; - scope.loandetails.amortizationValue = scope.loanaccountinfo.amortizationType.value; - scope.loandetails.interestCalculationPeriodValue = scope.loanaccountinfo.interestCalculationPeriodType.value; - scope.loandetails.transactionProcessingStrategyValue = scope.formValue(scope.loanaccountinfo.transactionProcessingStrategyOptions, scope.formData.transactionProcessingStrategyId, 'id', 'name'); + scope.loandetails.interestValue = scope.loanaccountinfo.interestType.code; + scope.loandetails.amortizationValue = scope.loanaccountinfo.amortizationType.code; + scope.loandetails.interestCalculationPeriodValue = scope.loanaccountinfo.interestCalculationPeriodType.code; + scope.loandetails.transactionProcessingStrategyValue = scope.formValue(scope.loanaccountinfo.transactionProcessingStrategyOptions, scope.formData.transactionProcessingStrategyId, 'id', 'code'); scope.datatables = data.datatables; scope.handleDatatables(scope.datatables); scope.disabled = false; @@ -387,16 +387,16 @@ scope.formData.isEqualAmortization = scope.loanaccountinfo.isEqualAmortization; scope.loandetails.amortizationValue = scope.loanaccountinfo.amortizationType.value; scope.formData.interestType = scope.loanaccountinfo.interestType.id; - scope.loandetails.interestValue = scope.loanaccountinfo.interestType.value; + scope.loandetails.interestValue = scope.loanaccountinfo.interestType.code; scope.formData.interestCalculationPeriodType = scope.loanaccountinfo.interestCalculationPeriodType.id; - scope.loandetails.interestCalculationPeriodValue = scope.loanaccountinfo.interestCalculationPeriodType.value; + scope.loandetails.interestCalculationPeriodValue = scope.loanaccountinfo.interestCalculationPeriodType.code; scope.formData.allowPartialPeriodInterestCalcualtion = scope.loanaccountinfo.allowPartialPeriodInterestCalcualtion; scope.formData.inArrearsTolerance = scope.loanaccountinfo.inArrearsTolerance; scope.formData.graceOnPrincipalPayment = scope.loanaccountinfo.graceOnPrincipalPayment; scope.formData.graceOnInterestPayment = scope.loanaccountinfo.graceOnInterestPayment; scope.formData.graceOnArrearsAgeing = scope.loanaccountinfo.graceOnArrearsAgeing; scope.formData.transactionProcessingStrategyId = scope.loanaccountinfo.transactionProcessingStrategyId; - scope.loandetails.transactionProcessingStrategyValue = scope.formValue(scope.loanaccountinfo.transactionProcessingStrategyOptions, scope.formData.transactionProcessingStrategyId, 'id', 'name'); + scope.loandetails.transactionProcessingStrategyValue = scope.formValue(scope.loanaccountinfo.transactionProcessingStrategyOptions, scope.formData.transactionProcessingStrategyId, 'id', 'code'); scope.formData.graceOnInterestCharged = scope.loanaccountinfo.graceOnInterestCharged; scope.formData.fixedEmiAmount = scope.loanaccountinfo.fixedEmiAmount; scope.formData.maxOutstandingLoanBalance = scope.loanaccountinfo.maxOutstandingLoanBalance; diff --git a/app/scripts/filters/YesOrNo.js b/app/scripts/filters/YesOrNo.js index cbd722d170..f992285511 100644 --- a/app/scripts/filters/YesOrNo.js +++ b/app/scripts/filters/YesOrNo.js @@ -1,18 +1,18 @@ (function (module) { mifosX.filters = _.extend(module, { - YesOrNo: function () { + YesOrNo: function ($filter, $locale) { return function (input) { var status = 'No'; - if (input == true) { - status = 'Yes'; - } else if (input == false) { - status = 'No'; + if (input === true) { + status = $locale.id === 'es' ? 'Sí' : 'Yes'; + } else if (input === false) { + status = $locale.id === 'es' ? 'No' : 'No'; } return status; } } }); - mifosX.ng.application.filter('YesOrNo', ['dateFilter', mifosX.filters.YesOrNo]).run(function ($log) { + mifosX.ng.application.filter('YesOrNo', ['$filter', '$locale', mifosX.filters.YesOrNo]).run(function ($log) { $log.info("YesOrNo filter initialized"); }); }(mifosX.filters || {})); diff --git a/app/views/loans/editloanaccount.html b/app/views/loans/editloanaccount.html index b7a173496a..761bcb431b 100755 --- a/app/views/loans/editloanaccount.html +++ b/app/views/loans/editloanaccount.html @@ -175,7 +175,7 @@