This is my url:
from views import *
urlpatterns = patterns('',
url(r'^$', BillingView.as_view(), name="index"),
)
and this is the method in my views.py:
class BillingView(BaseCompositeView):
"""
A view that lets you record new billing information. This view includes all
of the forms needed by the users on one page.
"""
# We cannot easily override FormView since this view uses multiple forms
template_name = "billing/base_billing.html"
etc.
Why is my view is not accessible?
Are you using django 1.4? What is the name of the project?
You probably want this for your import:
NameErrormeans you’re referencing something that hasn’t been defined or declared in the current scope.Edit:
To help diagnose the issue, try this:
And just examine if the correct libraries are on your path. You might find that you’ve got a newer version of django in your site-libs folder amongst other things.
When are you getting the NameError? When running from the development server, or a production web server? Please show us the full error and stack trace.