def org_organisation_logo(id):
 if (not id):
  return None
 s3db = current.s3db
 if isinstance(id, Row):
  record = id
 else:
  table = s3db.org_organisation
  record = current.db((table.id == id)).select(table.name, table.acronym, table.logo, limitby=(0, 1)).first()
 if (record and record.logo):
  size = (None, 60)
  image = s3db.pr_image_represent(record.logo, size=size)
  url_small = URL(c='default', f='download', args=image)
  if ((record.acronym is None) or (record.acronym == '')):
   alt = ('%s logo' % record.name)
  else:
   alt = ('%s logo' % record.acronym)
  logo = IMG(_src=url_small, _alt=alt, _height=60)
  return logo
 return ''

def org_organisation_logo ( id ) : if ( not id ) : return None s3db = current . s3db if isinstance ( id , Row ) : record = id else : table = s3db . org_organisation record = current . db ( ( table . id == id ) ) . select ( table . name , table . acronym , table . logo , limitby = ( 0 , 1 ) ) . first ( ) if ( record and record . logo ) : size = ( None , 60 ) image = s3db . pr_image_represent ( record . logo , size = size ) url_small = URL ( c = 'default' , f = 'download' , args = image ) if ( ( record . acronym is None ) or ( record . acronym == '' ) ) : alt = ( '%s logo' % record . name ) else : alt = ( '%s logo' % record . acronym ) logo = IMG ( _src = url_small , _alt = alt , _height = 60 ) return logo return ''
return a logo of the organisation with the given id .