fixing fhir test.
This commit is contained in:
parent
631bb9bdcd
commit
e7701be572
|
@ -1,7 +1,6 @@
|
|||
import {Component} from '@angular/core';
|
||||
import {GenericColumnDefn, ListGenericResourceComponent} from './list-generic-resource.component';
|
||||
import {attributeXTime} from './utils';
|
||||
import {getPath} from '../../fhir/utils';
|
||||
|
||||
@Component({
|
||||
selector: 'app-list-care-plan',
|
||||
|
@ -13,8 +12,8 @@ export class ListCarePlanComponent extends ListGenericResourceComponent {
|
|||
{ title: 'Category', versions: '*', format: 'code', getter: c => c.category[0].coding[0] },
|
||||
{ title: 'Reason', versions: '*', getter: c => {
|
||||
return (c.activity || []).map((a, i) => {
|
||||
let reason = getPath(a, "detail.code.coding.0.display") || ""
|
||||
return reason ? [reason, getPath(a, "detail.status") || "no data"] : []
|
||||
let reason = a.detail?.code?.coding[0]?.display || ""
|
||||
return reason ? [reason, a.detail?.status || "no data"] : []
|
||||
})
|
||||
} },
|
||||
{ title: 'Period', versions: '*', format: 'period', getter: c => c.period },
|
||||
|
|
Loading…
Reference in New Issue