public async Task <IActionResult> Edit(int id, [Bind("ID,InitiatedART401,InitiatedARTDate401," + "DeliveryFacility402,DeliveryFacilityDate402," + "EarlyBirth403a,EarlyBirthDate403a,InfantHIVstatus403b,MotherResults403c," + "MotherResultsDate403c,InfantBreastfeeding404a,InfantBreastfeedingDate404a," + "RemarksName,NambaMshiriki01,UserId,Wilaya02,TareheMahojiano03,Kituo04,JinaAnayehoji05,Ngazikituo06,MdaKuishiZanzibar109,KiwangoElimu102,Umri101,WilayaUnayoishi107,IdadiMimba106,HaliNdoa103,KipatoMwezi104,Kazi105,NjeZanzibar108,KilomitaKituo201,KilomitaUjazo202,HudumaUjauzito203,UgumuKliniki204a,HudumaHapa205,BasiMbaliAfya204b_1,UgumuUsafiriUmma204b_2,KukosaNauli204b_3,MsafaraMrefu204b_4,AnaishiMbaliBasi204b_5,AnaishiMbaliAfya204b_6,Mengine204b_7,TajaMengine204b,UmepataHapaHuduma206,UmriMimba301,MwakaVVU302,MdaVVU303,DawaVVU304a,LiniDawaVVU304b,CTC304c")] PmtctData pmtctData) { if (id != pmtctData.ID) { _logger.LogWarning(LoggingEvents.GetItemNotFound, "Update({Id}) NOT FOUND", id); return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(pmtctData); await _context.SaveChangesAsync(); _logger.LogInformation(LoggingEvents.UpdateItem, "Item {Id} Updated", pmtctData.ID); } catch (DbUpdateConcurrencyException) { if (!PmtctDataExists(pmtctData.ID)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(pmtctData)); }
public async Task <IActionResult> Edit(int id, [Bind("ID,TareheHudhurio,HaliYako305a,Mwenza305b1," + "Mwanafamiliaa305b2,Wazazi305b3,Rafiki305b1,Mfanyakazi305b5,Wengine305b6,Tajawengine305b7," + "Naogopakutengwa306a1,Naogopakuachwa306a2,kunyanyapaliwa306a2,BadosijaaminiVVUliwa306a4," + "Sinaninaemwamini306a6,Nyinginezo306a6,MpangoMtu306b,HaliMwenza307,KuhudumiwaTofautiVVU308a," + "Mwenza308b1,Mwanafamiliaa308b2,Wazazi308b3,Rafiki308b1,Mfanyakazi308b5,Mhudumu308b6,Wengine308b7," + "Tajawengine308b8,UmejiungaVVU309a,NdioTaja309b,MamaMwambata310a,Ushauri310b1,Elimuafya310b2," + "Ufuatiliaji310b3,Nyinginezo310b4,Rufaa,TareheHudhurioLijalo,Ufuatiliaji,JinaMtoHuduma," + "NambaMshiriki01")] PmtctFollowUp pmtctFollowUp) { if (id != pmtctFollowUp.ID) { return(NotFound()); } if (ModelState.IsValid) { try { _context.Update(pmtctFollowUp); await _context.SaveChangesAsync(); } catch (DbUpdateConcurrencyException) { if (!PmtctFollowUpExists(pmtctFollowUp.ID)) { return(NotFound()); } else { throw; } } return(RedirectToAction(nameof(Index))); } return(View(pmtctFollowUp)); }