from django.urls import path
from django.views.decorators.csrf import csrf_exempt
from . import views

urlpatterns = [

    # Session Purchase Order

    path("create-stripe-checkout-session-purchase/",
        csrf_exempt(views.CreateStripeCheckoutSessionPurchaserOrderView.as_view())),
    
    path("expire-stripe-checkout-session-purchase-order/",
        csrf_exempt(views.ExpireStripeCheckoutSessionPurchaseOrderView.as_view())),
    
    path('sessionpurchaseorder/', views.SessionPurchaseOrderList.as_view()),
    path('sessionpurchaseorder/<int:pk>', views.SessionPurchaseOrderDetail.as_view()),

    path('sessionshippingitem/', views.SessionShippingItemList.as_view()),
    path('sessionshippingitem/<int:pk>', views.SessionShippingItemDetail.as_view()),

    path('sessionshippingaddress/', views.SessionShippingAddressList.as_view()),
    path('sessionshippingaddress/<int:pk>', views.SessionShippingAddressDetail.as_view()),

    path('sessionpurchaseshippingitem/', views.SessionPurchaseShippingItemList.as_view()),
    path('sessionpurchaseshippingitem/<int:pk>', views.SessionPurchaseShippingItemDetail.as_view()),

    path('trackorder/', views.TrackOrderList.as_view()),
    path('trackorder/<int:pk>', views.TrackOrderDetail.as_view()),

    # Session Recharge

    path("create-stripe-checkout-session-recharge-web/",
        csrf_exempt(views.CreateStripeCheckoutSessionRechargeView.as_view())),
    
    path("expire-stripe-checkout-session-recharge/",
        csrf_exempt(views.ExpireStripeCheckoutSessionRechargeView.as_view())),

    path('sessionrecharge/', views.SessionRechargeList.as_view()),
    path('sessionrecharge/<int:pk>', views.SessionRechargeDetail.as_view()),
]