public void Run() { var model = RecipeReportService.GetRecipeSelectionModel(); model.Callback = RunRecipeReport; var window = new NetworkReportSelectionView { ViewModel = this }; window.Render(model); window.ShowDialog(); }
private void RunRecipeReport(RecipeReportSelectionModel model) { View.StatusUpdate(StatusModel.StartStopWatch); View.StatusUpdate(StatusModel.Update("Running Recipe Report")); ThreadPool.QueueUserWorkItem(delegate { try { View.EnableCancel(true); bool wasCancelled; RecipeReportService.RunReport(model, View.StatusUpdate, out wasCancelled); if (wasCancelled) { View.ReportCancelled(); } RenderDocument(); } finally { View.EnableCancel(false); View.StatusUpdate(StatusModel.Completed); } }); }
public void Delete(string key) { RecipeReportService.DeleteReport(key); RenderDocument(); }
public void CancelReport() { RecipeReportService.CancelReport(); }
public override RecipeReportModel GetModel() { return(RecipeReportService.GetModel()); }