Django queryset and serialization together
Project description
django-qserializer
Django QSerializer started as an internal Buser project to improve our serialization process.
Database queries and serialization are two separated step, but really ORM coupled. Relationships must be fetched from database before serialization, but Django don't have an easy way to define that.
from django.db import models
from django_qserializer import SerializableManager
class Company(models.Model):
name = models.CharField(max_length=64)
class Bus(models.Model):
company = models.ForeignKey(Company, on_delete=models.SET_NULL)
objects = SerializableManager()
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
django_qserializer-0.1.tar.gz
(5.1 kB
view hashes)
Built Distribution
Close
Hashes for django_qserializer-0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9b1b55f123ba9a1a552bf19255435f37e370100f3ee2e85d321555213edd85c0 |
|
MD5 | 950087bbc5e20901fa12ebebbb319115 |
|
BLAKE2b-256 | 54af87cf2c15a4f5e07f5d6409dd49f5ac2c64754536df50e313ce69fa177b1b |