[Answer]-How to use Django inlineformset_factory with custom formset

1👍

Your problem in

ItemFormSet = inlineformset_factory(Packet, Item, form=CreatePacketForm,
                                formset=CreateItemForm,
                                extra=1, max_num=20, can_delete=False)

form kwarg here is to customise formset forms

So it should be:

ItemFormSet = inlineformset_factory(Packet, Item, form=CreateItemForm, extra=1, max_num=20, can_delete=False)

Leave a comment