15 lines
349 B
Python
15 lines
349 B
Python
#coding:utf-8
|
|
from django.contrib import admin
|
|
from django_summernote.admin import SummernoteModelAdmin
|
|
from .models import News
|
|
|
|
|
|
class NewsAdmin(SummernoteModelAdmin):
|
|
model = News
|
|
list_display = ('id', 'category', 'title', 'created', 'updated')
|
|
search_fields = ('title',)
|
|
list_per_page = 10
|
|
|
|
|
|
admin.site.register(News, NewsAdmin)
|