from django.conf.urls.static import static from django.contrib import admin from django.urls import path, include from .views import * urlpatterns = [ path('all', OrderlistView.as_view(), name='order-list'), path('cart', CartView.as_view()), path('cart/set-address', SetAddressForCartView.as_view()), path('cart/discount', ApplyDiscountView.as_view()), path('cart/special-discount', ApplySpecialDiscountView.as_view()), path('cart/all', CartItemClear.as_view()), path('cart/item/', CartItemViews.as_view(), name='change-item-cart'), path('cart/payment', PaymentView.as_view(), name='payment'), path('transaction/', CallbackView.as_view(), name='callback-gateway'), path('', OrderGetView.as_view(), name='order-get'), # User invoice download endpoint (DRF APIView) path('invoice/', UserOrderInvoiceView.as_view(), name='user-order-invoice'), # Admin invoice download endpoints path('invoice/order//download', download_order_invoice, name='download-order-invoice'), path('invoice/shop-order//download', download_shop_order_invoice, name='download-shop-order-invoice'), ]