public IActionResult GetFamilyMembersForm()
        {
            var model = new FamilyMembersViewModel();

            model.LoadMaritalStatuses(familyResearchRepository);
            model.LoadRelationships(familyResearchRepository);

            return(PartialView("_FamilyMembersForm", model));
        }
        public IActionResult AddItemInFamilyMembersTable([FromBody] FamilyMembersDetails model)
        {
            if (ModelState.IsValid == true)
            {
                model.FullName = model.FullName?.Trim();
                SessionState.UserSession.AddItemInDataCollection <FamilyMembersDetails>(Constants.FamilyResearch_FamilyMembers_Table, model);
            }

            var familyMembersDetails = new FamilyMembersViewModel();

            familyMembersDetails.LoadMaritalStatuses(familyResearchRepository);
            familyMembersDetails.LoadRelationships(familyResearchRepository);
            familyMembersDetails.Age = model?.Age;
            familyMembersDetails.CurrentOccupation = model?.CurrentOccupation;
            familyMembersDetails.Education         = model?.Education;
            familyMembersDetails.FullName          = model?.FullName;
            familyMembersDetails.MaritalStatusId   = model?.MaritalStatusId ?? 0;
            familyMembersDetails.RelationshipId    = model?.RelationshipId ?? 0;

            return(PartialView("_FamilyMembersForm", familyMembersDetails));
        }