Django Publishable Model¶
Make your models publishable in an easy way, the admin will be smart and easily configurable
Documentation¶
The full documentation is at https://django-publishable-model.readthedocs.io.
Quickstart¶
Install Django Publishable Model:
pip install django-publishable-model
Add it to your INSTALLED_APPS:
INSTALLED_APPS = (
...
'publishable_model',
...
)
Features¶
Handle of Django Model’s publication.
Example of usage¶
from publishable_model.models import PublishableModel
class News(PublishableModel, models.Model):
title = models.CharField(_("Title"), max_length=64, )
content = models.TextField(_("Content"), blank=True, default="")
def __str__(self):
return self.title
class Meta(PublishableModel.Meta):
verbose_name = _('News')
verbose_name_plural = _('News')
Running Tests¶
Does the code actually work?
source <YOURVIRTUALENV>/bin/activate
(myenv) $ pip install tox
(myenv) $ tox
or
./manage.py test tests
Development commands¶
- ::
pip install -r requirements_dev.txt invoke -l
Credits¶
Tools used in rendering this package: