...
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
package org.openmrs.module.CDAGenerator.CDAHandlers; public class MyCDADocument extends BaseCdaTypeHandler { public MyCDADocument() { this.documentFullName="MyCDADocument"; this.documentShortName="MCD"; this.documentDescription="to add new cda document type"; this.templateid="some free text";//required attribute,not null this.formatCode=null; //optional attribute } } |
...
- fork our module from gitub here
- open "CDAGenerator-api"folder
- In src/main/java package try to locate "org.openmrs.module.CDAGenerator.SectionHandlers" package
- Now in this "org.openmrs.module.CDAGenerator.SectionHandlers" package, Create class for new section you need and Note that this class must extend BaseCdaSectionHandler class.
- Add details about section either using setter methods or adding in constructor. Thats it and new Section is ready!
...
Image showing location to add new sections
Sample Code
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
package org.openmrs.module.CDAGenerator.SectionHandlers;
public class MySection extends BaseCdaSectionHandler
{
public ChiefComplaintSection()
{
this.sectionName="My Section";
this.templateid="";//ihe specific id
this.sectionDescription="This is my new section";
this.code="";//Ihe specific code for section
}
} |
Screenshots
1) When module is loaded Administration tab looks like this
...