mirror of
https://github.com/HamzaSha1/zod-backend.git
synced 2025-07-15 18:07:02 +00:00
jira-17 add junior and send invite mail
This commit is contained in:
@ -6,6 +6,7 @@ from rest_framework.response import Response
|
||||
"""Third party Django app"""
|
||||
from templated_email import send_templated_mail
|
||||
import jwt
|
||||
import string
|
||||
from datetime import datetime
|
||||
from calendar import timegm
|
||||
from uuid import uuid4
|
||||
@ -179,3 +180,10 @@ def get_token(data: dict = dict):
|
||||
'access': access,
|
||||
'refresh': refresh
|
||||
}
|
||||
|
||||
|
||||
def generate_alphanumeric_code(length):
|
||||
alphabet = string.ascii_letters + string.digits
|
||||
code = ''.join(secrets.choice(alphabet) for _ in range(length))
|
||||
return code
|
||||
|
||||
|
Reference in New Issue
Block a user