A django model field that generates a random pin of a desired length
Project description
Generates a random pin for your Django model field.
Installation
Install via pip:
$ pip install django-randompinfield
Add to your installed apps:
INSTALLED_APPS = (
...
'randompinfield',
...
)
Usage
Import RandomPinField into your models.py.
from django.db import models
from randompinfield import RandomPinField
class MyModel(models.Model):
slug = RandomPinField(length=3)
The length is an optional argument.
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
File details
Details for the file django-randompinfield-0.4.7.tar.gz.
File metadata
- Download URL: django-randompinfield-0.4.7.tar.gz
- Upload date:
- Size: 1.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
452ef6abc9888c9296f0d8c9f4f3e16a018ded1f6ab805677c13cf5ad4d3a82d
|
|
| MD5 |
3fb5b61187c78dc97c3cc87f330431c3
|
|
| BLAKE2b-256 |
c5da1e86d3339c122031f4bf5aa0d3842b8000801032ee5c781339813d061b10
|