django-blog-zinnia / cmsplugin-zinnia

Bridge between django-blog-zinnia and django-cms
BSD 3-Clause "New" or "Revised" License
53 stars 46 forks source link

Custom template does not render in latest entries, it defaults to entry_list.html #66

Open khrizo opened 6 years ago

khrizo commented 6 years ago

django 1.11.12 django cms 3.5.xx

CMSPLUGIN_ZINNIA_TEMPLATES = [ ('cmsplugin_zinnia/entry_custom.html', 'Entry custom'), ]

in class CMSLatestEntriesPlugin(ZinniaCMSPluginBase): I added

def get_render_template(self, context, instance, placeholder):
    return instance.template_to_render or 'cmsplugin_zinnia/entry_list.html'

seems to be working.