1
0
mirror of https://github.com/peeringdb/peeringdb.git synced 2024-05-11 05:55:09 +00:00

initialize info prefixes{4,6} with 0 #289 (#545)

This commit is contained in:
Matt Griswold
2019-08-16 20:00:55 -05:00
committed by GitHub
parent 500d1a78ed
commit 0d0f682795

View File

@ -791,6 +791,13 @@ class FacilityAdmin(ModelAdminWithVQCtrl, SoftDeleteAdmin):
class NetworkAdminForm(StatusForm):
#set initial values on info_prefixes4 and 6 to 0
#this streamlines the process of adding a network through
#the django admin controlpanel (#289)
info_prefixes4 = baseForms.IntegerField(required=False, initial=0)
info_prefixes6 = baseForms.IntegerField(required=False, initial=0)
def __init__(self, *args, **kwargs):
super(NetworkAdminForm, self).__init__(*args, **kwargs)
fk_handleref_filter(self, "org")