from django.contrib import admin
from django.urls import path, include
from pages import views
urlpatterns = [
path('admin/', admin.site.urls),
path('', views.index, name='index'),
path('dashboard/', include(pages.urls)),
]
我正在尝试使用urls.py文件下的include方法将dashboad /请求定向到我的应用urls.py文件,该文件不起作用。
<< img src =“ https://image.soinside.com/eyJ1cmwiOiAiaHR0cHM6Ly9pLnN0YWNrLmltZ3VyLmNvbS9iaUgwTS5wbmcifQ==” alt =“ >
从django.contrib从django.urls导入路径导入管理员,包括从页面导入视图urlpatterns = [path('admin /',admin.site.urls),path('',views.index,name ='index '),路径('...
更改此行:
您好,欢迎来到StackOverflow!