[progress Communities] [progress Openedge Abl] Forum Post: [kendo For Angular] How To...

  • Thread starter Thread starter Martin Velikov
  • Start date Start date
Status
Not open for further replies.
M

Martin Velikov

Guest
Hello, I am using Kendo for Angular and OpenEdge 11.63 Currently I have 2 services: 1. ...MyApp/static/CrudService.json 2. ...MyApp/static/ReadOnlyService.json I have 2 separate users: 1. admin with ROLE_PSCAdmin 2. user with ROLE_PSCUser I separeted their login permissions and user (ROLE_PSCUser) can login only in ReadOnlyService.json and is working. I don't know how to make the service in the front-end angular project. I am having JSDOSession which is working with one service. const _serviceURI = ' http://IP:8850/MyApp'; const _catalogURI = _serviceURI + '/static/'+ 'Crud' + 'Service.json'; const _catalogURI2 = _serviceURI + '/static/'+ 'OnlyRead' + 'Service.json'; const authenticationModel = progress.data.Session.AUTH_TYPE_FORM; let opts: progress.data.JSDOSessionOptions = { serviceURI: _serviceURI, authenticationModel: authenticationModel } // create a new session object let _session = new progress.data.JSDOSession(opts); this.jsdoPromise = new Promise((resolve, reject) => { _session.login("username", "password").done(function (_session: progress.data.JSDOSession, result: any, info: any) { console.log("session.login"); _session.addCatalog(_catalogURI).then(() => { console.log("ADMIN"); resolve(self.jsdo = new progress.data.JSDO(self.tableName)); }); }) }) The first Idea I had was to get the ROLE_ from the server but I have no success. I tryed with this: https://documentation.progress.com/output/ua/OpenEdge_latest/index.html#page/asadm%2Finterpreting-the-appserverstatus-section.html%23 My second idea is to _session.login() and then to try one by one every _catalogURI and this way to get the user ROLE_, but I have no success as well. Any suggestions? Thanks, Martin

Continue reading...
 
Status
Not open for further replies.
Back
Top