Пример #1
0
    def report(self, message, report_name):
        """ for unit tests ONLY - sends messages to all nurses! """
        from weltel.callbacks import shida_report, other_report

        report_name = report_name.strip().lower()
        if report_name == "shida":
            shida_report(self.router, message.reporter)
        elif report_name == "other":
            other_report(self.router, message.reporter)
        else:
            logging.info("Nurse %s sent unrecognized command '%s'" % (message.reporter.alias, message.persistent_msg))
            message.respond(_("That report is not recognized."))
Пример #2
0
 def report(self, message, report_name):
     """ for unit tests ONLY - sends messages to all nurses! """
     from weltel.callbacks import shida_report, other_report
     report_name = report_name.strip().lower()
     if report_name == 'shida':
         shida_report(self.router, message.reporter)
     elif report_name == 'other':
         other_report(self.router, message.reporter)
     else:
         logging.info("Nurse %s sent unrecognized command '%s'" % \
                      (message.reporter.alias, message.persistent_msg))
         message.respond( _("That report is not recognized.") )
Пример #3
0
 def shida_report(self, message):
     from weltel.callbacks import shida_report
     shida_report(self.router)