VirtualMailManager/handler.py
branchv0.6.x
changeset 557 1498abbb6c91
parent 555 499c63f52462
child 559 cc0f67f99780
equal deleted inserted replaced
556:fbbb16476c5b 557:1498abbb6c91
   478 
   478 
   479         dom = self._get_domain(domainname)
   479         dom = self._get_domain(domainname)
   480         serviceset = ServiceSet(self._dbh, **kwargs)
   480         serviceset = ServiceSet(self._dbh, **kwargs)
   481         dom.update_serviceset(serviceset, (True, False)[not force])
   481         dom.update_serviceset(serviceset, (True, False)[not force])
   482 
   482 
       
   483     def domain_transport(self, domainname, transport, force=None):
       
   484         """Wrapper around Domain.update_transport()"""
       
   485         if force is not None and force != 'force':
       
   486             raise DomainError(_(u"Invalid argument: '%s'") % force,
       
   487                               INVALID_ARGUMENT)
       
   488         dom = self._get_domain(domainname)
       
   489         trsp = Transport(self._dbh, transport=transport)
       
   490         if force is None:
       
   491             dom.update_transport(trsp)
       
   492         else:
       
   493             dom.update_transport(trsp, force=True)
       
   494 
   483     def domain_note(self, domainname, note):
   495     def domain_note(self, domainname, note):
   484         """Wrapper around Domain.update_transport()"""
   496         """Wrapper around Domain.update_note()"""
   485         dom = self._get_domain(domainname)
   497         dom = self._get_domain(domainname)
   486         dom.update_note(note)
   498         dom.update_note(note)
   487 
   499 
   488     def domain_delete(self, domainname, force=False):
   500     def domain_delete(self, domainname, force=False):
   489         """Wrapper around Domain.delete()"""
   501         """Wrapper around Domain.delete()"""