feat: build Onyx SSR shell and plan hero with mock data
This commit is contained in:
1 parent
84c20992f9
commit
2db494fb10
34 files changed
+3197
-2
No files matched your search
@@ -0,0 +1,10 @@
|
||||
import { getMockTrainJob } from '../../utils/train-jobs'
|
||||
|
||||
export default defineEventHandler((event) => {
|
||||
const jobId = getRouterParam(event, 'jobId')
|
||||
const job = jobId ? getMockTrainJob(jobId) : undefined
|
||||
if (!job) {
|
||||
throw createError({ statusCode: 404, statusMessage: `Unknown training job: ${jobId}` })
|
||||
}
|
||||
return job
|
||||
})
|
||||
Reference in new issue
Block a user