feat(orders): add recipient management and enhance order forms
- Introduced Recipient model to manage order recipients separately from customers. - Updated Order model to link to Recipient, replacing recipient_name and recipient_phone fields. - Enhanced OrderForm to include recipient selection modes: customer, history, and new. - Added AJAX endpoint to fetch recipient history for customers. - Updated admin interface to manage recipients and display recipient information in order details. - Refactored address handling to accommodate new recipient logic. - Improved demo order creation to include random recipients.
This commit is contained in:
@@ -18,6 +18,7 @@ urlpatterns = [
|
||||
|
||||
# AJAX endpoints
|
||||
path('api/customer-address-history/', views.get_customer_address_history, name='api-customer-address-history'),
|
||||
path('api/customer-recipient-history/', views.get_customer_recipient_history, name='api-customer-recipient-history'),
|
||||
|
||||
# Wallet payment
|
||||
path('<int:order_number>/apply-wallet/', views.apply_wallet_payment, name='apply-wallet'),
|
||||
|
||||
Reference in New Issue
Block a user