mirror of
https://github.com/i701/sarlink-portal-api.git
synced 2025-06-07 12:06:20 +00:00
Remove unused imports and clean up OTP message formatting in CreateTemporaryUserView
All checks were successful
Build and Push Docker Images / Build and Push Docker Images (push) Successful in 3m29s
All checks were successful
Build and Push Docker Images / Build and Push Docker Images (push) Successful in 3m29s
This commit is contained in:
parent
cdd032ac54
commit
907b713082
@ -1,5 +1,4 @@
|
|||||||
# django imports
|
# django imports
|
||||||
import pprint
|
|
||||||
from django.contrib.auth import login
|
from django.contrib.auth import login
|
||||||
|
|
||||||
# rest_framework imports
|
# rest_framework imports
|
||||||
@ -32,8 +31,7 @@ from typing import cast, Dict, Any
|
|||||||
from django.core.mail import send_mail
|
from django.core.mail import send_mail
|
||||||
from django.db.models import Q
|
from django.db.models import Q
|
||||||
from api.notifications import send_otp
|
from api.notifications import send_otp
|
||||||
from .tasks import add, add_new_devices_to_omada
|
from .tasks import add
|
||||||
from devices.models import Device
|
|
||||||
|
|
||||||
# local apps import
|
# local apps import
|
||||||
from .serializers import (
|
from .serializers import (
|
||||||
@ -197,7 +195,6 @@ class CreateTemporaryUserView(generics.CreateAPIView):
|
|||||||
otp = temp_user.generate_otp()
|
otp = temp_user.generate_otp()
|
||||||
send_otp(
|
send_otp(
|
||||||
str(temp_user.t_mobile),
|
str(temp_user.t_mobile),
|
||||||
otp,
|
|
||||||
f"Your Registration SARLink OTP: {otp}. \nExpires at {formatted_time}. \n\n- SAR Link",
|
f"Your Registration SARLink OTP: {otp}. \nExpires at {formatted_time}. \n\n- SAR Link",
|
||||||
)
|
)
|
||||||
serializer = self.get_serializer(temp_user)
|
serializer = self.get_serializer(temp_user)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user