4.8.5 test (#1819)

This commit is contained in:
Archer
2024-06-21 18:32:05 +08:00
committed by GitHub
parent 5cc01b8509
commit 24596a6e21
40 changed files with 908 additions and 1058 deletions

View File

@@ -8,7 +8,7 @@ import { ApiRequestProps } from '@fastgpt/service/type/next';
/* update chat top, custom title */
async function handler(req: ApiRequestProps<UpdateHistoryProps>, res: NextApiResponse) {
const { appId, chatId, customTitle, top } = req.body;
const { appId, chatId, title, customTitle, top } = req.body;
await autChatCrud({
req,
authToken: true,
@@ -20,6 +20,7 @@ async function handler(req: ApiRequestProps<UpdateHistoryProps>, res: NextApiRes
{ appId, chatId },
{
updateTime: new Date(),
...(title !== undefined && { title }),
...(customTitle !== undefined && { customTitle }),
...(top !== undefined && { top })
}