Reputation: 1
At my current company we have DocuSign integrated with Salesforce for sending out contracts to our potential clients.
Each contract is required to be signed by our potential client but also from our VP of sales/services.
I created a custom button on the quote object to submit the quote to DocuSign passing the information required (Signer Role, name, email etc) The problem I am having is that for some reason the full name of the second signer (the internal signer) does not get passed on to DocuSign so the sales rep has to manually go and edit the recipients each time and add the name.
Button code:
var quoteApproved = {!Quote.Quote_Approved__c};
//********* Option Declarations (Do not modify )*********//
var RC = '';
var RSL = '';
var RSRO = '';
var RROS = '';
var CCRM = '';
var CCTM = '';
var CCNM = '';
var CRCL = '';
var CRL = '';
var OCO = '';
var DST = '';
var LA = '';
var CEM = '';
var CES = '';
var STB = '';
var SSB = '';
var SES = '';
var SEM = '';
var SRS = '';
var SCS = '';
var RES = '';
//*************************************************//
switch ("{!Quote.Signed_by__c}") {
case "John Cash":
CRL = "[email protected]; FirstName~John; LastName~Cash; Role~Signer 2; RoutingOrder~1";
CCTM = "Signer 2~Signer";
break;
case "Mark Cash":
CRL = "[email protected]; FirstName~Mark; LastName~Cash; Role~Signer 2; RoutingOrder~1";
CCTM = "Signer 2~Signer";
}
if (quoteApproved) {
{
!REQUIRESCRIPT("/apex/dsfs__DocuSign_JavaScript")
}
var sourceId = DSGetPageIDFromHref();
var RQD = DSGetPageIDFromHref();
window.location.href = "/apex/dsfs__DocuSign_CreateEnvelope?DSEID=0&SourceID=" + sourceId + "&CCTM=" + CCTM + "&CRL=" + CRL + "&RQD=" + RQD;
} else {
alert("Your quote has not been approved yet. \nPlease submit for approval before sending the contract.");
}
Upvotes: 0
Views: 129
Reputation: 1
I have resolved the issue. The RQD variable was adding a # at the end of the URL preventing the completion of the field mapping.
Upvotes: 0