public bool UpdateFreelancerPersonalInfo(FREELANCER_PERSONAL_INFO_Model entity) { if (entity != null) { var data = Mapper.Map <FREELANCER_PERSONAL_INFO_Model, FREELANCER_PERSONAL_INFO>(entity); return(_iFreelancerPersonalInfoRepository.Update(data)); } return(false); }
public ActionResult Index() { FREELANCER_PERSONAL_INFO_Model personalInfo = null; if (User.Identity.GetUserId() != null) { personalInfo = _iFreelancerPersonalInfoService.GetFreelancerPersonalInfoById(User.Identity.GetUserId()); } return(View(personalInfo)); }
public ActionResult Edit([Bind(Include = "Freelancer_Id,FirstName,LastName,FatherName,MotherName,DOB,Gender,Religion,MaritalStatus,Nationality,NID,PresentAddress,PermanentAddress,Mobile1,Mobile2,Email")] FREELANCER_PERSONAL_INFO_Model freelancer_personal_info_model) { if (ModelState.IsValid) { if (_iFreelancerPersonalInfoService.UpdateFreelancerPersonalInfo(freelancer_personal_info_model)) { return(RedirectToAction("Index")); } } return(View(freelancer_personal_info_model)); }
public ActionResult Edit() { if (User.Identity.GetUserId() == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } FREELANCER_PERSONAL_INFO_Model freelancer_personal_info_model = _iFreelancerPersonalInfoService.GetFreelancerPersonalInfoById(User.Identity.GetUserId()); if (freelancer_personal_info_model == null) { return(HttpNotFound()); } return(View(freelancer_personal_info_model)); }