Hi all,
I've got a model defined similar to below:
class ObjPage(RoutablePageMixin, Page):
body_content = StreamField([
('heading', blocks.CharBlock(classname="full title",icon="title")),
('paragraph', blocks.RichTextBlock()),
('image', ImageChooserBlock(icon="image")),
], null=True, blank=True)
content_panels = Page.content_panels + [
FieldPanel('body', classname="full"),
StreamFieldPanel('body_content'),
]
@route(_(r'^slug/(?P<slug>[\w-]+)/$'))
def detail(self, request, slug):
obj = Items.objects.get(slug=slug)
return render(request, 'detail.html', {'self': self, 'object': obj})
Oddly enough, the routablepageurl templatetag works great using the above route to come up with URLs. However, when I attempt to actually use the URLs in question I am only getting 404s. Any ideas as to what's going on? I added some debugging print statements and they haven't been firing at all.
Thanks!