public DeleteEnvironmentScanningResponse DeleteEnvironmentalScanning(DeleteEnvironmentScanningRequest request) { var environmental = new EnvironmentalScanning { Id = request.Id }; DataContext.EnvironmentalScannings.Attach(environmental); DataContext.EnvironmentalScannings.Remove(environmental); DataContext.SaveChanges(); return(new DeleteEnvironmentScanningResponse { IsSuccess = true, Message = "Deleted has been succesfully" }); }
public DeleteEnvironmentScanningResponse DeleteEnvironmentScanning(DeleteEnvironmentScanningRequest request) { var ultimate = new UltimateObjectivePoint { Id = request.Id }; DataContext.UltimateObjectivePoints.Attach(ultimate); DataContext.UltimateObjectivePoints.Remove(ultimate); DataContext.SaveChanges(); return(new DeleteEnvironmentScanningResponse { IsSuccess = true, Message = "Deleted has been succesfully" }); }