private void UpdateStepsToSkip(ProfileImportStep step, Boolean add) { List <ProfileImportStep> toSkip = View.SkipSteps; if (add && !toSkip.Contains(step)) { toSkip.Add(step); } else if (!add && toSkip.Contains(step)) { toSkip.Remove(step); } View.SkipSteps = toSkip; }
public void MoveToNextStep(ProfileImportStep step) { switch (step) { case ProfileImportStep.SelectSource: MoveFromSourceSelector(); break; case ProfileImportStep.SourceCSV: case ProfileImportStep.SourceRequestForMembership: case ProfileImportStep.SourceCallForPapers: MoveFromSelectedSource(); break; // MoveFromSelectedSource(); //// MoveToSummary(); // break; case ProfileImportStep.FieldsMatcher: MoveFromFieldsMatcher(); break; case ProfileImportStep.ItemsSelctor: MoveFromItemsSelector(); break; case ProfileImportStep.SelectOrganizations: MoveFromOrganizationsSelector(); break; case ProfileImportStep.SelectCommunities: MoveFromCommunitiesSelector(); break; case ProfileImportStep.SubscriptionsSettings: MoveFromSubscriptionsSettings(); break; case ProfileImportStep.MailTemplate: MoveFromMailTemplate(); break; case ProfileImportStep.Summary: break; } }
public void MoveToPreviousStep(ProfileImportStep step) { if (UserContext.isAnonymous) { View.DisplaySessionTimeout(); } else { switch (step) { case ProfileImportStep.SourceCSV: case ProfileImportStep.SourceRequestForMembership: case ProfileImportStep.SourceCallForPapers: View.GotoStep(ProfileImportStep.SelectSource); break; //case ProfileImportStep.SourceRequestForMembership: // View.GotoStep(ProfileImportStep.SelectSource); // break; case ProfileImportStep.FieldsMatcher: switch (View.CurrentSource) { case SourceType.FileCSV: View.GotoStep(ProfileImportStep.SourceCSV); break; case SourceType.RequestForMembership: View.GotoStep(ProfileImportStep.SourceRequestForMembership); break; case SourceType.CallForPapers: View.GotoStep(ProfileImportStep.SourceCallForPapers); break; default: break; } break; case ProfileImportStep.ItemsSelctor: View.GotoStep(ProfileImportStep.FieldsMatcher); break; case ProfileImportStep.SelectOrganizations: View.GotoStep(ProfileImportStep.ItemsSelctor); break; case ProfileImportStep.SelectCommunities: View.GotoStep(ProfileImportStep.SelectOrganizations); break; case ProfileImportStep.SubscriptionsSettings: View.GotoStep(ProfileImportStep.SelectCommunities); break; case ProfileImportStep.MailTemplate: View.GotoStep(ProfileImportStep.SubscriptionsSettings); break; case ProfileImportStep.Summary: View.GotoStep(ProfileImportStep.MailTemplate); break; case ProfileImportStep.ImportCompleted: if (View.ItemsToSelect > 0 && View.PreviousStep != ProfileImportStep.None) { View.GotoStep(View.PreviousStep); } else { View.GotoStep(ProfileImportStep.SelectSource, true); } View.PreviousStep = ProfileImportStep.None; break; case ProfileImportStep.ImportWithErrors: if (View.ItemsToSelect > 0 && View.PreviousStep != ProfileImportStep.None) { View.GotoStep(View.PreviousStep); } else { View.GotoStep(ProfileImportStep.SelectSource, true); } View.PreviousStep = ProfileImportStep.None; break; case ProfileImportStep.Errors: View.GotoStep(ProfileImportStep.Summary); break; } } }