<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Finesse Gadget DirectTransfer failing in Contact Center</title>
    <link>https://community.cisco.com/t5/contact-center/finesse-gadget-directtransfer-failing/m-p/4316370#M11849</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Can you please help me how to pass agtExtn dynamically to&amp;nbsp;initiateDirectTransfer in gadget? Case1 is working but not Case2 or Case3.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;U&gt;&lt;STRONG&gt;Case1 :&lt;/STRONG&gt;-&lt;/U&gt; &lt;STRONG&gt;Hardcoded agentExtn; Transfer working&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;html += "&amp;lt;button class=\"btn btn-primary btn-block\" id=\"btn\" onClick=\"finesse.modules.SampleGadget.initiateDirectTransfer(1234567890,'8000000000');\"&amp;gt;WRAP CALL &amp;lt;/button&amp;gt;";&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Case2:-Assigned var agtExtn = user.getExtension(); and passing&amp;nbsp;agtExtn in single quote;Transfer Failing&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;html += "&amp;lt;button class=\"btn btn-primary btn-block\" id=\"btn\" onClick=\"finesse.modules.SampleGadget.initiateDirectTransfer('agtExtn','8000000000');\"&amp;gt;WRAP CALL &amp;lt;/button&amp;gt;";&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Case3:-Assigned var agtExtn = user.getExtension(); and passing&amp;nbsp;agtExtn without single quote;Transfer Failing&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;html += "&amp;lt;button class=\"btn btn-primary btn-block\" id=\"btn\" onClick=\"finesse.modules.SampleGadget.initiateDirectTransfer(agtExtn,'8000000000');\"&amp;gt;WRAP CALL &amp;lt;/button&amp;gt;";&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can you please help me why it is not working when passing agtExtn dynamically?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 30 Mar 2021 19:06:23 GMT</pubDate>
    <dc:creator>smeegada1</dc:creator>
    <dc:date>2021-03-30T19:06:23Z</dc:date>
    <item>
      <title>Finesse Gadget DirectTransfer failing</title>
      <link>https://community.cisco.com/t5/contact-center/finesse-gadget-directtransfer-failing/m-p/4316370#M11849</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Can you please help me how to pass agtExtn dynamically to&amp;nbsp;initiateDirectTransfer in gadget? Case1 is working but not Case2 or Case3.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;U&gt;&lt;STRONG&gt;Case1 :&lt;/STRONG&gt;-&lt;/U&gt; &lt;STRONG&gt;Hardcoded agentExtn; Transfer working&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;html += "&amp;lt;button class=\"btn btn-primary btn-block\" id=\"btn\" onClick=\"finesse.modules.SampleGadget.initiateDirectTransfer(1234567890,'8000000000');\"&amp;gt;WRAP CALL &amp;lt;/button&amp;gt;";&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Case2:-Assigned var agtExtn = user.getExtension(); and passing&amp;nbsp;agtExtn in single quote;Transfer Failing&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;html += "&amp;lt;button class=\"btn btn-primary btn-block\" id=\"btn\" onClick=\"finesse.modules.SampleGadget.initiateDirectTransfer('agtExtn','8000000000');\"&amp;gt;WRAP CALL &amp;lt;/button&amp;gt;";&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Case3:-Assigned var agtExtn = user.getExtension(); and passing&amp;nbsp;agtExtn without single quote;Transfer Failing&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;html += "&amp;lt;button class=\"btn btn-primary btn-block\" id=\"btn\" onClick=\"finesse.modules.SampleGadget.initiateDirectTransfer(agtExtn,'8000000000');\"&amp;gt;WRAP CALL &amp;lt;/button&amp;gt;";&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can you please help me why it is not working when passing agtExtn dynamically?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 30 Mar 2021 19:06:23 GMT</pubDate>
      <guid>https://community.cisco.com/t5/contact-center/finesse-gadget-directtransfer-failing/m-p/4316370#M11849</guid>
      <dc:creator>smeegada1</dc:creator>
      <dc:date>2021-03-30T19:06:23Z</dc:date>
    </item>
    <item>
      <title>Re: Finesse Gadget DirectTransfer failing</title>
      <link>https://community.cisco.com/t5/contact-center/finesse-gadget-directtransfer-failing/m-p/4316399#M11850</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you want to pass in the agent's extension, you need to do that in the js file rather than the html. I would suggest removing that parameter from the&amp;nbsp;&lt;SPAN&gt;finesse.modules.SampleGadget.initiateDirectTransfer method and within the initiateDirectTransfer method, use &lt;A href="https://developer.cisco.com/docs/finesse/#!rest-services-user/getextension" target="_self"&gt;user.getExtension()&lt;/A&gt; in the dialog.initiateDirectTransfer method call.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;I hope that helps.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Thanx,&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Denise&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 30 Mar 2021 20:10:17 GMT</pubDate>
      <guid>https://community.cisco.com/t5/contact-center/finesse-gadget-directtransfer-failing/m-p/4316399#M11850</guid>
      <dc:creator>dekwan</dc:creator>
      <dc:date>2021-03-30T20:10:17Z</dc:date>
    </item>
    <item>
      <title>Re: Finesse Gadget DirectTransfer failing</title>
      <link>https://community.cisco.com/t5/contact-center/finesse-gadget-directtransfer-failing/m-p/4316452#M11851</link>
      <description>&lt;P&gt;Hi Denise,&lt;/P&gt;&lt;P&gt;My requirement is to initiateDirectTransfer after agent clicking button so am using below logic in JS file only.I have tried passing&amp;nbsp;&lt;SPAN&gt;&lt;A href="https://developer.cisco.com/docs/finesse/#!rest-services-user/getextension" target="_blank"&gt;user.getExtension()&lt;/A&gt;&amp;nbsp;directly in&amp;nbsp;initiateDirectTransfer and still have problem.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;html += "&amp;lt;button class=\"btn btn-primary btn-block\" id=\"btn\" onClick=\"finesse.modules.SampleGadget.initiateDirectTransfer(&lt;A href="https://developer.cisco.com/docs/finesse/#!rest-services-user/getextension" target="_blank"&gt;user.getExtension()&lt;/A&gt;,'8000000000');\"&amp;gt;WRAP CALL &amp;lt;/button&amp;gt;";&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Are you suggesting same or to implement changes in below method.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;initiateDirectTransfer: function (mediaAddress, toAddress) {&lt;BR /&gt;// clear the error message before making the call&lt;BR /&gt;$('#errorMsg').html("");&lt;BR /&gt;// Example of the user make call method&lt;BR /&gt;currentDialog.initiateDirectTransfer(mediaAddress, toAddress, {&lt;BR /&gt;success: makeCallSuccess,&lt;BR /&gt;error: makeCallError&lt;BR /&gt;});&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Please advise.&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 30 Mar 2021 22:38:49 GMT</pubDate>
      <guid>https://community.cisco.com/t5/contact-center/finesse-gadget-directtransfer-failing/m-p/4316452#M11851</guid>
      <dc:creator>smeegada1</dc:creator>
      <dc:date>2021-03-30T22:38:49Z</dc:date>
    </item>
    <item>
      <title>Re: Finesse Gadget DirectTransfer failing</title>
      <link>https://community.cisco.com/t5/contact-center/finesse-gadget-directtransfer-failing/m-p/4316487#M11853</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You cannot use user.getExtension in HTML code. You have to do it in the js part of the code.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I'm talking about this:&lt;/P&gt;
