issues fixes : ps

This commit is contained in:
venbatechnologies@gmail.com 2018-12-24 12:53:33 +05:30
parent 34a3b0da66
commit a6542e9027
8 changed files with 257 additions and 242 deletions

View File

@ -42,7 +42,7 @@
<div [formGroupName]="s">
<div>
<mat-form-field style="width:100%">
<mat-select placeholder="Property Type" formControlName="property_type" required>
<mat-select placeholder="Property Type" formControlName="property_type" >
<mat-option *ngFor="let prop of m_propertyType" [value]="prop.id">{{ prop.name }}</mat-option>
</mat-select>
</mat-form-field>
@ -63,7 +63,7 @@
<div [formGroupName]="s">
<div>
<mat-form-field class="ml-xs example-full-width">
<input matInput placeholder="Manufacturer, Model" formControlName="manufacturer_model_four_weeler" required autocomplete="off">
<input matInput placeholder="Manufacturer, Model" formControlName="manufacturer_model_four_weeler" autocomplete="off">
</mat-form-field>
</div>
</div>
@ -77,7 +77,7 @@
<div [formGroupName]="s">
<div>
<mat-form-field class="ml-xs example-full-width">
<input matInput placeholder="Manufacturer, Model" formControlName="manufacturer_model_two_weeler" required autocomplete="off">
<input matInput placeholder="Manufacturer, Model" formControlName="manufacturer_model_two_weeler" autocomplete="off">
</mat-form-field>
</div>
</div>
@ -91,7 +91,7 @@
<div [formGroupName]="s">
<div>
<mat-form-field class="ml-xs example-full-width">
<input matInput placeholder="Description" formControlName="consumer_durable_description" required>
<input matInput placeholder="Description" formControlName="consumer_durable_description" >
</mat-form-field>
</div>
</div>
@ -106,26 +106,26 @@
<div fxLayout="row wrap" fxLayoutGap="2px" fxLayoutAlign="start none">
<div fxFlex="33">
<mat-form-field class="ml-xs example-full-width">
<input matInput placeholder="Premium Paid" formControlName="premium_paid" required (keypress)="keyPress($event)" autocomplete="off">
<input matInput placeholder="Premium Paid" formControlName="premium_paid" (keypress)="keyPress($event)" autocomplete="off">
</mat-form-field>
</div>
<div fxFlex="33">
<mat-form-field>
<mat-select placeholder="Frequency" formControlName="frequency_mode" required>
<mat-select placeholder="Frequency" formControlName="frequency_mode" >
<mat-option *ngFor="let freqn of m_freqOfPurchase" [value]="freqn.frequency_id">{{ freqn.name }}</mat-option>
</mat-select>
</mat-form-field>
</div>
<div fxFlex="33">
<mat-form-field class="ml-xs example-full-width">
<input matInput placeholder="Sum Assured" formControlName="sum_assured" required (keypress)="keyPress($event)" autocomplete="off">
<input matInput placeholder="Sum Assured" formControlName="sum_assured" (keypress)="keyPress($event)" autocomplete="off">
</mat-form-field>
</div>
</div>
<div fxLayout="row wrap" fxLayoutGap="2px" fxLayoutAlign="start none">
<div fxFlex="33">
<mat-form-field class="ml-xs example-full-width">
<input matInput placeholder="Members Covered" formControlName="members_coverd" required autocomplete="off">
<input matInput placeholder="Members Covered" formControlName="members_coverd" autocomplete="off">
</mat-form-field>
</div>
</div>
@ -141,7 +141,7 @@
<div fxLayout="row wrap" fxLayoutGap="2px" fxLayoutAlign="start none">
<div fxFlex="33">
<mat-form-field>
<mat-select placeholder="Type" formControlName="investments_type" required>
<mat-select placeholder="Type" formControlName="investments_type" >
<mat-option *ngFor="let ins_type of m_investmentType" [value]="ins_type.id">{{ ins_type.name }}</mat-option>
</mat-select>
</mat-form-field>
@ -153,12 +153,12 @@
</div>
<div fxFlex="33" >
<mat-form-field class="ml-xs example-full-width">
<input matInput placeholder="Amount of Investment" formControlName="amount_of_invest" required (keypress)="keyPress($event)" autocomplete="off">
<input matInput placeholder="Amount of Investment" formControlName="amount_of_invest" (keypress)="keyPress($event)" autocomplete="off">
</mat-form-field>
</div>
<div fxFlex="33">
<mat-form-field class="ml-xs example-full-width">
<input matInput placeholder="Bank Name" formControlName="bank_name" required autocomplete="off">
<input matInput placeholder="Bank Name" formControlName="bank_name" autocomplete="off">
</mat-form-field>
</div>
</div>
@ -174,16 +174,16 @@
<div [formGroupName]="s">
<div>
<mat-form-field class="ml-xs example-full-width">
<input matInput placeholder="Description of the Assets" formControlName="any_other_assets" required autocomplete="off">
<input matInput placeholder="Description of the Assets" formControlName="any_other_assets" autocomplete="off">
</mat-form-field>
<mat-form-field class="ml-xs example-full-width">
<input matInput placeholder="Value of the Assets" formControlName="any_other_asset_value" required autocomplete="off">
<input matInput placeholder="Value of the Assets" formControlName="any_other_asset_value" autocomplete="off">
</mat-form-field>
<!-- <mat-form-field class="ml-xs example-full-width"> -->
<!-- <input matInput placeholder="Is Any Loan" formControlName="any_other_asset_loan" required> -->
<!-- <input matInput placeholder="Is Any Loan" formControlName="any_other_asset_loan" > -->
<!-- </mat-form-field> -->
<mat-form-field class="ml-xs example-full-width">
<mat-select placeholder="Is there any asset loan?" formControlName="any_other_asset_loan" required>
<mat-select placeholder="Is there any asset loan?" formControlName="any_other_asset_loan" >
<mat-option value="yes">Yes</mat-option>
<mat-option value="no">No</mat-option>
<mat-option value="nan">NA</mat-option>
@ -215,7 +215,7 @@
<div fxFlex="33">
<mat-form-field class="ml-xs example-full-width">
<input matInput placeholder="Name of the Owner" formControlName="business_name_of_the_owner" autocomplete="off">
<input matInput placeholder="Name of the Business Owner" formControlName="business_name_of_the_owner" autocomplete="off">
</mat-form-field>
</div>
@ -223,7 +223,7 @@
<mat-form-field class="ml-xs example-full-width">
<mat-select placeholder="Name of the Owner"
formControlName="business_name_of_the_owner" required>
formControlName="business_name_of_the_owner" >
<mat-option value="{{owner.pd_co_applicant_id}}" *ngFor="let owner of applicants">{{owner.applicant_name}}</mat-option>
@ -238,7 +238,7 @@
</div>
<div fxFlex="33">
<mat-form-field class="ml-xs example-full-width">
<mat-select placeholder="Relation" formControlName="relation" required>
<mat-select placeholder="Relation" formControlName="relation" >
<mat-option value="{{relations.relationship_id}}"
*ngFor="let relations of m_relation">
{{relations.name}}
@ -343,7 +343,7 @@
<div [formGroupName]="s">
<div>
<mat-form-field style="width:100%">
<mat-select placeholder="Property Type" formControlName="property_type" required>
<mat-select placeholder="Property Type" formControlName="property_type" >
<mat-option *ngFor="let prop of m_propertyType" [value]="prop.id">{{ prop.name }}</mat-option>
</mat-select>
</mat-form-field>
@ -364,7 +364,7 @@
<div [formGroupName]="s">
<div>
<mat-form-field class="ml-xs example-full-width">
<input matInput placeholder="Manufacturer, Model" formControlName="manufacturer_model_four_weeler" required autocomplete="off">
<input matInput placeholder="Manufacturer, Model" formControlName="manufacturer_model_four_weeler" autocomplete="off">
</mat-form-field>
</div>
</div>
@ -378,7 +378,7 @@
<div [formGroupName]="s">
<div>
<mat-form-field class="ml-xs example-full-width">
<input matInput placeholder="Manufacturer, Model" formControlName="manufacturer_model_two_weeler" required autocomplete="off">
<input matInput placeholder="Manufacturer, Model" formControlName="manufacturer_model_two_weeler" autocomplete="off">
</mat-form-field>
</div>
</div>
@ -406,7 +406,7 @@
<div [formGroupName]="s">
<div>
<mat-form-field class="ml-xs example-full-width">
<input matInput placeholder="Description" formControlName="consumer_durable_description" required>
<input matInput placeholder="Description" formControlName="consumer_durable_description" >
</mat-form-field>
</div>
</div>
@ -421,33 +421,33 @@
<div fxLayout="row wrap" fxLayoutGap="2px" fxLayoutAlign="start none">
<!---- <div fxFlex="33">
<mat-form-field>
<mat-select placeholder="Type" formControlName="insurance_type" required>
<mat-select placeholder="Type" formControlName="insurance_type" >
<mat-option *ngFor="let ins_type of m_insuranceType" [value]="ins_type.id">{{ ins_type.name }}</mat-option>
</mat-select>
</mat-form-field>
</div>-->
<div fxFlex="33">
<mat-form-field class="ml-xs example-full-width">
<input matInput placeholder="Premium Paid" formControlName="premium_paid" required (keypress)="keyPress($event)" autocomplete="off">
<input matInput placeholder="Premium Paid" formControlName="premium_paid" (keypress)="keyPress($event)" autocomplete="off">
</mat-form-field>
</div>
<div fxFlex="33">
<mat-form-field>
<mat-select placeholder="Frequency" formControlName="frequency_mode" required>
<mat-select placeholder="Frequency" formControlName="frequency_mode" >
<mat-option *ngFor="let freqn of m_freqOfPurchase" [value]="freqn.frequency_id">{{ freqn.name }}</mat-option>
</mat-select>
</mat-form-field>
</div>
<div fxFlex="33">
<mat-form-field class="ml-xs example-full-width">
<input matInput placeholder="Sum Assured" formControlName="sum_assured" required (keypress)="keyPress($event)" autocomplete="off">
<input matInput placeholder="Sum Assured" formControlName="sum_assured" (keypress)="keyPress($event)" autocomplete="off">
</mat-form-field>
</div>
</div>
<div fxLayout="row wrap" fxLayoutGap="2px" fxLayoutAlign="start none">
<div fxFlex="33">
<mat-form-field class="ml-xs example-full-width">
<input matInput placeholder="Members Covered" formControlName="members_coverd" required autocomplete="off">
<input matInput placeholder="Members Covered" formControlName="members_coverd" autocomplete="off">
</mat-form-field>
</div>
</div>
@ -463,7 +463,7 @@
<div fxLayout="row wrap" fxLayoutGap="2px" fxLayoutAlign="start none">
<div fxFlex="33%" class="ml-xs example-full-width">
<mat-form-field>
<mat-select placeholder="Type" formControlName="investments_type" required>
<mat-select placeholder="Type" formControlName="investments_type" >
<mat-option *ngFor="let ins_type of m_investmentType" [value]="ins_type.id">{{ ins_type.name }}</mat-option>
</mat-select>
</mat-form-field>
@ -477,14 +477,14 @@
<!-- </div> -->
<div fxFlex="33%" >
<mat-form-field class="ml-xs example-full-width">
<input matInput placeholder="Amount of Investment" formControlName="amount_of_invest" required (keypress)="keyPress($event)" autocomplete="off">
<input matInput placeholder="Amount of Investment" formControlName="amount_of_invest" (keypress)="keyPress($event)" autocomplete="off">
</mat-form-field>
</div>
</div>
<div fxLayout="row wrap" fxLayoutGap="2px" fxLayoutAlign="start none">
<div fxFlex="33%">
<mat-form-field class="ml-xs example-full-width">
<input matInput placeholder="Bank Name" formControlName="bank_name" required autocomplete="off">
<input matInput placeholder="Bank Name" formControlName="bank_name" autocomplete="off">
</mat-form-field>
</div>
</div>
@ -499,14 +499,14 @@
<div [formGroupName]="s">
<div>
<mat-form-field class="ml-xs example-full-width">
<input matInput placeholder="Description of the Assets" formControlName="any_other_assets" required autocomplete="off">
<input matInput placeholder="Description of the Assets" formControlName="any_other_assets" autocomplete="off">
</mat-form-field>
<mat-form-field class="ml-xs example-full-width">
<input matInput placeholder="Value of the Assets" formControlName="any_other_asset_value" required autocomplete="off">
<input matInput placeholder="Value of the Assets" formControlName="any_other_asset_value" autocomplete="off">
</mat-form-field>
<mat-form-field class="ml-xs example-full-width">
<mat-select placeholder="Name of the Owner"
formControlName="name_of_the_owner" required>
formControlName="name_of_the_owner" >
<mat-option value="{{owner.pd_co_applicant_id}}" *ngFor="let owner of applicants">{{owner.applicant_name}}</mat-option>
@ -520,7 +520,7 @@
</div>
<div>
<mat-form-field class="ml-xs example-full-width">
<mat-select placeholder="Relation" formControlName="relation" required>
<mat-select placeholder="Relation" formControlName="relation" >
<mat-option value="{{relations.relationship_id}}"
*ngFor="let relations of m_relation">
{{relations.name}}
@ -529,10 +529,10 @@
</mat-form-field>
</div>
<!-- <mat-form-field class="ml-xs example-full-width"> -->
<!-- <input matInput placeholder="Is Any Loan" formControlName="any_other_asset_loan" required> -->
<!-- <input matInput placeholder="Is Any Loan" formControlName="any_other_asset_loan" > -->
<!-- </mat-form-field> -->
<mat-form-field class="ml-xs example-full-width">
<mat-select placeholder="Is there any asset loan?" formControlName="any_other_asset_loan" required>
<mat-select placeholder="Is there any asset loan?" formControlName="any_other_asset_loan" >
<mat-option value="yes">Yes</mat-option>
<mat-option value="no">No</mat-option>
<mat-option value="nan">NA</mat-option>
@ -569,7 +569,7 @@
<div fxFlex="33">
<mat-form-field class="ml-xs example-full-width">
<mat-select placeholder="Name of the Owner"
formControlName="name_of_the_owner" required>
formControlName="name_of_the_owner" >
<mat-option value="{{owner.pd_co_applicant_id}}" *ngFor="let owner of applicants">{{owner.applicant_name}}</mat-option>
@ -584,7 +584,7 @@
</div>
<div fxFlex="33">
<mat-form-field class="ml-xs example-full-width">
<mat-select placeholder="Relation" formControlName="relation" required>
<mat-select placeholder="Relation" formControlName="relation" >
<mat-option value="{{relations.relationship_id}}"
*ngFor="let relations of m_relation">
{{relations.name}}

