Created
September 3, 2016 08:19
-
-
Save chathurawidanage/aaf3de2da7b507867da84a48f33f8e91 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@RequestMapping( value = "/{id}", method = RequestMethod.DELETE ) | |
@PreAuthorize( "hasRole('ALL') or hasRole('F_TRACKED_ENTITY_INSTANCE_ADD')" ) | |
@ResponseStatus( HttpStatus.NO_CONTENT ) | |
public void deleteTrackedEntityInstance( @PathVariable String id ) throws WebMessageException | |
{ | |
if ( !instanceService.trackedEntityInstanceExists( id ) ) | |
{ | |
throw new WebMessageException( WebMessageUtils.notFound( "Tracked entity instance not found for ID " + id ) ); | |
} | |
trackedEntityInstanceService.deleteTrackedEntityInstance( id ); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment