'complete_activity' Command
The command affects only the started activity specified by key fields of 'command/appointment' element that exists in the system and sets the activity status to 'completed'. The command will:
a) complete the existing started activity, specified by key fields of 'command/appointment'
b) update activity properties if 'command/appointment/properties' element is present
The command will fail if:
activity does not exist in OFSC
activity status is other than started
'command/time' is less than activity start time
Note: A segmentable activity can only be completed by the 'complete_activity'
command if there are no started segments and there is at least one
segment in the 'complete' or 'notdone' status, otherwise the command
will fail.