group of business form changes
This commit is contained in:
parent
d631915989
commit
b6525281aa
@ -28,7 +28,7 @@
|
||||
<div fxLayout="row wrap" fxLayoutGap="5px" fxLayoutAlign="start none">
|
||||
<mat-form-field style="width:100%">
|
||||
<mat-select (selectionChange)="selectedAssetsType($event,i,2)" placeholder="Assets Type" formControlName="business_assets_mode" requried>
|
||||
<mat-option *ngFor="let asset of m_assets_type" [value]="asset.id">{{ asset.name }}</mat-option>
|
||||
<mat-option *ngFor="let asset of m_assets_type" [value]="asset.id">{{ asset.name | titlecase }}</mat-option>
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
</div>
|
||||
@ -43,7 +43,7 @@
|
||||
|
||||
<mat-form-field style="width:30%">
|
||||
<mat-select placeholder="Property Type" formControlName="property_type" >
|
||||
<mat-option *ngFor="let prop of m_propertyType" [value]="prop.id">{{ prop.name }}</mat-option>
|
||||
<mat-option *ngFor="let prop of m_propertyType" [value]="prop.id">{{ prop.name | titlecase }}</mat-option>
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
|
||||
@ -107,7 +107,7 @@
|
||||
|
||||
<mat-form-field style="width:30%">
|
||||
<mat-select placeholder="Frequency" formControlName="frequency_mode" >
|
||||
<mat-option *ngFor="let freqn of m_freqOfPurchase" [value]="freqn.frequency_id">{{ freqn.name }}</mat-option>
|
||||
<mat-option *ngFor="let freqn of m_freqOfPurchase" [value]="freqn.frequency_id">{{ freqn.name | titlecase }}</mat-option>
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
|
||||
@ -138,7 +138,7 @@
|
||||
<div fxLayout="row wrap" fxLayoutGap="2px" fxLayoutAlign="start none">
|
||||
<mat-form-field style="width:30%">
|
||||
<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-option *ngFor="let ins_type of m_investmentType" [value]="ins_type.id">{{ ins_type.name | titlecase }}</mat-option>
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
<mat-form-field style="width:30%" *ngIf="detail.get('investments_type').value == 6 ">
|
||||
@ -175,7 +175,7 @@
|
||||
|
||||
<mat-form-field style="width:30%">
|
||||
<mat-select placeholder="Is there any asset loan?" formControlName="any_other_asset_loan" (selectionChange)="selectedAssetLoanType($event.value,2)">
|
||||
<mat-option value="{{data.value}}" *ngFor="let data of m_any_asset_loan_type">{{data.viewValue}}</mat-option>
|
||||
<mat-option value="{{data.value}}" *ngFor="let data of m_any_asset_loan_type">{{data.viewValue | titlecase}}</mat-option>
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
|
||||
@ -219,8 +219,13 @@
|
||||
</mat-form-field>
|
||||
|
||||
<mat-form-field *ngIf="sup.get('business_assets_mode').value == 1 || sup.get('business_assets_mode').value == 2 || sup.get('business_assets_mode').value == 3 || sup.get('business_assets_mode').value == 4 || sup.get('business_assets_mode').value == 5" style="width:30%">
|
||||
<input matInput placeholder="Name of the Business Owner" formControlName="business_name_of_the_owner" autocomplete="off">
|
||||
</mat-form-field>
|
||||
<!-- <input matInput placeholder="Name of the Business Owner" formControlName="business_name_of_the_owner" autocomplete="off"> -->
|
||||
<mat-select placeholder="Name of the Business Owner"
|
||||
formControlName="business_name_of_the_owner" required>
|
||||
<mat-option [value]="company.company_name" *ngFor="let company of existCompanyList">{{company.company_name | titlecase}}</mat-option>
|
||||
<!-- <mat-option value="Others">Others</mat-option> -->
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
</div>
|
||||
|
||||
|
||||
@ -301,7 +306,7 @@
|
||||
<div fxLayout="row wrap" fxLayoutGap="5px" fxLayoutAlign="start none">
|
||||
<mat-form-field style="width:100%">
|
||||
<mat-select (selectionChange)="selectedAssetsType($event,i,1)" placeholder="Assets Type" formControlName="assets_mode" requried>
|
||||
<mat-option *ngFor="let asset of m_assets_type" [value]="asset.id">{{ asset.name }}</mat-option>
|
||||
<mat-option *ngFor="let asset of m_assets_type" [value]="asset.id">{{ asset.name | titlecase }}</mat-option>
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
</div>
|
||||
@ -314,7 +319,7 @@
|
||||
<div fxLayout="row" fxLayoutGap="2px" fxLayoutAlign="start none">
|
||||
<mat-form-field style="width:30%">
|
||||
<mat-select placeholder="Property Type" formControlName="property_type" >
|
||||
<mat-option *ngFor="let prop of m_propertyType" [value]="prop.id">{{ prop.name }}</mat-option>
|
||||
<mat-option *ngFor="let prop of m_propertyType" [value]="prop.id">{{ prop.name | titlecase }}</mat-option>
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
<mat-form-field *ngIf="detail.get('property_type').value == 5" style="width:30%">
|
||||
@ -386,7 +391,7 @@
|
||||
</mat-form-field>
|
||||
<mat-form-field style="width:30%">
|
||||
<mat-select placeholder="Frequency" formControlName="frequency_mode" >
|
||||
<mat-option *ngFor="let freqn of m_freqOfPurchase" [value]="freqn.frequency_id">{{ freqn.name }}</mat-option>
|
||||
<mat-option *ngFor="let freqn of m_freqOfPurchase" [value]="freqn.frequency_id">{{ freqn.name | titlecase }}</mat-option>
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
<mat-form-field style="width:30%" *ngIf="detail.get('frequency_mode').value == 8 ">
|
||||
@ -418,7 +423,7 @@
|
||||
|
||||
<mat-form-field style="width:30%">
|
||||
<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-option *ngFor="let ins_type of m_investmentType" [value]="ins_type.id">{{ ins_type.name | titlecase }}</mat-option>
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
|
||||
@ -457,7 +462,7 @@
|
||||
<mat-form-field style="width:30%">
|
||||
<mat-select placeholder="Name of the Owner"
|
||||
formControlName="name_of_the_owner" >
|
||||
<mat-option value="{{owner.pd_co_applicant_id}}" *ngFor="let owner of applicants">{{owner.applicant_name}}</mat-option>
|
||||
<mat-option value="{{owner.pd_co_applicant_id}}" *ngFor="let owner of applicants">{{owner.applicant_name | titlecase}}</mat-option>
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
|
||||
@ -470,7 +475,7 @@
|
||||
<mat-select placeholder="Relation" formControlName="relation" >
|
||||
<mat-option value="{{relations.relationship_id}}"
|
||||
*ngFor="let relations of m_relation">
|
||||
{{relations.name}}
|
||||
{{relations.name | titlecase}}
|
||||
</mat-option>
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
@ -487,7 +492,7 @@
|
||||
<!-- </mat-form-field> -->
|
||||
<mat-form-field style="width:30%">
|
||||
<mat-select placeholder="Is there any asset loan?" formControlName="any_other_asset_loan" (selectionChange)="selectedAssetLoanType($event.value,1)">
|
||||
<mat-option value="{{data.value}}" *ngFor="let data of m_any_asset_loan_type">{{data.viewValue}}</mat-option>
|
||||
<mat-option value="{{data.value}}" *ngFor="let data of m_any_asset_loan_type">{{data.viewValue | titlecase}}</mat-option>
|
||||
</mat-select>
|
||||
<!-- <input matInput placeholder="What is the EMI amount ?" formControlName="any_other_asset_loan" autocomplete="off"> -->
|
||||
</mat-form-field>
|
||||
@ -512,7 +517,7 @@
|
||||
|
||||
<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:30%">
|
||||
<mat-select placeholder="Name of the Owner" formControlName="name_of_the_owner" >
|
||||
<mat-option value="{{owner.pd_co_applicant_id}}" *ngFor="let owner of applicants">{{owner.applicant_name}}</mat-option>
|
||||
<mat-option value="{{owner.pd_co_applicant_id}}" *ngFor="let owner of applicants">{{owner.applicant_name | titlecase}}</mat-option>
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
|
||||
@ -525,7 +530,7 @@
|
||||
<mat-select placeholder="Relation" formControlName="relation" >
|
||||
<mat-option value="{{relations.relationship_id}}"
|
||||
*ngFor="let relations of m_relation">
|
||||
{{relations.name}}
|
||||
{{relations.name | titlecase}}
|
||||
</mat-option>
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
|
||||
@ -31,7 +31,7 @@ export class AssetsInfoComponent implements OnInit {
|
||||
pageTitle: string ="Assets Details";
|
||||
//@Input() pdid: number;
|
||||
pdid:string;
|
||||
businessProfessionName :string;
|
||||
//businessProfessionName :string;
|
||||
|
||||
public _assetsQuesFrom: FormGroup;
|
||||
public submitted = false;
|
||||
@ -183,6 +183,7 @@ public m_investmentType = [];
|
||||
// ]
|
||||
|
||||
private notifier: NotifierService;
|
||||
existCompanyList: any =[];
|
||||
constructor(
|
||||
notifier: NotifierService,
|
||||
private _formBuilder: FormBuilder,
|
||||
@ -216,9 +217,14 @@ public m_investmentType = [];
|
||||
|
||||
ngOnInit() {
|
||||
|
||||
this.pdTrigerService.getTypeofActivityForSuppliedInfoForm(this.pdid).subscribe(data => {
|
||||
this.businessProfessionName = (data.status == 200) ? data.records.profession_name : '' ;
|
||||
});
|
||||
// this.pdTrigerService.getTypeofActivityForSuppliedInfoForm(this.pdid,'').subscribe(data => {
|
||||
// this.businessProfessionName = (data.status == 200) ? data.records.profession_name : '' ;
|
||||
// });
|
||||
this.pdTrigerService.getCompaniesListsForBusiness(this.pdid).subscribe(data=>{
|
||||
if(data.dataStatus){
|
||||
this.existCompanyList = data.records.filter(val =>val.is_active);
|
||||
}
|
||||
})
|
||||
|
||||
this.getPdSupplierFormDetails();
|
||||
this.getM_Assets_Type();
|
||||
@ -348,7 +354,7 @@ public m_investmentType = [];
|
||||
this.initDetails(),
|
||||
]),
|
||||
business_assets_details : this._formBuilder.array([
|
||||
this.initBusinessDetails(this.businessProfessionName),
|
||||
this.initBusinessDetails(),
|
||||
]),
|
||||
assets_form_remark:['']
|
||||
});
|
||||
@ -382,12 +388,12 @@ public m_investmentType = [];
|
||||
});
|
||||
}
|
||||
|
||||
initBusinessDetails(data) {
|
||||
initBusinessDetails() {
|
||||
return this._formBuilder.group({
|
||||
business_assets_mode: [''],
|
||||
business_details: this._formBuilder.array([]),
|
||||
business_approximate_market_value: [''],
|
||||
business_name_of_the_owner: [data],
|
||||
business_name_of_the_owner: [],
|
||||
//other_owner:[''],
|
||||
//relation:[''],
|
||||
//purchase_year: [''],
|
||||
@ -402,9 +408,6 @@ public m_investmentType = [];
|
||||
|
||||
show: boolean;
|
||||
selectedAssetsType(e: any, i: any,flag : any): void {
|
||||
console.log(e);
|
||||
console.log(i);
|
||||
console.log(flag);
|
||||
let val = i;
|
||||
if(flag == 1){
|
||||
const arr = (<FormArray>this._assetsQuesFrom.controls['assets_details']).at(val).get('details') as FormArray;
|
||||
@ -878,7 +881,7 @@ public m_investmentType = [];
|
||||
control.push(this.initDetails());
|
||||
}else if(flag == 2){
|
||||
const control = <FormArray>this._assetsQuesFrom.controls['business_assets_details'];
|
||||
control.push(this.initBusinessDetails(this.businessProfessionName));
|
||||
control.push(this.initBusinessDetails());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -0,0 +1,29 @@
|
||||
<h2 mat-dialog-title class="paragraph_change">
|
||||
<div fxFlex="70" align="left" style="padding: 10px !important;">{{pageTitle}}</div>
|
||||
<div fxFlex="30" align="end" style="padding: 10px !important;">
|
||||
<button mat-raised-button mat-icon-button class="mr-1 mb-1 hover-icon" type="button" matTooltip="Close" matTooltipPosition="right" mat-dialog-close><mat-icon>close</mat-icon></button>
|
||||
|
||||
</div>
|
||||
</h2>
|
||||
|
||||
<mat-dialog-content>
|
||||
<mat-card *ngFor="let companyList of existCompanyList">
|
||||
<mat-card-header>
|
||||
<mat-card-title class="p-text">{{companyList.company_name | titlecase}}</mat-card-title>
|
||||
</mat-card-header>
|
||||
<mat-card-content>
|
||||
<div fxLayout="row wrap" class="child_mat_card">
|
||||
<mat-card fxFlex.xs="80" fxFlex.sm="80" fxFlex.md="40" fxFlex.lg="32" fxFlex.xl="33" *ngFor="let formButton of companyList.form_status;let quesIndex=index" [ngStyle]="{'background-color':formButton.isAnswered == false ? '#fff' : '#4caf50' ,'color':'#fff'}" (click)="OnSelectBusinessGroupForms(formButton, companyList)">
|
||||
<mat-card-header>
|
||||
<span style="padding: 17px 14px 3px 15px !important;border-radius: 0px 0px 0px 15px!important;width: 50px !important;" class="menu-badge mat-purple ng-star-inserted" align="center">{{quesIndex+1}}</span>
|
||||
<div fxFlex="100" align="left" style="padding:15px !important;">
|
||||
{{ formButton.form_name }}
|
||||
</div>
|
||||
</mat-card-header>
|
||||
</mat-card>
|
||||
</div>
|
||||
</mat-card-content>
|
||||
</mat-card>
|
||||
|
||||
</mat-dialog-content>
|
||||
<notifier-container></notifier-container>
|
||||
@ -0,0 +1,33 @@
|
||||
.paragraph_change {
|
||||
color: #fff !important;
|
||||
background-color: #e00201 !important;
|
||||
}
|
||||
|
||||
.p-text {
|
||||
color:#e00201 !important;
|
||||
font-weight: bold;
|
||||
}
|
||||
::ng-deep .mat-card-header-text{
|
||||
margin:0px !important;
|
||||
}
|
||||
.mat-purple{
|
||||
background-color: gray !important;
|
||||
}
|
||||
.cdk-global-overlay-wrapper{
|
||||
justify-content: center !important;
|
||||
}
|
||||
|
||||
$base-card-box-shadow:1.5px 2.6px 24px 0 rgba(0, 35, 136, 0.08) !important;
|
||||
mat-card .child_mat_card > mat-card {
|
||||
border-radius: 0px 0px 0px 15px;
|
||||
box-shadow: $base-card-box-shadow;
|
||||
transform: scale(0.95);
|
||||
transition: box-shadow 0.5s, transform 0.5s;
|
||||
&:hover {
|
||||
cursor: pointer;
|
||||
// background-color: #e00201 !important;
|
||||
transform: scale(1);
|
||||
box-shadow: 5px 20px 30px rgba(0, 0, 0, 0.2);
|
||||
}
|
||||
|
||||
}
|
||||
@ -0,0 +1,25 @@
|
||||
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
|
||||
|
||||
import { BusinessInfoGroupComponent } from './business-info-group.component';
|
||||
|
||||
describe('BusinessInfoGroupComponent', () => {
|
||||
let component: BusinessInfoGroupComponent;
|
||||
let fixture: ComponentFixture<BusinessInfoGroupComponent>;
|
||||
|
||||
beforeEach(async(() => {
|
||||
TestBed.configureTestingModule({
|
||||
declarations: [ BusinessInfoGroupComponent ]
|
||||
})
|
||||
.compileComponents();
|
||||
}));
|
||||
|
||||
beforeEach(() => {
|
||||
fixture = TestBed.createComponent(BusinessInfoGroupComponent);
|
||||
component = fixture.componentInstance;
|
||||
fixture.detectChanges();
|
||||
});
|
||||
|
||||
it('should create', () => {
|
||||
expect(component).toBeTruthy();
|
||||
});
|
||||
});
|
||||
@ -0,0 +1,110 @@
|
||||
import { Component,OnInit,Inject,Input} from '@angular/core';
|
||||
import { NotifierService } from 'angular-notifier';
|
||||
import {MatDialog,MatDialogRef,MAT_DIALOG_DATA, MatTableDataSource} from '@angular/material';
|
||||
/** Service */
|
||||
import { PdTrigerService } from './../../../../../pd-service/pd-triger.service';
|
||||
import {ActivatedRoute, Router} from "@angular/router";
|
||||
import {SupplierInfoComponent} from './../../forms/supplier-info/supplier-info.component';
|
||||
import {ClientInfoComponent} from './../../forms/client-info/client-info.component';
|
||||
import {StockComponent} from './../../forms/stock/stock.component';
|
||||
import {FinancialInfoComponent} from './../../forms/financial-info/financial-info.component';
|
||||
import {BusinessInfoComponent} from './../../forms/business-info/business-info.component';
|
||||
|
||||
@Component({
|
||||
selector: 'app-business-info-group',
|
||||
templateUrl: './business-info-group.component.html',
|
||||
styleUrls: ['./business-info-group.component.scss']
|
||||
})
|
||||
export class BusinessInfoGroupComponent implements OnInit {
|
||||
pageTitle: string ="Business Informations";
|
||||
existCompanyList: any = [];
|
||||
pdid: number;
|
||||
form_id: number;
|
||||
constructor(notifier: NotifierService,
|
||||
private route: ActivatedRoute,
|
||||
private router: Router,
|
||||
private _pd: PdTrigerService,
|
||||
@Inject(MAT_DIALOG_DATA) public pd_all_details: any, private dialog: MatDialog) {
|
||||
this.pdid = this.pd_all_details.pdmaster_details.pd_id;
|
||||
this.form_id = 13;
|
||||
}
|
||||
|
||||
ngOnInit() {
|
||||
this.getCompanyListForBusiness();
|
||||
}
|
||||
getCompanyListForBusiness(): void{
|
||||
this._pd.getCompaniesListsForBusiness(this.pdid).subscribe(data=>{
|
||||
if(data.dataStatus){
|
||||
this.existCompanyList = data.records.filter(val =>val.is_active);
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
// direct form based questions
|
||||
OnSelectBusinessGroupForms(details: any, company: any) {
|
||||
this.pd_all_details.company_id =company.company_order_id;
|
||||
this.pd_all_details.company_name =company.company_name;
|
||||
if(details.form_id==1){
|
||||
const dialogRef = this.dialog.open(SupplierInfoComponent, {
|
||||
data: this.pd_all_details,
|
||||
position: { right: '0'},
|
||||
width:'80%',
|
||||
disableClose: true
|
||||
});
|
||||
dialogRef.afterClosed()
|
||||
.subscribe(dataresult => {
|
||||
this.getCompanyListForBusiness();
|
||||
});
|
||||
}
|
||||
else if(details.form_id==2){
|
||||
const dialogRef = this.dialog.open(ClientInfoComponent, {
|
||||
data: this.pd_all_details,
|
||||
position: { right: '0'},
|
||||
width:'80%',
|
||||
disableClose: true
|
||||
});
|
||||
dialogRef.afterClosed()
|
||||
.subscribe(dataresult => {
|
||||
this.getCompanyListForBusiness();
|
||||
});
|
||||
}
|
||||
else if(details.form_id==11){
|
||||
const dialogRef = this.dialog.open(StockComponent, {
|
||||
data: this.pd_all_details,
|
||||
position: { right: '0'},
|
||||
width:'80%',
|
||||
disableClose: true
|
||||
});
|
||||
dialogRef.afterClosed()
|
||||
.subscribe(dataresult => {
|
||||
this.getCompanyListForBusiness();
|
||||
});
|
||||
}
|
||||
else if(details.form_id==13){
|
||||
const dialogRef = this.dialog.open(BusinessInfoComponent, {
|
||||
data: this.pd_all_details,
|
||||
position: { right: '0'},
|
||||
width:'80%',
|
||||
disableClose: true
|
||||
});
|
||||
dialogRef.afterClosed()
|
||||
.subscribe(dataresult => {
|
||||
this.getCompanyListForBusiness();
|
||||
});
|
||||
}
|
||||
else if(details.form_id==14){
|
||||
const dialogRef = this.dialog.open(FinancialInfoComponent, {
|
||||
data: this.pd_all_details,
|
||||
position: { right: '0'},
|
||||
width:'80%',
|
||||
disableClose: true
|
||||
});
|
||||
dialogRef.afterClosed()
|
||||
.subscribe(dataresult => {
|
||||
this.getCompanyListForBusiness();
|
||||
});
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
@ -26,8 +26,8 @@
|
||||
<mat-form-field style="width: 45%;">
|
||||
<mat-select placeholder="Name in Which The Business is Run"
|
||||
formControlName="profession_name" required>
|
||||
<mat-option value="{{company}}" *ngFor="let company of existCompanyList">{{company | titlecase}}</mat-option>
|
||||
<mat-option value="Others">Others</mat-option>
|
||||
<mat-option [value]="company.company_name" *ngFor="let company of existCompanyList">{{company.company_name | titlecase}}</mat-option>
|
||||
<!-- <mat-option value="Others">Others</mat-option> -->
|
||||
</mat-select>
|
||||
</mat-form-field>
|
||||
<mat-form-field style="width: 45%;" *ngIf="businessForm.controls.profession_name.value=='Others'">
|
||||
|
||||
@ -32,8 +32,10 @@ import {DatePipe } from '@angular/common';
|
||||
export class BusinessInfoComponent implements OnInit {
|
||||
pipe = new DatePipe('en-US');
|
||||
pdid: number;
|
||||
company_id: String;
|
||||
company_name: String;
|
||||
form_id: number;
|
||||
pageTitle: string ="Business Details";
|
||||
pageTitle: string ="Business Information";
|
||||
relationData: any = [];
|
||||
companyRelationShipList: any =[];
|
||||
//industryData: any = [];
|
||||
@ -60,6 +62,8 @@ export class BusinessInfoComponent implements OnInit {
|
||||
@Inject(MAT_DIALOG_DATA) public pd_all_details: any, private dialog: MatDialog) {
|
||||
//this.adapter.setLocale('fr');
|
||||
this.pdid = this.pd_all_details.pdmaster_details.pd_id;
|
||||
this.company_id = this.pd_all_details.company_id;
|
||||
this.company_name = this.pd_all_details.company_name;
|
||||
this.applicants = this.pd_all_details.pdapplicants_detials;
|
||||
this.form_id = 13;
|
||||
this.notifier = notifier;
|
||||
@ -101,6 +105,7 @@ export class BusinessInfoComponent implements OnInit {
|
||||
let params: any = {};
|
||||
params.pd_id = this.pdid;
|
||||
params.pd_form_id = this.form_id;
|
||||
params.company_id = this.company_id;
|
||||
this._pd.retriveForm(params).subscribe(data => {
|
||||
let businessVal = data.records;
|
||||
let constVal: any;
|
||||
@ -163,6 +168,7 @@ export class BusinessInfoComponent implements OnInit {
|
||||
|
||||
businessVal.pdid = this.pdid;
|
||||
businessVal.formid = this.form_id;
|
||||
businessVal.company_id = this.company_id;
|
||||
businessVal.fk_createdby = this.pdid;
|
||||
//businessVal.designation = DesgnArray;
|
||||
businessVal.partners = PartnrArray;
|
||||
@ -562,8 +568,9 @@ export class BusinessInfoComponent implements OnInit {
|
||||
this.businessForm = this.fb.group({
|
||||
pdid: this.pdid,
|
||||
formid: this.form_id,
|
||||
company_id: this.company_id,
|
||||
fk_createdby: this.pdid,
|
||||
profession_name: ['', Validators.compose([Validators.required])],
|
||||
profession_name: [this.company_name, Validators.compose([Validators.required])],
|
||||
business_entity_type: ['', Validators.compose([Validators.required])],
|
||||
business_years: ['', Validators.compose([Validators.required])],
|
||||
business_month: ['', Validators.compose([Validators.required])],
|
||||
@ -1266,7 +1273,7 @@ export class BusinessInfoComponent implements OnInit {
|
||||
getCompanyListForBusiness(): void{
|
||||
this._pd.getCompaniesListsForBusiness(this.pdid).subscribe(data=>{
|
||||
if(data.dataStatus){
|
||||
this.existCompanyList = data.records;
|
||||
this.existCompanyList = data.records.filter(val =>val.is_active && val.company_order_id==this.company_id);
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
@ -35,7 +35,7 @@ export class ClientInfoComponent implements OnInit {
|
||||
//@Input() pdid: number;
|
||||
pdid: string;
|
||||
form_id: number;
|
||||
|
||||
company_id: string;
|
||||
public _supplierQuesFrom: FormGroup;
|
||||
public submitted = false;
|
||||
|
||||
@ -78,6 +78,7 @@ export class ClientInfoComponent implements OnInit {
|
||||
@Inject(MAT_DIALOG_DATA) public pd_all_details: any) {
|
||||
this.pdid = this.pd_all_details.pdmaster_details.pd_id;
|
||||
this.form_id = 2;
|
||||
this.company_id = this.pd_all_details.company_id;
|
||||
this.notifier = notifier;
|
||||
}
|
||||
public viewerOptions: any = {
|
||||
@ -103,8 +104,7 @@ export class ClientInfoComponent implements OnInit {
|
||||
noRecordsFound: Boolean = false;
|
||||
errorMessage: any = '';
|
||||
ngOnInit() {
|
||||
|
||||
this.pdTrigerService.getTypeofActivityForSuppliedInfoForm(this.pdid).subscribe(data => {
|
||||
this.pdTrigerService.getTypeofActivityForSuppliedInfoForm(this.pdid,this.company_id).subscribe(data => {
|
||||
if(data.dataStatus){
|
||||
// let datas = {
|
||||
// "profession_name": "Others",
|
||||
@ -151,7 +151,11 @@ export class ClientInfoComponent implements OnInit {
|
||||
|
||||
retaildTradingForm: Boolean = false;
|
||||
initFormLoadDetails(record) {
|
||||
this.pdTrigerService.getPDFormDetailsWithID(this.pdid, '2').subscribe(
|
||||
let params: any = {};
|
||||
params.pd_id = this.pdid;
|
||||
params.pd_form_id = this.form_id;
|
||||
params.company_id = this.company_id;
|
||||
this.pdTrigerService.retriveForm(params).subscribe(
|
||||
data => {
|
||||
if (data.dataStatus) {
|
||||
let dataForm = data.records;
|
||||
@ -159,6 +163,7 @@ export class ClientInfoComponent implements OnInit {
|
||||
this._supplierQuesFrom = this._formBuilder.group({
|
||||
pdid: [this.pdid],
|
||||
formid: ['2'],
|
||||
company_id:[this.company_id],
|
||||
manufacturing_details: this._formBuilder.array([this.manufacturingFormCreation(record)]),
|
||||
trade_details: this._formBuilder.array([this.tradingFormCreation(record)]),
|
||||
service_provider_details: this._formBuilder.array([this.serviceProviderFormCreation(record)]),
|
||||
@ -244,6 +249,7 @@ export class ClientInfoComponent implements OnInit {
|
||||
this._supplierQuesFrom = this._formBuilder.group({
|
||||
pdid: [this.pdid],
|
||||
formid: ['2'],
|
||||
company_id:[this.company_id],
|
||||
manufacturing_details: this._formBuilder.array([this.manufacturingFormCreation(record)]),
|
||||
trade_details: this._formBuilder.array([this.tradingFormCreation(record)]),
|
||||
service_provider_details: this._formBuilder.array([this.serviceProviderFormCreation(record)]),
|
||||
|
||||
@ -33,6 +33,7 @@ export class FinancialInfoComponent implements OnInit {
|
||||
pageTitle: string ="Financial Information";
|
||||
pdid: string;
|
||||
form_id: number;
|
||||
company_id: string;
|
||||
public financialForm: FormGroup;
|
||||
private notifier: NotifierService;
|
||||
SalesStatement : any = [];
|
||||
@ -57,6 +58,7 @@ export class FinancialInfoComponent implements OnInit {
|
||||
@Inject(MAT_DIALOG_DATA) public pd_all_details: any) {
|
||||
this.pdid = this.pd_all_details.pdmaster_details.pd_id;
|
||||
this.form_id = 14;
|
||||
this.company_id =this.pd_all_details.company_id;
|
||||
this.notifier = notifier;
|
||||
}
|
||||
public viewerOptions: any = {
|
||||
@ -84,6 +86,7 @@ export class FinancialInfoComponent implements OnInit {
|
||||
let params: any = {};
|
||||
params.pd_id = this.pdid;
|
||||
params.pd_form_id = this.form_id;
|
||||
params.company_id = this.company_id;
|
||||
this._pd.retriveForm(params).subscribe(value => {
|
||||
const financial_date = <FormArray>this.financialForm.controls['date_per_financial'];
|
||||
const estimated_val = <FormArray>this.financialForm.controls['estimated_value'];
|
||||
@ -110,7 +113,6 @@ export class FinancialInfoComponent implements OnInit {
|
||||
financial_date.push(this.createDate(''));
|
||||
}
|
||||
if (result_val.length > 0) {
|
||||
console.log(result_val);
|
||||
result_val.forEach((val,index) => {
|
||||
//console.log('dedrf',val.estimate_annual_sale);
|
||||
this.AV_annualSalesInwords[index] = this._pd.convertNumberToWords(val.estimate_annual_sale);
|
||||
@ -124,6 +126,7 @@ export class FinancialInfoComponent implements OnInit {
|
||||
}
|
||||
retriveData.pdid = this.pdid;
|
||||
retriveData.formid = this.form_id;
|
||||
retriveData.company_id = this.company_id;
|
||||
retriveData.fk_createdby = this.pdid;
|
||||
this.financialForm.setValue(retriveData);
|
||||
} else {
|
||||
@ -136,6 +139,7 @@ export class FinancialInfoComponent implements OnInit {
|
||||
this.financialForm = this.fb.group({
|
||||
pdid: this.pdid,
|
||||
formid: this.form_id,
|
||||
company_id: this.company_id,
|
||||
fk_createdby: this.pdid,
|
||||
financial_remarks: [''],
|
||||
staring_financial_year : ['',Validators.compose([Validators.minLength(4),Validators.maxLength(4)])],
|
||||
@ -247,7 +251,6 @@ export class FinancialInfoComponent implements OnInit {
|
||||
}
|
||||
|
||||
selectedType(e: any): void {
|
||||
console.log(e);
|
||||
if(e.value == 'yes'){
|
||||
let startingYear = this.financialForm.controls['staring_financial_year'].value;
|
||||
let totalFinYear = this.financialForm.controls['total_financial_year'].value;
|
||||
@ -260,7 +263,6 @@ export class FinancialInfoComponent implements OnInit {
|
||||
}
|
||||
|
||||
if(array.length > 0 ){
|
||||
console.log(array.length);
|
||||
|
||||
array.value.forEach((val,index)=>{
|
||||
let vals = {
|
||||
@ -325,32 +327,23 @@ export class FinancialInfoComponent implements OnInit {
|
||||
// }
|
||||
// }
|
||||
calFinAnnualSale(index,detail){
|
||||
//alert('FIn Annual Sales Data');
|
||||
console.log(index);
|
||||
console.log()
|
||||
let annual_sale = detail.value.financial_annual_sale;
|
||||
if (index != 0) {
|
||||
let array = <FormArray>this.financialForm.controls['date_per_financial'];
|
||||
let prev_annual_sale = array.value[index-1].financial_annual_sale;
|
||||
let annual_sale_variation = (( annual_sale - prev_annual_sale)/prev_annual_sale) * 100 ;
|
||||
detail.controls.financial_annualsales_variation.setValue(annual_sale_variation.toFixed(2));
|
||||
console.log('annual sales variation in %',annual_sale_variation);
|
||||
}
|
||||
}
|
||||
|
||||
calculateEstimationAnnualSale(index,detail){
|
||||
//alert('Function Inside');
|
||||
console.log(detail);
|
||||
let annual_sale = detail.value.estimate_annual_sale;
|
||||
console.log(annual_sale);
|
||||
console.log(index);
|
||||
// console.log(annual_sale);
|
||||
if (index != 0) {
|
||||
let array = <FormArray>this.financialForm.controls['estimated_value'];
|
||||
let prev_annual_sale = array.value[index-1].estimate_annual_sale;
|
||||
let annual_sale_variation = (( annual_sale - prev_annual_sale)/prev_annual_sale) * 100 ;
|
||||
detail.controls.estimate_annualsales_variation.setValue(annual_sale_variation.toFixed(2));
|
||||
console.log('estimate annual sales variation in %',annual_sale_variation);
|
||||
}
|
||||
}
|
||||
|
||||
@ -362,25 +355,16 @@ export class FinancialInfoComponent implements OnInit {
|
||||
if ( (profit != '' || loss != '') && index != 0) {
|
||||
|
||||
let array = <FormArray>this.financialForm.controls['date_per_financial'];
|
||||
|
||||
console.log('Profit',profit);
|
||||
console.log(Math.abs(profit));
|
||||
|
||||
let prev_profit = array.value[index - 1].financial_net_profit != '' ? array.value[index - 1].financial_net_profit : 0;
|
||||
console.log('Profitpre',prev_profit);
|
||||
let prev_loss = array.value[index - 1].financial_net_loss !='' ? array.value[index - 1].financial_net_loss : 0 ;
|
||||
let prev_year = array.value[index - 1].financial_year;
|
||||
let prev_annual_sale = array.value[index-1].financial_annual_sale;
|
||||
console.log('loss',loss);
|
||||
loss = loss != 0 ? loss * (-1) : loss;
|
||||
console.log('-1 loss',loss);
|
||||
console.log('pre_loss',prev_loss);
|
||||
prev_loss = prev_loss != 0 ? prev_loss * (-1) : prev_loss ;
|
||||
console.log('-1 pre loss',prev_loss);
|
||||
console.log(Math.abs(profit));
|
||||
//let variation2 = ((()))
|
||||
let variation = (((profit != '' ? profit : loss ) - (prev_profit != '' ? prev_profit : prev_loss ))/ (prev_profit != '' ? Math.abs(prev_profit) : Math.abs(prev_loss))) * 100;
|
||||
//console.log('console.log(Math.abs(profit));',Math.abs(variation));
|
||||
console.log(variation);
|
||||
// let variation ;
|
||||
// if(profit != ''){
|
||||
// variation = (((profit != '' ? profit : loss ) - ( prev_profit != '' ? prev_profit : prev_loss ))/ (prev_profit != '' ? prev_profit : prev_loss)) * 100 * (profit != '' ? (1) : (-1)) ;
|
||||
@ -395,7 +379,6 @@ export class FinancialInfoComponent implements OnInit {
|
||||
detail.controls.financial_variation.setValue(variation.toFixed(2));
|
||||
|
||||
//Increase in Sales in FY 2017-18 over sales in FY 2016-17 is 11.11%
|
||||
console.log('variation in %',variation);
|
||||
|
||||
// this.SalesStatement[index] = ( variation <= 0 ? 'Decreases ' : 'Increases ' ) + 'in Sales in FY ' + curr_year + ' Over Sales in FY '+ prev_year + ' is ' + variation.toFixed(2) + '%';
|
||||
// console.log('this.SlesStatement',this.SalesStatement);
|
||||
@ -437,7 +420,6 @@ export class FinancialInfoComponent implements OnInit {
|
||||
// }
|
||||
|
||||
calMargin(index, detail) {
|
||||
console.log('detail', detail);
|
||||
// let array = <FormArray>this.financialForm.controls['date_per_financial'];
|
||||
let salary = detail.value.financial_annual_sale;
|
||||
// let prev_annual_sale = array.value[index-1].financial_annual_sale;
|
||||
@ -499,7 +481,6 @@ export class FinancialInfoComponent implements OnInit {
|
||||
if ( (profit != '' || loss != '') && index != 0) {
|
||||
|
||||
let array = <FormArray>this.financialForm.controls['estimated_value'];
|
||||
console.log(array.value[index - 1].financial_net_profit);
|
||||
|
||||
let prev_profit = array.value[index - 1].estimate_net_profit != '' ? array.value[index - 1].estimate_net_profit : 1;
|
||||
let prev_loss = array.value[index - 1].estimate_net_loss !='' ? array.value[index - 1].estimate_net_loss : 1;
|
||||
@ -521,9 +502,7 @@ export class FinancialInfoComponent implements OnInit {
|
||||
}
|
||||
|
||||
calMarginVal(index, detail) {
|
||||
console.log('Margin Estimate VAR',detail);
|
||||
let salary = detail.value.estimate_annual_sale;
|
||||
console.log('Margin Estimate Vsalary',salary);
|
||||
|
||||
// if (salary != '' && profit != '') {
|
||||
// let margin = profit / salary * 100;
|
||||
@ -534,23 +513,16 @@ export class FinancialInfoComponent implements OnInit {
|
||||
if(detail.value.estimate_profit_or_loss == 1){
|
||||
|
||||
let profit = detail.value.estimate_net_profit;
|
||||
console.log('if Margin Profit',profit);
|
||||
|
||||
if (salary != '' && profit != '') {
|
||||
console.log('if if Margin Estimate salary',salary);
|
||||
console.log('if if Margin Profit',profit);
|
||||
let margin = profit / salary * 100;
|
||||
console.log('margin',margin);
|
||||
detail.controls.estimate_margin_of_profit.setValue(margin.toFixed(2));
|
||||
}
|
||||
}
|
||||
else if (detail.value.estimate_profit_or_loss == 2){
|
||||
|
||||
let loss = detail.value.estimate_net_loss;
|
||||
console.log('else if Margin loss',loss);
|
||||
if (salary != '' && loss != '') {
|
||||
console.log('elseif if Margin Estimate salary',salary);
|
||||
console.log('alseif if Margin loss',loss);
|
||||
let margin = (loss / salary) * 100 * (-1);
|
||||
detail.controls.estimate_margin_of_loss.setValue(margin.toFixed(2));
|
||||
|
||||
@ -588,7 +560,6 @@ export class FinancialInfoComponent implements OnInit {
|
||||
// }
|
||||
|
||||
calProfitAndLossVal( i, detail) {
|
||||
console.log(detail);
|
||||
let salary = detail.value.estimate_annual_sale;
|
||||
if(detail.value.estimate_profit_or_loss == 1){
|
||||
let margin_profit = detail.value.estimate_margin_of_profit;
|
||||
@ -682,9 +653,7 @@ export class FinancialInfoComponent implements OnInit {
|
||||
// return;
|
||||
// }
|
||||
let records = this.financialForm.value;
|
||||
console.log('data', records);
|
||||
this._pd.saveForm(records).subscribe(data => {
|
||||
console.log('data', data);
|
||||
this.notifier.notify('success', 'Saved Successfully.');
|
||||
//this.dialogRef.close();
|
||||
}, error => {
|
||||
@ -715,10 +684,6 @@ export class FinancialInfoComponent implements OnInit {
|
||||
|
||||
/** To Convert Amount into Words */
|
||||
inWords(e,i,flag:number){
|
||||
|
||||
// console.log(e);
|
||||
// console.log(i);
|
||||
// console.log(flag);
|
||||
|
||||
switch(flag){
|
||||
case 1 :
|
||||
|
||||
@ -527,7 +527,7 @@
|
||||
</form>
|
||||
</div>
|
||||
|
||||
<notifier-container></notifier-container>
|
||||
<!-- <notifier-container></notifier-container> -->
|
||||
<!-- <mat-card style="padding: 12px;">
|
||||
<p>Stock Details</p>
|
||||
<form [formGroup]="stockForms" class="address"> -->
|
||||
|
||||
@ -22,6 +22,7 @@ export class StockComponent implements OnInit {
|
||||
pageTitle: string ="Stock Details";
|
||||
pdid: number;
|
||||
form_id: number;
|
||||
company_id: string;
|
||||
public stockForms: FormGroup;
|
||||
private notifier: NotifierService;
|
||||
public uomData : any = [];
|
||||
@ -50,6 +51,7 @@ export class StockComponent implements OnInit {
|
||||
private _pd: PdTrigerService,@Inject(MAT_DIALOG_DATA) public pd_all_details: any) {
|
||||
this.pdid = this.pd_all_details.pdmaster_details.pd_id;
|
||||
this.form_id = 11;
|
||||
this.company_id = this.pd_all_details.company_id
|
||||
this.notifier = notifier;
|
||||
}
|
||||
public viewerOptions: any = {
|
||||
@ -82,7 +84,7 @@ export class StockComponent implements OnInit {
|
||||
// })
|
||||
|
||||
//this._pd.getTypeofActivityForSuppliedInfoForm(this.pdid).subscribe(
|
||||
this._pd.stockFormAccess({pd_id:this.pdid}).subscribe(data => {
|
||||
this._pd.stockFormAccess({pd_id:this.pdid,company_id:this.company_id}).subscribe(data => {
|
||||
|
||||
if(data.dataStatus == true){
|
||||
let datas = data.records;
|
||||
@ -109,21 +111,20 @@ export class StockComponent implements OnInit {
|
||||
}
|
||||
|
||||
public initstockForms(record){
|
||||
console.log(record);
|
||||
let params: any = {};
|
||||
params.pd_id = this.pdid;
|
||||
params.pd_form_id = this.form_id;
|
||||
|
||||
params.company_id = this.company_id;
|
||||
this._pd.retriveForm(params).subscribe(value => {
|
||||
if (value.status == 200) {
|
||||
let dataForm = value.records;
|
||||
|
||||
|
||||
if(dataForm !== undefined) {
|
||||
console.log(dataForm);
|
||||
this.stockForms = this.fb.group({
|
||||
pdid: [this.pdid],
|
||||
formid: [this.form_id],
|
||||
company_id: [this.company_id],
|
||||
stock_remarks: [''],
|
||||
manufacturing_details: this.fb.array([this.manufacturingFormCreation(record)]),
|
||||
retail_details : this.fb.array([this.retailFormCreation(record)]),
|
||||
@ -131,7 +132,6 @@ export class StockComponent implements OnInit {
|
||||
});
|
||||
|
||||
let arr = record.filter(data => data.type_of_activity_id == 1);
|
||||
console.log(133,arr.length);
|
||||
if(arr.length > 0) {
|
||||
// console.log(1,dataForm);
|
||||
// console.log(164,dataForm.manufacturing_details);
|
||||
@ -257,6 +257,7 @@ export class StockComponent implements OnInit {
|
||||
this.stockForms = this.fb.group({
|
||||
pdid: [this.pdid],
|
||||
formid: [this.form_id],
|
||||
company_id: [this.company_id],
|
||||
stock_remarks: [''],
|
||||
manufacturing_details: this.fb.array([this.manufacturingFormCreation(record)]),
|
||||
retail_details : this.fb.array([this.retailFormCreation(record)]),
|
||||
@ -320,11 +321,8 @@ export class StockComponent implements OnInit {
|
||||
|
||||
manufacturingForm: Boolean = false;
|
||||
manufacturingFormCreation(record) {
|
||||
console.log(record);
|
||||
let arr = record.filter(data => data.type_of_activity_id == 1);
|
||||
console.log(arr);
|
||||
if (arr.length > 0) {
|
||||
console.log(arr.length);
|
||||
this.manufacturingForm = true;
|
||||
return this.fb.group({
|
||||
manufacturing_raw_materials: this.fb.array([]),
|
||||
|
||||
@ -37,7 +37,7 @@ export class SupplierInfoComponent implements OnInit {
|
||||
//@Input() pdid: number;
|
||||
pdid: string;
|
||||
form_id: number;
|
||||
|
||||
company_id: string;
|
||||
public _supplierQuesFrom: FormGroup;
|
||||
public submitted = false;
|
||||
|
||||
@ -51,6 +51,7 @@ export class SupplierInfoComponent implements OnInit {
|
||||
@Inject(MAT_DIALOG_DATA) public pd_all_details: any) {
|
||||
this.pdid = this.pd_all_details.pdmaster_details.pd_id;
|
||||
this.form_id = 1;
|
||||
this.company_id = this.pd_all_details.company_id
|
||||
this.notifier = notifier;
|
||||
}
|
||||
public viewerOptions: any = {
|
||||
@ -76,7 +77,7 @@ export class SupplierInfoComponent implements OnInit {
|
||||
noRecordsFound: Boolean = false;
|
||||
errorMessage: any = '';
|
||||
ngOnInit() {
|
||||
this.pdTrigerService.getTypeofActivityForSuppliedInfoForm(this.pdid).subscribe(data => {
|
||||
this.pdTrigerService.getTypeofActivityForSuppliedInfoForm(this.pdid, this.company_id).subscribe(data => {
|
||||
if(data.dataStatus){
|
||||
// let datas = {
|
||||
// "profession_name": "Others",
|
||||
@ -116,8 +117,12 @@ export class SupplierInfoComponent implements OnInit {
|
||||
|
||||
serviceProviderForm: Boolean = false;
|
||||
initFormLoadDetails(record) {
|
||||
let params: any = {};
|
||||
params.pd_id = this.pdid;
|
||||
params.pd_form_id = this.form_id;
|
||||
params.company_id = this.company_id;
|
||||
// alert(JSON.stringify(record));
|
||||
this.pdTrigerService.getPDFormDetailsWithID(this.pdid, '1').subscribe(
|
||||
this.pdTrigerService.retriveForm(params).subscribe(
|
||||
data => {
|
||||
if(data.dataStatus){
|
||||
let dataForm = data.records;
|
||||
@ -125,6 +130,7 @@ export class SupplierInfoComponent implements OnInit {
|
||||
this._supplierQuesFrom = this._formBuilder.group({
|
||||
pdid: [this.pdid],
|
||||
formid: ['1'],
|
||||
company_id: [this.company_id],
|
||||
manufacturing_details: this._formBuilder.array([this.manufacturingFormCreation(record)]),
|
||||
trade_details: this._formBuilder.array([this.tradingFormCreation(record)]),
|
||||
supplier_info_form_remark: [dataForm.supplier_info_form_remark || null]
|
||||
@ -154,6 +160,7 @@ export class SupplierInfoComponent implements OnInit {
|
||||
this._supplierQuesFrom = this._formBuilder.group({
|
||||
pdid: [this.pdid],
|
||||
formid: ['1'],
|
||||
company_id: [this.company_id],
|
||||
manufacturing_details: this._formBuilder.array([this.manufacturingFormCreation(record)]),
|
||||
trade_details: this._formBuilder.array([this.tradingFormCreation(record)]),
|
||||
supplier_info_form_remark: [dataForm.supplier_info_form_remark || null]
|
||||
|
||||
@ -26,7 +26,7 @@
|
||||
<span style="padding: 2px 9px 3px 9px !important;" class="menu-badge mat-purple ng-star-inserted" align="center">{{quesIndex+1}}</span>
|
||||
</div> -->
|
||||
</mat-card-header>
|
||||
</mat-card>
|
||||
</mat-card>
|
||||
</div>
|
||||
</mat-card-content>
|
||||
<mat-card-actions align="end">
|
||||
|
||||
@ -26,6 +26,7 @@ import {LoanDetailsComponent} from './forms/loan-details/loan-details.component'
|
||||
import {GeneralInfoComponent} from './forms/general-info/general-info.component';
|
||||
import {NeighbourHoodComponent} from './forms/neighbour-hood/neighbour-hood.component';
|
||||
import {FinalRemarksComponent} from './forms/final-remarks/final-remarks.component';
|
||||
import { BusinessInfoGroupComponent } from './forms/business-info-group/business-info-group.component';
|
||||
|
||||
@Component({
|
||||
selector: 'app-start-pd',
|
||||
@ -314,7 +315,7 @@ export class StartPdComponent implements OnInit, OnDestroy {
|
||||
});
|
||||
}else
|
||||
if(this.selectedFormsCategory.form_id==13){
|
||||
const dialogRef = this.dialog.open(BusinessInfoComponent, {
|
||||
const dialogRef = this.dialog.open(BusinessInfoGroupComponent, {
|
||||
data: this.pdFullDetails,
|
||||
position: { right: '0'},
|
||||
width:'80%',
|
||||
|
||||
@ -89,6 +89,7 @@ import { FinalRemarksComponent } from './list-pd/start-pd/forms/final-remarks/fi
|
||||
import { BusinessOtherFamilyMemberComponent } from './list-pd/start-pd/forms/dialogue/business-other-family-member/business-other-family-member.component';
|
||||
import { QcReviewComponent } from './list-pd/pd-report/qc-review/qc-review.component';
|
||||
import { SharedModule } from "app/shared/shared.module";
|
||||
import { BusinessInfoGroupComponent } from './list-pd/start-pd/forms/business-info-group/business-info-group.component';
|
||||
|
||||
/**
|
||||
* Custom angular notifier options
|
||||
@ -266,7 +267,7 @@ const pdCustomNotifierOptions: NotifierOptions = {
|
||||
// AgmCoreModule.forRoot({apiKey: 'AIzaSyBtdO5k6CRntAMJCF-H5uZjTCoSGX95cdk'}), OwlDateTimeModule,
|
||||
// OwlNativeDateTimeModule,
|
||||
// ],
|
||||
declarations: [RentalInfoComponent, TelePdAllocationComponent, FinancialInfoComponent, BusinessInfoComponent, EmploymentInfoComponent, StockComponent, BankingDetailsComponent, ListPdComponent, FamilyDetailsComponent, AddressComponent, ManagePdComponent, MapPdViewComponent, AddPdComponent, ViewPdComponent, PdAllocationComponent, SmartPdAllocationComponent, SchedulePdComponent, EditPdApplicantComponent, EditPdMasterComponent, StartPdComponent, InprogressPdComponent, AllPdComponent, ScheduledPdComponent, CompletedPdComponent, QcCompletedPdComponent, ClientInfoComponent, CurrentLoanComponent, AssetsInfoComponent, LoanDetailsComponent, OtherIncomeComponent, SupplierInfoComponent, PersonalInfoComponent, LenderRepresentativeComponent, PdReportComponent, AssessedIncomeComponent, AllocationViewMoreComponent, PdRequirementComponent, GeneralInfoComponent, ModelEditPdReportComponent, OtherApplicantDetailsComponent, NeighbourHoodComponent, DialogChangeCurrentVenrsion, FinalRemarksComponent, BusinessOtherFamilyMemberComponent, QcReviewComponent],
|
||||
declarations: [RentalInfoComponent, TelePdAllocationComponent, FinancialInfoComponent, BusinessInfoComponent, EmploymentInfoComponent, StockComponent, BankingDetailsComponent, ListPdComponent, FamilyDetailsComponent, AddressComponent, ManagePdComponent, MapPdViewComponent, AddPdComponent, ViewPdComponent, PdAllocationComponent, SmartPdAllocationComponent, SchedulePdComponent, EditPdApplicantComponent, EditPdMasterComponent, StartPdComponent, InprogressPdComponent, AllPdComponent, ScheduledPdComponent, CompletedPdComponent, QcCompletedPdComponent, ClientInfoComponent, CurrentLoanComponent, AssetsInfoComponent, LoanDetailsComponent, OtherIncomeComponent, SupplierInfoComponent, PersonalInfoComponent, LenderRepresentativeComponent, PdReportComponent, AssessedIncomeComponent, AllocationViewMoreComponent, PdRequirementComponent, GeneralInfoComponent, ModelEditPdReportComponent, OtherApplicantDetailsComponent, NeighbourHoodComponent, DialogChangeCurrentVenrsion, FinalRemarksComponent, BusinessOtherFamilyMemberComponent, QcReviewComponent, BusinessInfoGroupComponent],
|
||||
|
||||
// exports: [PdAllocationComponent, SmartPdAllocationComponent, SchedulePdComponent, EditPdApplicantComponent, EditPdMasterComponent, StartPdComponent, CompletedPdComponent, QcCompletedPdComponent],
|
||||
// providers: [PdTrigerService, GetGeometricLocationService],
|
||||
@ -304,13 +305,13 @@ const pdCustomNotifierOptions: NotifierOptions = {
|
||||
OwlNativeDateTimeModule,
|
||||
],
|
||||
// declarations: [ListPdComponent, ManagePdComponent, MapPdViewComponent, AddPdComponent, ViewPdComponent, PdAllocationComponent, SmartPdAllocationComponent, SchedulePdComponent, EditPdApplicantComponent, EditPdMasterComponent, StartPdComponent, InprogressPdComponent, AllPdComponent, ScheduledPdComponent, CompletedPdComponent, QcCompletedPdComponent, ClientInfoComponent, SupplierInfoComponent, PersonalInfoComponent, AssetsInfoComponent],
|
||||
exports: [PdAllocationComponent, SmartPdAllocationComponent, TelePdAllocationComponent, SchedulePdComponent, EditPdApplicantComponent, EditPdMasterComponent, StartPdComponent, CompletedPdComponent, QcCompletedPdComponent, ClientInfoComponent, SupplierInfoComponent, PersonalInfoComponent, CurrentLoanComponent, LoanDetailsComponent, OtherIncomeComponent, AssetsInfoComponent, AddressComponent, FamilyDetailsComponent, BankingDetailsComponent, StockComponent, EmploymentInfoComponent, BusinessInfoComponent, FinancialInfoComponent, LenderRepresentativeComponent,RentalInfoComponent, AssessedIncomeComponent, AllocationViewMoreComponent, GeneralInfoComponent, PdRequirementComponent, OtherApplicantDetailsComponent, NeighbourHoodComponent, BusinessOtherFamilyMemberComponent],
|
||||
exports: [PdAllocationComponent, SmartPdAllocationComponent, TelePdAllocationComponent, SchedulePdComponent, EditPdApplicantComponent, EditPdMasterComponent, StartPdComponent, CompletedPdComponent, QcCompletedPdComponent, ClientInfoComponent, SupplierInfoComponent, PersonalInfoComponent, CurrentLoanComponent, LoanDetailsComponent, OtherIncomeComponent, AssetsInfoComponent, AddressComponent, FamilyDetailsComponent, BankingDetailsComponent, StockComponent, EmploymentInfoComponent, BusinessInfoComponent, FinancialInfoComponent, LenderRepresentativeComponent,RentalInfoComponent, AssessedIncomeComponent, AllocationViewMoreComponent, GeneralInfoComponent, PdRequirementComponent, OtherApplicantDetailsComponent, NeighbourHoodComponent, BusinessOtherFamilyMemberComponent, BusinessInfoGroupComponent],
|
||||
providers: [PdTrigerService, GetGeometricLocationService,{provide: MAT_DATE_LOCALE, useValue: 'en-GB'},
|
||||
{provide: DateAdapter, useClass: MomentDateAdapter, deps: [MAT_DATE_LOCALE]},
|
||||
{provide: MAT_DATE_FORMATS, useValue: MAT_MOMENT_DATE_FORMATS}],
|
||||
|
||||
entryComponents: [PdAllocationComponent, SmartPdAllocationComponent, SchedulePdComponent, EditPdApplicantComponent, EditPdMasterComponent, TelePdAllocationComponent, AllocationViewMoreComponent, PersonalInfoComponent,
|
||||
ClientInfoComponent, SupplierInfoComponent, CurrentLoanComponent, LoanDetailsComponent, OtherIncomeComponent, AssetsInfoComponent, AddressComponent, FamilyDetailsComponent, BankingDetailsComponent, StockComponent, EmploymentInfoComponent, BusinessInfoComponent, FinancialInfoComponent, LenderRepresentativeComponent,RentalInfoComponent, AssessedIncomeComponent, GeneralInfoComponent, PdRequirementComponent, ModelEditPdReportComponent, OtherApplicantDetailsComponent, NeighbourHoodComponent, DialogChangeCurrentVenrsion, FinalRemarksComponent, BusinessOtherFamilyMemberComponent, QcReviewComponent],
|
||||
ClientInfoComponent, SupplierInfoComponent, CurrentLoanComponent, LoanDetailsComponent, OtherIncomeComponent, AssetsInfoComponent, AddressComponent, FamilyDetailsComponent, BankingDetailsComponent, StockComponent, EmploymentInfoComponent, BusinessInfoComponent, FinancialInfoComponent, LenderRepresentativeComponent,RentalInfoComponent, AssessedIncomeComponent, GeneralInfoComponent, PdRequirementComponent, ModelEditPdReportComponent, OtherApplicantDetailsComponent, NeighbourHoodComponent, DialogChangeCurrentVenrsion, FinalRemarksComponent, BusinessOtherFamilyMemberComponent, QcReviewComponent, BusinessInfoGroupComponent],
|
||||
|
||||
})
|
||||
export class ManagePdModule {
|
||||
|
||||
@ -322,15 +322,14 @@ export class PdTrigerService {
|
||||
|
||||
swapOlderPDReportToLatest(pdId: any): Observable<any> {
|
||||
pdId.fk_createdby = this._aws.getlocale();
|
||||
alert(JSON.stringify(pdId));
|
||||
return this._http.post<any>(this.apiUrl + "swapOlderPDReportToLatest", { "records": pdId })
|
||||
.pipe(
|
||||
catchError(this.handleError('operation', []))
|
||||
)
|
||||
}
|
||||
|
||||
getTypeofActivityForSuppliedInfoForm(pd_id: any): Observable<any> {
|
||||
return this._http.post<any>(this.apiUrl + "getTypeOfActivetyFromBusinessForm", { "records": { "pd_id": pd_id } })
|
||||
getTypeofActivityForSuppliedInfoForm(pd_id: any,company_id:any): Observable<any> {
|
||||
return this._http.post<any>(this.apiUrl + "getTypeOfActivetyFromBusinessForm", { "records": { "pd_id": pd_id,"company_id":company_id } })
|
||||
.pipe(
|
||||
catchError(this.handleError('operation', []))
|
||||
)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user