The API retrieves the name of the first template associated with the given proposal.

APISignature
selectFirstTemplateNameForProposalwebService static String selectFirstTemplateNameForProposal(Id proposalId)



Request Parameter
NameTypeDescription
proposalIdID

The ID of the proposal.



Response Parameter
FieldTypeDescription
templateNameStringThe name of the first template.


Code Sample

The sample code below enables you to get the first template name associated to the given proposal.


/**
 * The below code gets first template name.
 */
public String selectFirstTemplateNameForProposal(String proposalName) 
{
	String templateName;
	Id proposalSOID = [SELECT Id FROM Apttus_Proposal__Proposal__c WHERE Name = :proposalName LIMIT 1].Id;
	templateName = Apttus_Proposal.ProposalWebService.selectFirstTemplateNameForProposal(proposalSOID);
   	return templateName;
}
CODE