28
Views
4
Comments
Reactive Web and Roles
Question

Quick question,

I am creating customer logon with Reactive web. I know how to do it with Traditional but what would be the best approach for authentication. From what I see I cannot use the Check Role on the server side. Any thoughts?


Thanks

Otis Brown wrote:

Quick question,

I am creating customer logon with Reactive web. I know how to do it with Traditional but what would be the best approach for authentication. From what I see I cannot use the Check Role on the server side. Any thoughts?


Thanks

Hi,

For reactive web app, it separates the client action and server action. And, the check role is server action, therefore, you need to do things like the images and implement the logic to return the check role result. Btw, you can use if in you client action and UI

 Hope this help

mvp_badge
MVP

Hi Otis,

Ceck this clientnsidenjavascript API, use $roles.NameOfTheRole instead of $roles.$parameters.RoleName

So if you have a role defined named Employee then use $roles.Employee 

please be aware that client side UserRoles can easily be tampered with in browsers dev tools, so always validate server side to when you get or store data.

Regards,

Daniel

Daniël Kuhlmann wrote:

Hi Otis,

Ceck this clientnsidenjavascript API, use $roles.NameOfTheRole instead of $roles.$parameters.RoleName

So if you have a role defined named Employee then use $roles.Employee 

please be aware that client side UserRoles can easily be tampered with in browsers dev tools, so always validate server side to when you get or store data.

Regards,

Daniel

Just a small side-step from this discussion (since it is already answered by you for the client side part). Why on earth are these functions not available as Client Actions? Does anyone know the logic behind the choices on why a lot of client side functionality is not available in an OutSystems native manner?

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.