You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

24 lines
706 B

4 years ago
  1. from django.contrib import admin
  2. # Register your models here.
  3. from .models import Project, HonoraryCertificate, Library, IFG #, ELitStip
  4. # @admin.register(Project)
  5. # class ProjectAdmin(admin.ModelAdmin):
  6. # #fields = ('pid',)
  7. # readonly_fields = ('pid',)
  8. # # list_display =('pid',)
  9. # def __init__(self, *args, **kwargs):
  10. # super().__init__(*args, **kwargs)
  11. # self.fields = super().get_all_field_names() + 'pid'
  12. # return self
  13. @admin.register(Project)
  14. class ProjectAdmin(admin.ModelAdmin):
  15. readonly_fields = ('pid',)
  16. admin.site.register([
  17. HonoraryCertificate,
  18. Library,
  19. IFG,
  20. ])