Commit 1aa9a702 authored by Jérome Perrin's avatar Jérome Perrin

remove country= parameter for asText. It's not part of the interface, and

anyway is not passed by getDefaultAddressText and others.



git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@12725 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 7f7d4610
......@@ -67,19 +67,15 @@ class GeographicAddress(Coordinate, Base):
__implements__ = ( Interface.Coordinate )
security.declareProtected(Permissions.AccessContentsInformation, 'asText')
def asText(self, country=''):
def asText(self):
"""
Returns the address as a complete formatted string
with street address, zip, city and region
"""
result = Coordinate.asText(self)
if result is None:
if country=='France' or country=='france' or country=='fr' :
result = ('%s\n%s %s') % (self.getStreetAddress() or '',
self.getZipCode() or '', self.getCity() or '')
else :
result = ('%s\n%s %s') % (self.getStreetAddress() or '',
self.getCity() or '', self.getZipCode() or '')
result = ('%s\n%s %s') % (self.getStreetAddress() or '',
self.getCity() or '', self.getZipCode() or '')
if not result.strip():
return ''
return result
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment