I'm using an AngularJS (1.6) SPA with the alfresco-js-api directly in the browser.
Thought I should be able to login with a valid ticket using
var ticket="XXXXXXXXXXXXX"; //valid ticket inside
var alfrescoApiInst = new AlfrescoApi({ provider:'ECM' });
alfrescoApiInst.loginTicket(ticket).then(function (data) {
console.log('valid ticket you are logged in');
}, function (error) {
console.error(error);
});
but this is not working.
But using the ticket in the constructor works
var alfrescoApiInst=new AlfrescoApi({ticketEcm:ticket,hostEcm:hostUrl,provider:"ECM"});
It works with the constructor, but did I miss anything or got it totally wrong?