public async Task <IActionResult> DeleteAsync(int id)
        {
            var result = await
                         _manager
                         .DeleteAsync(id);

            return(Ok(result
                ? ServiceResponseHelper.GetSuccessResponse(result)
                : ServiceResponseHelper.GetFailureResponse <bool>()));
        }
Example #2
0
        public async Task <IHttpActionResult> DeleteDepartment(int clientId, int departmentId)
        {
            var userId = GetUserId();

            return(Ok(await _departmentManager.DeleteAsync(departmentId, clientId, userId)));
        }