﻿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
26220	Allow SingleObjectTemplateResponseMixin to get a template_name from form_class if it's a ModelForm	Guilhem Saurel	Clifford Gama	"In this case, we have to set twice the model (or manually set template_name):

{{{
class ArticleForm(ModelForm):
    class Meta:
        model = Article
        fields = ['author', 'date']
    
    def clean_date(self):
        ...

class ArticleCreateView(CreateView):
    form_class = ArticleForm
    model = Article  # Redundant
}}}

A PoC to fix this is available here: https://github.com/nim65s/django/commit/614dae5022bb5c7d8ad0336e17ef1e0c84b9dbbf"	New feature	assigned	Generic views	1.9	Normal			berker.peksag@… Clifford Gama	Accepted	1	0	0	1	0	0
