Budibase / budibase

Low code platform for building business apps and workflows in minutes. Supports PostgreSQL, MySQL, MariaDB, MSSQL, MongoDB, Rest API, Docker, K8s, and more 🚀
https://budibase.com
Other
22.83k stars 1.58k forks source link

Support view RBAC with forms and cache view definitions #14899

Closed aptkingston closed 1 month ago

aptkingston commented 1 month ago

Description

This PR fixes an issue where forms always attempted to load the definition of their parent table when being used with a view, which is unnecessary and threw permission errors if the user did not also have access to this table.

Another improvement on this PR will massively help reduce API calls to the server - caching view definitions in client memory. We already cache table definitions, but we did not do the same for view definitions. These cannot change at runtime so it is safe to cache. On a table autoscreen with side panels, this reduces 8 duplicate API calls for the view definition into 1.

Before: image

After: image

qa-wolf[bot] commented 1 month ago

QA Wolf here! As you write new code it's important that your test coverage is keeping up. Click here to request test coverage for this PR!