Description of the bug or enhancement
https://www.cuba-platform.com/discuss/t/multitenancy-plugin-not-filtering-on-tenants-through-entitymanager/10825/3?u=alexbudarov
Newbie users don't realize that multitenancy constraints are applied.
The documentation doesn't say anything about the way you should load data in order for tenant constraints to be applied.
It should be a separate section.
Things we would like to see in the doc:
- Adding multitenancy constraints work on the EntityManager layer for JPQL queries. Multitenancy constraints don't work for native SQL queries.
- If you need auto-applying of tenant constraints, you need to load data with EntityManager/DataManager
- All data loaders use DataManager to load their data
- REST API also uses DataManager to load data
- Reporting: SQL bands don't apply multitenancy constraints. Those can be applied only if you call DataManager queries inside of a Groovy band or use JPQL bands
- Reporting: JPQL bands work with multitenancy constraints.
Description of the bug or enhancement
https://www.cuba-platform.com/discuss/t/multitenancy-plugin-not-filtering-on-tenants-through-entitymanager/10825/3?u=alexbudarov
Newbie users don't realize that multitenancy constraints are applied.
The documentation doesn't say anything about the way you should load data in order for tenant constraints to be applied.
It should be a separate section.
Things we would like to see in the doc: