|
1 | 1 | import { Component, OnDestroy, OnInit } from '@angular/core'; |
| 2 | +import { Title } from '@angular/platform-browser'; |
2 | 3 | import { ActivatedRoute, NavigationEnd, Router } from '@angular/router'; |
3 | 4 | import { Subject, takeUntil } from 'rxjs'; |
| 5 | +import { environment } from '../../../environments/environment'; |
4 | 6 | import { ComplianceAndEnforcementDto } from '../../services/compliance-and-enforcement/compliance-and-enforcement.dto'; |
5 | 7 | import { |
6 | 8 | ComplianceAndEnforcementService, |
@@ -32,6 +34,7 @@ export class ComplianceAndEnforcementComponent implements OnInit, OnDestroy { |
32 | 34 | private readonly service: ComplianceAndEnforcementService, |
33 | 35 | private readonly responsiblePartyService: ResponsiblePartiesService, |
34 | 36 | private readonly toastService: ToastService, |
| 37 | + private readonly titleService: Title, |
35 | 38 | ) {} |
36 | 39 |
|
37 | 40 | ngOnInit(): void { |
@@ -85,6 +88,10 @@ export class ComplianceAndEnforcementComponent implements OnInit, OnDestroy { |
85 | 88 | ? (owners[0].organizationName || owners[0].individualName) + (owners.length > 1 ? ' et al.' : '') |
86 | 89 | : ''; |
87 | 90 | } |
| 91 | + |
| 92 | + this.titleService.setTitle( |
| 93 | + `${environment.siteName} | ${this.file.fileNumber} (${this.propertyOwnerName || 'Unknown'})`, |
| 94 | + ); |
88 | 95 | } |
89 | 96 | } catch (error) { |
90 | 97 | console.error('Error loading file:', error); |
|
0 commit comments