Template
## Summary - Closes #7 - Portal Retail **Sales** page: 30-day orders/revenue/units/AOV, daily charts, top products - Home dashboard cards for 30-day shop sales and revenue when `FEATURE_SHOP` is on - Stacks on #6 (shop catalog). Merge that first, then retarget `master` if needed. ## Test plan - [ ] Sales page requires login; empty state with no paid orders - [ ] Paid/fulfilled in the last 30 days counted; draft/open/cancelled/old excluded - [ ] Top products ranked by units; home dashboard shows 30-day sales count - [ ] `manage.py test shop core.tests_features` Reviewed-on: #8
21 lines
716 B
Python
21 lines
716 B
Python
from django.urls import path
|
|
|
|
from shop import views
|
|
|
|
app_name = "shop_portal"
|
|
|
|
urlpatterns = [
|
|
path("sales/", views.portal_sales, name="sales"),
|
|
path("products/", views.portal_product_list, name="product_list"),
|
|
path("products/new/", views.portal_product_edit, name="product_new"),
|
|
path("products/<uuid:pk>/", views.portal_product_edit, name="product_edit"),
|
|
path(
|
|
"products/<uuid:pk>/stock/",
|
|
views.portal_stock_adjust,
|
|
name="product_stock",
|
|
),
|
|
path("orders/", views.portal_order_list, name="order_list"),
|
|
path("orders/<uuid:pk>/", views.portal_order_detail, name="order_detail"),
|
|
path("webhooks/stripe/", views.stripe_webhook, name="stripe_webhook"),
|
|
]
|