From 15fe7e7dcec1c8a49bcb8e45a3160e75bb951b08 Mon Sep 17 00:00:00 2001 From: zhaoyingbo Date: Tue, 28 Jan 2025 13:14:13 +0000 Subject: [PATCH] =?UTF-8?q?feat:=20=E7=A7=BB=E9=99=A4=E5=86=97=E4=BD=99?= =?UTF-8?q?=E7=9A=84ID=E6=B6=88=E6=81=AF=E5=8F=91=E9=80=81=E9=80=BB?= =?UTF-8?q?=E8=BE=91=EF=BC=8C=E6=94=B9=E4=B8=BA=E7=BB=9F=E4=B8=80=E4=BD=BF?= =?UTF-8?q?=E7=94=A8=E6=9B=B4=E6=96=B0=E6=88=96=E5=9B=9E=E5=A4=8D=E6=B6=88?= =?UTF-8?q?=E6=81=AF=E7=9A=84=E6=96=B9=E6=B3=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- routes/bot/eventMsg.ts | 18 +++--------------- 1 file changed, 3 insertions(+), 15 deletions(-) diff --git a/routes/bot/eventMsg.ts b/routes/bot/eventMsg.ts index 0b2bd32..42634c2 100644 --- a/routes/bot/eventMsg.ts +++ b/routes/bot/eventMsg.ts @@ -49,20 +49,6 @@ const filterIllegalMsg = async (ctx: Context): Promise => { return true } -/** - * 发送ID消息 - * @param {Context} ctx - 上下文数据 - */ -const manageIdMsg = ({ - larkBody: { chatId }, - larkCard, - larkService, -}: Context) => - larkService.message.sendCard2Chat( - chatId, - larkCard.genTempCard("chatId", { chat_id: chatId }) - ) - /** * 处理意图消息 * @param {Context} ctx - 上下文数据 @@ -99,7 +85,9 @@ const manageIntent = async (ctx: Context) => { if (intentAgent.isBaseIntent(intentRes)) { switch (intentRes.intent) { case 1: - await manageIdMsg(ctx) + await message.updateOrReply( + larkCard.genTempCard("chatId", { chat_id: chatId }) as string + ) break case 2: await attachService.ciMonitor(chatId)