From 037b7123408a6a324f6539825fc4e2885dbcf935 Mon Sep 17 00:00:00 2001 From: liuwei Date: Mon, 10 Mar 2025 15:01:20 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8A=A0=E7=BE=A4=E6=B6=88=E6=81=AF=E6=B5=8B?= =?UTF-8?q?=E8=AF=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- group_add/main.py | 60 ++++------------------------------------------- 1 file changed, 4 insertions(+), 56 deletions(-) diff --git a/group_add/main.py b/group_add/main.py index 1877d3f..5a1bbe2 100644 --- a/group_add/main.py +++ b/group_add/main.py @@ -31,60 +31,8 @@ class GroupAdd: now_time = str(datetime.now().strftime("%Y-%m-%d %H:%M:%S")) nick_name = self.all_contacts.get(message.sender, message.sender) - user_info = self.wcf.query_sql("MicroMsg.db", f"SELECT * FROM Contact WHERE UserName = '{message.sender}';") + # 创建包含用户昵称、时间和Emoji表情的字符串 + welcome_message = f"🎉 欢迎用户 {nick_name} \n👋 在 {now_time} 🕒 加入群聊!😊" - self.LOG.info(f"GroupAdd contact:{user_info}") - - BigHeadImgUrl = "" - url = "https://hot.imsyy.top/#/" - outxml = f""" - - - - 👏欢迎 {nick_name} 加入群聊!🎉 - ⌚时间:{now_time} - view - 5 - 0 - - {url} - - - - - {BigHeadImgUrl} - - - - - - - - 0 - - - - - - - - 0 - - - - - - 0 - - - - Jyunere - 0 - - 1 - - - - - - """ + self.wcf.send_text(welcome_message, (message.roomid if message.from_group() else message.sender), + message.sender)