merge2 : ps
This commit is contained in:
commit
8d7641846c
File diff suppressed because one or more lines are too long
@ -116,6 +116,7 @@ import { PdQuestionAssessedBusinessIncomePage } from '../pages/pd-question/pd-qu
|
|||||||
import { PdGeneralImagesPage } from '../pages/pd-general-images/pd-general-images';
|
import { PdGeneralImagesPage } from '../pages/pd-general-images/pd-general-images';
|
||||||
import { PdQuestionSalaryInfoPage } from '../pages/pd-question/pd-question-salary-info/pd-question-salary-info';
|
import { PdQuestionSalaryInfoPage } from '../pages/pd-question/pd-question-salary-info/pd-question-salary-info';
|
||||||
import { LocationAccuracy } from '@ionic-native/location-accuracy';
|
import { LocationAccuracy } from '@ionic-native/location-accuracy';
|
||||||
|
import {PdQuestionAssessedSummaryPage} from '../pages/pd-question/pd-question-assessed-summary/pd-question-assessed-summary'
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
declarations: [
|
declarations: [
|
||||||
@ -166,6 +167,7 @@ import { LocationAccuracy } from '@ionic-native/location-accuracy';
|
|||||||
PdQuestionAssessedBusinessIncomePage,
|
PdQuestionAssessedBusinessIncomePage,
|
||||||
PdGeneralImagesPage,
|
PdGeneralImagesPage,
|
||||||
PdQuestionSalaryInfoPage,
|
PdQuestionSalaryInfoPage,
|
||||||
|
PdQuestionAssessedSummaryPage
|
||||||
],
|
],
|
||||||
imports: [
|
imports: [
|
||||||
BrowserModule,ReactiveFormsModule,FormsModule,
|
BrowserModule,ReactiveFormsModule,FormsModule,
|
||||||
@ -252,6 +254,7 @@ import { LocationAccuracy } from '@ionic-native/location-accuracy';
|
|||||||
PdQuestionAssessedBusinessIncomePage,
|
PdQuestionAssessedBusinessIncomePage,
|
||||||
PdGeneralImagesPage,
|
PdGeneralImagesPage,
|
||||||
PdQuestionSalaryInfoPage,
|
PdQuestionSalaryInfoPage,
|
||||||
|
PdQuestionAssessedSummaryPage
|
||||||
|
|
||||||
],
|
],
|
||||||
providers: [
|
providers: [
|
||||||
|
|||||||
@ -122,7 +122,7 @@
|
|||||||
</mat-card>
|
</mat-card>
|
||||||
</div>
|
</div>
|
||||||
<div *ngIf="templateAccess">
|
<div *ngIf="templateAccess">
|
||||||
<mat-card *ngFor="let tempForm of questionCate.template_forms;let i=index">
|
<mat-card *ngFor="let tempForm of dis_forms;let i=index">
|
||||||
<ion-list (click)="tempQustionTag(tempForm.form_id)">
|
<ion-list (click)="tempQustionTag(tempForm.form_id)">
|
||||||
<ion-item>
|
<ion-item>
|
||||||
<ion-icon item-start="" class="lettericon" [style.background]="bgColortempForm[i]">{{tempForm.form_name[0] | slice : 0 :1 | uppercase}}</ion-icon>
|
<ion-icon item-start="" class="lettericon" [style.background]="bgColortempForm[i]">{{tempForm.form_name[0] | slice : 0 :1 | uppercase}}</ion-icon>
|
||||||
|
|||||||
@ -52,6 +52,7 @@ export class PdQuestionCategoryPage {
|
|||||||
templateAccess: boolean;
|
templateAccess: boolean;
|
||||||
bgColortempForm: any=[];
|
bgColortempForm: any=[];
|
||||||
bgColorqustCat: any=[];
|
bgColorqustCat: any=[];
|
||||||
|
dis_forms:any;
|
||||||
// @ViewChild('doughnutCanvas') doughnutCanvas;
|
// @ViewChild('doughnutCanvas') doughnutCanvas;
|
||||||
pdinfo: any;
|
pdinfo: any;
|
||||||
questionList:any;
|
questionList:any;
|
||||||
@ -126,6 +127,7 @@ searchitem:any;
|
|||||||
this.questionCateAccess = true;
|
this.questionCateAccess = true;
|
||||||
this.templateAccess = true;
|
this.templateAccess = true;
|
||||||
this.questionCate = this.questionCate;
|
this.questionCate = this.questionCate;
|
||||||
|
this.dis_forms=this.questionCate.template_forms.filter(val=>val.isAnswerable==true );
|
||||||
this.searchQuestion = this.questionCate.question_answers;
|
this.searchQuestion = this.questionCate.question_answers;
|
||||||
|
|
||||||
if(this.questionCate.counts.overall_answered_count !=0 && this.questionCate.counts.overall_question_count !=0 && this.questionCate.counts.overall_answered_count == this.questionCate.counts.overall_question_count)
|
if(this.questionCate.counts.overall_answered_count !=0 && this.questionCate.counts.overall_question_count !=0 && this.questionCate.counts.overall_answered_count == this.questionCate.counts.overall_question_count)
|
||||||
@ -143,7 +145,9 @@ searchitem:any;
|
|||||||
}else if(this.questionCate.template_forms!='')
|
}else if(this.questionCate.template_forms!='')
|
||||||
{
|
{
|
||||||
this.templateAccess = true;
|
this.templateAccess = true;
|
||||||
this.questionCate = this.questionCate;
|
this.questionCate = this.questionCate
|
||||||
|
this.dis_forms=this.questionCate.template_forms.filter(val=>val.isAnswerable==true );
|
||||||
|
console.log("temp",this.questionCate);
|
||||||
this.searchTempForm = this.questionCate.template_forms
|
this.searchTempForm = this.questionCate.template_forms
|
||||||
// if(this.questionCate.counts.overall_answered_count !=0 && this.questionCate.counts.overall_question_count !=0 && this.questionCate.counts.overall_answered_count == this.questionCate.counts.overall_question_count)
|
// if(this.questionCate.counts.overall_answered_count !=0 && this.questionCate.counts.overall_question_count !=0 && this.questionCate.counts.overall_answered_count == this.questionCate.counts.overall_question_count)
|
||||||
// {
|
// {
|
||||||
|
|||||||
@ -24,24 +24,29 @@
|
|||||||
</mat-select>
|
</mat-select>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
|
|
||||||
<mat-form-field style="width: 100%" *ngIf="item.get('business_income_id').value==3">
|
<mat-form-field style="width: 100%" *ngIf="item.get('business_income_id').value==1">
|
||||||
<input type="text" matInput placeholder="Other Business Income" formControlName="other_income_item" name="other_income_item">
|
<input type="text" matInput placeholder="Other Business Income" formControlName="other_income_item" name="other_income_item">
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
|
|
||||||
<mat-form-field style="width: 100%">
|
<mat-form-field style="width: 100%">
|
||||||
<input matInput placeholder="Amount (Rs)" type="tel" name="income_value" formControlName="income_value" (blur)="busIncomecalculate(i,item)">
|
<input matInput placeholder="Amount (Rs)" type="tel" name="income_value" formControlName="income_value" (keyup)="busIncomecalculate(i,item.value);inWords($event.target.value,i,1)">
|
||||||
|
<mat-hint align="end" style="font-size: 12px" *ngIf="item.get('income_value').value != null">{{"₹"}} {{Value[i]}} Only</mat-hint>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
<mat-form-field style="width: 100%">
|
<mat-form-field style="width: 100%">
|
||||||
<mat-select placeholder="frequency" formControlName="fk_frequency_id" (selectionChange)="busIncomecalculate(i,item)">
|
<mat-select placeholder="Frequency" formControlName="fk_frequency_id" (selectionChange)="busIncomecalculate(i,item.value)">
|
||||||
<mat-option *ngFor="let frq of m_freqOfPurchase" [value]="frq.frequency_id
|
<mat-option *ngFor="let frq of m_freqOfPurchase" [value]="frq.frequency_id
|
||||||
">{{frq.name}}</mat-option>
|
">{{frq.name}}</mat-option>
|
||||||
</mat-select>
|
</mat-select>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
<mat-form-field style="width: 100%" *ngIf="item.get('fk_frequency_id').value==8">
|
<mat-form-field style="width: 100%" *ngIf="item.get('fk_frequency_id').value==1">
|
||||||
<input type="text" matInput placeholder="Other Frequency" formControlName="other_frequncy_item" name="other_frequncy_item">
|
<input type="text" matInput placeholder="Other Frequency" formControlName="other_frequncy_item" name="other_frequncy_item">
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
<mat-form-field style="width: 100%">
|
<mat-form-field style="width: 100%">
|
||||||
<input matInput placeholder="Annual Expenses" type="number" name="annual_income_value" formControlName="annual_income_value" readonly>
|
<input matInput placeholder="Annual Expenses" type="number" name="annual_income_value" formControlName="annual_income_value" readonly>
|
||||||
|
<mat-hint align="end" style="font-size: 12px" *ngIf="item.get('annual_income_value').value != null">{{"₹"}} {{AnnualExpenses[i]}} Only</mat-hint>
|
||||||
|
</mat-form-field>
|
||||||
|
<mat-form-field style="width: 100%">
|
||||||
|
<textarea matInput autocomplete="off" placeholder="Remarks" formControlName="comments" ></textarea>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
|
|
||||||
<ion-buttons end>
|
<ion-buttons end>
|
||||||
|
|||||||
@ -4,6 +4,7 @@ import { FormGroup, FormBuilder, FormArray, Validators } from '@angular/forms';
|
|||||||
import { AwsServiceProvider } from '../../../providers/aws-service/aws-service';
|
import { AwsServiceProvider } from '../../../providers/aws-service/aws-service';
|
||||||
import { QuestionCategoryProvider } from '../../../providers/question-category/question-category';
|
import { QuestionCategoryProvider } from '../../../providers/question-category/question-category';
|
||||||
import { ToastProvider } from '../../../providers/common-provider/toast';
|
import { ToastProvider } from '../../../providers/common-provider/toast';
|
||||||
|
import {ConstantsProvider} from '../../../providers/constants/constants'
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Generated class for the PdQuestionAssessedBusinessIncomePage page.
|
* Generated class for the PdQuestionAssessedBusinessIncomePage page.
|
||||||
@ -27,7 +28,9 @@ export class PdQuestionAssessedBusinessIncomePage {
|
|||||||
pdDetails: any;
|
pdDetails: any;
|
||||||
BuissnessForm:FormGroup;
|
BuissnessForm:FormGroup;
|
||||||
businessIncome:any;
|
businessIncome:any;
|
||||||
constructor(public navCtrl: NavController, public navParams: NavParams,public fb:FormBuilder,public aws:AwsServiceProvider,public qustCat:QuestionCategoryProvider,public toast:ToastProvider) {
|
Value: any=[];
|
||||||
|
AnnualExpenses: any=[];
|
||||||
|
constructor(public navCtrl: NavController, public navParams: NavParams,public fb:FormBuilder,public aws:AwsServiceProvider,public qustCat:QuestionCategoryProvider,public toast:ToastProvider,public cons:ConstantsProvider) {
|
||||||
this.pdDetails = this.navParams.get('pdDetails');
|
this.pdDetails = this.navParams.get('pdDetails');
|
||||||
this.expenseDetails = this.navParams.get('income');
|
this.expenseDetails = this.navParams.get('income');
|
||||||
|
|
||||||
@ -76,6 +79,7 @@ export class PdQuestionAssessedBusinessIncomePage {
|
|||||||
income_value:[null,Validators.compose([Validators.required])],
|
income_value:[null,Validators.compose([Validators.required])],
|
||||||
fk_frequency_id:[null,Validators.compose([Validators.required])],
|
fk_frequency_id:[null,Validators.compose([Validators.required])],
|
||||||
annual_income_value:[null,Validators.compose([Validators.required])],
|
annual_income_value:[null,Validators.compose([Validators.required])],
|
||||||
|
comments:[null],
|
||||||
isactive:['1'],
|
isactive:['1'],
|
||||||
fk_createdby:[this.users],
|
fk_createdby:[this.users],
|
||||||
other_income_item:[null],
|
other_income_item:[null],
|
||||||
@ -98,68 +102,77 @@ export class PdQuestionAssessedBusinessIncomePage {
|
|||||||
control.removeAt(i);
|
control.removeAt(i);
|
||||||
}
|
}
|
||||||
|
|
||||||
busIncomecalculate(index,details)
|
busIncomecalculate(indexVal,values)
|
||||||
{
|
{
|
||||||
|
let control:any = <FormArray>this.BuissnessForm.controls['busIncome'];
|
||||||
|
if(values.income_value!='' && values.fk_frequency_id!='' && values.income_value!=null && values.fk_frequency_id!=null) {
|
||||||
let frequencyId = details.value.fk_frequency_id;
|
let filterFrequencyValue: any = this.m_freqOfPurchase.filter(val =>val.frequency_id==values.fk_frequency_id);
|
||||||
let incomeValue = details.value.income_value;
|
control.controls[indexVal].controls['annual_income_value'].setValue(parseInt(values.income_value) * parseInt(filterFrequencyValue[0].mutiple_factor));
|
||||||
// let UOM = details.value.rate_per_unit;
|
this.inWords(parseInt(values.income_value) * parseInt(filterFrequencyValue[0].mutiple_factor),indexVal,2)
|
||||||
|
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
control.controls[indexVal].controls['annual_income_value'].setValue('');
|
||||||
|
}
|
||||||
|
//OLD CALCULATION
|
||||||
|
// let frequencyId = details.value.fk_frequency_id;
|
||||||
|
// let incomeValue = details.value.income_value;
|
||||||
|
// // let UOM = details.value.rate_per_unit;
|
||||||
|
|
||||||
let annual:any;
|
// let annual:any;
|
||||||
if(incomeValue!=null && incomeValue !=null){
|
// if(incomeValue!=null && incomeValue !=null){
|
||||||
let frequency_factor = this.m_freqOfPurchase.filter(frq=>frq.frequency_id == frequencyId)[0];
|
// let frequency_factor = this.m_freqOfPurchase.filter(frq=>frq.frequency_id == frequencyId)[0];
|
||||||
if(frequencyId==1)
|
// if(frequencyId==1)
|
||||||
{
|
// {
|
||||||
|
|
||||||
annual = (incomeValue*frequency_factor.mutiple_factor);
|
// annual = (incomeValue*frequency_factor.mutiple_factor);
|
||||||
this.incomeannual[index] = annual;
|
// this.incomeannual[index] = annual;
|
||||||
details.controls['annual_income_value'].setValue(annual);
|
// details.controls['annual_income_value'].setValue(annual);
|
||||||
}else if(frequencyId==2)
|
// }else if(frequencyId==2)
|
||||||
{
|
// {
|
||||||
annual = (incomeValue*frequency_factor.mutiple_factor);
|
// annual = (incomeValue*frequency_factor.mutiple_factor);
|
||||||
this.incomeannual[index] = annual;
|
// this.incomeannual[index] = annual;
|
||||||
details.controls['annual_income_value'].setValue(annual);
|
// details.controls['annual_income_value'].setValue(annual);
|
||||||
}else if(frequencyId==3)
|
// }else if(frequencyId==3)
|
||||||
{
|
// {
|
||||||
annual = (incomeValue*frequency_factor.mutiple_factor);
|
// annual = (incomeValue*frequency_factor.mutiple_factor);
|
||||||
this.incomeannual[index] = annual;
|
// this.incomeannual[index] = annual;
|
||||||
details.controls['annual_income_value'].setValue(annual);
|
// details.controls['annual_income_value'].setValue(annual);
|
||||||
}else if(frequencyId==4)
|
// }else if(frequencyId==4)
|
||||||
{
|
// {
|
||||||
annual = (incomeValue*frequency_factor.mutiple_factor);
|
// annual = (incomeValue*frequency_factor.mutiple_factor);
|
||||||
this.incomeannual[index] = annual;
|
// this.incomeannual[index] = annual;
|
||||||
details.controls['annual_income_value'].setValue(annual);
|
// details.controls['annual_income_value'].setValue(annual);
|
||||||
}else if(frequencyId==5)
|
// }else if(frequencyId==5)
|
||||||
{
|
// {
|
||||||
annual = (incomeValue*frequency_factor.mutiple_factor);
|
// annual = (incomeValue*frequency_factor.mutiple_factor);
|
||||||
this.incomeannual[index] = annual;
|
// this.incomeannual[index] = annual;
|
||||||
details.controls['annual_income_value'].setValue(annual);
|
// details.controls['annual_income_value'].setValue(annual);
|
||||||
}else if(frequencyId==6)
|
// }else if(frequencyId==6)
|
||||||
{
|
// {
|
||||||
annual = (incomeValue*frequency_factor.mutiple_factor);
|
// annual = (incomeValue*frequency_factor.mutiple_factor);
|
||||||
this.incomeannual[index] = annual;
|
// this.incomeannual[index] = annual;
|
||||||
details.controls['annual_income_value'].setValue(annual);
|
// details.controls['annual_income_value'].setValue(annual);
|
||||||
}else if(frequencyId==7)
|
// }else if(frequencyId==7)
|
||||||
{
|
// {
|
||||||
annual = (incomeValue*frequency_factor.mutiple_factor);
|
// annual = (incomeValue*frequency_factor.mutiple_factor);
|
||||||
this.incomeannual[index] = annual;
|
// this.incomeannual[index] = annual;
|
||||||
details.controls['annual_income_value'].setValue(annual);
|
// details.controls['annual_income_value'].setValue(annual);
|
||||||
}else if(frequencyId==8)
|
// }else if(frequencyId==8)
|
||||||
{
|
// {
|
||||||
annual = (incomeValue);
|
// annual = (incomeValue);
|
||||||
this.incomeannual[index] = annual;
|
// this.incomeannual[index] = annual;
|
||||||
details.controls['annual_income_value'].setValue(annual);
|
// details.controls['annual_income_value'].setValue(annual);
|
||||||
|
|
||||||
}else
|
// }else
|
||||||
{
|
// {
|
||||||
|
|
||||||
}
|
// }
|
||||||
this.grandIncomeTotal = this.incomeannual.reduce((a,b)=> +a + +b,0);
|
// this.grandIncomeTotal = this.incomeannual.reduce((a,b)=> +a + +b,0);
|
||||||
}else
|
// }else
|
||||||
{
|
// {
|
||||||
this.toast.pdTriggerappmessage('Enter the Amount and Frequency');
|
// this.toast.pdTriggerappmessage('Enter the Amount and Frequency');
|
||||||
}
|
// }
|
||||||
}
|
}
|
||||||
|
|
||||||
saveBusinessData(answerData)
|
saveBusinessData(answerData)
|
||||||
@ -195,6 +208,10 @@ export class PdQuestionAssessedBusinessIncomePage {
|
|||||||
{
|
{
|
||||||
this.incomeannual[index] = val.annual_income_value;
|
this.incomeannual[index] = val.annual_income_value;
|
||||||
control.push(this.createBusinessExpensewithData(val));
|
control.push(this.createBusinessExpensewithData(val));
|
||||||
|
if(val.income_value != null){
|
||||||
|
this.Value[index]=this.cons.convertNumberToWords(val.income_value)
|
||||||
|
this.AnnualExpenses[index]=this.cons.convertNumberToWords(val.annual_income_value)
|
||||||
|
}
|
||||||
})
|
})
|
||||||
this.grandIncomeTotal = this.incomeannual.reduce((a,b)=> +a + +b,0);
|
this.grandIncomeTotal = this.incomeannual.reduce((a,b)=> +a + +b,0);
|
||||||
}
|
}
|
||||||
@ -210,10 +227,22 @@ export class PdQuestionAssessedBusinessIncomePage {
|
|||||||
income_value:[data.income_value,Validators.compose([Validators.required])],
|
income_value:[data.income_value,Validators.compose([Validators.required])],
|
||||||
fk_frequency_id:[data.fk_frequency_id,Validators.compose([Validators.required])],
|
fk_frequency_id:[data.fk_frequency_id,Validators.compose([Validators.required])],
|
||||||
annual_income_value:[data.annual_income_value,Validators.compose([Validators.required])],
|
annual_income_value:[data.annual_income_value,Validators.compose([Validators.required])],
|
||||||
|
comments:[data.comments],
|
||||||
isactive:['1'],
|
isactive:['1'],
|
||||||
fk_createdby:[this.users],
|
fk_createdby:[this.users],
|
||||||
other_income_item:[data.other_income_item],
|
other_income_item:[data.other_income_item],
|
||||||
other_frequncy_item:[data.other_frequncy_item],
|
other_frequncy_item:[data.other_frequncy_item],
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
inWords(e,c,flag){
|
||||||
|
switch(flag){
|
||||||
|
case 1 :
|
||||||
|
this.Value[c] = this.cons.convertNumberToWords(e);
|
||||||
|
break;
|
||||||
|
case 2 :
|
||||||
|
this.AnnualExpenses[c] = this.cons.convertNumberToWords(e);
|
||||||
|
break;
|
||||||
|
default : break;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -24,7 +24,8 @@
|
|||||||
</mat-select>
|
</mat-select>
|
||||||
</mat-form-field >
|
</mat-form-field >
|
||||||
<mat-form-field style="width: 100%">
|
<mat-form-field style="width: 100%">
|
||||||
<input matInput placeholder="Amount (Rs)" type="number" name="expense_value" formControlName="expense_value" (keyup)="businessCalculation(i,item.value)">
|
<input matInput placeholder="Amount (Rs)" type="number" name="expense_value" formControlName="expense_value" (keyup)="businessCalculation(i,item.value);inWords($event.target.value,i,1)">
|
||||||
|
<mat-hint align="end" style="font-size: 11px" *ngIf="item.get('expense_value').value != null">{{"₹"}} {{Value[i]}} Only</mat-hint>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
<mat-form-field style="width: 100%">
|
<mat-form-field style="width: 100%">
|
||||||
<mat-select placeholder="Frequency" formControlName="fk_frequency_id" (selectionChange)="businessCalculation(i,item.value)">
|
<mat-select placeholder="Frequency" formControlName="fk_frequency_id" (selectionChange)="businessCalculation(i,item.value)">
|
||||||
@ -34,7 +35,11 @@
|
|||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
<mat-form-field style="width: 100%">
|
<mat-form-field style="width: 100%">
|
||||||
<input matInput placeholder="Annual Expenses" type="number" name="annual_expenses_value" formControlName="annual_expenses_value" readonly>
|
<input matInput placeholder="Annual Expenses" type="number" name="annual_expenses_value" formControlName="annual_expenses_value" readonly>
|
||||||
|
<mat-hint align="end" style="font-size: 11px" *ngIf="item.get('annual_expenses_value').value != null">{{"₹"}} {{AnnualExpenses[i]}} Only</mat-hint>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
|
<mat-form-field style="width: 100%">
|
||||||
|
<textarea matInput autocomplete="off" placeholder="Remarks" formControlName="comments" ></textarea>
|
||||||
|
</mat-form-field>
|
||||||
|
|
||||||
<ion-buttons end>
|
<ion-buttons end>
|
||||||
|
|
||||||
|
|||||||
@ -4,7 +4,7 @@ import { FormGroup, FormBuilder, Validators, FormArray } from '@angular/forms';
|
|||||||
import { AwsServiceProvider } from '../../../providers/aws-service/aws-service';
|
import { AwsServiceProvider } from '../../../providers/aws-service/aws-service';
|
||||||
import { QuestionCategoryProvider } from '../../../providers/question-category/question-category';
|
import { QuestionCategoryProvider } from '../../../providers/question-category/question-category';
|
||||||
import { ToastProvider } from '../../../providers/common-provider/toast';
|
import { ToastProvider } from '../../../providers/common-provider/toast';
|
||||||
|
import { ConstantsProvider } from '../../../providers/constants/constants'
|
||||||
/**
|
/**
|
||||||
* Generated class for the PdQuestionAssessedBusinessPage page.
|
* Generated class for the PdQuestionAssessedBusinessPage page.
|
||||||
*
|
*
|
||||||
@ -20,6 +20,8 @@ import { ToastProvider } from '../../../providers/common-provider/toast';
|
|||||||
export class PdQuestionAssessedBusinessPage {
|
export class PdQuestionAssessedBusinessPage {
|
||||||
m_freqOfPurchase: any;
|
m_freqOfPurchase: any;
|
||||||
expenseDetails: any;
|
expenseDetails: any;
|
||||||
|
Value: any=[];
|
||||||
|
AnnualExpenses: any=[];
|
||||||
grandpurchaseTotal(arg0: any): any {
|
grandpurchaseTotal(arg0: any): any {
|
||||||
throw new Error("Method not implemented.");
|
throw new Error("Method not implemented.");
|
||||||
}
|
}
|
||||||
@ -29,7 +31,7 @@ export class PdQuestionAssessedBusinessPage {
|
|||||||
pdDetails: any;
|
pdDetails: any;
|
||||||
BuissnessForm:FormGroup;
|
BuissnessForm:FormGroup;
|
||||||
businessExpenses:any;
|
businessExpenses:any;
|
||||||
constructor(public navCtrl: NavController, public navParams: NavParams,public fb:FormBuilder,public aws:AwsServiceProvider,public qustCat:QuestionCategoryProvider,public toast:ToastProvider) {
|
constructor(public navCtrl: NavController, public navParams: NavParams,public fb:FormBuilder,public aws:AwsServiceProvider,public qustCat:QuestionCategoryProvider,public toast:ToastProvider,public cons:ConstantsProvider) {
|
||||||
this.pdDetails = this.navParams.get('pdDetails');
|
this.pdDetails = this.navParams.get('pdDetails');
|
||||||
this.expenseDetails = this.navParams.get('expense');
|
this.expenseDetails = this.navParams.get('expense');
|
||||||
this.users = this.aws.getlocale();
|
this.users = this.aws.getlocale();
|
||||||
@ -79,6 +81,7 @@ export class PdQuestionAssessedBusinessPage {
|
|||||||
expense_value:[null,Validators.compose([Validators.required])],
|
expense_value:[null,Validators.compose([Validators.required])],
|
||||||
fk_frequency_id:[null,Validators.compose([Validators.required])],
|
fk_frequency_id:[null,Validators.compose([Validators.required])],
|
||||||
annual_expenses_value:[null,Validators.compose([Validators.required])],
|
annual_expenses_value:[null,Validators.compose([Validators.required])],
|
||||||
|
comments:[null],
|
||||||
isactive:['1'],
|
isactive:['1'],
|
||||||
fk_createdby:[this.users]
|
fk_createdby:[this.users]
|
||||||
})
|
})
|
||||||
@ -90,10 +93,11 @@ export class PdQuestionAssessedBusinessPage {
|
|||||||
if(values.expense_value!='' && values.fk_frequency_id!='' && values.expense_value!=null && values.fk_frequency_id!=null) {
|
if(values.expense_value!='' && values.fk_frequency_id!='' && values.expense_value!=null && values.fk_frequency_id!=null) {
|
||||||
let filterFrequencyValue: any = this.m_freqOfPurchase.filter(val =>val.frequency_id==values.fk_frequency_id);
|
let filterFrequencyValue: any = this.m_freqOfPurchase.filter(val =>val.frequency_id==values.fk_frequency_id);
|
||||||
control.controls[indexVal].controls['annual_expenses_value'].setValue(parseInt(values.expense_value) * parseInt(filterFrequencyValue[0].mutiple_factor));
|
control.controls[indexVal].controls['annual_expenses_value'].setValue(parseInt(values.expense_value) * parseInt(filterFrequencyValue[0].mutiple_factor));
|
||||||
|
this.inWords(parseInt(values.expense_value) * parseInt(filterFrequencyValue[0].mutiple_factor),indexVal,2)
|
||||||
|
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
control.controls[indexVal].controls['annual_expenses_value'].setValue('');
|
control.controls[indexVal].controls['annual_expenses_value'].setValue(null);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -129,12 +133,14 @@ export class PdQuestionAssessedBusinessPage {
|
|||||||
{
|
{
|
||||||
annual = (expenseValue*250);
|
annual = (expenseValue*250);
|
||||||
this.expenseannual[index] = annual;
|
this.expenseannual[index] = annual;
|
||||||
details.controls['annual_expenses_value'].setValue(annual);
|
details.controls['annual_expenses_value'].setValue(annual);
|
||||||
|
this.inWords(annual,index,2)
|
||||||
}else if(frequencyId==3)
|
}else if(frequencyId==3)
|
||||||
{
|
{
|
||||||
annual = (expenseValue);
|
annual = (expenseValue);
|
||||||
this.expenseannual[index] = annual;
|
this.expenseannual[index] = annual;
|
||||||
details.controls['annual_expenses_value'].setValue(annual);
|
details.controls['annual_expenses_value'].setValue(annual);
|
||||||
|
this.inWords(annual,index,2)
|
||||||
}else if(frequencyId==4)
|
}else if(frequencyId==4)
|
||||||
{
|
{
|
||||||
|
|
||||||
@ -143,6 +149,7 @@ export class PdQuestionAssessedBusinessPage {
|
|||||||
annual = (expenseValue*12);
|
annual = (expenseValue*12);
|
||||||
this.expenseannual[index] = annual;
|
this.expenseannual[index] = annual;
|
||||||
details.controls['annual_expenses_value'].setValue(annual);
|
details.controls['annual_expenses_value'].setValue(annual);
|
||||||
|
this.inWords(annual,index,2)
|
||||||
}else if(frequencyId==6)
|
}else if(frequencyId==6)
|
||||||
{
|
{
|
||||||
|
|
||||||
@ -196,6 +203,10 @@ export class PdQuestionAssessedBusinessPage {
|
|||||||
{
|
{
|
||||||
this.expenseannual[index] = val.annual_expenses_value;
|
this.expenseannual[index] = val.annual_expenses_value;
|
||||||
control.push(this.createBusinessExpensewithData(val));
|
control.push(this.createBusinessExpensewithData(val));
|
||||||
|
if(val.expense_value != null){
|
||||||
|
this.Value[index]=this.cons.convertNumberToWords(val.expense_value)
|
||||||
|
this.AnnualExpenses[index]=this.cons.convertNumberToWords(val.annual_expenses_value)
|
||||||
|
}
|
||||||
})
|
})
|
||||||
this.grandExpenseTotal = this.expenseannual.reduce((a,b)=> +a + +b,0);
|
this.grandExpenseTotal = this.expenseannual.reduce((a,b)=> +a + +b,0);
|
||||||
}
|
}
|
||||||
@ -211,8 +222,20 @@ export class PdQuestionAssessedBusinessPage {
|
|||||||
expense_value:[data.expense_value,Validators.compose([Validators.required])],
|
expense_value:[data.expense_value,Validators.compose([Validators.required])],
|
||||||
fk_frequency_id:[data.fk_frequency_id,Validators.compose([Validators.required])],
|
fk_frequency_id:[data.fk_frequency_id,Validators.compose([Validators.required])],
|
||||||
annual_expenses_value:[data.annual_expenses_value,Validators.compose([Validators.required])],
|
annual_expenses_value:[data.annual_expenses_value,Validators.compose([Validators.required])],
|
||||||
|
comments:[data.comments],
|
||||||
isactive:['1'],
|
isactive:['1'],
|
||||||
fk_createdby:[this.users]
|
fk_createdby:[this.users]
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
inWords(e,c,flag){
|
||||||
|
switch(flag){
|
||||||
|
case 1 :
|
||||||
|
this.Value[c] = this.cons.convertNumberToWords(e);
|
||||||
|
break;
|
||||||
|
case 2 :
|
||||||
|
this.AnnualExpenses[c] = this.cons.convertNumberToWords(e);
|
||||||
|
break;
|
||||||
|
default : break;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -29,14 +29,18 @@
|
|||||||
<input matInput type="text" placeholder="Margin Value" formControlName="margin_value" name="margin_value" readonly>
|
<input matInput type="text" placeholder="Margin Value" formControlName="margin_value" name="margin_value" readonly>
|
||||||
<mat-hint align="end" style="font-size:12px" *ngIf="item.get('margin_value').value != ''">{{"₹"}} {{marginAmtInwords[sale_i]}} Only</mat-hint>
|
<mat-hint align="end" style="font-size:12px" *ngIf="item.get('margin_value').value != ''">{{"₹"}} {{marginAmtInwords[sale_i]}} Only</mat-hint>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
<mat-form-field style="width: 100%">
|
||||||
|
<textarea matInput autocomplete="off" placeholder="Remarks" formControlName="comments"></textarea>
|
||||||
|
</mat-form-field>
|
||||||
</mat-card>
|
</mat-card>
|
||||||
<mat-card>
|
<mat-card>
|
||||||
<mat-card-header><h2>{{item.get('sales_item').value | titlecase}}</h2></mat-card-header>
|
<mat-card-header><h2>{{item.get('sales_item').value | titlecase}}</h2></mat-card-header>
|
||||||
<div formArrayName="child">
|
<div formArrayName="child">
|
||||||
<div *ngFor="let tenants of item['controls'].child['controls']; let i =index;let dailylast = last" [formGroupName]="i">
|
<div *ngFor="let tenants of item['controls'].child['controls']; let i =index;let dailylast = last" [formGroupName]="i">
|
||||||
<mat-form-field style="width: 100%">
|
<mat-form-field style="width: 100%">
|
||||||
<input matInput type="date" max="maxDate" [matDatepicker]="picker" placeholder="Sales Date" (dateChange)="salesCalculation(sale_i,item.value)" formControlName="sales_date" name="sales_date">
|
<input matInput type="date" max="maxDate" placeholder="Sales Date" (dateChange)="salesCalculation(sale_i,item.value)" formControlName="sales_date" name="sales_date">
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
<mat-form-field style="width: 100%">
|
<mat-form-field style="width: 100%">
|
||||||
<input matInput type="number" (blur)="getSalesCalc(tenants,item,sale_i)" placeholder="Value" (keyup)="salesCalculation(sale_i,item.value,item.value.child);inWords($event.target.value,i,1)" formControlName="sales_value" name="sales_value">
|
<input matInput type="number" (blur)="getSalesCalc(tenants,item,sale_i)" placeholder="Value" (keyup)="salesCalculation(sale_i,item.value,item.value.child);inWords($event.target.value,i,1)" formControlName="sales_value" name="sales_value">
|
||||||
|
|||||||
@ -66,6 +66,7 @@ export class PdQuestionAssessedDailySalesPage {
|
|||||||
fk_pd_id: [this.pdDetails.pd_id],
|
fk_pd_id: [this.pdDetails.pd_id],
|
||||||
margin_per: [null],
|
margin_per: [null],
|
||||||
margin_value: [null],
|
margin_value: [null],
|
||||||
|
comments:[null],
|
||||||
fk_createdby: [this.users],
|
fk_createdby: [this.users],
|
||||||
isactive: ['1'],
|
isactive: ['1'],
|
||||||
});
|
});
|
||||||
@ -236,16 +237,20 @@ export class PdQuestionAssessedDailySalesPage {
|
|||||||
dailySalesData.forEach((val, index) => {
|
dailySalesData.forEach((val, index) => {
|
||||||
|
|
||||||
control.push(this.dailySalesWithData(val));
|
control.push(this.dailySalesWithData(val));
|
||||||
|
this.marginAmtInwords[index]=this.constant.convertNumberToWords(val.margin_value)
|
||||||
salesChildControl = (<FormArray>this.salesDailyForm.controls['sales_product']).at(index).get('child') as FormArray;
|
salesChildControl = (<FormArray>this.salesDailyForm.controls['sales_product']).at(index).get('child') as FormArray;
|
||||||
|
|
||||||
salesChildControlarr[index] = Object.keys(val['items']).map(key => val['items'][key]);
|
salesChildControlarr[index] = Object.keys(val['items']).map(key => val['items'][key]);
|
||||||
|
|
||||||
salesChildControlarr[index].forEach((vals, i) => {
|
salesChildControlarr[index].forEach((vals, i) => {
|
||||||
vals.forEach((item, key) => {
|
vals.forEach((item, key) => {
|
||||||
let saleDate = new Date(item.sales_date);
|
let saleDate = new Date(item.sales_date);
|
||||||
|
|
||||||
item.sales_date = saleDate.getFullYear() + '-' + ("0" + (saleDate.getMonth() + 1)).slice(-2) + '-' + ("0" + (saleDate.getDay() + 1)).slice(-2);
|
item.sales_date = saleDate.getFullYear() + '-' + ("0" + (saleDate.getMonth() + 1)).slice(-2) + '-' + ("0" + (saleDate.getDay() + 1)).slice(-2);
|
||||||
|
//console.log("sale data",new Date(this.pipe.transform(item.sales_date, 'dd-MM-yyyy')))
|
||||||
|
console.log("sale",item.sales_date)
|
||||||
salesChildControl.push(this.dailySalesChildWithData(item, val.sim_id));
|
salesChildControl.push(this.dailySalesChildWithData(item, val.sim_id));
|
||||||
|
this.Value[key]=this.constant.convertNumberToWords(item.sales_value)
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|
||||||
@ -267,6 +272,7 @@ export class PdQuestionAssessedDailySalesPage {
|
|||||||
isactive: ['1'],
|
isactive: ['1'],
|
||||||
margin_per: [data.margin_per],
|
margin_per: [data.margin_per],
|
||||||
margin_value: [data.margin_value],
|
margin_value: [data.margin_value],
|
||||||
|
comments:[data.comments]
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
dailySalesChildWithData(data, fk_id) {
|
dailySalesChildWithData(data, fk_id) {
|
||||||
@ -277,6 +283,7 @@ export class PdQuestionAssessedDailySalesPage {
|
|||||||
simc_id: [data.simc_id],
|
simc_id: [data.simc_id],
|
||||||
fk_sim_id: [fk_id],
|
fk_sim_id: [fk_id],
|
||||||
sales_date: [data.sales_date, Validators.compose([Validators.required])],
|
sales_date: [data.sales_date, Validators.compose([Validators.required])],
|
||||||
|
// sales_date: [new Date(this.pipe.transform(data.sales_date, 'dd-MM-yyyy')), Validators.compose([Validators.required])],
|
||||||
sales_value: [data.sales_value, Validators.compose([Validators.required])],
|
sales_value: [data.sales_value, Validators.compose([Validators.required])],
|
||||||
isactive: ['1'],
|
isactive: ['1'],
|
||||||
})
|
})
|
||||||
|
|||||||
@ -28,13 +28,13 @@
|
|||||||
<mat-radio-button value="2">No</mat-radio-button>
|
<mat-radio-button value="2">No</mat-radio-button>
|
||||||
</mat-radio-group>
|
</mat-radio-group>
|
||||||
</mat-list>
|
</mat-list>
|
||||||
<mat-list style="width: 100%" *ngIf="assessedForm.get('mode').value==2">
|
<!-- <mat-list style="width: 100%" *ngIf="assessedForm.get('mode').value==2">
|
||||||
<p>Sales</p>
|
<p>Sales</p>
|
||||||
<mat-radio-group formControlName="margin">
|
<mat-radio-group formControlName="margin">
|
||||||
<mat-radio-button value="1">Gross Margin</mat-radio-button>
|
<mat-radio-button value="1">Gross Margin</mat-radio-button>
|
||||||
<mat-radio-button value="2">Net Margin</mat-radio-button>
|
<mat-radio-button value="2">Net Margin</mat-radio-button>
|
||||||
</mat-radio-group>
|
</mat-radio-group>
|
||||||
</mat-list>
|
</mat-list> -->
|
||||||
<ion-row>
|
<ion-row>
|
||||||
<button ion-button full color="optblue" (click)="saveAssessedForm(assessedForm.value)"> Proceed</button>
|
<button ion-button full color="optblue" (click)="saveAssessedForm(assessedForm.value)"> Proceed</button>
|
||||||
</ion-row>
|
</ion-row>
|
||||||
@ -119,8 +119,19 @@
|
|||||||
<h1 class="htag">OTHER BUSINESS INCOME</h1>
|
<h1 class="htag">OTHER BUSINESS INCOME</h1>
|
||||||
</mat-card>
|
</mat-card>
|
||||||
</ion-col>
|
</ion-col>
|
||||||
|
<ion-col col-6 text-center *ngIf="finalAccess">
|
||||||
|
<mat-card (click)="getViewPage(11)" class="item-ribbon" style="height: 110px;">
|
||||||
|
<span class="ribbon cruzeiro">
|
||||||
|
<span>--</span>
|
||||||
|
</span>
|
||||||
|
|
||||||
|
<ion-icon class="ion-icon-custome" name="logo-android"></ion-icon>
|
||||||
|
<h1 class="htag">SUMMARY</h1>
|
||||||
|
</mat-card>
|
||||||
|
</ion-col>
|
||||||
</ion-row>
|
</ion-row>
|
||||||
<mat-card *ngIf="finalAccess" style="margin-bottom:10px;">
|
|
||||||
|
<!-- <mat-card *ngIf="finalAccess" style="margin-bottom:10px;">
|
||||||
<h4 text-center>SUMMARY</h4>
|
<h4 text-center>SUMMARY</h4>
|
||||||
<hr>
|
<hr>
|
||||||
<ion-row>
|
<ion-row>
|
||||||
@ -178,6 +189,6 @@
|
|||||||
</ion-row>
|
</ion-row>
|
||||||
<hr>
|
<hr>
|
||||||
|
|
||||||
</mat-card>
|
</mat-card> -->
|
||||||
</div>
|
</div>
|
||||||
</ion-content>
|
</ion-content>
|
||||||
@ -5,6 +5,7 @@ import { FormBuilder, FormGroup, Validators } from '@angular/forms';
|
|||||||
import { QuestionCategoryProvider } from '../../../providers/question-category/question-category';
|
import { QuestionCategoryProvider } from '../../../providers/question-category/question-category';
|
||||||
import { ToastProvider } from '../../../providers/common-provider/toast';
|
import { ToastProvider } from '../../../providers/common-provider/toast';
|
||||||
import { PdQuestionAssessedInfoPage } from '../pd-question-assessed-info/pd-question-assessed-info';
|
import { PdQuestionAssessedInfoPage } from '../pd-question-assessed-info/pd-question-assessed-info';
|
||||||
|
import {PdQuestionAssessedSummaryPage} from '../pd-question-assessed-summary/pd-question-assessed-summary'
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Generated class for the PdQuestionAssessedDashPage page.
|
* Generated class for the PdQuestionAssessedDashPage page.
|
||||||
@ -46,7 +47,7 @@ export class PdQuestionAssessedDashPage {
|
|||||||
fk_pd_id:[this.pdDetails.pd_id],
|
fk_pd_id:[this.pdDetails.pd_id],
|
||||||
mode:[null,Validators.compose([Validators.required])],
|
mode:[null,Validators.compose([Validators.required])],
|
||||||
margin:[null],
|
margin:[null],
|
||||||
fk_createdby:[this.users],
|
fk_createdby:[null],
|
||||||
fk_updatedby:[null],
|
fk_updatedby:[null],
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@ -60,19 +61,37 @@ export class PdQuestionAssessedDashPage {
|
|||||||
}
|
}
|
||||||
getViewPage(pageId)
|
getViewPage(pageId)
|
||||||
{
|
{
|
||||||
|
if(pageId == 11){//Summary
|
||||||
|
this.navCtrl.push(PdQuestionAssessedSummaryPage,{'pdDetails':this.pdDetails,'pageId':pageId})
|
||||||
|
}
|
||||||
|
else{
|
||||||
this.navCtrl.push(PdQuestionAssessedInfoPage,{'pdDetails':this.pdDetails,'pageId':pageId});
|
this.navCtrl.push(PdQuestionAssessedInfoPage,{'pdDetails':this.pdDetails,'pageId':pageId});
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
saveAssessedForm(answerData)
|
saveAssessedForm(answerData)
|
||||||
{
|
{
|
||||||
|
|
||||||
|
|
||||||
if(this.assessedForm.valid)
|
if(this.assessedForm.valid)
|
||||||
{
|
{
|
||||||
|
if(answerData.mode.value == 1 ){
|
||||||
|
this.assessedForm.controls['margin'].setValue(1)
|
||||||
|
}
|
||||||
|
else if(answerData.mode.value == 2 ){
|
||||||
|
this.assessedForm.controls['margin'].setValue(2)
|
||||||
|
}
|
||||||
|
if(this.assessedForm.controls['calc_type_id'].value != null){
|
||||||
|
this.assessedForm.controls['fk_updatedby'].setValue(this.users)
|
||||||
|
}
|
||||||
|
if(this.assessedForm.controls['fk_createdby'].value == null){
|
||||||
|
this.assessedForm.controls['fk_createdby'].setValue(this.users);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
let records = {'records':this.assessedForm.value};
|
let records = {'records':this.assessedForm.value};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
this.qustCat.saveassessedForms('saveAssessedIncomeCalculateMode',records).subscribe(res=>
|
this.qustCat.saveassessedForms('saveAssessedIncomeCalculateMode',records).subscribe(res=>
|
||||||
{
|
{
|
||||||
@ -131,6 +150,7 @@ export class PdQuestionAssessedDashPage {
|
|||||||
this.assessedForm.controls['mode'].setValue(this.grossprofit.mode);
|
this.assessedForm.controls['mode'].setValue(this.grossprofit.mode);
|
||||||
this.assessedForm.controls['margin'].setValue(this.grossprofit.margin);
|
this.assessedForm.controls['margin'].setValue(this.grossprofit.margin);
|
||||||
this.assessedForm.controls['calc_type_id'].setValue(this.grossprofit.calc_type_id);
|
this.assessedForm.controls['calc_type_id'].setValue(this.grossprofit.calc_type_id);
|
||||||
|
this.assessedForm.controls['fk_createdby'].setValue(this.grossprofit.fk_createdby);
|
||||||
}
|
}
|
||||||
|
|
||||||
}else
|
}else
|
||||||
|
|||||||
@ -21,16 +21,21 @@
|
|||||||
<input matInput placeholder="Expense Particulars" type="text" name="expense_value" formControlName="expense_item">
|
<input matInput placeholder="Expense Particulars" type="text" name="expense_value" formControlName="expense_item">
|
||||||
</mat-form-field >
|
</mat-form-field >
|
||||||
<mat-form-field style="width: 100%">
|
<mat-form-field style="width: 100%">
|
||||||
<input matInput placeholder="Amount (Rs)" type="number" name="expense_value" formControlName="expense_value">
|
<input matInput placeholder="Amount (Rs)" type="number" name="expense_value" (keyup)="houseExpensecalculat(i,item.value);inWords($event.target.value,i,1)" formControlName="expense_value">
|
||||||
|
<mat-hint align="end" style="font-size: 11px" *ngIf="item.get('expense_value').value != null">{{"₹"}} {{Value[i]}} Only</mat-hint>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
<mat-form-field style="width: 100%">
|
<mat-form-field style="width: 100%">
|
||||||
<mat-select placeholder="frequency" formControlName="fk_frequency_id" (selectionChange)="houseExpensecalculat(i,item)">
|
<mat-select placeholder="frequency" formControlName="fk_frequency_id" (selectionChange)="houseExpensecalculat(i,item.value)">
|
||||||
<mat-option *ngFor="let frq of m_freqOfPurchase" [value]="frq.frequency_id
|
<mat-option *ngFor="let frq of m_freqOfPurchase" [value]="frq.frequency_id
|
||||||
">{{frq.name}}</mat-option>
|
">{{frq.name}}</mat-option>
|
||||||
</mat-select>
|
</mat-select>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
<mat-form-field style="width: 100%">
|
<mat-form-field style="width: 100%">
|
||||||
<input matInput placeholder="Annual Expenses" type="number" name="annual_expense_value" formControlName="annual_expense_value" readonly>
|
<input matInput placeholder="Annual Expenses" type="number" name="annual_expense_value" formControlName="annual_expense_value" readonly>
|
||||||
|
<mat-hint align="end" style="font-size: 11px" *ngIf="item.get('annual_expense_value').value != null">{{"₹"}} {{AnnualExpenses[i]}} Only</mat-hint>
|
||||||
|
</mat-form-field>
|
||||||
|
<mat-form-field style="width: 100%">
|
||||||
|
<textarea matInput placeholder="Remarks" autocomplete="off" formControlName="comments"></textarea>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
|
|
||||||
<ion-buttons end>
|
<ion-buttons end>
|
||||||
|
|||||||
@ -4,6 +4,7 @@ import { FormArray, FormGroup, FormBuilder, Validators } from '@angular/forms';
|
|||||||
import { AwsServiceProvider } from '../../../providers/aws-service/aws-service';
|
import { AwsServiceProvider } from '../../../providers/aws-service/aws-service';
|
||||||
import { ToastProvider } from '../../../providers/common-provider/toast';
|
import { ToastProvider } from '../../../providers/common-provider/toast';
|
||||||
import { QuestionCategoryProvider } from '../../../providers/question-category/question-category';
|
import { QuestionCategoryProvider } from '../../../providers/question-category/question-category';
|
||||||
|
import { ConstantsProvider } from '../../../providers/constants/constants'
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Generated class for the PdQuestionAssessedHouseholdPage page.
|
* Generated class for the PdQuestionAssessedHouseholdPage page.
|
||||||
@ -27,7 +28,9 @@ export class PdQuestionAssessedHouseholdPage {
|
|||||||
houseannual: any =[];
|
houseannual: any =[];
|
||||||
grandHouseExpenseTotal: any=[];
|
grandHouseExpenseTotal: any=[];
|
||||||
houseHoldForm:FormGroup;
|
houseHoldForm:FormGroup;
|
||||||
constructor(public navCtrl: NavController, public navParams: NavParams,public fb:FormBuilder,public aws:AwsServiceProvider,public toast:ToastProvider,public qustCat:QuestionCategoryProvider) {
|
Value: any=[];
|
||||||
|
AnnualExpenses: any=[];
|
||||||
|
constructor(public navCtrl: NavController, public navParams: NavParams,public fb:FormBuilder,public aws:AwsServiceProvider,public toast:ToastProvider,public qustCat:QuestionCategoryProvider,public cons:ConstantsProvider) {
|
||||||
this.pdDetails = this.navParams.get('pdDetails');
|
this.pdDetails = this.navParams.get('pdDetails');
|
||||||
this.houseExpenseDetails = this.navParams.get('FormId');
|
this.houseExpenseDetails = this.navParams.get('FormId');
|
||||||
this.expenseDetails = this.navParams.get('expense');
|
this.expenseDetails = this.navParams.get('expense');
|
||||||
@ -68,7 +71,8 @@ export class PdQuestionAssessedHouseholdPage {
|
|||||||
expense_item: [null,Validators.compose([Validators.required])],
|
expense_item: [null,Validators.compose([Validators.required])],
|
||||||
expense_value: [null,Validators.compose([Validators.required])],
|
expense_value: [null,Validators.compose([Validators.required])],
|
||||||
fk_frequency_id: [null,Validators.compose([Validators.required])],
|
fk_frequency_id: [null,Validators.compose([Validators.required])],
|
||||||
annual_expense_value: [null,Validators.compose([Validators.required])],
|
annual_expense_value: [null,Validators.compose([Validators.required])],
|
||||||
|
comments:[null],
|
||||||
isactive: ["1"],
|
isactive: ["1"],
|
||||||
fk_createdby: [this.users]
|
fk_createdby: [this.users]
|
||||||
})
|
})
|
||||||
@ -89,56 +93,68 @@ export class PdQuestionAssessedHouseholdPage {
|
|||||||
const control = <FormArray>this.houseHoldForm.controls['houseExpense'] as FormArray;
|
const control = <FormArray>this.houseHoldForm.controls['houseExpense'] as FormArray;
|
||||||
control.removeAt(i)
|
control.removeAt(i)
|
||||||
}
|
}
|
||||||
houseExpensecalculat(index,details)
|
houseExpensecalculat(indexVal,values)
|
||||||
{
|
{
|
||||||
|
|
||||||
let frequencyId = details.value.fk_frequency_id;
|
|
||||||
let expenseValue = details.value.expense_value;
|
|
||||||
// let UOM = details.value.rate_per_unit;
|
|
||||||
// console.log(frequencyId,purchaseQty,UOM,index);
|
|
||||||
// console.log(details);
|
|
||||||
let annual
|
|
||||||
if(expenseValue!=null){
|
|
||||||
if(frequencyId==1)
|
|
||||||
{
|
|
||||||
|
|
||||||
}else if(frequencyId==2)
|
let control:any = <FormArray>this.houseHoldForm.controls['houseExpense'];
|
||||||
{
|
if(values.expense_value!='' && values.fk_frequency_id!='' && values.expense_value!=null && values.fk_frequency_id!=null) {
|
||||||
annual = (expenseValue*250);
|
let filterFrequencyValue: any = this.m_freqOfPurchase.filter(val =>val.frequency_id==values.fk_frequency_id);
|
||||||
this.houseannual[index] = annual;
|
control.controls[indexVal].controls['annual_expense_value'].setValue(parseInt(values.expense_value) * parseInt(filterFrequencyValue[0].mutiple_factor));
|
||||||
details.controls['annual_expense_value'].setValue(annual);
|
this.inWords(parseInt(values.expense_value) * parseInt(filterFrequencyValue[0].mutiple_factor),indexVal,2)
|
||||||
}else if(frequencyId==3)
|
|
||||||
{
|
|
||||||
annual = (expenseValue);
|
|
||||||
this.houseannual[index] = annual;
|
|
||||||
details.controls['annual_expense_value'].setValue(annual);
|
|
||||||
}else if(frequencyId==4)
|
|
||||||
{
|
|
||||||
|
|
||||||
}else if(frequencyId==5)
|
|
||||||
{
|
|
||||||
annual = (expenseValue*12);
|
|
||||||
this.houseannual[index] = annual;
|
|
||||||
details.controls['annual_expense_value'].setValue(annual);
|
|
||||||
}else if(frequencyId==6)
|
|
||||||
{
|
|
||||||
|
|
||||||
}else if(frequencyId==7)
|
|
||||||
{
|
|
||||||
|
|
||||||
}else if(frequencyId==8)
|
|
||||||
{
|
|
||||||
|
|
||||||
}else
|
|
||||||
{
|
|
||||||
|
|
||||||
}
|
|
||||||
this.grandHouseExpenseTotal = this.houseannual.reduce((a,b)=> +a + +b,0);
|
|
||||||
console.log(this.grandHouseExpenseTotal);
|
|
||||||
}else
|
|
||||||
{
|
|
||||||
this.toast.pdTriggerappmessage('Enter the Amount and Frequency');
|
|
||||||
}
|
}
|
||||||
|
else {
|
||||||
|
control.controls[indexVal].controls['annual_expense_value'].setValue(null);
|
||||||
|
}
|
||||||
|
|
||||||
|
//OLD CALCULATION
|
||||||
|
// let frequencyId = details.value.fk_frequency_id;
|
||||||
|
// let expenseValue = details.value.expense_value;
|
||||||
|
// // let UOM = details.value.rate_per_unit;
|
||||||
|
// // console.log(frequencyId,purchaseQty,UOM,index);
|
||||||
|
// // console.log(details);
|
||||||
|
// let annual
|
||||||
|
// if(expenseValue!=null){
|
||||||
|
// if(frequencyId==1)
|
||||||
|
// {
|
||||||
|
|
||||||
|
// }else if(frequencyId==2)
|
||||||
|
// {
|
||||||
|
// annual = (expenseValue*250);
|
||||||
|
// this.houseannual[index] = annual;
|
||||||
|
// details.controls['annual_expense_value'].setValue(annual);
|
||||||
|
// }else if(frequencyId==3)
|
||||||
|
// {
|
||||||
|
// annual = (expenseValue);
|
||||||
|
// this.houseannual[index] = annual;
|
||||||
|
// details.controls['annual_expense_value'].setValue(annual);
|
||||||
|
// }else if(frequencyId==4)
|
||||||
|
// {
|
||||||
|
|
||||||
|
// }else if(frequencyId==5)
|
||||||
|
// {
|
||||||
|
// annual = (expenseValue*12);
|
||||||
|
// this.houseannual[index] = annual;
|
||||||
|
// details.controls['annual_expense_value'].setValue(annual);
|
||||||
|
// }else if(frequencyId==6)
|
||||||
|
// {
|
||||||
|
|
||||||
|
// }else if(frequencyId==7)
|
||||||
|
// {
|
||||||
|
|
||||||
|
// }else if(frequencyId==8)
|
||||||
|
// {
|
||||||
|
|
||||||
|
// }else
|
||||||
|
// {
|
||||||
|
|
||||||
|
// }
|
||||||
|
// this.grandHouseExpenseTotal = this.houseannual.reduce((a,b)=> +a + +b,0);
|
||||||
|
// console.log(this.grandHouseExpenseTotal);
|
||||||
|
// }else
|
||||||
|
// {
|
||||||
|
// this.toast.pdTriggerappmessage('Enter the Amount and Frequency');
|
||||||
|
// }
|
||||||
}
|
}
|
||||||
saveHouseExpenseData(answerData)
|
saveHouseExpenseData(answerData)
|
||||||
{
|
{
|
||||||
@ -171,6 +187,10 @@ export class PdQuestionAssessedHouseholdPage {
|
|||||||
{
|
{
|
||||||
this.houseannual[index] = val.annual_expense_value;
|
this.houseannual[index] = val.annual_expense_value;
|
||||||
control.push(this.createHouseholdwithData(val));
|
control.push(this.createHouseholdwithData(val));
|
||||||
|
if(val.expense_value != null){
|
||||||
|
this.Value[index]=this.cons.convertNumberToWords(val.expense_value)
|
||||||
|
this.AnnualExpenses[index]=this.cons.convertNumberToWords(val.annual_expense_value)
|
||||||
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
this.grandHouseExpenseTotal = this.houseannual.reduce((a,b)=> +a + +b,0);
|
this.grandHouseExpenseTotal = this.houseannual.reduce((a,b)=> +a + +b,0);
|
||||||
@ -186,9 +206,21 @@ export class PdQuestionAssessedHouseholdPage {
|
|||||||
expense_item: [data.expense_item,Validators.compose([Validators.required])],
|
expense_item: [data.expense_item,Validators.compose([Validators.required])],
|
||||||
expense_value: [data.expense_value,Validators.compose([Validators.required])],
|
expense_value: [data.expense_value,Validators.compose([Validators.required])],
|
||||||
fk_frequency_id: [data.fk_frequency_id,Validators.compose([Validators.required])],
|
fk_frequency_id: [data.fk_frequency_id,Validators.compose([Validators.required])],
|
||||||
annual_expense_value: [data.annual_expense_value,Validators.compose([Validators.required])],
|
annual_expense_value: [data.annual_expense_value,Validators.compose([Validators.required])],
|
||||||
|
comments:[data.comments],
|
||||||
isactive: ["1"],
|
isactive: ["1"],
|
||||||
fk_createdby: [this.users]
|
fk_createdby: [this.users]
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
inWords(e,c,flag){
|
||||||
|
switch(flag){
|
||||||
|
case 1 :
|
||||||
|
this.Value[c] = this.cons.convertNumberToWords(e);
|
||||||
|
break;
|
||||||
|
case 2 :
|
||||||
|
this.AnnualExpenses[c] = this.cons.convertNumberToWords(e);
|
||||||
|
break;
|
||||||
|
default : break;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -13,7 +13,9 @@
|
|||||||
|
|
||||||
|
|
||||||
<ion-content padding>
|
<ion-content padding>
|
||||||
<form [formGroup]="grossProfitForm">
|
<div *ngIf="pageId==1">
|
||||||
|
<!--PURCHASE DETAILS ALREADY IN DASH PAGE-->
|
||||||
|
<!-- <form [formGroup]="grossProfitForm">
|
||||||
<mat-card>
|
<mat-card>
|
||||||
|
|
||||||
<mat-card-content>
|
<mat-card-content>
|
||||||
@ -23,10 +25,12 @@
|
|||||||
</mat-select>
|
</mat-select>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
</mat-card-content>
|
</mat-card-content>
|
||||||
|
<ion-buttons end>
|
||||||
<button align="end" ion-button color="optblue" (click)="submitDetails(grossProfitForm.value)">Save</button>
|
<button align="end" ion-button color="optblue" (click)="submitDetails(grossProfitForm.value)">Save</button>
|
||||||
|
</ion-buttons>
|
||||||
</mat-card>
|
</mat-card>
|
||||||
</form>
|
</form> -->
|
||||||
<div *ngIf="pageId==1">
|
|
||||||
|
|
||||||
<!-- <mat-expansion-panel [expanded]="true">
|
<!-- <mat-expansion-panel [expanded]="true">
|
||||||
<mat-expansion-panel-header>
|
<mat-expansion-panel-header>
|
||||||
@ -43,7 +47,7 @@
|
|||||||
<mat-card-content>
|
<mat-card-content>
|
||||||
<!-- <p>Sales declared by the customer as the annual sales actually done.</p> -->
|
<!-- <p>Sales declared by the customer as the annual sales actually done.</p> -->
|
||||||
<mat-form-field style="width: 100%">
|
<mat-form-field style="width: 100%">
|
||||||
<mat-placeholder>Sales Declared by the Customer as the Annual Sales Actually Done</mat-placeholder>
|
<mat-placeholder style="font-size: 14px">Sales Declared by the Customer as the Annual Sales Actually Done</mat-placeholder>
|
||||||
<input matInput autocomplete="off" type="number" formControlName="sales_declared_by_customer" name="sales_declared_by_customer" (keyup)="salesCalculation(assessedForm.value)">
|
<input matInput autocomplete="off" type="number" formControlName="sales_declared_by_customer" name="sales_declared_by_customer" (keyup)="salesCalculation(assessedForm.value)">
|
||||||
<mat-hint align="end" style="font-size: 12px" *ngIf="assessedForm.value.sales_declared_by_customer != ''">{{"₹"}} {{SaleAmtInwords}} Only</mat-hint>
|
<mat-hint align="end" style="font-size: 12px" *ngIf="assessedForm.value.sales_declared_by_customer != ''">{{"₹"}} {{SaleAmtInwords}} Only</mat-hint>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
@ -57,8 +61,11 @@
|
|||||||
<mat-hint align="end" style="font-size: 12px" *ngIf="assessedForm.get('sales_declared_by_customer').value != ''">{{"₹"}} {{marginAmtInwords}} Only</mat-hint>
|
<mat-hint align="end" style="font-size: 12px" *ngIf="assessedForm.get('sales_declared_by_customer').value != ''">{{"₹"}} {{marginAmtInwords}} Only</mat-hint>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
</div>
|
</div>
|
||||||
|
<mat-form-field style="width: 100%">
|
||||||
|
<textarea matInput type="text" placeholder="Remarks" formControlName="comments" autocomplete="off"></textarea>
|
||||||
|
</mat-form-field>
|
||||||
<ion-row>
|
<ion-row>
|
||||||
<br/>
|
<br/><br/>
|
||||||
|
|
||||||
|
|
||||||
<!-- <ion-buttons >
|
<!-- <ion-buttons >
|
||||||
@ -80,7 +87,7 @@
|
|||||||
<mat-expansion-panel>
|
<mat-expansion-panel>
|
||||||
<mat-expansion-panel-header>
|
<mat-expansion-panel-header>
|
||||||
<mat-panel-title>
|
<mat-panel-title>
|
||||||
Sales Details
|
Sales Calculate Item Wise
|
||||||
</mat-panel-title>
|
</mat-panel-title>
|
||||||
</mat-expansion-panel-header>
|
</mat-expansion-panel-header>
|
||||||
|
|
||||||
@ -96,7 +103,7 @@
|
|||||||
|
|
||||||
|
|
||||||
<a (click)="AddAssessedForm()">
|
<a (click)="AddAssessedForm()">
|
||||||
<ion-icon color="optblue" name="md-add" style="font-size: 22px;"></ion-icon>
|
<ion-icon color="optblue" name="add-circle" style="font-size: 24px;"></ion-icon>
|
||||||
</a>
|
</a>
|
||||||
|
|
||||||
|
|
||||||
@ -125,14 +132,14 @@
|
|||||||
<mat-expansion-panel>
|
<mat-expansion-panel>
|
||||||
<mat-expansion-panel-header>
|
<mat-expansion-panel-header>
|
||||||
<mat-panel-title>
|
<mat-panel-title>
|
||||||
Daily Sales Details
|
Sales Calculate Daily Wise
|
||||||
</mat-panel-title>
|
</mat-panel-title>
|
||||||
</mat-expansion-panel-header>
|
</mat-expansion-panel-header>
|
||||||
<mat-card-header><h4>Daily Sales Details</h4></mat-card-header>
|
<mat-card-header><h4>Daily Sales Details</h4></mat-card-header>
|
||||||
<ion-row>
|
<ion-row>
|
||||||
<ion-col offset-11 col-1 text-right>
|
<ion-col offset-11 col-1 text-right>
|
||||||
<a (click)="AddAssessedDailyForm()">
|
<a (click)="AddAssessedDailyForm()">
|
||||||
<ion-icon color="optblue" name="md-add" style="font-size: 22px;"></ion-icon>
|
<ion-icon color="optblue" name="add-circle" style="font-size: 24px;"></ion-icon>
|
||||||
</a>
|
</a>
|
||||||
</ion-col>
|
</ion-col>
|
||||||
</ion-row>
|
</ion-row>
|
||||||
@ -205,13 +212,29 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
<div *ngIf="pageId==2">
|
<div *ngIf="pageId==2">
|
||||||
|
<!--PURCHASE DETAILS ALREADY IN DASH PAGE-->
|
||||||
|
<!-- <form [formGroup]="grossProfitForm">
|
||||||
|
<mat-card>
|
||||||
|
|
||||||
|
<mat-card-content>
|
||||||
|
<mat-form-field style="width:100%">
|
||||||
|
<mat-select placeholder="Purchase Detail Available" formControlName="mode" (selectionChange)="changeOptions(grossProfitForm.value)" required>
|
||||||
|
<mat-option *ngFor="let getData of check__purchse_type" [value]="getData.id">{{getData.name}}</mat-option>
|
||||||
|
</mat-select>
|
||||||
|
</mat-form-field>
|
||||||
|
</mat-card-content>
|
||||||
|
<ion-buttons end>
|
||||||
|
<button align="end" ion-button color="optblue" (click)="submitDetails(grossProfitForm.value)">Save</button>
|
||||||
|
</ion-buttons>
|
||||||
|
</mat-card>
|
||||||
|
</form> -->
|
||||||
<mat-card>
|
<mat-card>
|
||||||
<mat-card-header><h4>Purchase Details</h4></mat-card-header>
|
<mat-card-header><h4>Purchase Item</h4></mat-card-header>
|
||||||
<ion-row>
|
<ion-row>
|
||||||
<ion-col col-3 *ngIf="purchse_details !=''"><a (click)="editPurchaseAllDetails(purchse_details)"><h2>{{"✎"}}</h2></a></ion-col>
|
<ion-col col-3 *ngIf="purchse_details !=''"><a (click)="editPurchaseAllDetails(purchse_details)"><h2>{{"✎"}}</h2></a></ion-col>
|
||||||
<ion-col offset-9 col-3 text-right>
|
<ion-col offset-9 col-3 text-right>
|
||||||
<a (click)="AddPurchaseForm()">
|
<a (click)="AddPurchaseForm()">
|
||||||
<ion-icon name="md-add" color="optblue" style="font-size: 22px;"></ion-icon>
|
<ion-icon name="add-circle" color="optblue" style="font-size: 24px;"></ion-icon>
|
||||||
</a>
|
</a>
|
||||||
</ion-col>
|
</ion-col>
|
||||||
</ion-row>
|
</ion-row>
|
||||||
@ -233,13 +256,13 @@
|
|||||||
</div>
|
</div>
|
||||||
<div *ngIf="pageId==3">
|
<div *ngIf="pageId==3">
|
||||||
<mat-card>
|
<mat-card>
|
||||||
<mat-card-header><h4>Business Expenses</h4></mat-card-header>
|
<mat-card-header><h4>Business Expense Items</h4></mat-card-header>
|
||||||
|
|
||||||
<ion-row>
|
<ion-row>
|
||||||
<ion-col col-3 *ngIf="businessExpenses_details!=''"><a (click)="editExpenseAllDetails(businessExpenses_details)"><h2>{{"✎"}}</h2></a></ion-col>
|
<ion-col col-3 *ngIf="businessExpenses_details!=''"><a (click)="editExpenseAllDetails(businessExpenses_details)"><h2>{{"✎"}}</h2></a></ion-col>
|
||||||
<ion-col offset-6 col-3 text-right>
|
<ion-col offset-6 col-3 text-right>
|
||||||
<a (click)="AddExpenseForm()">
|
<a (click)="AddExpenseForm()">
|
||||||
<ion-icon name="md-add" color="optblue" style="font-size: 22px;"></ion-icon>
|
<ion-icon name="add-circle" color="optblue" style="font-size: 24px;"></ion-icon>
|
||||||
</a>
|
</a>
|
||||||
</ion-col>
|
</ion-col>
|
||||||
</ion-row>
|
</ion-row>
|
||||||
@ -261,7 +284,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div *ngIf="pageId==4">
|
<div *ngIf="pageId==4">
|
||||||
<mat-card>
|
<mat-card>
|
||||||
<mat-card-header><h4>HouseHold Details</h4></mat-card-header>
|
<mat-card-header><h4>House Hold Items</h4></mat-card-header>
|
||||||
|
|
||||||
<ion-row>
|
<ion-row>
|
||||||
<ion-col col-3 *ngIf="houseHold_details !=''"><a (click)="editHouseExpenseAllDetails(houseHold_details)"><h2>{{"✎"}}</h2></a></ion-col>
|
<ion-col col-3 *ngIf="houseHold_details !=''"><a (click)="editHouseExpenseAllDetails(houseHold_details)"><h2>{{"✎"}}</h2></a></ion-col>
|
||||||
@ -289,13 +312,13 @@
|
|||||||
</div>
|
</div>
|
||||||
<div *ngIf="pageId==5">
|
<div *ngIf="pageId==5">
|
||||||
<mat-card>
|
<mat-card>
|
||||||
<mat-card-header><h4>Business Income Details</h4></mat-card-header>
|
<mat-card-header><h4>Other Business Income Items</h4></mat-card-header>
|
||||||
|
|
||||||
<ion-row>
|
<ion-row>
|
||||||
<ion-col col-3 *ngIf="busissnessIncome !=''"><a (click)="editIncomeAllDetails(busissnessIncome)"><h2>{{"✎"}}</h2></a></ion-col>
|
<ion-col col-3 *ngIf="busissnessIncome !=''"><a (click)="editIncomeAllDetails(busissnessIncome)"><h2>{{"✎"}}</h2></a></ion-col>
|
||||||
<ion-col offset-6 col-3 text-right>
|
<ion-col offset-6 col-3 text-right>
|
||||||
<a (click)="AddIncomeForm()">
|
<a (click)="AddIncomeForm()">
|
||||||
<ion-icon name="md-add" color="optblue" style="font-size: 22px;"></ion-icon>
|
<ion-icon name="add-circle" color="optblue" style="font-size: 24px;"></ion-icon>
|
||||||
</a>
|
</a>
|
||||||
</ion-col>
|
</ion-col>
|
||||||
</ion-row>
|
</ion-row>
|
||||||
|
|||||||
@ -91,6 +91,7 @@ export class PdQuestionAssessedInfoPage {
|
|||||||
fk_pd_id:[this.pdDetails.pd_id],
|
fk_pd_id:[this.pdDetails.pd_id],
|
||||||
margin_per:[null],
|
margin_per:[null],
|
||||||
margin_value:[null],
|
margin_value:[null],
|
||||||
|
comments:[null],
|
||||||
isactive:[1],
|
isactive:[1],
|
||||||
fk_createdby:[this.users],
|
fk_createdby:[this.users],
|
||||||
|
|
||||||
@ -141,21 +142,25 @@ export class PdQuestionAssessedInfoPage {
|
|||||||
this.grossProfitForm.controls['margin'].setValue('2');
|
this.grossProfitForm.controls['margin'].setValue('2');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
submitDetails(records: any){
|
|
||||||
if (this.grossProfitForm.invalid) {
|
//PURCHASE DETAILS SUBMIT
|
||||||
|
// submitDetails(records: any){
|
||||||
|
// if (this.grossProfitForm.invalid) {
|
||||||
|
|
||||||
this.toast.pdTriggerappmessage("Please Check All Manatory Fields..");
|
// this.toast.pdTriggerappmessage("Please Check All Manatory Fields..");
|
||||||
return;
|
// return;
|
||||||
}
|
// }
|
||||||
console.log(records);
|
// // let datas:any;
|
||||||
this.qustCat.saveassessedForms('saveAssessedIncomeCalculateMode',records).subscribe(data => {
|
// // datas=records;
|
||||||
this.toast.pdTriggerappmessage('Saved Successfully.');
|
|
||||||
//this.loadAssessedForms.next('1');
|
// this.qustCat.saveassessedForms('saveAssessedIncomeCalculateMode',records).subscribe(data => {
|
||||||
}, error => {
|
// this.toast.pdTriggerappmessage('Saved Successfully.');
|
||||||
this.toast.pdTriggerappmessage('Something Wents Wrong Try Again.!');
|
// //this.loadAssessedForms.next('1');
|
||||||
// this.loadAssessedForms.next('1');
|
// }, error => {
|
||||||
});
|
// this.toast.pdTriggerappmessage('Something Wents Wrong Try Again.!');
|
||||||
}
|
// // this.loadAssessedForms.next('1');
|
||||||
|
// });
|
||||||
|
// }
|
||||||
|
|
||||||
|
|
||||||
getMarginCalc()
|
getMarginCalc()
|
||||||
@ -232,9 +237,12 @@ export class PdQuestionAssessedInfoPage {
|
|||||||
// this.getpurchaseDetails(this.purchse_details);
|
// this.getpurchaseDetails(this.purchse_details);
|
||||||
|
|
||||||
|
|
||||||
|
// this.grossProfitForm.controls['mode'].setValue(res['records'].gross)
|
||||||
|
|
||||||
|
// const control=<FormArray>this.grossProfitForm['controls']
|
||||||
|
// this.grossProfitForm.controls['mode'].setValue(res['records'].gross_profit_calculation_type.mode);
|
||||||
|
// this.grossProfitForm.controls['margin'].setValue(res['records'].gross_profit_calculation_type.margin)
|
||||||
|
// this.grossProfitForm.controls['calc_type_id'].setValue(res['records'].gross_profit_calculation_type.calc_type_id)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -265,6 +273,7 @@ export class PdQuestionAssessedInfoPage {
|
|||||||
this.assessedForm.controls['sdc_id'].setValue(sales_value.sdc_id);
|
this.assessedForm.controls['sdc_id'].setValue(sales_value.sdc_id);
|
||||||
this.assessedForm.controls['sales_declared_by_customer'].setValue(sales_value.sales_declared_by_customer);
|
this.assessedForm.controls['sales_declared_by_customer'].setValue(sales_value.sales_declared_by_customer);
|
||||||
this.assessedForm.controls['margin_value'].setValue(sales_value.margin_value);
|
this.assessedForm.controls['margin_value'].setValue(sales_value.margin_value);
|
||||||
|
this.assessedForm.controls['comments'].setValue(sales_value.comments)
|
||||||
this.assessedForm.controls['margin_per'].setValue(sales_value.margin_per);
|
this.assessedForm.controls['margin_per'].setValue(sales_value.margin_per);
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -273,7 +282,15 @@ export class PdQuestionAssessedInfoPage {
|
|||||||
})
|
})
|
||||||
|
|
||||||
}
|
}
|
||||||
|
grossProfitWithData(data:any){
|
||||||
|
return this.fb.group({
|
||||||
|
calc_type_id:[data.calc_type_id],
|
||||||
|
fk_pd_id:[this.pdDetails.pd_id],
|
||||||
|
company_id:[data.company_id],
|
||||||
|
mode:[data.mode],
|
||||||
|
margin:[data.margin],
|
||||||
|
})
|
||||||
|
}
|
||||||
/**
|
/**
|
||||||
* Add Assessed Forms
|
* Add Assessed Forms
|
||||||
*/
|
*/
|
||||||
@ -288,12 +305,13 @@ export class PdQuestionAssessedInfoPage {
|
|||||||
{
|
{
|
||||||
let salesData = this.sales_item_value.filter(sal=>sal.sci_id==salesCal);
|
let salesData = this.sales_item_value.filter(sal=>sal.sci_id==salesCal);
|
||||||
console.log(salesData);
|
console.log(salesData);
|
||||||
this.navCtrl.push(PdQuestionAssessedSalesPage,{'pdDetails':this.pdDetails,'sales':salesData,'grossprofit':this.grossprofitCalc});
|
// this.navCtrl.push(PdQuestionAssessedSalesPage,{'pdDetails':this.pdDetails,'sales':salesData,'grossprofit':this.grossprofitCalc});
|
||||||
|
this.navCtrl.push(PdQuestionAssessedSalesPage,{'pdDetails':this.pdDetails,'sales':salesData,'margin_calculation_status':this.activateMarginCalculation});
|
||||||
|
|
||||||
}
|
}
|
||||||
editAllDetails(AllsalesData)
|
editAllDetails(AllsalesData)
|
||||||
{
|
{
|
||||||
this.navCtrl.push(PdQuestionAssessedSalesPage,{'pdDetails':this.pdDetails,'sales':AllsalesData,'grossprofit':this.grossprofitCalc});
|
this.navCtrl.push(PdQuestionAssessedSalesPage,{'pdDetails':this.pdDetails,'sales':AllsalesData,'margin_calculation_status':this.activateMarginCalculation});
|
||||||
}
|
}
|
||||||
|
|
||||||
/**Assessed Daily Form Details */
|
/**Assessed Daily Form Details */
|
||||||
@ -306,7 +324,7 @@ export class PdQuestionAssessedInfoPage {
|
|||||||
{
|
{
|
||||||
let dailySaleDetails = this.sales_item_month_value.filter(ass=>ass.sim_id==simId);
|
let dailySaleDetails = this.sales_item_month_value.filter(ass=>ass.sim_id==simId);
|
||||||
console.log(dailySaleDetails);
|
console.log(dailySaleDetails);
|
||||||
this.navCtrl.push(PdQuestionAssessedDailySalesPage,{'pdDetails':this.pdDetails,'salesDaily':dailySaleDetails,'grossprofit':this.grossprofitCalc})
|
this.navCtrl.push(PdQuestionAssessedDailySalesPage,{'pdDetails':this.pdDetails,'salesDaily':dailySaleDetails,'margin_calculation_status':this.activateMarginCalculation})
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -26,7 +26,7 @@
|
|||||||
|
|
||||||
<div fxLayout="column" fxLayoutAlign="start stretch">
|
<div fxLayout="column" fxLayoutAlign="start stretch">
|
||||||
<mat-form-field style="width: 100%">
|
<mat-form-field style="width: 100%">
|
||||||
<input matInput placeholder="Purchase Quantity" type="text" name="purchase_qty" formControlName="purchase_qty" required>
|
<input matInput placeholder="Purchase Quantity" type="number" name="purchase_qty" (keyup)="purchaseCalculation(i,item.value)" formControlName="purchase_qty" required>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
</div>
|
</div>
|
||||||
<div fxLayout="column" fxLayoutAlign="start stretch">
|
<div fxLayout="column" fxLayoutAlign="start stretch">
|
||||||
@ -36,16 +36,21 @@
|
|||||||
<mat-option *ngFor="let uom of UOM" [value]="uom.uom_id">{{uom.name}}</mat-option>
|
<mat-option *ngFor="let uom of UOM" [value]="uom.uom_id">{{uom.name}}</mat-option>
|
||||||
</mat-select>
|
</mat-select>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
<mat-form-field style="width: 100%" *ngIf="item.get('fk_uom_id').value == 1 ">
|
||||||
|
<input matInput autocomplete="off" placeholder="Other UOM" formControlName="uom_other">
|
||||||
|
</mat-form-field>
|
||||||
<div fxLayout="column" fxLayoutAlign="start stretch">
|
<div fxLayout="column" fxLayoutAlign="start stretch">
|
||||||
<mat-form-field style="width: 100%">
|
<mat-form-field style="width: 100%">
|
||||||
<input matInput placeholder="Rate per unit of Purchase" type="text" name="rate_per_unit" formControlName="rate_per_unit"required>
|
<input matInput placeholder="Rate / Unit of Purchase" type="text" name="rate_per_unit" formControlName="rate_per_unit" (keyup)="inWords($event.target.value,i,1)" required>
|
||||||
|
<mat-hint align="end" style="font-size:12px" *ngIf="item.get('rate_per_unit').value != null"> {{"₹"}} {{RateOfPurchase[i]}} Only</mat-hint>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
</div>
|
</div>
|
||||||
<div fxLayout="column" fxLayoutAlign="start stretch">
|
<div fxLayout="column" fxLayoutAlign="start stretch">
|
||||||
<mat-form-field style="width: 100%">
|
<mat-form-field style="width: 100%">
|
||||||
|
|
||||||
<mat-select placeholder="frequency" formControlName="fk_frequency_id" (selectionChange)="salecalculat(i,item)">
|
<mat-select placeholder="Frequency" formControlName="fk_frequency_id" (selectionChange)="purchaseCalculation(i,item.value)">
|
||||||
<mat-option *ngFor="let frq of m_freqOfPurchase" [value]="frq.frequency_id
|
<mat-option *ngFor="let frq of m_freqOfPurchase" [value]="frq.frequency_id
|
||||||
">{{frq.name}}</mat-option>
|
">{{frq.name}}</mat-option>
|
||||||
</mat-select>
|
</mat-select>
|
||||||
@ -53,7 +58,11 @@
|
|||||||
</div>
|
</div>
|
||||||
<div fxLayout="column" fxLayoutAlign="start stretch">
|
<div fxLayout="column" fxLayoutAlign="start stretch">
|
||||||
<mat-form-field style="width: 100%">
|
<mat-form-field style="width: 100%">
|
||||||
<input matInput placeholder="Annual Purchase Value" type="text" name="annual_purchase_value" formControlName="annual_purchase_value" readonly>
|
<input matInput placeholder="Annual Purchase" type="text" name="annual_purchase_value" formControlName="annual_purchase_value" readonly>
|
||||||
|
<mat-hint align="end" style="font-size:12px" *ngIf="item.get('annual_purchase_value').value != null"> {{"₹"}} {{AnnualPurchase[i]}} Only</mat-hint>
|
||||||
|
</mat-form-field>
|
||||||
|
<mat-form-field style="width: 100%">
|
||||||
|
<textarea matInput autocomplete="off" formControlName="comments" placeholder="Remarks"></textarea>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
</div>
|
</div>
|
||||||
<ion-buttons end>
|
<ion-buttons end>
|
||||||
@ -64,7 +73,7 @@
|
|||||||
</ion-col>
|
</ion-col>
|
||||||
<ion-col offset-8 col-3>
|
<ion-col offset-8 col-3>
|
||||||
<a (click)="addPurchaseDetails()" *ngIf="last">
|
<a (click)="addPurchaseDetails()" *ngIf="last">
|
||||||
<ion-icon name="md-add" color="optblue" style="font-size: 22px;"></ion-icon>
|
<ion-icon name="add-circle" color="optblue" style="font-size: 24px;"></ion-icon>
|
||||||
</a>
|
</a>
|
||||||
</ion-col>
|
</ion-col>
|
||||||
|
|
||||||
|
|||||||
@ -4,6 +4,7 @@ import { FormGroup, FormBuilder, Validators, FormArray } from '@angular/forms';
|
|||||||
import { QuestionCategoryProvider } from '../../../providers/question-category/question-category';
|
import { QuestionCategoryProvider } from '../../../providers/question-category/question-category';
|
||||||
import { ToastProvider } from '../../../providers/common-provider/toast';
|
import { ToastProvider } from '../../../providers/common-provider/toast';
|
||||||
import { AwsServiceProvider } from '../../../providers/aws-service/aws-service';
|
import { AwsServiceProvider } from '../../../providers/aws-service/aws-service';
|
||||||
|
import { ConstantsProvider } from '../../../providers/constants/constants'
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Generated class for the PdQuestionAssessedPurchasePage page.
|
* Generated class for the PdQuestionAssessedPurchasePage page.
|
||||||
@ -27,14 +28,19 @@ export class PdQuestionAssessedPurchasePage {
|
|||||||
annual: any = [];
|
annual: any = [];
|
||||||
grandpurchaseTotal: any;
|
grandpurchaseTotal: any;
|
||||||
rawMaterialForm:FormGroup;
|
rawMaterialForm:FormGroup;
|
||||||
constructor(public navCtrl: NavController, public fb:FormBuilder,public navParams: NavParams,public qustCat:QuestionCategoryProvider,public toast:ToastProvider,public aws:AwsServiceProvider) {
|
RateOfPurchase: any=[];
|
||||||
|
AnnualPurchase: any=[];
|
||||||
|
constructor(public navCtrl: NavController, public fb:FormBuilder,public navParams: NavParams,public qustCat:QuestionCategoryProvider,public toast:ToastProvider,public aws:AwsServiceProvider,public cons:ConstantsProvider) {
|
||||||
this.pdDetails = this.navParams.get('pdDetails');
|
this.pdDetails = this.navParams.get('pdDetails');
|
||||||
this.purchaseDetails = this.navParams.get('purchase');
|
this.purchaseDetails = this.navParams.get('purchase');
|
||||||
|
console.log("purchase",this.purchaseDetails)
|
||||||
|
console.log("pd",this.pdDetails);
|
||||||
this.users = this.aws.getlocale();
|
this.users = this.aws.getlocale();
|
||||||
this.rawMaterialForm = this.fb.group(
|
this.rawMaterialForm = this.fb.group(
|
||||||
{
|
{
|
||||||
purchase:this.fb.array([]),
|
purchase:this.fb.array([]),
|
||||||
});
|
});
|
||||||
|
|
||||||
if(this.purchaseDetails!=null)
|
if(this.purchaseDetails!=null)
|
||||||
{
|
{
|
||||||
this.getpurchaseDetails(this.purchaseDetails);
|
this.getpurchaseDetails(this.purchaseDetails);
|
||||||
@ -59,9 +65,11 @@ export class PdQuestionAssessedPurchasePage {
|
|||||||
purchase_item:[null,Validators.compose([Validators.required])],
|
purchase_item:[null,Validators.compose([Validators.required])],
|
||||||
purchase_qty:[null,Validators.compose([Validators.required])],
|
purchase_qty:[null,Validators.compose([Validators.required])],
|
||||||
fk_uom_id:[null,Validators.compose([Validators.required])],
|
fk_uom_id:[null,Validators.compose([Validators.required])],
|
||||||
|
uom_other:[null],
|
||||||
rate_per_unit:[null,Validators.compose([Validators.required])],
|
rate_per_unit:[null,Validators.compose([Validators.required])],
|
||||||
fk_frequency_id:[null,Validators.compose([Validators.required])],
|
fk_frequency_id:[null,Validators.compose([Validators.required])],
|
||||||
annual_purchase_value:[null,Validators.compose([Validators.required])],
|
annual_purchase_value:[null,Validators.compose([Validators.required])],
|
||||||
|
comments:[null],
|
||||||
isactive:['1'],
|
isactive:['1'],
|
||||||
fk_createdby:[this.users]
|
fk_createdby:[this.users]
|
||||||
})
|
})
|
||||||
@ -107,56 +115,67 @@ export class PdQuestionAssessedPurchasePage {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
salecalculat(index,details)
|
purchaseCalculation(indexVal,values)
|
||||||
{
|
{
|
||||||
console.log(this.grandpurchaseTotal);
|
|
||||||
console.log(details,index);
|
|
||||||
let frequencyId = details.value.fk_frequency_id;
|
|
||||||
let purchaseQty = details.value.purchase_qty;
|
|
||||||
let UOM = details.value.rate_per_unit;
|
|
||||||
console.log(frequencyId,purchaseQty,UOM,index);
|
|
||||||
// console.log(frequencyId);
|
|
||||||
let annual
|
|
||||||
if(purchaseQty!=null && UOM!=null){
|
|
||||||
if(frequencyId==1)
|
|
||||||
{
|
|
||||||
|
|
||||||
}else if(frequencyId==2)
|
let control:any = <FormArray>this.rawMaterialForm.controls['purchase'];
|
||||||
{
|
if(values.purchase_qty!='' && values.rate_per_unit!='' && values.fk_frequency_id!='' && values.purchase_qty!=null && values.rate_per_unit!=null && values.fk_frequency_id!=null) {
|
||||||
annual = (purchaseQty*UOM*250);
|
let filterFrequencyValue: any = this.m_freqOfPurchase.filter(val =>val.frequency_id==values.fk_frequency_id);
|
||||||
this.annual[index] = annual;
|
control.controls[indexVal].controls['annual_purchase_value'].setValue(parseInt(values.purchase_qty) * parseInt(values.rate_per_unit) * parseInt(filterFrequencyValue[0].mutiple_factor));
|
||||||
details.controls['annual_purchase_value'].setValue(annual);
|
this.inWords(parseInt(values.purchase_qty) * parseInt(values.rate_per_unit) * parseInt(filterFrequencyValue[0].mutiple_factor),indexVal,2)
|
||||||
}else if(frequencyId==3)
|
|
||||||
{
|
|
||||||
annual = (purchaseQty*UOM);
|
|
||||||
this.annual[index] = annual;
|
|
||||||
details.controls['annual_purchase_value'].setValue(annual);
|
|
||||||
}else if(frequencyId==4)
|
|
||||||
{
|
|
||||||
|
|
||||||
}else if(frequencyId==5)
|
}
|
||||||
{
|
else {
|
||||||
annual = (purchaseQty*UOM*12);
|
control.controls[indexVal].controls['annual_purchase_value'].setValue(null);
|
||||||
this.annual[index] = annual;
|
}
|
||||||
details.controls['annual_purchase_value'].setValue(annual);
|
// console.log(this.grandpurchaseTotal);
|
||||||
}else if(frequencyId==6)
|
// console.log(details,index);
|
||||||
{
|
// let frequencyId = details.value.fk_frequency_id;
|
||||||
|
// let purchaseQty = details.value.purchase_qty;
|
||||||
|
// let UOM = details.value.rate_per_unit;
|
||||||
|
// console.log(frequencyId,purchaseQty,UOM,index);
|
||||||
|
// // console.log(frequencyId);
|
||||||
|
// let annual
|
||||||
|
// if(purchaseQty!=null && UOM!=null){
|
||||||
|
// if(frequencyId==1)
|
||||||
|
// {
|
||||||
|
|
||||||
}else if(frequencyId==7)
|
// }else if(frequencyId==2)
|
||||||
{
|
// {
|
||||||
|
// annual = (purchaseQty*UOM*250);
|
||||||
|
// this.annual[index] = annual;
|
||||||
|
// details.controls['annual_purchase_value'].setValue(annual);
|
||||||
|
// }else if(frequencyId==3)
|
||||||
|
// {
|
||||||
|
// annual = (purchaseQty*UOM);
|
||||||
|
// this.annual[index] = annual;
|
||||||
|
// details.controls['annual_purchase_value'].setValue(annual);
|
||||||
|
// }else if(frequencyId==4)
|
||||||
|
// {
|
||||||
|
|
||||||
}else if(frequencyId==8)
|
// }else if(frequencyId==5)
|
||||||
{
|
// {
|
||||||
|
// annual = (purchaseQty*UOM*12);
|
||||||
|
// this.annual[index] = annual;
|
||||||
|
// details.controls['annual_purchase_value'].setValue(annual);
|
||||||
|
// }else if(frequencyId==6)
|
||||||
|
// {
|
||||||
|
|
||||||
}else
|
// }else if(frequencyId==7)
|
||||||
{
|
// {
|
||||||
|
|
||||||
}
|
// }else if(frequencyId==8)
|
||||||
this.grandpurchaseTotal = this.annual.reduce((a,b)=> +a + +b,0);
|
// {
|
||||||
}else
|
|
||||||
{
|
// }else
|
||||||
this.toast.pdTriggerappmessage('Enter the Purchase Quantity and UOM');
|
// {
|
||||||
}
|
|
||||||
|
// }
|
||||||
|
// this.grandpurchaseTotal = this.annual.reduce((a,b)=> +a + +b,0);
|
||||||
|
// }else
|
||||||
|
// {
|
||||||
|
// this.toast.pdTriggerappmessage('Enter the Purchase Quantity and UOM');
|
||||||
|
// }
|
||||||
}
|
}
|
||||||
savepurchaseData(answerData)
|
savepurchaseData(answerData)
|
||||||
{
|
{
|
||||||
@ -212,11 +231,24 @@ export class PdQuestionAssessedPurchasePage {
|
|||||||
purchase_item:[data.purchase_item,Validators.compose([Validators.required])],
|
purchase_item:[data.purchase_item,Validators.compose([Validators.required])],
|
||||||
purchase_qty:[data.purchase_qty,Validators.compose([Validators.required])],
|
purchase_qty:[data.purchase_qty,Validators.compose([Validators.required])],
|
||||||
fk_uom_id:[data.fk_uom_id,Validators.compose([Validators.required])],
|
fk_uom_id:[data.fk_uom_id,Validators.compose([Validators.required])],
|
||||||
|
uom_other:[data.uom_other],
|
||||||
rate_per_unit:[data.rate_per_unit,Validators.compose([Validators.required])],
|
rate_per_unit:[data.rate_per_unit,Validators.compose([Validators.required])],
|
||||||
fk_frequency_id:[data.fk_frequency_id,Validators.compose([Validators.required])],
|
fk_frequency_id:[data.fk_frequency_id,Validators.compose([Validators.required])],
|
||||||
annual_purchase_value:[data.annual_purchase_value,Validators.compose([Validators.required])],
|
annual_purchase_value:[data.annual_purchase_value,Validators.compose([Validators.required])],
|
||||||
|
comments:[data.comments],
|
||||||
isactive:['1'],
|
isactive:['1'],
|
||||||
fk_createdby:[this.users]
|
fk_createdby:[this.users]
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
inWords(e,c,flag){
|
||||||
|
switch(flag){
|
||||||
|
case 1 :
|
||||||
|
this.RateOfPurchase[c] = this.cons.convertNumberToWords(e);
|
||||||
|
break;
|
||||||
|
case 2 :
|
||||||
|
this.AnnualPurchase[c] = this.cons.convertNumberToWords(e);
|
||||||
|
break;
|
||||||
|
default : break;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -17,7 +17,7 @@
|
|||||||
<div formArrayName="salesCalItemwise">
|
<div formArrayName="salesCalItemwise">
|
||||||
<div *ngFor="let item of assessedForm.get('salesCalItemwise').controls; let i = index;let last = last" [formGroupName]="i">
|
<div *ngFor="let item of assessedForm.get('salesCalItemwise').controls; let i = index;let last = last" [formGroupName]="i">
|
||||||
<mat-card>
|
<mat-card>
|
||||||
<h3>Itemwise</h3>
|
<!-- <h3>Itemwise</h3> -->
|
||||||
<mat-form-field style="width: 100%">
|
<mat-form-field style="width: 100%">
|
||||||
<input type="text" matInput placeholder="Product/Services" formControlName="sales_item" (keyup)="salecalculat(i,item.value)" name="sales_item">
|
<input type="text" matInput placeholder="Product/Services" formControlName="sales_item" (keyup)="salecalculat(i,item.value)" name="sales_item">
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
@ -32,7 +32,7 @@
|
|||||||
<mat-form-field style="width: 100%">
|
<mat-form-field style="width: 100%">
|
||||||
<input type="number" matInput placeholder="Rate/unit of sale" formControlName="rate_per_unit" name="rate_per_unit" (keyup)="inWords($event.target.value,i,4)">
|
<input type="number" matInput placeholder="Rate/unit of sale" formControlName="rate_per_unit" name="rate_per_unit" (keyup)="inWords($event.target.value,i,4)">
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
<mat-label align="end" style="font-size: 12px" *ngIf="item.get('rate_per_unit').value != ''">{{"₹"}} {{ratePerUnitAmtInwords[i]}} Only</mat-label>
|
<mat-label align="end" style="font-size: 12px" *ngIf="item.get('rate_per_unit').value != null">{{"₹"}} {{ratePerUnitAmtInwords[i]}} Only</mat-label>
|
||||||
<mat-form-field style="width: 100%">
|
<mat-form-field style="width: 100%">
|
||||||
<mat-select placeholder="Frequency" formControlName="fk_frequency_id" (selectionChange)="salecalculat(i,item.value)">
|
<mat-select placeholder="Frequency" formControlName="fk_frequency_id" (selectionChange)="salecalculat(i,item.value)">
|
||||||
<mat-option *ngFor="let frq of m_freqOfPurchase" [value]="frq.frequency_id
|
<mat-option *ngFor="let frq of m_freqOfPurchase" [value]="frq.frequency_id
|
||||||
@ -41,7 +41,7 @@
|
|||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
<mat-form-field style="width: 100%">
|
<mat-form-field style="width: 100%">
|
||||||
<input matInput type="number" placeholder="Annual Sales" formControlName="annual_sale_value" name="annual_sale_value" readonly>
|
<input matInput type="number" placeholder="Annual Sales" formControlName="annual_sale_value" name="annual_sale_value" readonly>
|
||||||
<mat-hint align="end" style="font-size: 12px" *ngIf="item.get('rate_per_unit').value != ''">{{"₹"}} {{annualSaleAmtInwords[i]}} Only</mat-hint>
|
<mat-hint align="end" style="font-size: 12px" *ngIf="item.get('rate_per_unit').value != null">{{"₹"}} {{annualSaleAmtInwords[i]}} Only</mat-hint>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
<div *ngIf="margin_calculation_status===true">
|
<div *ngIf="margin_calculation_status===true">
|
||||||
<mat-form-field style="width: 100%">
|
<mat-form-field style="width: 100%">
|
||||||
@ -49,13 +49,17 @@
|
|||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
<mat-form-field style="width: 100%">
|
<mat-form-field style="width: 100%">
|
||||||
<input matInput type="number" placeholder="Margin Amount" (keyup)="salesMarginAmtCalculation(i,item.value)" formControlName="margin_per_uom" name="margin_per_uom">
|
<input matInput type="number" placeholder="Margin Amount" (keyup)="salesMarginAmtCalculation(i,item.value)" formControlName="margin_per_uom" name="margin_per_uom">
|
||||||
<mat-hint align="end" style="font-size: 12px" *ngIf="item.get('rate_per_unit').value != ''">{{"₹"}} {{marginAmtInwords[i]}} Only</mat-hint>
|
<mat-hint align="end" style="font-size: 12px" *ngIf="item.get('rate_per_unit').value != null">{{"₹"}} {{marginAmtInwords[i]}} Only</mat-hint>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
<mat-form-field style="width: 100%">
|
<mat-form-field style="width: 100%">
|
||||||
<input matInput type="number" placeholder="Considered Margin Amount" formControlName="margin_final_value" name="margin_final_value" readonly>
|
<input matInput type="number" placeholder="Considered Margin Amount" formControlName="margin_final_value" name="margin_final_value" readonly>
|
||||||
<mat-hint align="end" style="font-size: 12px" *ngIf="item.get('rate_per_unit').value != ''">{{"₹"}} {{marginFinalAmtInwords[i]}} Only</mat-hint>
|
<mat-hint align="end" style="font-size: 12px" *ngIf="item.get('rate_per_unit').value != null">{{"₹"}} {{marginFinalAmtInwords[i]}} Only</mat-hint>
|
||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
<mat-form-field style="width: 100%">
|
||||||
|
<textarea matInput autocomplete="off" placeholder="Remarks" formControlName="comments"></textarea>
|
||||||
|
</mat-form-field>
|
||||||
<ion-buttons>
|
<ion-buttons>
|
||||||
<ion-row>
|
<ion-row>
|
||||||
<ion-col col-1>
|
<ion-col col-1>
|
||||||
|
|||||||
@ -95,6 +95,7 @@ export class PdQuestionAssessedSalesPage {
|
|||||||
margin_per:[null],
|
margin_per:[null],
|
||||||
margin_per_uom:[null],
|
margin_per_uom:[null],
|
||||||
margin_final_value:[null],
|
margin_final_value:[null],
|
||||||
|
comments:[null]
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -311,6 +312,11 @@ export class PdQuestionAssessedSalesPage {
|
|||||||
|
|
||||||
this.annual[index] = sale.annual_sale_value
|
this.annual[index] = sale.annual_sale_value
|
||||||
control.push(this.createSaleswithData(sale));
|
control.push(this.createSaleswithData(sale));
|
||||||
|
|
||||||
|
this.ratePerUnitAmtInwords[index]=this.cons.convertNumberToWords(sale.rate_per_unit)
|
||||||
|
this.annualSaleAmtInwords[index]=this.cons.convertNumberToWords(sale.annual_sale_value)
|
||||||
|
this.marginAmtInwords[index]=this.cons.convertNumberToWords(sale.margin_per_uom)
|
||||||
|
this.marginFinalAmtInwords[index]=this.cons.convertNumberToWords(sale.margin_final_value)
|
||||||
})
|
})
|
||||||
// this.assessedForm.controls['salesCalItemwise'].setValue(salesData);
|
// this.assessedForm.controls['salesCalItemwise'].setValue(salesData);
|
||||||
// console.log(control);
|
// console.log(control);
|
||||||
@ -332,6 +338,7 @@ export class PdQuestionAssessedSalesPage {
|
|||||||
margin_per:[data.margin_per],
|
margin_per:[data.margin_per],
|
||||||
margin_per_uom:[data.margin_per_uom],
|
margin_per_uom:[data.margin_per_uom],
|
||||||
margin_final_value:[data.margin_final_value],
|
margin_final_value:[data.margin_final_value],
|
||||||
|
comments:[data.comments]
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -0,0 +1,271 @@
|
|||||||
|
<!--
|
||||||
|
Generated template for the PdQuestionAssessedSummaryPage page.
|
||||||
|
|
||||||
|
See http://ionicframework.com/docs/components/#navigation for more info on
|
||||||
|
Ionic pages and navigation.
|
||||||
|
-->
|
||||||
|
<ion-header>
|
||||||
|
|
||||||
|
<ion-navbar color="optblue">
|
||||||
|
<ion-title>Summary</ion-title>
|
||||||
|
</ion-navbar>
|
||||||
|
|
||||||
|
</ion-header>
|
||||||
|
|
||||||
|
|
||||||
|
<ion-content padding >
|
||||||
|
<div *ngIf="loadData==true">
|
||||||
|
<!--Sales Declared by Customer-->
|
||||||
|
<mat-accordion *ngIf="salesCustomer.sales_revenue != null && salesCustomer.sales_revenue != ''" >
|
||||||
|
<mat-expansion-panel>
|
||||||
|
<mat-expansion-panel-header>
|
||||||
|
<mat-panel-title><h6> Declared By Customer </h6></mat-panel-title>
|
||||||
|
</mat-expansion-panel-header>
|
||||||
|
<ion-row>
|
||||||
|
<ion-col>
|
||||||
|
Sales Revenue
|
||||||
|
</ion-col>
|
||||||
|
<ion-col text-right class="val">
|
||||||
|
{{salesCustomer.sales_revenue}}
|
||||||
|
</ion-col>
|
||||||
|
</ion-row>
|
||||||
|
<ion-row>
|
||||||
|
<ion-col>
|
||||||
|
Purchases
|
||||||
|
</ion-col>
|
||||||
|
<ion-col text-right class="val">
|
||||||
|
{{salesCustomer.purchases}}
|
||||||
|
</ion-col>
|
||||||
|
</ion-row>
|
||||||
|
<ion-row>
|
||||||
|
<ion-col>
|
||||||
|
Gross Profit / Loss(a-b)
|
||||||
|
</ion-col>
|
||||||
|
<ion-col text-right class="val">
|
||||||
|
{{salesCustomer.grossprofit}}
|
||||||
|
</ion-col>
|
||||||
|
</ion-row>
|
||||||
|
<ion-row>
|
||||||
|
<ion-col>
|
||||||
|
Business Expenses
|
||||||
|
</ion-col>
|
||||||
|
<ion-col text-right class="val">
|
||||||
|
{{salesCustomer.business_expenses}}
|
||||||
|
</ion-col>
|
||||||
|
</ion-row>
|
||||||
|
<ion-row>
|
||||||
|
<ion-col>
|
||||||
|
Net Profit / Loss(c-d)
|
||||||
|
</ion-col>
|
||||||
|
<ion-col text-right class="val">
|
||||||
|
{{salesCustomer.netprofit}}
|
||||||
|
</ion-col>
|
||||||
|
</ion-row>
|
||||||
|
<ion-row>
|
||||||
|
<ion-col>
|
||||||
|
Household Expenses
|
||||||
|
</ion-col>
|
||||||
|
<ion-col text-right class="val">
|
||||||
|
{{salesCustomer.house_hold_expenses}}
|
||||||
|
</ion-col>
|
||||||
|
</ion-row>
|
||||||
|
<ion-row>
|
||||||
|
<ion-col>
|
||||||
|
Disposable Income
|
||||||
|
</ion-col>
|
||||||
|
<ion-col text-right class="val">
|
||||||
|
{{salesCustomer.disposable_income}}
|
||||||
|
</ion-col>
|
||||||
|
</ion-row>
|
||||||
|
<ion-row>
|
||||||
|
<ion-col>
|
||||||
|
Net Margin %
|
||||||
|
</ion-col>
|
||||||
|
<ion-col text-right class="val">
|
||||||
|
{{salesCustomer.netmargin}} %
|
||||||
|
</ion-col>
|
||||||
|
</ion-row>
|
||||||
|
|
||||||
|
</mat-expansion-panel>
|
||||||
|
</mat-accordion>
|
||||||
|
<br/>
|
||||||
|
<!--Sales calculated by itemWise-->
|
||||||
|
<mat-accordion *ngIf="salesItemWise.sales_revenue != null && salesItemWise.sales_revenue != ''">
|
||||||
|
<mat-expansion-panel>
|
||||||
|
<mat-expansion-panel-header>
|
||||||
|
<mat-panel-title><h6> As Derived from Item Wise Sales </h6></mat-panel-title>
|
||||||
|
</mat-expansion-panel-header>
|
||||||
|
<ion-row>
|
||||||
|
<ion-col>
|
||||||
|
Sales Revenue
|
||||||
|
</ion-col>
|
||||||
|
<ion-col text-right class="val">
|
||||||
|
{{salesItemWise.sales_revenue}}
|
||||||
|
</ion-col>
|
||||||
|
</ion-row>
|
||||||
|
<ion-row>
|
||||||
|
<ion-col>
|
||||||
|
Purchases
|
||||||
|
</ion-col>
|
||||||
|
<ion-col text-right class="val">
|
||||||
|
{{salesItemWise.purchases}}
|
||||||
|
</ion-col>
|
||||||
|
</ion-row>
|
||||||
|
<ion-row>
|
||||||
|
<ion-col>
|
||||||
|
Gross Profit / Loss(a-b)
|
||||||
|
</ion-col>
|
||||||
|
<ion-col text-right class="val">
|
||||||
|
{{salesItemWise.grossprofit}}
|
||||||
|
</ion-col>
|
||||||
|
</ion-row>
|
||||||
|
<ion-row>
|
||||||
|
<ion-col>
|
||||||
|
Business Expenses
|
||||||
|
</ion-col>
|
||||||
|
<ion-col text-right class="val">
|
||||||
|
{{salesItemWise.business_expenses}}
|
||||||
|
</ion-col>
|
||||||
|
</ion-row>
|
||||||
|
<ion-row>
|
||||||
|
<ion-col>
|
||||||
|
Net Profit / Loss(c-d)
|
||||||
|
</ion-col>
|
||||||
|
<ion-col text-right class="val">
|
||||||
|
{{salesItemWise.netprofit}}
|
||||||
|
</ion-col>
|
||||||
|
</ion-row>
|
||||||
|
<ion-row>
|
||||||
|
<ion-col>
|
||||||
|
Household Expenses
|
||||||
|
</ion-col>
|
||||||
|
<ion-col text-right class="val">
|
||||||
|
{{salesItemWise.house_hold_expenses}}
|
||||||
|
</ion-col>
|
||||||
|
</ion-row>
|
||||||
|
<ion-row>
|
||||||
|
<ion-col>
|
||||||
|
Disposable Income
|
||||||
|
</ion-col>
|
||||||
|
<ion-col text-right class="val">
|
||||||
|
{{salesItemWise.disposable_income}}
|
||||||
|
</ion-col>
|
||||||
|
</ion-row>
|
||||||
|
<ion-row>
|
||||||
|
<ion-col>
|
||||||
|
Net Margin %
|
||||||
|
</ion-col>
|
||||||
|
<ion-col text-right class="val">
|
||||||
|
{{salesItemWise.netmargin}} %
|
||||||
|
</ion-col>
|
||||||
|
</ion-row>
|
||||||
|
|
||||||
|
</mat-expansion-panel>
|
||||||
|
</mat-accordion>
|
||||||
|
<br/>
|
||||||
|
|
||||||
|
|
||||||
|
<!--Sales calculated by MonthWise-->
|
||||||
|
<mat-accordion *ngIf="salesMonthWise.sales_revenue != null && salesMonthWise.sales_revenue != ''">
|
||||||
|
<mat-expansion-panel>
|
||||||
|
<mat-expansion-panel-header>
|
||||||
|
<mat-panel-title><h6> As Derived from Kuchha Sales Book/Bills </h6></mat-panel-title>
|
||||||
|
</mat-expansion-panel-header>
|
||||||
|
<ion-row>
|
||||||
|
<ion-col>
|
||||||
|
Sales Revenue
|
||||||
|
</ion-col>
|
||||||
|
<ion-col text-right class="val">
|
||||||
|
{{salesMonthWise.sales_revenue}}
|
||||||
|
</ion-col>
|
||||||
|
</ion-row>
|
||||||
|
<ion-row>
|
||||||
|
<ion-col>
|
||||||
|
Purchases
|
||||||
|
</ion-col>
|
||||||
|
<ion-col text-right class="val">
|
||||||
|
{{salesMonthWise.purchases}}
|
||||||
|
</ion-col>
|
||||||
|
</ion-row>
|
||||||
|
<ion-row>
|
||||||
|
<ion-col>
|
||||||
|
Gross Profit / Loss(a-b)
|
||||||
|
</ion-col>
|
||||||
|
<ion-col text-right class="val">
|
||||||
|
{{salesMonthWise.grossprofit}}
|
||||||
|
</ion-col>
|
||||||
|
</ion-row>
|
||||||
|
<ion-row>
|
||||||
|
<ion-col>
|
||||||
|
Business Expenses
|
||||||
|
</ion-col>
|
||||||
|
<ion-col text-right class="val">
|
||||||
|
{{salesMonthWise.business_expenses}}
|
||||||
|
</ion-col>
|
||||||
|
</ion-row>
|
||||||
|
<ion-row>
|
||||||
|
<ion-col>
|
||||||
|
Net Profit / Loss(c-d)
|
||||||
|
</ion-col>
|
||||||
|
<ion-col text-right class="val">
|
||||||
|
{{salesMonthWise.netprofit}}
|
||||||
|
</ion-col>
|
||||||
|
</ion-row>
|
||||||
|
<ion-row>
|
||||||
|
<ion-col>
|
||||||
|
Household Expenses
|
||||||
|
</ion-col>
|
||||||
|
<ion-col text-right class="val">
|
||||||
|
{{salesMonthWise.house_hold_expenses}}
|
||||||
|
</ion-col>
|
||||||
|
</ion-row>
|
||||||
|
<ion-row>
|
||||||
|
<ion-col>
|
||||||
|
Disposable Income
|
||||||
|
</ion-col>
|
||||||
|
<ion-col text-right class="val">
|
||||||
|
{{salesMonthWise.disposable_income}}
|
||||||
|
</ion-col>
|
||||||
|
</ion-row>
|
||||||
|
<ion-row>
|
||||||
|
<ion-col>
|
||||||
|
Net Margin %
|
||||||
|
</ion-col>
|
||||||
|
<ion-col text-right class="val">
|
||||||
|
{{salesMonthWise.netmargin}} %
|
||||||
|
</ion-col>
|
||||||
|
</ion-row>
|
||||||
|
|
||||||
|
</mat-expansion-panel>
|
||||||
|
</mat-accordion>
|
||||||
|
<br/>
|
||||||
|
|
||||||
|
<mat-card *ngIf="consolidatedReport.consolidated_sales_revenue != null && consolidatedReport.consolidated_sales_revenue != ''">
|
||||||
|
<ion-row>
|
||||||
|
<ion-col class="l_cons">
|
||||||
|
Considered Sales / Revenue
|
||||||
|
</ion-col>
|
||||||
|
<ion-col text-right class="val">
|
||||||
|
{{consolidatedReport.consolidated_sales_revenue}}
|
||||||
|
</ion-col>
|
||||||
|
</ion-row>
|
||||||
|
<ion-row>
|
||||||
|
<ion-col class="l_cons">
|
||||||
|
Considered Net Margin %
|
||||||
|
</ion-col>
|
||||||
|
<ion-col text-right class="val">
|
||||||
|
{{consolidatedReport.consolidated_nermagin}} %
|
||||||
|
</ion-col>
|
||||||
|
</ion-row>
|
||||||
|
<ion-row>
|
||||||
|
<ion-col class="l_cons">
|
||||||
|
Considered Net Profit
|
||||||
|
</ion-col>
|
||||||
|
<ion-col text-right class="val">
|
||||||
|
{{consolidatedReport.consolidated_nerprofit}}
|
||||||
|
</ion-col>
|
||||||
|
</ion-row>
|
||||||
|
</mat-card>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</ion-content>
|
||||||
@ -0,0 +1,21 @@
|
|||||||
|
page-pd-question-assessed-summary {
|
||||||
|
.val{
|
||||||
|
font-weight: bold
|
||||||
|
}
|
||||||
|
.l_cons{
|
||||||
|
color:seagreen;
|
||||||
|
font-weight:bold
|
||||||
|
}
|
||||||
|
.mat-card{
|
||||||
|
border-radius: 10px;
|
||||||
|
margin-bottom: 15px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.scroll-content{
|
||||||
|
background-color: #eee;
|
||||||
|
}
|
||||||
|
.mat-expansion-panel-header{
|
||||||
|
padding: 30px;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@ -0,0 +1,50 @@
|
|||||||
|
import { Component } from '@angular/core';
|
||||||
|
import { IonicPage, NavController, NavParams } from 'ionic-angular';
|
||||||
|
import {QuestionCategoryProvider} from '../../../providers/question-category/question-category'
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Generated class for the PdQuestionAssessedSummaryPage page.
|
||||||
|
*
|
||||||
|
* See https://ionicframework.com/docs/components/#navigation for more info on
|
||||||
|
* Ionic pages and navigation.
|
||||||
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
@Component({
|
||||||
|
selector: 'page-pd-question-assessed-summary',
|
||||||
|
templateUrl: 'pd-question-assessed-summary.html',
|
||||||
|
})
|
||||||
|
export class PdQuestionAssessedSummaryPage {
|
||||||
|
pdDetails:any;
|
||||||
|
salesCustomer:any;
|
||||||
|
salesMonthWise:any;
|
||||||
|
salesItemWise:any;
|
||||||
|
consolidatedReport:any;
|
||||||
|
loadData:boolean=false;
|
||||||
|
constructor(public navCtrl: NavController, public navParams: NavParams,public qustCat: QuestionCategoryProvider) {
|
||||||
|
this.pdDetails=this.navParams.get('pdDetails')
|
||||||
|
// console.log(this.pdDetails)
|
||||||
|
this.getAssessedDetails();
|
||||||
|
}
|
||||||
|
ionViewWillEnter(){
|
||||||
|
//console.log("ionViewWillEnter")
|
||||||
|
//this.getAssessedDetails();
|
||||||
|
}
|
||||||
|
ionViewDidLoad() {
|
||||||
|
console.log('ionViewDidLoad PdQuestionAssessedSummaryPage');
|
||||||
|
|
||||||
|
}
|
||||||
|
getAssessedDetails(){
|
||||||
|
let records = {'pd_id':this.pdDetails.pd_id};
|
||||||
|
this.qustCat.retiverassessedForm('getAssessedIncome',records).subscribe(res=>{
|
||||||
|
if(res['dataStatus']== true){
|
||||||
|
this.salesCustomer=res['records'].final_data[0].sales_declared_by_customer
|
||||||
|
this.salesItemWise=res['records'].final_data[0].sales_calculated_by_itemwise
|
||||||
|
this.salesMonthWise=res['records'].final_data[0].sales_calculated_by_monthwise
|
||||||
|
this.consolidatedReport=res['records'].final_data[0].consolidated_report
|
||||||
|
console.log(this.salesCustomer);
|
||||||
|
this.loadData=true
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -19,7 +19,7 @@ public commonimage = "http://ssa.sineedge.com/sparqapi/logo/avatar.jpg";
|
|||||||
let testapiurl = 'http://ssa.sineedge.com/sparqtest/api/';
|
let testapiurl = 'http://ssa.sineedge.com/sparqtest/api/';
|
||||||
let devapiurl = 'http://ssa.sineedge.com/sparqapi/api/';
|
let devapiurl = 'http://ssa.sineedge.com/sparqapi/api/';
|
||||||
let localapiurl = 'http://192.168.0.9/sparqapi/api/';
|
let localapiurl = 'http://192.168.0.9/sparqapi/api/';
|
||||||
return devapiurl;
|
return testapiurl;
|
||||||
}
|
}
|
||||||
|
|
||||||
getcurrentDate()
|
getcurrentDate()
|
||||||
|
|||||||
@ -29175,6 +29175,28 @@ page-pd-question-assessed-info textarea.mat-input-element {
|
|||||||
margin: 5px 0;
|
margin: 5px 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
page-pd-question-assessed-summary .val {
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
|
||||||
|
page-pd-question-assessed-summary .l_cons {
|
||||||
|
color: seagreen;
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
|
||||||
|
page-pd-question-assessed-summary .mat-card {
|
||||||
|
border-radius: 10px;
|
||||||
|
margin-bottom: 15px;
|
||||||
|
}
|
||||||
|
|
||||||
|
page-pd-question-assessed-summary .scroll-content {
|
||||||
|
background-color: #eee;
|
||||||
|
}
|
||||||
|
|
||||||
|
page-pd-question-assessed-summary .mat-expansion-panel-header {
|
||||||
|
padding: 30px;
|
||||||
|
}
|
||||||
|
|
||||||
page-pd-question-assests .scroll-content {
|
page-pd-question-assests .scroll-content {
|
||||||
padding: 16px;
|
padding: 16px;
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user