mirror of
https://github.com/Hopiu/wagtail.git
synced 2026-05-12 09:13:14 +00:00
document why CharBlock doesn't need to pass 'label' / 'initial' to CharField
This commit is contained in:
parent
e10d6a99da
commit
02e618cd6e
1 changed files with 1 additions and 1 deletions
|
|
@ -351,7 +351,7 @@ class FieldBlock(Block):
|
|||
|
||||
class CharBlock(FieldBlock):
|
||||
def __init__(self, required=True, help_text=None, max_length=None, min_length=None, **kwargs):
|
||||
# TODO: decide what to do about 'label' and 'initial' parameters to the form field
|
||||
# CharField's 'label' and 'initial' parameters are not exposed, as Block handles that functionality natively (via 'label' and 'default')
|
||||
self.field = forms.CharField(required=required, help_text=help_text, max_length=max_length, min_length=min_length)
|
||||
super(CharBlock, self).__init__(**kwargs)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue