|
|
|
@ -29,6 +29,9 @@ def dbDashboard(request):
|
|
|
|
|
if request.GET.get("delegated", None) or mnts.count() == 0:
|
|
|
|
|
# if user wants to see rir/lir objects or only has rir/lir mnts, use all available mnts
|
|
|
|
|
mnts = request.user.maintainer_set.all()
|
|
|
|
|
showDelegations = True
|
|
|
|
|
else:
|
|
|
|
|
showDelegations = False
|
|
|
|
|
|
|
|
|
|
hasDelegations = request.user.maintainer_set.filter(Q(rir=True) | Q(lir=True)).count() > 0
|
|
|
|
|
|
|
|
|
@ -64,7 +67,7 @@ def dbDashboard(request):
|
|
|
|
|
mntForm = MntInitialForm(user=request.user, prefix="mnt", initial={'handle': 'AUTO', 'description': 'Primary maintainer of %s' % request.user.username})
|
|
|
|
|
contactForm = ContactInitialForm(user=request.user, initial={'handle': 'AUTO', 'name': request.user.username.capitalize()}, prefix='contact')
|
|
|
|
|
|
|
|
|
|
return render(request, "whoisdb/overview.html", {"mnts": mnts, "contacts": contacts, "mntForm": mntForm, "contactForm": contactForm, "netblocks": netblocks, "asblocks": asblocks, "asnumbers": asnumbers, 'hasDelegations': hasDelegations})
|
|
|
|
|
return render(request, "whoisdb/overview.html", {"mnts": mnts, "contacts": contacts, "mntForm": mntForm, "contactForm": contactForm, "netblocks": netblocks, "asblocks": asblocks, "asnumbers": asnumbers, 'hasDelegations': hasDelegations, "showDelegations": showDelegations})
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
def showHandle(request, handle):
|
|
|
|
|