旧的 url 是 url(r'^edit-(\d+)/', views.user_edit),
新的是用 path 要怎么写!!!
1
itskingname Oct 16, 2018
url(r'^edit-v2-(\d+)/', views.user_edit)
怎么样 |
2
Qzier Oct 16, 2018 urlconf:
path('edit-v2-<int:pk>/', views.user_edit), view def yourview(request, pk): pass |
3
cooioobb OP @itskingname 我想转换的是 path 新的。不过也谢谢啦!
|