mirror of
https://github.com/nikdoof/test-auth.git
synced 2025-12-14 06:42:16 +00:00
More helpful Blacklist form, allows for users to set the level of blacklist.
This commit is contained in:
@@ -310,8 +310,11 @@ def blacklist_user(request, userid):
|
||||
else:
|
||||
expiry = form.cleaned_data['expiry_date']
|
||||
|
||||
level = form.cleaned_data.get('level', 0)
|
||||
print level
|
||||
|
||||
def blacklist_item(type, value):
|
||||
o = Blacklist(type=type, value=value, source=source, expiry_date=expiry, created_by=request.user, reason=form.cleaned_data['reason'])
|
||||
o = Blacklist(type=type, value=value, level=level, source=source, expiry_date=expiry, created_by=request.user, reason=form.cleaned_data['reason'])
|
||||
o.save()
|
||||
|
||||
for ea in u.eveaccount_set.all():
|
||||
|
||||
Reference in New Issue
Block a user