app/soc/views/sponsor/profile.py
changeset 298 c76a366c7ab4
parent 272 00cea07656c0
child 309 7190b224c701
--- a/app/soc/views/sponsor/profile.py	Fri Oct 10 13:14:24 2008 +0000
+++ b/app/soc/views/sponsor/profile.py	Sun Oct 12 00:08:54 2008 +0000
@@ -32,12 +32,12 @@
 
 DEF_SPONSOR_PUBLIC_TMPL = 'soc/group/profile/public.html'
 
-def public(request, linkname=None, template=DEF_SPONSOR_PUBLIC_TMPL):
+def public(request, link_name=None, template=DEF_SPONSOR_PUBLIC_TMPL):
   """How the "general public" sees the Sponsor profile.
 
   Args:
     request: the standard django request object.
-    linkname: the Sponsor's site-unique "linkname" extracted from the URL
+    link_name: the Sponsor's site-unique "link_name" extracted from the URL
     template: the template path to use for rendering the template.
 
   Returns:
@@ -47,15 +47,15 @@
   context = helper.responses.getUniversalContext(request)
 
   try:
-    linkname_sponsor = sponsor.getSponsorIfLinkName(linkname)
+    link_name_sponsor = sponsor.sponsor_logic.getIfFields(link_name=link_name)
   except out_of_band.ErrorResponse, error:
     # show custom 404 page when link name doesn't exist in Datastore
     return simple.errorResponse(request, error, template, context)
 
-  linkname_sponsor.description = \
-      helper.templates.unescape(linkname_sponsor.description)
+  link_name_sponsor.description = \
+      helper.templates.unescape(link_name_sponsor.description)
   
-  context.update({'linkname_group': linkname_sponsor,
+  context.update({'link_name_group': link_name_sponsor,
                   'group_type': 'Sponsor'})
 
   return helper.responses.respond(request, template, context)
\ No newline at end of file