include report information in the header if filtered to report.
This commit is contained in:
parent
74a3fd4b4e
commit
8e39cf60a7
|
@ -8,6 +8,19 @@
|
|||
<ng-container [ngTemplateOutlet]="loading ? isLoadingTemplate : isEmptyReport ? emptyReport : report"></ng-container>
|
||||
|
||||
<ng-template #report>
|
||||
|
||||
<!-- Report Details -->
|
||||
<div class="row" *ngIf="reportDisplayModel">
|
||||
<div class="col-12 mt-3 mb-3">
|
||||
<h1 class="az-dashboard-title">Report Info</h1>
|
||||
</div>
|
||||
<div class="col-12">
|
||||
<fhir-resource [displayModel]="reportDisplayModel" [showDetails]="true"></fhir-resource>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<!-- Observations Title -->
|
||||
<div class="row mt-5 mb-3">
|
||||
<div class="col-6">
|
||||
|
|
|
@ -7,6 +7,9 @@ import {forkJoin, Observable} from 'rxjs';
|
|||
import {flatMap, map, mergeMap} from 'rxjs/operators';
|
||||
import {ResponseWrapper} from '../../models/response-wrapper';
|
||||
import {ActivatedRoute, Params} from '@angular/router';
|
||||
import {FastenDisplayModel} from '../../../lib/models/fasten/fasten-display-model';
|
||||
import {fhirModelFactory} from '../../../lib/models/factory';
|
||||
import {ResourceType} from '../../../lib/models/constants';
|
||||
|
||||
class ObservationGroup {[key: string]: ResourceFhir[]}
|
||||
class ObservationGroupInfo {
|
||||
|
@ -36,6 +39,7 @@ export class ReportLabsComponent implements OnInit {
|
|||
reportSourceId: string = ''
|
||||
reportResourceType: string = ''
|
||||
reportResourceId: string = ''
|
||||
reportDisplayModel: FastenDisplayModel = null
|
||||
|
||||
//currentPage data
|
||||
observationGroups: ObservationGroup = {}
|
||||
|
@ -113,6 +117,8 @@ export class ReportLabsComponent implements OnInit {
|
|||
mergeMap((diagnosticReports) => {
|
||||
let diagnosticReport = diagnosticReports?.[0]
|
||||
console.log("diagnosticReport", diagnosticReport)
|
||||
this.reportDisplayModel = fhirModelFactory(diagnosticReport.source_resource_type as ResourceType, diagnosticReport)
|
||||
|
||||
|
||||
//get a list of all the observations associated with this report
|
||||
let observationIds = fhirpath.evaluate(diagnosticReport.resource_raw, "DiagnosticReport.result.reference")
|
||||
|
|
Loading…
Reference in New Issue