Remove "Delete Pool" button when a pool is connected to a VIP
Option "Delete Pool" doesn't appear in pool row if there is a VIP created for this pool. This patch set partially fixes bug 1234659 Change-Id: I40357dc76943d644de7782275dde3c34fe7faf42
This commit is contained in:
parent
5918dd58f0
commit
f924bb3d1c
|
@ -83,6 +83,11 @@ class DeletePoolLink(tables.DeleteAction):
|
|||
data_type_singular = _("Pool")
|
||||
data_type_plural = _("Pools")
|
||||
|
||||
def allowed(self, request, datum=None):
|
||||
if datum and datum.vip_id:
|
||||
return False
|
||||
return True
|
||||
|
||||
|
||||
class DeleteMonitorLink(tables.DeleteAction):
|
||||
name = "deletemonitor"
|
||||
|
|
Loading…
Reference in New Issue