Created
November 13, 2017 17:22
-
-
Save SalesforceCPQ/f1a3853a0d2a923a0ed68292e9f559d4 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public class GenerateNDA { | |
| public GenerateNDA(ApexPages.StandardController stdcontroller){ | |
| } | |
| public PageReference createNDA() | |
| { | |
| string quoteID = ApexPages.currentPage().getParameters().get('id'); | |
| SBQQ__Quote__c q = [select id, name from SBQQ__Quote__c where id = :quoteID]; | |
| q.SBQQ__QuoteTemplateId__c = '[QUOTE TEMPLATE ID HERE]'; | |
| Database.Update(q); | |
| return new PageReference('/apex/sbqq__GenerateDocument?scontrolCaching=1&id=' + quoteID); | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment