public PartialViewResult _EducationVarificationForm() { EducationVarificationModel model = new EducationVarificationModel(); var objloginmodel = (eTracLoginModel)(Session["etrac"]); model = _IGuestUserRepository.GetEducationVerificationForm(objloginmodel.UserId); return(PartialView("_EducationVarificationForm", model)); }
public ActionResult _EducationVarificationForm(EducationVarificationModel model) { if (ModelState.IsValid) { var objloginmodel = (eTracLoginModel)(Session["etrac"]); _IGuestUserRepository.SetEducationVerificationForm(objloginmodel.UserId, model); return(Json(true, JsonRequestBehavior.AllowGet)); } model.IsSave = false; return(PartialView("_EducationVarificationForm", model)); }
public void SetEducationVerificationForm(long userId, EducationVarificationModel model) { try { using (workorderEMSEntities Context = new workorderEMSEntities()) { var empid = Context.UserRegistrations.Where(x => x.UserId == userId)?.FirstOrDefault().EmployeeID; var isexist = GetEducationVerificationForm(userId); if (ReferenceEquals(isexist, null)) { Context.spSetEducationVerificationForm("I", model.EvfId, empid, model.Certificate, model.HighSchool.SchoolName, "", model.HighSchool.City, model.HighSchool.State, model.HighSchool.AttendFrom, model.HighSchool.AttendTo, model.IsActive); } else { Context.spSetEducationVerificationForm("U", isexist.EvfId, empid, model.Certificate, model.HighSchool.SchoolName, "", model.HighSchool.City, model.HighSchool.State, model.HighSchool.AttendFrom, model.HighSchool.AttendTo, model.IsActive); } } } catch (Exception ex) { throw ex; } }
/// <summary> /// Created By : Ashwajit Bansod /// Created Date : 02-11-2019 /// Created For : TO save files from mobile /// </summary> /// <param name="obj"></param> /// <returns></returns> public bool SaveFileList(CommonFormModel obj) { bool isSaved = false; var _guestRepository = new GuestUserRepository(); try { if (obj != null) { if (obj.FormName == "EducationForm" && obj.EducationFormModel != null) { var educatioModel = new EducationVarificationModel(); educatioModel.EvfId = obj.EducationFormModel.EVF_Id; educatioModel.Certificate = obj.EducationFormModel.EVF_SchoolDegreeDiplomaCert; educatioModel.HighSchool.SchoolName = obj.EducationFormModel.EVF_OrganizationName; educatioModel.HighSchool.City = obj.EducationFormModel.EVF_City; educatioModel.HighSchool.State = obj.EducationFormModel.EVF_State; educatioModel.HighSchool.AttendFrom = Convert.ToDateTime(obj.EducationFormModel.EVF_AttendedFrom); educatioModel.HighSchool.AttendTo = Convert.ToDateTime(obj.EducationFormModel.EVF_AttendedTo); educatioModel.IsActive = "Y"; _guestRepository.SetEducationVerificationForm(obj.UserId, educatioModel); isSaved = true; } else if (obj.FormName == "DirectDepositForm" && obj.DirectDepositFormModel != null) { var directDepo = new DirectDepositeFormModel(); directDepo.Account1.EmployeeBankName = obj.DirectDepositFormModel.DDF_BankName_1; directDepo.Account1.AccountType = obj.DirectDepositFormModel.DDF_AccountType_1; directDepo.Account1.Account = obj.DirectDepositFormModel.DDF_AccountNumber_1; directDepo.Account1.BankRouting = obj.DirectDepositFormModel.DDF_BankRountingNumber_1; directDepo.Account1.DepositeAmount = obj.DirectDepositFormModel.DDF_PercentageOrDollarAmount_1; directDepo.Account2.EmployeeBankName = obj.DirectDepositFormModel.DDF_BankName_2; directDepo.Account2.AccountType = obj.DirectDepositFormModel.DDF_AccountType_2; directDepo.Account2.Account = obj.DirectDepositFormModel.DDF_AccountNumber_2; directDepo.Account2.BankRouting = obj.DirectDepositFormModel.DDF_BankRountingNumber_2; directDepo.Account2.DepositeAmount = obj.DirectDepositFormModel.DDF_PercentageOrDollarAmount_2; _guestRepository.SetDirectDepositeFormData(directDepo, obj.UserId); isSaved = true; } else if (obj.FormName == "EmergencyContactInfo" && obj.EmergencyContactFormModel != null) { var emergency_form = new EmergencyContactFormModel(); emergency_form.ECF_EMP_EmployeeId = obj.EmergencyContactFormModel.ECF_EMP_EmployeeId; emergency_form.ECF_HomeEmail = obj.EmergencyContactFormModel.ECF_HomeEmail; emergency_form.ECF_HomePhone = obj.EmergencyContactFormModel.ECF_HomePhone; emergency_form.ECF_Id = obj.EmergencyContactFormModel.ECF_Id; emergency_form.ECF_NickName = obj.EmergencyContactFormModel.ECF_NickName; emergency_form.ECF_FirstName = obj.EmergencyContactFormModel.ECF_FirstName; emergency_form.ECF_MiddleName = obj.EmergencyContactFormModel.ECF_MiddleName; emergency_form.ECF_LastName = obj.EmergencyContactFormModel.ECF_LastName; emergency_form.ECF_Address = obj.EmergencyContactFormModel.ECF_Address; emergency_form.ECF_Gender = obj.EmergencyContactFormModel.ECF_Gender; emergency_form.ECF_Citizenship = obj.EmergencyContactFormModel.ECF_Citizenship; emergency_form.ECF_BirthDate = obj.EmergencyContactFormModel.ECF_BirthDate; emergency_form.ECF_DriverLicense = obj.EmergencyContactFormModel.ECF_DriverLicense; emergency_form.ECF_EmergencyContactName = obj.EmergencyContactFormModel.ECF_EmergencyContactName; emergency_form.ECF_Mobile = obj.EmergencyContactFormModel.ECF_Mobile; emergency_form.ECF_PhoneNumber = obj.EmergencyContactFormModel.ECF_PhoneNumber; emergency_form.ECF_SSN = obj.EmergencyContactFormModel.ECF_SSN; emergency_form.ECF_Relationship = obj.EmergencyContactFormModel.ECF_Relationship; emergency_form.ECF_HomeAddress = obj.EmergencyContactFormModel.ECF_HomeAddress; _guestRepository.SetEmergencyContactFormData(emergency_form, obj.UserId); isSaved = true; } else if (obj.FormName == "W-4" && obj.W4FormModel != null) { var w4_Form = new W4FormModel(); w4_Form.EmployeerNameAndAddress = obj.W4FormModel.EmployeerNameAndAddress; w4_Form.City = obj.W4FormModel.City; w4_Form.State = obj.W4FormModel.State; w4_Form.Zip = obj.W4FormModel.Zip; w4_Form.FirstName = obj.W4FormModel.FirstName; w4_Form.LastName = obj.W4FormModel.LastName; w4_Form.MiddleName = obj.W4FormModel.MiddleName; w4_Form.w4F_10 = obj.W4FormModel.w4F_10; w4_Form.EmployeeMaritalStatus = obj.W4FormModel.EmployeeMaritalStatus; w4_Form.w4F_4 = obj.W4FormModel.w4F_4; w4_Form.w4F_5 = obj.W4FormModel.w4F_5; w4_Form.w4F_6 = obj.W4FormModel.w4F_6; w4_Form.w4F_7 = obj.W4FormModel.w4F_7; w4_Form.w4F_8EmployersName = obj.W4FormModel.w4F_8EmployersName; w4_Form.w4F_9 = obj.W4FormModel.w4F_9; w4_Form.EmpId = obj.W4FormModel.EmpId; w4_Form.W4FId = obj.W4FormModel.W4FId; w4_Form.SSN = obj.W4FormModel.SSN; // _guestRepository.SetDirectDepositeFormData(w4_Form, obj.UserId); } } } catch (Exception ex) { } return(isSaved); }