VirtualMailManager/Account.py
branchv0.6.x
changeset 246 481280686789
parent 245 f9a6b6701cf9
child 250 73cd082cd724
equal deleted inserted replaced
245:f9a6b6701cf9 246:481280686789
   308                     # TP: A service (pop3/imap) isn't enabled/usable for a user
   308                     # TP: A service (pop3/imap) isn't enabled/usable for a user
   309                     info[service] = _('disabled')
   309                     info[service] = _('disabled')
   310             info['address'] = self._addr
   310             info['address'] = self._addr
   311             info['home'] = '%s/%s' % (self._domain.directory, info['uid'])
   311             info['home'] = '%s/%s' % (self._domain.directory, info['uid'])
   312             info['mail_location'] = MailLocation(mid=info['mid']).mail_location
   312             info['mail_location'] = MailLocation(mid=info['mid']).mail_location
   313             info['transport'] = Transport(self._dbh,
   313             if info['transport'] == self._domain.transport.tid:
   314                                           tid=info['transport']).transport
   314                 info['transport'] = self._domain.transport.transport
       
   315             else:
       
   316                 info['transport'] = Transport(self._dbh,
       
   317                                               tid=info['transport']).transport
   315             del info['mid']
   318             del info['mid']
   316             return info
   319             return info
   317         # nearly impossibleā€½
   320         # nearly impossibleā€½
   318         raise AErr(_(u"Couldn't fetch information for account: '%s'") \
   321         raise AErr(_(u"Couldn't fetch information for account: '%s'") \
   319                    % self._addr, NO_SUCH_ACCOUNT)
   322                    % self._addr, NO_SUCH_ACCOUNT)