|
a/Allura/allura/controllers/project.py |
|
b/Allura/allura/controllers/project.py |
|
... |
|
... |
192 |
flash('Welcome to the SourceForge Project System! '
|
192 |
flash('Welcome to the SourceForge Project System! '
|
193 |
'To get started, fill out some information about your project.')
|
193 |
'To get started, fill out some information about your project.')
|
194 |
redirect(c.project.script_name + 'admin/overview')
|
194 |
redirect(c.project.script_name + 'admin/overview')
|
195 |
|
195 |
|
196 |
@expose()
|
196 |
@expose()
|
197 |
def icon(self):
|
197 |
def icon(self, **kw):
|
198 |
icon = self.neighborhood.icon
|
198 |
icon = self.neighborhood.icon
|
199 |
if not icon:
|
199 |
if not icon:
|
200 |
raise exc.HTTPNotFound
|
200 |
raise exc.HTTPNotFound
|
201 |
return icon.serve()
|
201 |
return icon.serve()
|
202 |
|
202 |
|
|
... |
|
... |
318 |
response.headers['Content-Type'] = ''
|
318 |
response.headers['Content-Type'] = ''
|
319 |
response.content_type = 'application/xml'
|
319 |
response.content_type = 'application/xml'
|
320 |
return feed.writeString('utf-8')
|
320 |
return feed.writeString('utf-8')
|
321 |
|
321 |
|
322 |
@expose()
|
322 |
@expose()
|
323 |
def icon(self):
|
323 |
def icon(self, **kw):
|
324 |
icon = c.project.icon
|
324 |
icon = c.project.icon
|
325 |
if not icon:
|
325 |
if not icon:
|
326 |
raise exc.HTTPNotFound
|
326 |
raise exc.HTTPNotFound
|
327 |
return icon.serve()
|
327 |
return icon.serve()
|
328 |
|
328 |
|
329 |
@expose()
|
329 |
@expose()
|
330 |
def user_icon(self):
|
330 |
def user_icon(self, **kw):
|
331 |
try:
|
331 |
try:
|
332 |
return self.icon()
|
332 |
return self.icon()
|
333 |
except exc.HTTPNotFound:
|
333 |
except exc.HTTPNotFound:
|
334 |
redirect(g.forge_static('images/user.png'))
|
334 |
redirect(g.forge_static('images/user.png'))
|
335 |
|
335 |
|
|
... |
|
... |
742 |
def _lookup(self, recipient, *remainder):
|
742 |
def _lookup(self, recipient, *remainder):
|
743 |
recipient = unquote(recipient)
|
743 |
recipient = unquote(recipient)
|
744 |
return GrantController(self.neighborhood, self.award, recipient), remainder
|
744 |
return GrantController(self.neighborhood, self.award, recipient), remainder
|
745 |
|
745 |
|
746 |
@expose()
|
746 |
@expose()
|
747 |
def icon(self):
|
747 |
def icon(self, **kw):
|
748 |
icon = self.award.icon
|
748 |
icon = self.award.icon
|
749 |
if not icon:
|
749 |
if not icon:
|
750 |
raise exc.HTTPNotFound
|
750 |
raise exc.HTTPNotFound
|
751 |
return icon.serve()
|
751 |
return icon.serve()
|
752 |
|
752 |
|
|
... |
|
... |
807 |
@expose('jinja:allura:templates/award_not_found.html')
|
807 |
@expose('jinja:allura:templates/award_not_found.html')
|
808 |
def not_found(self, **kw):
|
808 |
def not_found(self, **kw):
|
809 |
return dict()
|
809 |
return dict()
|
810 |
|
810 |
|
811 |
@expose()
|
811 |
@expose()
|
812 |
def icon(self):
|
812 |
def icon(self, **kw):
|
813 |
icon = self.award.icon
|
813 |
icon = self.award.icon
|
814 |
if not icon:
|
814 |
if not icon:
|
815 |
raise exc.HTTPNotFound
|
815 |
raise exc.HTTPNotFound
|
816 |
return icon.serve()
|
816 |
return icon.serve()
|
817 |
|
817 |
|