mirror of
https://github.com/TakeusV1/flask_ipam.git
synced 2026-10-13 17:15:33 +02:00
Update r_base.py
This commit is contained in:
1 parent
4628df54e1
commit
bcd6469572
1 file changed
+6
-6
@@ -152,18 +152,18 @@ def allocation_edit_modal(net_id, ipv4):
|
||||
# Special Allocation
|
||||
if int(form.is_special.data) == 1:
|
||||
# DHCP
|
||||
db_alloc.is_dhcp == True
|
||||
db_alloc.is_gateway == False
|
||||
db_alloc.is_dhcp = True
|
||||
db_alloc.is_gateway = False
|
||||
db_alloc.hostname = None
|
||||
db_alloc.description = "DHCP Allocation"
|
||||
elif int(form.is_special.data) == 2:
|
||||
# Gateway
|
||||
db_alloc.is_dhcp == False
|
||||
db_alloc.is_gateway == True
|
||||
db_alloc.is_dhcp = False
|
||||
db_alloc.is_gateway = True
|
||||
else:
|
||||
# None
|
||||
db_alloc.is_dhcp == False
|
||||
db_alloc.is_gateway == False
|
||||
db_alloc.is_dhcp = False
|
||||
db_alloc.is_gateway = False
|
||||
|
||||
db.session.commit()
|
||||
flash("Allocation Updated", 'success')
|
||||
|
||||
Reference in new issue
Block a user