Skip to content

Instantly share code, notes, and snippets.

@miragedeb
Created April 9, 2016 17:24
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save miragedeb/af42ab4f8edd8a36bbed25a2ad7584c1 to your computer and use it in GitHub Desktop.
Save miragedeb/af42ab4f8edd8a36bbed25a2ad7584c1 to your computer and use it in GitHub Desktop.
public class ExtensionName {
Public Flow.Interview.Add_Defenders_to_Quote myAutoFlow { get; set; }
Public ExtensionName(ApexPages.StandardController controller) {}
public String getmyID() {
if (myAutoFlow==null)
return '';
else
//Put flow variable that represents the id of newly created record
return myAutoFlow.vObjID;
}
public PageReference getNextPage(){
PageReference p = new PageReference('/' + getmyID() );
p.setRedirect(true);
return p;
}
}
@jbhenley86
Copy link

I'm having trouble create a test class for this extension, so I can't deploy the extension to production.
Do you have a simple test class for this?
Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment