public ActionResult Edit([Bind(Include = "CompanyName,CompanyLink,Address,City,State,ZipCode,Latitude,Longitude,CareerPage")] Company company) { if (ModelState.IsValid) { db.Entry(company).State = EntityState.Modified; db.SaveChanges(); return(RedirectToAction("Index")); } return(View(company)); }
public async Task <ActionResult> Edit([Bind(Include = "ID,ApplicationLink,Company,DatePosted,Experience,Hours,JobID,JobTitle,LanguagesUsed,Location,Salary")] Job job) { if (ModelState.IsValid) { context.Entry(job).State = EntityState.Modified; await context.SaveChangesAsync(); return(RedirectToAction("Index")); } PopulateCompanyDropdownList(); return(View(job)); }