Page not found (404)
当我访问时,我得到了job/list/
。我正在获取详细信息job/my-slug
。它有效但无效JobInfoList
。我错过了什么吗?谢谢
网址
url(r'^job/(?P<slug>[\w-]+)/$', login_required(JobInfoDetail.as_view()), name='jobinfo_detail'),
url(r'^job/list/$', login_required(JobInfoList.as_view()), name='job_list'),
意见
class JobInfoDetail(DetailView):
context_object_name = "jobinfo"
model = JobInfo
class JobInfoList(ListView):
context_object_name = "job_list"
model = JobInfo
def get_queryset(self):
return JobInfo.objects.filter(company__userprofile__user=self.request.user)