intro_Django/ProyectoWeb/blog/admin.py

17 lines
384 B
Python
Raw Normal View History

2020-11-21 02:49:07 -03:00
from django.contrib import admin
from .models import Categoria, Entrada
# Register your models here.
class CategoriaAdmin(admin.ModelAdmin):
readonly_fields = ('created', 'updated')
class EntradasAdmin(admin.ModelAdmin):
readonly_fields = ('created', 'updated')
admin.site.register(Categoria, CategoriaAdmin)
admin.site.register(Entrada, EntradasAdmin)