def path_from_uid(self): uid = self.request.get('uid') sender = self.request.get('sender') if uid and sender: company = self.context.reference_catalog.lookupObject(uid) if ICompany.providedBy(company): #owner = company.getOwner() #email = owner.getProperty('email', '') email = company.getEmail() if email == sender: return company.absolute_url_path() return ''
def getCompany(self): company = self.aq_parent.aq_parent if ICompany.providedBy(company): return company