New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[do not merge] Access Tabs for Hub resources (testable with namespaces) #1498
Conversation
73d9907
to
c22d598
Compare
return filters; | ||
}, [t]); | ||
|
||
const view = useInMemoryView<HubAccessRole>({ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@vidyanambiar I am just starting to look at this PR. It does look pretty good.
I could not follow why we need to use the useInMemoryView, neither why the changes were required there. Is it something that we will need to use in order to use the new approach for breadcrumbs?
Could we document this new hook, and how to use them?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@nixocio Thanks for taking a look!
Reason for using the useInMemoryView
hook: Unlike most other list UIs, this one does not have a direct API call for loading the roles table so we cannot utilize usePulpView
or useHubView
which are associated with an API call for fetching the data for the table. We need to use the object-roles
array that is received within the user/team data. So the table is constructed using a static array. useInMemoryView
is a hook provided in the framework to create a PageTable directly from data instead of the API. And it provides the utilities required like selectable rows, filtering etc. I needed to make a small update for making the filtering work correctly for text-based filters.
Something is broken, I can access both Access tabs under namespaces,
(same for groups) (looks like it doesn't set the namespace id in the url) but when I alter the url manually, I still get the same Under Development screen |
@himdel Yes, https://localhost:4102/namespaces/:id/user-access-add-user does not work yet in this PR (same for teams). I'm fixing up the routing for that along with hooking up the add user action in the next PR. |
d1d9d85
to
8d2424b
Compare
Jira Issues
AAH-3052
AAH-3053
AAH-3054
Design changes from existing UI:
Changes in this PR:
useInMemoryView
to handle text-based filters correctlyScreen.Recording.2024-01-24.at.12.42.54.PM.mov