evorepo/main/fields.py
Dan McGee d21d8be018 UserProfile model and fields shuffle
Move this model into the devel/ application, and move the PGPKeyField
which is used only by these models into the application as well. This
involves updating some old migrations along the way to ensure we don't
reference a field class that no longer exists.

Signed-off-by: Dan McGee <dan@archlinux.org>
2012-04-20 11:15:03 -05:00

16 lines
389 B
Python

from django.db import models
class PositiveBigIntegerField(models.BigIntegerField):
_south_introspects = True
def get_internal_type(self):
return "BigIntegerField"
def formfield(self, **kwargs):
defaults = { 'min_value': 0 }
defaults.update(kwargs)
return super(PositiveBigIntegerField, self).formfield(**defaults)
# vim: set ts=4 sw=4 et: