12.07.2015 Views

Open CTI Developer's Guide - Salesforce.com

Open CTI Developer's Guide - Salesforce.com

Open CTI Developer's Guide - Salesforce.com

SHOW MORE
SHOW LESS
  • No tags were found...

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Methods for <strong>Salesforce</strong> Application InteractionsearchAndScreenPop()NameTypeDescriptionThe following is an example of searching for “Acme,” and finding one Accountand three Opportunity objects:{"006x0000001ZcyG":{"Name":"Acme - 600Widgets","object":"Opportunity"},"001x0000003DGQR":{"Name":"Acme","Type":"1","object":"Account"},"006x0000001ZcyH":{"Name":"Acme - 200Widgets","object":"Opportunity"},"006x0000001ZcyF":{"Name":"Acme - 1,200Widgets","object":"Opportunity"},screenPopUrl:"/search/SearchResults?searchType=2&str=Acme"}errorstringIf the API call was successful, this variable is undefined. If the API call failed,this variable returns an error message.searchAndScreenPop()UsageSearches objects specified in the SoftPhone layout for a given string. Returns search results and screen pops any matchingrecords. This method respects screen pop settings defined in the SoftPhone layout. For more information, see “Designing aCustom SoftPhone Layout” in the <strong>Salesforce</strong> online help.Syntaxsforce.interaction.searchAndScreenPop(searchParams:string, queryParams:string,callType:string, (optional) callback:function);ArgumentsNamesearchParamsqueryParamscallTypecallbackTypestringstringstringfunctionDescriptionString to search.Specifies the query parameters to pass to the URL.Specifies the type of call, such as inbound, outbound, internal, or null. Per thesettings in the SoftPhone layout, the call type determines which objects tosearch for any matches. For more information, see “Designing a CustomSoftPhone Layout” in the <strong>Salesforce</strong> online help.If callType is null, searches are inbound by default. If callType is internalor outbound, no screen pops occur.JavaScript method called upon <strong>com</strong>pletion of the method.Sample Code–JavaScriptvar callback = function (response) {28

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!