public function deleteID($ActivityID, $Options = [])
{
// Get the activity first.
$Activity = $this->getID($ActivityID);
if ($Activity) {
// Log the deletion.
$Log = val('Log', $Options);
if ($Log) {
LogModel::insert($Log, 'Activity', $Activity);
}
// Delete comments on the activity item
$this->SQL->delete('ActivityComment', ['ActivityID' => $ActivityID]);
// Delete the activity item
return parent::deleteID($ActivityID);
} else {
return false;
}
}