mathi!2002

This commit is contained in:
venbatechnologies@gmail.com 2019-02-28 10:36:11 +05:30
parent 96333ce5bb
commit 6e33ad94d2
5 changed files with 617 additions and 606 deletions

Binary file not shown.

View File

@ -136,22 +136,47 @@ export class CurrentLoanComponent implements OnInit {
const control = <FormArray>this.currentLoanForm.controls['loan_details']; const control = <FormArray>this.currentLoanForm.controls['loan_details'];
if (value.status == 200) { if (value.status == 200) {
console.log('value.records',value.records);
this.currentLoanForm.controls['existing_loan'].setValue(value.records.existing_loan); this.currentLoanForm.controls['existing_loan'].setValue(value.records.existing_loan);
this.currentLoanForm.controls['currentloan_remarks'].setValue(value.records.currentloan_remarks); this.currentLoanForm.controls['currentloan_remarks'].setValue(value.records.currentloan_remarks);
if (value.records.existing_loan == 'Yes') { if (value.records.existing_loan == 'Yes') {
var result = Object.keys(value.records.loan_details).map(function (key) { console.log('value.records.loan_details',);
return value.records.loan_details[key]; let loandetails = value.records.loan_details
var result = Object.keys(loandetails).map(function (key) {
return loandetails[key];
}); });
const control = <FormArray>this.currentLoanForm.controls['loan_details'];
if (result.length > 0) { if (result.length > 0) {
result.forEach((val,index) => { result.forEach((val,index) => {
this.amtInwords[index] = this._pd.convertNumberToWords(val.loan_amount); this.amtInwords[index] = this._pd.convertNumberToWords(val.loan_amount);
this.emiAmtInwords[index] = this._pd.convertNumberToWords(val.emi); this.emiAmtInwords[index] = this._pd.convertNumberToWords(val.emi);
this.selectedfrequency(val.frequency,index); this.selectedfrequency(val.frequency,index);
//this.selectedLoanTakenBy(val.loan_taken_by,index); //this.selectedLoanTakenBy(val.loan_taken_by,index);
let objs = {
'label': val.loan_amount,
'loan_amount': val.loan_amount,
'frequency':val.frequency,
'other_frequency':val.other_frequency,
'emi': val.emi,
'loan_type': val.loan_type,
'others_loan_type': val.others_loan_type,
'loan_taken_by':val.loan_taken_by,
'others_loan_taken':val.others_loan_taken,
'lender': val.lender,
'others_lender':val.others_lender,
'original_tenure': val.original_tenure,
'current_balance_tenure': val.current_balance_tenure,
'elapsed_tenure':val.elapsed_tenure
}
control.push(this.createLoanDetail(objs));
}); });
this.currentLoanForm.controls['loan_details'].setValue(result);
// this.currentLoanForm.controls['loan_details'].setValue(result_data);
} else { } else {
// control.push(this.createLoanDetail()); // control.push(this.createLoanDetail());
} }
@ -424,19 +449,19 @@ export class CurrentLoanComponent implements OnInit {
createLoanDetail(data) { createLoanDetail(data) {
return this.fb.group({ return this.fb.group({
label: data == null ? [''] : [data.label], label: data == null ? [''] : [data.label],
loan_amount: [''], loan_amount: null ? [''] : [data.loan_amount],
frequency:[''], frequency:null ? [''] : [data.frequency],
other_frequency:[''], other_frequency:null ? [''] : [data.other_frequency],
emi: [''], emi: null ? [''] : [data.emi],
loan_type: [''], loan_type: null ? [''] : [data.loan_type],
others_loan_type: [''], others_loan_type: null ? [''] : [data.others_loan_type],
loan_taken_by:[''], loan_taken_by:null ? [''] : [data.loan_taken_by],
others_loan_taken:[''], others_loan_taken:null ? [''] : [data.others_loan_taken],
lender: [''], lender: null ? [''] : [data.lender],
others_lender:[''], others_lender:null ? [''] : [data.others_lender],
original_tenure: [''], original_tenure: null ? [''] : [data.original_tenure],
current_balance_tenure: [''], current_balance_tenure: null ? [''] : [data.current_balance_tenure],
elapsed_tenure:[''] elapsed_tenure:null ? [''] : [data.elapsed_tenure]
}); });
} }

View File

@ -1,19 +1,17 @@
<form [formGroup]="financialForm" class="address"> <form [formGroup]="financialForm" class="address">
<h2 mat-dialog-title class="paragraph_change"> <h2 mat-dialog-title class="paragraph_change">
<div fxFlex="70" align="left" style="padding: 10px !important;"> <div fxFlex="70" align="left" style="padding: 10px !important;">
<span>{{main_applicant}} ({{lender_applicant_id}}), {{customer_segment_abbr}} - {{subproduct_abbr}} </span><br> <span>{{main_applicant}} ({{lender_applicant_id}}), {{customer_segment_abbr}} - {{subproduct_abbr}} </span><br>
{{pageTitle}} {{pageTitle}}
</div> </div>
<div fxFlex="30" align="end" style="padding: 10px !important;"> <div fxFlex="30" align="end" style="padding: 10px !important;">
<button mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="Close" matTooltipPosition="right" mat-dialog-close><mat-icon>close</mat-icon></button> <button mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="Close"
matTooltipPosition="right" mat-dialog-close>
<mat-icon>close</mat-icon>
</button>
</div> </div>
</h2> </h2>
<mat-dialog-content> <mat-dialog-content>
<mat-tab-group> <mat-tab-group>
<mat-tab label="Questions"> <mat-tab label="Questions">
<ng-template matTabContent> <ng-template matTabContent>
@ -22,383 +20,416 @@
<mat-card> <mat-card>
<mat-card-header> <mat-card-header>
<mat-card-title> <mat-card-title>
<!-- <p> Financial as per Statements</p> -->
<p>Data as Per Financial Statements</p> <p>Data as Per Financial Statements</p>
</mat-card-title> </mat-card-title>
</mat-card-header> </mat-card-header>
<div style="width:100%"> <div style="width:100%">
<mat-form-field style="width:31%"> <mat-form-field style="width:35%">
<mat-select placeholder="Financial Statements Available ?" formControlName="is_financial_statements"
<mat-select placeholder="Financial Statements Available ?" formControlName="is_financial_statements" (selectionChange)="selectedStatement($event.value)"> (selectionChange)="selectedStatement($event.value)">
<mat-option value="yes">Yes</mat-option> <mat-option value="yes">Yes</mat-option>
<mat-option value="no">No</mat-option> <mat-option value="no">No</mat-option>
</mat-select> </mat-select>
</mat-form-field> </mat-form-field>
</div> </div>
<div *ngIf="isDisplay"> <div *ngIf="isDisplay">
<mat-form-field style="width:37%"> <mat-form-field style="width:37%">
<mat-label>Enter year from which financials provided</mat-label> <mat-label>Enter year from which financials provided</mat-label>
<input matInput autocomplete="off" placeholder="YYYY eg.2018" formControlName="financial_starting_year" (keypress)="keyPress($event)" [readonly]="isReadOnly"> <input matInput autocomplete="off" placeholder="YYYY eg.2018" formControlName="financial_starting_year"
(keypress)="keyPress($event)" [readonly]="isReadOnly">
<mat-error> Invalid year format</mat-error> <mat-error> Invalid year format</mat-error>
</mat-form-field> </mat-form-field>
<!-- <mat-form-field hintLabel="Max 10 characters">
<input matInput #input maxlength="10" placeholder="Enter some input">
<mat-hint align="start" style="font-size:70%">{{input.value?.length || 0}}/10</mat-hint>
</mat-form-field> -->
<mat-form-field style="width:25%"> <mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Number of Financial Years" formControlName="financial_no_of_year" (change)="dynamicalFinYear($event)" (keypress)="keyPress($event)" [readonly]="isReadOnly"> <input matInput autocomplete="off" placeholder="Number of Financial Years"
formControlName="financial_no_of_year" (change)="dynamicalFinYear($event)"
(keypress)="keyPress($event)" [readonly]="isReadOnly">
</mat-form-field> </mat-form-field>
</div> </div>
<div *ngIf="financial_no_of_year != ''" formArrayName="date_per_financial"> <div *ngIf="financial_no_of_year != ''" formArrayName="date_per_financial">
<!-- <div formArrayName="date_per_financial"> --> <div *ngFor="let details of financialForm.controls.date_per_financial['controls']; let i=index"
<div *ngFor="let details of financialForm.controls.date_per_financial['controls']; let i=index" [formGroupName]="i"> [formGroupName]="i">
<mat-card-content class="matcard"> <mat-card-content class="matcard">
<mat-label class="highlight"> <i>Financial Year : {{details.get('financial_year').value}} </i> </mat-label> <mat-label class="highlight"> <i>Financial Year :
{{details.get('financial_year').value}} </i> </mat-label>
<hr> <hr>
<div style="width:100%"> <div style="width:100%">
<br> <br>
<mat-form-field style="width:30%"> <mat-form-field style="width:30%">
<!-- <input matInput autocomplete="off" placeholder="Annual Sale" formControlName="financial_annual_sale" (change)="calMargin(i, details)" type="number" > --> <input matInput autocomplete="off" placeholder="Annual Sale"
<input matInput autocomplete="off" placeholder="Annual Sale" formControlName="financial_annual_sale" (change)="calculationForFinanicalStatement()" (keypress)="keyPress($event)" (keyup)="inWords($event,i,1)"> formControlName="financial_annual_sale" (change)="calculationForFinanicalStatement()"
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('financial_annual_sale').value != ''">{{"&#8377;"}} {{FY_annualSalesInwords[i]}} Only</mat-hint> (keypress)="keyPress($event)" (keyup)="inWords($event,i,1)">
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('financial_annual_sale').value != ''">{{"&#8377;"}}
{{FY_annualSalesInwords[i]}} Only</mat-hint>
</mat-form-field> </mat-form-field>
<span *ngIf="i != 0"> <span *ngIf="i != 0">
<mat-form-field style="width:60%"> <mat-form-field style="width:60%">
<input matInput autocomplete="off" placeholder="Sale Variation from Previous Year in %" formControlName="financial_annualsales_variation" (keypress)="keyPress($event)" readonly> <input matInput autocomplete="off" placeholder="Sale Variation from Previous Year in %"
formControlName="financial_annualsales_variation"
(keypress)="keyPress($event)" readonly>
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('financial_annualsales_variation').value != '' "> <mat-hint align="start" style="font-size:70%" *ngIf="details.get('financial_annualsales_variation').value != '' ">
<span *ngIf="details.get('financial_annualsales_variation').value == 0"> <span *ngIf="details.get('financial_annualsales_variation').value == 0">
No difference in Sales in FY <i> {{details.get('financial_year').value}} </i> over Sales in FY <i> {{financialForm.controls.date_per_financial['controls'][i-1].get('financial_year').value}} </i> No difference in Sales in FY <i>
{{details.get('financial_year').value}} </i> over
Sales in FY <i>
{{financialForm.controls.date_per_financial['controls'][i-1].get('financial_year').value}}
</i>
</span> </span>
<span *ngIf="details.get('financial_annualsales_variation').value > 0" class="greenhighlight"> <span *ngIf="details.get('financial_annualsales_variation').value > 0"
Increase in Sales in FY <i> {{details.get('financial_year').value}} </i> over Sales in FY <i> {{financialForm.controls.date_per_financial['controls'][i-1].get('financial_year').value}} </i> <b> {{details.get('financial_annualsales_variation').value}} % </b> class="greenhighlight">
Increase in Sales in FY <i>
{{details.get('financial_year').value}} </i> over
Sales in FY <i>
{{financialForm.controls.date_per_financial['controls'][i-1].get('financial_year').value}}
</i> <b>
{{details.get('financial_annualsales_variation').value}}
% </b>
</span> </span>
<span *ngIf="details.get('financial_annualsales_variation').value < 0" class="highlight"> <span *ngIf="details.get('financial_annualsales_variation').value < 0"
Decrease in Sales in FY <i> {{details.get('financial_year').value}} </i> over Sales in FY <i>{{financialForm.controls.date_per_financial['controls'][i-1].get('financial_year').value}} </i> <b> {{(details.get('financial_annualsales_variation').value).replace('-', '')}} % </b> class="highlight">
Decrease in Sales in FY <i>
{{details.get('financial_year').value}} </i> over
Sales in FY <i>{{financialForm.controls.date_per_financial['controls'][i-1].get('financial_year').value}}
</i> <b>
{{(details.get('financial_annualsales_variation').value).replace('-',
'')}} % </b>
</span> </span>
</mat-hint> </mat-hint>
</mat-form-field> </mat-form-field>
</span> </span>
</div> </div>
<div style="width:100%"> <div style="width:100%">
<mat-form-field style="width:30%"> <mat-form-field style="width:30%">
<!-- <input matInput autocomplete="off" placeholder="Net Profit / Loss" formControlName="financial_net_profit" (change)="calMargin( i, details); calYearVariation( i, details)" type="number" > --> <!-- <input matInput autocomplete="off" placeholder="Net Profit / Loss" formControlName="financial_net_profit" (change)="calMargin( i, details); calYearVariation( i, details)" type="number" > -->
<mat-select placeholder="Is there Net Profit or Net Loss?" formControlName="finanical_profit_or_loss" (selectionChange)="selectedProfitOrLossType($event,details)"> <mat-select placeholder="Is there Net Profit or Net Loss?"
formControlName="finanical_profit_or_loss" (selectionChange)="selectedProfitOrLossType($event,details)">
<mat-option value="1">Net Profit</mat-option> <mat-option value="1">Net Profit</mat-option>
<mat-option value="2">Net Loss</mat-option> <mat-option value="2">Net Loss</mat-option>
</mat-select> </mat-select>
</mat-form-field> </mat-form-field>
<span *ngIf="details.get('finanical_profit_or_loss').value == 1 "> <span *ngIf="details.get('finanical_profit_or_loss').value == 1 ">
<mat-form-field style="width:28%"> <mat-form-field style="width:28%">
<input matInput autocomplete="off" placeholder="Net Profit Amount" formControlName="financial_net_profit" (change)="calculationForFinanicalStatement()" (keypress)="keyPress($event)" (keyup)="inWords($event,i,2)"> <input matInput autocomplete="off" placeholder="Net Profit Amount"
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('financial_net_profit').value != ''">{{"&#8377;"}} {{FY_netProfitAmtInwords[i]}} Only</mat-hint> formControlName="financial_net_profit" (change)="calculationForFinanicalStatement()"
(keypress)="keyPress($event)" (keyup)="inWords($event,i,2)">
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('financial_net_profit').value != ''">{{"&#8377;"}}
{{FY_netProfitAmtInwords[i]}} Only</mat-hint>
</mat-form-field> </mat-form-field>
<mat-form-field style="width:28%"> <mat-form-field style="width:28%">
<input matInput autocomplete="off" placeholder="Net Profit to Sales in %" formControlName="financial_margin_of_profit" (keypress)="keyPress($event)" readonly> <input matInput autocomplete="off" placeholder="Net Profit to Sales in %"
formControlName="financial_margin_of_profit" (keypress)="keyPress($event)"
readonly>
</mat-form-field> </mat-form-field>
</span> </span>
<span *ngIf="details.get('finanical_profit_or_loss').value == 2 "> <span *ngIf="details.get('finanical_profit_or_loss').value == 2 ">
<mat-form-field style="width:28%"> <mat-form-field style="width:28%">
<input matInput autocomplete="off" placeholder="Net Loss Amount" formControlName="financial_net_loss" (change)="calculationForFinanicalStatement()" (keypress)="keyPress($event)" (keyup)="inWords($event,i,3)"> <input matInput autocomplete="off" placeholder="Net Loss Amount"
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('financial_net_loss').value != ''">{{"&#8377;"}} {{FY_netLossAmtInwords[i]}} Only</mat-hint> formControlName="financial_net_loss" (change)="calculationForFinanicalStatement()"
(keypress)="keyPress($event)" (keyup)="inWords($event,i,3)">
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('financial_net_loss').value != ''">{{"&#8377;"}}
{{FY_netLossAmtInwords[i]}} Only</mat-hint>
</mat-form-field> </mat-form-field>
<mat-form-field style="width:28%"> <mat-form-field style="width:28%">
<input matInput autocomplete="off" placeholder="Net Loss to Sales in %" formControlName="financial_margin_of_loss" (keypress)="keyPress($event)" reaonly> <input matInput autocomplete="off" placeholder="Net Loss to Sales in %"
formControlName="financial_margin_of_loss" (keypress)="keyPress($event)"
reaonly>
</mat-form-field> </mat-form-field>
</span> </span>
</div> </div>
<span *ngIf="i != 0"> <span *ngIf="i != 0">
<mat-form-field style="width:45%"> <mat-form-field style="width:45%">
<input matInput autocomplete="off" [ngClass]="{'highlight': (details.controls['financial_variation'].value > 40) || (details.controls['financial_variation'].value < -40)}" placeholder="Profit Variation from Previous Year in %" formControlName="financial_variation" (keypress)="keyPress($event)" readonly> <input matInput autocomplete="off" [ngClass]="{'highlight': (details.controls['financial_variation'].value > 40) || (details.controls['financial_variation'].value < -40)}"
<mat-hint align="start" style="font-size:70%" *ngIf="i != 0 && details.get('financial_variation').value != '' " [ngClass]="{'highlight': (details.controls['financial_variation'].value > 40) || (details.controls['financial_variation'].value < -40)}" > placeholder="Profit Variation from Previous Year in %"
formControlName="financial_variation" (keypress)="keyPress($event)"
readonly>
<mat-hint align="start" style="font-size:70%" *ngIf="i != 0 && details.get('financial_variation').value != '' "
[ngClass]="{'highlight': (details.controls['financial_variation'].value > 40) || (details.controls['financial_variation'].value < -40)}">
<span *ngIf="details.get('financial_variation').value == 0"> <span *ngIf="details.get('financial_variation').value == 0">
No difference in Profit in FY <i> {{details.get('financial_year').value}} </i> over Profit in FY <i> {{financialForm.controls.date_per_financial['controls'][i-1].get('financial_year').value}} </i> No difference in Profit in FY <i>
{{details.get('financial_year').value}} </i> over
Profit in FY <i>
{{financialForm.controls.date_per_financial['controls'][i-1].get('financial_year').value}}
</i>
</span> </span>
<span *ngIf="details.get('financial_variation').value > 0" class="greenhighlight"> <span *ngIf="details.get('financial_variation').value > 0"
Increase in Profit in FY <i> {{details.get('financial_year').value}} </i> over Profit in FY <i> {{financialForm.controls.date_per_financial['controls'][i-1].get('financial_year').value}} </i> <b> {{details.get('financial_variation').value}} % </b> class="greenhighlight">
Increase in Profit in FY <i>
{{details.get('financial_year').value}} </i> over
Profit in FY <i>
{{financialForm.controls.date_per_financial['controls'][i-1].get('financial_year').value}}
</i> <b> {{details.get('financial_variation').value}} % </b>
</span> </span>
<span *ngIf="details.get('financial_variation').value < 0" class="highlight"> <span *ngIf="details.get('financial_variation').value < 0"
Decrease in Profit in FY <i> {{details.get('financial_year').value}} </i> over Profit in FY <i> {{financialForm.controls.date_per_financial['controls'][i-1].get('financial_year').value}} </i> <b> {{(details.get('financial_variation').value).replace('-', '')}} % </b> class="highlight">
Decrease in Profit in FY <i>
{{details.get('financial_year').value}} </i> over
Profit in FY <i>
{{financialForm.controls.date_per_financial['controls'][i-1].get('financial_year').value}}
</i> <b>
{{(details.get('financial_variation').value).replace('-',
'')}} % </b>
</span> </span>
</mat-hint> </mat-hint>
<!-- “Increase in Sales in FY 2017-2018 over sales in FY 2016-2017 is 11.11%” --> <!-- “Increase in Sales in FY 2017-2018 over sales in FY 2016-2017 is 11.11%” -->
<!-- <mat-hint align="start" style="font-size:70%" *ngIf="i != 0" [ngClass]="{'highlight': (details.controls['financial_variation'].value > 40) || (details.controls['financial_variation'].value < -40)}" >{{SalesStatement[i]}}</mat-hint> -->
</mat-form-field> </mat-form-field>
<mat-form-field style="width:45%"> <mat-form-field style="width:45%">
<input matInput autocomplete="off" [ngClass]="{'highlight': (details.controls['financial_profit_to_sale_variation'].value > 40) || (details.controls['financial_profit_to_sale_variation'].value < -40)}" placeholder="Variation of Profit % over sales" formControlName="financial_profit_to_sale_variation" (keypress)="keyPress($event)" readonly> <input matInput autocomplete="off" [ngClass]="{'highlight': (details.controls['financial_profit_to_sale_variation'].value > 40) || (details.controls['financial_profit_to_sale_variation'].value < -40)}"
<mat-hint align="start" style="font-size:70%" *ngIf="i != 0 && details.get('financial_profit_to_sale_variation').value != '' " [ngClass]="{'highlight': (details.controls['financial_profit_to_sale_variation'].value > 40) || (details.controls['financial_profit_to_sale_variation'].value < -40)}"> placeholder="Variation of Profit % over sales" formControlName="financial_profit_to_sale_variation"
(keypress)="keyPress($event)" readonly>
<mat-hint align="start" style="font-size:70%" *ngIf="i != 0 && details.get('financial_profit_to_sale_variation').value != '' "
[ngClass]="{'highlight': (details.controls['financial_profit_to_sale_variation'].value > 40) || (details.controls['financial_profit_to_sale_variation'].value < -40)}">
<span *ngIf="details.get('financial_profit_to_sale_variation').value == 0"> <span *ngIf="details.get('financial_profit_to_sale_variation').value == 0">
No difference in Profit sales % in FY <i> {{details.get('financial_year').value}} </i> over Profit sales % in FY <i> {{financialForm.controls.date_per_financial['controls'][i-1].get('financial_year').value}} </i> No difference in Profit sales % in FY <i>
{{details.get('financial_year').value}} </i> over
Profit sales % in FY <i>
{{financialForm.controls.date_per_financial['controls'][i-1].get('financial_year').value}}
</i>
</span> </span>
<span *ngIf="details.get('financial_profit_to_sale_variation').value > 0" class="greenhighlight"> <span *ngIf="details.get('financial_profit_to_sale_variation').value > 0"
Increase in Profit sales % in FY <i> {{details.get('financial_year').value}} </i> over Profit sales % in FY <i> {{financialForm.controls.date_per_financial['controls'][i-1].get('financial_year').value}} </i> <b> {{details.get('financial_profit_to_sale_variation').value}} % </b> class="greenhighlight">
Increase in Profit sales % in FY <i>
{{details.get('financial_year').value}} </i> over
Profit sales % in FY <i>
{{financialForm.controls.date_per_financial['controls'][i-1].get('financial_year').value}}
</i> <b>
{{details.get('financial_profit_to_sale_variation').value}}
% </b>
</span> </span>
<span *ngIf="details.get('financial_profit_to_sale_variation').value < 0" class="highlight"> <span *ngIf="details.get('financial_profit_to_sale_variation').value < 0"
Decrease in Profit sales % in FY <i> {{details.get('financial_year').value}} </i> over Profit sales % in FY <i> {{financialForm.controls.date_per_financial['controls'][i-1].get('financial_year').value}} </i> <b> {{(details.get('financial_profit_to_sale_variation').value).replace('-', '')}} % </b> class="highlight">
Decrease in Profit sales % in FY <i>
{{details.get('financial_year').value}} </i> over
Profit sales % in FY <i>
{{financialForm.controls.date_per_financial['controls'][i-1].get('financial_year').value}}
</i> <b>
{{(details.get('financial_profit_to_sale_variation').value).replace('-',
'')}} % </b>
</span> </span>
</mat-hint> </mat-hint>
</mat-form-field> </mat-form-field>
</span> </span>
</mat-card-content> </mat-card-content>
</div> </div>
</div> </div>
<span *ngIf="isDisplay"> <span *ngIf="isDisplay">
<mat-form-field *ngIf="financial_no_of_year != '' && customerCommentsFlag" style="width:90%"> <mat-form-field *ngIf="financial_no_of_year != '' && customerCommentsFlag" style="width:90%">
<input matInput autocomplete="off" placeholder="Comments on Financials" formControlName="financial_reason" > <input matInput autocomplete="off" placeholder="Comments on Financials"
formControlName="financial_reason">
</mat-form-field> </mat-form-field>
</span> </span>
</mat-card> </mat-card>
</div> </div>
</div> </div>
<div fxLayout="row wrap" *ngIf="CustSegAbbr != 'AI'"> <div fxLayout="row wrap" *ngIf="CustSegAbbr != 'AI'">
<div fxFlex="100"> <div fxFlex="100">
<!-- -->
<mat-card> <mat-card>
<mat-card-header> <mat-card-header>
<mat-card-title><p> Financial as per Customer</p></mat-card-title> <mat-card-title>
<p> Financial as per Customer</p>
</mat-card-title>
</mat-card-header> </mat-card-header>
<!-- *ngIf="isDisplay" -->
<mat-form-field style="width:35%"> <mat-form-field style="width:35%">
<mat-select placeholder="Same as Financial Statements ?" formControlName="is_financial_customer" (selectionChange)="selectedFinancialCustomer($event.value)"> <mat-select placeholder="Same as Financial Statements ?" formControlName="is_financial_customer"
(selectionChange)="selectedFinancialCustomer($event.value)">
<mat-option value="yes">Yes</mat-option> <mat-option value="yes">Yes</mat-option>
<mat-option value="no">No</mat-option> <mat-option value="no">No</mat-option>
</mat-select> </mat-select>
</mat-form-field> </mat-form-field>
<div formArrayName="estimated_value"> <div formArrayName="estimated_value">
<div *ngFor="let details of financialForm.controls.estimated_value['controls']; let i=index" <div *ngFor="let details of financialForm.controls.estimated_value['controls']; let i=index"
[formGroupName]="i"> [formGroupName]="i">
<mat-card-content class="matcard"> <mat-card-content class="matcard">
<!-- <mat-label class="highlight"> <i>Financial Year : {{details.get('estimate_year').value}} </i> </mat-label>
<hr> -->
<!-- <div fxLayout="row"> -->
<div style="width:100%"> <div style="width:100%">
<!-- <br> -->
<!-- <span style="width:10%;padding-left:2%"><p>Sales</p></span> -->
<mat-form-field style="width:25%"> <mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Annual Sales From" formControlName="estimate_sales_from" (change)="calculateSalesAverage(i, details);" (keyup)="inWords($event,i,11)"> <input matInput autocomplete="off" placeholder="Annual Sales From"
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('estimate_sales_from').value != ''">{{"&#8377;"}} {{AV_SalesFrmInwords[i]}} Only</mat-hint> formControlName="estimate_sales_from" (change)="calculateSalesAverage(i, details);"
(keyup)="inWords($event,i,11)">
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('estimate_sales_from').value != ''">{{"&#8377;"}}
{{AV_SalesFrmInwords[i]}} Only</mat-hint>
</mat-form-field> </mat-form-field>
<!-- <span style="width:10%;padding-left:2%"><p>to</p></span> -->
<mat-form-field style="width:25%"> <mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Annual Sales To" formControlName="estimate_sales_to" (change)="confirmAlert(i, details);" (keyup)="inWords($event,i,12)"> <input matInput autocomplete="off" placeholder="Annual Sales To"
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('estimate_sales_to').value != ''">{{"&#8377;"}} {{AV_SalesToInwords[i]}} Only</mat-hint> formControlName="estimate_sales_to" (change)="confirmAlert(i, details);"
(keyup)="inWords($event,i,12)">
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('estimate_sales_to').value != ''">{{"&#8377;"}}
{{AV_SalesToInwords[i]}} Only</mat-hint>
</mat-form-field> </mat-form-field>
<!-- <span style="width:10%;padding-left:2%"><p>Average</p></span> -->
<mat-form-field style="width:25%"> <mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Considered Sales Average" formControlName="estimate_sales_average" readonly> <input matInput autocomplete="off" placeholder="Considered Sales Average"
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('estimate_sales_average').value != ''">{{"&#8377;"}} {{AV_SalesInwords[i]}} Only</mat-hint> formControlName="estimate_sales_average" readonly>
<!-- //{{"&#8377;"}} {{AV_SalesInwords[i]}} Only --> <mat-hint align="start" style="font-size:70%" *ngIf="details.get('estimate_sales_average').value != ''">{{"&#8377;"}}
{{AV_SalesInwords[i]}} Only</mat-hint>
</mat-form-field> </mat-form-field>
</div> </div>
<!-- </div> -->
<div style="width:100%"> <div style="width:100%">
<mat-form-field style="width:39%"> <mat-form-field style="width:39%">
<!-- <input matInput autocomplete="off" placeholder="Net Profit / Loss" formControlName="financial_net_profit" (change)="calMargin( i, details); calYearVariation( i, details)" type="number" > --> <mat-select placeholder="Was there Net Profit or Net Loss?"
<mat-select placeholder="Was there Net Profit or Net Loss?" formControlName="estimate_profit_or_loss" > formControlName="estimate_profit_or_loss">
<!-- (selectionChange)="selectedProfitOrLossType($event.value,2)"> -->
<mat-option value="1">Net Profit</mat-option> <mat-option value="1">Net Profit</mat-option>
<mat-option value="2">Net Loss</mat-option> <mat-option value="2">Net Loss</mat-option>
</mat-select> </mat-select>
</mat-form-field> </mat-form-field>
<mat-form-field style="width:40%" *ngIf="details.get('estimate_profit_or_loss').value != '' "> <mat-form-field style="width:40%" *ngIf="details.get('estimate_profit_or_loss').value != '' ">
<mat-select placeholder="Is there Net Margin information Available?" formControlName="estimate_net_margin_availablity" > <mat-select placeholder="Is there Net Margin information Available?"
formControlName="estimate_net_margin_availablity">
<mat-option value="yes">Yes</mat-option> <mat-option value="yes">Yes</mat-option>
<mat-option value="no">No</mat-option> <mat-option value="no">No</mat-option>
</mat-select> </mat-select>
</mat-form-field> </mat-form-field>
<!-- <span *ngIf="details.get('estimate_profit_or_loss').value == 1 "> -->
<!-- <mat-form-field style="width:28%">
<input matInput autocomplete="off" placeholder="Net Profit Amount" formControlName="estimate_net_profit" (change)="calMarginVal( i, details); calVariation( i, details)" (keyup)="inWords($event,i,5)">
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('estimate_net_profit').value != ''">{{"&#8377;"}} {{AV_netProfitAmtInwords[i]}} Only</mat-hint>
</mat-form-field>
<mat-form-field style="width:28%">
<input matInput autocomplete="off" placeholder="Net Profit to Sales in %" formControlName="estimate_margin_of_profit" (change)="calProfitAndLossVal(i,details); calVariation( i, details)" (keypress)="keyPress($event)" >
</mat-form-field> -->
<div style="width:100%" *ngIf="details.get('estimate_profit_or_loss').value == 1 && details.get('estimate_net_margin_availablity').value == 'yes' "> <div style="width:100%" *ngIf="details.get('estimate_profit_or_loss').value == 1 && details.get('estimate_net_margin_availablity').value == 'yes' ">
<mat-form-field style="width:25%"> <mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Net Profit % From" formControlName="estimate_profit_range_from" type="number" min='0' max='100' (change)="calculateMarginProfit( i, details);"> <input matInput autocomplete="off" placeholder="Net Profit % From"
formControlName="estimate_profit_range_from" type="number"
min='0' max='100' (change)="calculateMarginProfit( i, details);">
</mat-form-field> </mat-form-field>
<mat-form-field style="width:25%"> <mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Net Profit % To" formControlName="estimate_profit_range_to" type="number" min='0' max='100' (change)="calculateMarginProfit( i, details);"> <input matInput autocomplete="off" placeholder="Net Profit % To"
formControlName="estimate_profit_range_to" type="number"
min='0' max='100' (change)="calculateMarginProfit( i, details);">
</mat-form-field> </mat-form-field>
<mat-form-field style="width:25%"> <mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Net Profit % Considered" formControlName="estimate_profit_margin_percent" type="number" readonly> <input matInput autocomplete="off" placeholder="Net Profit % Considered"
formControlName="estimate_profit_margin_percent" type="number"
readonly>
<!-- <mat-hint align="start" style="font-size:70%" *ngIf="details.get('estimate_profit_margin').value != ''"> {{"&#8377;"}} {{AV_marginProfitAmtInwords[i]}} Only ( {{"&#8377;"}} {{details.get('estimate_profit_margin').value}} ) </mat-hint> --> <!-- <mat-hint align="start" style="font-size:70%" *ngIf="details.get('estimate_profit_margin').value != ''"> {{"&#8377;"}} {{AV_marginProfitAmtInwords[i]}} Only ( {{"&#8377;"}} {{details.get('estimate_profit_margin').value}} ) </mat-hint> -->
</mat-form-field> </mat-form-field>
<mat-form-field style="width:25%"> <mat-form-field style="width:25%">
<input matInput placeholder="Net Profit Amount Considered" formControlName="estimate_profit_margin" readonly> <input matInput placeholder="Net Profit Amount Considered"
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('estimate_profit_margin').value != ''"> {{"&#8377;"}} {{AV_marginProfitAmtInwords[i]}} Only </mat-hint> formControlName="estimate_profit_margin" readonly>
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('estimate_profit_margin').value != ''">
{{"&#8377;"}} {{AV_marginProfitAmtInwords[i]}} Only
</mat-hint>
</mat-form-field> </mat-form-field>
</div> </div>
<div style="width:100%" *ngIf="details.get('estimate_profit_or_loss').value == 1 && details.get('estimate_net_margin_availablity').value == 'no' "> <div style="width:100%" *ngIf="details.get('estimate_profit_or_loss').value == 1 && details.get('estimate_net_margin_availablity').value == 'no' ">
<mat-form-field style="width:25%"> <mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Net Profit Amount From" formControlName="estimate_net_profit_from" type="number" (change)="calculateProfitAmount(i, details);" (keyup)="inWords($event,i,7)"> <input matInput autocomplete="off" placeholder="Net Profit Amount From"
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('estimate_net_profit_from').value != ''">{{"&#8377;"}} {{AV_netProfitAmtFrmInwords[i]}} Only </mat-hint> formControlName="estimate_net_profit_from" type="number"
(change)="calculateProfitAmount(i, details);" (keyup)="inWords($event,i,7)">
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('estimate_net_profit_from').value != ''">{{"&#8377;"}}
{{AV_netProfitAmtFrmInwords[i]}} Only </mat-hint>
</mat-form-field> </mat-form-field>
<mat-form-field style="width:25%"> <mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Net Profit Amount To" formControlName="estimate_net_profit_to" type="number" (change)="calculateProfitAmount(i, details);" (keyup)="inWords($event,i,8)"> <input matInput autocomplete="off" placeholder="Net Profit Amount To"
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('estimate_net_profit_to').value != ''">{{"&#8377;"}} {{AV_netProfitAmtToInwords[i]}} Only </mat-hint> formControlName="estimate_net_profit_to" type="number"
(change)="calculateProfitAmount(i, details);" (keyup)="inWords($event,i,8)">
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('estimate_net_profit_to').value != ''">{{"&#8377;"}}
{{AV_netProfitAmtToInwords[i]}} Only </mat-hint>
</mat-form-field> </mat-form-field>
<mat-form-field style="width:25%"> <mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Considered Net Profit % " formControlName="estimate_net_profit_percent" readonly> <input matInput autocomplete="off" placeholder="Considered Net Profit % "
formControlName="estimate_net_profit_percent" readonly>
</mat-form-field> </mat-form-field>
<mat-form-field style="width:25%"> <mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Considered Profit Amount" formControlName="estimate_net_profit" type="number" readonly> <input matInput autocomplete="off" placeholder="Considered Profit Amount"
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('estimate_net_profit').value != ''">{{"&#8377;"}} {{AV_netProfitAmtInwords[i]}} Only </mat-hint> formControlName="estimate_net_profit" type="number"
<!-- // --> readonly>
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('estimate_net_profit').value != ''">{{"&#8377;"}}
{{AV_netProfitAmtInwords[i]}} Only </mat-hint>
</mat-form-field> </mat-form-field>
</div> </div>
<!-- </span> --> <div style="width:100%" *ngIf="details.get('estimate_profit_or_loss').value == 2 && details.get('estimate_net_margin_availablity').value == 'yes' ">
<div *ngIf="details.get('estimate_net_profit').value != ''"> <mat-form-field style="width:25%">
<mat-card-subtitle> Working Capital Details </mat-card-subtitle> <input matInput autocomplete="off" placeholder="Net Loss % From"
<mat-form-field style="width:50%"> formControlName="estimate_loss_range_from" min='0' max='100'
<input matInput autocomplete="off" placeholder="In case of Credit Sales, what is the average no of days taken to receive the money?" formControlName="estimate_receive_the_money_in_days" type="number"> type="number" (change)="calculateMarginLoss( i, details);">
</mat-form-field> </mat-form-field>
<mat-form-field style="width:50%"> <mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="In case of Credit Purchase, what is the average no of days taken to pay the money?" formControlName="estimate_pay_the_money_in_days" type="number"> <input matInput autocomplete="off" placeholder="Net Loss % To"
formControlName="estimate_loss_range_to" min='0' max='100'
type="number" (change)="calculateMarginLoss( i, details);">
</mat-form-field> </mat-form-field>
<mat-form-field style="width:50%"> <mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="What is the average no of days for which stock lies unsold during the year?" formControlName="estimate_unsold_stock_lies_in_days" type="number"> <input matInput autocomplete="off" placeholder="Net Loss % Considered"
formControlName="estimate_loss_margin_percent" type="number"
readonly>
</mat-form-field> </mat-form-field>
<mat-form-field style="width:50%"> <mat-form-field style="width:25%">
<input matInput placeholder="Net Loss Amount Considered"
formControlName="estimate_loss_margin" readonly>
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('estimate_loss_margin').value != ''">{{"&#8377;"}}
{{AV_marginLossAmtInwords[i]}} Only </mat-hint>
</mat-form-field>
</div>
<div style="width:100%" *ngIf="details.get('estimate_profit_or_loss').value == 2 && details.get('estimate_net_margin_availablity').value == 'no' ">
<mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Net Loss Amount From"
formControlName="estimate_net_loss_from" type="number"
(change)="calculateLossAmount(i, details);" (keyup)="inWords($event,i,9)">
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('estimate_net_loss_from').value != ''">{{"&#8377;"}}
{{AV_netLossAmtFrmInwords[i]}} Only </mat-hint>
</mat-form-field>
<mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Net Loss Amount To"
formControlName="estimate_net_loss_to" type="number"
(change)="calculateLossAmount(i, details);" (keyup)="inWords($event,i,10)">
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('estimate_net_loss_to').value != ''">{{"&#8377;"}}
{{AV_netLossAmtToInwords[i]}} Only </mat-hint>
</mat-form-field>
<mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Considered Net Loss %"
formControlName="estimate_net_loss_percent" readonly>
</mat-form-field>
<mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Considered Loss Amount"
formControlName="estimate_net_loss" type="number" readonly>
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('estimate_net_loss').value != ''">{{"&#8377;"}}
{{AV_netLossAmtInwords[i]}} Only</mat-hint>
</mat-form-field>
</div>
<div style="width:100%" *ngIf="details.get('estimate_profit_or_loss').value == 2">
<mat-form-field style="width:83%">
<input matInput autocomplete="off" placeholder="What is the reason for the Loss?"
formControlName="estimate_reason_for_loss">
</mat-form-field>
</div>
</div>
</mat-card-content>
</div>
</div>
</mat-card>
</div>
</div>
<div fxLayout="row wrap">
<div fxFlex="100">
<mat-card>
<mat-card-header>
<mat-card-title>
<p>Working Capital Details</p>
</mat-card-title>
</mat-card-header>
<mat-card-content>
<!-- <mat-card-subtitle> Working Capital Details </mat-card-subtitle> -->
<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" type="number">
</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" type="number">
</mat-form-field>
<mat-form-field style="width:92%">
<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" type="number">
</mat-form-field>
<mat-form-field style="width:92%">
<mat-select placeholder="Is there Working Capital Facilities?" formControlName="is_there_working_capital_available"> <mat-select placeholder="Is there Working Capital Facilities?" formControlName="is_there_working_capital_available">
<mat-option value="yes">Yes</mat-option> <mat-option value="yes">Yes</mat-option>
<mat-option value="no">No</mat-option> <mat-option value="no">No</mat-option>
</mat-select> </mat-select>
</mat-form-field> </mat-form-field>
<mat-form-field style="width:45%;" *ngIf="details.get('is_there_working_capital_available').value == 'yes'"> <mat-form-field style="width:45%;" *ngIf="financialForm.controls.is_there_working_capital_available.value == 'yes'">
<mat-select multiple formControlName="estimate_working_capital_facilities_availed" placeholder="Working Capital Facilities availed"> <mat-select multiple formControlName="working_capital_facilities_availed"
placeholder="Working Capital Facilities availed">
<!-- <mat-option>Select</mat-option> -->
<mat-option *ngFor="let a of av" [value]="a.id">{{a.name}}</mat-option> <mat-option *ngFor="let a of av" [value]="a.id">{{a.name}}</mat-option>
</mat-select> </mat-select>
</mat-form-field> </mat-form-field>
<mat-form-field style="width:45%;" *ngIf="details.get('estimate_working_capital_facilities_availed').value != ''"> <mat-form-field style="width:42%;" *ngIf="financialForm.controls.is_there_working_capital_available.value == 'yes' && financialForm.controls.working_capital_facilities_availed.value != ''">
<input matInput autocomplete="off" placeholder="Specify The Reason" formControlName="reason_for_working_capital_facilities_availed"> <input matInput autocomplete="off" placeholder="Specify The Reason"
formControlName="reason_for_working_capital_facilities_availed">
</mat-form-field> </mat-form-field>
</div>
<!-- <table>
<tr *ngFor="let value of values">
<ng-container>
<td>
<input #chkEnable ngModel type="checkbox" />
</td>
<td [disabled]="!chkEnable.checked">
<mat-form-field>
<input matInput autocomplete="off" type="text" placeholder="Enter text here">
</mat-form-field>
<input />
</td>
</ng-container>
</tr>
</table> -->
<!-- <span *ngIf="details.get('estimate_profit_or_loss').value == 2 "> -->
<div style="width:100%" *ngIf="details.get('estimate_profit_or_loss').value == 2 && details.get('estimate_net_margin_availablity').value == 'yes' ">
<mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Net Loss % From" formControlName="estimate_loss_range_from" min='0' max='100' type="number" (change)="calculateMarginLoss( i, details);">
</mat-form-field>
<mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Net Loss % To" formControlName="estimate_loss_range_to" min='0' max='100' type="number" (change)="calculateMarginLoss( i, details);">
</mat-form-field>
<mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Net Loss % Considered" formControlName="estimate_loss_margin_percent" type="number" readonly>
<!-- <mat-hint align="start" style="font-size:70%" *ngIf="details.get('estimate_loss_margin').value != ''">{{"&#8377;"}} {{AV_marginLossAmtInwords[i]}} Only ( {{"&#8377;"}} {{details.get('estimate_loss_margin').value}} ) </mat-hint> -->
<!-- // -->
</mat-form-field>
<mat-form-field style="width:25%">
<input matInput placeholder="Net Loss Amount Considered" formControlName="estimate_loss_margin" readonly>
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('estimate_loss_margin').value != ''">{{"&#8377;"}} {{AV_marginLossAmtInwords[i]}} Only </mat-hint>
</mat-form-field>
</div>
<div style="width:100%" *ngIf="details.get('estimate_profit_or_loss').value == 2 && details.get('estimate_net_margin_availablity').value == 'no' ">
<mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Net Loss Amount From" formControlName="estimate_net_loss_from" type="number" (change)="calculateLossAmount(i, details);" (keyup)="inWords($event,i,9)">
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('estimate_net_loss_from').value != ''">{{"&#8377;"}} {{AV_netLossAmtFrmInwords[i]}} Only </mat-hint>
</mat-form-field>
<mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Net Loss Amount To" formControlName="estimate_net_loss_to" type="number" (change)="calculateLossAmount(i, details);" (keyup)="inWords($event,i,10)">
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('estimate_net_loss_to').value != ''">{{"&#8377;"}} {{AV_netLossAmtToInwords[i]}} Only </mat-hint>
</mat-form-field>
<mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Considered Net Loss %" formControlName="estimate_net_loss_percent" readonly>
</mat-form-field>
<mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Considered Loss Amount" formControlName="estimate_net_loss" type="number" readonly>
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('estimate_net_loss').value != ''">{{"&#8377;"}} {{AV_netLossAmtInwords[i]}} Only</mat-hint>
<!-- // -->
</mat-form-field>
</div>
<div style="width:100%" *ngIf="details.get('estimate_profit_or_loss').value == 2">
<mat-form-field style="width:83%">
<input matInput autocomplete="off" placeholder="What is the reason for the Loss?" formControlName="estimate_reason_for_loss">
</mat-form-field>
</div>
<!-- <mat-form-field style="width:28%">
<input matInput autocomplete="off" placeholder="Net Loss" formControlName="estimate_net_loss" (change)="calMarginVal( i, details); calVariation( i, details)" (keyup)="inWords($event,i,6)">
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('estimate_net_loss').value != ''">{{"&#8377;"}} {{AV_netLossAmtInwords[i]}} Only</mat-hint>
</mat-form-field>
<mat-form-field style="width:28%">
<input matInput autocomplete="off" placeholder="Net Loss to Sales" formControlName="estimate_margin_of_loss" (keypress)="keyPress($event)" (change)="calProfitAndLossVal(i,details); calVariation( i, details)" >
</mat-form-field> -->
<!-- </span> -->
</div>
<!-- <mat-form-field *ngIf="i != 0" style="width:65%">
<input matInput autocomplete="off" [ngClass]="{'highlight': details.controls['estimate_variation'].value >= 40 || details.controls['estimate_variation'].value >= -40}" placeholder="Variation from Previous Year in %" formControlName="estimate_variation" (keypress)="keyPress($event)">
<mat-hint align="start" style="font-size:70%" [ngClass]="{'highlight': (details.controls['estimate_variation'].value >= 40) || (details.controls['estimate_variation'].value < -40)}" >
<span *ngIf="details.get('estimate_variation').value == 0">
No difference in Profit in FY <i> {{details.get('estimate_year').value}} </i> over Profit in FY <i> {{financialForm.controls.estimated_value['controls'][i-1].get('estimate_year').value}} </i>
</span>
<span *ngIf="details.get('estimate_variation').value > 0" class="greenhighlight">
Increase in Profit in FY <i> {{details.get('estimate_year').value}} </i> over Profit in FY<i> {{financialForm.controls.estimated_value['controls'][i-1].get('estimate_year').value}} </i> <b> {{details.get('estimate_variation').value}} % </b>
</span>
<span *ngIf="details.get('estimate_variation').value < 0" class="highlight">
Decrease in Profit in FY <i> {{details.get('estimate_year').value}} </i>over Profit in FY <i> {{financialForm.controls.estimated_value['controls'][i-1].get('estimate_year').value}} </i> <b> {{(details.get('estimate_variation').value).replace('-', '')}} % </b>
</span>
<!-- {{details.controls[''].value}} {{details.controls[''].value}} -->
<!-- 'details.controls['estimate_variation'].value <= 0' ? 'Decreases ' : 'Increases ' + 'in Sales in FY ' + curr_year + ' Over Sales in FY '+ prev_year + ' is ' + {{details.controls['estimate_variation'].value}} + '%'; -->
<!--</mat-hint>
</mat-form-field> -->
<!--<mat-form-field>
<input matInput autocomplete="off" placeholder="Reason For Major Difference" formControlName="estimate_reason" >
</mat-form-field>-->
<!-- <button type="button" mat-raised-button mat-icon-button (click)="addGoods()"
matTooltip="Add More Estimated Value" matTooltipPosition="above" class="mr-1 mb-1 hover-icon" color="primary" *ngIf="i==0">
<mat-icon>add</mat-icon>
</button> -->
<!-- <button type="button" mat-raised-button mat-icon-button (click)="deleteGoods(i)"
matTooltip="Delete" matTooltipPosition="above" class="mr-1 mb-1 hover-icon" *ngIf="i>0">
<mat-icon>delete</mat-icon>
</button> -->
</mat-card-content> </mat-card-content>
</div>
</div>
</mat-card> </mat-card>
<!-- end co apllicant -->
</div> </div>
</div> </div>
</ng-template> </ng-template>
@ -454,43 +485,91 @@
<div fxFlex="row"> <div fxFlex="row">
<div fxFlex="100" class="m-gap p-gap"> <div fxFlex="100" class="m-gap p-gap">
<div fxLayout="row" fxLayoutWrap="wrap"> <div fxLayout="row" fxLayoutWrap="wrap">
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50" fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"> <div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
<a href="http://www.google.com"><mat-icon style="color: #e00201;font-size: 60px !important;width:inherit !important;">picture_as_pdf</mat-icon> <span class="d-block">version_111</span></a> fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20">
<a href="http://www.google.com">
<mat-icon style="color: #e00201;font-size: 60px !important;width:inherit !important;">picture_as_pdf</mat-icon>
<span class="d-block">version_111</span>
</a>
</div> </div>
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50" fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"> <div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
<a href="http://www.google.com"><mat-icon style="color: #e00201;font-size: 60px !important;width:inherit !important;">picture_as_pdf</mat-icon> <span class="d-block">version_111</span></a> fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20">
<a href="http://www.google.com">
<mat-icon style="color: #e00201;font-size: 60px !important;width:inherit !important;">picture_as_pdf</mat-icon>
<span class="d-block">version_111</span>
</a>
</div> </div>
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50" fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"> <div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
<a href="http://www.google.com"><mat-icon style="color: #e00201;font-size: 60px !important;width:inherit !important;">picture_as_pdf</mat-icon> <span class="d-block">version_111</span></a> fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20">
<a href="http://www.google.com">
<mat-icon style="color: #e00201;font-size: 60px !important;width:inherit !important;">picture_as_pdf</mat-icon>
<span class="d-block">version_111</span>
</a>
</div> </div>
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50" fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"> <div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
<a href="http://www.google.com"><mat-icon style="color: #e00201;font-size: 60px !important;width:inherit !important;">picture_as_pdf</mat-icon> <span class="d-block">version_111</span></a> fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20">
<a href="http://www.google.com">
<mat-icon style="color: #e00201;font-size: 60px !important;width:inherit !important;">picture_as_pdf</mat-icon>
<span class="d-block">version_111</span>
</a>
</div> </div>
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50" fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"> <div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
<a href="http://www.google.com"><mat-icon style="color: #e00201;font-size: 60px !important;width:inherit !important;">picture_as_pdf</mat-icon> <span class="d-block">version_111</span></a> fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20">
<a href="http://www.google.com">
<mat-icon style="color: #e00201;font-size: 60px !important;width:inherit !important;">picture_as_pdf</mat-icon>
<span class="d-block">version_111</span>
</a>
</div> </div>
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50" fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"> <div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
<a href="http://www.google.com"><mat-icon style="color: #e00201;font-size: 60px !important;width:inherit !important;">picture_as_pdf</mat-icon> <span class="d-block">version_111</span></a> fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20">
<a href="http://www.google.com">
<mat-icon style="color: #e00201;font-size: 60px !important;width:inherit !important;">picture_as_pdf</mat-icon>
<span class="d-block">version_111</span>
</a>
</div> </div>
</div> </div>
<div fxLayout="row" fxLayoutWrap="wrap"> <div fxLayout="row" fxLayoutWrap="wrap">
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50" fxFlex.md="25" fxFlex.lg="25" fxFlex.xl="25"> <div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
<a href="http://www.google.com"><mat-icon style="color: #e00201;font-size: 60px !important;width:inherit !important;">picture_as_pdf</mat-icon> <span class="d-block">version_111</span></a> fxFlex.md="25" fxFlex.lg="25" fxFlex.xl="25">
<a href="http://www.google.com">
<mat-icon style="color: #e00201;font-size: 60px !important;width:inherit !important;">picture_as_pdf</mat-icon>
<span class="d-block">version_111</span>
</a>
</div> </div>
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50" fxFlex.md="25" fxFlex.lg="25" fxFlex.xl="25"> <div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
<a href="http://www.google.com"><mat-icon style="color: #e00201;font-size: 60px !important;width:inherit !important;">picture_as_pdf</mat-icon> <span class="d-block">version_111</span></a> fxFlex.md="25" fxFlex.lg="25" fxFlex.xl="25">
<a href="http://www.google.com">
<mat-icon style="color: #e00201;font-size: 60px !important;width:inherit !important;">picture_as_pdf</mat-icon>
<span class="d-block">version_111</span>
</a>
</div> </div>
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50" fxFlex.md="25" fxFlex.lg="25" fxFlex.xl="25"> <div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
<a href="http://www.google.com"><mat-icon style="color: #e00201;font-size: 60px !important;width:inherit !important;">picture_as_pdf</mat-icon> <span class="d-block">version_111</span></a> fxFlex.md="25" fxFlex.lg="25" fxFlex.xl="25">
<a href="http://www.google.com">
<mat-icon style="color: #e00201;font-size: 60px !important;width:inherit !important;">picture_as_pdf</mat-icon>
<span class="d-block">version_111</span>
</a>
</div> </div>
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50" fxFlex.md="25" fxFlex.lg="25" fxFlex.xl="25"> <div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
<a href="http://www.google.com"><mat-icon style="color: #e00201;font-size: 60px !important;width:inherit !important;">picture_as_pdf</mat-icon> <span class="d-block">version_111</span></a> fxFlex.md="25" fxFlex.lg="25" fxFlex.xl="25">
<a href="http://www.google.com">
<mat-icon style="color: #e00201;font-size: 60px !important;width:inherit !important;">picture_as_pdf</mat-icon>
<span class="d-block">version_111</span>
</a>
</div> </div>
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50" fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"> <div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
<a href="http://www.google.com"><mat-icon style="color: #e00201;font-size: 60px !important;width:inherit !important;">picture_as_pdf</mat-icon> <span class="d-block">version_111</span></a> fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20">
<a href="http://www.google.com">
<mat-icon style="color: #e00201;font-size: 60px !important;width:inherit !important;">picture_as_pdf</mat-icon>
<span class="d-block">version_111</span>
</a>
</div> </div>
<div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50" fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20"> <div class="text-center mb-2 hover-icon" fxFlex.xs="50" fxFlex.sm="50"
<a href="http://www.google.com"><mat-icon style="color: #e00201;font-size: 60px !important;width:inherit !important;">picture_as_pdf</mat-icon> <span class="d-block">version_111</span></a> fxFlex.md="20" fxFlex.lg="20" fxFlex.xl="20">
<a href="http://www.google.com">
<mat-icon style="color: #e00201;font-size: 60px !important;width:inherit !important;">picture_as_pdf</mat-icon>
<span class="d-block">version_111</span>
</a>
</div> </div>
</div> </div>
</div> </div>
@ -499,9 +578,7 @@
</div> </div>
</ng-template> </ng-template>
</mat-tab> </mat-tab>
</mat-tab-group> </mat-tab-group>
</mat-dialog-content> </mat-dialog-content>
<mat-dialog-actions> <mat-dialog-actions>
<div fxFlex="60" class="pb-0 text-sm-left" align="left"> <div fxFlex="60" class="pb-0 text-sm-left" align="left">
@ -511,107 +588,11 @@
</mat-form-field> </mat-form-field>
</div> </div>
<div fxFlex="40" align="end"> <div fxFlex="40" align="end">
<button type="submit" class="mr-1 mb-1 hover-icon" mat-raised-button mat-icon-button matTooltip="Submit" matTooltipPosition="above" (click)="submitDetails()"><mat-icon>save</mat-icon> <button type="submit" class="mr-1 mb-1 hover-icon" mat-raised-button mat-icon-button matTooltip="Submit"
matTooltipPosition="above" (click)="submitDetails()">
<mat-icon>save</mat-icon>
</button> </button>
</div> </div>
</mat-dialog-actions> </mat-dialog-actions>
</form> </form>
<notifier-container></notifier-container> <notifier-container></notifier-container>
<!-- <mat-card style="padding: 12px;">
<p>Financial Information</p>
<form [formGroup]="financialForm" class="address">
<mat-card>
<mat-card-header>
<p>Data as Per Financial Statements<p>
</mat-card-header>
<div formArrayName="date_per_financial">
<div *ngFor="let details of financialForm.controls.date_per_financial['controls']; let i=index"
[formGroupName]="i">
<mat-card-content class="matcard">
<mat-form-field>
<input matInput autocomplete="off" placeholder="Year (format: 2015-16)" formControlName="financial_year" >
</mat-form-field>
<mat-form-field>
<input matInput autocomplete="off" placeholder="Annual Sale" formControlName="financial_annual_sale" (change)="calMargin(i, details)" type="number" >
</mat-form-field>
<mat-form-field>
<input matInput autocomplete="off" placeholder="Net Profit / Loss" formControlName="financial_net_profit" (change)="calMargin( i, details); calYearVariation( i, details)" type="number" >
</mat-form-field>
<mat-form-field>
<input matInput autocomplete="off" placeholder="Net Profit to Sales" formControlName="financial_margin" (keypress)="keyPress($event)" >
</mat-form-field>
<mat-form-field *ngIf="i != 0">
<input matInput autocomplete="off" [ngClass]="{'highlight': (details.controls['financial_variation'].value > 40) || (details.controls['financial_variation'].value < -40)}" placeholder="Variation from Previous Year in %" formControlName="financial_variation" (keypress)="keyPress($event)">
</mat-form-field>
<mat-form-field>
<input matInput autocomplete="off" placeholder="Reason For Major Difference" formControlName="financial_reason" >
</mat-form-field>
<button type="button" mat-raised-button mat-icon-button (click)="addDate()"
matTooltip="Add More Financial Statements" matTooltipPosition="above" class="mr-1 mb-1 hover-icon" color="primary" *ngIf="i==0">
<mat-icon>add</mat-icon>
</button>
<button type="button" mat-raised-button mat-icon-button (click)="deleteDate(i)"
matTooltip="Delete" matTooltipPosition="above" class="mr-1 mb-1 hover-icon" *ngIf="i>0">
<mat-icon>delete</mat-icon>
</button>
</mat-card-content>
</div>
</div>
</mat-card>
<mat-card>
<mat-card-header>
<p>Actual Values as per Customer<p>
</mat-card-header>
<div formArrayName="estimated_value">
<div *ngFor="let details of financialForm.controls.estimated_value['controls']; let i=index"
[formGroupName]="i">
<mat-card-content class="matcard">
<mat-form-field>
<input matInput autocomplete="off" placeholder="Year (format: 2015-16)" formControlName="estimate_year" >
</mat-form-field>
<mat-form-field>
<input matInput autocomplete="off" placeholder="Annual Sale" formControlName="estimate_annual_sale" (change)="calMarginVal( i, details)" type="number" >
</mat-form-field>
<mat-form-field>
<input matInput autocomplete="off" placeholder="Net Profit / Loss" formControlName="estimate_net_profit" (change)="calMarginVal( i, details); calVariation( i, details)" type="number" >
</mat-form-field>
<mat-form-field>
<input matInput autocomplete="off" disabled placeholder="Margin" formControlName="estimate_margin" (keypress)="keyPress($event)" >
</mat-form-field>
<mat-form-field *ngIf="i != 0">
<input matInput autocomplete="off" [ngClass]="{'highlight': details.controls['estimate_variation'].value >= 40 || details.controls['estimate_variation'].value >= -40}" placeholder="Variation from Previous Year in %" formControlName="estimate_variation" (keypress)="keyPress($event)">
</mat-form-field>
<!--<mat-form-field>
<input matInput autocomplete="off" placeholder="Reason For Major Difference" formControlName="estimate_reason" >
</mat-form-field>-->
<!-- <button type="button" mat-raised-button mat-icon-button (click)="addGoods()"
matTooltip="Add More Estimated Value" matTooltipPosition="above" class="mr-1 mb-1 hover-icon" color="primary" *ngIf="i==0">
<mat-icon>add</mat-icon>
</button>
<button type="button" mat-raised-button mat-icon-button (click)="deleteGoods(i)"
matTooltip="Delete" matTooltipPosition="above" class="mr-1 mb-1 hover-icon" *ngIf="i>0">
<mat-icon>delete</mat-icon>
</button>
</mat-card-content>
</div>
</div>
</mat-card>
<div fxLayout="row">
<div fxFlex="60" class="pb-0 text-sm-left">
<mat-form-field appearance="outline" style="width: 100%">
<mat-label>Remarks</mat-label>
<textarea matInput autocomplete="off" placeholder="Remarks" formControlName="financial_remarks" ></textarea>
</mat-form-field>
</div>
</div>
<div style="text-align: right;">
<button type="submit" class="mr-1 mb-1 hover-icon" mat-raised-button mat-icon-button matTooltip="Submit" matTooltipPosition="above" (click)="submitDetails()"><mat-icon>save</mat-icon>
</button>
</div>
</form>
</mat-card> -->

View File

@ -211,6 +211,18 @@ export class FinancialInfoComponent implements OnInit {
financial_no_of_year : [''], financial_no_of_year : [''],
financial_reason: [''], financial_reason: [''],
financial_customer:[''], financial_customer:[''],
// estimate_receive_the_money_in_days:[value.estimate_receive_the_money_in_days],
// estimate_pay_the_money_in_days:[value.estimate_pay_the_money_in_days],
// estimate_unsold_stock_lies_in_days:[value.estimate_unsold_stock_lies_in_days],
// 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:[''],
working_capital_facilities_availed:[''],
reason_for_working_capital_facilities_availed:[''],
// same_as_financial_statements:[''], // same_as_financial_statements:[''],
date_per_financial: this.fb.array([]), date_per_financial: this.fb.array([]),
estimated_value: this.fb.array([]) estimated_value: this.fb.array([])
@ -310,12 +322,6 @@ export class FinancialInfoComponent implements OnInit {
estimate_net_loss_percent:[value.estimate_net_loss_percent], estimate_net_loss_percent:[value.estimate_net_loss_percent],
estimate_net_loss:[value.estimate_net_loss], estimate_net_loss:[value.estimate_net_loss],
estimate_reason_for_loss:[value.estimate_reason_for_loss], estimate_reason_for_loss:[value.estimate_reason_for_loss],
estimate_receive_the_money_in_days:[value.estimate_receive_the_money_in_days],
estimate_pay_the_money_in_days:[value.estimate_pay_the_money_in_days],
estimate_unsold_stock_lies_in_days:[value.estimate_unsold_stock_lies_in_days],
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]
}); });
} }
@ -388,7 +394,6 @@ export class FinancialInfoComponent implements OnInit {
this.isDisplay = false; this.isDisplay = false;
this.financialForm.controls['is_financial_customer'].setValue('no'); this.financialForm.controls['is_financial_customer'].setValue('no');
this.selectedFinancialCustomer('no');
const statementControl = <FormArray>this.financialForm.controls['date_per_financial']; const statementControl = <FormArray>this.financialForm.controls['date_per_financial'];

View File

@ -249,7 +249,7 @@ export class NeighbourHoodComponent implements OnInit {
// neighbourhoodControl.controls['do_know'].setValidators([Validators.required]); // neighbourhoodControl.controls['do_know'].setValidators([Validators.required]);
// neighbourhoodControl.controls['do_know'].updateValueAndValidity(); // neighbourhoodControl.controls['do_know'].updateValueAndValidity();
return; // return;
} }