1 thing we could improve here and in some other places, is to skip the request made to BE, if we already know of FE that the user doesn't have the privilege to do that request. This would also involve disabling some extra buttons in those cases. For example the role filters button in this view, if user doesn't have the privilege to fetch roles.
We already have this logic in some places, but in others we didn't have a concrete understanding of whether a user without a certain privilege should be able to access that resource (For example fetching roles without the correct privilege for use in filters). During the last longer grooming we decided to make sure that privileges are logical and you need to have the corresponding privilege, which means that there are places in FE which can be improved based on this information.
1 thing we could improve here and in some other places, is to skip the request made to BE, if we already know of FE that the user doesn't have the privilege to do that request. This would also involve disabling some extra buttons in those cases. For example the role filters button in this view, if user doesn't have the privilege to fetch roles.
We already have this logic in some places, but in others we didn't have a concrete understanding of whether a user without a certain privilege should be able to access that resource (For example fetching roles without the correct privilege for use in filters). During the last longer grooming we decided to make sure that privileges are logical and you need to have the corresponding privilege, which means that there are places in FE which can be improved based on this information.
This is more of a nice-to-have visual update
Originally posted by @KaarelKa in https://github.com/keeleinstituut/tv-tolkevarav/issues/755#issuecomment-2175594602