iro/user.py
changeset 57 97ef6ca145e6
parent 30 5253631a8dd3
child 58 fb161058bcab
equal deleted inserted replaced
56:3718abbfffd6 57:97ef6ca145e6
    74         except:
    74         except:
    75             raise NoID(id)
    75             raise NoID(id)
    76         job.stop()
    76         job.stop()
    77 
    77 
    78     
    78     
    79     def startSMS(self,message,recipients,provider="default"):
    79     def startSMS(self, message, recipients, provider="default"):
    80         '''
    80         '''
    81         starts the SMS with message to recipients
    81         starts the SMS with message to recipients
    82         '''
    82         '''
    83         if not "sms" in self.features:
    83         if not "sms" in self.features:
    84             raise NotSupportedFeature("sms")
    84             raise NotSupportedFeature("sms")
    85         id = self.jobqueue.newSMS(message,recipients,provider)
    85         id = self.jobqueue.newSMS(message,recipients,provider)
    86         self.jobs[id]=self.jobqueue[id]
    86         self.jobs[id]=self.jobqueue[id]
    87         return id
    87         return id
    88     
    88     
    89     
    89     
    90     def startFAX(self,subject, fax,provider="default"):
    90     def startFAX(self, subject, fax, recipients, provider="default"):
    91         '''
    91         '''
    92         starts the FAX  with the pdf file fax and the subject
    92         starts the FAX  with the pdf file fax and the subject
    93         '''
    93         '''
       
    94         logger.debug("startFAX(%s,%s,%s,%s)"%(subject, fax, recipients, provider))
    94         if not "fax" in self.features:
    95         if not "fax" in self.features:
    95             raise NotSupportedFeature("fax")
    96             raise NotSupportedFeature("fax")
    96         id = self.jobqueue.newFAX(subject, fax,recipients,provider)
    97         id = self.jobqueue.newFAX(subject, fax,recipients,provider)
    97         self.jobs[id]=self.jobqueue[id]
    98         self.jobs[id]=self.jobqueue[id]
    98         return id
    99         return id