From b4feb79dc7214241ff95ecc27841c47af6d7c05c Mon Sep 17 00:00:00 2001 From: Parsa Nazer Date: Sat, 22 Feb 2025 21:35:50 +0330 Subject: [PATCH] update message otp --- backend/account/views.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/backend/account/views.py b/backend/account/views.py index 86408f1..27e9230 100644 --- a/backend/account/views.py +++ b/backend/account/views.py @@ -39,7 +39,8 @@ class SendOTPView(APIView): try: user, created = User.objects.get_or_create(phone=phone) otp = user.set_otp() - message = f"کد یک بار مصرف : {otp}" + message = f"""به فروشگاه هی ملز خوش اومدی!!❤️🤖 +کد یک بار مصرف شما : {otp}""" sms_api = ghasedak_sms.Ghasedak(api_key="1227eaaddcba72bcb0169b37032cf16ae9ac6ed8b3b7c2768b74e2ee351d1b52gyRe3AGomZRPTNEd") @@ -63,9 +64,7 @@ class SendOTPView(APIView): if response['statusCode'] == 200: return Response({'detail': 'OTP sent successfully'}, status=status.HTTP_200_OK) else: - print('remmber to remove #TODO') - print(response) - return Response({'detail': f'OTP sent successfully {otp}'}, status=status.HTTP_200_OK) + return Response({'detail': f'مشکلی در ارسال کد رخ داد'}, status=status.HTTP_200_OK) # return Response({'detail': response, 'otp_code': otp}, status=status.HTTP_500_INTERNAL_SERVER_ERROR) except User.DoesNotExist: