A Django library to enable semi-isolated multitenancy in your project with users outside the tenant.
Project description
Configuración de Django Multitenant
MULTITENANT_DEFAULT_SCHEMA = 'public' # Esquema predeterminado MULTITENANT_VALIDATION = True # Habilitar validación de acceso al tenant MULTITENANT_SWITCH_METHOD = 'session' # Métodos disponibles: session, subdomain, header
MIDDLEWARE = [ ... 'multitenant.middleware.TenantMiddleware', ... ]
from tenantflow.models import AbstractAccount
class Account(AbstractAccount): """ Extended model for tenant account """ plan = models.CharField(max_length=50, help_text="Plan contratado por el tenant")
from tenantflow.models import AbstractUserAccount
class UserAccount(AbstractUserAccount): """ Relación extendida entre usuarios y tenants con datos adicionales. """ extra_field = models.CharField(max_length=50, help_text="Campo adicional", blank=True)
from tenantflow.models import AbstractUserRole
class UserRole(AbstractUserRole): """ Rol extendido con configuraciones especÃficas del proyecto. """ additional_config = models.JSONField(blank=True, null=True, help_text="Configuraciones extra")
from tenantflow.models import AbstractUserPrivilege
class UserPrivilege(AbstractUserPrivilege): """ Privilegios extendidos para casos de uso especÃficos. """ restricted = models.BooleanField(default=False, help_text="Indica si este privilegio está restringido")
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file django_tenantflow-1.0.0.tar.gz.
File metadata
- Download URL: django_tenantflow-1.0.0.tar.gz
- Upload date:
- Size: 5.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.0.1 CPython/3.12.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c916becbd5ad47f6c1f4d132757faf0cfaf800e1504ccb81a19d7034225f5d56
|
|
| MD5 |
2bdb8cae38fafcb0ffcdeaf337816174
|
|
| BLAKE2b-256 |
18ff55e6b5602bfe7208fcad5a116aba4ef5b73233b968c2d10bad1afa6214d7
|
File details
Details for the file django_tenantflow-1.0.0-py3-none-any.whl.
File metadata
- Download URL: django_tenantflow-1.0.0-py3-none-any.whl
- Upload date:
- Size: 9.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.0.1 CPython/3.12.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5dfc77c633ab5dbbd90b5a4f8c257f763cbf46eabf27eee752047f93ba9d404d
|
|
| MD5 |
78d07002c71231f2d7d5785a45031407
|
|
| BLAKE2b-256 |
d6dee266990c25c110e8a29dbc6130b4d6340ee66101789a08341f2e3095c161
|