feat: Implement cross-tenant access functionality
- Added configuration for enabling cross-tenant access in the application. - Introduced new API endpoints for listing and searching tenants, accessible only to users with the appropriate permissions. - Updated user and tenant models to include the `can_access_all_tenants` field. - Enhanced the authentication middleware to handle cross-tenant requests and validate user permissions. - Created a new TenantSelector component for selecting tenants in the frontend, improving user experience. - Updated internationalization files to support new tenant-related strings and messages.
This commit is contained in:
@@ -0,0 +1,10 @@
|
||||
-- 000016_add_can_access_all_tenants.down.sql
|
||||
-- Remove can_access_all_tenants column from users table
|
||||
|
||||
BEGIN;
|
||||
|
||||
ALTER TABLE users
|
||||
DROP COLUMN IF EXISTS can_access_all_tenants;
|
||||
|
||||
COMMIT;
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
-- 000016_add_can_access_all_tenants.up.sql
|
||||
-- Add can_access_all_tenants column to users table
|
||||
|
||||
BEGIN;
|
||||
|
||||
ALTER TABLE users
|
||||
ADD COLUMN IF NOT EXISTS can_access_all_tenants BOOLEAN NOT NULL DEFAULT FALSE;
|
||||
|
||||
COMMIT;
|
||||
|
||||
Reference in New Issue
Block a user