feat: add backend
This commit is contained in:
11
apps/server/controllers/application.ts
Normal file
11
apps/server/controllers/application.ts
Normal file
@@ -0,0 +1,11 @@
|
||||
import type { Context } from 'koa';
|
||||
import prisma from '../libs/db.ts';
|
||||
|
||||
export async function list(ctx: Context) {
|
||||
const list = await prisma.application.findMany({
|
||||
where: {
|
||||
valid: 1,
|
||||
},
|
||||
});
|
||||
ctx.body = list;
|
||||
}
|
||||
Reference in New Issue
Block a user