This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class MyInline(admin.TabularInline): | |
model = MyModel | |
extra = 0 | |
template = 'admin/edit_inline/list.html' | |
def get_formset(self, request, obj=None, **kwargs): | |
FormSet = super(ActivationKeyInline, self).get_formset(request, obj, **kwargs) | |
class NewFormSet(FormSet): | |
def _construct_forms(self, *args, **kwargs): | |
qs = self.get_queryset() |