feat: Update Orders to follow CRUD pattern SOP
Following PROJECT_SOP.md section 5.7 CRUD Module Pattern: **Backend (NavigationRegistry.php):** - Added Orders submenu: All orders | New - Prepared for future tabs (Drafts, Recurring) **Frontend (Orders/index.tsx):** - Removed 'New order' button from toolbar - Kept bulk actions (Delete) in toolbar - Filters remain in toolbar **Result:** - Orders now consistent with Products pattern - Follows industry standard (Shopify, WooCommerce) - Submenu for main actions, toolbar for filters/bulk actions **Next:** - Implement variable product handling in OrderForm
This commit is contained in:
@@ -117,7 +117,11 @@ class NavigationRegistry {
|
||||
'label' => __('Orders', 'woonoow'),
|
||||
'path' => '/orders',
|
||||
'icon' => 'receipt-text',
|
||||
'children' => [], // Orders has no submenu by design
|
||||
'children' => [
|
||||
['label' => __('All orders', 'woonoow'), 'mode' => 'spa', 'path' => '/orders'],
|
||||
['label' => __('New', 'woonoow'), 'mode' => 'spa', 'path' => '/orders/new'],
|
||||
// Future: Drafts, Recurring, etc.
|
||||
],
|
||||
],
|
||||
[
|
||||
'key' => 'products',
|
||||
|
||||
Reference in New Issue
Block a user