You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
10 lines
395 B
10 lines
395 B
import { listProjects } from "../../service/projects";
|
|
|
|
export default defineWrappedResponseHandler(async (event) => {
|
|
const query = getQuery(event);
|
|
const page = Math.max(1, parseInt(String(query.page || "1")));
|
|
const pageSize = Math.min(50, Math.max(1, parseInt(String(query.pageSize || "30"))));
|
|
|
|
const result = await listProjects({ page, pageSize });
|
|
return R.success(result);
|
|
});
|
|
|