diff --git a/accounts/urls.py b/accounts/urls.py index a76cec5..8144824 100644 --- a/accounts/urls.py +++ b/accounts/urls.py @@ -1,14 +1,18 @@ from django.urls import path, include from .views import * +from dj_rest_auth.views import LoginView, LogoutView app_name = 'accounts' urlpatterns = [ # 일반 로그인 / 회원가입 - path('dj-rest-auth/', include('dj_rest_auth.urls')), - path('dj-rest-auth/registration/', include('dj_rest_auth.registration.urls')), - path('allauth/', include('allauth.urls')), + path('accounts/login', LoginView.as_view(), name='login'), + path('accounts/logout', LogoutView.as_view(), name='logout'), + path('accounts/registration', include('dj_rest_auth.registration.urls')), + # path('dj-rest-auth/', include('dj_rest_auth.urls')), + # path('dj-rest-auth/registration/', include('dj_rest_auth.registration.urls')), + # path('allauth/', include('allauth.urls')), # 회원 탈퇴 - path('accounts/withdraw/', WithdrawUserView.as_view(), name='withdraw'), + path('accounts/withdraw', WithdrawUserView.as_view(), name='withdraw'), ] \ No newline at end of file diff --git a/linenow/settings.py b/linenow/settings.py index 867d5fa..fb986f5 100644 --- a/linenow/settings.py +++ b/linenow/settings.py @@ -239,6 +239,10 @@ # 백엔드 도메인 또는 IP주소 'https://211.188.52.202', 'https://linenow.xyz' + 'http://linenow-manager.co.kr', + 'https://linenow-manager.co.kr', + 'http://linenow.co.kr', + 'https://linenow.co.kr' ] # Celery 관련 설정 diff --git a/manager/serializers.py b/manager/serializers.py index a6d5c25..137f766 100644 --- a/manager/serializers.py +++ b/manager/serializers.py @@ -20,15 +20,15 @@ class BoothWaitingSerializer(serializers.ModelSerializer): class Meta: model = Waiting fields = [ - 'id', 'user', 'party_size', 'waiting_status', 'ready_to_confirm_at', + 'id', 'user', 'party_size', 'waiting_status', 'registered_at','ready_to_confirm_at', 'confirmed_at', 'canceled_at', 'confirm_due_time', 'arrival_due_time' ] # 사용자 정보 반환 (이름과 전화번호) def get_user(self, obj): return { - # "phone_number": obj.user.phone_number, - "name": obj.user.username + "phone_number": obj.user.phone_number, + "name": obj.user.name } # 3분 더한 시간 반환 diff --git a/waiting/urls.py b/waiting/urls.py index 78f9141..722cb15 100644 --- a/waiting/urls.py +++ b/waiting/urls.py @@ -2,7 +2,7 @@ from rest_framework.routers import DefaultRouter from .views import WaitingViewSet -router = DefaultRouter() +router = DefaultRouter(trailing_slash=False) router.register(r'waitings', WaitingViewSet, basename='waiting') urlpatterns = [