Skip to content

Commit

Permalink
Merge pull request #1801 from ORNL-AMO/issue-1790-b
Browse files Browse the repository at this point in the history
fix fontawesome exclamation point
  • Loading branch information
rmroot authored Jan 31, 2025
2 parents b15856a + e649850 commit a884de5
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 29 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ <h1 class="card-title"><span class="fa fa-building"></span> {{account.name}}</h1
<span
class="position-absolute top-0 start-100 translate-middle badge rounded-pill bg-danger"
*ngIf="energyAnalysisNeeded || waterAnalysisNeeded">
<span class="fa-exclamation white"></span>
<span class="fa fa-exclamation white"></span>
</span>
</button>
</div>
Expand Down Expand Up @@ -67,7 +67,7 @@ <h1 class="card-title"><span class="fa fa-building"></span> {{account.name}}</h1
<li class="list-group-item" *ngIf="energyAnalysisNeeded">
<a class="nav-link" routerLink="/account/analysis/dashboard/energy">
<span class="badge rounded-pill bg-danger">
<span class="fa-exclamation white"></span>
<span class="fa fa-exclamation white"></span>
</span>
Energy analysis needed. <ng-container *ngIf="latestEnergyAnalysisItem">Latest energy
analysis conducted for
Expand All @@ -78,7 +78,7 @@ <h1 class="card-title"><span class="fa fa-building"></span> {{account.name}}</h1
<li class="list-group-item" *ngIf="waterAnalysisNeeded">
<a class="nav-link" routerLink="/account/analysis/dashboard/water">
<span class="badge rounded-pill bg-danger">
<span class="fa-exclamation white"></span>
<span class="fa fa-exclamation white"></span>
</span>
Water analysis needed. <ng-container *ngIf="latestWaterAnalysisItem">Latest water
analysis conducted for
Expand Down
46 changes: 24 additions & 22 deletions src/app/app.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,10 @@ import { ApplicationInstanceDbService } from './indexedDB/application-instance-d
declare let gtag: Function;

@Component({
selector: 'app-root',
templateUrl: './app.component.html',
styleUrls: ['./app.component.css'],
standalone: false
selector: 'app-root',
templateUrl: './app.component.html',
styleUrls: ['./app.component.css'],
standalone: false
})
export class AppComponent {

Expand Down Expand Up @@ -170,7 +170,7 @@ export class AppComponent {
this.dataInitialized = true;
this.router.navigateByUrl('setup-wizard');
}

} catch (err) {
console.log(err);
await this.eGridService.parseEGridData();
Expand Down Expand Up @@ -346,26 +346,28 @@ export class AppComponent {
}

async setAppOpenNotifications() {
let applicationData: ApplicationInstanceData = this.applicationInstanceDbService.applicationInstanceData.getValue();
if (!applicationData.isSurveyDone) {
if (applicationData.doSurveyReminder) {
setTimeout(() => {
this.surveyService.showSurveyModal.next(true);
}, 5000);
await firstValueFrom(this.applicationInstanceDbService.setSurveyDone());
} else {
let hasMetUsageRequirement: boolean = this.surveyService.getHasMetUsageRequirements(applicationData);
let showModalToExistingUser: boolean = this.surveyService.checkIsExistingUser();
let showModal: boolean = showModalToExistingUser || hasMetUsageRequirement;

setTimeout(() => {
this.surveyService.showSurveyModal.next(showModal);
}, 5000);
if (environment.production) {
let applicationData: ApplicationInstanceData = this.applicationInstanceDbService.applicationInstanceData.getValue();
if (!applicationData.isSurveyDone) {
if (applicationData.doSurveyReminder) {
setTimeout(() => {
this.surveyService.showSurveyModal.next(true);
}, 5000);
await firstValueFrom(this.applicationInstanceDbService.setSurveyDone());
} else {
let hasMetUsageRequirement: boolean = this.surveyService.getHasMetUsageRequirements(applicationData);
let showModalToExistingUser: boolean = this.surveyService.checkIsExistingUser();
let showModal: boolean = showModalToExistingUser || hasMetUsageRequirement;

if (!applicationData.isSurveyToastDone && !showModalToExistingUser) {
setTimeout(() => {
this.surveyService.showSurveyToast.next(true);
this.surveyService.showSurveyModal.next(showModal);
}, 5000);

if (!applicationData.isSurveyToastDone && !showModalToExistingUser) {
setTimeout(() => {
this.surveyService.showSurveyToast.next(true);
}, 5000);
}
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ <h1 class="card-title"><span class="fa fa-industry" [ngStyle]="{color: facility.
<span
class="position-absolute top-0 start-100 translate-middle badge rounded-pill bg-danger"
*ngIf="energyAnalysisNeeded || waterAnalysisNeeded">
<span class="fa-exclamation white"></span>
<span class="fa fa-exclamation white"></span>
</span>
</button>
</div>
Expand Down Expand Up @@ -93,7 +93,7 @@ <h1 class="card-title"><span class="fa fa-industry" [ngStyle]="{color: facility.
<li class="list-group-item" *ngIf="meterReadingsNeeded">
<a class="nav-link" routerLink="/facility/{{facility.id}}/utility">
<span class="badge rounded-pill bg-danger">
<span class="fa-exclamation white"></span>
<span class="fa fa-exclamation white"></span>
</span>
Meter readings needed. <span *ngIf="lastBill">Latest entry {{lastBill.readDate |
date}}.</span>
Expand All @@ -103,7 +103,7 @@ <h1 class="card-title"><span class="fa fa-industry" [ngStyle]="{color: facility.
<a class="nav-link"
routerLink="/facility/{{facility.id}}/analysis/analysis-dashboard/energy">
<span class="badge rounded-pill bg-danger">
<span class="fa-exclamation white"></span>
<span class="fa fa-exclamation white"></span>
</span>
Energy analysis needed. <ng-container *ngIf="latestEnergyAnalysisItem">Latest energy
analysis conducted for
Expand All @@ -115,7 +115,7 @@ <h1 class="card-title"><span class="fa fa-industry" [ngStyle]="{color: facility.
<a class="nav-link"
routerLink="/facility/{{facility.id}}/analysis/analysis-dashboard/water">
<span class="badge rounded-pill bg-danger">
<span class="fa-exclamation white"></span>
<span class="fa fa-exclamation white"></span>
</span>
Water analysis needed. <ng-container *ngIf="latestWaterAnalysisItem">Latest water
analysis conducted for
Expand Down

0 comments on commit a884de5

Please sign in to comment.