What happens when you create the default view for an Opp to use Skuid but a user does not have a license?

  • 1
  • Question
  • Updated 5 years ago
  • Answered
Does the user get the Salesforce default view or does it error out?
Photo of Michael Marshall

Michael Marshall

  • 362 Points 250 badge 2x thumb

Posted 6 years ago

  • 1
Photo of Zach McElrath

Zach McElrath, Employee

  • 49,056 Points 20k badge 2x thumb
Official Response
Mike, good question.

Assuming that the user has access to the Visualforce page that you've created to perform the override logic, and that you're using "skuid.Redirects" as the extension class that performs the redirect logic, then by default, what would happen is that, if the user does not have a Skuid license, they'll get an error --- if they DO have a Skuid license, they'll get redirected appropriately. This is an unavoidable consequence of the fact that the user is accessing code included in a managed package.

However, fortunately, there is a way to avoid this.

If you add a local version of this Redirects class, your users who do NOT have Skuid licenses (yet :) will be invisibly redirected to the appropriate Standard / Default Salesforce view, instead of the view that they would be served by Skuid.

HOW TO DO THIS:

1. Add this Apex class into your org (either through Force.com IDE, a change set from a Sandbox, or Migration Tool).

2. Once the class is deployed, go to the Visualforce override page you created for the Opportunity object's view action. Find extensions="skuid.Redirects" and replace it with extensions="Redirects" (that is, telling the page to use your local Redirects class instead of Skuid's Redirects class. Save the Visualforce page.

3. Result --> your users who don't have Skuid licenses yet should be redirected to standard Salesforce pages. Once they have Skuid licenses, normal Skuid behavior will occur.