Files

13 lines
351 B
Python
Raw Permalink Normal View History

2026-01-18 11:59:48 +03:30
import string
import random
from authentication.models import SystemUserProfile
from general_urls import base_user_gate_way_id
while (True):
res = ''.join(random.choices(string.ascii_lowercase + string.digits, k=5))
res = base_user_gate_way_id + res
if not SystemUserProfile.objects.filter(user_gate_way_id=res).exists():
break