##// END OF EJS Templates
Rename "nb" variable to "template" for clarity
Cameron Bates -
Show More
@@ -211,8 +211,8 b' class ProjectDashboardHandler(AuthenticatedHandler):'
211 def get(self):
211 def get(self):
212 nbm = self.application.notebook_manager
212 nbm = self.application.notebook_manager
213 project = nbm.notebook_dir
213 project = nbm.notebook_dir
214 nb = self.application.jinja2_env.get_template('projectdashboard.html')
214 template = self.application.jinja2_env.get_template('projectdashboard.html')
215 self.write( nb.render(project=project,
215 self.write( template.render(project=project,
216 base_project_url=self.application.ipython_app.base_project_url,
216 base_project_url=self.application.ipython_app.base_project_url,
217 base_kernel_url=self.application.ipython_app.base_kernel_url,
217 base_kernel_url=self.application.ipython_app.base_kernel_url,
218 read_only=self.read_only,
218 read_only=self.read_only,
@@ -223,8 +223,8 b' class ProjectDashboardHandler(AuthenticatedHandler):'
223 class LoginHandler(AuthenticatedHandler):
223 class LoginHandler(AuthenticatedHandler):
224
224
225 def _render(self, message=None):
225 def _render(self, message=None):
226 nb = self.application.jinja2_env.get_template('login.html')
226 template = self.application.jinja2_env.get_template('login.html')
227 self.write( nb.render(
227 self.write( template.render(
228 next=self.get_argument('next', default=self.application.ipython_app.base_project_url),
228 next=self.get_argument('next', default=self.application.ipython_app.base_project_url),
229 read_only=self.read_only,
229 read_only=self.read_only,
230 logged_in=self.logged_in,
230 logged_in=self.logged_in,
@@ -260,8 +260,8 b' class LogoutHandler(AuthenticatedHandler):'
260 else:
260 else:
261 message = {'warning': 'Cannot log out. Notebook authentication '
261 message = {'warning': 'Cannot log out. Notebook authentication '
262 'is disabled.'}
262 'is disabled.'}
263 nb = self.application.jinja2_env.get_template('logout.html')
263 template = self.application.jinja2_env.get_template('logout.html')
264 self.write( nb.render(
264 self.write( template.render(
265 read_only=self.read_only,
265 read_only=self.read_only,
266 logged_in=self.logged_in,
266 logged_in=self.logged_in,
267 login_available=self.login_available,
267 login_available=self.login_available,
@@ -286,8 +286,8 b' class NamedNotebookHandler(AuthenticatedHandler):'
286 project = nbm.notebook_dir
286 project = nbm.notebook_dir
287 if not nbm.notebook_exists(notebook_id):
287 if not nbm.notebook_exists(notebook_id):
288 raise web.HTTPError(404, u'Notebook does not exist: %s' % notebook_id)
288 raise web.HTTPError(404, u'Notebook does not exist: %s' % notebook_id)
289 nb = self.application.jinja2_env.get_template('notebook.html')
289 template = self.application.jinja2_env.get_template('notebook.html')
290 self.write( nb.render(project=project,
290 self.write( template.render(project=project,
291 notebook_id=notebook_id,
291 notebook_id=notebook_id,
292 base_project_url=self.application.ipython_app.base_project_url,
292 base_project_url=self.application.ipython_app.base_project_url,
293 base_kernel_url=self.application.ipython_app.base_kernel_url,
293 base_kernel_url=self.application.ipython_app.base_kernel_url,
@@ -306,8 +306,8 b' class PrintNotebookHandler(AuthenticatedHandler):'
306 project = nbm.notebook_dir
306 project = nbm.notebook_dir
307 if not nbm.notebook_exists(notebook_id):
307 if not nbm.notebook_exists(notebook_id):
308 raise web.HTTPError(404, u'Notebook does not exist: %s' % notebook_id)
308 raise web.HTTPError(404, u'Notebook does not exist: %s' % notebook_id)
309 nb = self.application.jinja2_env.get_template('printnotebook.html')
309 template = self.application.jinja2_env.get_template('printnotebook.html')
310 self.write( nb.render(
310 self.write( template.render(
311 project=project,
311 project=project,
312 notebook_id=notebook_id,
312 notebook_id=notebook_id,
313 base_project_url=self.application.ipython_app.base_project_url,
313 base_project_url=self.application.ipython_app.base_project_url,
General Comments 0
You need to be logged in to leave comments. Login now