This is an automated email from the ASF dual-hosted git repository. dgnatyshyn pushed a commit to branch DLAB-1715 in repository https://gitbox.apache.org/repos/asf/incubator-dlab.git
commit 08f2e36990b4268d05ad7a2da5fb373c84067aac Author: Dmytro_Gnatyshyn <[email protected]> AuthorDate: Wed Jul 29 16:22:27 2020 +0300 [DLAB-1715]: Small fix --- .../src/app/core/services/applicationSecurity.service.ts | 1 - .../webapp/src/app/shared/navbar/navbar.component.ts | 11 +++-------- 2 files changed, 3 insertions(+), 9 deletions(-) diff --git a/services/self-service/src/main/resources/webapp/src/app/core/services/applicationSecurity.service.ts b/services/self-service/src/main/resources/webapp/src/app/core/services/applicationSecurity.service.ts index fae09ef..1bcd4f8 100644 --- a/services/self-service/src/main/resources/webapp/src/app/core/services/applicationSecurity.service.ts +++ b/services/self-service/src/main/resources/webapp/src/app/core/services/applicationSecurity.service.ts @@ -87,7 +87,6 @@ export class ApplicationSecurityService { map(response => { this.storage.destroyTokens(); this.storage.setBillingQuoteUsed(''); - this.storage.setIsBillingQuoteUsed(''); this._loggedInStatus.next(false); return response; }, this)); diff --git a/services/self-service/src/main/resources/webapp/src/app/shared/navbar/navbar.component.ts b/services/self-service/src/main/resources/webapp/src/app/shared/navbar/navbar.component.ts index 7be914f..7046696 100644 --- a/services/self-service/src/main/resources/webapp/src/app/shared/navbar/navbar.component.ts +++ b/services/self-service/src/main/resources/webapp/src/app/shared/navbar/navbar.component.ts @@ -164,14 +164,9 @@ export class NavbarComponent implements OnInit, OnDestroy { } private checkQuoteUsed(): void { - if (!this.storage.getBillingQuoteUsed( ) && !this.storage.getIsBillingQuoteUsed()) { + if (!this.storage.getBillingQuoteUsed( )) { this.healthStatusService.getQuotaStatus().pipe(take(1)).subscribe((params: Quota) => { let checkQuotaAlert = ''; - params = { - projectQuotas: {Proj1: 99, Proj2: 99, Proj3: 99, Proj4: 99}, - totalQuotaUsed: 50 - }; - const exceedProjects = [], informProjects = []; Object.keys(params.projectQuotas).forEach(key => { if (params.projectQuotas[key] > this.quotesLimit && params.projectQuotas[key] < 100) { @@ -192,9 +187,9 @@ export class NavbarComponent implements OnInit, OnDestroy { if (Number(params.totalQuotaUsed) >= 100) checkQuotaAlert = 'total_exceed'; if (checkQuotaAlert === '') { - this.storage.setIsBillingQuoteUsed(true); + this.storage.setBillingQuoteUsed('informed'); } else { - this.storage.setIsBillingQuoteUsed(''); + this.storage.setBillingQuoteUsed(''); } if (this.dialog.openDialogs.length > 0 || this.dialog.openDialogs.length > 0) return; --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
