R
Renato Teixeira
Guest
Hello, Lars and Edsel! We are having some progress here. By importig pwrapper into progress.js as a workaround we no more need to implement jquery in our angular2 project. A code sample of our injectable JSDO class constructor(private http: Http) { this._serviceURI = ' >'; this._catalogURI = ' >'; this._session = new progress.data.JSDOSession({ serviceURI: this._serviceURI, authenticationModel: progress.data.Session.AUTH_TYPE_FORM }); } public addCatalog(){ //RETURNING PROMISE TO NGMODULE HANDLE IT return this._session.addCatalog(this._catalogURI, 'user', 'pass'); } public login(username?: string, password?: string) { let that = this, promise = that._session.login("user","pass"); promise.done((session, result)=>{ console.log('logged in', result); }) } /** CRUD OPERATIONS OMITTED **/ We get the data and all operations occurs fine, but we get this error at the first load. TypeError: deferred.resolve is not a function at Object.resolve (pwrapper.js:48) at XMLHttpRequest.JSDO._invokeComplete [as onCompleteFn] (progress.js:3123) at XMLHttpRequest.JSD
nReadyStateChangeGeneric (progress.js:6735) at XMLHttpRequest.wrapFn [as _onreadystatechange] (zone.js:1190) at ZoneDelegate.webpackJsonp.1037.ZoneDelegate.invokeTask (zone.js:363) at Object.onInvokeTask (ng_zone.js:264) at ZoneDelegate.webpackJsonp.1037.ZoneDelegate.invokeTask (zone.js:362) at Zone.webpackJsonp.1037.Zone.runTask (zone.js:166) at XMLHttpRequest.ZoneTask.invoke (zone.js:416) Have you any idea what's about?
Continue reading...
Continue reading...