&lt;PRE&gt; initiateDirectTransfer: function (mediaAddress, toAddress) {
// clear the error message before making the call
$('#errorMsg').html("");
// Example of the user make call method
currentDialog.initiateDirectTransfer(mediaAddress, toAddress, {
success: makeCallSuccess,
error: makeCallError
});&lt;/PRE&gt;
&lt;P&gt;You need to remove the mediaAddress parameter and then the currentDialog.initiateDirectTransfer, you need to use user.getExtension(). So it should look like this:&lt;/P&gt;
&lt;PRE&gt; initiateDirectTransfer: function (toAddress) {
// clear the error message before making the call
$('#errorMsg').html("");
// Example of the user make call method
currentDialog.initiateDirectTransfer(user.getExtension(), toAddress, {
success: makeCallSuccess,
error: makeCallError
});&lt;/PRE&gt;
&lt;P&gt;Thanx,&lt;/P&gt;
&lt;P&gt;Denise&lt;/P&gt;</description>
      <pubDate>Wed, 31 Mar 2021 01:01:53 GMT</pubDate>
      <guid>https://community.cisco.com/t5/contact-center/finesse-gadget-directtransfer-failing/m-p/4316487#M11853</guid>
      <dc:creator>dekwan</dc:creator>
      <dc:date>2021-03-31T01:01:53Z</dc:date>
    </item>
    <item>
      <title>Re: Finesse Gadget DirectTransfer failing</title>
      <link>https://community.cisco.com/t5/contact-center/finesse-gadget-directtransfer-failing/m-p/4321282#M11867</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Whilst Denise is correct in that you cannot execute js code in plain html, but I'm pretty sure that isn't your intent.&lt;/P&gt;&lt;P&gt;You appear to be building the html in javascript code, so you simply need to use quotes correctly to execute the call to&amp;nbsp; the user.getExtension() function. At present you are literally adding "user.getExtension()" as part of the HTML.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So change your line to something like this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;html += '&amp;lt;button class="btn btn-primary btn-block" id="btn" onClick="finesse.modules.SampleGadget.initiateDirectTransfer('+&lt;/SPAN&gt;&lt;A href="https://developer.cisco.com/docs/finesse/#!rest-services-user/getextension" target="_blank" rel="nofollow noopener noreferrer"&gt;user.getExtension()+'&lt;/A&gt;&lt;SPAN&gt;,8000000000);"&amp;gt;WRAP CALL &amp;lt;/button&amp;gt;';&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Regards,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Andrew&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Sat, 10 Apr 2021 02:50:34 GMT</pubDate>
      <guid>https://community.cisco.com/t5/contact-center/finesse-gadget-directtransfer-failing/m-p/4321282#M11867</guid>
      <dc:creator>flindersuni</dc:creator>
      <dc:date>2021-04-10T02:50:34Z</dc:date>
    </item>
  </channel>
</rss>

