iptdevs-design-system 3.1.147 → 3.1.149
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm2020/lib/cod/steps/cod-form-step-four/cod-form-step-four.component.mjs +18 -4
- package/fesm2015/iptdevs-design-system.mjs +17 -3
- package/fesm2015/iptdevs-design-system.mjs.map +1 -1
- package/fesm2020/iptdevs-design-system.mjs +17 -3
- package/fesm2020/iptdevs-design-system.mjs.map +1 -1
- package/package.json +1 -1
|
@@ -3971,6 +3971,8 @@ class CodFormStepFourComponent extends CodFormSteps {
|
|
|
3971
3971
|
quota_times: ['', [Validators.required]],
|
|
3972
3972
|
total_price: [{ value: '', disabled: true }, [Validators.required]],
|
|
3973
3973
|
paid_level: ['', [Validators.required]],
|
|
3974
|
+
quota_price: ['', [Validators.required]],
|
|
3975
|
+
fee_number: ['', [Validators.required]],
|
|
3974
3976
|
});
|
|
3975
3977
|
this.listenPaymentMethodField();
|
|
3976
3978
|
}
|
|
@@ -4040,13 +4042,20 @@ class CodFormStepFourComponent extends CodFormSteps {
|
|
|
4040
4042
|
}
|
|
4041
4043
|
// Calcular cuotas
|
|
4042
4044
|
this.dataFinancing = [];
|
|
4043
|
-
const quotaValues = this.codPrices.filter(codPrice => codPrice.code === Number(this.codFormStepFour.controls['quota_times'].value))[0].quota_price;
|
|
4045
|
+
// const quotaValues = this.codPrices.filter(codPrice => codPrice.code === Number(this.codFormStepFour.controls['quota_times'].value))[0].quota_price;
|
|
4046
|
+
// let params: CalculateQuotesParams = {
|
|
4047
|
+
// date: new Date(this.codFormStepFour.controls['payment_date'].value),
|
|
4048
|
+
// quotaValues,
|
|
4049
|
+
// quotaTimes: this.codPrices.filter(codPrice => codPrice.code === Number(this.codFormStepFour.controls['quota_times'].value))[0].fee_number,
|
|
4050
|
+
// totalPrice: this.codFormStepFour.controls['total_price'].value,
|
|
4051
|
+
// }
|
|
4044
4052
|
let params = {
|
|
4045
4053
|
date: new Date(this.codFormStepFour.controls['payment_date'].value),
|
|
4046
|
-
quotaValues,
|
|
4047
|
-
quotaTimes:
|
|
4054
|
+
quotaValues: Number(this.codFormStepFour.controls['quota_price'].value),
|
|
4055
|
+
quotaTimes: Number(this.codFormStepFour.controls['fee_number'].value),
|
|
4048
4056
|
totalPrice: this.codFormStepFour.controls['total_price'].value,
|
|
4049
4057
|
};
|
|
4058
|
+
console.log(params);
|
|
4050
4059
|
this.dataFinancing = this.calculateQuotesService.calculateQuotes(params);
|
|
4051
4060
|
this.isFinancing = true;
|
|
4052
4061
|
this.financingData.emit(this.dataFinancing);
|
|
@@ -4122,11 +4131,14 @@ class CodFormStepFourComponent extends CodFormSteps {
|
|
|
4122
4131
|
this.resetLocalStorage(this.controls);
|
|
4123
4132
|
}
|
|
4124
4133
|
selectLevels(dataPayment) {
|
|
4134
|
+
console.log(dataPayment);
|
|
4125
4135
|
if (this.codFormStepFour.get('payment_method')?.value == 1) {
|
|
4126
4136
|
this.codFormStepFour.controls['quota_times'].setValue(dataPayment.code);
|
|
4127
4137
|
this.codFormStepFour.controls['total_price'].setValue(dataPayment.enrollment);
|
|
4128
4138
|
this.codFormStepFour.controls['program_price'].setValue(dataPayment.financed_price);
|
|
4129
4139
|
this.codFormStepFour.controls['paid_level'].setValue(dataPayment.paid_level - 1);
|
|
4140
|
+
this.codFormStepFour.controls['fee_number'].setValue(dataPayment.fee_number);
|
|
4141
|
+
this.codFormStepFour.controls['quota_price'].setValue(dataPayment.quota_price);
|
|
4130
4142
|
this.updateValueAndValidity();
|
|
4131
4143
|
}
|
|
4132
4144
|
else if (this.codFormStepFour.get('payment_method')?.value == 2) {
|
|
@@ -4134,6 +4146,8 @@ class CodFormStepFourComponent extends CodFormSteps {
|
|
|
4134
4146
|
this.codFormStepFour.controls['total_price'].setValue(dataPayment.enrollment);
|
|
4135
4147
|
this.codFormStepFour.controls['program_price'].setValue(dataPayment.normal_price);
|
|
4136
4148
|
this.codFormStepFour.controls['paid_level'].setValue(dataPayment.paid_level - 1);
|
|
4149
|
+
this.codFormStepFour.controls['fee_number'].setValue(dataPayment.fee_number);
|
|
4150
|
+
this.codFormStepFour.controls['quota_price'].setValue(dataPayment.quota_price);
|
|
4137
4151
|
this.updateValueAndValidity();
|
|
4138
4152
|
}
|
|
4139
4153
|
}
|