From 4c06b7d3e9aded7957189bf22ffad44220f818d8 Mon Sep 17 00:00:00 2001 From: Sean Sylver Date: Mon, 13 May 2024 21:21:03 -0700 Subject: [PATCH 1/7] WFNEWS-2164 Fetch missing data from public side in admin screen --- .../admin-incident-form.component.ts | 162 +++++++++++------- 1 file changed, 102 insertions(+), 60 deletions(-) diff --git a/client/wfnews-war/src/main/angular/src/app/components/admin-incident-form/admin-incident-form.component.ts b/client/wfnews-war/src/main/angular/src/app/components/admin-incident-form/admin-incident-form.component.ts index f705bbe033..94849b99d3 100644 --- a/client/wfnews-war/src/main/angular/src/app/components/admin-incident-form/admin-incident-form.component.ts +++ b/client/wfnews-war/src/main/angular/src/app/components/admin-incident-form/admin-incident-form.component.ts @@ -299,21 +299,6 @@ export class AdminIncidentForm implements OnInit, OnChanges { this.currentEtag = result.headers.get('ETag') self.publishedIncidentDetailGuid = response.publishedIncidentDetailGuid; - self.incident.traditionalTerritory = - response.traditionalTerritoryDetail; - self.incident.lastPublished = response.publishedTimestamp; - self.incident.location = response.incidentLocation; - - self.incident.sizeComments = - response.incidentSizeDetail || - 'Fire size is based on most current information available.'; - Object.entries(SizeTypeOptionDisclaimer).forEach( - ([index, disclaimer]) => { - if (disclaimer === response.incidentSizeDetail) { - self.incident.sizeType = Number.parseInt(index, 10); - } - }, - ); self.incident.cause = 0; self.incident.causeComments = response.incidentCauseDetail; @@ -327,52 +312,9 @@ export class AdminIncidentForm implements OnInit, OnChanges { if (!response.incidentCauseDetail) { self.incident.causeComments = CauseOptionDisclaimer[0]; } - self.incident.publishedStatus = - response.newsPublicationStatusCode; - self.incident.responseComments = response.resourceDetail; - - self.incident.wildifreCrewsInd = - response.wildfireCrewResourcesInd; - self.incident.crewsComments = - response.wildfireCrewResourcesDetail; - - self.incident.aviationInd = - response.wildfireAviationResourceInd; - self.incident.aviationComments = - response.wildfireAviationResourceDetail; - - self.incident.incidentManagementInd = - response.incidentMgmtCrewRsrcInd; - self.incident.incidentManagementComments = - response.incidentMgmtCrewRsrcDetail; - self.incident.heavyEquipmentInd = - response.heavyEquipmentResourcesInd; - self.incident.heavyEquipmentComments = - response.heavyEquipmentResourcesDetail; - self.incident.structureProtectionInd = - response.structureProtectionRsrcInd; - self.incident.structureProtectionComments = - response.structureProtectionRsrcDetail; - - self.incident.crewResourceCount = - response?.crewResourceCount || undefined; - self.incident.aviationResourceCount = - response?.aviationResourceCount || undefined; - self.incident.heavyEquipmentResourceCount = - response?.heavyEquipmentResourceCount || undefined; - self.incident.incidentManagementResourceCount = - response?.incidentManagementResourceCount || undefined; - self.incident.structureProtectionResourceCount = - response?.structureProtectionResourceCount || undefined; - - self.incident.contact.fireCentre = - response.contactOrgUnitIdentifer?.toString(); - self.incident.contact.phoneNumber = - response.contactPhoneNumber; - self.incident.contact.emailAddress = - response.contactEmailAddress; - self.incident.incidentOverview = response.incidentOverview; + this.populateCommonFields(response) + this.incidentForm.patchValue(this.incident); this.incidentForm.markAsPristine(); this.evacOrdersDetailsPanel.getEvacOrders(); @@ -381,6 +323,8 @@ export class AdminIncidentForm implements OnInit, OnChanges { console.log('No published data found...'); console.error(error); self.publishedIncidentDetailGuid = null; + // If WFIM returns a 404 for the incident, fetch the published incident from the WFNEWS public API + this.populateIncidentWithPublishedIncident(this.currentAdminIncident?.incidentLabel, this.wildFireYear, self) }, ); @@ -410,6 +354,104 @@ export class AdminIncidentForm implements OnInit, OnChanges { return !value ? null : value; } + populateIncidentWithPublishedIncident(incidentLabel, wildfireYear, self){ + this.publishedIncidentService.fetchPublishedIncident(incidentLabel, wildfireYear) + .subscribe(response => { + if(response) { + // set cause fields that should be specific to the public side + // give the admin screen default cause comments, as they should be null in the public API at this point + self.incident.cause = response.generalIncidentCauseCatId; + if (response.incidentCauseDetail != null) { + self.incident.causeComments = response.incidentCauseDetail + } else self.incident.causeComments = this.populateCauseComments(response.generalIncidentCauseCatId); + this.populateCommonFields(response); + } + }), + (error) => { + console.log('No public published data found...'); + console.error(error); + }, + + this.incidentForm?.patchValue(this.incident); + this.incidentForm?.markAsPristine(); + this.evacOrdersDetailsPanel?.getEvacOrders(); + this.cdr.detectChanges(); + } + + populateCauseComments(causeCode: number) { + switch(causeCode){ + case 1: return "Humans start wildfires in several ways, either by accident or intentionally."; + case 2: return "When lightning strikes an object it can release enough heat to ignite a tree or other fuels."; + case 3: return "Wildfire investigations often take time and can be very complex. Investigations may be carried out by one or more agencies, including the BC Wildfire Service, the Compliance and Enforcement Branch, the RCMP, or other law enforcement agencies, and may be cross jurisdictional." + default: return "A wildfire of undetermined cause, including a wildfire that is currently under investigation, as well as one where the investigation has been completed."; + } + } + + populateCommonFields(response){ + if(response) { + this.incident.traditionalTerritory = response.traditionalTerritoryDetail; + this.incident.lastPublished = response.publishedTimestamp; + this.incident.location = response.incidentLocation; + + this.incident.sizeComments = + response.incidentSizeDetail || + 'Fire size is based on most current information available.'; + Object.entries(SizeTypeOptionDisclaimer).forEach( + ([index, disclaimer]) => { + if (disclaimer === response.incidentSizeDetail) { + this.incident.sizeType = Number.parseInt(index, 10); + } + }, + ); + + this.incident.publishedStatus = + response.newsPublicationStatusCode; + this.incident.responseComments = response.resourceDetail; + + this.incident.wildifreCrewsInd = + response.wildfireCrewResourcesInd; + this.incident.crewsComments = + response.wildfireCrewResourcesDetail; + + this.incident.aviationInd = + response.wildfireAviationResourceInd; + this.incident.aviationComments = + response.wildfireAviationResourceDetail; + + this.incident.incidentManagementInd = + response.incidentMgmtCrewRsrcInd; + this.incident.incidentManagementComments = + response.incidentMgmtCrewRsrcDetail; + this.incident.heavyEquipmentInd = + response.heavyEquipmentResourcesInd; + this.incident.heavyEquipmentComments = + response.heavyEquipmentResourcesDetail; + this.incident.structureProtectionInd = + response.structureProtectionRsrcInd; + this.incident.structureProtectionComments = + response.structureProtectionRsrcDetail; + + this.incident.crewResourceCount = + response?.crewResourceCount || undefined; + this.incident.aviationResourceCount = + response?.aviationResourceCount || undefined; + this.incident.heavyEquipmentResourceCount = + response?.heavyEquipmentResourceCount || undefined; + this.incident.incidentManagementResourceCount = + response?.incidentManagementResourceCount || undefined; + this.incident.structureProtectionResourceCount = + response?.structureProtectionResourceCount || undefined; + + this.incident.contact.fireCentre = + response.contactOrgUnitIdentifer?.toString(); + this.incident.contact.phoneNumber = + response.contactPhoneNumber; + this.incident.contact.emailAddress = + response.contactEmailAddress; + this.incident.incidentOverview = response.incidentOverview; + } + } + async publishChanges() { this.publishDisabled = true; this.cdr.detectChanges(); From 5529ce5095572057425fa6368df09dcd6949b50e Mon Sep 17 00:00:00 2001 From: Sean Sylver Date: Tue, 14 May 2024 15:38:36 -0700 Subject: [PATCH 2/7] WFNEWS-2164 Use one datasource for published incident in admin --- .../admin-incident-form.component.ts | 150 ++++++++++++------ .../incident-info-panel-mobile.component.html | 2 +- 2 files changed, 103 insertions(+), 49 deletions(-) diff --git a/client/wfnews-war/src/main/angular/src/app/components/admin-incident-form/admin-incident-form.component.ts b/client/wfnews-war/src/main/angular/src/app/components/admin-incident-form/admin-incident-form.component.ts index 94849b99d3..b81fee2003 100644 --- a/client/wfnews-war/src/main/angular/src/app/components/admin-incident-form/admin-incident-form.component.ts +++ b/client/wfnews-war/src/main/angular/src/app/components/admin-incident-form/admin-incident-form.component.ts @@ -213,11 +213,12 @@ export class AdminIncidentForm implements OnInit, OnChanges { this.incidentNumberSequnce = params['incidentNumberSequence']; const self = this; + let publishedWFIM = false; this.publishedIncidentService .fetchIMIncident(this.wildFireYear, this.incidentNumberSequnce) .subscribe( - (incidentResponse) => { + async (incidentResponse) => { self.currentAdminIncident = incidentResponse.response; this.publishedIncidentType = self.currentAdminIncident.type; (self.incident as any).discoveryDate = new Date( @@ -293,44 +294,67 @@ export class AdminIncidentForm implements OnInit, OnChanges { this.cdr.detectChanges(); }); - incidentResponse.getPublishedIncident.subscribe( - (result) => { - const response = result.body; - this.currentEtag = result.headers.get('ETag') - self.publishedIncidentDetailGuid = - response.publishedIncidentDetailGuid; - - self.incident.cause = 0; - self.incident.causeComments = response.incidentCauseDetail; - Object.entries(CauseOptionDisclaimer).forEach( - ([index, disclaimer]) => { - if (disclaimer === response.incidentCauseDetail) { - self.incident.cause = Number.parseInt(index, 10); - } - }, + const publishedIncident = new Promise((resolve, reject) => { + incidentResponse.getPublishedIncident.toPromise().then( + (result) => { + if(result) { + publishedWFIM = true; + resolve(result) + }else reject(result) + }, (err) => { + console.log('No published data found...'); + console.error(err); + self.publishedIncidentDetailGuid = null; + publishedWFIM = false; + reject(err) + } + ); + }); + + + // If WFIM returns a 404 for the incident, fetch the published incident from the WFNEWS public API + // set cause fields that should be specific to the public side + // give the admin screen default cause comments, as they should be null in the public API at this point + const publicPublishedIncident = new Promise((resolve, reject) => { + this.publishedIncidentService.fetchPublishedIncident(self.currentAdminIncident.incidentLabel, this.wildFireYear) + .toPromise().then( + (response) => { + // resolve only if the incident has not been published in WFIM + if(!publishedWFIM) resolve(response) + else reject(response) + }, (err) => { + console.log('No public published data found...'); + console.error(err); + reject(err) + } ); - if (!response.incidentCauseDetail) { - self.incident.causeComments = CauseOptionDisclaimer[0]; + }); + + const promises = [publishedIncident, publicPublishedIncident]; + + Promise.allSettled(promises).then((results) => + results.forEach((result) => { + let iterate = true; + if (result?.status == 'fulfilled') { + if (iterate) { + const res = result?.value; + if (!publishedWFIM) { + this.populatePublicFields(res) + } else { + this.populatePublishedIMFields(res) + } + this.populateCommonFields(res) + iterate = false; + } } + } + )); - this.populateCommonFields(response) - - this.incidentForm.patchValue(this.incident); - this.incidentForm.markAsPristine(); - this.evacOrdersDetailsPanel.getEvacOrders(); - }, - (error) => { - console.log('No published data found...'); - console.error(error); - self.publishedIncidentDetailGuid = null; - // If WFIM returns a 404 for the incident, fetch the published incident from the WFNEWS public API - this.populateIncidentWithPublishedIncident(this.currentAdminIncident?.incidentLabel, this.wildFireYear, self) - }, - ); this.incidentForm.patchValue(this.incident); this.incidentForm.markAsPristine(); this.cdr.detectChanges(); + this.evacOrdersDetailsPanel.getEvacOrders(); }, (incidentResponseError) => { console.error(incidentResponseError); @@ -354,18 +378,47 @@ export class AdminIncidentForm implements OnInit, OnChanges { return !value ? null : value; } - populateIncidentWithPublishedIncident(incidentLabel, wildfireYear, self){ + populatePublicFields(result) { + this.incident.cause = result?.generalIncidentCauseCatId; + if (result?.incidentCauseDetail != null) { + this.incident.causeComments = result?.incidentCauseDetail + } else this.incident.causeComments = this.populateCauseComments(result?.generalIncidentCauseCatId); + } + + populatePublishedIMFields(result) { + const response = result?.body; + this.currentEtag = result?.headers?.get('ETag') + this.publishedIncidentDetailGuid = + response?.publishedIncidentDetailGuid; + + this.incident.cause = 0; + this.incident.causeComments = response?.incidentCauseDetail; + Object.entries(CauseOptionDisclaimer).forEach( + ([index, disclaimer]) => { + if (disclaimer === response?.incidentCauseDetail) { + this.incident.cause = Number.parseInt(index, 10); + } + }, + ); + if (!response?.incidentCauseDetail) { + this.incident.causeComments = CauseOptionDisclaimer[0]; + } + + + } + + populateIncidentWithPublishedIncident(incidentLabel, wildfireYear, self) { this.publishedIncidentService.fetchPublishedIncident(incidentLabel, wildfireYear) .subscribe(response => { - if(response) { - // set cause fields that should be specific to the public side - // give the admin screen default cause comments, as they should be null in the public API at this point - self.incident.cause = response.generalIncidentCauseCatId; - if (response.incidentCauseDetail != null) { - self.incident.causeComments = response.incidentCauseDetail - } else self.incident.causeComments = this.populateCauseComments(response.generalIncidentCauseCatId); - this.populateCommonFields(response); - } + if (response) { + // set cause fields that should be specific to the public side + // give the admin screen default cause comments, as they should be null in the public API at this point + self.incident.cause = response.generalIncidentCauseCatId; + if (response.incidentCauseDetail != null) { + self.incident.causeComments = response.incidentCauseDetail + } else self.incident.causeComments = this.populateCauseComments(response.generalIncidentCauseCatId); + this.populateCommonFields(response); + } }), (error) => { console.log('No public published data found...'); @@ -379,16 +432,17 @@ export class AdminIncidentForm implements OnInit, OnChanges { } populateCauseComments(causeCode: number) { - switch(causeCode){ + switch (causeCode) { case 1: return "Humans start wildfires in several ways, either by accident or intentionally."; case 2: return "When lightning strikes an object it can release enough heat to ignite a tree or other fuels."; case 3: return "Wildfire investigations often take time and can be very complex. Investigations may be carried out by one or more agencies, including the BC Wildfire Service, the Compliance and Enforcement Branch, the RCMP, or other law enforcement agencies, and may be cross jurisdictional." default: return "A wildfire of undetermined cause, including a wildfire that is currently under investigation, as well as one where the investigation has been completed."; - } + } } - populateCommonFields(response){ - if(response) { + populateCommonFields(result) { + const response = result?.body; + if (response) { this.incident.traditionalTerritory = response.traditionalTerritoryDetail; this.incident.lastPublished = response.publishedTimestamp; this.incident.location = response.incidentLocation; @@ -535,7 +589,7 @@ export class AdminIncidentForm implements OnInit, OnChanges { duration: 100000, panelClass: 'snackbar-success-v2', }); - // Update the Draft/Publish status on incident name + // Update the Draft/Publish status on incident name this.incident.lastPublished = doc?.publishedTimestamp; this.incident.publishedStatus = doc?.newsPublicationStatusCode; this.incidentForm.markAsPristine(); @@ -570,7 +624,7 @@ export class AdminIncidentForm implements OnInit, OnChanges { // if (publishedGuid) { // } else { - + // } const saveResult = this.publishedIncidentService.saveIMPublishedIncident(incident); if (saveResult) { diff --git a/client/wfnews-war/src/main/angular/src/app/components/public-incident-page/incident-info-panel-mobile/incident-info-panel-mobile.component.html b/client/wfnews-war/src/main/angular/src/app/components/public-incident-page/incident-info-panel-mobile/incident-info-panel-mobile.component.html index dc28cd3603..4fe6ef95e5 100644 --- a/client/wfnews-war/src/main/angular/src/app/components/public-incident-page/incident-info-panel-mobile/incident-info-panel-mobile.component.html +++ b/client/wfnews-war/src/main/angular/src/app/components/public-incident-page/incident-info-panel-mobile/incident-info-panel-mobile.component.html @@ -240,7 +240,7 @@

Suspected Cause

question - {{getCauseLabel(incident.generalIncidentCauseCatId)}} + {{incident.incidentCauseDetail || getCauseLabel(incident.generalIncidentCauseCatId)}}
From 42dcd6f8d043c2e570c6e63b4f3fc300f85d443e Mon Sep 17 00:00:00 2001 From: Sean Sylver Date: Tue, 14 May 2024 15:44:31 -0700 Subject: [PATCH 3/7] Remove typo and clean up --- .../admin-incident-form/admin-incident-form.component.ts | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/client/wfnews-war/src/main/angular/src/app/components/admin-incident-form/admin-incident-form.component.ts b/client/wfnews-war/src/main/angular/src/app/components/admin-incident-form/admin-incident-form.component.ts index b81fee2003..06b11cc06f 100644 --- a/client/wfnews-war/src/main/angular/src/app/components/admin-incident-form/admin-incident-form.component.ts +++ b/client/wfnews-war/src/main/angular/src/app/components/admin-incident-form/admin-incident-form.component.ts @@ -218,7 +218,7 @@ export class AdminIncidentForm implements OnInit, OnChanges { this.publishedIncidentService .fetchIMIncident(this.wildFireYear, this.incidentNumberSequnce) .subscribe( - async (incidentResponse) => { + (incidentResponse) => { self.currentAdminIncident = incidentResponse.response; this.publishedIncidentType = self.currentAdminIncident.type; (self.incident as any).discoveryDate = new Date( @@ -403,8 +403,6 @@ export class AdminIncidentForm implements OnInit, OnChanges { if (!response?.incidentCauseDetail) { this.incident.causeComments = CauseOptionDisclaimer[0]; } - - } populateIncidentWithPublishedIncident(incidentLabel, wildfireYear, self) { From 44c88f8156b292198ceccecbdddf08fa7a478e2d Mon Sep 17 00:00:00 2001 From: Sean Sylver Date: Wed, 15 May 2024 09:54:01 -0700 Subject: [PATCH 4/7] WFNEWS-2164 Await Promise.allSettled call --- .../admin-incident-form/admin-incident-form.component.ts | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/client/wfnews-war/src/main/angular/src/app/components/admin-incident-form/admin-incident-form.component.ts b/client/wfnews-war/src/main/angular/src/app/components/admin-incident-form/admin-incident-form.component.ts index 06b11cc06f..df09a15a39 100644 --- a/client/wfnews-war/src/main/angular/src/app/components/admin-incident-form/admin-incident-form.component.ts +++ b/client/wfnews-war/src/main/angular/src/app/components/admin-incident-form/admin-incident-form.component.ts @@ -218,7 +218,7 @@ export class AdminIncidentForm implements OnInit, OnChanges { this.publishedIncidentService .fetchIMIncident(this.wildFireYear, this.incidentNumberSequnce) .subscribe( - (incidentResponse) => { + async (incidentResponse) => { self.currentAdminIncident = incidentResponse.response; this.publishedIncidentType = self.currentAdminIncident.type; (self.incident as any).discoveryDate = new Date( @@ -330,9 +330,7 @@ export class AdminIncidentForm implements OnInit, OnChanges { ); }); - const promises = [publishedIncident, publicPublishedIncident]; - - Promise.allSettled(promises).then((results) => + await Promise.allSettled([publishedIncident, publicPublishedIncident]).then((results) => results.forEach((result) => { let iterate = true; if (result?.status == 'fulfilled') { From 8638271ff0889ba63fbf4f92def8a3357ac7f16b Mon Sep 17 00:00:00 2001 From: Sean Sylver Date: Wed, 15 May 2024 10:15:45 -0700 Subject: [PATCH 5/7] Update promise syntax --- .../admin-incident-form/admin-incident-form.component.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/client/wfnews-war/src/main/angular/src/app/components/admin-incident-form/admin-incident-form.component.ts b/client/wfnews-war/src/main/angular/src/app/components/admin-incident-form/admin-incident-form.component.ts index df09a15a39..02946c479d 100644 --- a/client/wfnews-war/src/main/angular/src/app/components/admin-incident-form/admin-incident-form.component.ts +++ b/client/wfnews-war/src/main/angular/src/app/components/admin-incident-form/admin-incident-form.component.ts @@ -330,7 +330,7 @@ export class AdminIncidentForm implements OnInit, OnChanges { ); }); - await Promise.allSettled([publishedIncident, publicPublishedIncident]).then((results) => + const results = await Promise.allSettled([publishedIncident, publicPublishedIncident]).then((results) => results.forEach((result) => { let iterate = true; if (result?.status == 'fulfilled') { From 2bbf5322f968c60d6c199d2f7a9dcd84b3a3e2fe Mon Sep 17 00:00:00 2001 From: Sean Sylver Date: Wed, 15 May 2024 10:19:00 -0700 Subject: [PATCH 6/7] Update promise syntax --- .../admin-incident-form.component.ts | 43 ++++++++++--------- 1 file changed, 22 insertions(+), 21 deletions(-) diff --git a/client/wfnews-war/src/main/angular/src/app/components/admin-incident-form/admin-incident-form.component.ts b/client/wfnews-war/src/main/angular/src/app/components/admin-incident-form/admin-incident-form.component.ts index 02946c479d..7cbae5e814 100644 --- a/client/wfnews-war/src/main/angular/src/app/components/admin-incident-form/admin-incident-form.component.ts +++ b/client/wfnews-war/src/main/angular/src/app/components/admin-incident-form/admin-incident-form.component.ts @@ -297,10 +297,10 @@ export class AdminIncidentForm implements OnInit, OnChanges { const publishedIncident = new Promise((resolve, reject) => { incidentResponse.getPublishedIncident.toPromise().then( (result) => { - if(result) { + if (result) { publishedWFIM = true; resolve(result) - }else reject(result) + } else reject(result) }, (err) => { console.log('No published data found...'); console.error(err); @@ -320,8 +320,8 @@ export class AdminIncidentForm implements OnInit, OnChanges { .toPromise().then( (response) => { // resolve only if the incident has not been published in WFIM - if(!publishedWFIM) resolve(response) - else reject(response) + if (!publishedWFIM) resolve(response) + else reject(response) }, (err) => { console.log('No public published data found...'); console.error(err); @@ -330,23 +330,24 @@ export class AdminIncidentForm implements OnInit, OnChanges { ); }); - const results = await Promise.allSettled([publishedIncident, publicPublishedIncident]).then((results) => - results.forEach((result) => { - let iterate = true; - if (result?.status == 'fulfilled') { - if (iterate) { - const res = result?.value; - if (!publishedWFIM) { - this.populatePublicFields(res) - } else { - this.populatePublishedIMFields(res) - } - this.populateCommonFields(res) - iterate = false; + const results = await Promise.allSettled([publishedIncident, publicPublishedIncident]); + + results.forEach((result) => { + let iterate = true; + if (result?.status == 'fulfilled') { + if (iterate) { + const res = result?.value; + if (!publishedWFIM) { + this.populatePublicFields(res) + } else { + this.populatePublishedIMFields(res) } + this.populateCommonFields(res) + iterate = false; } } - )); + }); + this.incidentForm.patchValue(this.incident); @@ -422,9 +423,9 @@ export class AdminIncidentForm implements OnInit, OnChanges { }, this.incidentForm?.patchValue(this.incident); - this.incidentForm?.markAsPristine(); - this.evacOrdersDetailsPanel?.getEvacOrders(); - this.cdr.detectChanges(); + this.incidentForm?.markAsPristine(); + this.evacOrdersDetailsPanel?.getEvacOrders(); + this.cdr.detectChanges(); } populateCauseComments(causeCode: number) { From c364746e1dcc70b8a099a2d4d0f05220feb180db Mon Sep 17 00:00:00 2001 From: Sean Sylver Date: Thu, 16 May 2024 10:19:17 -0700 Subject: [PATCH 7/7] WFNEWS-2164 Mobile view fix suspected cause --- .../incident-info-panel-mobile.component.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/client/wfnews-war/src/main/angular/src/app/components/public-incident-page/incident-info-panel-mobile/incident-info-panel-mobile.component.html b/client/wfnews-war/src/main/angular/src/app/components/public-incident-page/incident-info-panel-mobile/incident-info-panel-mobile.component.html index 4fe6ef95e5..33fe40d84c 100644 --- a/client/wfnews-war/src/main/angular/src/app/components/public-incident-page/incident-info-panel-mobile/incident-info-panel-mobile.component.html +++ b/client/wfnews-war/src/main/angular/src/app/components/public-incident-page/incident-info-panel-mobile/incident-info-panel-mobile.component.html @@ -240,12 +240,12 @@

Suspected Cause

question - {{incident.incidentCauseDetail || getCauseLabel(incident.generalIncidentCauseCatId)}} + {{getCauseLabel(incident.generalIncidentCauseCatId)}}
- {{getCauseDescription(incident.generalIncidentCauseCatId)}} + {{incident.incidentCauseDetail || getCauseDescription(incident.generalIncidentCauseCatId)}}