Monday, September 15, 2014

Django Modeling setting an integer value to a negative value

Is it possible to default a integer to a negative number with Django Modeling?

I did the following, but the value in the display shows 1 not -1


ces_out_servicegrid_polling_interval=models.IntegerField(default=-1, editable=False)

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CAD0urK2mxveDZATVw5d13usWikZa8mg5s-eL4mQqxxpVWMH0Uw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment