A lib to help in the creation applications with shared schema without suffering
Documentation
The full documentation is at [ReadTheDocs](https://vinta-django-orgs.readthedocs.io).
Quickstart
Install Django Shared Schema Organizations:
pip install vinta-django-orgs
Add it to your INSTALLED_APPS:
INSTALLED_APPS = (
...
'organizations.apps.OrganizationsConfig',
...
)
Add Django Shared Schema Organizations’s URL patterns:
from django.urls import include, path
urlpatterns = [
...
path('', include('organizations.urls')),
...
]
Add OrganizationMiddleware to your MIDDLEWARES:
MIDDLEWARES = [
# ...
'organizations.middleware.OrganizationMiddleware',
# ...
]
Features
Organizations synced with django requests: The active organization can be extracted from the domain of the request and from a specific http header attribute.
Easy data isolation between organizations: You retrieve and create data the same way you do without organizations. The active organization can be retrieved from the request, and can also be forcedly set.
Partially shared data: If there is data that can be accessed from more then one organization in your applidation, you don’t need to duplicate it.
Running Tests
Does the code actually work?
$ uv sync $ uv run tox
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 vinta_django_orgs-0.0.3.tar.gz.
File metadata
- Download URL: vinta_django_orgs-0.0.3.tar.gz
- Upload date:
- Size: 67.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via:
uv/0.11.18 {"installer":{"name":"uv","version":"0.11.18","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3c0de69fe95b8d8d22dbec60ba56fc84144c098dc53027633bb51fa46238c4e2
|
|
| MD5 |
3e3801e605639cf588ef7434d8603507
|
|
| BLAKE2b-256 |
844d81ca1d5721c00344da37addcf41814d0e216de6fc85763736a0ee12816b2
|
File details
Details for the file vinta_django_orgs-0.0.3-py3-none-any.whl.
File metadata
- Download URL: vinta_django_orgs-0.0.3-py3-none-any.whl
- Upload date:
- Size: 68.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via:
uv/0.11.18 {"installer":{"name":"uv","version":"0.11.18","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
18f94aa92797c2914b5f489f33a99bd0bd1712de88d765e0f9e2b3449a30aac5
|
|
| MD5 |
b3cd546ec859f6e238ad741f75766648
|
|
| BLAKE2b-256 |
839699bc09935958225bff958574b4c54ce2d24d99f8444fda7d1242e9b9fbb0
|