class Inline(admin.TabularInline): model = MyModel extra = 0 class InlineReadOnly(Inline): can_delete = False def has_add_permission(self, request): return False def get_readonly_fields(self, request, obj=None): result = list(set( [field.name for field in self.opts.local_fields] + [field.name for field in self.opts.local_many_to_many] )) result.remove('id') return result class MyAdmin(admin.ModelAdmin): def add_view(self, request, form_url='', extra_context=None): self.inlines = [Inline, ] return super(MyAdmin, self).add_view(request, form_url, extra_context) def change_view(self, request, object_id, form_url='', extra_context=None): self.inlines = [AttachmentInlineReadOnly, ] return super(InlineReadOnly, self).change_view(request, object_id, form_url, extra_context)