Exemplo n.º 1
0
 def view(self,id):
     c.artist = meta.Session.query(model.Artist).get(id)
     if c.artist.bio:
         c.bio = textile(c.artist.bio)
     #meta.Session.query(model.Album).filter(model.Album.artists.contains(c.artist)).all()
     #c.numworks = len(q.all())
     #c.featured = q.filter_by(featured=True).all()
     return render('/artist/detail.html')
Exemplo n.º 2
0
Arquivo: bios.py Projeto: kzahel/gwhiz
 def view(self,id):
     c.composer = meta.Session.query(model.Composer).get(id)
     c.bio = textile(c.composer.bio)
     c.numworks = len(c.composer.works)
     c.numpublications = len(c.composer.publications)
     c.featured_works = [w for w in c.composer.works if w.featured == True]
     c.featured_publications = [w for w in c.composer.publications if w.featured == True]
     return render('/bios/detail.html')
Exemplo n.º 3
0
 def publicationdetail(self,id):
     c.publication = meta.Session.query(model.Publication).get(id)
     if c.publication.description:
         c.publication.description = textile(c.publication.description)
     return render('/catalog/publicationdetail.html')
Exemplo n.º 4
0
 def workdetail(self,id):
     q = meta.Session.query(model.Work).get(id)
     c.work = q
     if c.work.description:
         c.work.description = textile(c.work.description)
     return render('/catalog/workdetail.html')