﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
15315	modelform_factory should accept widgets argument	SardarNL	nobody	"Since Django 1.2 model forms can override widgets by specifying 'widgets' attribute in Meta, similar to 'fields' or 'exclude'. The modelform_factory doesn't accept widgets, so the only way to specify it is by defining a new parent ModelForm with Meta and giving it as 'form' argument. This is more complex than it needs to be.

The fix is to add new keyword argument widgets=None and add:

{{{
if widgets is not None:
        attrs['widgets'] = widgets
}}}

right after similar if for 'exclude'. This will add 'widgets' attribute to dynamically created Meta.
"	New feature	closed	Forms	1.2	Normal	fixed	dceu2011	AndrewIngram	Ready for checkin	1	0	0	0	0	0
