<s> from django . core import validators <EOL> from django . db import models <EOL> from django . contrib . sites . models import Site <EOL> from django . utils . translation import gettext_lazy as _ <EOL> class FlatPage ( models . Model ) : <EOL> url = models . CharField ( _ ( '<STR_LIT>' ) , maxlength = <NUM_LIT:100> , validator_list = [ validators . isAlphaNumericURL ] , <EOL> help_text = _ ( "<STR_LIT>" ) ) <EOL> title = models . CharField ( _ ( '<STR_LIT:title>' ) , maxlength = <NUM_LIT:200> ) <EOL> content = models . TextField ( _ ( '<STR_LIT:content>' ) ) <EOL> enable_comments = models . BooleanField ( _ ( '<STR_LIT>' ) ) <EOL> template_name = models . CharField ( _ ( '<STR_LIT>' ) , maxlength = <NUM_LIT> , blank = True , <EOL> help_text = _ ( "<STR_LIT>" ) ) <EOL> registration_required = models . BooleanField ( _ ( '<STR_LIT>' ) , help_text = _ ( "<STR_LIT>" ) ) <EOL> sites = models . ManyToManyField ( Site ) <EOL> class Meta : <EOL> db_table = '<STR_LIT>' <EOL> verbose_name = _ ( '<STR_LIT>' ) <EOL> verbose_name_plural = _ ( '<STR_LIT>' ) <EOL> ordering = ( '<STR_LIT:url>' , ) <EOL> class Admin : <EOL> fields = ( <EOL> ( None , { '<STR_LIT>' : ( '<STR_LIT:url>' , '<STR_LIT:title>' , '<STR_LIT:content>' , '<STR_LIT>' ) } ) , <EOL> ( '<STR_LIT>' , { '<STR_LIT>' : '<STR_LIT>' , '<STR_LIT>' : ( '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' ) } ) , <EOL> ) <EOL> list_filter = ( '<STR_LIT>' , ) <EOL> search_fields = ( '<STR_LIT:url>' , '<STR_LIT:title>' ) <EOL> def __str__ ( self ) : <EOL> return "<STR_LIT>" % ( self . url , self . title ) <EOL> def get_absolute_url ( self ) : <EOL> return self . url </s>
