add mandatory Total Banking facilities section
This commit is contained in:
parent
13172585dd
commit
daa6b7d89c
BIN
ng6-seed/Sparqsineedge(WEB 20-04-2021)Test.zip
Normal file
BIN
ng6-seed/Sparqsineedge(WEB 20-04-2021)Test.zip
Normal file
Binary file not shown.
@ -834,21 +834,25 @@
|
||||
<mat-form-field style="width:92%">
|
||||
<input matInput autocomplete="off" placeholder="In case of Credit Sales, what is the average no of days taken to receive the money?"
|
||||
formControlName="receive_the_money_in_days" OnlyNumber type="text">
|
||||
</mat-form-field>
|
||||
<mat-error *ngIf="financialForm.controls['receive_the_money_in_days'].hasError('required')">In case of Credit Sales, what is the average no of days taken to receive the money Required</mat-error>
|
||||
</mat-form-field>
|
||||
<mat-form-field style="width:92%">
|
||||
<input matInput autocomplete="off" placeholder="In case of Credit Purchase, what is the average no of days taken to pay the money?"
|
||||
formControlName="pay_the_money_in_days" OnlyNumber type="text">
|
||||
</mat-form-field>
|
||||
<mat-error *ngIf="financialForm.controls['pay_the_money_in_days'].hasError('required')">In case of Credit Purchase, what is the average no of days taken to pay the money Required</mat-error>
|
||||
</mat-form-field>
|
||||
<mat-form-field style="width:92%" *ngIf="!ServiceDataAvailability">
|
||||
<input matInput autocomplete="off" placeholder="What is the average no of days for which stock lies unsold during the year?"
|
||||
formControlName="unsold_stock_lies_in_days" OnlyNumber type="text">
|
||||
</mat-form-field>
|
||||
<mat-error *ngIf="financialForm.controls['unsold_stock_lies_in_days'].hasError('required')">What is the average no of days for which stock lies unsold during the year Required</mat-error>
|
||||
</mat-form-field>
|
||||
<mat-form-field style="width:92%">
|
||||
<mat-select placeholder="Is there {{lender_short_name == 'CFPL' ? 'Total Banking Facilities' :'Working Capital Facilities'}}?" formControlName="is_there_working_capital_available">
|
||||
<!-- (selectionChange)="selectedWorkingCptl($event.value)" -->
|
||||
<mat-option value="yes">Yes</mat-option>
|
||||
<mat-option value="no">No</mat-option>
|
||||
</mat-select>
|
||||
<mat-error *ngIf="financialForm.controls['is_there_working_capital_available'].hasError('required')">Is there Facilities Required</mat-error>
|
||||
</mat-form-field>
|
||||
<!-- <mat-form-field style="width:45%;" *ngIf="financialForm.controls.is_there_working_capital_available.value == 'yes'">
|
||||
<mat-select multiple formControlName="working_capital_facilities_availed"
|
||||
|
||||
@ -258,52 +258,52 @@ export class FinancialInfoComponent implements OnInit {
|
||||
workingCptlControl.push(this.workingCptl(val));
|
||||
|
||||
if (val.exist_status == 1 && val.id == 2) {
|
||||
this.financialForm.addControl('bank_guarantee', new FormControl(''));
|
||||
this.financialForm.addControl('bank_guarantee', new FormControl('', Validators.required));
|
||||
}
|
||||
if (val.exist_status == 1 && val.id == 3) {
|
||||
this.financialForm.addControl('cash_credit_limit', new FormControl(''));
|
||||
this.financialForm.addControl('cash_credit_limit', new FormControl('', Validators.required));
|
||||
console.log("retrivedata",retriveData)
|
||||
!retriveData.hasOwnProperty('cash_credit_limit')? retriveData.cash_credit_limit='' : retriveData.cash_credit_limit
|
||||
}
|
||||
if (val.exist_status == 1 && val.id == 4) {
|
||||
this.financialForm.addControl('factoring', new FormControl(''));
|
||||
this.financialForm.addControl('factoring', new FormControl('', Validators.required));
|
||||
}
|
||||
if (val.exist_status == 1 && val.id == 5) {
|
||||
this.financialForm.addControl('forfaiting', new FormControl(''));
|
||||
this.financialForm.addControl('forfaiting', new FormControl('', Validators.required));
|
||||
}
|
||||
if (val.exist_status == 1 && val.id == 6) {
|
||||
this.financialForm.addControl('letter_of_credit', new FormControl(''));
|
||||
this.financialForm.addControl('letter_of_credit', new FormControl('', Validators.required));
|
||||
|
||||
}
|
||||
if (val.exist_status == 1 && val.id == 7) {
|
||||
this.financialForm.addControl('od_limit', new FormControl(''));
|
||||
this.financialForm.addControl('od_limit', new FormControl('', Validators.required));
|
||||
}
|
||||
if (val.exist_status == 1 && val.id == 1) {
|
||||
this.financialForm.addControl('other_reason_for_working_capital_facilities_availed', new FormControl(''));
|
||||
this.financialForm.addControl('reason_for_working_capital_facilities_availed', new FormControl(''));
|
||||
this.financialForm.addControl('other_reason_for_working_capital_facilities_availed', new FormControl('', Validators.required));
|
||||
this.financialForm.addControl('reason_for_working_capital_facilities_availed', new FormControl('', Validators.required));
|
||||
}
|
||||
if (val.exist_status == 1 && val.id == 8) {
|
||||
this.financialForm.addControl('lender_name', new FormControl(''));
|
||||
this.financialForm.addControl('lender_name', new FormControl('', Validators.required));
|
||||
|
||||
}
|
||||
if (val.exist_status == 1 && val.id == 9) {
|
||||
this.financialForm.addControl('loan_amount', new FormControl(''));
|
||||
this.financialForm.addControl('loan_amount', new FormControl('', Validators.required));
|
||||
|
||||
}
|
||||
if (val.exist_status == 1 && val.id == 10) {
|
||||
this.financialForm.addControl('loan_type', new FormControl(''));
|
||||
this.financialForm.addControl('loan_type', new FormControl('', Validators.required));
|
||||
|
||||
}
|
||||
if (val.exist_status == 1 && val.id == 11) {
|
||||
this.financialForm.addControl('loan_tenor', new FormControl(''));
|
||||
this.financialForm.addControl('loan_tenor', new FormControl('', Validators.required));
|
||||
|
||||
}
|
||||
if (val.exist_status == 1 && val.id == 12) {
|
||||
this.financialForm.addControl('loan_start_date', new FormControl(''));
|
||||
this.financialForm.addControl('loan_start_date', new FormControl('', Validators.required));
|
||||
|
||||
}
|
||||
if (val.exist_status == 1 && val.id == 13) {
|
||||
this.financialForm.addControl('monthly_emi', new FormControl(''));
|
||||
this.financialForm.addControl('monthly_emi', new FormControl('', Validators.required));
|
||||
|
||||
}
|
||||
|
||||
@ -462,10 +462,10 @@ export class FinancialInfoComponent implements OnInit {
|
||||
// is_there_working_capital_available:[value.is_there_working_capital_available],
|
||||
// estimate_working_capital_facilities_availed:[value.estimate_working_capital_facilities_availed],
|
||||
// reason_for_working_capital_facilities_availed:[value.reason_for_working_capital_facilities_availed]
|
||||
receive_the_money_in_days:[''],
|
||||
pay_the_money_in_days:[''],
|
||||
unsold_stock_lies_in_days:[''],
|
||||
is_there_working_capital_available:[''],
|
||||
receive_the_money_in_days:['', Validators.compose([Validators.required])],
|
||||
pay_the_money_in_days:['', Validators.compose([Validators.required])],
|
||||
unsold_stock_lies_in_days:['', Validators.compose([Validators.required])],
|
||||
is_there_working_capital_available:['', Validators.compose([Validators.required])],
|
||||
working_capital_facilities_availed:[''],
|
||||
// reason_for_working_capital_facilities_availed:[''],
|
||||
// same_as_financial_statements:[''],
|
||||
@ -510,81 +510,81 @@ export class FinancialInfoComponent implements OnInit {
|
||||
this.financialForm.removeControl('bank_guarantee');
|
||||
}
|
||||
else if (event.value.exist_status == false && event.value.id == 2) {
|
||||
this.financialForm.addControl('bank_guarantee', new FormControl(''));
|
||||
this.financialForm.addControl('bank_guarantee', new FormControl('', Validators.required));
|
||||
}
|
||||
if (event.value.exist_status == true && event.value.id == 3) {
|
||||
this.financialForm.removeControl('cash_credit_limit');
|
||||
}
|
||||
else if (event.value.exist_status == false && event.value.id == 3) {
|
||||
this.financialForm.addControl('cash_credit_limit', new FormControl(''));
|
||||
this.financialForm.addControl('cash_credit_limit', new FormControl('', Validators.required));
|
||||
}
|
||||
if (event.value.exist_status == true && event.value.id == 4) {
|
||||
this.financialForm.removeControl('factoring');
|
||||
}
|
||||
else if (event.value.exist_status == false && event.value.id == 4) {
|
||||
this.financialForm.addControl('factoring', new FormControl(''));
|
||||
this.financialForm.addControl('factoring', new FormControl('', Validators.required));
|
||||
}
|
||||
if (event.value.exist_status == true && event.value.id == 5) {
|
||||
this.financialForm.removeControl('forfaiting');
|
||||
}
|
||||
else if (event.value.exist_status == false && event.value.id == 5) {
|
||||
this.financialForm.addControl('forfaiting', new FormControl(''));
|
||||
this.financialForm.addControl('forfaiting', new FormControl('', Validators.required));
|
||||
}
|
||||
if (event.value.exist_status == true && event.value.id == 6) {
|
||||
this.financialForm.removeControl('letter_of_credit');
|
||||
}
|
||||
else if (event.value.exist_status == false && event.value.id == 6) {
|
||||
this.financialForm.addControl('letter_of_credit', new FormControl(''));
|
||||
this.financialForm.addControl('letter_of_credit', new FormControl('', Validators.required));
|
||||
}
|
||||
if (event.value.exist_status == true && event.value.id == 7) {
|
||||
this.financialForm.removeControl('od_limit');
|
||||
}
|
||||
else if (event.value.exist_status == false && event.value.id == 7) {
|
||||
this.financialForm.addControl('od_limit', new FormControl(''));
|
||||
this.financialForm.addControl('od_limit', new FormControl('', Validators.required));
|
||||
}
|
||||
if (event.value.exist_status == true && event.value.id == 1) {
|
||||
this.financialForm.removeControl('other_reason_for_working_capital_facilities_availed');
|
||||
this.financialForm.removeControl('reason_for_working_capital_facilities_availed');
|
||||
}
|
||||
else if (event.value.exist_status == false && event.value.id == 1) {
|
||||
this.financialForm.addControl('other_reason_for_working_capital_facilities_availed', new FormControl(''));
|
||||
this.financialForm.addControl('reason_for_working_capital_facilities_availed', new FormControl(''));
|
||||
this.financialForm.addControl('other_reason_for_working_capital_facilities_availed', new FormControl('', Validators.required));
|
||||
this.financialForm.addControl('reason_for_working_capital_facilities_availed', new FormControl('', Validators.required));
|
||||
}
|
||||
if (event.value.exist_status == true && event.value.id == 8) {
|
||||
this.financialForm.removeControl('lender_name');
|
||||
}
|
||||
else if (event.value.exist_status == false && event.value.id == 8) {
|
||||
this.financialForm.addControl('lender_name', new FormControl(''));
|
||||
this.financialForm.addControl('lender_name', new FormControl('', Validators.required));
|
||||
}
|
||||
if (event.value.exist_status == true && event.value.id == 9) {
|
||||
this.financialForm.removeControl('loan_amount');
|
||||
}
|
||||
else if (event.value.exist_status == false && event.value.id == 9) {
|
||||
this.financialForm.addControl('loan_amount', new FormControl(''));
|
||||
this.financialForm.addControl('loan_amount', new FormControl('', Validators.required));
|
||||
}
|
||||
if (event.value.exist_status == true && event.value.id == 10) {
|
||||
this.financialForm.removeControl('loan_type');
|
||||
}
|
||||
else if (event.value.exist_status == false && event.value.id == 10) {
|
||||
this.financialForm.addControl('loan_type', new FormControl(''));
|
||||
this.financialForm.addControl('loan_type', new FormControl('', Validators.required));
|
||||
}
|
||||
if (event.value.exist_status == true && event.value.id == 11) {
|
||||
this.financialForm.removeControl('loan_tenor');
|
||||
}
|
||||
else if (event.value.exist_status == false && event.value.id == 11) {
|
||||
this.financialForm.addControl('loan_tenor', new FormControl(''));
|
||||
this.financialForm.addControl('loan_tenor', new FormControl('', Validators.required));
|
||||
}
|
||||
if (event.value.exist_status == true && event.value.id == 12) {
|
||||
this.financialForm.removeControl('loan_start_date');
|
||||
}
|
||||
else if (event.value.exist_status == false && event.value.id == 12) {
|
||||
this.financialForm.addControl('loan_start_date', new FormControl(''));
|
||||
this.financialForm.addControl('loan_start_date', new FormControl('', Validators.required));
|
||||
}
|
||||
if (event.value.exist_status == true && event.value.id == 13) {
|
||||
this.financialForm.removeControl('monthly_emi');
|
||||
}
|
||||
else if (event.value.exist_status == false && event.value.id == 13) {
|
||||
this.financialForm.addControl('monthly_emi', new FormControl(''));
|
||||
this.financialForm.addControl('monthly_emi', new FormControl('', Validators.required));
|
||||
}
|
||||
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user