public async Task <IActionResult> Create([Bind("Cid,Fname,Lname,Country")] Custometbl custometbl) { if (ModelState.IsValid) { _context.Add(custometbl); await _context.SaveChangesAsync(); return(RedirectToAction(nameof(Index))); } return(View(custometbl)); }
public async Task <IActionResult> Create([Bind("AdoptId,ChildFullName,AdoptFullName,CitizenshipofAdopter,Ageofchild,AdopterphoneNumber,ReasonforAdoption,Sexofchild,IssueDate,Cid")] Adoptiontbl adoptiontbl) { if (ModelState.IsValid) { _context.Add(adoptiontbl); await _context.SaveChangesAsync(); return(RedirectToAction(nameof(Index))); } ViewData["Cid"] = new SelectList(_context.Custometbl, "Cid", "Fname", adoptiontbl.Cid); return(View(adoptiontbl)); }
public async Task <IActionResult> Create([Bind("Mnum,DateofMarriage,HusbandFullname,Wifefullname,Wittness1,Wittness2,WifeAge,HusbandAge,Region,Zone,IssueDate,Cid")] Marriagetbl marriagetbl) { if (ModelState.IsValid) { _context.Add(marriagetbl); await _context.SaveChangesAsync(); return(RedirectToAction(nameof(Index))); } ViewData["Cid"] = new SelectList(_context.Custometbl, "Cid", "Fname", marriagetbl.Cid); return(View(marriagetbl)); }
public async Task <IActionResult> Create([Bind("Did,DateofDivorce,DcirtificateNumber,HusbandFullName,WifeFullName,WifeAge,RequesterofDinvorce,IssueDate,Cid")] Divorcetbl divorcetbl) { if (ModelState.IsValid) { _context.Add(divorcetbl); await _context.SaveChangesAsync(); return(RedirectToAction(nameof(Index))); } ViewData["Cid"] = new SelectList(_context.Custometbl, "Cid", "Fname", divorcetbl.Cid); return(View(divorcetbl)); }
public async Task <IActionResult> Create([Bind("DrefNum,DateofDeath,CaseofDeath,Region,Zone,Woreda,Wittness,Reltionofwittness,Age,Sex,IssueDate,Cid")] Deathtbl deathtbl) { if (ModelState.IsValid) { _context.Add(deathtbl); await _context.SaveChangesAsync(); return(RedirectToAction(nameof(Index))); } ViewData["Cid"] = new SelectList(_context.Custometbl, "Cid", "Fname", deathtbl.Cid); return(View(deathtbl)); }
public async Task <IActionResult> Create([Bind("Cnum,Dob,Mfullname,Region,Woreda,Sex,DateofIssue,Cid")] Birthtbl birthtbl) { if (ModelState.IsValid) { _context.Add(birthtbl); await _context.SaveChangesAsync(); return(RedirectToAction(nameof(Index))); } ViewData["Cid"] = new SelectList(_context.Custometbl, "Cid", "Fname", birthtbl.Cid); return(View(birthtbl)); }