Skip to content

Conversation

milkaknap
Copy link

Add support for default value like in django.db.models.fields.Field.
Example:

class MyModel(models.Model):
flags = BitField(flags=(...), default=('flaggy_foo', 'flaggy_bar'))

Add support for default value like in django.db.models.fields.Field. 
Example:

class MyModel(models.Model):
    flags = BitField(flags=(...), default=('flaggy_foo', 'flaggy_bar'))
@johnboiles
Copy link

Q: have you tested this with South migrations? South uses the default parameter when creating new columns.

@milkaknap
Copy link
Author

No, I haven't tested it with South migrations.

Correct indentation and bugfix (if value is tuple or list, it cannot be processed by BitHandler).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants