feat(dashboard): add aggregated dashboard stats API, robust logout, and warehouse seeders
deploy-chabokan / deploy (push) Canceled after 0s
deploy-chabokan / deploy (push) Canceled after 0s
This commit is contained in:
@@ -0,0 +1,11 @@
|
||||
const catchAsync = require('../../globalErrorHandler/catchAsync')
|
||||
const dashboardService = require('./dashboardService')
|
||||
|
||||
exports.getDashboardStats = catchAsync(async (req, res, next) => {
|
||||
const stats = await dashboardService.getDashboardStats()
|
||||
|
||||
res.status(200).json({
|
||||
status: 'success',
|
||||
data: stats,
|
||||
})
|
||||
})
|
||||
Reference in New Issue
Block a user