@Handler(supports=ConceptName.class) public class ConceptNameSaveHandler extends Object implements SaveHandler<ConceptName>
ConceptName
objects when they are saved via a save* method in an
Openmrs Service. This handler is automatically called by the RequiredDataAdvice
AOP
class. ConceptNameTag
s that have a null
ConceptNameTag.getConceptNameTagId()
.RequiredDataHandler
,
SaveHandler
,
ConceptName
Constructor and Description |
---|
ConceptNameSaveHandler() |
Modifier and Type | Method and Description |
---|---|
void |
handle(ConceptName conceptName,
User currentUser,
Date currentDate,
String reason)
This method does a lookup on all tag name for all child
ConceptNameTag s that have a
null ConceptNameTag.getConceptNameTagId() . |
public void handle(ConceptName conceptName, User currentUser, Date currentDate, String reason)
ConceptNameTag
s that have a
null ConceptNameTag.getConceptNameTagId()
.handle
in interface RequiredDataHandler<ConceptName>
handle
in interface SaveHandler<ConceptName>
conceptName
- an OpenmrsObject that needs to have some required data setcurrentUser
- the user who is saving this objectcurrentDate
- the datetime this object is being savedreason
- (optional) would be the second argument in the save method, if existsShould not fail if tags is null
Should replace tags without ids with database fetched tag
Should not replace tags without ids that are not in the database
Should not replace tags that have ids
Copyright © 2024 OpenMRS Inc.. All rights reserved.