kopia lustrzana https://github.com/wagtail/wagtail
Fixed capitalisation of field verbose names
rodzic
96240288f8
commit
f698c2fb52
|
@ -14,85 +14,79 @@ class Migration(migrations.Migration):
|
|||
migrations.AlterField(
|
||||
model_name='grouppagepermission',
|
||||
name='group',
|
||||
field=models.ForeignKey(related_name='page_permissions', verbose_name='group', to='auth.Group'),
|
||||
field=models.ForeignKey(verbose_name='Group', related_name='page_permissions', to='auth.Group'),
|
||||
preserve_default=True,
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name='grouppagepermission',
|
||||
name='page',
|
||||
field=models.ForeignKey(related_name='group_permissions', verbose_name='page', to='wagtailcore.Page'),
|
||||
field=models.ForeignKey(verbose_name='Page', related_name='group_permissions', to='wagtailcore.Page'),
|
||||
preserve_default=True,
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name='grouppagepermission',
|
||||
name='permission_type',
|
||||
field=models.CharField(max_length=20, verbose_name='permission type', choices=[('add', 'Add/edit pages you own'), ('edit', 'Add/edit any page'), ('publish', 'Publish any page'), ('lock', 'Lock/unlock any page')]),
|
||||
field=models.CharField(choices=[('add', 'Add/edit pages you own'), ('edit', 'Add/edit any page'), ('publish', 'Publish any page'), ('lock', 'Lock/unlock any page')], max_length=20, verbose_name='Permission type'),
|
||||
preserve_default=True,
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name='page',
|
||||
name='search_description',
|
||||
field=models.TextField(verbose_name='search description', blank=True),
|
||||
preserve_default=True,
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name='page',
|
||||
name='seo_title',
|
||||
field=models.CharField(help_text="Optional. 'Search Engine Friendly' title. This will appear at the top of the browser window.", max_length=255, verbose_name='page title', blank=True),
|
||||
field=models.TextField(blank=True, verbose_name='Search description'),
|
||||
preserve_default=True,
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name='page',
|
||||
name='show_in_menus',
|
||||
field=models.BooleanField(default=False, help_text='Whether a link to this page will appear in automatically generated menus', verbose_name='show in menus'),
|
||||
field=models.BooleanField(default=False, help_text='Whether a link to this page will appear in automatically generated menus', verbose_name='Show in menus'),
|
||||
preserve_default=True,
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name='page',
|
||||
name='slug',
|
||||
field=models.SlugField(help_text='The name of the page as it will appear in URLs e.g http://domain.com/blog/[my-slug]/', max_length=255, verbose_name='slug'),
|
||||
field=models.SlugField(help_text='The name of the page as it will appear in URLs e.g http://domain.com/blog/[my-slug]/', max_length=255, verbose_name='Slug'),
|
||||
preserve_default=True,
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name='page',
|
||||
name='title',
|
||||
field=models.CharField(help_text="The page title as you'd like it to be seen by the public", max_length=255, verbose_name='title'),
|
||||
field=models.CharField(help_text="The page title as you'd like it to be seen by the public", max_length=255, verbose_name='Title'),
|
||||
preserve_default=True,
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name='pageviewrestriction',
|
||||
name='page',
|
||||
field=models.ForeignKey(related_name='view_restrictions', verbose_name='page', to='wagtailcore.Page'),
|
||||
field=models.ForeignKey(verbose_name='Page', related_name='view_restrictions', to='wagtailcore.Page'),
|
||||
preserve_default=True,
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name='pageviewrestriction',
|
||||
name='password',
|
||||
field=models.CharField(max_length=255, verbose_name='password'),
|
||||
field=models.CharField(max_length=255, verbose_name='Password'),
|
||||
preserve_default=True,
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name='site',
|
||||
name='hostname',
|
||||
field=models.CharField(max_length=255, verbose_name='hostname', db_index=True),
|
||||
field=models.CharField(db_index=True, max_length=255, verbose_name='Hostname'),
|
||||
preserve_default=True,
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name='site',
|
||||
name='is_default_site',
|
||||
field=models.BooleanField(default=False, help_text='If true, this site will handle requests for all other hostnames that do not have a site entry of their own', verbose_name='is default site'),
|
||||
field=models.BooleanField(default=False, help_text='If true, this site will handle requests for all other hostnames that do not have a site entry of their own', verbose_name='Is default site'),
|
||||
preserve_default=True,
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name='site',
|
||||
name='port',
|
||||
field=models.IntegerField(default=80, help_text='Set this to something other than 80 if you need a specific port number to appear in URLs (e.g. development on port 8000). Does not affect request handling (so port forwarding still works).', verbose_name='port'),
|
||||
field=models.IntegerField(default=80, help_text='Set this to something other than 80 if you need a specific port number to appear in URLs (e.g. development on port 8000). Does not affect request handling (so port forwarding still works).', verbose_name='Port'),
|
||||
preserve_default=True,
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name='site',
|
||||
name='root_page',
|
||||
field=models.ForeignKey(related_name='sites_rooted_here', verbose_name='root page', to='wagtailcore.Page'),
|
||||
field=models.ForeignKey(verbose_name='Root page', related_name='sites_rooted_here', to='wagtailcore.Page'),
|
||||
preserve_default=True,
|
||||
),
|
||||
]
|
||||
|
|
|
@ -50,10 +50,10 @@ class SiteManager(models.Manager):
|
|||
|
||||
@python_2_unicode_compatible
|
||||
class Site(models.Model):
|
||||
hostname = models.CharField(verbose_name=_('hostname'), max_length=255, db_index=True)
|
||||
port = models.IntegerField(verbose_name=_('port'), default=80, help_text=_("Set this to something other than 80 if you need a specific port number to appear in URLs (e.g. development on port 8000). Does not affect request handling (so port forwarding still works)."))
|
||||
root_page = models.ForeignKey('Page', verbose_name=_('root page'), related_name='sites_rooted_here')
|
||||
is_default_site = models.BooleanField(verbose_name=_('is default site'), default=False, help_text=_("If true, this site will handle requests for all other hostnames that do not have a site entry of their own"))
|
||||
hostname = models.CharField(verbose_name=_('Hostname'), max_length=255, db_index=True)
|
||||
port = models.IntegerField(verbose_name=_('Port'), default=80, help_text=_("Set this to something other than 80 if you need a specific port number to appear in URLs (e.g. development on port 8000). Does not affect request handling (so port forwarding still works)."))
|
||||
root_page = models.ForeignKey('Page', verbose_name=_('Root page'), related_name='sites_rooted_here')
|
||||
is_default_site = models.BooleanField(verbose_name=_('Is default site'), default=False, help_text=_("If true, this site will handle requests for all other hostnames that do not have a site entry of their own"))
|
||||
|
||||
class Meta:
|
||||
unique_together = ('hostname', 'port')
|
||||
|
@ -263,8 +263,8 @@ class PageBase(models.base.ModelBase):
|
|||
|
||||
@python_2_unicode_compatible
|
||||
class Page(six.with_metaclass(PageBase, MP_Node, ClusterableModel, index.Indexed)):
|
||||
title = models.CharField(verbose_name=_('title'), max_length=255, help_text=_("The page title as you'd like it to be seen by the public"))
|
||||
slug = models.SlugField(verbose_name=_('slug'), max_length=255, help_text=_("The name of the page as it will appear in URLs e.g http://domain.com/blog/[my-slug]/"))
|
||||
title = models.CharField(verbose_name=_('Title'), max_length=255, help_text=_("The page title as you'd like it to be seen by the public"))
|
||||
slug = models.SlugField(verbose_name=_('Slug'), max_length=255, help_text=_("The name of the page as it will appear in URLs e.g http://domain.com/blog/[my-slug]/"))
|
||||
# TODO: enforce uniqueness on slug field per parent (will have to be done at the Django
|
||||
# level rather than db, since there is no explicit parent relation in the db)
|
||||
content_type = models.ForeignKey('contenttypes.ContentType', related_name='pages')
|
||||
|
@ -273,9 +273,9 @@ class Page(six.with_metaclass(PageBase, MP_Node, ClusterableModel, index.Indexed
|
|||
url_path = models.CharField(max_length=255, blank=True, editable=False)
|
||||
owner = models.ForeignKey(settings.AUTH_USER_MODEL, null=True, blank=True, editable=False, on_delete=models.SET_NULL, related_name='owned_pages')
|
||||
|
||||
seo_title = models.CharField(verbose_name=_("page title"), max_length=255, blank=True, help_text=_("Optional. 'Search Engine Friendly' title. This will appear at the top of the browser window."))
|
||||
show_in_menus = models.BooleanField(verbose_name=_('show in menus'), default=False, help_text=_("Whether a link to this page will appear in automatically generated menus"))
|
||||
search_description = models.TextField(verbose_name=_('search description'), blank=True)
|
||||
seo_title = models.CharField(verbose_name=_("Page title"), max_length=255, blank=True, help_text=_("Optional. 'Search Engine Friendly' title. This will appear at the top of the browser window."))
|
||||
show_in_menus = models.BooleanField(verbose_name=_('Show in menus'), default=False, help_text=_("Whether a link to this page will appear in automatically generated menus"))
|
||||
search_description = models.TextField(verbose_name=_('Search description'), blank=True)
|
||||
|
||||
go_live_at = models.DateTimeField(verbose_name=_("Go live date/time"), help_text=_("Please add a date-time in the form YYYY-MM-DD hh:mm."), blank=True, null=True)
|
||||
expire_at = models.DateTimeField(verbose_name=_("Expiry date/time"), help_text=_("Please add a date-time in the form YYYY-MM-DD hh:mm."), blank=True, null=True)
|
||||
|
@ -1171,9 +1171,9 @@ PAGE_PERMISSION_TYPE_CHOICES = [
|
|||
|
||||
|
||||
class GroupPagePermission(models.Model):
|
||||
group = models.ForeignKey(Group, verbose_name=_('group'), related_name='page_permissions')
|
||||
page = models.ForeignKey('Page', verbose_name=_('page'), related_name='group_permissions')
|
||||
permission_type = models.CharField(verbose_name=_('permission type'), max_length=20, choices=PAGE_PERMISSION_TYPE_CHOICES)
|
||||
group = models.ForeignKey(Group, verbose_name=_('Group'), related_name='page_permissions')
|
||||
page = models.ForeignKey('Page', verbose_name=_('Page'), related_name='group_permissions')
|
||||
permission_type = models.CharField(verbose_name=_('Permission type'), max_length=20, choices=PAGE_PERMISSION_TYPE_CHOICES)
|
||||
|
||||
class Meta:
|
||||
unique_together = ('group', 'page', 'permission_type')
|
||||
|
@ -1398,5 +1398,5 @@ class PagePermissionTester(object):
|
|||
|
||||
|
||||
class PageViewRestriction(models.Model):
|
||||
page = models.ForeignKey('Page', verbose_name=_('page'), related_name='view_restrictions')
|
||||
password = models.CharField(verbose_name=_('password'), max_length=255)
|
||||
page = models.ForeignKey('Page', verbose_name=_('Page'), related_name='view_restrictions')
|
||||
password = models.CharField(verbose_name=_('Password'), max_length=255)
|
||||
|
|
|
@ -14,19 +14,19 @@ class Migration(migrations.Migration):
|
|||
migrations.AlterField(
|
||||
model_name='userprofile',
|
||||
name='approved_notifications',
|
||||
field=models.BooleanField(default=True, help_text='Receive notification when your page edit is approved', verbose_name='approved notifications'),
|
||||
field=models.BooleanField(default=True, help_text='Receive notification when your page edit is approved', verbose_name='Approved notifications'),
|
||||
preserve_default=True,
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name='userprofile',
|
||||
name='rejected_notifications',
|
||||
field=models.BooleanField(default=True, help_text='Receive notification when your page edit is rejected', verbose_name='rejected notifications'),
|
||||
field=models.BooleanField(default=True, help_text='Receive notification when your page edit is rejected', verbose_name='Rejected notifications'),
|
||||
preserve_default=True,
|
||||
),
|
||||
migrations.AlterField(
|
||||
model_name='userprofile',
|
||||
name='submitted_notifications',
|
||||
field=models.BooleanField(default=True, help_text='Receive notification when a page is submitted for moderation', verbose_name='submitted notifications'),
|
||||
field=models.BooleanField(default=True, help_text='Receive notification when a page is submitted for moderation', verbose_name='Submitted notifications'),
|
||||
preserve_default=True,
|
||||
),
|
||||
]
|
||||
|
|
|
@ -11,19 +11,19 @@ class UserProfile(models.Model):
|
|||
user = models.OneToOneField(settings.AUTH_USER_MODEL)
|
||||
|
||||
submitted_notifications = models.BooleanField(
|
||||
verbose_name=_('submitted notifications'),
|
||||
verbose_name=_('Submitted notifications'),
|
||||
default=True,
|
||||
help_text=_("Receive notification when a page is submitted for moderation")
|
||||
)
|
||||
|
||||
approved_notifications = models.BooleanField(
|
||||
verbose_name=_('approved notifications'),
|
||||
verbose_name=_('Approved notifications'),
|
||||
default=True,
|
||||
help_text=_("Receive notification when your page edit is approved")
|
||||
)
|
||||
|
||||
rejected_notifications = models.BooleanField(
|
||||
verbose_name=_('rejected notifications'),
|
||||
verbose_name=_('Rejected notifications'),
|
||||
default=True,
|
||||
help_text=_("Receive notification when your page edit is rejected")
|
||||
)
|
||||
|
|
Ładowanie…
Reference in New Issue