Django Num2Fa
django-num2fa is a wrapper around num2fa package which provides a set of filters to convert numbers to Persian numbers and words.
Installation
pip install -U django-num2fa
That's it!
Usage
First, add django_num2fa inside your INSTALLED_APPS:
INSTALLED_APPS = [
'django.contrib.admin',
'django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.messages',
'django.contrib.staticfiles',
'django_num2fa',
# other packages
]
load num2fa inside your template:
{% load num2fa %}
then, wherever you have a number in your code template, pipe it with one of the fa_numbers, fa_words, and fa_ordinal_words template filters.
{% load num2fa %}
{{ number | fa_numbers }}
{{ number | fa_words }}
{{ number | fa_ordinal_words }}
Contributing
We welcome contributions! To learn how you can contribute, please check the Contributing document.
License
This work is licensed under the terms of the GNU Affero General Public License (AGPL).
Metadata
Release files for django-num2fa 1.0.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| django-num2fa-1.0.3.tar.gz | 15.8 kB | Without provenance | Details for django-num2fa-1.0.3.tar.gz |
Release files / django-num2fa-1.0.3.tar.gz
| Download URL | django-num2fa-1.0.3.tar.gz |
|---|---|
| Size | 15.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
614a1f700e0787a0a80593d422705f1fe3f4785f1b3e94606a0cd534e37f64d6
|
|
BLAKE2b-256 checksum How to use checksums |
15853b3f99ef37b5bf2feb205dac30ace21b993f990cd07e4f4b44d499a365e2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.10.12
|
Security for django-num2fa 1.0.3
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.