mirror of
https://github.com/ChatGPTNextWeb/ChatGPT-Next-Web.git
synced 2025-11-16 22:13:47 +08:00
opt user table
This commit is contained in:
@@ -12,11 +12,15 @@ async function handle(
|
||||
// const url = req.url;
|
||||
const { pathname, searchParams } = new URL(req.url);
|
||||
const searchText = searchParams.get("search");
|
||||
|
||||
// console.log(req, '2', params.path)
|
||||
|
||||
if (method === "GET") {
|
||||
// 是否有查询
|
||||
try {
|
||||
const skip = Number(searchParams.get("skip"));
|
||||
const take = Number(searchParams.get("take"));
|
||||
console.log("-----", skip, take);
|
||||
const result = searchText
|
||||
? await prisma.user.findMany({
|
||||
orderBy: {
|
||||
|
||||
Reference in New Issue
Block a user