-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
✨ 添加水群时长统计 #913
Merged
fumiama
merged 12 commits into
FloatTech:master
from
guohuiyuan:feature-chatcount-20240521
Jun 11, 2024
Merged
✨ 添加水群时长统计 #913
fumiama
merged 12 commits into
FloatTech:master
from
guohuiyuan:feature-chatcount-20240521
Jun 11, 2024
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
fumiama
requested changes
May 25, 2024
大部分更新数据库,就算加查找缓存,还是要更新数据库的时间的,所以我打算把时间戳和时长都放在内存算了
Sent from my iPhone
…------------------ 原始邮件 ------------------
发件人: 源文雨 ***@***.***>
发送时间: 2024年5月28日 20:05
收件人: FloatTech/ZeroBot-Plugin ***@***.***>
抄送: himawari ***@***.***>, Author ***@***.***>
主题: Re: [FloatTech/ZeroBot-Plugin] ✨ 添加水群时长统计 (PR #913)
@fumiama commented on this pull request.
In plugin/chatcount/chatcount.go:
> + rankSize = 15 +) + +func init() { + engine := control.AutoRegister(&ctrl.Options[*zero.Ctx]{ + DisableOnDefault: false, + Brief: "聊天时长统计", + Help: "- ***@***.***\n- 查看水群排名", + PrivateDataFolder: "chatcount", + }) + go func() { + ctdb = initialize(engine.DataFolder() + "chatcount.db") + }() + engine.OnMessage(zero.OnlyGroup).SetBlock(false). + Handle(func(ctx *zero.Ctx) { + todayTime, remindFlag := ctdb.updateChatTime(ctx.Event.GroupID, ctx.Event.UserID)
那你咋统计
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
也可以,毕竟是以天为基准,也不会重启那么频繁,每条消息写一次开销太大了。 |
fumiama
requested changes
Jun 6, 2024
fumiama
approved these changes
Jun 11, 2024
vatebur
pushed a commit
to vatebur/ZeroBot-Plugin
that referenced
this pull request
Jun 11, 2024
* ✨ 添加水群时长统计 * 🐛 优化名片逻辑 * 🐛 更新发言时间 * 🎨 格式化 * 🐛 添加锁 * 🎨 改成at * 🎨 添加map * 🎨 修lint * 🐛 修改排序问题 * 🎨 优化lint
fumiama
pushed a commit
that referenced
this pull request
Jun 11, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
No description provided.