Changeset 2104 for trunk/loreality/loreality/controllers/pilot.py
- Timestamp:
- 07/05/10 12:56:53 (23 months ago)
- File:
-
- 1 edited
-
trunk/loreality/loreality/controllers/pilot.py (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/loreality/loreality/controllers/pilot.py
r2100 r2104 24 24 class PilotController(BaseController): 25 25 26 #-------------------------------------------------------------- 27 def index(self, values=None, errors=None ): 28 c.heading = "Pilots" 29 c.title = "All pilots" 30 31 pilot_q = meta.Session.query(model.Pilot).order_by( model.Pilot.name ) 32 c.pilots = pilot_q.all() 33 34 html = render('/derived/page/overview_pilot.html') 35 return htmlfill.render(html, defaults=values, errors=errors) 36 #-------------------------------------------------------------- 26 37 def view(self, id, values=None, errors=None ): 27 38 if id is None: … … 32 43 abort(404) 33 44 34 c. title = "LoReality"35 c. heading= pilot.name45 c.heading = "Pilots" 46 c.title = pilot.name 36 47 c.pilot = pilot 37 48 … … 39 50 return htmlfill.render(html, defaults=values, errors=errors) 40 51 52 #-------------------------------------------------------------- 41 53 @authorize(h.auth.is_creator) 42 54 def edit(self, id=None, values=None, errors=None ): … … 48 60 abort(404) 49 61 50 c. title = "LoReality"51 c. heading= "Edit %s"%pilot.name62 c.heading = "Pilots" 63 c.title = "Edit %s"%pilot.name 52 64 c.pilot = pilot 53 65
Note: See TracChangeset
for help on using the changeset viewer.
