Closed nitinkunni closed 6 years ago
V10 version has pretty weird way to do it compared to V8 version. It exposes currentUser and you should be able autowire it. We should improve the code by bringing the ones from V8 version.
V8 version has SecurityUtils methods isCurrentUserInRole
, getUserRoles
and getCurrentUser
which work better #14
Where do I download the code for v8 version?
thanks. I am still trying to understanding AutoWiring. I will download v8 and see if I can get that code integrated into my v10 copy
Currently in the code, the Role setup is only at Page level and handled using the @Secured() annotation in the various view classes. However, I want to use the current user role to do specific control processing. Example show or hide a particular widget in the Dashboard page. How do I do that? The Dashboard view class only seems to expose the OrderRepository and not the current logged in user and role.
Please suggest