acrylamid icon indicating copy to clipboard operation
acrylamid copied to clipboard

support translations on entry.type="page"

Open gustabot42 opened this issue 11 years ago • 1 comments

entry.type="page" are not listed in translation views, there is no way to manage translated page with the same logic of "entry"s, with respect to language menu in templates

gustabot42 avatar Oct 17 '13 16:10 gustabot42

a deviation is to use a filter in the views definition, with special tag for pages.

'/:slug/': {'view': 'entry', 'if': lambda e: 'page' in e.tags}, '/:year/:slug/': {'views': ['entry', 'draft'], 'if': lambda e: 'page' not in e.tags},

gustabot42 avatar Oct 17 '13 16:10 gustabot42