from django.db import models
from django.utils import timezone

# Create your models here.
class Post (models.Model):
    title = models.CharField(max_length=200) 
    slug  = models.CharField(max_length=200)
    pub_date =models.DateTimeField(default = timezone.now) 

    body = models.TextField()
    class Meta:
       ordering = ('-pub_date',)
    def  __unicode__(self):
        return self.title

