feat: add usercount, session count and complete rate

This commit is contained in:
wancat committed 2023-10-14 16:03:44 +08:00
1 parent add6bfd100
commit cc95bb195b
7 files changed
+131 -5

No files matched your search

+2 -3
View File
@@ -2,6 +2,7 @@ import connectDB from '@linux-odyssey/models'
import express from 'express'
import { engine } from 'express-handlebars'
import config from './config.js'
import { homeController } from './controllers/index.js'
async function main() {
await connectDB(config.db)
@@ -12,9 +13,7 @@ async function main() {
app.set('view engine', 'handlebars')
app.set('views', './views')
app.get('/', (req, res) => {
res.render('home', { title: 'Linux Odyssey Admin' })
})
app.get('/', homeController)
app.listen(3001, () => {
console.log('Server started on http://localhost:3001')