finanical issues : ps
This commit is contained in:
parent
121ff7b31b
commit
376ffeaef8
@ -13,117 +13,117 @@
|
||||
|
||||
<mat-dialog-content>
|
||||
|
||||
<mat-tab-group>
|
||||
<mat-tab label="Questions">
|
||||
<ng-template matTabContent>
|
||||
<div fxLayout="row wrap">
|
||||
<div fxFlex="100">
|
||||
<mat-card>
|
||||
<mat-card-header>
|
||||
<mat-card-title><p> Data as Per Financial Statements</p></mat-card-title>
|
||||
</mat-card-header>
|
||||
<mat-tab-group>
|
||||
<mat-tab label="Questions">
|
||||
<ng-template matTabContent>
|
||||
<div fxLayout="row wrap">
|
||||
<div fxFlex="100">
|
||||
<mat-card>
|
||||
<mat-card-header>
|
||||
<mat-card-title><p> Data as Per Financial Statements</p></mat-card-title>
|
||||
</mat-card-header>
|
||||
|
||||
<div style="width:100%">
|
||||
<mat-form-field style="width:35%">
|
||||
<mat-label>Enter year from which financials provided</mat-label>
|
||||
<input matInput autocomplete="off" placeholder="YYYY eg.2018" formControlName="staring_financial_year" (keypress)="keyPress($event)" [readonly]="isReadOnly">
|
||||
<mat-error> Invalid year format</mat-error>
|
||||
</mat-form-field>
|
||||
<div style="width:100%">
|
||||
<mat-form-field style="width:35%">
|
||||
<mat-label>Enter year from which financials provided</mat-label>
|
||||
<input matInput autocomplete="off" placeholder="YYYY eg.2018" formControlName="staring_financial_year" (keypress)="keyPress($event)" [readonly]="isReadOnly">
|
||||
<mat-error> Invalid year format</mat-error>
|
||||
</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:35%">
|
||||
<input matInput autocomplete="off" placeholder="Number of Financial Years" formControlName="total_financial_year" (change)="dynamicalFinYear($event)" (keypress)="keyPress($event)" [readonly]="isReadOnly">
|
||||
</mat-form-field>
|
||||
</div>
|
||||
<mat-form-field style="width:35%">
|
||||
<input matInput autocomplete="off" placeholder="Number of Financial Years" formControlName="total_financial_year" (change)="dynamicalFinYear($event)" (keypress)="keyPress($event)" [readonly]="isReadOnly">
|
||||
</mat-form-field>
|
||||
</div>
|
||||
|
||||
<div *ngIf="total_financial_year != ''" formArrayName="date_per_financial">
|
||||
<div *ngIf="total_financial_year != ''" formArrayName="date_per_financial">
|
||||
<!-- <div formArrayName="date_per_financial"> -->
|
||||
<div *ngFor="let details of financialForm.controls.date_per_financial['controls']; let i=index"
|
||||
[formGroupName]="i">
|
||||
<div *ngFor="let details of financialForm.controls.date_per_financial['controls']; let i=index" [formGroupName]="i">
|
||||
|
||||
<mat-card-content class="matcard">
|
||||
<mat-label class="highlight"> <i>Financial Year : {{details.get('financial_year').value}} </i> </mat-label>
|
||||
<hr>
|
||||
<mat-card-content class="matcard">
|
||||
<mat-label class="highlight"> <i>Financial Year : {{details.get('financial_year').value}} </i> </mat-label>
|
||||
<hr>
|
||||
|
||||
<div style="width:100%">
|
||||
<br>
|
||||
<div style="width:100%">
|
||||
<br>
|
||||
|
||||
<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" formControlName="financial_annual_sale" (change)="calFinAnnualSale(i, details)" (keypress)="keyPress($event)" (keyup)="inWords($event,i,1)">
|
||||
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('financial_annual_sale').value != ''">{{"₹"}} {{FY_annualSalesInwords[i]}} Only</mat-hint>
|
||||
</mat-form-field>
|
||||
<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" formControlName="financial_annual_sale" (change)="calFinAnnualSale(i, details)" (keypress)="keyPress($event)" (keyup)="inWords($event,i,1)">
|
||||
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('financial_annual_sale').value != ''">{{"₹"}} {{FY_annualSalesInwords[i]}} Only</mat-hint>
|
||||
</mat-form-field>
|
||||
|
||||
<span *ngIf="i != 0">
|
||||
<mat-form-field style="width:60%">
|
||||
<input matInput autocomplete="off" placeholder="Sale Variation from Previous Year in %" formControlName="financial_annualsales_variation" (keypress)="keyPress($event)">
|
||||
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('financial_annualsales_variation').value != '' " >
|
||||
<span *ngIf="details.get('financial_annualsales_variation').value == 0">
|
||||
No differents 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 *ngIf="details.get('financial_annualsales_variation').value > 0" 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 *ngIf="details.get('financial_annualsales_variation').value < 0" 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>
|
||||
</mat-hint>
|
||||
</mat-form-field>
|
||||
</span>
|
||||
<span *ngIf="i != 0">
|
||||
<mat-form-field style="width:60%">
|
||||
<input matInput autocomplete="off" placeholder="Sale Variation from Previous Year in %" formControlName="financial_annualsales_variation" (keypress)="keyPress($event)">
|
||||
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('financial_annualsales_variation').value != '' " >
|
||||
<span *ngIf="details.get('financial_annualsales_variation').value == 0">
|
||||
No differents 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 *ngIf="details.get('financial_annualsales_variation').value > 0" 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 *ngIf="details.get('financial_annualsales_variation').value < 0" 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>
|
||||
</mat-hint>
|
||||
</mat-form-field>
|
||||
</span>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div style="width:100%">
|
||||
<mat-form-field style="width:30%">
|
||||
<div style="width:100%">
|
||||
<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" > -->
|
||||
<mat-select placeholder="Is there Net Profit or Net Loss?" formControlName="finanical_profit_or_loss" >
|
||||
<mat-select placeholder="Is there Net Profit or Net Loss?" formControlName="finanical_profit_or_loss" >
|
||||
<!-- (selectionChange)="selectedProfitOrLossType($event,1)> -->
|
||||
<mat-option value="1" >Net Profit</mat-option>
|
||||
<mat-option value="2" >Net Loss</mat-option>
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
<mat-option value="1" >Net Profit</mat-option>
|
||||
<mat-option value="2" >Net Loss</mat-option>
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
|
||||
<span *ngIf="details.get('finanical_profit_or_loss').value == 1 ">
|
||||
<mat-form-field style="width:28%">
|
||||
<input matInput autocomplete="off" placeholder="Net Profit Amount" formControlName="financial_net_profit" (change)="calMargin( i, details); calYearVariation( i, details)" (keypress)="keyPress($event)" (keyup)="inWords($event,i,2)">
|
||||
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('financial_net_profit').value != ''">{{"₹"}} {{FY_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="financial_margin_of_profit" (keypress)="keyPress($event)" >
|
||||
</mat-form-field>
|
||||
</span>
|
||||
<span *ngIf="details.get('finanical_profit_or_loss').value == 2 ">
|
||||
<mat-form-field style="width:28%">
|
||||
<input matInput autocomplete="off" placeholder="Net Loss Amount" formControlName="financial_net_loss" (change)="calMargin( i, details); calYearVariation( i, details)" (keypress)="keyPress($event)" (keyup)="inWords($event,i,3)">
|
||||
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('financial_net_loss').value != ''">{{"₹"}} {{FY_netLossAmtInwords[i]}} Only</mat-hint>
|
||||
</mat-form-field>
|
||||
<mat-form-field style="width:28%">
|
||||
<input matInput autocomplete="off" placeholder="Net Loss to Sales in %" formControlName="financial_margin_of_loss" (keypress)="keyPress($event)">
|
||||
</mat-form-field>
|
||||
</span>
|
||||
</div>
|
||||
<span *ngIf="details.get('finanical_profit_or_loss').value == 1 ">
|
||||
<mat-form-field style="width:28%">
|
||||
<input matInput autocomplete="off" placeholder="Net Profit Amount" formControlName="financial_net_profit" (change)="calMargin( i, details); calYearVariation( i, details)" (keypress)="keyPress($event)" (keyup)="inWords($event,i,2)">
|
||||
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('financial_net_profit').value != ''">{{"₹"}} {{FY_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="financial_margin_of_profit" (keypress)="keyPress($event)" >
|
||||
</mat-form-field>
|
||||
</span>
|
||||
|
||||
<span *ngIf="i != 0">
|
||||
<mat-form-field style="width:65%">
|
||||
<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)">
|
||||
<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">
|
||||
No differents 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 *ngIf="details.get('financial_variation').value > 0" 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 *ngIf="details.get('financial_variation').value < 0" 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>
|
||||
</mat-hint>
|
||||
<span *ngIf="details.get('finanical_profit_or_loss').value == 2 ">
|
||||
<mat-form-field style="width:28%">
|
||||
<input matInput autocomplete="off" placeholder="Net Loss Amount" formControlName="financial_net_loss" (change)="calMargin( i, details); calYearVariation( i, details)" (keypress)="keyPress($event)" (keyup)="inWords($event,i,3)">
|
||||
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('financial_net_loss').value != ''">{{"₹"}} {{FY_netLossAmtInwords[i]}} Only</mat-hint>
|
||||
</mat-form-field>
|
||||
<mat-form-field style="width:28%">
|
||||
<input matInput autocomplete="off" placeholder="Net Loss to Sales in %" formControlName="financial_margin_of_loss" (keypress)="keyPress($event)">
|
||||
</mat-form-field>
|
||||
</span>
|
||||
</div>
|
||||
|
||||
<span *ngIf="i != 0">
|
||||
<mat-form-field style="width:65%">
|
||||
<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)">
|
||||
<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">
|
||||
No differents 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 *ngIf="details.get('financial_variation').value > 0" 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 *ngIf="details.get('financial_variation').value < 0" 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>
|
||||
</mat-hint>
|
||||
<!-- “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>
|
||||
</span>
|
||||
</mat-form-field>
|
||||
</span>
|
||||
|
||||
|
||||
|
||||
@ -135,15 +135,16 @@
|
||||
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-form-field *ngIf="i != 0 && customerCommentsFlag" style="width:65%">
|
||||
</div>
|
||||
</div>
|
||||
<mat-form-field *ngIf="total_financial_year != '' && customerCommentsFlag" style="width:100%">
|
||||
<!-- <input matInput autocomplete="off" placeholder="Reason For Major Difference" formControlName="financial_reason" > -->
|
||||
<input matInput autocomplete="off" placeholder="Customer Comments on Financials" formControlName="financial_reason" >
|
||||
</mat-form-field>
|
||||
</mat-card>
|
||||
<input matInput autocomplete="off" placeholder="Customer Comments on Financials" formControlName="financial_reason" >
|
||||
</mat-form-field>
|
||||
</mat-card>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div fxLayout="row wrap">
|
||||
|
||||
@ -90,6 +90,7 @@ export class FinancialInfoComponent implements OnInit {
|
||||
this._pd.retriveForm(params).subscribe(value => {
|
||||
const financial_date = <FormArray>this.financialForm.controls['date_per_financial'];
|
||||
const estimated_val = <FormArray>this.financialForm.controls['estimated_value'];
|
||||
|
||||
if (value.status == 200) {
|
||||
let retriveData = value.records;
|
||||
this.isReadOnly = true;
|
||||
@ -145,6 +146,7 @@ export class FinancialInfoComponent implements OnInit {
|
||||
financial_remarks: [''],
|
||||
staring_financial_year : ['',Validators.compose([Validators.minLength(4),Validators.maxLength(4)])],
|
||||
total_financial_year : [''],
|
||||
financial_reason: [''],
|
||||
same_as_financial_statements:[''],
|
||||
date_per_financial: this.fb.array([]),
|
||||
estimated_value: this.fb.array([])
|
||||
@ -171,7 +173,7 @@ export class FinancialInfoComponent implements OnInit {
|
||||
financial_margin_of_loss: [''],
|
||||
financial_variation: [''],
|
||||
financial_annualsales_variation : [''],
|
||||
financial_reason: [''],
|
||||
|
||||
});
|
||||
}
|
||||
createValue(date) {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user