Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var Telegram = require('telegram-node-bot');
- class StartController extends Telegram.TelegramBaseController {
- startHandler($){
- $.runMenu({
- message: "Good and bright day.\n" + "Im your virtual receptionist and I can help you during your arrival and stay at the hotel. \n" + "To bring you a properly assistance tell me if you have allready a stay in a Hotel: " ,
- options: {
- parse_mode: 'Markdown' // in options field you can pass some additional data, like parse_mode
- },
- 'Yes, I have a place': {
- resizeKeyboard: true,
- },
- 'Not at the moment': {
- message: 'Can I help you to find one?',
- resizeKeyboard: true,
- 'yes': () => {
- },
- 'no': () => {
- }
- },
- 'anyMatch': () => { //will be executed at any other message
- }
- })
- }
- get routes(){
- return {
- 'startCommand' : 'startHandler'
- };
- }
- }
- module.exports = StartController;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement