Closed MustafaTaj closed 4 months ago
Example survey command was build using regular keyboards only, it won't work properly if you try to call it from the callback query handler command.
Have you looked at the example callbackquery and inlinekeyboard commands?
I solve it by modifying the command as follows:
[-] $this->conversation = new Conversation($user_id, $chat_id, $this->getName());
[+] $this->conversation = new Conversation($chat_id, $chat_id, $this->getName());
I'm not sure how good that works with chatID as userID in the database since it would cause a duplicate when 2 or more uses were start the survey from a group chat
I've come across the issue myself and wrote a pastebin how i solved it, using InlineKeyboard in a conversation
Required Information
{...}
Summary
am trying to use the survey command example using the example-bot. It works fine when I input
/survey
in the chatbut using an inline keyboard doesn't seem to make the wizard work propely
in CallbackqueryCommand.php I tried to use:
return $this->telegram->executeCommand('survey);
and it only shows the first step of the wizard and doesn't continue.
this is my code CallbackqueryCommand.php
this is my /start command code