public IActionResult OnGet(int companyId) { Company = companyData.GetById(companyId); if (Company == null) { return(RedirectToPage("./NotFound")); } return(Page()); }
public IActionResult OnGet(int companyId) { company = new CompanyDemo.Core.Company(); company = companyData.GetById(companyId); if (company == null) { //Response.StatusCode = 404; //return null; return(RedirectToPage("./NotFound")); } return(Page()); }
public void OnGet(int companyId) { Company = companyData.GetById(companyId); CompanyTypes = htmlHelper.GetEnumSelectList <CompanyType>(); }