Пример #1
0
 def add(self, message, match):
     if self._is_authorized(message):
         jid_add = self._get_jid(match.group("phone_number"))
         self._add_user(message.getFrom(), jid_add)
         time.sleep(1)
         try:
             self.interface_layer.toLower(
                 TextMessageProtocolEntity(get("welcome"),
                                           to=message.getFrom()))
         except:
             self.interface_layer.toLower(
                 TextMessageProtocolEntity(get("welcome"),
                                           to=message.getFrom()))
Пример #2
0
 def f_help(self, message=None, match=None, to=None):
     return TextMessageProtocolEntity(get("fun"), to=message.getFrom())
Пример #3
0
 def list_comic(self, message=None, match=None, to=None):
     return TextMessageProtocolEntity(get("comic"), to=message.getFrom())
Пример #4
0
 def list_story(self, message=None, match=None, to=None):
     return TextMessageProtocolEntity(get("story"), to=message.getFrom())
Пример #5
0
 def youtube(self, message=None, match=None, to=None):
     return TextMessageProtocolEntity(get("y_menu"), to=message.getFrom())
Пример #6
0
 def about(self, message=None, match=None, to=None):
     return TextMessageProtocolEntity(get("about"), to=message.getFrom())
Пример #7
0
 def py2(self, message=None, match=None, to=None):
     return TextMessageProtocolEntity(get("python2"), to=message.getFrom())
Пример #8
0
 def link(self, message=None, match=None, to=None):
     return TextMessageProtocolEntity(get("link"), to=message.getFrom())
Пример #9
0
 def help2(self, message=None, match=None, to=None):
     return TextMessageProtocolEntity(get("home2"), to=message.getFrom())