﻿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
28751	Add an error message for inactive user login in AdminAuthenticationForm	SeungWon Kang	nobody	"In admin login site, I found that inactive error message does not exist. (In AuthenticationForm it exists) I know default BackEnd checks the inactive in user_can_authenticate() method, but I think this error message is helpful if using other BackEnd like AllowAllUsersModelBackEnd.

In AuthenticationForm, 
{{{
        def confirm_login_allowed(self, user):
        ...
        if not user.is_active:
            raise forms.ValidationError(
                self.error_messages['inactive'],
                code='inactive',
            )
}}}

but in AdminAuthenticationForm,

{{{
        def confirm_login_allowed(self, user):
        if not user.is_active or not user.is_staff:
            raise forms.ValidationError(
                self.error_messages['invalid_login'],
                code='invalid_login',
                params={'username': self.username_field.verbose_name}
            )
}}}"	Cleanup/optimization	new	contrib.admin	dev	Normal				Unreviewed	0	0	0	0	0	0
