Merge pull request #194 from nephila/feature/non_required_categories

Make category not required again
This commit is contained in:
Iacopo Spalletti 2016-02-02 09:44:08 +01:00
commit 660fe15291
3 changed files with 26 additions and 1 deletions

View file

@ -3,6 +3,11 @@
History
-------
0.6.4 (unreleased)
++++++++++++++++++
* Make categories non required
0.6.3 (2015-12-22)
++++++++++++++++++

View file

@ -0,0 +1,20 @@
# -*- coding: utf-8 -*-
# Generated by Django 1.9.2 on 2016-02-01 21:35
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('djangocms_blog', '0012_auto_20151220_1734'),
]
operations = [
migrations.AlterField(
model_name='post',
name='categories',
field=models.ManyToManyField(blank=True, related_name='blog_posts', to='djangocms_blog.BlogCategory', verbose_name='category'),
),
]

View file

@ -100,7 +100,7 @@ class Post(ModelMeta, TranslatableModel):
blank=True)
publish = models.BooleanField(_('publish'), default=False)
categories = models.ManyToManyField('djangocms_blog.BlogCategory', verbose_name=_('category'),
related_name='blog_posts',)
related_name='blog_posts', blank=True)
main_image = FilerImageField(verbose_name=_('main image'), blank=True, null=True,
on_delete=models.SET_NULL,
related_name='djangocms_blog_post_image')