/// <summary> /// Delete a single Equipment /// </summary> /// <param name="id">equipment id</param> /// <returns></returns> public IResult DeleteEquipment(string id) { var result = new Result { Operation = Operation.Delete, Status = Status.Success }; try { _equipmentRepository.DeleteOne(t => t.EquipmentId == ObjectId.Parse(id)); result.Message = EquipmentNotification.Deleted; } catch (Exception e) { result.Message = e.Message; result.Status = Status.Fail; } return(result); }