This project has moved and is read-only. For the latest updates, please go here.

Creating CCD for Problem List, Allergies, and Medications

Oct 20, 2015 at 3:19 PM
I was wondering if someone has created code using Everest framework for a Problem, Allergy, or Medication List CCD. I would like to look at the code and possibly even use it for an implementation. I have a project were we are migrating patient data and we will need to work with these 3 type of lists via a CCD during the data migration process. Thanks in advance for any help you can lend.
Oct 28, 2015 at 3:01 AM
Hi!

I have a few samples in C# however due to the fact I am at a conference I don't have all the C# source on me. A problem section diagnosing pregnancy would be constructed like this:
            var retVal = new Section()
            {
                Id = Guid.NewGuid(),
                TemplateId = LIST<II>.CreateList(new II("1.3.6.1.4.1.19376.1.5.3.1.3.6")),
                Title = "Active Problems / Concerns",
                Code = new CE<string>("11450-4", "2.16.840.1.113883.6.1", "LOINC", null, "PROBLEM LIST", null),
                Entry = new List<Entry>()
                {
                    new Entry(x_ActRelationshipEntry.DRIV, false, new Act() {
                        TemplateId = LIST<II>.CreateList(new II("1.3.6.1.4.1.19376.1.5.3.1.4.5.2"), new II("1.3.6.1.4.1.19376.1.5.3.1.4.5.1")),
                        Id = SET<II>.CreateSET(Guid.NewGuid()),
                        Code = new CD<string>() { NullFlavor = NullFlavor.NotApplicable },
                        StatusCode = ActStatus.Active,
                        EffectiveTime = new IVL<TS>(DateTime.Now, null),
                        Author = new List<Author>()
                        {
                            new Author()
                            {
                                Time = DateTime.Now,
                                AssignedAuthor = new AssignedAuthor()
                                {
                                    Id = SET<II>.CreateSET(new II(ConfigurationManager.AppSettings["PHYS_OID"], author.PhysicianId))
                                }
                            }
                        }, 
                        EntryRelationship = new List<EntryRelationship>()
                        {
                            new EntryRelationship()
                            {
                                ClinicalStatement = new Observation(x_ActMoodDocumentObservation.Eventoccurrence)
                                {
                                    TemplateId = LIST<II>.CreateList(new II("1.3.6.1.4.1.19376.1.5.3.1.4.5")),
                                    Code = new CD<string>("64572001", "2.16.840.1.113883.6.96", "SNOMED", null, "Condition", null),
                                    StatusCode = ActStatus.Completed,
                                    EffectiveTime = new IVL<TS>(DateTime.Now, null), 
                                    Value = new CD<String>("Z33", "2.16.840.1.113883.6.3", "ICD-10-WHO", null, "Currently Pregnant", null)
                                }
                            }
                        }

                    })
                }
            };

            string refText = "<content>Patient is currently pregnant</content>";
            retVal.Text = new ED();
            retVal.Text.Data = System.Text.Encoding.UTF8.GetBytes(refText);
            retVal.Text.Representation = MARC.Everest.DataTypes.Interfaces.EncapsulatedDataRepresentation.XML;
            retVal.Text.MediaType = null;
I also have a few samples in JEverest which can be adapted to .NET quite easily if you're interested.
Oct 28, 2015 at 4:36 PM
Thank you for the example! I will check it out. I would be interested in either your Java or .NET examples.

When you have time send some other examples. Again thank you for help.