1 # coding: utf-8
 2 """
 3 1. Bare-bones model
 4 
 5 This is a basic model with only two non-primary-key fields.
 6 """
 7 from django.db import models
 8 
 9 
10 class Article(models.Model):
11     headline = models.CharField(max_length=100, default='Default headline')
12     pub_date = models.DateTimeField()
13 
14     class Meta:
15         ordering = ('pub_date','headline')
16 
17     def __unicode__(self):
18         return self.headline
19