Im new to Django and trying to implement jet dashboard. I keep getting the following error. I looked at other resolution but none have worked for me. please help!
This is the url.py file form my app main:
urlpatterns = [
path('', home, name='home'),
path('login_view/', login_view, name='login_view'),
path('jet.dashboard/', include('jet.dashboard.urls')),
# ... the rest of your URLconf goes here...
]
This is the url.py for the projects main folder
urlpatterns = [
path('jet/', include('jet.urls', 'jet')), # Django JET URLS
path('jet.dashboard/', include('jet.dashboard.urls', 'jet.dashboard')), # Django
This is my view that suppose to render my jet dashboard:
if user is not None:
login(request, user)
# Check whether UserProfile exists
try:
profile = user.courses_user_profile
except UserProfile.DoesNotExist:
# Handle missing UserProfile (e.g., create one or return an error)
profile = UserProfile.objects.create(user=user)
# ... other handling ...
return redirect(reverse('jet.dashboard'))