issues fixes : ps

This commit is contained in:
venbatechnologies@gmail.com 2019-04-01 12:35:11 +05:30
parent 662ec38892
commit 26f8e55308
10 changed files with 141 additions and 120 deletions

View File

@ -294,7 +294,7 @@
<!--Desction Dynamic details : END -->
<div fxLayout="row wrap" fxLayoutGap="2px" fxLayoutAlign="start none">
<mat-form-field *ngIf="sup.get('assets_mode').value == 1 || sup.get('assets_mode').value == 2 || sup.get('assets_mode').value == 3 || sup.get('assets_mode').value == 4 || sup.get('assets_mode').value == 5"
style="width:45%">
style="width:45%; height: 105px !important;">
<input matInput placeholder="Approximate Market Value" formControlName="approximate_market_value"
OnlyNumber type="text" autocomplete="off">
<mat-hint align="start" style="font-size:90%" *ngIf="sup.get('approximate_market_value').value != ''">{{"&#8377;"}} {{sup.get('approximate_market_value').value | numberToWords}} Only</mat-hint>

View File

@ -17,10 +17,12 @@
.matcard mat-form-field {
margin: 0 2%;
height: 105px !important;
}
mat-form-field {
margin: 0 2%;
height: 105px !important;
}
$base-card-box-shadow:1.5px 2.6px 24px 0 rgba(0, 35, 136, 0.08) !important;

View File

@ -60,7 +60,7 @@
<input matInput autocomplete="off" placeholder="Specify Loan Type"
formControlName="others_loan_type">
</mat-form-field>
<mat-form-field style="width:45%;">
<mat-form-field style="width:45%; height:105px;">
<input matInput autocomplete="off" placeholder="Loan Amount"
formControlName="loan_amount" OnlyNumber type="text">
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('loan_amount').value != ''">{{"&#8377;"}} {{details.get('loan_amount').value | numberToWords}} Only</mat-hint>

View File

@ -38,16 +38,16 @@
<br>
<div fxLayout="row" fxLayoutGap="2px" fxLayoutAlign="start none">
<mat-form-field>
<input matInput OnlyNumber type="text" autocomplete="off" placeholder="Year"
<input matInput OnlyNumber type="number" autocomplete="off" placeholder="Year"
formControlName="how_long_year" required min='0'>
<mat-error *ngIf="employmentForm.controls.how_long_year.hasError('max')">Higer then business vintage</mat-error>
</mat-form-field>
<mat-form-field>
<input matInput OnlyNumber type="text" autocomplete="off" placeholder="Month"
<input matInput OnlyNumber type="number" autocomplete="off" placeholder="Month"
formControlName="how_long_month" min='0' (change)="ConvertMonthintoYear($event.target.value)">
<mat-error *ngIf="employmentForm.controls.how_long_month.hasError('max')">Higer then business vintage</mat-error>
</mat-form-field>
<mat-form-field style="width: 22%">
<mat-form-field style="width: 30%">
<input matInput placeholder="Total Work Experience" formControlName="total_business_experience"
OnlyNumber autocomplete="off" (change)="checkWorkingExperiences()">
<!-- <mat-hint style="color: red;" *ngIf="employmentForm.controls['total_business_experience'].value !=undefined && this.workExperienceErrorFlag">
@ -55,7 +55,7 @@
</mat-hint> -->
<mat-error *ngIf="employmentForm.controls.total_business_experience.hasError('min')">Total working Experience is Lower</mat-error>
</mat-form-field>
<mat-form-field style="width: 34%" *ngIf="workExperienceFlag">
<mat-form-field style="width: 100%" *ngIf="workExperienceFlag">
<input matInput placeholder="Previous Work Experience Details" formControlName="total_business_previous_experience">
</mat-form-field>

View File

