mirror of
https://github.com/django/django.git
synced 2025-10-24 14:16:09 +00:00
git-svn-id: http://code.djangoproject.com/svn/django/branches/newforms-admin@7589 bcc190cf-cafb-0310-a4f2-bffc1f526a37
17 lines
411 B
Python
17 lines
411 B
Python
from django.db import models
|
|
from django.contrib import admin
|
|
|
|
|
|
class Article(models.Model):
|
|
"""
|
|
A simple article to test admin views. Test backwards compabilty.
|
|
"""
|
|
content = models.TextField()
|
|
date = models.DateTimeField()
|
|
|
|
|
|
class ArticleAdmin(admin.ModelAdmin):
|
|
list_display = ('content', 'date')
|
|
list_filter = ('date',)
|
|
|
|
admin.site.register(Article, ArticleAdmin) |