Bugfix: Defaut values for template_folder from settings
Bugfix: Extend template_folder length to 200 (including update of migrations)
This commit is contained in:
parent
56cdd5e158
commit
2fa7ebb3b1
3 changed files with 6 additions and 6 deletions
|
@ -14,16 +14,16 @@ class Migration(migrations.Migration):
|
|||
migrations.AddField(
|
||||
model_name='authorentriesplugin',
|
||||
name='template_folder',
|
||||
field=models.CharField(default='Default template', verbose_name='Plugin template', max_length=40, help_text='Select plugin template to load for this instance', choices=[('plugins', 'Default template')]),
|
||||
field=models.CharField(default='Default template', verbose_name='Plugin template', max_length=200, help_text='Select plugin template to load for this instance', choices=[('plugins', 'Default template')]),
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name='genericblogplugin',
|
||||
name='template_folder',
|
||||
field=models.CharField(default='Default template', verbose_name='Plugin template', max_length=40, help_text='Select plugin template to load for this instance', choices=[('plugins', 'Default template')]),
|
||||
field=models.CharField(default='Default template', verbose_name='Plugin template', max_length=200, help_text='Select plugin template to load for this instance', choices=[('plugins', 'Default template')]),
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name='latestpostsplugin',
|
||||
name='template_folder',
|
||||
field=models.CharField(default='Default template', verbose_name='Plugin template', max_length=40, help_text='Select plugin template to load for this instance', choices=[('plugins', 'Default template')]),
|
||||
field=models.CharField(default='Default template', verbose_name='Plugin template', max_length=200, help_text='Select plugin template to load for this instance', choices=[('plugins', 'Default template')]),
|
||||
),
|
||||
]
|
||||
|
|
|
@ -380,10 +380,10 @@ class BasePostPlugin(CMSPlugin):
|
|||
_('current site'), default=True, help_text=_('Select items from the current site only')
|
||||
)
|
||||
template_folder = models.CharField(
|
||||
max_length=40,
|
||||
max_length=200,
|
||||
verbose_name=_('Plugin template'),
|
||||
help_text=_('Select plugin template to load for this instance'),
|
||||
default=BLOG_PLUGIN_TEMPLATE_FOLDERS[0][1],
|
||||
default=BLOG_PLUGIN_TEMPLATE_FOLDERS[0][0],
|
||||
choices=BLOG_PLUGIN_TEMPLATE_FOLDERS
|
||||
)
|
||||
|
||||
|
|
|
@ -136,7 +136,7 @@ def get_setting(name):
|
|||
settings, 'BLOG_LIVEBLOG_PLUGINS', ('LiveblogPlugin',)),
|
||||
|
||||
'BLOG_PLUGIN_TEMPLATE_FOLDERS': getattr(
|
||||
settings, 'BLOG_PLUGIN_TEMPLATE_FOLDERS', (('plugins', _('Default template')),) ),
|
||||
settings, 'BLOG_PLUGIN_TEMPLATE_FOLDERS', (('plugins', _('Default template')),)),
|
||||
|
||||
}
|
||||
return default['BLOG_%s' % name]
|
||||
|
|
Loading…
Reference in a new issue