Skip to main content
# Django Enumerify #

## Installation ##

```
pip install django-enumerify
```

## Usage ##

```
#!python

# .../app/enums.py

from django.utils.translation import gettext as _

from enumerify.enum import Enum

class GroupKind(Enum):
PUBLIC = 0
PRIVATE = 1

i18n = (
_('Public'),
_('Private'),
)

# .../app/models.py

from django.db import models

from enumerify import fields

from .enums import GroupKind

class Group(models.Model):
title = models.CharField(max_length=100)
slug = models.SlugField()
description = models.TextField()
kind = fields.SelectIntegerField(blueprint=GroupKind, default=GroupKind.PUBLIC)
created_at = models.DateTimeField(auto_now_add=True, db_index=True)

def __unicode__(self):
return u"Group: %s" % self.title

```

## Tests ##

```
#!python
$ python testapp/tests/runtests.py
```

Metadata

Release files for django-enumerify 0.5.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for django-enumerify 0.5.2
File Size Uploaded Provenance
django-enumerify-0.5.2.tar.gz 5.6 kB Without provenance Details

Release files / django-enumerify-0.5.2.tar.gz

Download URL django-enumerify-0.5.2.tar.gz
Size 5.6 kB
Tags Source
SHA-256 checksum
How to use checksums
d55b5b37fd1018895445a5773a7c4751c4a6d50ced8857cffa72c4149c3e02f9
BLAKE2b-256 checksum
How to use checksums
5595cd289e07188d7d8ca538fcf5e4ad7cb2548ccc60bdb690da9659006d0753
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Security for django-enumerify 0.5.2

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.5.2 This release

1 release file No provenance

0.5

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page