public IActionResult Index() { var model = new SearchViewModel(); model.BackupDetails = BackupDetails.List(); return(View(model)); }
protected override IActionResult DoAPIAction() { string result = APICall(); result = JsonConvert.DeserializeObject(result).ToString(); var vm = SetMessage(result); var model = new SearchViewModel(); model.BackupDetails = BackupDetails.List(); model.MessageViewModel = vm; return(View("Index", model)); }
public IActionResult Diff(string id) { string result = APICall(); result = JsonConvert.DeserializeObject(result).ToString(); if (result.Equals("Success", StringComparison.OrdinalIgnoreCase)) { ViewBag.Diff = BackupDetails.StoredBackupDetails().GetHTMLDiff(id); Console.WriteLine(ViewBag.Diff); return(View("DiffDisplay")); } var vm = SetMessage(result); var model = new SearchViewModel(); model.BackupDetails = BackupDetails.List(); model.MessageViewModel = vm; return(View("Index", model)); }
public IActionResult Index(SearchViewModel model) { model.BackupDetails = BackupDetails.List(model); return(View("Index", model)); }