View File

@ -345,14 +345,14 @@ public m_investmentType = [];
// Dynamic Form field creation Functionality : START ===>
initDetails() {
return this._formBuilder.group({
assets_mode: ['', Validators.compose([Validators.required])],
assets_mode: [''],
details: this._formBuilder.array([]),
approximate_market_value: ['', Validators.compose([])],
name_of_the_owner: ['', Validators.compose([])],
approximate_market_value: [''],
name_of_the_owner: [''],
other_owner:[''],
relation: [''],
// purchase_year: ['', Validators.compose([])],
//purchase_month: ['', Validators.compose([])],
// purchase_year: [''],
//purchase_month: [''],
emi: [''],
emi_paid: [''],
original_loan_tenure: [''],
@ -363,14 +363,14 @@ public m_investmentType = [];
initBusinessDetails(data) {
return this._formBuilder.group({
business_assets_mode: ['', Validators.compose([Validators.required])],
business_assets_mode: [''],
business_details: this._formBuilder.array([]),
business_approximate_market_value: ['', Validators.compose([])],
business_approximate_market_value: [''],
business_name_of_the_owner: [data],
// other_owner:[''],
// relation:[''],
// purchase_year: ['', Validators.compose([])],
//purchase_month: ['', Validators.compose([])],
// purchase_year: [''],
//purchase_month: [''],
business_emi: [''],
business_emi_paid: [''],
business_original_loan_tenure: [''],
@ -458,26 +458,26 @@ public m_investmentType = [];
loadProperty() {
return this._formBuilder.group({
property_type: ['', Validators.compose([Validators.required])],
property_type: [''],
other_property_type: ['']
});
}
loadJwellDescription() {
return this._formBuilder.group({
jwell_description: ['', Validators.compose([])]
jwell_description: ['']
});
}
loadConsumerDurableDescription() {
return this._formBuilder.group({
consumer_durable_description: ['', Validators.compose([Validators.required])]
consumer_durable_description: ['']
});
}
otherAssetsDescription() {
return this._formBuilder.group({
any_other_assets: ['', Validators.compose([Validators.required])],
any_other_assets: [''],
name_of_the_owner:[''],
other_owner:[''],
relation:[''],
@ -490,7 +490,7 @@ public m_investmentType = [];
otherBusinessAssetsDescription() {
return this._formBuilder.group({
any_other_assets: ['', Validators.compose([Validators.required])],
any_other_assets: [''],
any_other_asset_value : [''],
any_other_asset_loan : [''],
other_asset_emi_amt : ['']
@ -500,32 +500,32 @@ public m_investmentType = [];
loadInsuranceDescription() {
return this._formBuilder.group({
//insurance_type: ['', Validators.compose([Validators.required])],
premium_paid: ['', Validators.compose([])],
frequency_mode: ['', Validators.compose([])],
sum_assured: ['', Validators.compose([])],
members_coverd: ['', Validators.compose([])]
//insurance_type: [''],
premium_paid: [''],
frequency_mode: [''],
sum_assured: [''],
members_coverd: ['']
});
}
loadInvestDescription() {
return this._formBuilder.group({
investments_type: ['', Validators.compose([])],
investments_type: [''],
other_investments_type:[''],
amount_of_invest: ['', Validators.compose([])],
bank_name: ['', Validators.compose([])]
amount_of_invest: [''],
bank_name: ['']
});
}
load_Four_Weeler() {
return this._formBuilder.group({
manufacturer_model_four_weeler: ['', Validators.compose([])]
manufacturer_model_four_weeler: ['']
});
}
load_Two_Weeler() {
return this._formBuilder.group({
manufacturer_model_two_weeler: ['', Validators.compose([Validators.required])]
manufacturer_model_two_weeler: ['']
});
}
@ -533,26 +533,26 @@ public m_investmentType = [];
loadPropertyWithData(data) {
return this._formBuilder.group({
property_type: [data.property_type, Validators.compose([Validators.required])]
property_type: [data.property_type]
//property_type:['']
});
}
loadJwellDescriptionWithData(data) {
return this._formBuilder.group({
jwell_description: [data.jwell_description, Validators.compose([Validators.required])]
jwell_description: [data.jwell_description]
});
}
loadConsumerDurableDescriptionWithData(data) {
return this._formBuilder.group({
consumer_durable_description: [data.consumer_durable_description, Validators.compose([Validators.required])]
consumer_durable_description: [data.consumer_durable_description]
});
}
otherAssetsDescriptionWithData(data) {
return this._formBuilder.group({
any_other_assets: [data.any_other_assets, Validators.compose([Validators.required])],
any_other_assets: [data.any_other_assets],
name_of_the_owner:[data.name_of_the_owner],
other_owner:[data.other_owner],
relation:[data.relation],
@ -564,7 +564,7 @@ public m_investmentType = [];
otherBusinessAssetsDescriptionWithData(data) {
return this._formBuilder.group({
any_other_assets: [data.any_other_assets, Validators.compose([Validators.required])],
any_other_assets: [data.any_other_assets],
any_other_asset_value : [data.any_other_asset_value],
any_other_asset_loan : [data.any_other_asset_loan],
other_asset_emi_amt : [data.other_asset_emi_amt]
@ -575,32 +575,32 @@ public m_investmentType = [];
loadInsuranceDescriptionWithData(data) {
return this._formBuilder.group({
//insurance_type: [data.insurance_type, Validators.compose([Validators.required])],
premium_paid: [data.premium_paid, Validators.compose([Validators.required])],
frequency_mode: [data.frequency_mode, Validators.compose([Validators.required])],
sum_assured: [data.sum_assured, Validators.compose([Validators.required])],
members_coverd: [data.members_coverd, Validators.compose([Validators.required])]
//insurance_type: [data.insurance_type],
premium_paid: [data.premium_paid],
frequency_mode: [data.frequency_mode],
sum_assured: [data.sum_assured],
members_coverd: [data.members_coverd]
});
}
loadInvestDescriptionWithData(data) {
return this._formBuilder.group({
investments_type: [data.investments_type, Validators.compose([Validators.required])],
investments_type: [data.investments_type],
other_investments_type : [data.other_investments_type],
amount_of_invest: [data.amount_of_invest, Validators.compose([Validators.required])],
bank_name: [data.bank_name, Validators.compose([Validators.required])]
amount_of_invest: [data.amount_of_invest],
bank_name: [data.bank_name]
});
}
load_Four_WeelerWithData(data) {
return this._formBuilder.group({
manufacturer_model_four_weeler: [data.manufacturer_model_four_weeler, Validators.compose([Validators.required])]
manufacturer_model_four_weeler: [data.manufacturer_model_four_weeler]
});
}
load_Two_WeelerWithData(data) {
return this._formBuilder.group({
manufacturer_model_two_weeler: [data.manufacturer_model_two_weeler, Validators.compose([Validators.required])]
manufacturer_model_two_weeler: [data.manufacturer_model_two_weeler]
});
}
@ -608,14 +608,14 @@ public m_investmentType = [];
initDetailsWithdata(data) {
return this._formBuilder.group({
assets_mode: [data.assets_mode, Validators.compose([Validators.required])],
assets_mode: [data.assets_mode],
details: this._formBuilder.array([]),
approximate_market_value: [data.approximate_market_value, Validators.compose([])],
name_of_the_owner: [data.name_of_the_owner, Validators.compose([])],
approximate_market_value: [data.approximate_market_value],
name_of_the_owner: [data.name_of_the_owner],
other_owner:[data.other_owner || ''],
relation: [data.relation || ''],
// purchase_year: [data.purchase_year, Validators.compose([])],
// purchase_month: [data.purchase_month, Validators.compose([])],
// purchase_year: [data.purchase_year],
// purchase_month: [data.purchase_month],
emi: [data.emi || 0],
emi_paid: [data.emi_paid || ''],
original_loan_tenure: [data.original_loan_tenure || ''],
@ -625,14 +625,14 @@ public m_investmentType = [];
}
initBusinessDetailsWithdata(data) {
return this._formBuilder.group({
business_assets_mode: [data.business_assets_mode, Validators.compose([Validators.required])],
business_assets_mode: [data.business_assets_mode],
business_details: this._formBuilder.array([]),
business_approximate_market_value: [data.business_approximate_market_value, Validators.compose([])],
business_name_of_the_owner: [data.business_name_of_the_owner, Validators.compose([])],
business_approximate_market_value: [data.business_approximate_market_value],
business_name_of_the_owner: [data.business_name_of_the_owner],
// other_owner:[data.other_owner || ''],
// relation: [data.relation || ''],
// purchase_year: [data.purchase_year, Validators.compose([])],
// purchase_month: [data.purchase_month, Validators.compose([])],
// purchase_year: [data.purchase_year],
// purchase_month: [data.purchase_month],
business_emi: [data.business_emi || 0],
business_emi_paid: [data.business_emi_paid || ''],
business_original_loan_tenure: [data.business_original_loan_tenure || ''],

View File

@ -22,7 +22,7 @@
<mat-card-content>
<mat-form-field style="width:60% !important;">
<mat-select (selectionChange)="selectedLoanChanges($event)" placeholder="Do you have any other existing loan"
formControlName="existing_loan" required>
formControlName="existing_loan" >
<mat-option value="Yes">Yes</mat-option>
<mat-option value="No">No</mat-option>
</mat-select>
@ -38,45 +38,51 @@
<!-- {{frequencyData | json}} -->
<mat-card-content class="matcard">
<mat-form-field>
<input matInput placeholder="Loan Amount" formControlName="loan_amount" (keypress)="keyPress($event)" required>
<input matInput autocomplete="off" placeholder="Loan Amount" formControlName="loan_amount" (keypress)="keyPress($event)" >
</mat-form-field>
<mat-form-field>
<mat-select (selectionChange)="selectedfrequency($event.value,i)" placeholder="Frequency"
formControlName="frequency" required>
formControlName="frequency" >
<mat-option *ngFor="let freq of frequencyData" value="{{freq.frequency_id}}">{{freq.name}}</mat-option>
</mat-select>
</mat-form-field>
<mat-form-field *ngIf="details.get('frequency').value != ''" >
<input matInput [placeholder]="placeholderName[i] != '' ? placeholderName[i] : 'Instalment Amount' " formControlName="emi" (keypress)="keyPress($event)" required>
<input matInput autocomplete="off" [placeholder]="placeholderName[i] != '' ? placeholderName[i] : 'Instalment Amount' " formControlName="emi" (keypress)="keyPress($event)" >
</mat-form-field>
<mat-form-field>
<input matInput placeholder="Loan Type" formControlName="loan_type" required>
<mat-select placeholder="Loan Type" formControlName="loan_type" >
<mat-option value="{{types.existing_loan_type_id}}" *ngFor="let types of loanTypeData">{{types.loan_type_name}}</mat-option>
</mat-select>
<!-- <input matInput autocomplete="off" placeholder="Loan Type" formControlName="loan_type" > -->
</mat-form-field>
<mat-form-field *ngIf="details.get('loan_type').value == 9 ">
<input matInput autocomplete="off" placeholder="Specify Others Loan Type" formControlName="others_loan_type">
</mat-form-field>
<mat-form-field>
<mat-select placeholder="Loan Taken By" formControlName="loan_taken_by" required>
<mat-select placeholder="Loan Taken By" formControlName="loan_taken_by">
<mat-option value="{{owner.pd_co_applicant_id}}" *ngFor="let owner of applicants">{{owner.applicant_name}}</mat-option>
<mat-option value="Others">Others</mat-option>
<!-- <mat-option value= 0 >Others</mat-option> -->
</mat-select>
</mat-form-field>
<mat-form-field *ngIf="details.get('loan_taken_by').value == 'Others'">
<input matInput placeholder="Specify Others Loan Taken" formControlName="others_loan_taken">
<mat-form-field *ngIf="details.get('loan_taken_by').value == 0">
<input matInput autocomplete="off" placeholder="Specify Others Loan Taken" formControlName="others_loan_taken">
</mat-form-field>
<mat-form-field>
<mat-select placeholder="Lender" formControlName="lender" required>
<mat-select placeholder="Lender" formControlName="lender" >
<mat-option *ngFor="let btLen of lenderData" [value]="btLen.bt_lender_list_id">{{ btLen.lender_name }}</mat-option>
</mat-select>
</mat-form-field>
<mat-form-field *ngIf="details.get('lender').value == 3">
<input matInput placeholder="Specify Others Loan Taken" formControlName="others_loan_taken">
<input matInput autocomplete="off" placeholder="Specify Others Lender" formControlName="others_lender" >
</mat-form-field>
<!-- <mat-form-field>
<input matInput placeholder="Lender" formControlName="lender" required>
<input matInput autocomplete="off" placeholder="Lender" formControlName="lender" >
</mat-form-field> -->
<mat-form-field>
<input matInput placeholder="Original Tenure in Months" formControlName="original_tenure" required>
<input matInput autocomplete="off" placeholder="Original Tenure in Months" formControlName="original_tenure" >
</mat-form-field>
<mat-form-field>
<input matInput placeholder="Current Balance Tenure in Months" formControlName="current_balance_tenure" required>
<input matInput autocomplete="off" placeholder="Current Balance Tenure in Months" formControlName="current_balance_tenure" >
</mat-form-field>
<button type="button" class="mr-1 mb-1 hover-icon" mat-raised-button mat-icon-button matTooltip="Add More Loan Details" matTooltipPosition="above" color="primary" (click)="addLoanDetails()"
*ngIf="i==0">
@ -210,7 +216,7 @@
<div fxFlex="60" class="pb-0 text-sm-left" align="left">
<mat-form-field appearance="outline" style="width: 100%">
<mat-label>Remarks</mat-label>
<textarea matInput placeholder="Remarks" formControlName="currentloan_remarks" required></textarea>
<textarea matInput autocomplete="off" placeholder="Remarks" formControlName="currentloan_remarks" ></textarea>
</mat-form-field>
</div>
<div fxFlex="40" align="end">
@ -231,7 +237,7 @@
<div fxFlex="60" class="pb-0 text-sm-left"> -->
<!-- <mat-form-field style="width:60% !important;">
<mat-select (selectionChange)="selectedLoanChanges($event)" placeholder="Do you have any other existing loan"
formControlName="existing_loan" required>
formControlName="existing_loan" >
<mat-option value="Yes">Yes</mat-option>
<mat-option value="No">No</mat-option>
</mat-select>
@ -250,45 +256,45 @@
<!-- {{frequencyData | json}} -->
<!-- <mat-card-content class="matcard">
<mat-form-field>
<input matInput placeholder="Loan Amount" formControlName="loan_amount" (keypress)="keyPress($event)" required>
<input matInput autocomplete="off" placeholder="Loan Amount" formControlName="loan_amount" (keypress)="keyPress($event)" >
</mat-form-field>
<mat-form-field>
<mat-select (selectionChange)="selectedfrequency($event.value,i)" placeholder="Frequency"
formControlName="frequency" required>
formControlName="frequency" >
<mat-option *ngFor="let freq of frequencyData" value="{{freq.frequency_id}}">{{freq.name}}</mat-option>
</mat-select>
</mat-form-field>
<mat-form-field>
<input matInput [placeholder]="placeholderName[i] != '' ? placeholderName[i] : 'Instalment Amount' " formControlName="emi" (keypress)="keyPress($event)" required>
<input matInput autocomplete="off" [placeholder]="placeholderName[i] != '' ? placeholderName[i] : 'Instalment Amount' " formControlName="emi" (keypress)="keyPress($event)" >
</mat-form-field>
<mat-form-field>
<input matInput placeholder="Loan Type" formControlName="loan_type" required>
<input matInput autocomplete="off" placeholder="Loan Type" formControlName="loan_type" >
</mat-form-field>
<mat-form-field>
<mat-select placeholder="Loan Taken By" formControlName="loan_taken_by" required>
<mat-select placeholder="Loan Taken By" formControlName="loan_taken_by" >
<mat-option value="{{owner.pd_co_applicant_id}}" *ngFor="let owner of applicants">{{owner.applicant_name}}</mat-option>
<mat-option value="Others">Others</mat-option>
</mat-select>
</mat-form-field>
<mat-form-field *ngIf="details.get('loan_taken_by').value == 'Others'">
<input matInput placeholder="Specify Others Loan Taken" formControlName="others_loan_taken">
<mat-form-field *ngIf="details.get('loan_taken_by').value == 0">
<input matInput autocomplete="off" placeholder="Specify Others Loan Taken" formControlName="others_loan_taken">
</mat-form-field>
<mat-form-field>
<mat-select placeholder="Lender" formControlName="lender" required>
<mat-select placeholder="Lender" formControlName="lender" >
<mat-option *ngFor="let btLen of lenderData" [value]="btLen.bt_lender_list_id">{{ btLen.lender_name }}</mat-option>
</mat-select>
</mat-form-field>
<mat-form-field *ngIf="details.get('lender').value == 3">
<input matInput placeholder="Specify Others Loan Taken" formControlName="others_loan_taken">
<input matInput autocomplete="off" placeholder="Specify Others Loan Taken" formControlName="others_loan_taken">
</mat-form-field> -->
<!-- <mat-form-field>
<input matInput placeholder="Lender" formControlName="lender" required>
<input matInput autocomplete="off" placeholder="Lender" formControlName="lender" >
</mat-form-field> -->
<!-- <mat-form-field>
<input matInput placeholder="Original Tenure in Months" formControlName="original_tenure" required>
<input matInput autocomplete="off" placeholder="Original Tenure in Months" formControlName="original_tenure" >
</mat-form-field>
<mat-form-field>
<input matInput placeholder="Current Balance Tenure in Months" formControlName="current_balance_tenure" required>
<input matInput autocomplete="off" placeholder="Current Balance Tenure in Months" formControlName="current_balance_tenure" >
</mat-form-field>
<button type="button" class="mr-1 mb-1 hover-icon" mat-raised-button mat-icon-button matTooltip="Add More Loan Details" matTooltipPosition="above" color="primary" (click)="addLoanDetails()"
*ngIf="i==0">
@ -306,7 +312,7 @@
<div fxFlex="60" class="pb-0 text-sm-left">
<mat-form-field appearance="outline" style="width: 100%">
<mat-label>Remarks</mat-label>
<textarea matInput placeholder="Remarks" formControlName="currentloan_remarks" required></textarea>
<textarea matInput autocomplete="off" placeholder="Remarks" formControlName="currentloan_remarks" ></textarea>
</mat-form-field>
</div>
</div>

View File

@ -40,9 +40,11 @@ export class CurrentLoanComponent implements OnInit {
//@Input() applicant_details: any;
lenderData: any = [];
frequencyData: any = [];
loanTypeData: any = [];
applicants: any;
placeholderName : any = [];
IDXval : any;
OtherFlag : boolean = false;
constructor(notifier: NotifierService, private fb: FormBuilder, private route: ActivatedRoute,
private router: Router,
@ -52,6 +54,7 @@ export class CurrentLoanComponent implements OnInit {
this.form_id = 8;
this.notifier = notifier;
this.applicants = this.pd_all_details.pdapplicants_detials;
this.applicants.push({'pd_co_applicant_id':'0','applicant_name':'Others'});
}
public viewerOptions: any = {
navbar: false,
@ -75,6 +78,7 @@ export class CurrentLoanComponent implements OnInit {
ngOnInit() {
this.getMasterDetails('BTLENDERLIST',1);
this.getMasterDetails('FREQUENCY',2);
this.getMasterDetails('EXISTINGLOANTYPES',3);
this.initCurrentloanForm();
let params: any = {};
params.pd_id = this.pdid;
@ -96,6 +100,7 @@ export class CurrentLoanComponent implements OnInit {
result.forEach((val,index) => {
control.push(this.createLoanDetail());
this.selectedfrequency(val.frequency,index);
//this.selectedLoanTakenBy(val.loan_taken_by,index);
});
this.currentLoanForm.controls['loan_details'].setValue(result);
} else {
@ -110,8 +115,8 @@ export class CurrentLoanComponent implements OnInit {
}
public initCurrentloanForm(): void {
this.currentLoanForm = this.fb.group({
existing_loan: ['', Validators.compose([Validators.required])],
currentloan_remarks: ['', Validators.compose([Validators.required])],
existing_loan: [''],
currentloan_remarks: [''],
loan_details: this.fb.array([]),
});
}
@ -128,7 +133,7 @@ export class CurrentLoanComponent implements OnInit {
arr.removeAt(0);
}
}
selectedfrequency(e,i){
switch(+e){
@ -145,16 +150,17 @@ export class CurrentLoanComponent implements OnInit {
createLoanDetail() {
return this.fb.group({
loan_amount: ['', Validators.compose([Validators.required])],
frequency:['', Validators.compose([Validators.required])],
emi: ['', Validators.compose([Validators.required])],
loan_type: ['', Validators.compose([Validators.required])],
loan_amount: [''],
frequency:[''],
emi: [''],
loan_type: [''],
others_loan_type: [''],
loan_taken_by:[''],
others_loan_taken:[''],
lender: ['', Validators.compose([Validators.required])],
lender: [''],
others_lender:[''],
original_tenure: ['', Validators.compose([Validators.required])],
current_balance_tenure: ['', Validators.compose([Validators.required])],
original_tenure: [''],
current_balance_tenure: [''],
});
}
addLoanDetails() {
@ -200,12 +206,15 @@ export class CurrentLoanComponent implements OnInit {
getMasterDetails(table:string,type:number){
this._pd.getAllMasterDatas(table).subscribe(data => {
data.records.forEach(val => {
if (type==1 && val.isactive == 1) {
if(type==1 && val.isactive == 1) {
this.lenderData.push(val);
}
else if(type==2 && val.isactive == 1){
this.frequencyData.push(val);
}
else if(type==3 && val.isactive == 1){
this.loanTypeData.push(val);
}
})
});
}
@ -218,4 +227,4 @@ export class CurrentLoanComponent implements OnInit {
event.preventDefault();
}
}
}
}

View File

@ -23,11 +23,11 @@
<p>Data as Per Financial Statements<p>
</mat-card-header>
<mat-form-field>
<input matInput placeholder="Starting Financial Year" formControlName="staring_financial_year" required>
<input matInput autocomplete="off" placeholder="Starting Year Of Financial" formControlName="staring_financial_year" >
</mat-form-field>
<mat-form-field>
<input matInput placeholder="Total Financial Year" formControlName="total_financial_year" required (change)="dynamicalFinYear($event)">
<input matInput autocomplete="off" placeholder="Number of Year in Financial" formControlName="total_financial_year" (change)="dynamicalFinYear($event)">
</mat-form-field>
<div *ngIf="total_financial_year != ''" formArrayName="date_per_financial">
<!-- <div formArrayName="date_per_financial"> -->
@ -35,45 +35,45 @@
[formGroupName]="i">
<mat-card-content class="matcard">
<mat-form-field>
<!-- <input matInput placeholder="Year (format: 2015-16)" formControlName="financial_year" required> -->
<input matInput placeholder="Latest Financial Year" formControlName="financial_year" required>
<!-- <input matInput autocomplete="off" placeholder="Year (format: 2015-16)" formControlName="financial_year" > -->
<input matInput autocomplete="off" placeholder="Latest Financial Year" formControlName="financial_year" >
</mat-form-field>
<mat-form-field>
<!-- <input matInput placeholder="Annual Sale" formControlName="financial_annual_sale" (change)="calMargin(i, details)" type="number" required> -->
<input matInput placeholder="Annual Sale" formControlName="financial_annual_sale" (change)="calMargin(i, details)" (keypress)="keyPress($event)" required>
<!-- <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)="calMargin(i, details)" (keypress)="keyPress($event)" >
</mat-form-field>
<mat-form-field>
<!-- <input matInput placeholder="Net Profit / Loss" formControlName="financial_net_profit" (change)="calMargin( i, details); calYearVariation( i, details)" type="number" required> -->
<mat-select placeholder="Is there Net Profit or Net Loss?" formControlName="finanical_profit_or_loss" required>
<!-- <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-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>
<!-- <input matInput placeholder="Net Profit to Sales %" formControlName="financial_margin" (keypress)="keyPress($event)" required> -->
<input matInput placeholder="Net Profit Amount" formControlName="financial_net_profit" (change)="calMargin( i, details); calYearVariation( i, details)" (keypress)="keyPress($event)" required>
<!-- <input matInput autocomplete="off" placeholder="Net Profit to Sales %" formControlName="financial_margin" (keypress)="keyPress($event)" > -->
<input matInput autocomplete="off" placeholder="Net Profit Amount" formControlName="financial_net_profit" (change)="calMargin( i, details); calYearVariation( i, details)" (keypress)="keyPress($event)" >
</mat-form-field>
<mat-form-field>
<input matInput placeholder="Net Profit to Sales %" formControlName="financial_margin_of_profit" (keypress)="keyPress($event)" required>
<input matInput autocomplete="off" placeholder="Net Profit to Sales %" 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>
<input matInput placeholder="Net Loss Amount" formControlName="financial_net_loss" (change)="calMargin( i, details); calYearVariation( i, details)" (keypress)="keyPress($event)" required>
<input matInput autocomplete="off" placeholder="Net Loss Amount" formControlName="financial_net_loss" (change)="calMargin( i, details); calYearVariation( i, details)" (keypress)="keyPress($event)" >
</mat-form-field>
<mat-form-field>
<input matInput placeholder="Net Loss to Sales %" formControlName="financial_margin_of_loss" (keypress)="keyPress($event)" required>
<input matInput autocomplete="off" placeholder="Net Loss to Sales %" formControlName="financial_margin_of_loss" (keypress)="keyPress($event)" >
</mat-form-field>
</span>
<mat-form-field *ngIf="i != 0" style="width:65%">
<input matInput [ngClass]="{'highlight': (details.controls['financial_variation'].value > 40) || (details.controls['financial_variation'].value < -40)}" placeholder="Variation from Previous Year" formControlName="financial_variation" (keypress)="keyPress($event)">
<input matInput autocomplete="off" [ngClass]="{'highlight': (details.controls['financial_variation'].value > 40) || (details.controls['financial_variation'].value < -40)}" placeholder="Variation from Previous Year" formControlName="financial_variation" (keypress)="keyPress($event)">
<!-- <mat-hint align="end" *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 *ngIf="customerCommentsFlag" style="width:65%">
<!-- <input matInput placeholder="Reason For Major Difference" formControlName="financial_reason" required> -->
<input matInput placeholder="Customer Comments on variances in Financials" formControlName="financial_reason" required>
<!-- <input matInput autocomplete="off" placeholder="Reason For Major Difference" formControlName="financial_reason" > -->
<input matInput autocomplete="off" placeholder="Customer Comments on variances in Financials" formControlName="financial_reason" >
</mat-form-field>
<!-- <button type="button" mat-raised-button mat-icon-button (click)="addDate()"
@ -109,43 +109,43 @@
<mat-card-content class="matcard">
<mat-form-field>
<!-- <input matInput placeholder="Year (format: 2015-16)" formControlName="estimate_year" required> -->
<input matInput placeholder="Year" formControlName="estimate_year" required>
<!-- <input matInput autocomplete="off" placeholder="Year (format: 2015-16)" formControlName="estimate_year" > -->
<input matInput autocomplete="off" placeholder="Year" formControlName="estimate_year" >
</mat-form-field>
<mat-form-field>
<input matInput placeholder="Annual Sale" formControlName="estimate_annual_sale" (change)="calMarginVal( i, details)" (keypress)="keyPress($event)" required>
<input matInput autocomplete="off" placeholder="Annual Sale" formControlName="estimate_annual_sale" (change)="calMarginVal( i, details)" (keypress)="keyPress($event)" >
</mat-form-field>
<mat-form-field>
<!-- <input matInput placeholder="Net Profit / Loss" formControlName="financial_net_profit" (change)="calMargin( i, details); calYearVariation( i, details)" type="number" required> -->
<mat-select placeholder="Is there Net Profit or Net Loss?" formControlName="estimate_profit_or_loss" required>
<!-- <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="estimate_profit_or_loss" >
<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('estimate_profit_or_loss').value == 1 ">
<mat-form-field>
<input matInput placeholder="Net Profit Amount" formControlName="estimate_net_profit" (change)="calMarginVal( i, details); calVariation( i, details)" required>
<input matInput autocomplete="off" placeholder="Net Profit Amount" formControlName="estimate_net_profit" (change)="calMarginVal( i, details); calVariation( i, details)" >
</mat-form-field>
<mat-form-field>
<input matInput disabled placeholder="Margin" formControlName="estimate_margin_of_profit" (keypress)="keyPress($event)" required>
<input matInput autocomplete="off" disabled placeholder="Margin" formControlName="estimate_margin_of_profit" (keypress)="keyPress($event)" >
</mat-form-field>
</span>
<span *ngIf="details.get('estimate_profit_or_loss').value == 2 ">
<mat-form-field>
<input matInput placeholder="Net Loss" formControlName="estimate_net_loss" (change)="calMarginVal( i, details); calVariation( i, details)" required>
<input matInput autocomplete="off" placeholder="Net Loss" formControlName="estimate_net_loss" (change)="calMarginVal( i, details); calVariation( i, details)" >
</mat-form-field>
<mat-form-field>
<input matInput disabled placeholder="Margin" formControlName="estimate_margin_of_loss" (keypress)="keyPress($event)" (change)="calAmount(i, details); calVariation( i, details)" required>
<input matInput autocomplete="off" disabled placeholder="Margin" formControlName="estimate_margin_of_loss" (keypress)="keyPress($event)" (change)="calAmount(i, details); calVariation( i, details)" >
</mat-form-field>
</span>
<mat-form-field *ngIf="i != 0" style="width:65%">
<input matInput [ngClass]="{'highlight': details.controls['estimate_variation'].value >= 40 || details.controls['estimate_variation'].value >= -40}" placeholder="Variation from Previous Year" formControlName="estimate_variation" (keypress)="keyPress($event)">
<input matInput autocomplete="off" [ngClass]="{'highlight': details.controls['estimate_variation'].value >= 40 || details.controls['estimate_variation'].value >= -40}" placeholder="Variation from Previous Year" formControlName="estimate_variation" (keypress)="keyPress($event)">
<mat-hint align="end" [ngClass]="{'highlight': (details.controls['estimate_variation'].value >= 40) || (details.controls['estimate_variation'].value < -40)}" > {{details.controls['estimate_variation'].value}} {{details.controls['estimate_year'].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 placeholder="Reason For Major Difference" formControlName="estimate_reason" required>
<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">
@ -269,7 +269,7 @@
<div fxFlex="60" class="pb-0 text-sm-left" align="left">
<mat-form-field appearance="outline" style="width: 100%">
<mat-label>Remarks</mat-label>
<textarea matInput placeholder="Remarks" formControlName="financial_remarks" required></textarea>
<textarea matInput autocomplete="off" placeholder="Remarks" formControlName="financial_remarks" ></textarea>
</mat-form-field>
</div>
<div fxFlex="40" align="end">
@ -295,22 +295,22 @@
[formGroupName]="i">
<mat-card-content class="matcard">
<mat-form-field>
<input matInput placeholder="Year (format: 2015-16)" formControlName="financial_year" required>
<input matInput autocomplete="off" placeholder="Year (format: 2015-16)" formControlName="financial_year" >
</mat-form-field>
<mat-form-field>
<input matInput placeholder="Annual Sale" formControlName="financial_annual_sale" (change)="calMargin(i, details)" type="number" required>
<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 placeholder="Net Profit / Loss" formControlName="financial_net_profit" (change)="calMargin( i, details); calYearVariation( i, details)" type="number" required>
<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 placeholder="Net Profit to Sales %" formControlName="financial_margin" (keypress)="keyPress($event)" required>
<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 [ngClass]="{'highlight': (details.controls['financial_variation'].value > 40) || (details.controls['financial_variation'].value < -40)}" placeholder="Variation from Previous Year" formControlName="financial_variation" (keypress)="keyPress($event)">
<input matInput autocomplete="off" [ngClass]="{'highlight': (details.controls['financial_variation'].value > 40) || (details.controls['financial_variation'].value < -40)}" placeholder="Variation from Previous Year" formControlName="financial_variation" (keypress)="keyPress($event)">
</mat-form-field>
<mat-form-field>
<input matInput placeholder="Reason For Major Difference" formControlName="financial_reason" required>
<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()"
@ -334,22 +334,22 @@
[formGroupName]="i">
<mat-card-content class="matcard">
<mat-form-field>
<input matInput placeholder="Year (format: 2015-16)" formControlName="estimate_year" required>
<input matInput autocomplete="off" placeholder="Year (format: 2015-16)" formControlName="estimate_year" >
</mat-form-field>
<mat-form-field>
<input matInput placeholder="Annual Sale" formControlName="estimate_annual_sale" (change)="calMarginVal( i, details)" type="number" required>
<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 placeholder="Net Profit / Loss" formControlName="estimate_net_profit" (change)="calMarginVal( i, details); calVariation( i, details)" type="number" required>
<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 disabled placeholder="Margin" formControlName="estimate_margin" (keypress)="keyPress($event)" required>
<input matInput autocomplete="off" disabled placeholder="Margin" formControlName="estimate_margin" (keypress)="keyPress($event)" >
</mat-form-field>
<mat-form-field *ngIf="i != 0">
<input matInput [ngClass]="{'highlight': details.controls['estimate_variation'].value >= 40 || details.controls['estimate_variation'].value >= -40}" placeholder="Variation from Previous Year" formControlName="estimate_variation" (keypress)="keyPress($event)">
<input matInput autocomplete="off" [ngClass]="{'highlight': details.controls['estimate_variation'].value >= 40 || details.controls['estimate_variation'].value >= -40}" placeholder="Variation from Previous Year" formControlName="estimate_variation" (keypress)="keyPress($event)">
</mat-form-field>
<!--<mat-form-field>
<input matInput placeholder="Reason For Major Difference" formControlName="estimate_reason" required>
<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">
@ -367,7 +367,7 @@
<div fxFlex="60" class="pb-0 text-sm-left">
<mat-form-field appearance="outline" style="width: 100%">
<mat-label>Remarks</mat-label>
<textarea matInput placeholder="Remarks" formControlName="financial_remarks" required></textarea>
<textarea matInput autocomplete="off" placeholder="Remarks" formControlName="financial_remarks" ></textarea>
</mat-form-field>
</div>
</div>

View File

@ -119,9 +119,9 @@ export class FinancialInfoComponent implements OnInit {
pdid: this.pdid,
formid: this.form_id,
fk_createdby: this.pdid,
financial_remarks: ['', Validators.compose([Validators.required])],
staring_financial_year : ['', Validators.compose([Validators.required])],
total_financial_year : ['', Validators.compose([Validators.required])],
financial_remarks: [''],
staring_financial_year : [''],
total_financial_year : [''],
same_as_financial_statements:[''],
date_per_financial: this.fb.array([]),
estimated_value: this.fb.array([])
@ -132,36 +132,36 @@ export class FinancialInfoComponent implements OnInit {
// financial_year: ['', Validators.compose([Validators.required, Validators.pattern(/^[0-9]{4}-[0-9]{2}$/)])],
// financial_annual_sale: ['', Validators.compose([Validators.required, Validators.pattern(/^[0-9\(\)]+$/)])],
// financial_net_profit: ['', Validators.compose([Validators.required, Validators.pattern(/^-?[1-9]\d*|0$/)])],
// financial_margin: ['', Validators.compose([Validators.required])],
// financial_margin: [''],
// financial_variation: [''],
// financial_reason: ['', Validators.compose([Validators.required])],
// financial_reason: [''],
// });
// }
createDate(date) {
return this.fb.group({
financial_year: [date, Validators.compose([Validators.required, Validators.pattern(/^[0-9]{4}-[0-9]{2}$/)])],
financial_annual_sale: ['', Validators.compose([Validators.required, Validators.pattern(/^[0-9\(\)]+$/)])],
finanical_profit_or_loss:['', Validators.compose([Validators.required])],
financial_year: [date, Validators.compose([Validators.pattern(/^[0-9]{4}-[0-9]{2}$/)])],
financial_annual_sale: ['', Validators.compose([Validators.pattern(/^[0-9\(\)]+$/)])],
finanical_profit_or_loss:[''],
financial_net_profit: ['', Validators.compose([Validators.pattern(/^-?[1-9]\d*|0$/)])],
financial_net_loss: ['', Validators.compose([Validators.pattern(/^-?[1-9]\d*|0$/)])],
financial_margin_of_profit: [''],
financial_margin_of_loss: [''],
financial_variation: [''],
financial_reason: ['', Validators.compose([Validators.required])],
financial_reason: [''],
});
}
createValue(date) {
return this.fb.group({
estimate_year: [date, Validators.compose([Validators.required, Validators.pattern(/^[0-9]{4}-[0-9]{2}$/)])],
estimate_annual_sale: ['', Validators.compose([Validators.required, Validators.pattern(/^[0-9\(\)]+$/)])],
estimate_profit_or_loss:['', Validators.compose([Validators.required])],
estimate_net_profit: ['', Validators.compose([Validators.required, Validators.pattern(/^-?[1-9]\d*|0$/)])],
estimate_year: [date, Validators.compose([Validators.pattern(/^[0-9]{4}-[0-9]{2}$/)])],
estimate_annual_sale: ['', Validators.compose([Validators.pattern(/^[0-9\(\)]+$/)])],
estimate_profit_or_loss:[''],
estimate_net_profit: ['', Validators.compose([Validators.pattern(/^-?[1-9]\d*|0$/)])],
estimate_net_loss: ['', Validators.compose([Validators.pattern(/^-?[1-9]\d*|0$/)])],
//estimate_margin: ['', Validators.compose([Validators.required])],
//estimate_margin: [''],
estimate_margin_of_profit: [''],
estimate_margin_of_loss: [''],
estimate_variation: [''],
// estimate_reason: ['', Validators.compose([Validators.required])],
// estimate_reason: [''],
});
}
@ -169,14 +169,14 @@ export class FinancialInfoComponent implements OnInit {
return this.fb.group({
estimate_year: [value.estimate_year, Validators.compose([Validators.required, Validators.pattern(/^[0-9]{4}-[0-9]{2}$/)])],
estimate_annual_sale: [value.estimate_annual_sale, Validators.compose([Validators.required, Validators.pattern(/^[0-9\(\)]+$/)])],
estimate_profit_or_loss:[value.estimate_profit_or_loss, Validators.compose([Validators.required])],
estimate_profit_or_loss:[value.estimate_profit_or_loss],
estimate_net_loss: [value.estimate_net_loss, Validators.compose([Validators.pattern(/^-?[1-9]\d*|0$/)])],
estimate_net_profit: [value.estimate_net_profit, Validators.compose([Validators.required, Validators.pattern(/^-?[1-9]\d*|0$/)])],
//estimate_margin: [value., Validators.compose([Validators.required])],
//estimate_margin: [value.],
estimate_margin_of_profit: [value.estimate_margin_of_profit],
estimate_margin_of_loss: [value.estimate_margin_of_loss],
estimate_variation: [value.estimate_variation],
// estimate_reason: ['', Validators.compose([Validators.required])],
// estimate_reason: [''],
});
}

View File

@ -104,7 +104,7 @@ public viewerOptions: any = {
}
}
} else {
control.push(this.createDetail());
//control.push(this.createDetail());
}
})
}

View File

@ -27,43 +27,43 @@
<mat-card-title> <p>{{a+1}} . Raw Material </p> </mat-card-title>
<mat-card-content class="matcard">
<mat-form-field style="width:30%">
<input matInput placeholder="Name" formControlName="raw_name" required>
<input matInput autocomplete="off" placeholder="Name" formControlName="raw_name" >
</mat-form-field>
<mat-form-field style="width:30%">
<mat-select placeholder="is the Stock is Observed ?" formControlName="stock_observed" required>
<mat-select placeholder="is the Stock is Observed ?" formControlName="stock_observed" >
<mat-option value="yes" >Yes</mat-option>
<mat-option value="no" >No</mat-option>
</mat-select>
</mat-form-field>
<span *ngIf="mrm.get('stock_observed').value == 'no'" >
<mat-form-field style="width:30%">
<input matInput placeholder="Estimated Quantity" formControlName="raw_quantity" required>
<input matInput autocomplete="off" placeholder="Estimated Quantity" formControlName="raw_quantity" >
</mat-form-field>
<mat-form-field style="width:30%">
<mat-select placeholder="Unit of Mearsurement"
formControlName="raw_uom" required>
formControlName="raw_uom" >
<mat-option value="{{uom.uom_id}}" *ngFor="let uom of uomData">{{uom.name}}</mat-option>
</mat-select>
</mat-form-field>
<mat-form-field *ngIf="mrm.get('raw_uom').value == 61" style="width:30%">
<input matInput placeholder="Specify Other UOM" formControlName="other_uom" required>
<input matInput autocomplete="off" placeholder="Specify Other UOM" formControlName="other_uom" >
</mat-form-field>
<mat-form-field style="width:76%">
<input matInput placeholder="Estimated Value of Stock Observed" formControlName="raw_value" (keypress)="keyPress($event)" (keyup)="inWords($event,1)" required>
<input matInput autocomplete="off" placeholder="Estimated Value of Stock Observed" formControlName="raw_value" (keypress)="keyPress($event)" (keyup)="inWords($event,1)" >
<mat-hint align="end" *ngIf="mrm.get('raw_value').value != ''">{{"&#8377;"}} {{M_rawValueInWords}} Only</mat-hint>
</mat-form-field>
<mat-form-field style="width:76%">
<input matInput placeholder="Value of raw materials as per latest financial Statements" formControlName="rawmaterial_value" (keypress)="keyPress($event)" required>
<input matInput autocomplete="off" placeholder="Value of raw materials as per latest financial Statements" formControlName="rawmaterial_value" (keypress)="keyPress($event)" >
</mat-form-field>
<mat-form-field style="width:90%">
<mat-select placeholder="Is the stock of Raw Materials observed, sufficient considering the size of operations" formControlName="is_sufficiant_raw" required>
<mat-select placeholder="Is the stock of Raw Materials observed, sufficient considering the size of operations" formControlName="is_sufficiant_raw" >
<mat-option value="yes" >Yes</mat-option>
<mat-option value="no" >No</mat-option>
</mat-select>
</mat-form-field>
<mat-form-field *ngIf="mrm.get('is_sufficiant_raw').value == 'no'" appearance="outline" style="width: 90%">
<mat-label>Please comment on the stock level observed?</mat-label>
<textarea matInput placeholder="Please comment on the stock level observed" formControlName="rawmaterial_remarks"></textarea>
<textarea matInput autocomplete="off" placeholder="Please comment on the stock level observed" formControlName="rawmaterial_remarks"></textarea>
</mat-form-field>
</span>
<button type="button" mat-raised-button mat-icon-button (click)="addRawMaterials(1)"
@ -83,34 +83,34 @@
<mat-card-title> <p> {{b+1}} Finished Goods </p> </mat-card-title>
<mat-card-content class="matcard">
<mat-form-field style="width:30%">
<input matInput placeholder="Name" formControlName="goods_name" required>
<input matInput autocomplete="off" placeholder="Name" formControlName="goods_name" >
</mat-form-field>
<mat-form-field style="width:30%">
<mat-select placeholder="is the Goods is Observed ?" formControlName="goods_observed" required>
<mat-select placeholder="is the Goods is Observed ?" formControlName="goods_observed" >
<mat-option value="yes" >Yes</mat-option>
<mat-option value="no" >No</mat-option>
</mat-select>
</mat-form-field>
<span *ngIf="mfg.get('goods_observed').value == 'no'" >
<mat-form-field style="width:30%">
<input matInput placeholder="Estimated Quantity" formControlName="goods_quantity" required>
<input matInput autocomplete="off" placeholder="Estimated Quantity" formControlName="goods_quantity" >
</mat-form-field>
<mat-form-field style="width:76%">
<input matInput placeholder="Estimated Value of Stock Observed" formControlName="goods_value" (keypress)="keyPress($event)" (keyup)="inWords($event,2)" required>
<input matInput autocomplete="off" placeholder="Estimated Value of Stock Observed" formControlName="goods_value" (keypress)="keyPress($event)" (keyup)="inWords($event,2)" >
<mat-hint align="end" *ngIf="mfg.get('goods_value').value != ''">{{"&#8377;"}} {{M_goodsValueInWords}} Only</mat-hint>
</mat-form-field>
<mat-form-field style="width:76%">
<input matInput placeholder="Value of finished goods as per latest financial statements" formControlName="finished_goods_value" (keypress)="keyPress($event)" required>
<input matInput autocomplete="off" placeholder="Value of finished goods as per latest financial statements" formControlName="finished_goods_value" (keypress)="keyPress($event)" >
</mat-form-field>
<mat-form-field style="width:90%">
<mat-select placeholder="Is the stock of finished goods observed ?" formControlName="is_sufficiant_goods" required>
<mat-select placeholder="Is the stock of finished goods observed ?" formControlName="is_sufficiant_goods" >
<mat-option value="yes" >Yes</mat-option>
<mat-option value="no" >No</mat-option>
</mat-select>
</mat-form-field>
<mat-form-field *ngIf="mfg.get('is_sufficiant_goods').value == 'no'" appearance="outline" style="width: 90%">
<mat-label>Please comment on the finished goods stock level observed?</mat-label>
<textarea matInput placeholder="Please comment on the finished goods observed" formControlName="finishedgoods_remarks"></textarea>
<textarea matInput autocomplete="off" placeholder="Please comment on the finished goods observed" formControlName="finishedgoods_remarks"></textarea>
</mat-form-field>
</span>
@ -131,35 +131,35 @@
<mat-card-title> <p>{{c+1}} Traded Goods </p> </mat-card-title>
<mat-card-content class="matcard">
<mat-form-field style="width:30%">
<input matInput placeholder="Name" formControlName="traded_goods_name" required>
<input matInput autocomplete="off" placeholder="Name" formControlName="traded_goods_name" >
</mat-form-field>
<mat-form-field style="width:30%">
<mat-select placeholder="is the Traded Goods is Observed ?" formControlName="traded_goods_observed" required >
<mat-select placeholder="is the Traded Goods is Observed ?" formControlName="traded_goods_observed" >
<mat-option value="yes" >Yes</mat-option>
<mat-option value="no" >No</mat-option>
</mat-select>
</mat-form-field>
<span *ngIf="mtg.get('traded_goods_observed').value == 'no'" >
<mat-form-field style="width:30%">
<input matInput placeholder="Estimated Quantity" formControlName="traded_goods_quantity" required>
<input matInput autocomplete="off" placeholder="Estimated Quantity" formControlName="traded_goods_quantity" >
</mat-form-field>
<mat-form-field style="width:76%">
<input matInput placeholder="Estimated Value of Stock Observed" formControlName="estimated_traded_goods_value" (keypress)="keyPress($event)" (keyup)="inWords($event,3)" required>
<input matInput autocomplete="off" placeholder="Estimated Value of Stock Observed" formControlName="estimated_traded_goods_value" (keypress)="keyPress($event)" (keyup)="inWords($event,3)" >
<mat-hint align="end" *ngIf="mtg.get('estimated_traded_goods_value').value != ''">{{"&#8377;"}} {{M_tradedGoodsValueInWords}} Only</mat-hint>
</mat-form-field>
<mat-form-field style="width:76%">
<input matInput placeholder="Value of traded goods as per latest financial statements" formControlName="traded_goods_value" (keypress)="keyPress($event)" required>
<input matInput autocomplete="off" placeholder="Value of traded goods as per latest financial statements" formControlName="traded_goods_value" (keypress)="keyPress($event)" >
</mat-form-field>
<mat-form-field style="width:90%">
<!-- <input matInput placeholder="Is the stock of finished goods observed ?" formControlName="is_sufficiant_goods" required> -->
<mat-select placeholder="Is the stock of Traded goods observed ?" formControlName="is_sufficiant_traded_goods" required>
<!-- <input matInput autocomplete="off" placeholder="Is the stock of finished goods observed ?" formControlName="is_sufficiant_goods" > -->
<mat-select placeholder="Is the stock of Traded goods observed ?" formControlName="is_sufficiant_traded_goods" >
<mat-option value="yes" >Yes</mat-option>
<mat-option value="no" >No</mat-option>
</mat-select>
</mat-form-field>
<mat-form-field *ngIf="mtg.get('is_sufficiant_traded_goods').value == 'no'" appearance="outline" style="width: 90%">
<mat-label>Please comment on the Traded Goods stock level observed?</mat-label>
<textarea matInput placeholder="Please comment on the traded goods stock level observed" formControlName="traded_goods_remarks"></textarea>
<textarea matInput autocomplete="off" placeholder="Please comment on the traded goods stock level observed" formControlName="traded_goods_remarks"></textarea>
</mat-form-field>
</span>
@ -191,35 +191,35 @@
<mat-card-title> <p>{{d+1}} Finished Goods </p> </mat-card-title>
<mat-card-content class="matcard">
<mat-form-field style="width:30%">
<input matInput placeholder="Name" formControlName="goods_name" required>
<input matInput autocomplete="off" placeholder="Name" formControlName="goods_name" >
</mat-form-field>
<mat-form-field style="width:30%">
<mat-select placeholder="is the Goods is Observed ?" formControlName="goods_observed" required>
<mat-select placeholder="is the Goods is Observed ?" formControlName="goods_observed" >
<mat-option value="yes" >Yes</mat-option>
<mat-option value="no" >No</mat-option>
</mat-select>
</mat-form-field>
<span *ngIf="retailfg.get('goods_observed').value == 'no'" >
<mat-form-field style="width:30%">
<input matInput placeholder="Estimated Quantity" formControlName="goods_quantity" required>
<input matInput autocomplete="off" placeholder="Estimated Quantity" formControlName="goods_quantity" >
</mat-form-field>
<mat-form-field style="width:76%">
<input matInput placeholder="Estimated Value of Stock Observed" formControlName="goods_value" (keypress)="keyPress($event)" (keyup)="inWords($event,4)" required>
<input matInput autocomplete="off" placeholder="Estimated Value of Stock Observed" formControlName="goods_value" (keypress)="keyPress($event)" (keyup)="inWords($event,4)" >
<mat-hint align="end" *ngIf="retailfg.get('goods_value').value != ''">{{"&#8377;"}} {{R_goodsValueInWords}} Only</mat-hint>
</mat-form-field>
<mat-form-field style="width:76%">
<input matInput placeholder="Value of finished goods as per latest financial statements" formControlName="finished_goods_value" (keypress)="keyPress($event)" required>
<input matInput autocomplete="off" placeholder="Value of finished goods as per latest financial statements" formControlName="finished_goods_value" (keypress)="keyPress($event)" >
</mat-form-field>
<mat-form-field style="width:90%">
<mat-select placeholder="Is the stock of finished goods observed ?" formControlName="is_sufficiant_goods" required>
<mat-select placeholder="Is the stock of finished goods observed ?" formControlName="is_sufficiant_goods" >
<mat-option value="yes" >Yes</mat-option>
<mat-option value="no" >No</mat-option>
</mat-select>
</mat-form-field>
<mat-form-field *ngIf="retailfg.get('is_sufficiant_goods').value == 'no'" appearance="outline" style="width: 90%">
<mat-label>Please comment on the finished goods stock level observed?</mat-label>
<textarea matInput placeholder="Please comment on the finished goods observed" formControlName="finishedgoods_remarks"></textarea>
<textarea matInput autocomplete="off" placeholder="Please comment on the finished goods observed" formControlName="finishedgoods_remarks"></textarea>
</mat-form-field>
</span>
@ -240,35 +240,35 @@
<mat-card-title> <p>{{e+1}} Traded Goods </p> </mat-card-title>
<mat-card-content class="matcard">
<mat-form-field style="width:30%">
<input matInput placeholder="Name" formControlName="traded_goods_name" required>
<input matInput autocomplete="off" placeholder="Name" formControlName="traded_goods_name" >
</mat-form-field>
<mat-form-field style="width:30%">
<mat-select placeholder="is the Traded Goods is Observed ?" formControlName="traded_goods_observed" required>
<mat-select placeholder="is the Traded Goods is Observed ?" formControlName="traded_goods_observed" >
<mat-option value="yes" >Yes</mat-option>
<mat-option value="no" >No</mat-option>
</mat-select>
</mat-form-field>
<span *ngIf="item.get('traded_goods_observed').value == 'no'" >
<mat-form-field style="width:30%">
<input matInput placeholder="Estimated Quantity" formControlName="traded_goods_quantity" required>
<input matInput autocomplete="off" placeholder="Estimated Quantity" formControlName="traded_goods_quantity" >
</mat-form-field>
<mat-form-field style="width:76%">
<input matInput placeholder="Estimated Value of Stock Observed" formControlName="estimated_traded_goods_value" (keypress)="keyPress($event)" (keyup)="inWords($event,5)" required>
<input matInput autocomplete="off" placeholder="Estimated Value of Stock Observed" formControlName="estimated_traded_goods_value" (keypress)="keyPress($event)" (keyup)="inWords($event,5)" >
<mat-hint align="end" *ngIf="item.get('estimated_traded_goods_value').value != ''">{{"&#8377;"}} {{R_tradedGoodsValueInWords}} Only</mat-hint>
</mat-form-field>
<mat-form-field style="width:76%">
<input matInput placeholder="Value of traded goods as per latest financial statements" formControlName="traded_goods_value" (keypress)="keyPress($event)" required>
<input matInput autocomplete="off" placeholder="Value of traded goods as per latest financial statements" formControlName="traded_goods_value" (keypress)="keyPress($event)" >
</mat-form-field>
<mat-form-field style="width:90%">
<mat-select placeholder="Is the stock of Traded goods observed ?" formControlName="is_sufficiant_traded_goods" required>
<mat-select placeholder="Is the stock of Traded goods observed ?" formControlName="is_sufficiant_traded_goods" >
<mat-option value="yes" >Yes</mat-option>
<mat-option value="no" >No</mat-option>
</mat-select>
</mat-form-field>
<mat-form-field *ngIf="item.get('is_sufficiant_traded_goods').value == 'no'" appearance="outline" style="width: 90%">
<mat-label>Please comment on the Traded Goods stock level observed?</mat-label>
<textarea matInput placeholder="Please comment on the traded goods stock level observed" formControlName="traded_goods_remarks"></textarea>
<textarea matInput autocomplete="off" placeholder="Please comment on the traded goods stock level observed" formControlName="traded_goods_remarks"></textarea>
</mat-form-field>
</span>
@ -301,35 +301,35 @@
<mat-card-title> <p>{{f+1}} Finished Goods </p> </mat-card-title>
<mat-card-content class="matcard">
<mat-form-field style="width:30%">
<input matInput placeholder="Name" formControlName="goods_name" required>
<input matInput autocomplete="off" placeholder="Name" formControlName="goods_name" >
</mat-form-field>
<mat-form-field style="width:30%">
<mat-select placeholder="is the Goods is Observed ?" formControlName="goods_observed" required >
<mat-select placeholder="is the Goods is Observed ?" formControlName="goods_observed" >
<mat-option value="yes" >Yes</mat-option>
<mat-option value="no" >No</mat-option>
</mat-select>
</mat-form-field>
<span *ngIf="tradesubdetail.get('goods_observed').value == 'no'" >
<mat-form-field style="width:30%">
<input matInput placeholder="Estimated Quantity" formControlName="goods_quantity" required>
<input matInput autocomplete="off" placeholder="Estimated Quantity" formControlName="goods_quantity" >
</mat-form-field>
<mat-form-field style="width:76%">
<input matInput placeholder="Estimated Value of Stock Observed" formControlName="goods_value" (keypress)="keyPress($event)" (keyup)="inWords($event,6)" required>
<input matInput autocomplete="off" placeholder="Estimated Value of Stock Observed" formControlName="goods_value" (keypress)="keyPress($event)" (keyup)="inWords($event,6)" >
<mat-hint align="end" *ngIf="tradesubdetail.get('goods_value').value != ''">{{"&#8377;"}} {{T_goodsValueInWords}} Only</mat-hint>
</mat-form-field>
<mat-form-field style="width:76%">
<input matInput placeholder="Value of finished goods as per latest financial statements" formControlName="finished_goods_value" (keypress)="keyPress($event)" required>
<input matInput autocomplete="off" placeholder="Value of finished goods as per latest financial statements" formControlName="finished_goods_value" (keypress)="keyPress($event)" >
</mat-form-field>
<mat-form-field style="width:90%">
<mat-select placeholder="Is the stock of finished goods observed ?" formControlName="is_sufficiant_goods" required>
<mat-select placeholder="Is the stock of finished goods observed ?" formControlName="is_sufficiant_goods" >
<mat-option value="yes" >Yes</mat-option>
<mat-option value="no" >No</mat-option>
</mat-select>
</mat-form-field>
<mat-form-field *ngIf="tradesubdetail.get('is_sufficiant_goods').value == 'no'" appearance="outline" style="width: 90%">
<mat-label>Please comment on the finished goods stock level observed?</mat-label>
<textarea matInput placeholder="Please comment on the finished goods observed" formControlName="finishedgoods_remarks"></textarea>
<textarea matInput autocomplete="off" placeholder="Please comment on the finished goods observed" formControlName="finishedgoods_remarks"></textarea>
</mat-form-field>
</span>
@ -351,35 +351,35 @@
<mat-card-title> <p>{{g+1}} Traded Goods </p> </mat-card-title>
<mat-card-content class="matcard">
<mat-form-field style="width:30%">
<input matInput placeholder="Name" formControlName="traded_goods_name" required>
<input matInput autocomplete="off" placeholder="Name" formControlName="traded_goods_name" >
</mat-form-field>
<mat-form-field style="width:30%">
<mat-select placeholder="is the Traded Goods is Observed ?" formControlName="traded_goods_observed" required>
<mat-select placeholder="is the Traded Goods is Observed ?" formControlName="traded_goods_observed" >
<mat-option value="yes" >Yes</mat-option>
<mat-option value="no" >No</mat-option>
</mat-select>
</mat-form-field>
<span *ngIf="tradetg.get('traded_goods_observed').value == 'no'" >
<mat-form-field style="width:30%">
<input matInput placeholder="Estimated Quantity" formControlName="traded_goods_quantity" required>
<input matInput autocomplete="off" placeholder="Estimated Quantity" formControlName="traded_goods_quantity" >
</mat-form-field>
<mat-form-field style="width:76%">
<input matInput placeholder="Estimated Value of Stock Observed" formControlName="estimated_traded_goods_value" (keypress)="keyPress($event)" (keyup)="inWords($event,7)" required>
<input matInput autocomplete="off" placeholder="Estimated Value of Stock Observed" formControlName="estimated_traded_goods_value" (keypress)="keyPress($event)" (keyup)="inWords($event,7)" >
<mat-hint align="end" *ngIf="tradetg.get('estimated_traded_goods_value').value != ''">{{"&#8377;"}} {{T_tradedGoodsValueInWords}} Only</mat-hint>
</mat-form-field>
<mat-form-field style="width:76%">
<input matInput placeholder="Value of traded goods as per latest financial statements" formControlName="traded_goods_value" (keypress)="keyPress($event)" required>
<input matInput autocomplete="off" placeholder="Value of traded goods as per latest financial statements" formControlName="traded_goods_value" (keypress)="keyPress($event)" >
</mat-form-field>
<mat-form-field style="width:90%">
<!-- <input matInput placeholder="Is the stock of finished goods observed ?" formControlName="is_sufficiant_goods" required> -->
<mat-select placeholder="Is the stock of Traded goods observed ?" formControlName="is_sufficiant_traded_goods" required>
<!-- <input matInput autocomplete="off" placeholder="Is the stock of finished goods observed ?" formControlName="is_sufficiant_goods" > -->
<mat-select placeholder="Is the stock of Traded goods observed ?" formControlName="is_sufficiant_traded_goods" >
<mat-option value="yes" >Yes</mat-option>
<mat-option value="no" >No</mat-option>
</mat-select>
</mat-form-field>
<mat-form-field *ngIf="tradetg.get('is_sufficiant_traded_goods').value == 'no'" appearance="outline" style="width: 90%">
<mat-label>Please comment on the Traded Goods stock level observed?</mat-label>
<textarea matInput placeholder="Please comment on the traded goods stock level observed" formControlName="traded_goods_remarks"></textarea>
<textarea matInput autocomplete="off" placeholder="Please comment on the traded goods stock level observed" formControlName="traded_goods_remarks"></textarea>
</mat-form-field>
</span>
@ -516,7 +516,7 @@
<div fxFlex="60" class="pb-0 text-sm-left" align="left">
<mat-form-field appearance="outline" style="width: 100%">
<mat-label>Remarks</mat-label>
<textarea matInput placeholder="Remarks" formControlName="stock_remarks"></textarea>
<textarea matInput autocomplete="off" placeholder="Remarks" formControlName="stock_remarks"></textarea>
</mat-form-field>
</div>
<div fxFlex="40" align="end">