cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
264
Views
0
Helpful
2
Replies

user.makeCall gone?

Occipital
Level 1
Level 1

In CCX 11.5, user.makeCall() always dialed a call but with 12.0 and 12.5, no call is dialed. Release notes say nothing about it - nothing in the logs either. Was this API deprecated from 11 to 12?

1 Accepted Solution

Accepted Solutions

Hey.

 

No it is still there.

Working example on 12.5

 

function makeCall (number) {
clientLogs.log("call to " + number);
user.makeCall(number, { success: makeCallSuccess, error: makeCallError });
}

function makeCallSuccess(rsp) { clientLogs.log("In makeCallSuccess"); }
function makeCallError(rsp) { clientLogs.log("In makeCallError"); }

 

But maybee your init is the "old" way:

Example on the 12.5 way (Can't remember when the init changed. In some api calls, the "old" way still works, but i have seen something isn't working)

init: function () {
            var prefs = new gadgets.Prefs(),
                id = prefs.getString("id");
            var clientLogs = finesse.cslogger.ClientLogger;   // declare clientLogs

            gadgets.window.adjustHeight();

            finesse.clientservices.ClientServices.init(finesse.gadget.Config);
            clientLogs.init(gadgets.Hub, "MyGadget"); //this gadget id will be logged as a part of the message
            user = new finesse.restservices.User({
                id: id,
                onLoad: handleUserLoad,
                onChange: handleUserChange
            });

            containerServices = finesse.containerservices.ContainerServices.init();
            containerServices.addHandler(finesse.containerservices.ContainerServices.Topics.ACTIVE_TAB, function () {
                clientLogs.log("init(): Gadget is now visible and ready to use.");  // log to Finesse logger
                gadgets.window.adjustHeight();
            });
            containerServices.makeActiveTabReq();
        }

  

Please rate helpful posts and if applicable mark "Accept as a Solution".
Thanks, Thomas G. J.

View solution in original post

2 Replies 2

Hey.

 

No it is still there.

Working example on 12.5

 

function makeCall (number) {
clientLogs.log("call to " + number);
user.makeCall(number, { success: makeCallSuccess, error: makeCallError });
}

function makeCallSuccess(rsp) { clientLogs.log("In makeCallSuccess"); }
function makeCallError(rsp) { clientLogs.log("In makeCallError"); }

 

But maybee your init is the "old" way:

Example on the 12.5 way (Can't remember when the init changed. In some api calls, the "old" way still works, but i have seen something isn't working)

init: function () {
            var prefs = new gadgets.Prefs(),
                id = prefs.getString("id");
            var clientLogs = finesse.cslogger.ClientLogger;   // declare clientLogs

            gadgets.window.adjustHeight();

            finesse.clientservices.ClientServices.init(finesse.gadget.Config);
            clientLogs.init(gadgets.Hub, "MyGadget"); //this gadget id will be logged as a part of the message
            user = new finesse.restservices.User({
                id: id,
                onLoad: handleUserLoad,
                onChange: handleUserChange
            });

            containerServices = finesse.containerservices.ContainerServices.init();
            containerServices.addHandler(finesse.containerservices.ContainerServices.Topics.ACTIVE_TAB, function () {
                clientLogs.log("init(): Gadget is now visible and ready to use.");  // log to Finesse logger
                gadgets.window.adjustHeight();
            });
            containerServices.makeActiveTabReq();
        }

  

Please rate helpful posts and if applicable mark "Accept as a Solution".
Thanks, Thomas G. J.

Occipital
Level 1
Level 1

Thank you very much!  user.makeCall() is indeed still there.  Since I'm on UCCX, I changed the manner in which I import the Finesse library.  Having a local copy leads to staleness, and I was shipping Finesse 10.5 with my gadget.  No bueno.  Instead, now, this always gets the latest version:

	<script type="text/javascript" src="/desktop/assets/js/finesse.js"></script>