@stacksjs/defaults 0.75.529 → 0.75.537
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/ai/skills/stacks-actions/SKILL.md +1 -1
- package/ai/skills/stacks-build/SKILL.md +1 -1
- package/ai/skills/stacks-dashboard/SKILL.md +2 -2
- package/ai/skills/stacks-database/SKILL.md +1 -1
- package/ai/skills/stacks-migrations/SKILL.md +2 -2
- package/ai/skills/stacks-native/CATALOG.md +6 -6
- package/app/Actions/Dashboard/Commerce/CommerceCouponsAction.ts +27 -15
- package/app/Actions/Dashboard/Commerce/CommerceCouponsExportAction.ts +45 -0
- package/app/Actions/Dashboard/Commerce/CommerceCustomersAction.ts +22 -12
- package/app/Actions/Dashboard/Commerce/CommerceCustomersExportAction.ts +44 -0
- package/app/Actions/Dashboard/Commerce/CommercePosCheckoutAction.ts +9 -29
- package/app/Actions/Dashboard/Commerce/CommercePrintDevicesAction.ts +7 -9
- package/app/Actions/Dashboard/Commerce/CommerceProductDetailAction.ts +9 -8
- package/app/Actions/Dashboard/Commerce/CommerceTaxesAction.ts +7 -9
- package/app/Actions/Dashboard/Commerce/ManufacturerIndexAction.ts +8 -20
- package/app/Actions/Dashboard/Commerce/commerce-coupon-list.test.ts +203 -0
- package/app/Actions/Dashboard/Commerce/commerce-coupon-list.ts +248 -0
- package/app/Actions/Dashboard/Commerce/commerce-customer-list.test.ts +183 -0
- package/app/Actions/Dashboard/Commerce/commerce-customer-list.ts +186 -0
- package/app/Actions/Dashboard/Commerce/commerce-customer-records.test.ts +1 -34
- package/app/Actions/Dashboard/Commerce/commerce-customer-records.ts +0 -11
- package/app/Actions/Dashboard/Commerce/commerce-manufacturer-list.test.ts +118 -0
- package/app/Actions/Dashboard/Commerce/commerce-manufacturer-list.ts +41 -0
- package/app/Actions/Dashboard/Commerce/commerce-pos-catalog.test.ts +17 -5
- package/app/Actions/Dashboard/Commerce/commerce-pos-catalog.ts +17 -3
- package/app/Actions/Dashboard/Commerce/commerce-print-device-list.test.ts +99 -0
- package/app/Actions/Dashboard/Commerce/commerce-print-device-list.ts +18 -0
- package/app/Actions/Dashboard/Commerce/commerce-product-list.ts +5 -5
- package/app/Actions/Dashboard/Commerce/commerce-product-options.test.ts +81 -0
- package/app/Actions/Dashboard/Commerce/commerce-tax-rate-list.test.ts +99 -0
- package/app/Actions/Dashboard/Commerce/commerce-tax-rate-list.ts +18 -0
- package/app/Actions/Dashboard/Commerce/coupon-records.test.ts +1 -16
- package/app/Actions/Dashboard/Commerce/coupon-records.ts +6 -10
- package/app/Actions/Dashboard/Commerce/manufacturer-records.test.ts +5 -17
- package/app/Actions/Dashboard/Commerce/manufacturer-records.ts +0 -29
- package/app/Actions/Dashboard/Email/captured-mail.test.ts +16 -0
- package/app/Actions/Dashboard/Email/captured-mail.ts +9 -1
- package/app/Actions/Dashboard/Models/model-write.ts +36 -3
- package/app/Actions/Dashboard/Notifications/NotificationDeliveryHistoryAction.ts +13 -58
- package/app/Actions/Dashboard/Notifications/notification-delivery-history.ts +74 -0
- package/app/Actions/SitemapAction.ts +3 -1
- package/app/Models/Notification.ts +3 -1
- package/app/Models/NotificationDelivery.ts +4 -0
- package/app/Models/User.ts +10 -1
- package/bootstrap.ts +10 -2
- package/functions/commerce/tax-types.ts +21 -0
- package/functions/dashboard-list.test.ts +16 -0
- package/functions/dashboard-list.ts +14 -6
- package/functions/dashboard-model-record.test.ts +139 -0
- package/functions/dashboard-model-record.ts +353 -0
- package/functions/monitoring/errors.ts +22 -103
- package/functions/notifications/deliveries.ts +7 -38
- package/functions/queries.ts +7 -10
- package/ide/vscode/package.json +1 -1
- package/package.json +5 -5
- package/resources/components/Dashboard/Analytics/AnalyticsHub.stx +2 -2
- package/resources/components/Dashboard/Analytics/CampaignAnalytics.stx +22 -28
- package/resources/components/Dashboard/Analytics/EventAnalytics.stx +26 -34
- package/resources/components/Dashboard/Analytics/SalesAnalytics.stx +29 -37
- package/resources/components/Dashboard/Analytics/WebAnalyticsBreakdown.stx +12 -16
- package/resources/components/Dashboard/Analytics/WebAnalyticsDashboard.stx +43 -53
- package/resources/components/Dashboard/App/RequestsOverview.stx +2 -1
- package/resources/components/Dashboard/App/SourceInventory.stx +2 -1
- package/resources/components/Dashboard/Auth/AccessTokens.stx +3 -5
- package/resources/components/Dashboard/Billing/BillingPaymentMethodsPanel.stx +9 -11
- package/resources/components/Dashboard/Billing/BillingSettings.stx +1 -1
- package/resources/components/Dashboard/Buddy/BuddyAssistant.stx +4 -6
- package/resources/components/Dashboard/Commerce/CommerceCategoriesDashboard.stx +2 -2
- package/resources/components/Dashboard/Commerce/CommerceCategoriesTable.stx +3 -3
- package/resources/components/Dashboard/Commerce/CommerceCategoryDialog.stx +2 -2
- package/resources/components/Dashboard/Commerce/CommerceCategoryHierarchy.stx +3 -5
- package/resources/components/Dashboard/Commerce/CommerceCouponBreakdown.stx +17 -13
- package/resources/components/Dashboard/Commerce/CommerceCouponDialog.stx +1 -1
- package/resources/components/Dashboard/Commerce/CommerceCouponsDashboard.stx +57 -85
- package/resources/components/Dashboard/Commerce/CommerceCouponsTable.stx +32 -9
- package/resources/components/Dashboard/Commerce/CommerceCustomerDialog.stx +1 -1
- package/resources/components/Dashboard/Commerce/CommerceCustomersDashboard.stx +49 -83
- package/resources/components/Dashboard/Commerce/CommerceCustomersTable.stx +32 -9
- package/resources/components/Dashboard/Commerce/CommerceGiftCardBreakdown.stx +9 -15
- package/resources/components/Dashboard/Commerce/CommerceGiftCardDialog.stx +1 -1
- package/resources/components/Dashboard/Commerce/CommerceGiftCardsDashboard.stx +35 -119
- package/resources/components/Dashboard/Commerce/CommerceGiftCardsTable.stx +3 -3
- package/resources/components/Dashboard/Commerce/CommerceManufacturerDialog.stx +1 -1
- package/resources/components/Dashboard/Commerce/CommerceManufacturersDashboard.stx +3 -5
- package/resources/components/Dashboard/Commerce/CommerceManufacturersTable.stx +2 -2
- package/resources/components/Dashboard/Commerce/CommerceOrderDialog.stx +4 -4
- package/resources/components/Dashboard/Commerce/CommerceOrdersDashboard.stx +42 -129
- package/resources/components/Dashboard/Commerce/CommerceOrdersTable.stx +3 -3
- package/resources/components/Dashboard/Commerce/CommerceOverviewDashboard.stx +1 -1
- package/resources/components/Dashboard/Commerce/CommerceOverviewOrdersTable.stx +9 -11
- package/resources/components/Dashboard/Commerce/CommerceOverviewProductsTable.stx +5 -7
- package/resources/components/Dashboard/Commerce/CommerceOverviewStats.stx +14 -16
- package/resources/components/Dashboard/Commerce/CommercePaymentsBreakdown.stx +12 -18
- package/resources/components/Dashboard/Commerce/CommercePaymentsDashboard.stx +41 -120
- package/resources/components/Dashboard/Commerce/CommercePaymentsTable.stx +1 -1
- package/resources/components/Dashboard/Commerce/CommercePosCart.stx +13 -15
- package/resources/components/Dashboard/Commerce/CommercePosCatalog.stx +17 -19
- package/resources/components/Dashboard/Commerce/CommercePosCheckoutDialog.stx +2 -2
- package/resources/components/Dashboard/Commerce/CommercePosDashboard.stx +1 -1
- package/resources/components/Dashboard/Commerce/CommercePosReceiptDialog.stx +1 -1
- package/resources/components/Dashboard/Commerce/CommerceProductDetailDashboard.stx +5 -5
- package/resources/components/Dashboard/Commerce/CommerceProductDialog.stx +3 -3
- package/resources/components/Dashboard/Commerce/CommerceProductsDashboard.stx +41 -122
- package/resources/components/Dashboard/Commerce/CommerceProductsTable.stx +3 -3
- package/resources/components/Dashboard/Commerce/CommerceReviewEditDialog.stx +1 -1
- package/resources/components/Dashboard/Commerce/CommerceReviewsDashboard.stx +38 -122
- package/resources/components/Dashboard/Commerce/CommerceReviewsTable.stx +2 -2
- package/resources/components/Dashboard/Commerce/CommerceTaxDialog.stx +3 -3
- package/resources/components/Dashboard/Commerce/CommerceTaxesDashboard.stx +5 -4
- package/resources/components/Dashboard/Commerce/CommerceTaxesTable.stx +4 -3
- package/resources/components/Dashboard/Commerce/CommerceUnitDialog.stx +3 -7
- package/resources/components/Dashboard/Commerce/CommerceUnitsDashboard.stx +3 -5
- package/resources/components/Dashboard/Commerce/CommerceUnitsTable.stx +2 -2
- package/resources/components/Dashboard/Commerce/CommerceVariantDialog.stx +3 -3
- package/resources/components/Dashboard/Commerce/CommerceVariantsDashboard.stx +4 -4
- package/resources/components/Dashboard/Commerce/CommerceVariantsTable.stx +3 -5
- package/resources/components/Dashboard/Commerce/Delivery/CourierDialog.stx +1 -1
- package/resources/components/Dashboard/Commerce/Delivery/CouriersDashboard.stx +1 -1
- package/resources/components/Dashboard/Commerce/Delivery/CouriersTable.stx +2 -2
- package/resources/components/Dashboard/Commerce/Delivery/DeliveryOverviewDashboard.stx +44 -52
- package/resources/components/Dashboard/Commerce/Delivery/DeliveryPagination.stx +2 -2
- package/resources/components/Dashboard/Commerce/Delivery/DeliveryRouteDialog.stx +1 -1
- package/resources/components/Dashboard/Commerce/Delivery/DeliveryRoutesDashboard.stx +1 -1
- package/resources/components/Dashboard/Commerce/Delivery/DeliveryRoutesTable.stx +2 -2
- package/resources/components/Dashboard/Commerce/Delivery/DigitalDeliveriesDashboard.stx +1 -1
- package/resources/components/Dashboard/Commerce/Delivery/DigitalDeliveryTable.stx +2 -2
- package/resources/components/Dashboard/Commerce/Delivery/LicenseKeyDialog.stx +3 -3
- package/resources/components/Dashboard/Commerce/Delivery/LicenseKeysDashboard.stx +1 -1
- package/resources/components/Dashboard/Commerce/Delivery/LicenseKeysTable.stx +2 -2
- package/resources/components/Dashboard/Commerce/Delivery/ShippingMethodsDashboard.stx +1 -1
- package/resources/components/Dashboard/Commerce/Delivery/ShippingMethodsTable.stx +2 -2
- package/resources/components/Dashboard/Commerce/Delivery/ShippingRateDialog.stx +2 -2
- package/resources/components/Dashboard/Commerce/Delivery/ShippingRatesDashboard.stx +1 -1
- package/resources/components/Dashboard/Commerce/Delivery/ShippingRatesTable.stx +2 -2
- package/resources/components/Dashboard/Commerce/Delivery/ShippingZoneDialog.stx +1 -1
- package/resources/components/Dashboard/Commerce/Delivery/ShippingZonesDashboard.stx +1 -1
- package/resources/components/Dashboard/Commerce/Delivery/ShippingZonesTable.stx +4 -8
- package/resources/components/Dashboard/Commerce/PaymentDetailsDialog.stx +1 -3
- package/resources/components/Dashboard/Commerce/PrintDeviceBreakdown.stx +9 -15
- package/resources/components/Dashboard/Commerce/PrintDeviceDialog.stx +1 -1
- package/resources/components/Dashboard/Commerce/PrintDevicesDashboard.stx +3 -3
- package/resources/components/Dashboard/Commerce/PrintDevicesTable.stx +3 -3
- package/resources/components/Dashboard/Commerce/PrintLogBreakdown.stx +3 -9
- package/resources/components/Dashboard/Commerce/PrintLogDetailsDialog.stx +1 -1
- package/resources/components/Dashboard/Commerce/PrintLogsDashboard.stx +4 -4
- package/resources/components/Dashboard/Commerce/PrintLogsTable.stx +8 -10
- package/resources/components/Dashboard/Commerce/ProductWaitlistDashboard.stx +37 -109
- package/resources/components/Dashboard/Commerce/ProductWaitlistEntryDialog.stx +3 -3
- package/resources/components/Dashboard/Commerce/ProductWaitlistTable.stx +2 -2
- package/resources/components/Dashboard/Commerce/RestaurantWaitlistDashboard.stx +38 -112
- package/resources/components/Dashboard/Commerce/RestaurantWaitlistEntryDialog.stx +2 -2
- package/resources/components/Dashboard/Commerce/RestaurantWaitlistTable.stx +2 -2
- package/resources/components/Dashboard/Content/AuthorsDashboard.stx +4 -4
- package/resources/components/Dashboard/Content/BlogDashboard.stx +4 -4
- package/resources/components/Dashboard/Content/CommentsDashboard.stx +36 -83
- package/resources/components/Dashboard/Content/ContentDashboard.stx +12 -14
- package/resources/components/Dashboard/Content/ContentTaxonomyDashboard.stx +2 -2
- package/resources/components/Dashboard/Content/FileManagerDashboard.stx +8 -12
- package/resources/components/Dashboard/Content/FileStoragePanel.stx +6 -10
- package/resources/components/Dashboard/Content/FileUploadDialog.stx +1 -3
- package/resources/components/Dashboard/Content/PagesDashboard.stx +39 -78
- package/resources/components/Dashboard/Content/PostEditorDialog.stx +4 -8
- package/resources/components/Dashboard/Content/PostsDashboard.stx +44 -85
- package/resources/components/Dashboard/Content/SeoDashboard.stx +5 -4
- package/resources/components/Dashboard/Data/DataRecords.stx +140 -12
- package/resources/components/Dashboard/Deployments/DeploymentList.stx +4 -4
- package/resources/components/Dashboard/Deployments/DeploymentTable.stx +3 -1
- package/resources/components/Dashboard/Elements/DropdownNavigation.stx +5 -7
- package/resources/components/Dashboard/Email/CapturedMailDashboard.stx +1 -3
- package/resources/components/Dashboard/Email/CapturedMailList.stx +18 -20
- package/resources/components/Dashboard/Email/EmailActivityDashboard.stx +24 -28
- package/resources/components/Dashboard/Email/EmailSettingsList.stx +6 -8
- package/resources/components/Dashboard/Email/EmailSettingsNavigation.stx +10 -12
- package/resources/components/Dashboard/Email/EmailSidebar.stx +33 -37
- package/resources/components/Dashboard/Email/InboxMessageDetail.stx +1 -1
- package/resources/components/Dashboard/Email/InboxMessageList.stx +16 -18
- package/resources/components/Dashboard/Email/InboxSettingsDashboard.stx +1 -1
- package/resources/components/Dashboard/Environment/EnvironmentDashboard.stx +2 -2
- package/resources/components/Dashboard/GlobalSearch.stx +19 -21
- package/resources/components/Dashboard/Home/DashboardHome.stx +8 -1
- package/resources/components/Dashboard/Infrastructure/CloudDashboard.stx +1 -1
- package/resources/components/Dashboard/Infrastructure/DnsDashboard.stx +27 -13
- package/resources/components/Dashboard/Infrastructure/LogsDashboard.stx +1 -1
- package/resources/components/Dashboard/Infrastructure/MailboxesDashboard.stx +46 -8
- package/resources/components/Dashboard/Infrastructure/ServerlessDashboard.stx +1 -1
- package/resources/components/Dashboard/Infrastructure/ServersDashboard.stx +1 -1
- package/resources/components/Dashboard/Jobs/JobDetail.stx +1 -1
- package/resources/components/Dashboard/Jobs/JobHistory.stx +44 -57
- package/resources/components/Dashboard/Jobs/JobTable.stx +23 -25
- package/resources/components/Dashboard/Kanban/KanbanCardDialog.stx +1 -1
- package/resources/components/Dashboard/Library/ComponentsDashboard.stx +1 -1
- package/resources/components/Dashboard/Management/AssignmentDrawer.stx +5 -7
- package/resources/components/Dashboard/Management/PermissionsDashboard.stx +35 -43
- package/resources/components/Dashboard/Marketing/AbandonedCartsDashboard.stx +11 -13
- package/resources/components/Dashboard/Marketing/CampaignDialog.stx +1 -3
- package/resources/components/Dashboard/Marketing/CampaignsDashboard.stx +2 -2
- package/resources/components/Dashboard/Marketing/CampaignsTable.stx +2 -2
- package/resources/components/Dashboard/Marketing/MarketingListsDashboard.stx +1 -1
- package/resources/components/Dashboard/Marketing/MarketingListsTable.stx +2 -2
- package/resources/components/Dashboard/Marketing/SocialPostDialog.stx +1 -3
- package/resources/components/Dashboard/Marketing/SocialPostsDashboard.stx +2 -2
- package/resources/components/Dashboard/Marketing/SocialPostsTable.stx +2 -2
- package/resources/components/Dashboard/Models/ModelRecordActions.stx +11 -2
- package/resources/components/Dashboard/Models/ModelRecordCreate.stx +193 -0
- package/resources/components/Dashboard/Models/ModelRecordDetail.stx +144 -0
- package/resources/components/Dashboard/Models/ModelRecordEdit.stx +176 -0
- package/resources/components/Dashboard/Models/ModelRecordsDashboard.stx +52 -186
- package/resources/components/Dashboard/Models/ModelsOverview.stx +2 -4
- package/resources/components/Dashboard/Monitoring/ErrorDashboard.stx +47 -81
- package/resources/components/Dashboard/Monitoring/ErrorTable.stx +4 -2
- package/resources/components/Dashboard/NotFoundDashboard.stx +4 -4
- package/resources/components/Dashboard/Notifications/NotificationDeliveryHistory.stx +43 -77
- package/resources/components/Dashboard/Notifications/NotificationDeliveryOverview.stx +15 -17
- package/resources/components/Dashboard/Notifications/NotificationDeliveryTable.stx +1 -1
- package/resources/components/Dashboard/Operations/AuditDashboard.stx +1 -1
- package/resources/components/Dashboard/Operations/ChangeDashboard.stx +1 -1
- package/resources/components/Dashboard/Operations/IncidentDashboard.stx +1 -1
- package/resources/components/Dashboard/Operations/MigrationDashboard.stx +2 -2
- package/resources/components/Dashboard/Operations/RecoveryDashboard.stx +1 -1
- package/resources/components/Dashboard/Operations/SchedulerDashboard.stx +1 -1
- package/resources/components/Dashboard/Queries/QueryDashboard.stx +60 -86
- package/resources/components/Dashboard/Queries/QueryDetail.stx +5 -9
- package/resources/components/Dashboard/Realtime/RealtimeDashboard.stx +6 -8
- package/resources/components/Dashboard/Remote/RemoteConsole.stx +14 -20
- package/resources/components/Dashboard/Settings/AppearanceSettingsDashboard.stx +48 -54
- package/resources/components/Dashboard/Settings/MailSettingsDashboard.stx +8 -8
- package/resources/components/Dashboard/Settings/SettingsDashboard.stx +43 -47
- package/resources/components/Dashboard/Teams/TeamInvitationDashboard.stx +2 -2
- package/resources/components/Dashboard/UI/ActivityTable.stx +2 -1
- package/resources/components/Dashboard/UI/Button.stx +15 -0
- package/resources/components/Dashboard/UI/MetricCards.stx +5 -7
- package/resources/components/Dashboard/UI/Pagination.stx +3 -5
- package/resources/components/Dashboard/UI/QuickLinks.stx +2 -2
- package/resources/components/Dashboard/UI/Select.stx +1 -0
- package/resources/components/Dashboard/UI/Table.stx +139 -96
- package/resources/components/Dashboard/UI/Tabs.stx +18 -20
- package/routes/dashboard-api.ts +2 -0
- package/routes/dashboard.ts +246 -253
- package/routes/storefront.ts +31 -0
- package/stx-components-plugin.ts +12 -1
- package/views/dashboard/content/categories/index.stx +1 -1
- package/views/dashboard/content/tags/index.stx +1 -1
- package/views/dashboard/layouts/default.stx +27 -12
- package/views/dashboard/models/[model]/[id]/edit.stx +8 -0
- package/views/dashboard/models/[model]/[id].stx +8 -0
- package/views/dashboard/models/[model]/create.stx +8 -0
- package/resources/components/Dashboard/CreateRecordModal.stx +0 -138
- package/resources/components/Dashboard/Models/EditRecordModal.stx +0 -81
package/routes/dashboard.ts
CHANGED
|
@@ -15,6 +15,7 @@
|
|
|
15
15
|
* ```
|
|
16
16
|
*/
|
|
17
17
|
|
|
18
|
+
import { feature } from '@stacksjs/config'
|
|
18
19
|
import { isLocalDeployment } from '@stacksjs/env'
|
|
19
20
|
import { projectPath } from '@stacksjs/path'
|
|
20
21
|
import { dashboardGroupMiddleware, describeUnknownDashboardGroups, resolveDashboardAccess, route } from '@stacksjs/router'
|
|
@@ -102,28 +103,8 @@ route.post('/api/team-invitations/{token}/accept', 'Actions/Teams/AcceptInvitati
|
|
|
102
103
|
// leaked, not about guessing.
|
|
103
104
|
route.post('/api/feedback/{token}', 'Actions/Dashboard/Feedback/FeedbackStoreAction').name('feedback.store').skipCsrf().rateLimit(10, 'minute')
|
|
104
105
|
|
|
105
|
-
//
|
|
106
|
-
//
|
|
107
|
-
//
|
|
108
|
-
// CSRF is skipped because the storefront uses progressive-enhancement
|
|
109
|
-
// HTML forms — there's no JS to mint a token — and each cart is
|
|
110
|
-
// already gated by an opaque, HttpOnly session cookie that can't be
|
|
111
|
-
// guessed. Apps that want classic CSRF on top can re-register the
|
|
112
|
-
// same routes in their `routes/api.ts` without `.skipCsrf()`.
|
|
113
|
-
// ============================================================================
|
|
114
|
-
|
|
115
|
-
route.get('/api/cart', 'Actions/Storefront/GetCartAction').skipCsrf()
|
|
116
|
-
route.post('/api/cart/add', 'Actions/Storefront/AddToCartAction').skipCsrf()
|
|
117
|
-
route.post('/api/cart/update', 'Actions/Storefront/UpdateCartItemAction').skipCsrf()
|
|
118
|
-
route.post('/api/checkout/contact', 'Actions/Storefront/CheckoutContactAction').skipCsrf()
|
|
119
|
-
route.post('/api/checkout/shipping', 'Actions/Storefront/CheckoutShippingAction').skipCsrf()
|
|
120
|
-
route.post('/api/checkout/place', 'Actions/Storefront/PlaceOrderAction').skipCsrf()
|
|
121
|
-
|
|
122
|
-
// Buyer-submitted product review. Tied to a shipped order via
|
|
123
|
-
// order_id + email match (the SubmitReviewAction verifies ownership
|
|
124
|
-
// and stamps is_verified_purchase=1). Stored as is_approved=0 for
|
|
125
|
-
// admin moderation through `/dashboard/commerce/reviews`.
|
|
126
|
-
route.post('/api/reviews/submit', 'Actions/Storefront/SubmitReviewAction').skipCsrf()
|
|
106
|
+
// The storefront (cart, checkout, buyer reviews) is its own bundle,
|
|
107
|
+
// `storefront.ts`, mounted with the commerce feature.
|
|
127
108
|
|
|
128
109
|
// ============================================================================
|
|
129
110
|
// Health & System
|
|
@@ -323,46 +304,48 @@ route.group({ prefix: '/api/monitoring', middleware: guarded('/api/monitoring')
|
|
|
323
304
|
// is no longer a DB/CMS mirror. /cms below remains the authoring API.
|
|
324
305
|
// ============================================================================
|
|
325
306
|
|
|
326
|
-
|
|
327
|
-
route.
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
307
|
+
if (feature('cms')) {
|
|
308
|
+
route.group({ prefix: '/cms', middleware: guarded('/cms') }, () => {
|
|
309
|
+
route.get('/dashboard', 'Actions/Dashboard/Content/ContentDashboardAction')
|
|
310
|
+
route.get('/posts', 'Actions/Cms/PostIndexAction')
|
|
311
|
+
route.get('/posts/{id}', 'Actions/Cms/PostShowAction')
|
|
312
|
+
route.post('/posts', 'Actions/Cms/PostStoreAction')
|
|
313
|
+
route.patch('/posts/{id}', 'Actions/Cms/PostUpdateAction')
|
|
314
|
+
route.delete('/posts/{id}', 'Actions/Cms/PostDestroyAction')
|
|
315
|
+
route.patch('/posts/{id}/views', 'Actions/Cms/PostViewsUpdateAction')
|
|
316
|
+
|
|
317
|
+
route.get('/authors', 'Actions/Cms/AuthorIndexAction')
|
|
318
|
+
route.get('/authors/{id}', 'Actions/Cms/AuthorShowAction')
|
|
319
|
+
route.post('/authors', 'Actions/Cms/AuthorStoreAction')
|
|
320
|
+
route.patch('/authors/{id}', 'Actions/Cms/AuthorUpdateAction')
|
|
321
|
+
route.delete('/authors/{id}', 'Actions/Cms/AuthorDestroyAction')
|
|
322
|
+
|
|
323
|
+
route.get('/categories', 'Actions/Cms/CategorizableIndexAction')
|
|
324
|
+
route.get('/categories/{id}', 'Actions/Cms/CategorizableShowAction')
|
|
325
|
+
route.post('/categories', 'Actions/Cms/CategorizableStoreAction')
|
|
326
|
+
route.patch('/categories/{id}', 'Actions/Cms/CategorizableUpdateAction')
|
|
327
|
+
route.delete('/categories/{id}', 'Actions/Cms/CategorizableDestroyAction')
|
|
328
|
+
|
|
329
|
+
route.get('/tags', 'Actions/Cms/TaggableIndexAction')
|
|
330
|
+
route.get('/tags/{id}', 'Actions/Cms/TaggableShowAction')
|
|
331
|
+
route.post('/tags', 'Actions/Cms/TaggableStoreAction')
|
|
332
|
+
route.patch('/tags/{id}', 'Actions/Cms/TaggableUpdateAction')
|
|
333
|
+
route.delete('/tags/{id}', 'Actions/Cms/TaggableDestroyAction')
|
|
334
|
+
|
|
335
|
+
route.get('/comments', 'Actions/Cms/CommentIndexAction')
|
|
336
|
+
route.get('/comments/{id}', 'Actions/Cms/CommentShowAction')
|
|
337
|
+
route.post('/comments', 'Actions/Cms/CommentStoreAction')
|
|
338
|
+
route.patch('/comments/{id}', 'Actions/Cms/CommentUpdateAction')
|
|
339
|
+
route.delete('/comments/{id}', 'Actions/Cms/CommentDestroyAction')
|
|
340
|
+
|
|
341
|
+
route.get('/pages', 'Actions/Cms/PageIndexAction')
|
|
342
|
+
route.post('/pages', 'Actions/Cms/PageStoreAction')
|
|
343
|
+
route.patch('/pages/{id}', 'Actions/Cms/PageUpdateAction')
|
|
344
|
+
route.delete('/pages/{id}', 'Actions/Cms/PageDestroyAction')
|
|
345
|
+
|
|
346
|
+
route.get('/files', 'Actions/Dashboard/Content/FileIndexAction')
|
|
347
|
+
})
|
|
348
|
+
}
|
|
366
349
|
|
|
367
350
|
// (The public /blog mirror — posts/categories/tags/feed/sitemap from the DB —
|
|
368
351
|
// was retired. The blog is now BunPress + markdown; its feed.xml and
|
|
@@ -377,183 +360,184 @@ route.group({ prefix: '/cms', middleware: guarded('/cms') }, () => {
|
|
|
377
360
|
// underlying actions, since user routes load before framework routes.
|
|
378
361
|
// ============================================================================
|
|
379
362
|
|
|
380
|
-
|
|
381
|
-
route.
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
})
|
|
363
|
+
if (feature('commerce')) {
|
|
364
|
+
route.group({ prefix: '/api/commerce', middleware: guarded('/api/commerce') }, () => {
|
|
365
|
+
route.get('/dashboard', 'Actions/Dashboard/Commerce/CommerceDashboardAction')
|
|
366
|
+
route.get('/pos', 'Actions/Dashboard/Commerce/PosIndexAction')
|
|
367
|
+
route.get('/products', 'Actions/Commerce/Product/ProductIndexAction')
|
|
368
|
+
route.get('/products/{id}', 'Actions/Commerce/Product/ProductShowAction')
|
|
369
|
+
route.post('/products', 'Actions/Commerce/Product/ProductStoreAction')
|
|
370
|
+
route.patch('/products/{id}', 'Actions/Commerce/Product/ProductUpdateAction')
|
|
371
|
+
route.delete('/products/{id}', 'Actions/Commerce/Product/ProductDestroyAction')
|
|
372
|
+
|
|
373
|
+
// Product subresources nested under /products/* to match the
|
|
374
|
+
// frontend composables (defaults/functions/commerce/products/*.ts).
|
|
375
|
+
route.get('/products/{productId}/variants', 'Actions/Commerce/Product/ProductVariantIndexAction')
|
|
376
|
+
route.get('/products/variants', 'Actions/Commerce/Product/ProductVariantIndexAction')
|
|
377
|
+
route.get('/products/variants/{id}', 'Actions/Commerce/Product/ProductVariantShowAction')
|
|
378
|
+
route.post('/products/variants', 'Actions/Commerce/Product/ProductVariantStoreAction')
|
|
379
|
+
route.patch('/products/variants/{id}', 'Actions/Commerce/Product/ProductVariantUpdateAction')
|
|
380
|
+
route.delete('/products/variants/{id}', 'Actions/Commerce/Product/ProductVariantDestroyAction')
|
|
381
|
+
|
|
382
|
+
route.get('/products/units', 'Actions/Commerce/Product/ProductUnitIndexAction')
|
|
383
|
+
route.get('/products/units/{id}', 'Actions/Commerce/Product/ProductUnitShowAction')
|
|
384
|
+
route.post('/products/units', 'Actions/Commerce/Product/ProductUnitStoreAction')
|
|
385
|
+
route.patch('/products/units/{id}', 'Actions/Commerce/Product/ProductUnitUpdateAction')
|
|
386
|
+
route.delete('/products/units/{id}', 'Actions/Commerce/Product/ProductUnitDestroyAction')
|
|
387
|
+
|
|
388
|
+
route.get('/product-categories', 'Actions/Commerce/Product/ProductCategoryIndexAction')
|
|
389
|
+
route.post('/product-categories', 'Actions/Commerce/Product/ProductCategoryStoreAction')
|
|
390
|
+
|
|
391
|
+
// Manufacturers — frontend composable hits `/commerce/product-manufacturers`,
|
|
392
|
+
// so the resource name is namespaced to disambiguate from any future
|
|
393
|
+
// standalone manufacturers concept.
|
|
394
|
+
route.get('/product-manufacturers', 'Actions/Commerce/Product/ManufacturerIndexAction')
|
|
395
|
+
route.get('/product-manufacturers/{id}', 'Actions/Commerce/Product/ManufacturerShowAction')
|
|
396
|
+
route.post('/product-manufacturers', 'Actions/Commerce/Product/ManufacturerStoreAction')
|
|
397
|
+
route.patch('/product-manufacturers/{id}', 'Actions/Commerce/Product/ManufacturerUpdateAction')
|
|
398
|
+
route.delete('/product-manufacturers/{id}', 'Actions/Commerce/Product/ManufacturerDestroyAction')
|
|
399
|
+
|
|
400
|
+
route.get('/orders', 'Actions/Commerce/OrderIndexAction')
|
|
401
|
+
route.get('/orders/{id}', 'Actions/Commerce/OrderShowAction')
|
|
402
|
+
route.post('/orders', 'Actions/Commerce/OrderStoreAction')
|
|
403
|
+
route.patch('/orders/{id}', 'Actions/Commerce/OrderUpdateAction')
|
|
404
|
+
route.delete('/orders/{id}', 'Actions/Commerce/OrderDestroyAction')
|
|
405
|
+
route.get('/orders/export', 'Actions/Commerce/OrderExportAction')
|
|
406
|
+
|
|
407
|
+
route.get('/customers', 'Actions/Commerce/CustomerIndexAction')
|
|
408
|
+
route.get('/customers/{id}', 'Actions/Commerce/CustomerShowAction')
|
|
409
|
+
route.post('/customers', 'Actions/Commerce/CustomerStoreAction')
|
|
410
|
+
route.patch('/customers/{id}', 'Actions/Commerce/CustomerUpdateAction')
|
|
411
|
+
route.delete('/customers/{id}', 'Actions/Commerce/CustomerDestroyAction')
|
|
412
|
+
|
|
413
|
+
route.get('/coupons', 'Actions/Commerce/CouponIndexAction')
|
|
414
|
+
route.get('/coupons/{id}', 'Actions/Commerce/CouponShowAction')
|
|
415
|
+
route.post('/coupons', 'Actions/Commerce/CouponStoreAction')
|
|
416
|
+
route.patch('/coupons/{id}', 'Actions/Commerce/CouponUpdateAction')
|
|
417
|
+
route.delete('/coupons/{id}', 'Actions/Commerce/CouponDestroyAction')
|
|
418
|
+
|
|
419
|
+
route.get('/gift-cards', 'Actions/Commerce/GiftCardIndexAction')
|
|
420
|
+
route.get('/gift-cards/stats', 'Actions/Commerce/GiftCardStatsAction')
|
|
421
|
+
route.get('/gift-cards/{id}', 'Actions/Commerce/GiftCardShowAction')
|
|
422
|
+
route.post('/gift-cards', 'Actions/Commerce/GiftCardStoreAction')
|
|
423
|
+
route.patch('/gift-cards/{id}', 'Actions/Commerce/GiftCardUpdateAction')
|
|
424
|
+
route.patch('/gift-cards/{id}/balance', 'Actions/Commerce/GiftCardUpdateBalanceAction')
|
|
425
|
+
route.delete('/gift-cards/{id}', 'Actions/Commerce/GiftCardDestroyAction')
|
|
426
|
+
|
|
427
|
+
route.get('/tax-rates', 'Actions/Commerce/TaxRateIndexAction')
|
|
428
|
+
route.get('/tax-rates/{id}', 'Actions/Commerce/TaxRateShowAction')
|
|
429
|
+
route.post('/tax-rates', 'Actions/Commerce/TaxRateStoreAction')
|
|
430
|
+
route.patch('/tax-rates/{id}', 'Actions/Commerce/TaxRateUpdateAction')
|
|
431
|
+
route.delete('/tax-rates/{id}', 'Actions/Commerce/TaxRateDestroyAction')
|
|
432
|
+
|
|
433
|
+
// Reviews are scoped to products — frontend composable hits
|
|
434
|
+
// `/commerce/products/reviews`, not `/commerce/reviews`.
|
|
435
|
+
route.get('/products/reviews', 'Actions/Commerce/ReviewIndexAction')
|
|
436
|
+
route.get('/products/reviews/{id}', 'Actions/Commerce/ReviewShowAction')
|
|
437
|
+
route.post('/products/reviews', 'Actions/Commerce/ReviewStoreAction')
|
|
438
|
+
route.patch('/products/reviews/{id}', 'Actions/Commerce/ReviewUpdateAction')
|
|
439
|
+
route.delete('/products/reviews/{id}', 'Actions/Commerce/ReviewDestroyAction')
|
|
440
|
+
|
|
441
|
+
route.get('/receipts', 'Actions/Commerce/ReceiptIndexAction')
|
|
442
|
+
route.get('/receipts/{id}', 'Actions/Commerce/ReceiptShowAction')
|
|
443
|
+
route.post('/receipts', 'Actions/Commerce/ReceiptStoreAction')
|
|
444
|
+
route.patch('/receipts/{id}', 'Actions/Commerce/ReceiptUpdateAction')
|
|
445
|
+
route.delete('/receipts/{id}', 'Actions/Commerce/ReceiptDestroyAction')
|
|
446
|
+
|
|
447
|
+
route.get('/print-devices', 'Actions/Commerce/PrintDeviceIndexAction')
|
|
448
|
+
route.get('/print-devices/{id}', 'Actions/Commerce/PrintDeviceShowAction')
|
|
449
|
+
route.post('/print-devices', 'Actions/Commerce/PrintDeviceStoreAction')
|
|
450
|
+
route.patch('/print-devices/{id}', 'Actions/Commerce/PrintDeviceUpdateAction')
|
|
451
|
+
route.delete('/print-devices/{id}', 'Actions/Commerce/PrintDeviceDestroyAction')
|
|
452
|
+
|
|
453
|
+
route.get('/payment-stats', 'Actions/Commerce/PaymentFetchStatsAction')
|
|
454
|
+
route.get('/payment-trends', 'Actions/Commerce/PaymentMonthlyTrendsAction')
|
|
455
|
+
// Renamed from `/commerce-payments` — that path was double-prefixed
|
|
456
|
+
// because this group already mounts under `/commerce`, so callers
|
|
457
|
+
// hitting `/api/commerce/payments` (which the frontend composable
|
|
458
|
+
// does — see defaults/functions/commerce/payments.ts) were 404ing.
|
|
459
|
+
route.get('/payments', 'Actions/Commerce/PaymentIndexAction')
|
|
460
|
+
route.get('/payments/{id}', 'Actions/Commerce/PaymentShowAction')
|
|
461
|
+
route.post('/payments', 'Actions/Commerce/PaymentStoreAction')
|
|
462
|
+
route.patch('/payments/{id}', 'Actions/Commerce/PaymentUpdateAction')
|
|
463
|
+
route.delete('/payments/{id}', 'Actions/Commerce/PaymentDestroyAction')
|
|
464
|
+
|
|
465
|
+
route.get('/waitlist/products', 'Actions/Commerce/WaitlistProductIndexAction')
|
|
466
|
+
route.get('/waitlist/products/analytics', 'Actions/Commerce/WaitlistProductAnalyticsAction')
|
|
467
|
+
route.get('/waitlist/products/status', 'Actions/Commerce/WaitlistProductStatusAction')
|
|
468
|
+
route.get('/waitlist/products/time-series', 'Actions/Commerce/WaitlistProductTimeSeriesAction')
|
|
469
|
+
route.get('/waitlist/products/quantity-distribution', 'Actions/Commerce/WaitlistProductQuantityDistributionAction')
|
|
470
|
+
route.get('/waitlist/products/{id}', 'Actions/Commerce/WaitlistProductShowAction')
|
|
471
|
+
route.post('/waitlist/products', 'Actions/Commerce/WaitlistProductStoreAction')
|
|
472
|
+
route.patch('/waitlist/products/{id}', 'Actions/Commerce/WaitlistProductUpdateAction')
|
|
473
|
+
route.delete('/waitlist/products/{id}', 'Actions/Commerce/WaitlistProductDestroyAction')
|
|
474
|
+
|
|
475
|
+
route.get('/waitlist/restaurants', 'Actions/Commerce/WaitlistRestaurantIndexAction')
|
|
476
|
+
route.get('/waitlist/restaurants/dashboard', 'Actions/Commerce/WaitlistRestaurantDashboardAction')
|
|
477
|
+
route.get('/waitlist/restaurants/{id}', 'Actions/Commerce/WaitlistRestaurantShowAction')
|
|
478
|
+
route.post('/waitlist/restaurants', 'Actions/Commerce/WaitlistRestaurantStoreAction')
|
|
479
|
+
route.patch('/waitlist/restaurants/{id}', 'Actions/Commerce/WaitlistRestaurantUpdateAction')
|
|
480
|
+
route.delete('/waitlist/restaurants/{id}', 'Actions/Commerce/WaitlistRestaurantDestroyAction')
|
|
481
|
+
|
|
482
|
+
// ----------------------------------------------------------------
|
|
483
|
+
// Shipping (moved from a top-level /shipping group on 2026-05-08).
|
|
484
|
+
// The frontend composables (defaults/functions/commerce/shippings/*.ts)
|
|
485
|
+
// all expect these resources under /commerce/*, so the prior /shipping
|
|
486
|
+
// group was orphaned — every shipping/courier/license/digital call
|
|
487
|
+
// from the dashboard was 404ing. Resource names match the composable
|
|
488
|
+
// file names: shipping-methods/rates/zones, delivery-routes, couriers,
|
|
489
|
+
// digital-deliveries, license-keys.
|
|
490
|
+
// ----------------------------------------------------------------
|
|
491
|
+
route.get('/shipping-methods', 'Actions/Commerce/Shipping/ShippingMethodIndexAction')
|
|
492
|
+
route.get('/shipping-methods/{id}', 'Actions/Commerce/Shipping/ShippingMethodShowAction')
|
|
493
|
+
route.post('/shipping-methods', 'Actions/Commerce/Shipping/ShippingMethodStoreAction')
|
|
494
|
+
route.patch('/shipping-methods/{id}', 'Actions/Commerce/Shipping/ShippingMethodUpdateAction')
|
|
495
|
+
route.delete('/shipping-methods/{id}', 'Actions/Commerce/Shipping/ShippingMethodDestroyAction')
|
|
496
|
+
|
|
497
|
+
route.get('/shipping-rates', 'Actions/Commerce/Shipping/ShippingRateIndexAction')
|
|
498
|
+
route.get('/shipping-rates/{id}', 'Actions/Commerce/Shipping/ShippingRateShowAction')
|
|
499
|
+
route.post('/shipping-rates', 'Actions/Commerce/Shipping/ShippingRateStoreAction')
|
|
500
|
+
route.patch('/shipping-rates/{id}', 'Actions/Commerce/Shipping/ShippingRateUpdateAction')
|
|
501
|
+
route.delete('/shipping-rates/{id}', 'Actions/Commerce/Shipping/ShippingRateDestroyAction')
|
|
502
|
+
|
|
503
|
+
route.get('/shipping-zones', 'Actions/Commerce/Shipping/ShippingZoneIndexAction')
|
|
504
|
+
route.get('/shipping-zones/{id}', 'Actions/Commerce/Shipping/ShippingZoneShowAction')
|
|
505
|
+
route.post('/shipping-zones', 'Actions/Commerce/Shipping/ShippingZoneStoreAction')
|
|
506
|
+
route.patch('/shipping-zones/{id}', 'Actions/Commerce/Shipping/ShippingZoneUpdateAction')
|
|
507
|
+
route.delete('/shipping-zones/{id}', 'Actions/Commerce/Shipping/ShippingZoneDestroyAction')
|
|
508
|
+
|
|
509
|
+
route.get('/delivery-routes', 'Actions/Commerce/Shipping/DeliveryRouteIndexAction')
|
|
510
|
+
route.get('/delivery-routes/{id}', 'Actions/Commerce/Shipping/DeliveryRouteShowAction')
|
|
511
|
+
route.post('/delivery-routes', 'Actions/Commerce/Shipping/DeliveryRouteStoreAction')
|
|
512
|
+
route.patch('/delivery-routes/{id}', 'Actions/Commerce/Shipping/DeliveryRouteUpdateAction')
|
|
513
|
+
route.delete('/delivery-routes/{id}', 'Actions/Commerce/Shipping/DeliveryRouteDestroyAction')
|
|
514
|
+
|
|
515
|
+
route.get('/couriers', 'Actions/Commerce/Shipping/CourierIndexAction')
|
|
516
|
+
route.get('/couriers/{id}', 'Actions/Commerce/Shipping/CourierShowAction')
|
|
517
|
+
route.post('/couriers', 'Actions/Commerce/Shipping/CourierStoreAction')
|
|
518
|
+
route.patch('/couriers/{id}', 'Actions/Commerce/Shipping/CourierUpdateAction')
|
|
519
|
+
route.delete('/couriers/{id}', 'Actions/Commerce/Shipping/CourierDestroyAction')
|
|
520
|
+
|
|
521
|
+
// Renamed from `/digital` — frontend composable expects `/digital-deliveries`.
|
|
522
|
+
route.get('/digital-deliveries', 'Actions/Commerce/Shipping/DigitalDeliveryIndexAction')
|
|
523
|
+
route.get('/digital-deliveries/{id}', 'Actions/Commerce/Shipping/DigitalDeliveryShowAction')
|
|
524
|
+
route.post('/digital-deliveries', 'Actions/Commerce/Shipping/DigitalDeliveryStoreAction')
|
|
525
|
+
route.patch('/digital-deliveries/{id}', 'Actions/Commerce/Shipping/DigitalDeliveryUpdateAction')
|
|
526
|
+
route.delete('/digital-deliveries/{id}', 'Actions/Commerce/Shipping/DigitalDeliveryDestroyAction')
|
|
527
|
+
|
|
528
|
+
route.get('/license-keys', 'Actions/Commerce/Shipping/LicenseKeyIndexAction')
|
|
529
|
+
route.get('/license-keys/{id}', 'Actions/Commerce/Shipping/LicenseKeyShowAction')
|
|
530
|
+
route.post('/license-keys', 'Actions/Commerce/Shipping/LicenseKeyStoreAction')
|
|
531
|
+
route.patch('/license-keys/{id}', 'Actions/Commerce/Shipping/LicenseKeyUpdateAction')
|
|
532
|
+
route.delete('/license-keys/{id}', 'Actions/Commerce/Shipping/LicenseKeyDestroyAction')
|
|
533
|
+
})
|
|
534
|
+
}
|
|
550
535
|
|
|
551
536
|
// ============================================================================
|
|
552
537
|
// Analytics
|
|
553
538
|
// ============================================================================
|
|
554
539
|
|
|
555
540
|
route.group({ prefix: '/api/analytics', middleware: guarded('/api/analytics') }, () => {
|
|
556
|
-
route.get('/sales', 'Actions/Dashboard/Analytics/SalesAnalyticsAction')
|
|
557
541
|
route.get('/web', 'Actions/Dashboard/Analytics/WebAnalyticsAction')
|
|
558
542
|
route.get('/blog', 'Actions/Dashboard/Analytics/BlogAnalyticsAction')
|
|
559
543
|
route.get('/browsers', 'Actions/Dashboard/Analytics/BrowserAnalyticsAction')
|
|
@@ -563,7 +547,12 @@ route.group({ prefix: '/api/analytics', middleware: guarded('/api/analytics') },
|
|
|
563
547
|
route.get('/marketing', 'Actions/Dashboard/Analytics/MarketingAnalyticsAction')
|
|
564
548
|
route.get('/pages', 'Actions/Dashboard/Analytics/PageAnalyticsAction')
|
|
565
549
|
route.get('/referrers', 'Actions/Dashboard/Analytics/ReferrerAnalyticsAction')
|
|
566
|
-
|
|
550
|
+
// Sales and commerce analytics read the commerce tables, so they exist only
|
|
551
|
+
// with commerce installed.
|
|
552
|
+
if (feature('commerce')) {
|
|
553
|
+
route.get('/sales', 'Actions/Dashboard/Analytics/SalesAnalyticsAction')
|
|
554
|
+
route.get('/commerce', 'Actions/Dashboard/Analytics/CommerceAnalyticsAction')
|
|
555
|
+
}
|
|
567
556
|
})
|
|
568
557
|
|
|
569
558
|
// ============================================================================
|
|
@@ -632,30 +621,34 @@ route.get('/api/serverless', 'Actions/Dashboard/Cloud/ServerlessIndexAction').mi
|
|
|
632
621
|
// Dashboard Views — Commerce
|
|
633
622
|
// ============================================================================
|
|
634
623
|
|
|
635
|
-
|
|
636
|
-
route.
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
624
|
+
if (feature('commerce')) {
|
|
625
|
+
route.group({ prefix: '/dashboard/commerce', middleware: guarded('/dashboard/commerce') }, () => {
|
|
626
|
+
route.get('/customers', 'Actions/Dashboard/Commerce/CommerceCustomersAction')
|
|
627
|
+
route.get('/orders', 'Actions/Dashboard/Commerce/CommerceOrdersAction')
|
|
628
|
+
route.get('/products', 'Actions/Dashboard/Commerce/CommerceProductsAction')
|
|
629
|
+
route.get('/coupons', 'Actions/Dashboard/Commerce/CommerceCouponsAction')
|
|
630
|
+
route.get('/gift-cards', 'Actions/Dashboard/Commerce/CommerceGiftCardsAction')
|
|
631
|
+
route.get('/payments', 'Actions/Dashboard/Commerce/CommercePaymentsAction')
|
|
632
|
+
route.get('/delivery', 'Actions/Dashboard/Commerce/CommerceDeliveryAction')
|
|
633
|
+
route.get('/taxes', 'Actions/Dashboard/Commerce/CommerceTaxesAction')
|
|
634
|
+
route.get('/reviews', 'Actions/Dashboard/Commerce/ReviewIndexAction')
|
|
635
|
+
})
|
|
636
|
+
}
|
|
646
637
|
|
|
647
638
|
// ============================================================================
|
|
648
639
|
// Dashboard Views — CMS Content
|
|
649
640
|
// ============================================================================
|
|
650
641
|
|
|
651
|
-
|
|
652
|
-
route.
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
642
|
+
if (feature('cms')) {
|
|
643
|
+
route.group({ prefix: '/dashboard/cms', middleware: guarded('/dashboard/cms') }, () => {
|
|
644
|
+
route.get('/posts', 'Actions/Dashboard/Content/PostIndexAction')
|
|
645
|
+
route.get('/pages', 'Actions/Dashboard/Content/PageIndexAction')
|
|
646
|
+
route.get('/categories', 'Actions/Dashboard/Content/CategoryIndexAction')
|
|
647
|
+
route.get('/tags', 'Actions/Dashboard/Content/TagIndexAction')
|
|
648
|
+
route.get('/comments', 'Actions/Dashboard/Content/CommentIndexAction')
|
|
649
|
+
route.get('/authors', 'Actions/Dashboard/Content/AuthorIndexAction')
|
|
650
|
+
})
|
|
651
|
+
}
|
|
659
652
|
|
|
660
653
|
// ============================================================================
|
|
661
654
|
// Marketing
|