@ -183,8 +183,8 @@ export class EmploymentInfoComponent implements OnInit {
this.employmentForm = this.fb.group({
employer_name: ['', Validators.compose([Validators.required])],
employer_in_brief: ['', Validators.compose([Validators.required])],
how_long_year: ['', Validators.compose([Validators.required]),Validators.max(this.generalExistBusinessYear)],
how_long_month: [''],
how_long_year: ['',Validators.compose([Validators.required,Validators.max(this.generalExistBusinessYear)])],
how_long_month: ['',Validators.compose([Validators.max(12)])],
total_business_experience: [''],
total_business_previous_experience: [''],
was_met: [this.pd_cus_segment == 'SAL-CHQ' ? 'no' : '', Validators.compose([Validators.required])],
@ -231,15 +231,15 @@ export class EmploymentInfoComponent implements OnInit {
console.log('this.generalExistBusinessMonth',this.generalExistBusinessMonth);
console.log('this.generalExistBusinessYear',this.generalExistBusinessYear);
if(data1.business_month != null && data1.business_month != '' && data1.business_month != undefined){
this.generalExistBusinessMonth = data1.business_month
}
if(data1.business_years){
this.generalExistBusinessYear = data1.business_years
}
this.employmentForm.controls['how_long_year'].setValidators([Validators.max(this.generalExistBusinessYear)]);
this.employmentForm.controls['how_long_year'].setValidators(Validators.compose([Validators.max(this.generalExistBusinessYear)]));
this.employmentForm.controls['how_long_year'].updateValueAndValidity();
}
// ConvertMonthintoYear(e) {
@ -263,24 +263,28 @@ export class EmploymentInfoComponent implements OnInit {
ConvertMonthintoYear(e) {
let how_long_year = this.employmentForm.controls.how_long_year.value;
this.employmentForm.controls['how_long_month'].clearValidators();
let converted_month: number = +e%12;
let converted_year: number = e / 12;
// console.log('e',e%12);
// console.log('e',e);
// console.log('e',e/12);
if (how_long_year > this.generalExistBusinessYear) {
this.employmentForm.controls['how_long_year'].setValidators([Validators.max(this.generalExistBusinessYear)]);
this.employmentForm.controls['how_long_year'].updateValueAndValidity();
this.employmentForm.controls['how_long_year'].setValidators(Validators.compose([Validators.max(this.generalExistBusinessYear)]));
this.employmentForm.controls['how_long_year'].setValue('');
this.employmentForm.controls['how_long_month'].setValue('');
}
else {
if (how_long_year == this.generalExistBusinessYear && +converted_month > this.generalExistBusinessMonth) {
this.employmentForm.controls['how_long_year'].setValidators([Validators.max(this.generalExistBusinessYear)]);
this.employmentForm.controls['how_long_year'].updateValueAndValidity();
this.employmentForm.controls['how_long_year'].setValidators(Validators.compose([Validators.max(this.generalExistBusinessYear)]));
this.employmentForm.controls['how_long_month'].setValidators([Validators.max(this.generalExistBusinessMonth)]);
this.employmentForm.controls['how_long_month'].updateValueAndValidity();
this.employmentForm.controls['how_long_month'].setValidators(Validators.compose([Validators.max(this.generalExistBusinessMonth)]));
} else {
@ -289,6 +293,8 @@ export class EmploymentInfoComponent implements OnInit {
}
}
this.employmentForm.controls['how_long_year'].updateValueAndValidity();
this.employmentForm.controls['how_long_month'].updateValueAndValidity();
}
ValidateNetSalary(){

View File

@ -165,7 +165,7 @@
<input matInput placeholder="Specify Others"
formControlName="earning_if_others_segment">
</mat-form-field>
<mat-form-field style="width:45%;">
<mat-form-field style="width:45%;height: 105px !important;">
<input matInput placeholder="Income Per Month"
formControlName="earning_gross_income_per_month"
OnlyNumber type="text">

View File

@ -35,13 +35,13 @@
<div *ngIf="isDisplay">
<mat-form-field style="width:37%">
<mat-label>Enter year from which financials provided</mat-label>
<input matInput autocomplete="off" placeholder="YYYY eg.2018" formControlName="financial_starting_year"
<input matInput autocomplete="off" placeholder="YYYY eg.2018" formControlName="financial_starting_year" (change)="dynamicalFinYear()"
OnlyNumber type="text" [readonly]="isReadOnly">
<mat-error> Invalid year format</mat-error>
<mat-error *ngIf="financialForm.controls['financial_starting_year'].hasError('minlength')"> Invalid year format</mat-error>
</mat-form-field>
<mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Number of Financial Years"
formControlName="financial_no_of_year" (change)="dynamicalFinYear($event)"
formControlName="financial_no_of_year" (change)="dynamicalFinYear()"
OnlyNumber type="text" [readonly]="isReadOnly">
</mat-form-field>
</div>
@ -56,15 +56,12 @@
<br>
<mat-form-field style="width:30%">
<input matInput autocomplete="off" placeholder="Annual Sale"
formControlName="financial_annual_sale" (change)="calculationForFinanicalStatement()"
OnlyNumber type="text">
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('financial_annual_sale').value != ''">{{"&#8377;"}} {{details.get('financial_annual_sale').value | numberToWords}} Only</mat-hint>
<!-- <input matInput autocomplete="off" placeholder="Annual Sale"
formControlName="financial_annual_sale" (change)="calculationForFinanicalStatement()"
OnlyNumber type="text" (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> -->
OnlyNumber type="text">
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('financial_annual_sale').value != ''">{{"&#8377;"}}
{{details.get('financial_annual_sale').value | numberToWords}}
Only</mat-hint>
</mat-form-field>
<span *ngIf="i != 0">
<mat-form-field style="width:60%">
@ -114,36 +111,30 @@
<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)="calculationForFinanicalStatement()"
OnlyNumber type="text">
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('financial_net_profit').value != ''">{{"&#8377;"}} {{details.get('financial_net_profit').value | numberToWords}} Only</mat-hint>
<!-- <input matInput autocomplete="off" placeholder="Net Profit Amount"
formControlName="financial_net_profit" (change)="calculationForFinanicalStatement()"
OnlyNumber type="text" (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> -->
OnlyNumber type="text">
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('financial_net_profit').value != ''">{{"&#8377;"}}
{{details.get('financial_net_profit').value |
numberToWords}} 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" OnlyNumber type="text"
readonly>
formControlName="financial_margin_of_profit" OnlyNumber
type="text" readonly>
</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)="calculationForFinanicalStatement()"
OnlyNumber type="text">
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('financial_net_loss').value != ''">{{"&#8377;"}} {{details.get('financial_net_loss').value | numberToWords}} Only</mat-hint>
<!-- <input matInput autocomplete="off" placeholder="Net Loss Amount"
<input matInput autocomplete="off" placeholder="Net Loss Amount"
formControlName="financial_net_loss" (change)="calculationForFinanicalStatement()"
OnlyNumber type="text" (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> -->
OnlyNumber type="text">
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('financial_net_loss').value != ''">{{"&#8377;"}}
{{details.get('financial_net_loss').value | numberToWords}}
Only</mat-hint>
</mat-form-field>
<mat-form-field style="width:28%">
<input matInput autocomplete="off" placeholder="Net Loss to Sales in %"
@ -190,13 +181,14 @@
</mat-form-field>
<mat-form-field style="width:45%">
<input matInput autocomplete="off" [ngClass]="details.get('financial_profit_to_sale_variation').value > 0 ? 'greenhighlight' : 'highlight'"
placeholder="Variation of Profit/Loss to Sales % from Previous Year" formControlName="financial_profit_to_sale_variation"
OnlyNumber type="text" readonly>
placeholder="Variation of Profit/Loss to Sales % from Previous Year"
formControlName="financial_profit_to_sale_variation" OnlyNumber
type="text" readonly>
<mat-hint align="start" style="font-size:70%" *ngIf="i != 0 && details.get('financial_profit_to_sale_variation').value != '' ">
<span *ngIf="details.get('financial_profit_to_sale_variation').value == 0">
No difference in Profit/Loss to sales % in FY <i>
{{details.get('financial_year').value}} </i> over
Profit/Loss to sales % in FY <i>
Profit/Loss to sales % in FY <i>
{{financialForm.controls.date_per_financial['controls'][i-1].get('financial_year').value}}
</i>
</span>
@ -204,7 +196,7 @@
class="greenhighlight">
Increase in Profit/Loss to sales % in FY <i>
{{details.get('financial_year').value}} </i> over
Profit/Loss to sales % in FY <i>
Profit/Loss to 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}}
@ -214,7 +206,7 @@
class="highlight">
Decrease in Profit/Loss to sales % in FY <i>
{{details.get('financial_year').value}} </i> over
Profit/Loss to sales % in FY <i>
Profit/Loss to 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('-',
@ -258,9 +250,11 @@
<mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Annual Sales From"
formControlName="estimate_sales_from" (change)="calculateSalesAverage(i, details);"
OnlyNumber type="text">
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('estimate_sales_from').value != ''">{{"&#8377;"}} {{details.get('estimate_sales_from').value | numberToWords}} Only</mat-hint>
formControlName="estimate_sales_from" (change)="calculateSalesAverage(i, details);"
OnlyNumber type="text">
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('estimate_sales_from').value != ''">{{"&#8377;"}}
{{details.get('estimate_sales_from').value | numberToWords}}
Only</mat-hint>
<!-- <input matInput autocomplete="off" placeholder="Annual Sales From"
formControlName="estimate_sales_from" (change)="calculateSalesAverage(i, details);"
@ -271,9 +265,10 @@
<mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Annual Sales To"
formControlName="estimate_sales_to" (change)="confirmAlert(i, details);"
OnlyNumber type="text">
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('estimate_sales_to').value != ''">{{"&#8377;"}} {{details.get('estimate_sales_to').value | numberToWords}} Only</mat-hint>
formControlName="estimate_sales_to" (change)="confirmAlert(i, details);"
OnlyNumber type="text">
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('estimate_sales_to').value != ''">{{"&#8377;"}}
{{details.get('estimate_sales_to').value | numberToWords}} Only</mat-hint>
<!-- <input matInput autocomplete="off" placeholder="Annual Sales To"
formControlName="estimate_sales_to" (change)="confirmAlert(i, details);"
@ -283,8 +278,10 @@
</mat-form-field>
<mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Considered Sales Average"
formControlName="estimate_sales_average" readonly>
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('estimate_sales_average').value != ''">{{"&#8377;"}} {{details.get('estimate_sales_average').value | numberToWords}} Only</mat-hint>
formControlName="estimate_sales_average" readonly>
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('estimate_sales_average').value != ''">{{"&#8377;"}}
{{details.get('estimate_sales_average').value | numberToWords}}
Only</mat-hint>
<!-- <input matInput autocomplete="off" placeholder="Considered Sales Average"
formControlName="estimate_sales_average" readonly>
@ -310,8 +307,8 @@
<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%">
<input matInput autocomplete="off" placeholder="Net Profit % From"
formControlName="estimate_profit_range_from" OnlyNumber type="text"
min='0' max='100' (change)="calculateMarginProfit( i, details);">
formControlName="estimate_profit_range_from" OnlyNumber
type="text" min='0' max='100' (change)="calculateMarginProfit( i, details);">
</mat-form-field>
<mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Net Profit % To"
@ -320,14 +317,16 @@
</mat-form-field>
<mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Net Profit % Considered"
formControlName="estimate_profit_margin_percent" OnlyNumber type="text"
readonly>
formControlName="estimate_profit_margin_percent" OnlyNumber
type="text" 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-form-field>
<mat-form-field style="width:25%">
<input matInput placeholder="Net Profit Amount Considered"
formControlName="estimate_profit_margin" readonly>
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('estimate_profit_margin').value != ''">{{"&#8377;"}} {{details.get('estimate_profit_margin').value | numberToWords}} Only</mat-hint>
formControlName="estimate_profit_margin" readonly>
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('estimate_profit_margin').value != ''">{{"&#8377;"}}
{{details.get('estimate_profit_margin').value |
numberToWords}} Only</mat-hint>
<!-- <input matInput placeholder="Net Profit Amount Considered"
formControlName="estimate_profit_margin" readonly>
@ -339,9 +338,11 @@
<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%">
<input matInput autocomplete="off" placeholder="Net Profit Amount From"
formControlName="estimate_net_profit_from" OnlyNumber type="text"
(change)="calculateProfitAmount(i, details);">
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('estimate_net_profit_from').value != ''">{{"&#8377;"}} {{details.get('estimate_net_profit_from').value | numberToWords}} Only</mat-hint>
formControlName="estimate_net_profit_from" OnlyNumber type="text"
(change)="calculateProfitAmount(i, details);">
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('estimate_net_profit_from').value != ''">{{"&#8377;"}}
{{details.get('estimate_net_profit_from').value |
numberToWords}} Only</mat-hint>
<!-- <input matInput autocomplete="off" placeholder="Net Profit Amount From"
formControlName="estimate_net_profit_from" OnlyNumber type="text"
@ -351,9 +352,11 @@
</mat-form-field>
<mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Net Profit Amount To"
formControlName="estimate_net_profit_to" OnlyNumber type="text"
(change)="calculateProfitAmount(i, details);">
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('estimate_net_profit_to').value != ''">{{"&#8377;"}} {{details.get('estimate_net_profit_to').value | numberToWords}} Only</mat-hint>
formControlName="estimate_net_profit_to" OnlyNumber type="text"
(change)="calculateProfitAmount(i, details);">
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('estimate_net_profit_to').value != ''">{{"&#8377;"}}
{{details.get('estimate_net_profit_to').value |
numberToWords}} Only</mat-hint>
<!-- <input matInput autocomplete="off" placeholder="Net Profit Amount To"
formControlName="estimate_net_profit_to" OnlyNumber type="text"
@ -367,8 +370,10 @@
</mat-form-field>
<mat-form-field style="width:25%">
<input matInput placeholder="Considered Profit Amount"
formControlName="estimate_net_profit" readonly>
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('estimate_net_profit').value != ''">{{"&#8377;"}} {{details.get('estimate_net_profit').value | numberToWords}} Only</mat-hint>
formControlName="estimate_net_profit" readonly>
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('estimate_net_profit').value != ''">{{"&#8377;"}}
{{details.get('estimate_net_profit').value |
numberToWords}} Only</mat-hint>
<!-- <input matInput autocomplete="off" placeholder="Considered Profit Amount"
formControlName="estimate_net_profit" OnlyNumber type="text"
@ -390,13 +395,15 @@
</mat-form-field>
<mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Net Loss % Considered"
formControlName="estimate_loss_margin_percent" OnlyNumber type="text"
readonly>
formControlName="estimate_loss_margin_percent" OnlyNumber
type="text" readonly>
</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:90%" *ngIf="details.get('estimate_loss_margin').value != ''">{{"&#8377;"}} {{details.get('estimate_loss_margin').value | numberToWords}} Only</mat-hint>
formControlName="estimate_loss_margin" readonly>
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('estimate_loss_margin').value != ''">{{"&#8377;"}}
{{details.get('estimate_loss_margin').value |
numberToWords}} Only</mat-hint>
<!-- <input matInput placeholder="Net Loss Amount Considered"
formControlName="estimate_loss_margin" readonly>
@ -406,38 +413,39 @@
</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" OnlyNumber type="text"
(change)="calculateLossAmount(i, details);">
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('financial_annual_sale').value != ''">{{"&#8377;"}} {{details.get('financial_annual_sale').value | numberToWords}} Only</mat-hint>
<input matInput autocomplete="off" placeholder="Net Loss Amount From"
formControlName="estimate_net_loss_from" OnlyNumber type="text"
(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>
(change)="calculateLossAmount(i, details);">
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('financial_annual_sale').value != ''">{{"&#8377;"}}
{{details.get('financial_annual_sale').value |
numberToWords}} Only</mat-hint>
</mat-form-field>
<mat-form-field style="width:25%">
<input matInput autocomplete="off" placeholder="Annual Sale"
formControlName="financial_annual_sale" (change)="calculationForFinanicalStatement()"
OnlyNumber type="text">
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('estimate_net_loss_to').value != ''">{{"&#8377;"}} {{details.get('estimate_net_loss_to').value | numberToWords}} Only</mat-hint>
<!-- <input matInput autocomplete="off" placeholder="Net Loss Amount To"
formControlName="estimate_net_loss_to" OnlyNumber type="text"
(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 style="width:25%">
<input matInput autocomplete="off" placeholder="Net Loss Amount To"
formControlName="estimate_net_loss_from" OnlyNumber type="text"
(change)="calculateLossAmount(i, details);">
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('estimate_net_loss_to').value != ''">{{"&#8377;"}}
{{details.get('estimate_net_loss_to').value |
numberToWords}} Only</mat-hint>
</mat-form-field>
<!-- <mat-form-field style="width:25%">
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('estimate_net_loss_to').value != ''">{{"&#8377;"}}
{{details.get('estimate_net_loss_to').value |
numberToWords}} 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" OnlyNumber type="text">
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('estimate_net_loss').value != ''">{{"&#8377;"}} {{details.get('estimate_net_loss').value | numberToWords}} Only</mat-hint>
formControlName="estimate_net_loss" OnlyNumber type="text">
<mat-hint align="start" style="font-size:90%" *ngIf="details.get('estimate_net_loss').value != ''">{{"&#8377;"}}
{{details.get('estimate_net_loss').value | numberToWords}}
Only</mat-hint>
<!-- <input matInput autocomplete="off" placeholder="Considered Loss Amount"
formControlName="estimate_net_loss" OnlyNumber type="text" readonly>
<mat-hint align="start" style="font-size:70%" *ngIf="details.get('estimate_net_loss').value != ''">{{"&#8377;"}}

View File

@ -48,6 +48,7 @@
mat-form-field {
margin: 0 2%;
height: 105px !important;
}
$base-card-box-shadow:1.5px 2.6px 24px 0 rgba(0, 35, 136, 0.08) !important;
$product-bg-color-hover: rgba(103, 58, 183, 0.7);

View File

@ -357,28 +357,32 @@ export class FinancialInfoComponent implements OnInit {
}
/** For Auto-generating FinYear */
dynamicalFinYear($event){
dynamicalFinYear(){
let e = $event.target.value;
if(e == 1){
this.customerCommentsFlag = false;
}
else{
this.customerCommentsFlag = true;
}
let no_of_year = this.financialForm.controls['financial_no_of_year'].value
let startingYear = this.financialForm.controls['financial_starting_year'].value;
if(no_of_year != null && no_of_year != ''){
const control = <FormArray>this.financialForm.controls['date_per_financial'];
if(no_of_year == 1){
this.customerCommentsFlag = false;
}
else{
this.customerCommentsFlag = true;
}
while (control.length !== 0) {
control.removeAt(0);
}
let startingYear = this.financialForm.controls['financial_starting_year'].value;
if(e > 0 ){
for(let i = 1 ; i<= e ; i++ ){
let Year = (+startingYear+(i-1)) +'-'+ ((+startingYear)+(+i));
control.push(this.createDate(Year));
const control = <FormArray>this.financialForm.controls['date_per_financial'];
while (control.length !== 0) {
control.removeAt(0);
}
if(no_of_year > 0 ){
for(let i = 1 ; i<= no_of_year ; i++ ){
let Year = (+startingYear+(i-1)) +'-'+ ((+startingYear)+(+i));
control.push(this.createDate(Year));
}
}
}
}

View File

@ -37,7 +37,7 @@
</mat-form-field>
<mat-form-field style="width:30%">
<mat-select placeholder="Stock" formControlName="stock_observed"
(selectionChange)="checkComments($event.value,1,a)">
(selectionChange)="checkComments($event.value,1,a);">
<mat-option>Select</mat-option>
<mat-option value="yes">Add Stock Details</mat-option>
<mat-option value="no">No Stock Observed</mat-option>
@ -124,7 +124,7 @@
</mat-form-field>
<mat-form-field style="width:30%">
<mat-select placeholder="Stock" formControlName="goods_observed"
(selectionChange)="checkComments($event.value,2,b)">
(selectionChange)="checkComments($event.value,2,b);">
<mat-option>Select</mat-option>
<mat-option value="yes">Add Stock Details</mat-option>
<mat-option value="no">No Stock Observed</mat-option>