diff --git a/backend/pkg/database/gorm_repository_graph.go b/backend/pkg/database/gorm_repository_graph.go index 1ee372d3..21b843a0 100644 --- a/backend/pkg/database/gorm_repository_graph.go +++ b/backend/pkg/database/gorm_repository_graph.go @@ -29,17 +29,10 @@ func (rp *VertexResourcePlaceholder) ID() string { // Retrieve a list of all fhir resources (vertex), and a list of all associations (edge) // Generate a graph // return list of root nodes, and their flattened related resources. -func (gr *GormRepository) GetFlattenedResourceGraph(ctx context.Context, graphType pkg.ResourceGraphType, options models.ResourceGraphOptions) (map[string][]*models.ResourceBase, *models.ResourceGraphMetadata, error) { +func (gr *GormRepository) GetFlattenedResourceGraph(ctx context.Context, graphType pkg.ResourceGraphType, options models.ResourceGraphOptions) (map[string][]*models.ResourceBase, error) { currentUser, currentUserErr := gr.GetCurrentUser(ctx) if currentUserErr != nil { - return nil, nil, currentUserErr - } - - //initialize the graph results metadata - resourceGraphMetadata := models.ResourceGraphMetadata{ - TotalElements: 0, - PageSize: 20, //TODO: replace this with pkg.DefaultPageSize - Page: options.Page, + return nil, currentUserErr } // Get list of all (non-reciprocal) relationships @@ -52,18 +45,13 @@ func (gr *GormRepository) GetFlattenedResourceGraph(ctx context.Context, graphTy }). Find(&relatedResourceRelationships) if result.Error != nil { - return nil, nil, result.Error + return nil, result.Error } + log.Printf("found %d related resources", len(relatedResourceRelationships)) //Generate Graph // TODO optimization: eventually cache the graph in a database/storage, and update when new resources are added. - g := graph.New(resourceVertexId, graph.Directed(), graph.Acyclic(), graph.Rooted()) - - //// Get list of all resources TODO - REPLACED THIS - //wrappedResourceModels, err := gr.ListResources(ctx, models.ListResourceQueryOptions{}) - //if err != nil { - // return nil, err - //} + g := graph.New(resourceVertexId, graph.Directed(), graph.Rooted()) //add vertices to the graph (must be done first) //we don't want to request all resources from the database, so we will create a placeholder vertex for each resource. @@ -105,7 +93,7 @@ func (gr *GormRepository) GetFlattenedResourceGraph(ctx context.Context, graphTy &resourcePlaceholder, ) if err != nil { - return nil, nil, fmt.Errorf("an error occurred while adding vertex: %v", err) + return nil, fmt.Errorf("an error occurred while adding vertex: %v", err) } } @@ -142,7 +130,7 @@ func (gr *GormRepository) GetFlattenedResourceGraph(ctx context.Context, graphTy // } adjacencyMap, err := g.AdjacencyMap() if err != nil { - return nil, nil, fmt.Errorf("error while generating AdjacencyMap: %v", err) + return nil, fmt.Errorf("error while generating AdjacencyMap: %v", err) } // For a directed graph, PredecessorMap is the complement of AdjacencyMap. This is because in a directed graph, only @@ -151,12 +139,12 @@ func (gr *GormRepository) GetFlattenedResourceGraph(ctx context.Context, graphTy // ie. "empty" verticies in this map are "root" nodes. predecessorMap, err := g.PredecessorMap() if err != nil { - return nil, nil, fmt.Errorf("error while generating PredecessorMap: %v", err) + return nil, fmt.Errorf("error while generating PredecessorMap: %v", err) } // Doing this in one massive function, because passing graph by reference is difficult due to generics. - // Step 1: use predecessorMap to find all "root" resources (eg. MedicalHistory - encounters and conditions). store those nodes in their respective lists. + // Step 1: use predecessorMap to find all "root" resources (eg. MedicalHistory - encounters and EOB). store those nodes in their respective lists. resourcePlaceholderListDictionary := map[string][]*VertexResourcePlaceholder{} sources, _, sourceFlattenLevel := getSourcesAndSinksForGraphType(graphType) @@ -201,11 +189,10 @@ func (gr *GormRepository) GetFlattenedResourceGraph(ctx context.Context, graphTy // Step 2: now that we've created a relationship graph using placeholders, we need to determine which page of resources to return // and look up the actual resources from the database. - resourceListDictionary, totalElements, err := gr.InflateResourceGraphAtPage(resourcePlaceholderListDictionary, options.Page) + resourceListDictionary, err := gr.InflateSelectedResourcesInResourceGraph(currentUser, resourcePlaceholderListDictionary, options) if err != nil { - return nil, nil, fmt.Errorf("error while paginating & inflating resource graph: %v", err) + return nil, fmt.Errorf("error while paginating & inflating resource graph: %v", err) } - resourceGraphMetadata.TotalElements = totalElements // Step 3: define a function. When given a resource, should find all related resources, flatten the heirarchy and set the RelatedResourceFhir list flattenRelatedResourcesFn := func(resource *models.ResourceBase) { @@ -220,22 +207,30 @@ func (gr *GormRepository) GetFlattenedResourceGraph(ctx context.Context, graphTy resource.RelatedResource = []*models.ResourceBase{} + //make sure we don't keep traversing the same node over and over again + visited := map[string]bool{ + vertexId: true, + } + //get all the resource placeholders associated with this node //TODO: handle error? graph.DFS(g, vertexId, func(relatedVertexId string) bool { + relatedResourcePlaceholder, _ := g.Vertex(relatedVertexId) //skip the current resourcePlaceholder if it's referenced in this list. + //skip any "visted" nodes //also skip the current resourcePlaceholder if its a Binary resourcePlaceholder (which is a special case) - if vertexId != resourceVertexId(relatedResourcePlaceholder) && relatedResourcePlaceholder.ResourceType != "Binary" { + if _, hasVisited := visited[resourceVertexId(relatedResourcePlaceholder)]; !hasVisited && relatedResourcePlaceholder.ResourceType != "Binary" { relatedResource, err := gr.GetResourceByResourceTypeAndId(ctx, relatedResourcePlaceholder.ResourceType, relatedResourcePlaceholder.ResourceID) if err != nil { - gr.Logger.Warnf("ignoring, cannot safely handle error which occurred while getting related resource: %v", err) - return true + gr.Logger.Warnf("ignoring, cannot safely handle error which occurred while getting related resource (%s/%s): %v", relatedResourcePlaceholder.ResourceType, relatedResourcePlaceholder.ResourceID, err) + return false } resource.RelatedResource = append( resource.RelatedResource, relatedResource, ) + visited[resourceVertexId(relatedResourcePlaceholder)] = true } return false }) @@ -288,36 +283,50 @@ func (gr *GormRepository) GetFlattenedResourceGraph(ctx context.Context, graphTy // Step 5: return the populated resource list dictionary - return resourceListDictionary, &resourceGraphMetadata, nil + return resourceListDictionary, nil } -// LoadResourceGraphAtPage - this function will take a dictionary of placeholder "sources" graph and load the actual resources from the database, for a specific page +// InflateSelectedResourcesInResourceGraph - this function will take a dictionary of placeholder "sources" graph and load the selected resources (and their descendants) from the database. // - first, it will load all the "source" resources (eg. Encounter, Condition, etc) // - sort the root resources by date, desc // - use the page number + page size to determine which root resources to return // - return a dictionary of "source" resource lists -func (gr *GormRepository) InflateResourceGraphAtPage(resourcePlaceholderListDictionary map[string][]*VertexResourcePlaceholder, page int) (map[string][]*models.ResourceBase, int, error) { - totalElements := 0 - // Step 3a: since we cant calulate the sort order until the resources are loaded, we need to load all the root resources first. +func (gr *GormRepository) InflateSelectedResourcesInResourceGraph(currentUser *models.User, resourcePlaceholderListDictionary map[string][]*VertexResourcePlaceholder, options models.ResourceGraphOptions) (map[string][]*models.ResourceBase, error) { + + // Step 3a: group the selected resources by type, so we only need to do 1 query per type + selectedResourceIdsByResourceType := map[string][]models.OriginBase{} + + for _, resourceId := range options.ResourcesIds { + if _, ok := selectedResourceIdsByResourceType[resourceId.SourceResourceType]; !ok { + selectedResourceIdsByResourceType[resourceId.SourceResourceType] = []models.OriginBase{} + } + selectedResourceIdsByResourceType[resourceId.SourceResourceType] = append(selectedResourceIdsByResourceType[resourceId.SourceResourceType], resourceId) + } + + // Step 3b: query the database for all the selected resources //TODO: maybe its more performant to query each resource by type/id/source, since they are indexed already? rootWrappedResourceModels := []models.ResourceBase{} - for resourceType, _ := range resourcePlaceholderListDictionary { - // resourcePlaceholderListDictionary contains top level resource types (eg. Encounter, Condition, etc) + for resourceType, _ := range selectedResourceIdsByResourceType { + // selectedResourceIdsByResourceType contains selected resources grouped by ty[e types (eg. Encounter, Condition, etc) + //convert these to a list of interface{} for the query selectList := [][]interface{}{} - for ndx, _ := range resourcePlaceholderListDictionary[resourceType] { + for ndx, _ := range selectedResourceIdsByResourceType[resourceType] { + + selectedResource := selectedResourceIdsByResourceType[resourceType][ndx] + selectList = append(selectList, []interface{}{ - resourcePlaceholderListDictionary[resourceType][ndx].UserID, - resourcePlaceholderListDictionary[resourceType][ndx].SourceID, - resourcePlaceholderListDictionary[resourceType][ndx].ResourceType, - resourcePlaceholderListDictionary[resourceType][ndx].ResourceID, + currentUser.ID, + selectedResource.SourceID, + selectedResource.SourceResourceType, + selectedResource.SourceResourceID, }) } tableName, err := databaseModel.GetTableNameByResourceType(resourceType) if err != nil { - return nil, totalElements, err + return nil, err } var tableWrappedResourceModels []models.ResourceBase gr.GormClient. @@ -332,13 +341,7 @@ func (gr *GormRepository) InflateResourceGraphAtPage(resourcePlaceholderListDict //sort rootWrappedResourceModels = utils.SortResourceListByDate(rootWrappedResourceModels) - //calculate total elements - totalElements = len(rootWrappedResourceModels) - - //paginate (by calculating window for the slice) - rootWrappedResourceModels = utils.PaginateResourceList(rootWrappedResourceModels, page, 20) //todo: replace size with pkg.ResourceListPageSize - - // Step 3b: now that we have the root resources, lets generate a dictionary of resource lists, keyed by resource type + // Step 3c: now that we have the selected root resources, lets generate a dictionary of resource lists, keyed by resource type resourceListDictionary := map[string][]*models.ResourceBase{} for ndx, _ := range rootWrappedResourceModels { resourceType := rootWrappedResourceModels[ndx].SourceResourceType @@ -349,7 +352,7 @@ func (gr *GormRepository) InflateResourceGraphAtPage(resourcePlaceholderListDict } // Step 4: return the populated resource list dictionary - return resourceListDictionary, totalElements, nil + return resourceListDictionary, nil } // We need to support the following types of graphs: @@ -445,11 +448,10 @@ func getSourcesAndSinksForGraphType(graphType pkg.ResourceGraphType) ([][]string switch graphType { case pkg.ResourceGraphTypeMedicalHistory: sources = [][]string{ - {"condition", "composition"}, {"encounter", "explanationofbenefit"}, } sinks = [][]string{ - {"location", "device", "organization", "practitioner", "medication", "patient", "coverage"}, //resources that are shared across multiple conditions + {"condition", "composition", "location", "device", "organization", "practitioner", "medication", "patient", "coverage"}, //resources that are shared across multiple conditions {"binary"}, } sourceFlattenRelated = map[string]bool{ diff --git a/backend/pkg/database/gorm_repository_graph_test.go b/backend/pkg/database/gorm_repository_graph_test.go new file mode 100644 index 00000000..49613ddc --- /dev/null +++ b/backend/pkg/database/gorm_repository_graph_test.go @@ -0,0 +1,192 @@ +package database + +import ( + "context" + "fmt" + "github.com/fastenhealth/fasten-onprem/backend/pkg" + mock_config "github.com/fastenhealth/fasten-onprem/backend/pkg/config/mock" + "github.com/fastenhealth/fasten-onprem/backend/pkg/event_bus" + "github.com/fastenhealth/fasten-onprem/backend/pkg/models" + sourceFactory "github.com/fastenhealth/fasten-sources/clients/factory" + sourcePkg "github.com/fastenhealth/fasten-sources/pkg" + "github.com/golang/mock/gomock" + "github.com/google/uuid" + "github.com/sirupsen/logrus" + "github.com/stretchr/testify/require" + "github.com/stretchr/testify/suite" + "io/ioutil" + "log" + "os" + "testing" +) + +// Define the suite, and absorb the built-in basic suite +// functionality from testify - including a T() method which +// returns the current testing context +type RepositoryGraphTestSuite struct { + suite.Suite + MockCtrl *gomock.Controller + TestDatabase *os.File +} + +// BeforeTest has a function to be executed right before the test starts and receives the suite and test names as input +func (suite *RepositoryGraphTestSuite) BeforeTest(suiteName, testName string) { + suite.MockCtrl = gomock.NewController(suite.T()) + + dbFile, err := ioutil.TempFile("", fmt.Sprintf("%s.*.db", testName)) + if err != nil { + log.Fatal(err) + } + suite.TestDatabase = dbFile + +} + +// AfterTest has a function to be executed right after the test finishes and receives the suite and test names as input +func (suite *RepositoryGraphTestSuite) AfterTest(suiteName, testName string) { + suite.MockCtrl.Finish() + os.Remove(suite.TestDatabase.Name()) + os.Remove(suite.TestDatabase.Name() + "-shm") + os.Remove(suite.TestDatabase.Name() + "-wal") +} + +// In order for 'go test' to run this suite, we need to create +// a normal test function and pass our suite to suite.Run +func TestRepositoryGraphTestSuite(t *testing.T) { + suite.Run(t, new(RepositoryGraphTestSuite)) +} + +func (suite *RepositoryGraphTestSuite) TestGetFlattenedResourceGraph() { + //setup + fakeConfig := mock_config.NewMockInterface(suite.MockCtrl) + fakeConfig.EXPECT().GetString("database.location").Return(suite.TestDatabase.Name()).AnyTimes() + fakeConfig.EXPECT().GetString("database.type").Return("sqlite").AnyTimes() + fakeConfig.EXPECT().IsSet("database.encryption.key").Return(false).AnyTimes() + fakeConfig.EXPECT().GetString("log.level").Return("INFO").AnyTimes() + dbRepo, err := NewRepository(fakeConfig, logrus.WithField("test", suite.T().Name()), event_bus.NewNoopEventBusServer()) + require.NoError(suite.T(), err) + + userModel := &models.User{ + Username: "test_username", + Password: "testpassword", + Email: "test@test.com", + } + err = dbRepo.CreateUser(context.Background(), userModel) + require.NoError(suite.T(), err) + require.NotEmpty(suite.T(), userModel.ID) + require.NotEqual(suite.T(), uuid.Nil, userModel.ID) + authContext := context.WithValue(context.Background(), pkg.ContextKeyTypeAuthUsername, "test_username") + + testSourceCredential := models.SourceCredential{ + ModelBase: models.ModelBase{ + ID: uuid.New(), + }, + UserID: userModel.ID, + } + err = dbRepo.CreateSource(authContext, &testSourceCredential) + require.NoError(suite.T(), err) + + bundleFile, err := os.Open("./testdata/Abraham100_Heller342_262b819a-5193-404a-9787-b7f599358035.json") + require.NoError(suite.T(), err) + + testLogger := logrus.WithFields(logrus.Fields{ + "type": "test", + }) + + manualClient, err := sourceFactory.GetSourceClient(sourcePkg.FastenLighthouseEnvSandbox, sourcePkg.SourceTypeManual, authContext, testLogger, &testSourceCredential) + + summary, err := manualClient.SyncAllBundle(dbRepo, bundleFile, sourcePkg.FhirVersion401) + require.NoError(suite.T(), err) + require.Equal(suite.T(), 198, summary.TotalResources) + require.Equal(suite.T(), 234, len(summary.UpdatedResources)) + + //test + options := models.ResourceGraphOptions{ + ResourcesIds: []models.OriginBase{ + { + SourceID: testSourceCredential.ID, + SourceResourceType: "Encounter", + SourceResourceID: "d9a7c76f-dfe4-41c6-9924-82a405613f44", + }, + }, + } + + flattenedGraph, err := dbRepo.GetFlattenedResourceGraph(authContext, pkg.ResourceGraphTypeMedicalHistory, options) + require.NoError(suite.T(), err) + require.NotNil(suite.T(), flattenedGraph) + //validated using http://clinfhir.com/bundleVisualizer.html + + require.Equal(suite.T(), 1, len(flattenedGraph["Encounter"])) + require.Equal(suite.T(), 27, len(flattenedGraph["Encounter"][0].RelatedResource)) + +} + +// Bug: the Epic enounter graph was not consistently return the same related resources +func (suite *RepositoryGraphTestSuite) TestGetFlattenedResourceGraph_NDJson() { + //setup + fakeConfig := mock_config.NewMockInterface(suite.MockCtrl) + fakeConfig.EXPECT().GetString("database.location").Return(suite.TestDatabase.Name()).AnyTimes() + fakeConfig.EXPECT().GetString("database.type").Return("sqlite").AnyTimes() + fakeConfig.EXPECT().IsSet("database.encryption.key").Return(false).AnyTimes() + fakeConfig.EXPECT().GetString("log.level").Return("INFO").AnyTimes() + dbRepo, err := NewRepository(fakeConfig, logrus.WithField("test", suite.T().Name()), event_bus.NewNoopEventBusServer()) + require.NoError(suite.T(), err) + + userModel := &models.User{ + Username: "test_username", + Password: "testpassword", + Email: "test@test.com", + } + err = dbRepo.CreateUser(context.Background(), userModel) + require.NoError(suite.T(), err) + require.NotEmpty(suite.T(), userModel.ID) + require.NotEqual(suite.T(), uuid.Nil, userModel.ID) + authContext := context.WithValue(context.Background(), pkg.ContextKeyTypeAuthUsername, "test_username") + + testSourceCredential := models.SourceCredential{ + ModelBase: models.ModelBase{ + ID: uuid.New(), + }, + UserID: userModel.ID, + } + err = dbRepo.CreateSource(authContext, &testSourceCredential) + require.NoError(suite.T(), err) + + bundleFile, err := os.Open("./testdata/epic_fhircamila.ndjson") + require.NoError(suite.T(), err) + + testLogger := logrus.WithFields(logrus.Fields{ + "type": "test", + }) + + manualClient, err := sourceFactory.GetSourceClient(sourcePkg.FastenLighthouseEnvSandbox, sourcePkg.SourceTypeManual, authContext, testLogger, &testSourceCredential) + + summary, err := manualClient.SyncAllBundle(dbRepo, bundleFile, sourcePkg.FhirVersion401) + require.NoError(suite.T(), err) + require.Equal(suite.T(), 58, summary.TotalResources) + require.Equal(suite.T(), 58, len(summary.UpdatedResources)) + + //test + options := models.ResourceGraphOptions{ + ResourcesIds: []models.OriginBase{ + { + SourceID: testSourceCredential.ID, + SourceResourceType: "Encounter", + SourceResourceID: "eGmO0h.1.UQQrExl4bfM7OQ3", + }, + }, + } + + flattenedGraph, err := dbRepo.GetFlattenedResourceGraph(authContext, pkg.ResourceGraphTypeMedicalHistory, options) + require.NoError(suite.T(), err) + require.NotNil(suite.T(), flattenedGraph) + //validated using http://clinfhir.com/bundleVisualizer.html + + require.Equal(suite.T(), 1, len(flattenedGraph["Encounter"])) + //REGRESSION: in some cases the flattened graph was not correctly returning 7 related, instead only retuning 1 or 4. Bug in Graph generation + + for ndx, found := range flattenedGraph["Encounter"][0].RelatedResource { + suite.T().Logf("ndx: %d, found: %s/%s", ndx, found.SourceResourceType, found.SourceResourceID) + } + require.Equal(suite.T(), 7, len(flattenedGraph["Encounter"][0].RelatedResource)) + +} diff --git a/backend/pkg/database/interface.go b/backend/pkg/database/interface.go index d42a4101..c061ff06 100644 --- a/backend/pkg/database/interface.go +++ b/backend/pkg/database/interface.go @@ -28,7 +28,7 @@ type DatabaseRepository interface { AddResourceAssociation(ctx context.Context, source *models.SourceCredential, resourceType string, resourceId string, relatedSource *models.SourceCredential, relatedResourceType string, relatedResourceId string) error RemoveResourceAssociation(ctx context.Context, source *models.SourceCredential, resourceType string, resourceId string, relatedSource *models.SourceCredential, relatedResourceType string, relatedResourceId string) error FindResourceAssociationsByTypeAndId(ctx context.Context, source *models.SourceCredential, resourceType string, resourceId string) ([]models.RelatedResource, error) - GetFlattenedResourceGraph(ctx context.Context, graphType pkg.ResourceGraphType, options models.ResourceGraphOptions) (map[string][]*models.ResourceBase, *models.ResourceGraphMetadata, error) + GetFlattenedResourceGraph(ctx context.Context, graphType pkg.ResourceGraphType, options models.ResourceGraphOptions) (map[string][]*models.ResourceBase, error) AddResourceComposition(ctx context.Context, compositionTitle string, resources []*models.ResourceBase) error //UpsertProfile(context.Context, *models.Profile) error //UpsertOrganziation(context.Context, *models.Organization) error diff --git a/backend/pkg/database/testdata/epic_fhircamila.ndjson b/backend/pkg/database/testdata/epic_fhircamila.ndjson new file mode 100644 index 00000000..33e7169d --- /dev/null +++ b/backend/pkg/database/testdata/epic_fhircamila.ndjson @@ -0,0 +1,58 @@ +{"resourceType":"AllergyIntolerance","id":"eARZpey6BWRZxRZkRpc8OFJ46j3QOFrduk77hYQKWRQnp6GRlpYc2I3BfUN6pz4Anz77ow8.GJh54fUVfm3O8Vw3","clinicalStatus":{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/allergyintolerance-clinical","version":"4.0.0","code":"active","display":"Active"}]},"verificationStatus":{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/allergyintolerance-verification","version":"4.0.0","code":"unconfirmed","display":"Unconfirmed"}]},"code":{"coding":[{"system":"http://snomed.info/sct","code":"1631000175102","display":"Patient not asked"}],"text":"Not on File"},"patient":{"reference":"Patient/erXuFYUfucBZaryVksYEcMg3","display":"Lopez, Camila Maria"}} +{"contentType":"text/html","data":"PGRpdiBjbGFzcz0iZm10Q29udiIgc3R5bGU9ImxpbmUtaGVpZ2h0OiBub3JtYWw7IGZvbnQtZmFtaWx5OiBBcmlhbDsiPg0KDQo8ZGl2IHN0eWxlPSJ0ZXh0LWFsaWduOiBsZWZ0OyBtYXgtd2lkdGg6IDEwMCU7IiBkYXRhLXBhcmFncmFwaD0iMSI+PHNwYW4gc3R5bGU9ImZvbnQtd2VpZ2h0OiBib2xkOyBmb250LXNpemU6IDE0cHQ7IGZvbnQtZmFtaWx5OiAnU0VHT0UgVUknOyBjb2xvcjogIzAwMDAwMDsiPlN1YmplY3RpdmU8L3NwYW4+PC9kaXY+DQo8ZGl2IHN0eWxlPSJ0ZXh0LWFsaWduOiBsZWZ0OyBtYXgtd2lkdGg6IDEwMCU7IiBkYXRhLXBhcmFncmFwaD0iMSI+PHNwYW4gc3R5bGU9ImZvbnQtd2VpZ2h0OiBib2xkOyBmb250LXNpemU6IDExcHQ7IGZvbnQtZmFtaWx5OiAnU0VHT0UgVUknOyBjb2xvcjogIzAwMDAwMDsiPlBhdGllbnQgSUQ6PC9zcGFuPjxzcGFuIHN0eWxlPSJmb250LXdlaWdodDogYm9sZDsgZm9udC1zaXplOiAxMXB0OyBmb250LWZhbWlseTogJ1NFR09FIFVJJzsgY29sb3I6ICMwMDAwQTA7IHdoaXRlLXNwYWNlOiBwcmUtd3JhcDsiPiA8L3NwYW4+PHNwYW4gc3R5bGU9ImZvbnQtc2l6ZTogMTFwdDsgZm9udC1mYW1pbHk6ICdTRUdPRSBVSSc7IGNvbG9yOiAjMDAwMDAwOyI+Q2Ft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xlPSJmb250LXNpemU6IDExcHQ7IGZvbnQtZmFtaWx5OiAnU0VHT0UgVUknOyBjb2xvcjogIzAwMDAwMDsiPiZuYnNwOzwvc3Bhbj48L2Rpdj4NCjxkaXYgc3R5bGU9InRleHQtYWxpZ246IGxlZnQ7IG1heC13aWR0aDogMTAwJTsiIGRhdGEtcGFyYWdyYXBoPSIxIj48c3BhbiBzdHlsZT0iZm9udC13ZWlnaHQ6IGJvbGQ7IGZvbnQtc2l6ZTogMTRwdDsgZm9udC1mYW1pbHk6ICdTRUdPRSBVSSc7IGNvbG9yOiAjMDAwMDAwOyI+QXNzZXNzbWVudC9QbGFuPC9zcGFuPjwvZGl2Pg0KPGRpdiBzdHlsZT0idGV4dC1hbGlnbjogbGVmdDsgbWF4LXdpZHRoOiAxMDAlOyB3aWRvd3M6IDE7IG9ycGhhbnM6IDE7IiBkYXRhLXBhcmFncmFwaD0iMSI+PHNwYW4gc3R5bGU9ImZvbnQtc2l6ZTogMTFwdDsgZm9udC1mYW1pbHk6ICdTRUdPRSBVSSc7IGNvbG9yOiAjMDAwMDAwOyI+VGhlcmUgYXJlIG5vIGRpYWdub3NlcyBsaW5rZWQgdG8gdGhpcyBlbmNvdW50ZXIuPC9zcGFuPjwvZGl2PjwvZGl2Pg0K","id":"eXGCC0U1rMIkqT43GlAEfsA3","resourceType":"Binary"} +{"contentType":"text/html","data":"IDxicj5ObyBmaW5kaW5ncy4gUmVmZXIgdG8gY2FyZGlvbG9neS4=","id":"eatrFYJ-c5OxFaXGGKhRmtxnlc-Z0vWhRnWj621bo99g3","resourceType":"Binary"} +{"contentType":"text/html","data":"JiMxODM7IExlZnQgdmVudHJpY2xlIGVqZWN0aW9uIGZyYWN0aW9uIGlzIG5vcm1hbC48YnI+JiMxODM7IFNlcHRhbCB3YWxsIGhhcyBhYm5vcm1hbCBtb3Rpb24gY29uc2lzdGVudCB3aXRoIHBvc3Qtb3BlcmF0aXZlIHN0YXR1cy48YnI+Jm5ic3A7PGJyPkhl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HBhcn0=","id":"ftlnC8mfyjUVrXEpeEsj12f1.H.Tu5gtgXv1gF4e3F4Y4","resourceType":"Binary"} +{"resourceType":"CareTeam","id":"elXzftb61zxJqvM4xV3jTzA3","status":"active","category":[{"coding":[{"system":"http://loinc.org","code":"LA28865-6","display":"Longitudinal care-coordination focused care team"}],"text":"Longitudinal care-coordination focused care team"}],"subject":{"reference":"Patient/erXuFYUfucBZaryVksYEcMg3","display":"Lopez, Camila Maria"},"participant":[{"role":[{"coding":[{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.4.836982.1050","code":"9","display":"Family Medicine"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.4.698084.5655","code":"1","display":"General"}],"text":"Family Medicine"}],"member":{"reference":"Practitioner/eM5CWtq15N0WJeuCet5bJlQ3","type":"Practitioner","display":"Physician"}}]} +{"resourceType":"Condition","id":"euDDjG6i1-OkhZii5APxOiw3","clinicalStatus":{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/condition-clinical","version":"4.0.0","code":"active","display":"Active"}],"text":"Active"},"verificationStatus":{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/condition-ver-status","version":"4.0.0","code":"confirmed","display":"Confirmed"}],"text":"Confirmed"},"category":[{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/condition-category","code":"problem-list-item","display":"Problem List Item"}],"text":"Problem List Item"}],"severity":{"text":"Medium"},"code":{"coding":[{"system":"http://hl7.org/fhir/sid/icd-10-cm","code":"E28.2"},{"system":"http://snomed.info/sct","code":"69878008"}],"text":"Polycystic ovaries"},"subject":{"reference":"Patient/erXuFYUfucBZaryVksYEcMg3","display":"Lopez, Camila Maria"},"onsetPeriod":{"start":"2005-09-20","end":"2005-09-20"},"recordedDate":"2019-05-28"} +{"category":[{"coding":[{"code":"care-plan-problem","display":"Care Plan Problem","system":"http://open.epic.com/FHIR/StructureDefinition/condition-category"}],"text":"Care Plan Problem"}],"clinicalStatus":{"coding":[{"code":"active","display":"Active","system":"http://terminology.hl7.org/CodeSystem/condition-clinical","version":"4.0.0"}],"text":"Active"},"code":{"text":"Pain - Adult"},"extension":[{"url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-asserter","valueReference":{"display":"NURSING","type":"PractitionerRole"}},{"url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-asserter","valueReference":{"display":"INTERDISCIPLINARY","type":"PractitionerRole"}},{"url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-asserter","valueReference":{"display":"PHYSICAL THERAPY","type":"PractitionerRole"}},{"url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-asserter","valueReference":{"display":"RESPIRATORY THERAPY","type":"PractitionerRole"}},{"url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-asserter","valueReference":{"display":"SOCIAL WORK","type":"PractitionerRole"}}],"id":"e-oL436hofxVBDhMRXD9mrg3","onsetDateTime":"2023-06-02","recordedDate":"2023-06-02","recorder":{"display":"Robert Z","reference":"Practitioner/eHP1iZcoohQAKIcKyP6CDvA3"},"resourceType":"Condition","subject":{"display":"Lopez, Camila Maria","reference":"Patient/erXuFYUfucBZaryVksYEcMg3"}} +{"category":[{"coding":[{"code":"care-plan-problem","display":"Care Plan Problem","system":"http://open.epic.com/FHIR/StructureDefinition/condition-category"}],"text":"Care Plan Problem"}],"clinicalStatus":{"coding":[{"code":"active","display":"Active","system":"http://terminology.hl7.org/CodeSystem/condition-clinical","version":"4.0.0"}],"text":"Active"},"code":{"text":"Discharge Planning"},"extension":[{"url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-asserter","valueReference":{"display":"NURSING","type":"PractitionerRole"}},{"url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-asserter","valueReference":{"display":"INTERDISCIPLINARY","type":"PractitionerRole"}},{"url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-asserter","valueReference":{"display":"RESPIRATORY THERAPY","type":"PractitionerRole"}},{"url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-asserter","valueReference":{"display":"SOCIAL WORK","type":"PractitionerRole"}}],"id":"e7.CXqjHOcMA8Gxl2sOOs3w3","onsetDateTime":"2023-06-02","recordedDate":"2023-06-02","recorder":{"display":"Robert Z","reference":"Practitioner/eHP1iZcoohQAKIcKyP6CDvA3"},"resourceType":"Condition","subject":{"display":"Lopez, Camila Maria","reference":"Patient/erXuFYUfucBZaryVksYEcMg3"}} +{"category":[{"coding":[{"code":"care-plan-problem","display":"Care Plan Problem","system":"http://open.epic.com/FHIR/StructureDefinition/condition-category"}],"text":"Care Plan Problem"}],"clinicalStatus":{"coding":[{"code":"active","display":"Active","system":"http://terminology.hl7.org/CodeSystem/condition-clinical","version":"4.0.0"}],"text":"Active"},"code":{"text":"Safety Adult - Fall"},"extension":[{"url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-asserter","valueReference":{"display":"NURSING","type":"PractitionerRole"}},{"url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-asserter","valueReference":{"display":"INTERDISCIPLINARY","type":"PractitionerRole"}},{"url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-asserter","valueReference":{"display":"RESPIRATORY THERAPY","type":"PractitionerRole"}},{"url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-asserter","valueReference":{"display":"SOCIAL WORK","type":"PractitionerRole"}}],"id":"e1tKlHlRqm9EXhpS9iLx4xA3","onsetDateTime":"2023-06-02","recordedDate":"2023-06-02","recorder":{"display":"Robert Z","reference":"Practitioner/eHP1iZcoohQAKIcKyP6CDvA3"},"resourceType":"Condition","subject":{"display":"Lopez, Camila Maria","reference":"Patient/erXuFYUfucBZaryVksYEcMg3"}} +{"category":[{"coding":[{"code":"care-plan-problem","display":"Care Plan Problem","system":"http://open.epic.com/FHIR/StructureDefinition/condition-category"}],"text":"Care Plan Problem"}],"clinicalStatus":{"coding":[{"code":"active","display":"Active","system":"http://terminology.hl7.org/CodeSystem/condition-clinical","version":"4.0.0"}],"text":"Active"},"code":{"text":"Chronic Conditions and Co-morbidities"},"id":"eshaiIZ7f0Z.ptm.6wNwjrA3","onsetDateTime":"2023-06-02","recordedDate":"2023-06-02","recorder":{"display":"Robert Z","reference":"Practitioner/eHP1iZcoohQAKIcKyP6CDvA3"},"resourceType":"Condition","subject":{"display":"Lopez, Camila Maria","reference":"Patient/erXuFYUfucBZaryVksYEcMg3"}} +{"category":[{"coding":[{"code":"care-plan-problem","display":"Care Plan Problem","system":"http://open.epic.com/FHIR/StructureDefinition/condition-category"}],"text":"Care Plan Problem"}],"clinicalStatus":{"coding":[{"code":"active","display":"Active","system":"http://terminology.hl7.org/CodeSystem/condition-clinical","version":"4.0.0"}],"text":"Active"},"code":{"text":"Infection - Adult"},"extension":[{"url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-asserter","valueReference":{"display":"NURSING","type":"PractitionerRole"}},{"url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-asserter","valueReference":{"display":"INTERDISCIPLINARY","type":"PractitionerRole"}},{"url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-asserter","valueReference":{"display":"RESPIRATORY THERAPY","type":"PractitionerRole"}},{"url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-asserter","valueReference":{"display":"SOCIAL WORK","type":"PractitionerRole"}}],"id":"enxs1cxkwzPxvOqZcUj4IVQ3","onsetDateTime":"2023-06-02","recordedDate":"2023-06-02","recorder":{"display":"Robert Z","reference":"Practitioner/eHP1iZcoohQAKIcKyP6CDvA3"},"resourceType":"Condition","subject":{"display":"Lopez, Camila Maria","reference":"Patient/erXuFYUfucBZaryVksYEcMg3"}} +{"resourceType":"DiagnosticReport","id":"ebLG6RMUaZyb2xk2DuX.kd4g8mNRffn9ftcwqSmnhrwM3","identifier":[{"use":"official","type":{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/v2-0203","code":"PLAC","display":"Placer Identifier"}],"text":"Placer Identifier"},"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.798268","value":"1066905"}],"basedOn":[{"reference":"ServiceRequest/egf4KkhXmgeVWImXEEYH.CEE1ZgJG5SQy2vBX1HgvBCs3","type":"ServiceRequest"}],"status":"final","category":[{"coding":[{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.10.798268.30","code":"Lab"}],"text":"Lab"},{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/v2-0074","code":"LAB","display":"Laboratory"}],"text":"Laboratory"}],"code":{"coding":[{"system":"http://loinc.org","code":"4548-4"},{"system":"urn:oid:2.16.840.1.113883.6.12","code":"83036","display":"PR GLYCOSYLATED HEMOGLOBIN TEST"},{"system":"urn:oid:2.16.840.1.113883.6.96","code":"43396009","display":"HEMOGLOBIN A1C"}],"text":"Hemoglobin A1c"},"subject":{"reference":"Patient/erXuFYUfucBZaryVksYEcMg3","display":"Lopez, Camila Maria"},"encounter":{"reference":"Encounter/elMz2mwjsRvKnZiR.0ceTUg3","identifier":{"use":"usual","system":"urn:oid:1.2.840.114350.1.13.0.1.7.3.698084.8","value":"27558"},"display":"Office Visit"},"effectiveDateTime":"2019-05-28T14:22:00Z","issued":"2019-05-28T14:22:00Z","performer":[{"reference":"Practitioner/eM5CWtq15N0WJeuCet5bJlQ3","type":"Practitioner","display":"Physician"}],"result":[{"reference":"Observation/eyPMWgv2u2RUfsV4p1lLKuUtqyPs2-QNi2zKvbTsFYtRByc6B.cSi1iVU5V2HOpX23","display":"Component (1): HEMOGLOBIN A1C, POC"}]} +{"resourceType":"DiagnosticReport","id":"eeIUePPFhkOlGgtsbPko4a4tPlKY9045CYysh7Ryulnc3","identifier":[{"use":"official","type":{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/v2-0203","code":"PLAC","display":"Placer Identifier"}],"text":"Placer Identifier"},"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.798268","value":"1066912"},{"use":"official","type":{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/v2-0203","code":"FILL","display":"Filler Identifier"}],"text":"Filler Identifier"},"value":"161"}],"basedOn":[{"reference":"ServiceRequest/ePsXywWuaF47D-FPsxcnz3BOk1-JNF41RJJEMQu.2TCA3","type":"ServiceRequest"}],"status":"final","category":[{"coding":[{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.10.798268.30","code":"Imaging"}],"text":"Imaging"},{"coding":[{"system":"http://loinc.org","code":"LP29684-5","display":"Radiology"}],"text":"Radiology"}],"code":{"coding":[{"system":"http://loinc.org","code":"36643-5"},{"system":"urn:oid:2.16.840.1.113883.6.12","code":"71020","display":"HC XR CHEST 2V"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.5.737384.52000","code":"7000029"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.5.737384.72","code":"IMG36"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.5.737384.155","code":"RPID2503"}],"text":"X-ray Chest 2 Views"},"subject":{"reference":"Patient/erXuFYUfucBZaryVksYEcMg3","display":"Lopez, Camila Maria"},"encounter":{"reference":"Encounter/eoIRZgvu9RhrwOzDlZkRbSg3","identifier":{"use":"usual","system":"urn:oid:1.2.840.114350.1.13.0.1.7.3.698084.8","value":"29541"},"display":"Hospital Outpatient Visit"},"effectiveDateTime":"2023-06-02T20:43:46Z","issued":"2023-07-25T13:27:19Z","performer":[{"reference":"Practitioner/eM5CWtq15N0WJeuCet5bJlQ3","type":"Practitioner","display":"Physician"},{"reference":"Practitioner/elpRiy0AYgjhdjAhTBJ3Aiw3","type":"Practitioner","display":"Np"},{"reference":"Organization/etOhDRFmHqAJ3CBmvHCeF9VYgSiH5bYCNkDSOho2TXb43","type":"Organization","display":"IMAGING"}],"resultsInterpreter":[{"reference":"Practitioner/eM5CWtq15N0WJeuCet5bJlQ3","type":"Practitioner","display":"Physician"}],"result":[{"reference":"Observation/eWQ91GjryHtrlYhSNxK1L7mI-fgFwPAedom.YQ4JDeQk3","display":"Narrative"},{"reference":"Observation/eWQ91GjryHtrlYhSNxK1L7hOQbiABlro0a6oo2bIh68I3","display":"Impression"}],"conclusionCode":[{"coding":[{"system":"urn:oid:2.16.840.1.113883.6.103","code":"786.50","display":"Ischemic chest pain (CMS/HCC)"}],"text":"Ischemic chest pain"}],"presentedForm":[{"contentType":"text/html","url":"Binary/eatrFYJ-c5OxFaXGGKhRmt-kbn-1xHl8SNrcCB4fHVps3","title":"Narrative"},{"contentType":"text/html","url":"Binary/eatrFYJ-c5OxFaXGGKhRmtxnlc-Z0vWhRnWj621bo99g3","title":"Impression"}]} +{"resourceType":"DiagnosticReport","id":"ejRFFAyoWd-DvE0lHi4UEUVA9qTH9PxfCLhEetlq04Ck3","identifier":[{"use":"official","type":{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/v2-0203","code":"PLAC","display":"Placer Identifier"}],"text":"Placer Identifier"},"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.798268","value":"1066915"},{"use":"official","type":{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/v2-0203","code":"FILL","display":"Filler Identifier"}],"text":"Filler Identifier"},"value":"162"}],"basedOn":[{"reference":"ServiceRequest/e6t1HtRj0Za8M9Y0u5nU2tu3idJ7P66B2HzlMtddZ6Wc3","type":"ServiceRequest"}],"status":"final","category":[{"coding":[{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.10.798268.30","code":"Echo"}],"text":"Echocardiography"},{"coding":[{"system":"http://loinc.org","code":"LP29708-2","display":"Cardiology"}],"text":"Cardiology"}],"code":{"coding":[{"system":"urn:oid:2.16.840.1.113883.6.12","code":"93306","display":"HC TRANSTHORACIC ECHO"}],"text":"Transthoracic Echo (TTE) Complete"},"subject":{"reference":"Patient/erXuFYUfucBZaryVksYEcMg3","display":"Lopez, Camila Maria"},"encounter":{"reference":"Encounter/ej567ARSFdaF4ooZVunIlIg3","identifier":{"use":"usual","system":"urn:oid:1.2.840.114350.1.13.0.1.7.3.698084.8","value":"29542"},"display":"Hospital Outpatient Visit"},"effectiveDateTime":"2023-06-02T20:50:25Z","issued":"2023-07-25T13:26:44Z","performer":[{"reference":"Practitioner/eM5CWtq15N0WJeuCet5bJlQ3","type":"Practitioner","display":"Physician"},{"reference":"Practitioner/elpRiy0AYgjhdjAhTBJ3Aiw3","type":"Practitioner","display":"Np"},{"reference":"Organization/eVUDU8oWh9.KM7oI8Mu9jlqn1C3d5ozeHAXDHuaPYsvU3","type":"Organization","display":"CPACS"}],"resultsInterpreter":[{"reference":"Practitioner/eM5CWtq15N0WJeuCet5bJlQ3","type":"Practitioner","display":"Physician"}],"result":[{"reference":"Observation/epvZIWrCStn-QxWdd6yDL2rsODx.M3VAMdHGGYcFbGkQ3","display":"Narrative"},{"reference":"Observation/eUnZeZkXn.qk2e15Fa5GSJrQuuYKhh55JdwnpB0Cppeo3","display":"Myocardial Finding: Left Ventricle"}],"conclusionCode":[{"coding":[{"system":"urn:oid:2.16.840.1.113883.6.103","code":"786.50","display":"Ischemic chest pain (CMS/HCC)"}],"text":"Ischemic chest pain"}],"presentedForm":[{"contentType":"text/html","url":"Binary/ey9R3HQvzT5D6lNvbJeLdyTF10pM-Yzpp1nsL-VLVkJc3","title":"Narrative"}]} +{"resourceType":"DiagnosticReport","id":"e1xW6IyYA20h9CHX4rXDK8wRZibvNskG.0jb.xlYR.OI3","identifier":[{"use":"official","type":{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/v2-0203","code":"PLAC","display":"Placer Identifier"}],"text":"Placer Identifier"},"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.798268","value":"1159966"}],"basedOn":[{"reference":"ServiceRequest/enf3AGjDevbeKPagusE3V1s5OQotZY-b9J5pspEt6PfU3","type":"ServiceRequest"}],"status":"final","category":[{"coding":[{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.10.798268.30","code":"Path,Cyt"}],"text":"Pathology and Cytology"},{"coding":[{"system":"http://loinc.org","code":"LP7839-6","display":"Pathology"}],"text":"Pathology"}],"code":{"coding":[{"system":"urn:oid:2.16.840.1.113883.6.12","code":"88305","display":"PR SURG PATH,LEVEL IV"}],"text":"Specimen to pathology"},"subject":{"reference":"Patient/erXuFYUfucBZaryVksYEcMg3","display":"Lopez, Camila Maria"},"encounter":{"reference":"Encounter/eMT95RPaM-HxLc3NeIA5qlQ3","identifier":{"use":"usual","system":"urn:oid:1.2.840.114350.1.13.0.1.7.3.698084.8","value":"29544"},"display":"Office Visit"},"effectiveDateTime":"2023-06-02T21:02:00Z","issued":"2023-06-02T21:02:00Z","performer":[{"reference":"Practitioner/e2qocqJm-DdjHLS0Not4qjA3","type":"Practitioner","display":"Historical"}]} +{"resourceType":"DocumentReference","id":"eNreR3hAkvySSHIcq2Lrxlw3","identifier":[{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.727879","value":"196763"},{"system":"urn:oid:1.2.840.114350.1.72.3.15","value":"1.2.840.114350.1.13.0.1.7.2.727879_196763"}],"status":"current","docStatus":"final","type":{"coding":[{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.4.737880.5010","code":"1","display":"Progress Notes"},{"system":"urn:oid:1.2.840.114350.1.72.727879.69848980","code":"1","display":"Progress Notes"},{"system":"http://loinc.org","code":"11506-3","display":"Provider-unspecified Progress note","userSelected":true}],"text":"Progress Notes"},"category":[{"coding":[{"system":"http://hl7.org/fhir/us/core/CodeSystem/us-core-documentreference-category","code":"clinical-note","display":"Clinical Note"}],"text":"Clinical Note"}],"subject":{"reference":"Patient/erXuFYUfucBZaryVksYEcMg3","display":"Lopez, Camila Maria"},"date":"2023-05-21T16:55:00Z","author":[{"reference":"Practitioner/eUXiD4IyBLJFoR2VHOjfTdg3","type":"Practitioner","display":"Physician"}],"authenticator":{"extension":[{"valueDateTime":"2023-05-21T16:57:01Z","url":"http://open.epic.com/FHIR/StructureDefinition/extension/clinical-note-authentication-instant"}],"reference":"Practitioner/eUXiD4IyBLJFoR2VHOjfTdg3","type":"Practitioner","display":"Physician"},"custodian":{"identifier":{"system":"urn:ietf:rfc:3986","value":"urn:oid:fhir"},"display":"Epic USCDI on FHIR"},"content":[{"attachment":{"contentType":"text/html","url":"Binary/eXGCC0U1rMIkqT43GlAEfsA3"},"format":{"system":"http://ihe.net/fhir/ValueSet/IHE.FormatCode.codesystem","code":"urn:ihe:iti:xds:2017:mimeTypeSufficient","display":"mimeType Sufficient"}},{"attachment":{"contentType":"text/rtf","url":"Binary/ftlnC8mfyjUVrXEpeEsj12f1.H.Tu5gtgXv1gF4e3F4Y4"},"format":{"system":"http://ihe.net/fhir/ValueSet/IHE.FormatCode.codesystem","code":"urn:ihe:iti:xds:2017:mimeTypeSufficient","display":"mimeType Sufficient"}}],"context":{"extension":[{"valueCodeableConcept":{"coding":[{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.4.836982.1040","code":"1","display":"Physician"},{"system":"urn:oid:2.16.840.1.113883.11.19465","code":"207Q00000X","display":"Family Medicine Physician"}],"text":"Physician"},"url":"http://open.epic.com/FHIR/StructureDefinition/extension/clinical-note-author-provider-type"}],"encounter":[{"reference":"Encounter/exfbAtPCSLnf8s.193aMUnQ3","identifier":{"use":"usual","system":"urn:oid:1.2.840.114350.1.13.0.1.7.3.698084.8","value":"29539"},"display":"Office Visit"}],"period":{"start":"2023-05-21T16:53:00Z"}}} +{"resourceType":"DocumentReference","id":"ewtIzA62-DkL21MnJY6OyRj8UF8vh7UuasqvGB1pc5CY3","identifier":[{"use":"usual","system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.798268","value":"1066912"}],"status":"current","type":{"coding":[{"system":"http://loinc.org","code":"18748-4","display":"Diagnostic imaging study"}],"text":"Diagnostic imaging study"},"category":[{"coding":[{"system":"http://hl7.org/fhir/us/core/CodeSystem/us-core-documentreference-category","code":"clinical-note","display":"Clinical Note"}],"text":"Clinical Note"}],"subject":{"reference":"Patient/erXuFYUfucBZaryVksYEcMg3","display":"Lopez, Camila Maria"},"date":"2023-06-02T20:43:46Z","author":[{"reference":"Practitioner/eM5CWtq15N0WJeuCet5bJlQ3","type":"Practitioner","display":"Physician"}],"custodian":{"display":"Epic USCDI on FHIR"},"content":[{"attachment":{"contentType":"text/html","url":"Binary/eatrFYJ-c5OxFaXGGKhRmtxnlc-Z0vWhRnWj621bo99g3"},"format":{"system":"http://ihe.net/fhir/ValueSet/IHE.FormatCode.codesystem","code":"urn:ihe:iti:xds:2017:mimeTypeSufficient","display":"mimeType Sufficient"}}],"context":{"encounter":[{"reference":"Encounter/eoIRZgvu9RhrwOzDlZkRbSg3","identifier":{"use":"usual","system":"urn:oid:1.2.840.114350.1.13.0.1.7.3.698084.8","value":"29541"},"display":"Hospital Outpatient Visit"}],"period":{"start":"2023-06-02T20:43:46Z"}}} +{"resourceType":"DocumentReference","id":"ewtIzA62-DkL21MnJY6OyRhIhI5asLLt7L5RQtNUW6qY3","identifier":[{"use":"usual","system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.798268","value":"1066912"}],"status":"current","type":{"coding":[{"system":"http://loinc.org","code":"18748-4","display":"Diagnostic imaging study"}],"text":"Diagnostic imaging study"},"category":[{"coding":[{"system":"http://hl7.org/fhir/us/core/CodeSystem/us-core-documentreference-category","code":"clinical-note","display":"Clinical Note"}],"text":"Clinical Note"}],"subject":{"reference":"Patient/erXuFYUfucBZaryVksYEcMg3","display":"Lopez, Camila Maria"},"date":"2023-06-02T20:43:46Z","author":[{"reference":"Practitioner/eM5CWtq15N0WJeuCet5bJlQ3","type":"Practitioner","display":"Physician"}],"custodian":{"display":"Epic USCDI on FHIR"},"content":[{"attachment":{"contentType":"text/html","url":"Binary/eatrFYJ-c5OxFaXGGKhRmt-kbn-1xHl8SNrcCB4fHVps3"},"format":{"system":"http://ihe.net/fhir/ValueSet/IHE.FormatCode.codesystem","code":"urn:ihe:iti:xds:2017:mimeTypeSufficient","display":"mimeType Sufficient"}}],"context":{"encounter":[{"reference":"Encounter/eoIRZgvu9RhrwOzDlZkRbSg3","identifier":{"use":"usual","system":"urn:oid:1.2.840.114350.1.13.0.1.7.3.698084.8","value":"29541"},"display":"Hospital Outpatient Visit"}],"period":{"start":"2023-06-02T20:43:46Z"}}} +{"resourceType":"DocumentReference","id":"euYCTLWovmnCqF5RhHJi3Z25sdrk5joaPj1R8zBg5PYM3","identifier":[{"use":"usual","system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.798268","value":"1066915"}],"status":"current","type":{"coding":[{"system":"http://loinc.org","code":"18748-4","display":"Diagnostic imaging study"}],"text":"Diagnostic imaging study"},"category":[{"coding":[{"system":"http://hl7.org/fhir/us/core/CodeSystem/us-core-documentreference-category","code":"clinical-note","display":"Clinical Note"}],"text":"Clinical Note"}],"subject":{"reference":"Patient/erXuFYUfucBZaryVksYEcMg3","display":"Lopez, Camila Maria"},"date":"2023-06-02T20:50:25Z","author":[{"reference":"Practitioner/eM5CWtq15N0WJeuCet5bJlQ3","type":"Practitioner","display":"Physician"}],"custodian":{"display":"Epic USCDI on FHIR"},"content":[{"attachment":{"contentType":"text/html","url":"Binary/ey9R3HQvzT5D6lNvbJeLdyTF10pM-Yzpp1nsL-VLVkJc3"},"format":{"system":"http://ihe.net/fhir/ValueSet/IHE.FormatCode.codesystem","code":"urn:ihe:iti:xds:2017:mimeTypeSufficient","display":"mimeType Sufficient"}}],"context":{"encounter":[{"reference":"Encounter/ej567ARSFdaF4ooZVunIlIg3","identifier":{"use":"usual","system":"urn:oid:1.2.840.114350.1.13.0.1.7.3.698084.8","value":"29542"},"display":"Hospital Outpatient Visit"}],"period":{"start":"2023-06-02T20:50:25Z"}}} +{"resourceType":"Encounter","id":"eGmO0h.1.UQQrExl4bfM7OQ3","identifier":[{"use":"usual","system":"urn:oid:1.2.840.114350.1.13.0.1.7.3.698084.8","value":"29545"}],"status":"unknown","class":{"system":"urn:oid:1.2.840.114350.1.72.1.7.7.10.696784.13260","code":"10","display":"Surgery Log"},"type":[{"coding":[{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.10.698084.30","code":"51","display":"Surgery"}],"text":"Surgery"}],"subject":{"reference":"Patient/erXuFYUfucBZaryVksYEcMg3","display":"Lopez, Camila Maria"},"participant":[{"individual":{"reference":"Practitioner/eM5CWtq15N0WJeuCet5bJlQ3","type":"Practitioner","display":"Physician"}}],"period":{"start":"2023-06-06T16:20:00Z","end":"2023-06-06T17:35:00Z"},"location":[{"location":{"reference":"Location/efR3SIdpRKF9BFBM5qakt9F5X1mWxjiAGu2hNTKbqOdI3","display":"EMH Operating Room"}}],"partOf":{"reference":"Encounter/eoK8nLRcEypNjtns4dgnF3Q3","identifier":{"use":"usual","system":"urn:oid:1.2.840.114350.1.13.0.1.7.3.698084.8","value":"29547"},"display":"Emergency Department"}} +{"resourceType":"Encounter","id":"eMT95RPaM-HxLc3NeIA5qlQ3","identifier":[{"use":"usual","system":"urn:oid:1.2.840.114350.1.13.0.1.7.3.698084.8","value":"29544"}],"status":"in-progress","class":{"system":"urn:oid:1.2.840.114350.1.72.1.7.7.10.696784.13260","code":"13","display":"Support OP Encounter"},"type":[{"coding":[{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.10.698084.30","code":"101","display":"Office Visit"}],"text":"Office Visit"}],"subject":{"reference":"Patient/erXuFYUfucBZaryVksYEcMg3","display":"Lopez, Camila Maria"},"participant":[{"individual":{"reference":"Practitioner/eM5CWtq15N0WJeuCet5bJlQ3","type":"Practitioner","display":"Physician"}}],"period":{"start":"2023-06-02","end":"2023-06-02"},"location":[{"location":{"reference":"Location/e4W4rmGe9QzuGm2Dy4NBqVc0KDe6yGld6HW95UuN-Qd03","display":"EMC Family Medicine"}}]} +{"resourceType":"Encounter","id":"ej567ARSFdaF4ooZVunIlIg3","identifier":[{"use":"usual","system":"urn:oid:1.2.840.114350.1.13.0.1.7.3.698084.8","value":"29542"}],"status":"in-progress","class":{"system":"urn:oid:1.2.840.114350.1.72.1.7.7.10.696784.13260","code":"4","display":"HOV"},"type":[{"coding":[{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.10.698084.10110","code":"102","display":"Outpatient"}],"text":"Outpatient"},{"coding":[{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.10.698084.30","code":"3","display":"Hospital Encounter"}],"text":"Hospital Encounter"},{"coding":[{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.808267","code":"10023","display":"Transthoracic Echocardiogram Complete"}],"text":"Transthoracic Echocardiogram Complete"}],"subject":{"reference":"Patient/erXuFYUfucBZaryVksYEcMg3","display":"Lopez, Camila Maria"},"participant":[{"type":[{"coding":[{"system":"http://hl7.org/fhir/v3/ParticipationType","code":"REF","display":"referrer"}],"text":"referrer"}],"individual":{"reference":"Practitioner/elpRiy0AYgjhdjAhTBJ3Aiw3","type":"Practitioner","display":"Np"}}],"period":{"start":"2023-06-02T20:49:58Z"},"account":[{"identifier":{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.726582","value":"1000501"},"display":"LOPEZ,CAMILA MARIA"}],"hospitalization":{"extension":[{"valueDateTime":"2023-06-02T20:49:00Z","url":"http://open.epic.com/FHIR/StructureDefinition/extension/observation-datetime"}]},"location":[{"location":{"reference":"Location/exzJSfs-2YYqMPilpdzkcdMVzw6TB9WJfeqFRVe.cpSo3","display":"EMC Cardiology Procedures"}},{"location":{"reference":"Location/exzJSfs-2YYqMPilpdzkcdMVzw6TB9WJfeqFRVe.cpSo3","display":"EMC Cardiology Procedures"}},{"location":{"reference":"Location/eQSOrLdbVrMRc68KBcTBG4A3","display":"Epic Hospital System"}}]} +{"resourceType":"Encounter","id":"eoIRZgvu9RhrwOzDlZkRbSg3","identifier":[{"use":"usual","system":"urn:oid:1.2.840.114350.1.13.0.1.7.3.698084.8","value":"29541"}],"status":"in-progress","class":{"system":"urn:oid:1.2.840.114350.1.72.1.7.7.10.696784.13260","code":"4","display":"HOV"},"type":[{"coding":[{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.10.698084.10110","code":"102","display":"Outpatient"}],"text":"Outpatient"},{"coding":[{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.10.698084.30","code":"3","display":"Hospital Encounter"}],"text":"Hospital Encounter"},{"coding":[{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.808267","code":"1053001","display":"X-Ray Exam"}],"text":"X-Ray Exam"}],"subject":{"reference":"Patient/erXuFYUfucBZaryVksYEcMg3","display":"Lopez, Camila Maria"},"participant":[{"type":[{"coding":[{"system":"http://hl7.org/fhir/v3/ParticipationType","code":"REF","display":"referrer"}],"text":"referrer"}],"individual":{"reference":"Practitioner/elpRiy0AYgjhdjAhTBJ3Aiw3","type":"Practitioner","display":"Np"}}],"period":{"start":"2023-06-02T20:41:08Z"},"account":[{"identifier":{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.726582","value":"1000501"},"display":"LOPEZ,CAMILA MARIA"}],"hospitalization":{"extension":[{"valueDateTime":"2023-06-02T20:41:00Z","url":"http://open.epic.com/FHIR/StructureDefinition/extension/observation-datetime"}]},"location":[{"location":{"reference":"Location/e6.GHPEJ3Jrk18e14wi2AJ5vFRqvLa0ZB6qH40N4UgB03","display":"EMH X-Ray Imaging"}},{"location":{"reference":"Location/e6.GHPEJ3Jrk18e14wi2AJ5vFRqvLa0ZB6qH40N4UgB03","display":"EMH X-Ray Imaging"}},{"location":{"reference":"Location/eQSOrLdbVrMRc68KBcTBG4A3","display":"Epic Hospital System"}}]} +{"resourceType":"Encounter","id":"exfbAtPCSLnf8s.193aMUnQ3","identifier":[{"use":"usual","system":"urn:oid:1.2.840.114350.1.13.0.1.7.3.698084.8","value":"29539"}],"status":"finished","class":{"system":"urn:oid:1.2.840.114350.1.72.1.7.7.10.696784.13260","code":"13","display":"Support OP Encounter"},"type":[{"coding":[{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.10.698084.30","code":"101","display":"Office Visit"}],"text":"Office Visit"}],"subject":{"reference":"Patient/erXuFYUfucBZaryVksYEcMg3","display":"Lopez, Camila Maria"},"participant":[{"type":[{"text":"losAuthorizingPhysician"}],"individual":{"reference":"Practitioner/eM5CWtq15N0WJeuCet5bJlQ3","type":"Practitioner","display":"Physician"}}],"period":{"start":"2023-05-21","end":"2023-05-21"},"location":[{"location":{"reference":"Location/e4W4rmGe9QzuGm2Dy4NBqVc0KDe6yGld6HW95UuN-Qd03","display":"EMC Family Medicine"}}]} +{"resourceType":"Encounter","id":"elMz2mwjsRvKnZiR.0ceTUg3","identifier":[{"use":"usual","system":"urn:oid:1.2.840.114350.1.13.0.1.7.3.698084.8","value":"27558"}],"status":"in-progress","class":{"system":"urn:oid:1.2.840.114350.1.72.1.7.7.10.696784.13260","code":"13","display":"Support OP Encounter"},"type":[{"coding":[{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.10.698084.30","code":"101","display":"Office Visit"}],"text":"Office Visit"}],"subject":{"reference":"Patient/erXuFYUfucBZaryVksYEcMg3","display":"Lopez, Camila Maria"},"participant":[{"individual":{"reference":"Practitioner/eM5CWtq15N0WJeuCet5bJlQ3","type":"Practitioner","display":"Physician"}}],"period":{"start":"2019-05-28","end":"2019-05-28"},"location":[{"location":{"reference":"Location/e4W4rmGe9QzuGm2Dy4NBqVc0KDe6yGld6HW95UuN-Qd03","display":"EMC Family Medicine"}}]} +{"resourceType":"Encounter","id":"eEyT8ihlF3x9EsGhmSjNsaA3","identifier":[{"use":"usual","system":"urn:oid:1.2.840.114350.1.13.0.1.7.3.698084.8","value":"27547"}],"status":"in-progress","class":{"system":"urn:oid:1.2.840.114350.1.72.1.7.7.10.696784.13260","code":"13","display":"Support OP Encounter"},"type":[{"coding":[{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.10.698084.30","code":"101","display":"Office Visit"}],"text":"Office Visit"}],"subject":{"reference":"Patient/erXuFYUfucBZaryVksYEcMg3","display":"Lopez, Camila Maria"},"period":{"start":"2019-05-24","end":"2019-05-24"},"location":[{"location":{"reference":"Location/e4W4rmGe9QzuGm2Dy4NBqVc0KDe6yGld6HW95UuN-Qd03","display":"EMC Family Medicine"}}]} +{"resourceType":"Goal","id":"e3hwZL.Ra85rtejrMitqu8w3","extension":[{"valueString":"NURSING","url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-expressedby"},{"valueString":"INTERDISCIPLINARY","url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-expressedby"},{"valueString":"RESPIRATORY THERAPY","url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-expressedby"},{"valueString":"SOCIAL WORK","url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-expressedby"}],"lifecycleStatus":"active","category":[{"coding":[{"system":"http://open.epic.com/FHIR/StructureDefinition/goal-category","code":"inpatient-care-plan-goal","display":"Inpatient Care Plan Goal"}],"text":"Inpatient Care Plan Goal"}],"description":{"text":"Verbalizes/displays adequate comfort level or baseline comfort level"},"subject":{"reference":"Patient/erXuFYUfucBZaryVksYEcMg3","display":"Lopez, Camila Maria"},"startDate":"2023-06-02","addresses":[{"reference":"Condition/e-oL436hofxVBDhMRXD9mrg3","display":"Pain - Adult"}]} +{"resourceType":"Goal","id":"eQkMeW6kwaLlhQWHCjq6qiQ3","extension":[{"valueString":"NURSING","url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-expressedby"},{"valueString":"INTERDISCIPLINARY","url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-expressedby"},{"valueString":"RESPIRATORY THERAPY","url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-expressedby"},{"valueString":"SOCIAL WORK","url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-expressedby"}],"lifecycleStatus":"active","category":[{"coding":[{"system":"http://open.epic.com/FHIR/StructureDefinition/goal-category","code":"inpatient-care-plan-goal","display":"Inpatient Care Plan Goal"}],"text":"Inpatient Care Plan Goal"}],"description":{"text":"Absence of infection during hospitalization"},"subject":{"reference":"Patient/erXuFYUfucBZaryVksYEcMg3","display":"Lopez, Camila Maria"},"startDate":"2023-06-02","addresses":[{"reference":"Condition/enxs1cxkwzPxvOqZcUj4IVQ3","display":"Infection - Adult"}]} +{"resourceType":"Goal","id":"ebkef6fRYMQQ2wIkoURNGAA3","extension":[{"valueString":"NURSING","url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-expressedby"},{"valueString":"INTERDISCIPLINARY","url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-expressedby"},{"valueString":"RESPIRATORY THERAPY","url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-expressedby"},{"valueString":"SOCIAL WORK","url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-expressedby"}],"lifecycleStatus":"active","category":[{"coding":[{"system":"http://open.epic.com/FHIR/StructureDefinition/goal-category","code":"inpatient-care-plan-goal","display":"Inpatient Care Plan Goal"}],"text":"Inpatient Care Plan Goal"}],"description":{"text":"Absence of fever/infection during anticipated neutropenic period"},"subject":{"reference":"Patient/erXuFYUfucBZaryVksYEcMg3","display":"Lopez, Camila Maria"},"startDate":"2023-06-02","addresses":[{"reference":"Condition/enxs1cxkwzPxvOqZcUj4IVQ3","display":"Infection - Adult"}]} +{"resourceType":"Goal","id":"ed-oONVmWCMix2WPAWmM8cg3","extension":[{"valueString":"NURSING","url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-expressedby"},{"valueString":"INTERDISCIPLINARY","url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-expressedby"},{"valueString":"RESPIRATORY THERAPY","url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-expressedby"},{"valueString":"SOCIAL WORK","url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-expressedby"}],"lifecycleStatus":"active","category":[{"coding":[{"system":"http://open.epic.com/FHIR/StructureDefinition/goal-category","code":"inpatient-care-plan-goal","display":"Inpatient Care Plan Goal"}],"text":"Inpatient Care Plan Goal"}],"description":{"text":"Free from fall injury"},"subject":{"reference":"Patient/erXuFYUfucBZaryVksYEcMg3","display":"Lopez, Camila Maria"},"startDate":"2023-06-02","addresses":[{"reference":"Condition/e1tKlHlRqm9EXhpS9iLx4xA3","display":"Safety Adult - Fall"}]} +{"resourceType":"Goal","id":"ee47OnbFatGYF-t1YFS8qvA3","extension":[{"valueString":"NURSING","url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-expressedby"},{"valueString":"INTERDISCIPLINARY","url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-expressedby"},{"valueString":"RESPIRATORY THERAPY","url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-expressedby"},{"valueString":"SOCIAL WORK","url":"http://open.epic.com/FHIR/StructureDefinition/extension/multiple-expressedby"}],"lifecycleStatus":"active","category":[{"coding":[{"system":"http://open.epic.com/FHIR/StructureDefinition/goal-category","code":"inpatient-care-plan-goal","display":"Inpatient Care Plan Goal"}],"text":"Inpatient Care Plan Goal"}],"description":{"text":"Discharge to home or other facility with appropriate resources"},"subject":{"reference":"Patient/erXuFYUfucBZaryVksYEcMg3","display":"Lopez, Camila Maria"},"startDate":"2023-06-02","addresses":[{"reference":"Condition/e7.CXqjHOcMA8Gxl2sOOs3w3","display":"Discharge Planning"}]} +{"resourceType":"Goal","id":"eGv1hgf8wfgd-eV1xuhoW1w3","lifecycleStatus":"active","category":[{"coding":[{"system":"http://open.epic.com/FHIR/StructureDefinition/goal-category","code":"inpatient-care-plan-goal","display":"Inpatient Care Plan Goal"}],"text":"Inpatient Care Plan Goal"}],"description":{"text":"Patient's chronic conditions and co-morbidity symptoms are monitored and maintained or improved"},"subject":{"reference":"Patient/erXuFYUfucBZaryVksYEcMg3","display":"Lopez, Camila Maria"},"startDate":"2023-06-02","expressedBy":{"display":"INTERDISCIPLINARY"},"addresses":[{"reference":"Condition/eshaiIZ7f0Z.ptm.6wNwjrA3","display":"Chronic Conditions and Co-morbidities"}]} +{"resourceType":"Immunization","id":"eEAE--XrkYnFv04FWNZG8Aw3","identifier":[{"use":"usual","system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.768076","value":"29421"}],"status":"completed","vaccineCode":{"coding":[{"system":"http://hl7.org/fhir/sid/cvx","code":"115"},{"system":"http://hl7.org/fhir/sid/ndc","code":"58160-842-11"}],"text":"Tdap"},"patient":{"reference":"Patient/erXuFYUfucBZaryVksYEcMg3","display":"Lopez, Camila Maria"},"encounter":{"reference":"Encounter/exfbAtPCSLnf8s.193aMUnQ3","identifier":{"use":"usual","system":"urn:oid:1.2.840.114350.1.13.0.1.7.3.698084.8","value":"29539"},"display":"Office Visit"},"occurrenceDateTime":"2023-05-21","primarySource":true,"manufacturer":{"display":"Sanofi Pasteur"},"lotNumber":"1","site":{"coding":[{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.10.768076.4040","code":"7","display":"Left deltoid"}],"text":"Left deltoid"},"route":{"coding":[{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.10.768076.4030","code":"2","display":"Intramuscular"}],"text":"Intramuscular"},"doseQuantity":{"value":0.5,"unit":"mL","system":"urn:oid:1.2.840.114350.1.13.0.1.7.10.768076.4019","code":"1"},"performer":[{"function":{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/v2-0443","code":"AP","display":"Administering Provider"}],"text":"Administering Provider"},"actor":{"reference":"Practitioner/eM5CWtq15N0WJeuCet5bJlQ3","type":"Practitioner","display":"Physician"}}]} +{"id":"e4W4rmGe9QzuGm2Dy4NBqVc0KDe6yGld6HW95UuN-Qd03","mode":"instance","name":"EMC Family Medicine","resourceType":"Location"} +{"id":"e6.GHPEJ3Jrk18e14wi2AJ5vFRqvLa0ZB6qH40N4UgB03","mode":"instance","name":"EMH X-Ray Imaging","resourceType":"Location"} +{"id":"eQSOrLdbVrMRc68KBcTBG4A3","mode":"instance","name":"EHS Service Area","resourceType":"Location"} +{"id":"el.Nc4rfzXa7Ml9v6gin1Pw3","mode":"instance","name":"EHS Hospital","resourceType":"Location"} +{"id":"exzJSfs-2YYqMPilpdzkcdMVzw6TB9WJfeqFRVe.cpSo3","mode":"instance","name":"EMC Cardiology Procedures","resourceType":"Location"} +{"id":"efR3SIdpRKF9BFBM5qakt9F5X1mWxjiAGu2hNTKbqOdI3","mode":"instance","name":"EMH Operating Room","resourceType":"Location"} +{"code":{"coding":[{"code":"100899","system":"urn:oid:2.16.840.1.113883.6.253"},{"code":"25990002150316","system":"urn:oid:2.16.840.1.113883.6.68"},{"code":"49431","system":"urn:oid:2.16.840.1.113883.6.162"},{"code":"4124","system":"http://www.nlm.nih.gov/research/umls/rxnorm"},{"code":"11636","system":"http://www.nlm.nih.gov/research/umls/rxnorm"},{"code":"630734","system":"http://www.nlm.nih.gov/research/umls/rxnorm"},{"code":"748794","system":"http://www.nlm.nih.gov/research/umls/rxnorm"},{"code":"748798","system":"http://www.nlm.nih.gov/research/umls/rxnorm"},{"code":"840781","system":"http://www.nlm.nih.gov/research/umls/rxnorm"}],"text":"drospirenone-ethinyl estradiol 3-0.02 MG per tablet"},"form":{"coding":[{"code":"TABS","display":"tablet","system":"urn:oid:1.2.840.114350.1.13.0.1.7.4.698288.310"}],"text":"tablet"},"id":"ej-bgums0x4N6E0.QqIjJb3kGhOQBVK3lIYjcil9mb9j-ukNrz6P2y90AiDm3R20Y3","identifier":[{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.698288","use":"usual","value":"70784"}],"ingredient":[{"itemCodeableConcept":{"coding":[{"code":"100899","system":"urn:oid:2.16.840.1.113883.6.253"},{"code":"25990002150316","system":"urn:oid:2.16.840.1.113883.6.68"},{"code":"49431","system":"urn:oid:2.16.840.1.113883.6.162"},{"code":"4124","system":"http://www.nlm.nih.gov/research/umls/rxnorm"},{"code":"11636","system":"http://www.nlm.nih.gov/research/umls/rxnorm"},{"code":"630734","system":"http://www.nlm.nih.gov/research/umls/rxnorm"},{"code":"748794","system":"http://www.nlm.nih.gov/research/umls/rxnorm"},{"code":"748798","system":"http://www.nlm.nih.gov/research/umls/rxnorm"},{"code":"840781","system":"http://www.nlm.nih.gov/research/umls/rxnorm"}],"text":"drospirenone-ethinyl estradiol 3-0.02 MG per tablet"}}],"resourceType":"Medication"} +{"resourceType":"MedicationRequest","id":"ePDJ.zsf3Jfg2.MKkAMgW9EcIbsaiB.y-OTrPS5v2h8Q3","identifier":[{"use":"usual","system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.798268","value":"1066899"}],"status":"active","intent":"order","category":[{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/medicationrequest-category","code":"community","display":"Community"}],"text":"Community"}],"medicationReference":{"reference":"Medication/ej-bgums0x4N6E0.QqIjJb3kGhOQBVK3lIYjcil9mb9j-ukNrz6P2y90AiDm3R20Y3","display":"drospirenone-ethinyl estradiol 3-0.02 MG per tablet"},"subject":{"reference":"Patient/erXuFYUfucBZaryVksYEcMg3","display":"Lopez, Camila Maria"},"encounter":{"reference":"Encounter/elMz2mwjsRvKnZiR.0ceTUg3","identifier":{"use":"usual","system":"urn:oid:1.2.840.114350.1.13.0.1.7.3.698084.8","value":"27558"},"display":"Office Visit"},"authoredOn":"2019-05-28","requester":{"reference":"Practitioner/eM5CWtq15N0WJeuCet5bJlQ3","type":"Practitioner","display":"Physician"},"recorder":{"reference":"Practitioner/eM5CWtq15N0WJeuCet5bJlQ3","type":"Practitioner","display":"Physician"},"reasonCode":[{"coding":[{"system":"http://snomed.info/sct","code":"69878008","display":"Polycystic ovaries (disorder)"},{"system":"http://hl7.org/fhir/sid/icd-9-cm/diagnosis","code":"256.4","display":"Polycystic ovaries"},{"system":"http://hl7.org/fhir/sid/icd-10-cm","code":"E28.2","display":"Polycystic ovaries"}],"text":"Polycystic ovaries"}],"courseOfTherapyType":{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/medicationrequest-course-of-therapy","code":"continuous","display":"Continuous long term therapy"}],"text":"Continuous long term therapy"},"dosageInstruction":[{"text":"Take 1 tablet by mouth 1 (one) time each day., Starting Tue 5/28/2019, Until Wed 5/27/2020, Normal","patientInstruction":"Take 1 tablet by mouth 1 (one) time each day.","timing":{"repeat":{"boundsPeriod":{"start":"2019-05-28"},"count":365,"timeOfDay":["09:00:00"]},"code":{"text":"1 (one) time each day"}},"asNeededBoolean":false,"route":{"coding":[{"system":"http://snomed.info/sct","code":"260548002","display":"Oral (qualifier value)"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.4.798268.7025","code":"15","display":"Oral"}],"text":"Oral"},"method":{"coding":[{"system":"http://snomed.info/sct","code":"419652001","display":"Take"}],"text":"Take"},"doseAndRate":[{"type":{"coding":[{"system":"http://epic.com/CodeSystem/dose-rate-type","code":"calculated","display":"calculated"}],"text":"calculated"},"doseQuantity":{"value":1,"unit":"tablet","system":"http://unitsofmeasure.org","code":"{tbl}"}},{"type":{"coding":[{"system":"http://epic.com/CodeSystem/dose-rate-type","code":"admin-amount","display":"admin-amount"}],"text":"admin-amount"},"doseQuantity":{"value":1,"unit":"tablet","system":"http://unitsofmeasure.org","code":"{tbl}"}},{"type":{"coding":[{"system":"http://epic.com/CodeSystem/dose-rate-type","code":"ordered","display":"ordered"}],"text":"ordered"},"doseQuantity":{"value":1,"unit":"tablet","system":"http://unitsofmeasure.org","code":"{tbl}"}}]}],"dispenseRequest":{"validityPeriod":{"start":"2019-05-28"},"numberOfRepeatsAllowed":12,"quantity":{"value":28,"unit":"tablet"},"expectedSupplyDuration":{"value":28,"unit":"Day","system":"http://unitsofmeasure.org","code":"d"}}} +{"basedOn":[{"display":"XR CHEST 2 VIEWS","reference":"ServiceRequest/ePsXywWuaF47D-FPsxcnz3BOk1-JNF41RJJEMQu.2TCA3"}],"category":[{"coding":[{"code":"imaging","display":"Imaging","system":"http://terminology.hl7.org/CodeSystem/observation-category"}],"text":"Imaging"},{"coding":[{"code":"Imaging","display":"Imaging","system":"urn:oid:1.2.840.114350.1.13.0.1.7.10.798268.30"}],"text":"Imaging"}],"code":{"text":"Narrative"},"effectiveDateTime":"2023-06-02T20:43:46Z","encounter":{"display":"Hospital Outpatient Visit","identifier":{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.3.698084.8","use":"usual","value":"29541"},"reference":"Encounter/eoIRZgvu9RhrwOzDlZkRbSg3"},"id":"eWQ91GjryHtrlYhSNxK1L7mI-fgFwPAedom.YQ4JDeQk3","performer":[{"display":"Physician","reference":"Practitioner/eM5CWtq15N0WJeuCet5bJlQ3"}],"resourceType":"Observation","status":"final","subject":{"display":"Lopez, Camila Maria","reference":"Patient/erXuFYUfucBZaryVksYEcMg3"},"valueString":"Patient presents with history of chest pain. No rib fractures or lesions \r\nfound\r\n\r\n"} +{"basedOn":[{"display":"TRANSTHORACIC ECHO (TTE) COMPLETE","reference":"ServiceRequest/e6t1HtRj0Za8M9Y0u5nU2tu3idJ7P66B2HzlMtddZ6Wc3"}],"category":[{"coding":[{"code":"imaging","display":"Imaging","system":"http://terminology.hl7.org/CodeSystem/observation-category"}],"text":"Imaging"},{"coding":[{"code":"Echo","display":"Echocardiography","system":"urn:oid:1.2.840.114350.1.13.0.1.7.10.798268.30"}],"text":"Echocardiography"}],"code":{"text":"Narrative"},"effectiveDateTime":"2023-06-02T20:50:25Z","encounter":{"display":"Hospital Outpatient Visit","identifier":{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.3.698084.8","use":"usual","value":"29542"},"reference":"Encounter/ej567ARSFdaF4ooZVunIlIg3"},"id":"epvZIWrCStn-QxWdd6yDL2rsODx.M3VAMdHGGYcFbGkQ3","performer":[{"display":"Physician","reference":"Practitioner/eM5CWtq15N0WJeuCet5bJlQ3"}],"resourceType":"Observation","status":"final","subject":{"display":"Lopez, Camila Maria","reference":"Patient/erXuFYUfucBZaryVksYEcMg3"},"valueString":"· Left ventricle ejection fraction is normal.\r\n· Septal wall has abnormal motion consistent with post-operative status.\r\n \r\nHere is the interpretation summary text.\r\n\r\n\r\nLeft Ventricle\r\nEjection fraction is normal. Cavity is normal. End-diastolic volume appears mildly increased. Normal wall thickness observed. Mid-cavity obstruction is present. Shape is normal. Abnormal septal motion consistent with post-operative state. Normal fractional shortening. Normal left ventricle diastolic function. The findings are consistent with dilated cardiomyopathy."} +{"basedOn":[{"display":"XR CHEST 2 VIEWS","reference":"ServiceRequest/ePsXywWuaF47D-FPsxcnz3BOk1-JNF41RJJEMQu.2TCA3"}],"category":[{"coding":[{"code":"imaging","display":"Imaging","system":"http://terminology.hl7.org/CodeSystem/observation-category"}],"text":"Imaging"},{"coding":[{"code":"Imaging","display":"Imaging","system":"urn:oid:1.2.840.114350.1.13.0.1.7.10.798268.30"}],"text":"Imaging"}],"code":{"text":"Impression"},"effectiveDateTime":"2023-06-02T20:43:46Z","encounter":{"display":"Hospital Outpatient Visit","identifier":{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.3.698084.8","use":"usual","value":"29541"},"reference":"Encounter/eoIRZgvu9RhrwOzDlZkRbSg3"},"id":"eWQ91GjryHtrlYhSNxK1L7hOQbiABlro0a6oo2bIh68I3","performer":[{"display":"Physician","reference":"Practitioner/eM5CWtq15N0WJeuCet5bJlQ3"}],"resourceType":"Observation","status":"final","subject":{"display":"Lopez, Camila Maria","reference":"Patient/erXuFYUfucBZaryVksYEcMg3"},"valueString":" \r\nNo findings. Refer to cardiology."} +{"basedOn":[{"display":"HEMOGLOBIN A1C","reference":"ServiceRequest/egf4KkhXmgeVWImXEEYH.CEE1ZgJG5SQy2vBX1HgvBCs3"}],"category":[{"coding":[{"code":"laboratory","display":"Laboratory","system":"http://terminology.hl7.org/CodeSystem/observation-category"}],"text":"Laboratory"},{"coding":[{"code":"Lab","display":"Lab","system":"urn:oid:1.2.840.114350.1.13.0.1.7.10.798268.30"}],"text":"Lab"}],"code":{"coding":[{"code":"4548-4","display":"Hemoglobin A1c/Hemoglobin.total in Blood","system":"http://loinc.org"},{"code":"1558024","display":"Hemoglobin A1C","system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.768282"}],"text":"Hemoglobin A1C"},"effectiveDateTime":"2019-05-28T14:22:00Z","encounter":{"display":"Office Visit","identifier":{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.3.698084.8","use":"usual","value":"27558"},"reference":"Encounter/elMz2mwjsRvKnZiR.0ceTUg3"},"id":"eyPMWgv2u2RUfsV4p1lLKuUtqyPs2-QNi2zKvbTsFYtRByc6B.cSi1iVU5V2HOpX23","issued":"2019-05-28T14:22:41Z","resourceType":"Observation","specimen":{"display":"Specimen","reference":"Specimen/e.n21kE9PMQ94vOo1lkT2XkN1av86guPxYsFU20qTQ1M3"},"status":"final","subject":{"display":"Lopez, Camila Maria","reference":"Patient/erXuFYUfucBZaryVksYEcMg3"},"valueQuantity":{"value":5.1}} +{"active":true,"alias":["CPACS"],"id":"eVUDU8oWh9.KM7oI8Mu9jlqn1C3d5ozeHAXDHuaPYsvU3","name":"CPACS","resourceType":"Organization"} +{"active":true,"alias":["IMG"],"id":"etOhDRFmHqAJ3CBmvHCeF9VYgSiH5bYCNkDSOho2TXb43","name":"IMAGING","resourceType":"Organization"} +{"active":true,"address":[{"city":"VERONA","line":["123 Anywhere St."],"postalCode":"53593","state":"Wisconsin"}],"id":"enRyWnSP963FYDpoks4NHOA3","identifier":[{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.5.737384.61","type":{"text":"EPIC"},"use":"usual","value":"1627363736"}],"name":"EHS Service Area","resourceType":"Organization"} +{"id":"erXuFYUfucBZaryVksYEcMg3","extension":[{"url":"http://open.epic.com/FHIR/StructureDefinition/extension/legal-sex","valueCodeableConcept":{"coding":[{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.10.698084.130.657370.19999000","code":"female","display":"female"}]}},{"extension":[{"url":"ombCategory","valueCoding":{"system":"urn:oid:2.16.840.1.113883.6.238","code":"2131-1","display":"Other Race"}},{"url":"text","valueString":"Other"}],"url":"http://hl7.org/fhir/us/core/StructureDefinition/us-core-race"},{"extension":[{"url":"text","valueString":"Unknown"}],"url":"http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity"}],"identifier":[{"use":"usual","type":{"text":"EPIC"},"system":"urn:oid:1.2.840.114350.1.13.0.1.7.5.737384.0","value":"E4007"},{"use":"usual","type":{"text":"EXTERNAL"},"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.698084","value":"Z6129"},{"use":"usual","type":{"text":"FHIR"},"system":"http://open.epic.com/FHIR/StructureDefinition/patient-dstu2-fhir-id","value":"TnOZ.elPXC6zcBNFMcFA7A5KZbYxo2.4T-LylRk4GoW4B"},{"use":"usual","type":{"text":"FHIR STU3"},"system":"http://open.epic.com/FHIR/StructureDefinition/patient-fhir-id","value":"erXuFYUfucBZaryVksYEcMg3"},{"use":"usual","type":{"text":"INTERNAL"},"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.698084","value":" Z6129"},{"use":"usual","type":{"text":"EPI"},"system":"urn:oid:1.2.840.114350.1.13.0.1.7.5.737384.14","value":"203713"},{"use":"usual","type":{"text":"MYCHARTLOGIN"},"system":"urn:oid:1.2.840.114350.1.13.0.1.7.3.878082.110","value":"FHIRCAMILA"},{"use":"usual","type":{"text":"WPRINTERNAL"},"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.878082","value":"736"}],"active":true,"name":[{"use":"official","text":"Camila Maria Lopez","family":"Lopez","given":["Camila","Maria"]},{"use":"usual","text":"Camila Maria Lopez","family":"Lopez","given":["Camila","Maria"]}],"telecom":[{"system":"phone","value":"469-555-5555","use":"home"},{"system":"phone","value":"469-888-8888","use":"work"},{"system":"email","value":"knixontestemail@epic.com","rank":1}],"gender":"female","birthDate":"1987-09-12","deceasedBoolean":false,"address":[{"use":"home","line":["3268 West Johnson St.","Apt 117"],"city":"GARLAND","district":"DALLAS","state":"TX","postalCode":"75043","country":"US","period":{"start":"2019-05-24"}},{"use":"old","line":["3268 West Johnson St.","Apt 117"],"city":"GARLAND","district":"DALLAS","state":"TX","postalCode":"75043","country":"US"}],"maritalStatus":{"text":"Married"},"communication":[{"language":{"coding":[{"system":"urn:ietf:bcp:47","code":"en","display":"English"}],"text":"English"},"preferred":true}],"generalPractitioner":[{"reference":"Practitioner/eM5CWtq15N0WJeuCet5bJlQ3","type":"Practitioner","display":"Physician"}],"managingOrganization":{"reference":"Organization/enRyWnSP963FYDpoks4NHOA3","display":"EHS Service Area"},"resourceType":"Patient"} +{"active":true,"id":"eHP1iZcoohQAKIcKyP6CDvA3","identifier":[{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.697780","type":{"text":"INTERNAL"},"use":"usual","value":" 5157"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.697780","type":{"text":"EXTERNAL"},"use":"usual","value":"5157"}],"name":[{"family":"Z","given":["Robert"],"text":"Robert Z","use":"usual"}],"resourceType":"Practitioner"} +{"active":true,"gender":"male","id":"eM5CWtq15N0WJeuCet5bJlQ3","identifier":[{"system":"http://hl7.org/fhir/sid/us-npi","type":{"text":"NPI"},"use":"usual","value":"1627363736"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.697780","type":{"text":"INTERNAL"},"use":"usual","value":" FAMMD"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.697780","type":{"text":"EXTERNAL"},"use":"usual","value":"FAMMD"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.5.737384.6","type":{"text":"PROVID"},"use":"usual","value":"1000"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.5.737384.7","type":{"text":"EPIC"},"use":"usual","value":"207Q00000X"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.5.737384.60","type":{"text":"NPI"},"use":"usual","value":"1627363736"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.5.737384.63","type":{"text":"Epic"},"use":"usual","value":"6011"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.836982","type":{"text":"INTERNAL"},"use":"usual","value":" E1000"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.836982","type":{"text":"EXTERNAL"},"use":"usual","value":"E1000"}],"name":[{"_family":{"extension":[{"url":"http://hl7.org/fhir/StructureDefinition/data-absent-reason","valueCode":"masked"}]},"given":["Physician"],"text":"Physician","use":"usual"}],"photo":[{"url":"Binary/esQeLhUcHfUSQnyrAJ7GV7A3"}],"resourceType":"Practitioner"} +{"active":true,"id":"elpRiy0AYgjhdjAhTBJ3Aiw3","identifier":[{"system":"http://hl7.org/fhir/sid/us-npi","type":{"text":"NPI"},"use":"usual","value":"1400103994"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.5.737384.6","type":{"text":"PROVID"},"use":"usual","value":"400103"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.5.737384.7","type":{"text":"EPIC"},"use":"usual","value":"207Q00000X"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.5.737384.60","type":{"text":"NPI"},"use":"usual","value":"1400103994"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.5.737384.63","type":{"text":"Epic"},"use":"usual","value":"TEMP400103"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.836982","type":{"text":"INTERNAL"},"use":"usual","value":" E400103"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.836982","type":{"text":"EXTERNAL"},"use":"usual","value":"E400103"}],"name":[{"_family":{"extension":[{"url":"http://hl7.org/fhir/StructureDefinition/data-absent-reason","valueCode":"masked"}]},"given":["Np"],"text":"Np","use":"usual"}],"resourceType":"Practitioner"} +{"active":true,"id":"e2qocqJm-DdjHLS0Not4qjA3","identifier":[{"system":"http://hl7.org/fhir/sid/us-npi","type":{"text":"NPI"},"use":"usual","value":"1101299992"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.5.737384.7","type":{"text":"EPIC"},"use":"usual","value":"208D00000X"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.5.737384.60","type":{"text":"NPI"},"use":"usual","value":"1101299992"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.5.737384.63","type":{"text":"Epic"},"use":"usual","value":"830"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.836982","type":{"text":"INTERNAL"},"use":"usual","value":" E1012"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.836982","type":{"text":"EXTERNAL"},"use":"usual","value":"E1012"}],"name":[{"_family":{"extension":[{"url":"http://hl7.org/fhir/StructureDefinition/data-absent-reason","valueCode":"masked"}]},"given":["Historical"],"text":"Historical","use":"usual"}],"resourceType":"Practitioner"} +{"active":true,"gender":"male","id":"eUXiD4IyBLJFoR2VHOjfTdg3","identifier":[{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.697780","type":{"text":"INTERNAL"},"use":"usual","value":" FAMMD"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.697780","type":{"text":"EXTERNAL"},"use":"usual","value":"FAMMD"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.5.737384.6","type":{"text":"PROVID"},"use":"usual","value":"1000"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.5.737384.7","type":{"text":"EPIC"},"use":"usual","value":"207Q00000X"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.5.737384.60","type":{"text":"NPI"},"use":"usual","value":"1627363736"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.5.737384.63","type":{"text":"Epic"},"use":"usual","value":"6011"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.836982","type":{"text":"INTERNAL"},"use":"usual","value":" E1000"},{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.836982","type":{"text":"EXTERNAL"},"use":"usual","value":"E1000"}],"name":[{"_family":{"extension":[{"url":"http://hl7.org/fhir/StructureDefinition/data-absent-reason","valueCode":"masked"}]},"given":["Physician"],"text":"Physician","use":"usual"}],"resourceType":"Practitioner"} +{"resourceType":"Procedure","id":"e0ZpcfJHKvPE0nQfie.r1utQLnHC473E7POoGnZIh7yj3wWsggKlPmbROlo9Q5vi-3","identifier":[{"use":"usual","type":{"text":"ORD"},"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.798268","value":"1066915"},{"use":"usual","type":{"text":"EAP"},"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.696580","value":"104443"},{"use":"usual","type":{"text":"OPE"},"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.798069","value":"88"}],"status":"completed","category":{"coding":[{"system":"http://snomed.info/sct","code":"103693007","display":"Diagnostic procedure"}],"text":"Ordered Procedures"},"code":{"coding":[{"system":"http://www.ama-assn.org/go/cpt","code":"93306","display":"HC TRANSTHORACIC ECHO"}],"text":"TRANSTHORACIC ECHO (TTE) COMPLETE"},"subject":{"reference":"Patient/erXuFYUfucBZaryVksYEcMg3","display":"Lopez, Camila Maria"},"encounter":{"reference":"Encounter/ej567ARSFdaF4ooZVunIlIg3","identifier":{"use":"usual","system":"urn:oid:1.2.840.114350.1.13.0.1.7.3.698084.8","value":"29542"},"display":"Hospital Outpatient Visit"},"performedDateTime":"2023-06-02T20:50:25Z","asserter":{"reference":"Practitioner/elpRiy0AYgjhdjAhTBJ3Aiw3","type":"Practitioner","display":"Np"},"performer":[{"actor":{"reference":"Practitioner/eM5CWtq15N0WJeuCet5bJlQ3","type":"Practitioner","display":"Physician"},"onBehalfOf":{"reference":"Organization/eVUDU8oWh9.KM7oI8Mu9jlqn1C3d5ozeHAXDHuaPYsvU3","type":"Organization","display":"CPACS"}}],"reasonCode":[{"coding":[{"system":"http://hl7.org/fhir/sid/icd-9-cm/diagnosis","code":"786.50","display":"Ischemic chest pain (CMS/HCC)"}],"text":"Ischemic chest pain"}],"report":[{"reference":"DiagnosticReport/ejRFFAyoWd-DvE0lHi4UEUVA9qTH9PxfCLhEetlq04Ck3","type":"DiagnosticReport","display":"TRANSTHORACIC ECHO (TTE) COMPLETE"}]} +{"resourceType":"Procedure","id":"ea8l39YGDvGqR.Rw4MVH4p6am4lpdDPM2QFz0gpZXtbnV8a5ab-hpVbV1IBMzJ7D53","identifier":[{"use":"usual","type":{"text":"ORL"},"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.798276","value":"1505"},{"use":"usual","type":{"text":"EAP"},"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.696580","value":"14493"},{"use":"usual","type":{"text":"OPE"},"system":"urn:oid:1.2.840.114350.1.13.0.1.7.2.798069","value":"90"}],"status":"completed","category":{"coding":[{"system":"http://snomed.info/sct","code":"387713003","display":"Surgical procedure"}],"text":"Surgical Procedures"},"code":{"coding":[{"system":"http://www.ama-assn.org/go/cpt","code":"44950","display":"PR APPENDECTOMY"}],"text":"Removal of appendix (APPENDECTOMY)"},"subject":{"reference":"Patient/erXuFYUfucBZaryVksYEcMg3","display":"Lopez, Camila Maria"},"encounter":{"reference":"Encounter/eGmO0h.1.UQQrExl4bfM7OQ3","identifier":{"use":"usual","system":"urn:oid:1.2.840.114350.1.13.0.1.7.3.698084.8","value":"29545"},"display":"Surgery"},"performedPeriod":{"start":"2023-06-06T13:56:00Z","end":"2023-06-06T14:56:00Z"},"recorder":{"reference":"Practitioner/eHP1iZcoohQAKIcKyP6CDvA3","type":"Practitioner","display":"Robert Z"},"location":{"reference":"Location/el.Nc4rfzXa7Ml9v6gin1Pw3","display":"EHS Hospital"},"bodySite":[{"extension":[{"valueCodeableConcept":{"coding":[{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.4.798276.2010","code":"4","display":"N/A"}],"text":"N/A"},"url":"http://nictiz.nl/fhir/StructureDefinition/BodySite-Qualifier"}],"coding":[{"system":"urn:oid:1.2.840.114350.1.13.0.1.7.4.798276.2015","code":"10","display":"Abdomen"}],"text":"Abdomen"}]} diff --git a/backend/pkg/models/resource_graph_options.go b/backend/pkg/models/resource_graph_options.go index 24a7dd8a..5b2fd75e 100644 --- a/backend/pkg/models/resource_graph_options.go +++ b/backend/pkg/models/resource_graph_options.go @@ -1,5 +1,5 @@ package models type ResourceGraphOptions struct { - Page int + ResourcesIds []OriginBase `json:"resource_ids"` } diff --git a/backend/pkg/web/handler/resource_fhir.go b/backend/pkg/web/handler/resource_fhir.go index 71bc1293..534220db 100644 --- a/backend/pkg/web/handler/resource_fhir.go +++ b/backend/pkg/web/handler/resource_fhir.go @@ -76,7 +76,7 @@ func ListResourceFhir(c *gin.Context) { c.JSON(http.StatusOK, gin.H{"success": true, "data": wrappedResourceModels}) } -//this endpoint retrieves a specific resource by its ID +// this endpoint retrieves a specific resource by its ID func GetResourceFhir(c *gin.Context) { logger := c.MustGet(pkg.ContextKeyTypeLogger).(*logrus.Entry) databaseRepo := c.MustGet(pkg.ContextKeyTypeDatabase).(database.DatabaseRepository) @@ -129,18 +129,20 @@ func GetResourceFhirGraph(c *gin.Context) { graphType := strings.Trim(c.Param("graphType"), "/") - graphOptions := models.ResourceGraphOptions{} - if len(c.Query("page")) > 0 { - pageNumb, err := strconv.Atoi(c.Query("page")) - if err != nil { - logger.Errorln("An error occurred while calculating page number", err) - c.JSON(http.StatusInternalServerError, gin.H{"success": false}) - return - } - graphOptions.Page = pageNumb + var graphOptions models.ResourceGraphOptions + if err := c.ShouldBindJSON(&graphOptions); err != nil { + logger.Errorln("An error occurred while parsing resource graph query options", err) + c.JSON(http.StatusBadRequest, gin.H{"success": false}) + return } - resourceListDictionary, resourceListMetadata, err := databaseRepo.GetFlattenedResourceGraph(c, pkg.ResourceGraphType(graphType), graphOptions) + if len(graphOptions.ResourcesIds) == 0 { + logger.Errorln("No resource ids specified") + c.JSON(http.StatusBadRequest, gin.H{"success": false}) + return + } + + resourceListDictionary, err := databaseRepo.GetFlattenedResourceGraph(c, pkg.ResourceGraphType(graphType), graphOptions) if err != nil { logger.Errorln("An error occurred while retrieving list of resources", err) c.JSON(http.StatusInternalServerError, gin.H{"success": false}) @@ -148,7 +150,6 @@ func GetResourceFhirGraph(c *gin.Context) { } c.JSON(http.StatusOK, gin.H{"success": true, "data": map[string]interface{}{ - "results": resourceListDictionary, - "metadata": resourceListMetadata, + "results": resourceListDictionary, }}) } diff --git a/backend/pkg/web/server.go b/backend/pkg/web/server.go index 9a032cd5..a8171b24 100644 --- a/backend/pkg/web/server.go +++ b/backend/pkg/web/server.go @@ -72,7 +72,7 @@ func (ae *AppEngine) Setup() (*gin.RouterGroup, *gin.Engine) { secure.POST("/source/:sourceId/sync", handler.SourceSync) secure.GET("/source/:sourceId/summary", handler.GetSourceSummary) secure.GET("/resource/fhir", handler.ListResourceFhir) - secure.GET("/resource/graph/:graphType", handler.GetResourceFhirGraph) + secure.POST("/resource/graph/:graphType", handler.GetResourceFhirGraph) secure.GET("/resource/fhir/:sourceId/:resourceId", handler.GetResourceFhir) secure.POST("/resource/composition", handler.CreateResourceComposition) diff --git a/frontend/src/app/components/fhir/fhir-resource/fhir-resource.component.ts b/frontend/src/app/components/fhir/fhir-resource/fhir-resource.component.ts index d0951eaf..f87df80a 100644 --- a/frontend/src/app/components/fhir/fhir-resource/fhir-resource.component.ts +++ b/frontend/src/app/components/fhir/fhir-resource/fhir-resource.component.ts @@ -25,6 +25,10 @@ import {DiagnosticReportComponent} from '../resources/diagnostic-report/diagnost import {PractitionerComponent} from '../resources/practitioner/practitioner.component'; import {DocumentReferenceComponent} from '../resources/document-reference/document-reference.component'; import {MediaComponent} from '../resources/media/media.component'; +import {LocationComponent} from '../resources/location/location.component'; +import {OrganizationComponent} from '../resources/organization/organization.component'; +import {ObservationComponent} from '../resources/observation/observation.component'; + @Component({ selector: 'fhir-resource', @@ -119,6 +123,9 @@ export class FhirResourceComponent implements OnInit, OnChanges { case "Immunization": { return ImmunizationComponent; } + case "Location": { + return LocationComponent; + } case "Media": { return MediaComponent; } @@ -137,9 +144,12 @@ export class FhirResourceComponent implements OnInit, OnChanges { // case "NutritionOrder": { // return ListNutritionOrderComponent; // } - // case "Observation": { - // return ListObservationComponent; - // } + case "Observation": { + return ObservationComponent; + } + case "Organization": { + return OrganizationComponent; + } case "Procedure": { return ProcedureComponent; } diff --git a/frontend/src/app/components/fhir/resources/binary/binary.component.ts b/frontend/src/app/components/fhir/resources/binary/binary.component.ts index 191a2e55..259deec3 100644 --- a/frontend/src/app/components/fhir/resources/binary/binary.component.ts +++ b/frontend/src/app/components/fhir/resources/binary/binary.component.ts @@ -56,6 +56,7 @@ export class BinaryComponent implements OnInit, FhirResourceComponentInterface { this.markForCheck() }, (error) => { this.loading = false + console.error("Failed to lookup binary resource from attachment:", error) this.markForCheck() }) } diff --git a/frontend/src/app/components/fhir/resources/diagnostic-report/diagnostic-report.component.ts b/frontend/src/app/components/fhir/resources/diagnostic-report/diagnostic-report.component.ts index 0dba05b9..e0091d93 100644 --- a/frontend/src/app/components/fhir/resources/diagnostic-report/diagnostic-report.component.ts +++ b/frontend/src/app/components/fhir/resources/diagnostic-report/diagnostic-report.component.ts @@ -32,12 +32,12 @@ export class DiagnosticReportComponent implements OnInit, FhirResourceComponentI data: this.displayModel?.issued, enabled: !!this.displayModel?.issued, }, - { - label: 'Category', - data: this.displayModel?.category_coding, - data_type: TableRowItemDataType.CodingList, - enabled: this.displayModel?.has_category_coding, - }, + // { + // label: 'Category', + // data: this.displayModel?.category_coding, + // data_type: TableRowItemDataType.CodingList, + // enabled: this.displayModel?.has_category_coding, + // }, { label: 'Performer', data: this.displayModel?.performer, @@ -50,6 +50,15 @@ export class DiagnosticReportComponent implements OnInit, FhirResourceComponentI enabled: !!this.displayModel?.conclusion, }, ]; + + for(let categoryCodeable of (this.displayModel?.category_coding || [])){ + this.tableData.push({ + label: `Category`, + data_type: TableRowItemDataType.CodableConcept, + data: categoryCodeable, + enabled: true, + }) + } } markForCheck(){ this.changeRef.markForCheck() diff --git a/frontend/src/app/components/fhir/resources/location/location.component.html b/frontend/src/app/components/fhir/resources/location/location.component.html new file mode 100644 index 00000000..2668b35e --- /dev/null +++ b/frontend/src/app/components/fhir/resources/location/location.component.html @@ -0,0 +1,20 @@ +
Details and position information for a physical place where services are provided and resources and participants may be stored, found, contained, or accommodated.
+Observations are a central element in healthcare, used to support diagnosis, monitor progress, determine baselines and patterns and even capture demographic characteristics.
+A formally or informally recognized grouping of people or organizations formed for the purpose of achieving some form of collective action. Includes companies, institutions, corporations, departments, community groups, healthcare practice groups, payer/insurer, etc.
+