<s> """<STR_LIT>""" <EOL> from django . db import models <EOL> from django . utils . translation import ugettext_lazy as _ <EOL> from django . db . models import permalink <EOL> from django . contrib . auth . models import User <EOL> from django . contrib . contenttypes . models import ContentType <EOL> from django . contrib . contenttypes import generic <EOL> from tumblelog . managers import PostManager <EOL> class Post ( models . Model ) : <EOL> """<STR_LIT>""" <EOL> content_type = models . ForeignKey ( ContentType ) <EOL> object_id = models . PositiveIntegerField ( ) <EOL> content_object = generic . GenericForeignKey ( ) <EOL> title = models . CharField ( _ ( '<STR_LIT:title>' ) , max_length = <NUM_LIT:200> ) <EOL> author = models . ForeignKey ( User , <EOL> blank = True , <EOL> null = True , <EOL> verbose_name = _ ( '<STR_LIT>' ) , <EOL> related_name = '<STR_LIT>' ) <EOL> publish = models . DateTimeField ( _ ( '<STR_LIT>' ) ) <EOL> created = models . DateTimeField ( _ ( '<STR_LIT>' ) , auto_now_add = True ) <EOL> modified = models . DateTimeField ( _ ( '<STR_LIT>' ) , auto_now = True ) <EOL> objects = PostManager ( ) <EOL> class Meta : <EOL> verbose_name = _ ( '<STR_LIT>' ) <EOL> verbose_name_plural = _ ( '<STR_LIT>' ) <EOL> db_table = '<STR_LIT>' <EOL> ordering = ( '<STR_LIT>' , ) <EOL> get_latest_by = '<STR_LIT>' <EOL> def __unicode__ ( self ) : <EOL> return u"<STR_LIT:%s>" % self . title <EOL> @ permalink <EOL> def get_absolute_url ( self ) : <EOL> return ( '<STR_LIT>' , None , { <EOL> '<STR_LIT>' : self . pk , <EOL> } ) </s>
