public async Task DeleteAlert(string alertSid) { var alert = await AlertRepository.GetAlert(alertSid); await AlertRepository.DeleteAlert(alertSid); AlertCudOperation?.Invoke(this, new ResourceCudOperationEventArgs <Alert>(alert, ResourceCudOperation.Delete)); }
public async Task ClearDatabase() { await AccountRepository.Clear(); await CallRepository.Clear(); CallCudOperation?.Invoke(this, new ResourceCudOperationEventArgs <Call>(null, ResourceCudOperation.Reset)); await ConferenceRepository.Clear(); ConferenceCudOperation?.Invoke(this, new ResourceCudOperationEventArgs <Conference>(null, ResourceCudOperation.Reset)); await ConferenceParticipantRepository.Clear(); ConferenceParticipantCudOperation?.Invoke(this, new ResourceCudOperationEventArgs <ConferenceParticipant>(null, ResourceCudOperation.Reset)); await AlertRepository.Clear(); AlertCudOperation?.Invoke(this, new ResourceCudOperationEventArgs <Alert>(null, ResourceCudOperation.Reset)); await ActivityLogRepository.Clear(); ActivityLogCudOperation?.Invoke(this, new ResourceCudOperationEventArgs <ActivityLog>(null, ResourceCudOperation.Reset)); }