from django.db import models


# Model Field Reference
# https://docs.djangoproject.com/en/1.8/ref/models/fields/


class Post(models.Model):
    title = models.CharField(max_length=63)
    slug = models.SlugField()
    text = models.TextField()
    pub_date = models.DateField()

from django.db import models

from organizer.models import Startup, Tag


# Model Field Reference
# https://docs.djangoproject.com/en/1.8/ref/models/fields/


class Post(models.Model):
    title = models.CharField(max_length=63)
    slug = models.SlugField()
    text = models.TextField()
    pub_date = models.DateField()
    tags = models.ManyToManyField(Tag)
    startups = models.ManyToManyField(Startup)

Define Post model related fields.
Ch03: Define Post model related fields. [skip ci]

    https://docs.djangoproject.com/en/1.8/ref/models/fields/#manytomanyfield

Blog Posts may be about multiple Startups, just as Startups may be
written about multiple times. Posts may also be categorized by multiple
Tags, just as Tags may be used multiple times to categorize different
Posts.
