Skip to content

Instantly share code, notes, and snippets.

@keithmancuso
Created May 1, 2015 14:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save keithmancuso/3bc4df963116c7b513db to your computer and use it in GitHub Desktop.
Save keithmancuso/3bc4df963116c7b513db to your computer and use it in GitHub Desktop.
Not Nominee Check
public PageReference checkIfNotNominee() {
User theUser = GlobalVariables.getCurrentUser();
Coontact theContact = GlobalVariables.getCurrentContact(theUser);
if (theContact.RecordTypeId != RecordTypeConstant.nomineeContactRecordTypeId) {
PageReference page = System.Page.PosseCommunity;
page.setRedirect(true);
return page;
} else {
return null;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment