forms console log removed : ps
This commit is contained in:
parent
a8ff3480ff
commit
45d68de639
@ -98,7 +98,7 @@ export class AddressComponent implements OnInit {
|
|||||||
|
|
||||||
ngOnInit() {
|
ngOnInit() {
|
||||||
console.clear();
|
console.clear();
|
||||||
console.log('this.address',this.pdAddress);
|
// console.log('this.address',this.pdAddress);
|
||||||
this.getMasterDetails('PDLOCATIONAPPROACH',1);
|
this.getMasterDetails('PDLOCATIONAPPROACH',1);
|
||||||
this.getMasterDetails('COMMENTSONLOCALITY',2);
|
this.getMasterDetails('COMMENTSONLOCALITY',2);
|
||||||
//this.getMasterDetails('CUSTOMERBEHAVIOUR',3);review doc s.no 3.e
|
//this.getMasterDetails('CUSTOMERBEHAVIOUR',3);review doc s.no 3.e
|
||||||
@ -113,7 +113,7 @@ export class AddressComponent implements OnInit {
|
|||||||
params.pd_form_id = '5';
|
params.pd_form_id = '5';
|
||||||
|
|
||||||
this._pd.retriveForm(params).subscribe(data => {
|
this._pd.retriveForm(params).subscribe(data => {
|
||||||
console.log('data', data);
|
// console.log('data', data);
|
||||||
//const control = <FormArray>this.addressForm.controls['neighbourhood'];
|
//const control = <FormArray>this.addressForm.controls['neighbourhood'];
|
||||||
const control = <FormArray>this.addressForm.controls['additional_address_units'];
|
const control = <FormArray>this.addressForm.controls['additional_address_units'];
|
||||||
//const additionalPremisesControl = <FormArray>this.addressForm.controls['additional_premises'];
|
//const additionalPremisesControl = <FormArray>this.addressForm.controls['additional_premises'];
|
||||||
|
|||||||
@ -93,7 +93,7 @@ export class BankingDetailsComponent implements OnInit {
|
|||||||
params.pd_id = this.pdid;
|
params.pd_id = this.pdid;
|
||||||
params.pd_form_id = '7';
|
params.pd_form_id = '7';
|
||||||
this._pd.retriveForm(params).subscribe(data => {
|
this._pd.retriveForm(params).subscribe(data => {
|
||||||
console.log('data', data);
|
// console.log('data', data);
|
||||||
const control = <FormArray>this.bankingForm.controls['itemRows'];
|
const control = <FormArray>this.bankingForm.controls['itemRows'];
|
||||||
if (data.status == 200) {
|
if (data.status == 200) {
|
||||||
this.bankingForm.controls.banking_form_remark.setValue(data.records.banking_form_remark);
|
this.bankingForm.controls.banking_form_remark.setValue(data.records.banking_form_remark);
|
||||||
@ -180,7 +180,7 @@ export class BankingDetailsComponent implements OnInit {
|
|||||||
}
|
}
|
||||||
|
|
||||||
deleteBankdetails(index: number) {
|
deleteBankdetails(index: number) {
|
||||||
console.log('index value -', index);
|
// console.log('index value -', index);
|
||||||
const control = <FormArray>this.bankingForm.controls['itemRows'];
|
const control = <FormArray>this.bankingForm.controls['itemRows'];
|
||||||
control.removeAt(index);
|
control.removeAt(index);
|
||||||
}
|
}
|
||||||
@ -196,9 +196,9 @@ export class BankingDetailsComponent implements OnInit {
|
|||||||
records.banking_form_remark = this.bankingForm.controls.banking_form_remark.value;
|
records.banking_form_remark = this.bankingForm.controls.banking_form_remark.value;
|
||||||
// records.fk_createdby = '252';
|
// records.fk_createdby = '252';
|
||||||
records.banking_details = this.bankingForm.controls['itemRows'].value;
|
records.banking_details = this.bankingForm.controls['itemRows'].value;
|
||||||
console.log('data', records);
|
// console.log('data', records);
|
||||||
this._pd.saveForm(records).subscribe(data => {
|
this._pd.saveForm(records).subscribe(data => {
|
||||||
console.log('data', data);
|
// console.log('data', data);
|
||||||
this.notifier.notify('success', 'Saved Successfully.');
|
this.notifier.notify('success', 'Saved Successfully.');
|
||||||
}, error => {
|
}, error => {
|
||||||
this.notifier.notify('warning', 'Something Wents Wrong Try Again.!');
|
this.notifier.notify('warning', 'Something Wents Wrong Try Again.!');
|
||||||
|
|||||||
@ -1118,7 +1118,7 @@ export class BusinessInfoComponent implements OnInit {
|
|||||||
data.records.forEach(val => {
|
data.records.forEach(val => {
|
||||||
if (val.isactive == 1) {
|
if (val.isactive == 1) {
|
||||||
this.countryDataList.push(val);
|
this.countryDataList.push(val);
|
||||||
console.log(this.countryDataList);
|
// console.log(this.countryDataList);
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
});
|
});
|
||||||
@ -1232,7 +1232,7 @@ export class BusinessInfoComponent implements OnInit {
|
|||||||
submitDetails() {
|
submitDetails() {
|
||||||
|
|
||||||
// let family: any = [];
|
// let family: any = [];
|
||||||
console.log(this.businessForm.value);
|
// console.log(this.businessForm.value);
|
||||||
|
|
||||||
if (!this.businessForm.valid) {
|
if (!this.businessForm.valid) {
|
||||||
//console.log(' Requried validation error');
|
//console.log(' Requried validation error');
|
||||||
|
|||||||
@ -88,7 +88,7 @@ export class CurrentLoanComponent implements OnInit {
|
|||||||
params.pd_form_id = this.form_id;
|
params.pd_form_id = this.form_id;
|
||||||
|
|
||||||
this._pd.retriveForm(params).subscribe(value => {
|
this._pd.retriveForm(params).subscribe(value => {
|
||||||
console.log('value', value);
|
// console.log('value', value);
|
||||||
const control = <FormArray>this.currentLoanForm.controls['loan_details'];
|
const control = <FormArray>this.currentLoanForm.controls['loan_details'];
|
||||||
if (value.status == 200) {
|
if (value.status == 200) {
|
||||||
|
|
||||||
@ -127,7 +127,7 @@ export class CurrentLoanComponent implements OnInit {
|
|||||||
}
|
}
|
||||||
|
|
||||||
selectedLoanChanges(e): void {
|
selectedLoanChanges(e): void {
|
||||||
console.log(e);
|
// console.log(e);
|
||||||
if (e.value == 'Yes') {
|
if (e.value == 'Yes') {
|
||||||
// console.log('if()');
|
// console.log('if()');
|
||||||
const control = <FormArray>this.currentLoanForm.controls['loan_details'];
|
const control = <FormArray>this.currentLoanForm.controls['loan_details'];
|
||||||
@ -187,7 +187,7 @@ export class CurrentLoanComponent implements OnInit {
|
|||||||
}
|
}
|
||||||
submitCurrentloan() {
|
submitCurrentloan() {
|
||||||
if (!this.currentLoanForm.valid) {
|
if (!this.currentLoanForm.valid) {
|
||||||
console.log("data invalid")
|
// console.log("data invalid")
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
let records: any = {};
|
let records: any = {};
|
||||||
@ -199,9 +199,9 @@ export class CurrentLoanComponent implements OnInit {
|
|||||||
if (records.existing_loan == 'Yes') {
|
if (records.existing_loan == 'Yes') {
|
||||||
records.loan_details = this.currentLoanForm.controls['loan_details'].value;
|
records.loan_details = this.currentLoanForm.controls['loan_details'].value;
|
||||||
}
|
}
|
||||||
console.log('data', records);
|
// console.log('data', records);
|
||||||
this._pd.saveForm(records).subscribe(data => {
|
this._pd.saveForm(records).subscribe(data => {
|
||||||
console.log('data', data);
|
// console.log('data', data);
|
||||||
this.notifier.notify('success', 'Saved Successfully.');
|
this.notifier.notify('success', 'Saved Successfully.');
|
||||||
}, error => {
|
}, error => {
|
||||||
this.notifier.notify('warning', 'Something Wents Wrong Try Again.!');
|
this.notifier.notify('warning', 'Something Wents Wrong Try Again.!');
|
||||||
|
|||||||
@ -312,7 +312,7 @@ export class GeneralInfoComponent implements OnInit {
|
|||||||
// remove companies
|
// remove companies
|
||||||
removeCompanies(indexValues) {
|
removeCompanies(indexValues) {
|
||||||
this.count = this.count-1;
|
this.count = this.count-1;
|
||||||
console.log('removed Count',this.count);
|
// console.log('removed Count',this.count);
|
||||||
let control: any = this._generalForm.get('companies') as FormArray;
|
let control: any = this._generalForm.get('companies') as FormArray;
|
||||||
control.controls[indexValues].controls.is_active.setValue(false);
|
control.controls[indexValues].controls.is_active.setValue(false);
|
||||||
control.controls[indexValues].controls.company_name.clearValidators();
|
control.controls[indexValues].controls.company_name.clearValidators();
|
||||||
@ -444,7 +444,7 @@ export class GeneralInfoComponent implements OnInit {
|
|||||||
// submit form details
|
// submit form details
|
||||||
submitGeneralForm(formData:any) {
|
submitGeneralForm(formData:any) {
|
||||||
if (this._generalForm.invalid) {
|
if (this._generalForm.invalid) {
|
||||||
console.log('if',this._generalForm.value);
|
// console.log('if',this._generalForm.value);
|
||||||
this.validateAllFormFields(this._generalForm);
|
this.validateAllFormFields(this._generalForm);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -84,7 +84,7 @@ public viewerOptions: any = {
|
|||||||
params.pd_id = this.pdid;
|
params.pd_id = this.pdid;
|
||||||
params.pd_form_id = this.form_id;
|
params.pd_form_id = this.form_id;
|
||||||
this._pd.retriveForm(params).subscribe(value => {
|
this._pd.retriveForm(params).subscribe(value => {
|
||||||
console.log('value', value);
|
// console.log('value', value);
|
||||||
const control = <FormArray>this.otherIncomeForm.controls['income_details'];
|
const control = <FormArray>this.otherIncomeForm.controls['income_details'];
|
||||||
if (value.status == 200) {
|
if (value.status == 200) {
|
||||||
|
|
||||||
@ -140,7 +140,7 @@ public viewerOptions: any = {
|
|||||||
getFrequency() {
|
getFrequency() {
|
||||||
let master_name = 'FREQUENCY';
|
let master_name = 'FREQUENCY';
|
||||||
this._pd.getAllMasterDatas(master_name).subscribe(data => {
|
this._pd.getAllMasterDatas(master_name).subscribe(data => {
|
||||||
console.log('data', data);
|
// console.log('data', data);
|
||||||
data.records.forEach(val => {
|
data.records.forEach(val => {
|
||||||
if (val.isactive == 1) {
|
if (val.isactive == 1) {
|
||||||
this.frequencyData.push(val);
|
this.frequencyData.push(val);
|
||||||
@ -151,7 +151,7 @@ public viewerOptions: any = {
|
|||||||
getSourceOtherIncome() {
|
getSourceOtherIncome() {
|
||||||
let master_name = 'SOURCEOFOTHERINCOME';
|
let master_name = 'SOURCEOFOTHERINCOME';
|
||||||
this._pd.getAllMasterDatas(master_name).subscribe(data => {
|
this._pd.getAllMasterDatas(master_name).subscribe(data => {
|
||||||
console.log('data', data);
|
// console.log('data', data);
|
||||||
data.records.forEach(val => {
|
data.records.forEach(val => {
|
||||||
if (val.isactive == 1) {
|
if (val.isactive == 1) {
|
||||||
this.sourceData.push(val);
|
this.sourceData.push(val);
|
||||||
@ -182,9 +182,9 @@ public viewerOptions: any = {
|
|||||||
records.income_details = this.otherIncomeForm.controls['income_details'].value;
|
records.income_details = this.otherIncomeForm.controls['income_details'].value;
|
||||||
}
|
}
|
||||||
|
|
||||||
console.log('data', records);
|
// console.log('data', records);
|
||||||
this._pd.saveForm(records).subscribe(data => {
|
this._pd.saveForm(records).subscribe(data => {
|
||||||
console.log('data', data);
|
// console.log('data', data);
|
||||||
this.notifier.notify('success', 'Saved Successfully.');
|
this.notifier.notify('success', 'Saved Successfully.');
|
||||||
}, error => {
|
}, error => {
|
||||||
this.notifier.notify('warning', 'Something Wents Wrong Try Again.!');
|
this.notifier.notify('warning', 'Something Wents Wrong Try Again.!');
|
||||||
|
|||||||
@ -142,7 +142,7 @@ export class StockComponent implements OnInit {
|
|||||||
let arr = record.filter(data => data.type_of_activity_id == 1);
|
let arr = record.filter(data => data.type_of_activity_id == 1);
|
||||||
if(arr.length > 0) {
|
if(arr.length > 0) {
|
||||||
this._pd.retriveForm({pd_id:this.pdid,pd_form_id:1}).subscribe(value => {
|
this._pd.retriveForm({pd_id:this.pdid,pd_form_id:1}).subscribe(value => {
|
||||||
console.log('136',value);
|
// console.log('136',value);
|
||||||
if(value.status == 200){
|
if(value.status == 200){
|
||||||
this.suppliers_raw_materials = value.records.manufacturing_details[0].main_raw_materials;
|
this.suppliers_raw_materials = value.records.manufacturing_details[0].main_raw_materials;
|
||||||
let manufacturing_temparr = [];
|
let manufacturing_temparr = [];
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user