#7749: local flavor import example bug
---------------------------+------------------------------------------------
Reporter: MihaiD | Owner: nobody
Status: new | Milestone: 1.0
Component: Documentation | Version: SVN
Keywords: localflavor | Stage: Unreviewed
Has_patch: 0 |
---------------------------+------------------------------------------------
This example won't work as expected:
{{{
from django.contrib.localflavor import fr
class MyForm(forms.Form):
my_french_phone_no = fr.forms.FRPhoneNumberField()
}}}
as module fr doesn't appear to have a forms object.
You would need something like
{{{
from django.contrib.localflavor.fr import forms as fr_forms
}}}
or
{{{
import forms
}}}
in __init__.py
Valid for all other localflavor modules
--
Ticket URL: <http://code.djangoproject.com/ticket/7749>
Django Code <http://code.djangoproject.com/>
The web framework for perfectionists with deadlines
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django updates" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/django-updates?hl=en
-~----------~----~----~----~------~----~------~--~---