| }, | }, | ||||
| "private": true, | "private": true, | ||||
| "dependencies": { | "dependencies": { | ||||
| "@angular/animations": "~11.2.5", | |||||
| "@angular/common": "~11.2.5", | |||||
| "@angular/compiler": "~11.2.5", | |||||
| "@angular/core": "~11.2.5", | |||||
| "@angular/forms": "~11.2.5", | |||||
| "@angular/localize": "~11.2.5", | |||||
| "@angular/platform-browser": "~11.2.5", | |||||
| "@angular/platform-browser-dynamic": "~11.2.5", | |||||
| "@angular/router": "~11.2.5", | |||||
| "@angular/animations": "^11.2.9", | |||||
| "@angular/common": "^11.2.9", | |||||
| "@angular/compiler": "^11.2.9", | |||||
| "@angular/core": "^11.2.9", | |||||
| "@angular/forms": "^11.2.9", | |||||
| "@angular/localize": "^11.2.9", | |||||
| "@angular/platform-browser": "^11.2.9", | |||||
| "@angular/platform-browser-dynamic": "^11.2.9", | |||||
| "@angular/router": "^11.2.9", | |||||
| "@fortawesome/angular-fontawesome": "^0.8.2", | "@fortawesome/angular-fontawesome": "^0.8.2", | ||||
| "@fortawesome/fontawesome-svg-core": "^1.2.34", | |||||
| "@fortawesome/free-solid-svg-icons": "^5.15.2", | |||||
| "@fortawesome/fontawesome-svg-core": "^1.2.35", | |||||
| "@fortawesome/free-solid-svg-icons": "^5.15.3", | |||||
| "@progress/kendo-angular-buttons": "^6.1.0", | "@progress/kendo-angular-buttons": "^6.1.0", | ||||
| "@progress/kendo-angular-charts": "^5.1.0", | "@progress/kendo-angular-charts": "^5.1.0", | ||||
| "@progress/kendo-angular-common": "^2.0.0", | "@progress/kendo-angular-common": "^2.0.0", | ||||
| "@progress/kendo-angular-dateinputs": "^5.1.0", | "@progress/kendo-angular-dateinputs": "^5.1.0", | ||||
| "@progress/kendo-angular-dialog": "^5.0.0", | "@progress/kendo-angular-dialog": "^5.0.0", | ||||
| "@progress/kendo-angular-dropdowns": "^5.0.0", | |||||
| "@progress/kendo-angular-editor": "^2.0.1", | |||||
| "@progress/kendo-angular-dropdowns": "^5.2.0", | |||||
| "@progress/kendo-angular-editor": "^2.0.2", | |||||
| "@progress/kendo-angular-excel-export": "^4.0.0", | "@progress/kendo-angular-excel-export": "^4.0.0", | ||||
| "@progress/kendo-angular-grid": "^5.0.3", | "@progress/kendo-angular-grid": "^5.0.3", | ||||
| "@progress/kendo-angular-icons": "^0.4.2", | "@progress/kendo-angular-icons": "^0.4.2", | ||||
| "@progress/kendo-angular-indicators": "^1.0.0", | "@progress/kendo-angular-indicators": "^1.0.0", | ||||
| "@progress/kendo-angular-inputs": "^7.0.0", | |||||
| "@progress/kendo-angular-inputs": "^7.2.0", | |||||
| "@progress/kendo-angular-intl": "^3.0.0", | "@progress/kendo-angular-intl": "^3.0.0", | ||||
| "@progress/kendo-angular-l10n": "^3.0.0", | "@progress/kendo-angular-l10n": "^3.0.0", | ||||
| "@progress/kendo-angular-label": "^3.0.1", | |||||
| "@progress/kendo-angular-layout": "6", | |||||
| "@progress/kendo-angular-menu": "^3.0.0", | |||||
| "@progress/kendo-angular-label": "^3.0.2", | |||||
| "@progress/kendo-angular-layout": "^6.1.4", | |||||
| "@progress/kendo-angular-menu": "^3.0.1", | |||||
| "@progress/kendo-angular-navigation": "^1.0.0", | "@progress/kendo-angular-navigation": "^1.0.0", | ||||
| "@progress/kendo-angular-notification": "^3.0.0", | "@progress/kendo-angular-notification": "^3.0.0", | ||||
| "@progress/kendo-angular-pager": "^2.0.0", | "@progress/kendo-angular-pager": "^2.0.0", | ||||
| "@progress/kendo-angular-popup": "^4.0.0", | "@progress/kendo-angular-popup": "^4.0.0", | ||||
| "@progress/kendo-angular-progressbar": "^2.0.0", | "@progress/kendo-angular-progressbar": "^2.0.0", | ||||
| "@progress/kendo-angular-toolbar": "^4.0.0", | "@progress/kendo-angular-toolbar": "^4.0.0", | ||||
| "@progress/kendo-angular-treeview": "^5.0.0", | |||||
| "@progress/kendo-angular-treeview": "^5.1.1", | |||||
| "@progress/kendo-angular-upload": "^7.1.0", | "@progress/kendo-angular-upload": "^7.1.0", | ||||
| "@progress/kendo-data-query": "^1.5.4", | "@progress/kendo-data-query": "^1.5.4", | ||||
| "@progress/kendo-drawing": "^1.5.12", | |||||
| "@progress/kendo-licensing": "^1.0.2", | |||||
| "@progress/kendo-drawing": "^1.10.0", | |||||
| "@progress/kendo-licensing": "^1.1.4", | |||||
| "@progress/kendo-svg-icons": "^0.1.2", | "@progress/kendo-svg-icons": "^0.1.2", | ||||
| "@progress/kendo-theme-default": "^4.36.0", | "@progress/kendo-theme-default": "^4.36.0", | ||||
| "bootstrap": "^4.6.0", | "bootstrap": "^4.6.0", | ||||
| "hammerjs": "^2.0.8", | "hammerjs": "^2.0.8", | ||||
| "rxjs": "^6.6.6", | |||||
| "rxjs": "^6.6.7", | |||||
| "ts-debounce": "^3.0.0", | "ts-debounce": "^3.0.0", | ||||
| "tslib": "^2.1.0", | |||||
| "tslib": "^2.2.0", | |||||
| "zone.js": "~0.11.4" | "zone.js": "~0.11.4" | ||||
| }, | }, | ||||
| "devDependencies": { | "devDependencies": { | ||||
| "@angular-devkit/build-angular": "~0.1102.4", | |||||
| "@angular/cli": "~11.2.4", | |||||
| "@angular/compiler-cli": "~11.2.5", | |||||
| "@types/jasmine": "~3.6.6", | |||||
| "@angular-devkit/build-angular": "^0.1102.8", | |||||
| "@angular/cli": "^11.2.8", | |||||
| "@angular/compiler-cli": "^11.2.9", | |||||
| "@types/jasmine": "^3.6.9", | |||||
| "@types/jasminewd2": "~2.0.8", | "@types/jasminewd2": "~2.0.8", | ||||
| "@types/node": "^14.14.33", | |||||
| "@types/node": "^14.14.37", | |||||
| "codelyzer": "^6.0.1", | "codelyzer": "^6.0.1", | ||||
| "jasmine-core": "~3.6.0", | "jasmine-core": "~3.6.0", | ||||
| "jasmine-spec-reporter": "~6.0.0", | "jasmine-spec-reporter": "~6.0.0", | ||||
| "protractor": "~7.0.0", | "protractor": "~7.0.0", | ||||
| "ts-node": "~9.1.1", | "ts-node": "~9.1.1", | ||||
| "tslint": "~6.1.0", | "tslint": "~6.1.0", | ||||
| "typescript": "^4.1.5" | |||||
| "typescript": "4.1.5" | |||||
| } | } | ||||
| } | } |
| import {Component, Input, OnInit, Output, EventEmitter} from '@angular/core'; | |||||
| import {Component, EventEmitter, Input, OnInit, Output} from '@angular/core'; | |||||
| import {FormControl, FormGroup, NgForm, Validators} from '@angular/forms'; | import {FormControl, FormGroup, NgForm, Validators} from '@angular/forms'; | ||||
| import {LoanModel} from '../../models/loan.model'; | import {LoanModel} from '../../models/loan.model'; | ||||
| import {LoanSingleService} from '../../service/loan.single.service'; | import {LoanSingleService} from '../../service/loan.single.service'; | ||||
| public removeHandler({ dataItem }): void { | public removeHandler({ dataItem }): void { | ||||
| console.log(dataItem); | console.log(dataItem); | ||||
| const na = this.Loan.PayIn.filter(v => { | |||||
| this.Loan.PayIn = this.Loan.PayIn.filter(v => { | |||||
| return v.Id !== dataItem.Id; | return v.Id !== dataItem.Id; | ||||
| }); | }); | ||||
| this.Loan.PayIn = na; | |||||
| this.ls.removePayIn(dataItem.Id); | this.ls.removePayIn(dataItem.Id); | ||||
| } | } | ||||
| </ng-template> | </ng-template> | ||||
| <ng-template kendoGridEditTemplate | <ng-template kendoGridEditTemplate | ||||
| let-dataItem="dataItem" | let-dataItem="dataItem" | ||||
| let-formGroup="formGroup"> | |||||
| let-formGroup="incomeFormGroup"> | |||||
| <kendo-switch [checked]="dataItem.Balance >=0" | <kendo-switch [checked]="dataItem.Balance >=0" | ||||
| name="showBalance" [(ngModel)]="showBalance" | name="showBalance" [(ngModel)]="showBalance" | ||||
| > | > | ||||
| </kendo-switch> | </kendo-switch> | ||||
| <kendo-numerictextbox *ngIf="showBalance" name="balance" [formControl]="formGroup.get('Balance')" | |||||
| <kendo-numerictextbox *ngIf="showBalance" name="balance" | |||||
| [formControl]="incomeFormGroup.get('Balance')" | |||||
| [min]="-1" [max]="999999999" [autoCorrect]="true" class="balance"> | [min]="-1" [max]="999999999" [autoCorrect]="true" class="balance"> | ||||
| </kendo-numerictextbox> | </kendo-numerictextbox> | ||||
| </ng-template> | </ng-template> | ||||
| </ng-template> | </ng-template> | ||||
| <ng-template kendoGridEditTemplate | <ng-template kendoGridEditTemplate | ||||
| let-dataItem="dataItem" | let-dataItem="dataItem" | ||||
| let-formGroup="formGroup"> | |||||
| let-formGroup="incomeFormGroup"> | |||||
| <kendo-switch [checked]="dataItem.OffsetBalance >=0" | <kendo-switch [checked]="dataItem.OffsetBalance >=0" | ||||
| name="showOffsetBalance" [(ngModel)]="showOffsetBalance" | name="showOffsetBalance" [(ngModel)]="showOffsetBalance" | ||||
| </kendo-switch> | </kendo-switch> | ||||
| <kendo-numerictextbox *ngIf="showOffsetBalance" name="offsetBalance" | <kendo-numerictextbox *ngIf="showOffsetBalance" name="offsetBalance" | ||||
| [formControl]="formGroup.get('OffsetBalance')" | |||||
| [formControl]="incomeFormGroup.get('OffsetBalance')" | |||||
| [min]="-1" [max]="999999999" [autoCorrect]="true" class="balance"> | [min]="-1" [max]="999999999" [autoCorrect]="true" class="balance"> | ||||
| </kendo-numerictextbox> | </kendo-numerictextbox> | ||||
| </ng-template> | </ng-template> | ||||
| <ng-template kendoGridCellTemplate let-dataItem let-rowIndex="rowIndex" > | <ng-template kendoGridCellTemplate let-dataItem let-rowIndex="rowIndex" > | ||||
| <button kendoButton *ngIf="dataItem.UploadId > 0" (click)="showUpload(dataItem.UploadId)" icon="attachment"> {{ dataItem.UploadId }} | <button kendoButton *ngIf="dataItem.UploadId > 0" (click)="showUpload(dataItem.UploadId)" icon="attachment"> {{ dataItem.UploadId }} | ||||
| </button> | </button> | ||||
| <p *ngIf="dataItem.Uploads <=0" align="center"> - </p> | |||||
| <p *ngIf="dataItem.Uploads <=0" > - </p> | |||||
| </ng-template> | </ng-template> | ||||
| </kendo-grid-column> | </kendo-grid-column> | ||||
| ngOnInit(): void { | ngOnInit(): void { | ||||
| this.pis.getPayInList(new PayInListFilterModel()).subscribe( | this.pis.getPayInList(new PayInListFilterModel()).subscribe( | ||||
| ( resp: PayInListResult) => { | ( resp: PayInListResult) => { | ||||
| console.log(resp); | |||||
| this.gridData = resp; | this.gridData = resp; | ||||
| } | } | ||||
| ); | ); | ||||
| public addHandler({ sender }): void { | public addHandler({ sender }): void { | ||||
| this.closeEditor(sender); | this.closeEditor(sender); | ||||
| let balance = -1; | |||||
| let offsetBalance = -1; | |||||
| // if ( this.Loan.PayIn.length > 0) { | |||||
| // const idx = this.Loan.PayIn.length -1; | |||||
| // balance = this.Loan.PayIn[idx].Balance; | |||||
| // offsetBalance = this.Loan.PayIn[idx].OffsetBalance; | |||||
| // } | |||||
| // this.showBalance = balance >= 0 ; | |||||
| // this.showOffsetBalance = offsetBalance >= 0 ; | |||||
| const balance = -1; | |||||
| const offsetBalance = -1; | |||||
| this.showBalance = balance >= 0 ; | |||||
| this.showOffsetBalance = offsetBalance >= 0 ; | |||||
| this.incomeFormGroup = createFormGroup({ | this.incomeFormGroup = createFormGroup({ | ||||
| Id: 0, | Id: 0, | ||||
| Trail: 168, | Trail: 168, | ||||
| // 0, | // 0, | ||||
| // ); | // ); | ||||
| //console.log('saving PayIn', pi); | |||||
| // console.log('saving PayIn', pi); | |||||
| // this.ls.savePayIn(pi, isNew).subscribe( | // this.ls.savePayIn(pi, isNew).subscribe( | ||||
| // (resp: PayInModel) => { | // (resp: PayInModel) => { | ||||
| // this.Loan.cuPayIn(resp); | // this.Loan.cuPayIn(resp); |
| <div class="outer-div"> | <div class="outer-div"> | ||||
| <div class="inner-div"> | <div class="inner-div"> | ||||
| <div class="front"> | <div class="front"> | ||||
| <div class="front__bkg-photo" [ngStyle]="{'background-image': bgPhoto() }"></div> | |||||
| <div class="front__face-photo" [ngStyle]="{'background-image': photoURL() }"> | |||||
| <div class="front__bkg-photo" [ngStyle]="{'background-image': 'url(' + bgPhoto() + ')' }"></div> | |||||
| <div class="front__face-photo" [ngStyle]="{'background-image': 'url(' + photoURL() +')' }"> | |||||
| </div> | </div> | ||||
| <div class="front__text"> | <div class="front__text"> | ||||
| <h3 class="front__text-header">{{contact.Display}} </h3> | <h3 class="front__text-header">{{contact.Display}} </h3> |
| photoURL(): string { | photoURL(): string { | ||||
| if (this.contact === undefined ) { return ''; } | if (this.contact === undefined ) { return ''; } | ||||
| const url = 'url(' + this.auth.getUrl('avatar/') + this.contact.Id + ')'; | |||||
| const url = this.auth.getUrl('avatar/') + this.contact.Id ; | |||||
| return url; | return url; | ||||
| } | } | ||||
| public bgPhoto(): string { | public bgPhoto(): string { | ||||
| if ( !this.contact.Enabled ){ | if ( !this.contact.Enabled ){ | ||||
| return 'url("../../assets/img/bg-disabled-card.jpg")'; | |||||
| return '../../assets/img/bg/bg-disabled-card.jpg'; | |||||
| } | } | ||||
| switch (this.UserExtra.Role) { | switch (this.UserExtra.Role) { | ||||
| case 'broker': | case 'broker': | ||||
| return 'url("../../assets/img/bg-client-card.jpg")'; | |||||
| return '../../assets/img/bg/bg-client-card.jpg'; | |||||
| case 'user': | case 'user': | ||||
| return 'url("../../assets/img/bg-user-card.jpg")'; | |||||
| return '../../assets/img/bg/bg-user-card.jpg'; | |||||
| case 'people': | case 'people': | ||||
| return 'url("../../assets/img/bg-broker-card.jpg")'; | |||||
| return '../../assets/img/bg/bg-broker-card.jpg'; | |||||
| case 'admin': | case 'admin': | ||||
| return 'url("../../assets/img/bg-admin-card.jpg")'; | |||||
| return '../../assets/img/bg/bg-admin-card.jpg'; | |||||
| } | } | ||||
| } | } |
| width: 100%; | width: 100%; | ||||
| height: 100vh; | height: 100vh; | ||||
| opacity: 0.95; | opacity: 0.95; | ||||
| background: url('/assets/img/bg-settings.jpg') no-repeat center center fixed; | |||||
| background: url('../../assets/img/bg/bg-settings.jpg') no-repeat center center fixed; | |||||
| background-size: cover; | background-size: cover; | ||||
| } | } | ||||
| width: 100%; | width: 100%; | ||||
| height: 100vh; | height: 100vh; | ||||
| opacity: 0.95; | opacity: 0.95; | ||||
| background: url('/assets/img/bg-settings.jpg') no-repeat center center fixed; | |||||
| background: url('../../assets/img/bg/bg-settings.jpg') no-repeat center center fixed; | |||||
| background-size: cover; | background-size: cover; | ||||
| } | } | ||||