Topic Support for Bot, resolves #649
- added
/setgrouptopiccommand which admin can use to set/unset group topic for werewolf bot - added new column in
dbo.Grouptable :GroupTopicIdto store topic id - restricts bot command to specified topic only, except admin command and manually allowed command with Attribute
AllowOutsideConfiguredTopic
Note : I may have forget some places to update and make topic support
This PR resolves : https://github.com/GreyWolfDev/Werewolf/issues/649
this is new PR, as i messed up old one
old PR : https://github.com/GreyWolfDev/Werewolf/pull/660#issue-3148283214
note that i have squashed those 2 commit :
8abf556f fix(/setgrouptopic): complete TODO 1 and 2, used button for set and unset.
b0ec8681 add(topic support) && update(sql schema)...
- removed TODO description as they are done.
- removed database schema update commit line, i think it can be directly done by someone or a separate PR for schema update
Those 2 TODO are left(but planned, unrelated to this PR) :
- Remove redundant direct call to Telegram send API and make single method that send normal message or document based on flag parameter such as
msg_type: [TEXT,DOC,GIF]- A database migrator system, so we can avoid manual database backup and restore
(I should note, I have not tried to execute the code to test its functional correctness so far. These are all just my thoughts based on reading it.)
I will work on reviews when I get time. Thank you for feedback
@Olgabrezel check new commit and tell me if there is anything needed to be done