[WIP] Show server root directory in move dialog

Thomas Kluyver 9 years ago
parent 5fe331e77e
commit b2d048a85e

@ -255,6 +255,7 @@ class NotebookWebApplication(web.Application):
mathjax_config=jupyter_app.mathjax_config,
config=jupyter_app.config,
config_dir=jupyter_app.config_dir,
server_root_dir=jupyter_app.notebook_dir,
jinja2_env=env,
terminals_available=False, # Set later if terminals are available
)

@ -842,7 +842,15 @@ define([
.text('Enter new destination directory path for '+ num_items + ' items:')
).append(
$("<br/>")
).append(input);
).append(
$("<table/>").append(
$("<tr/>").append(
$("<td/>").text(utils.get_body_data('serverRoot'))
).append(
$("<td/>").append(input)
)
).css('width', '100%')
);
var d = dialog.modal({
title : "Move "+ num_items + " Items",
body : dialog_body,

@ -8,6 +8,7 @@
data-base-url="{{base_url | urlencode}}"
data-notebook-path="{{notebook_path | urlencode}}"
data-terminals-available="{{terminals_available}}"
data-server-root="{{server_root}}"
{% endblock %}

@ -49,6 +49,7 @@ class TreeHandler(IPythonHandler):
notebook_path=path,
breadcrumbs=breadcrumbs,
terminals_available=self.settings['terminals_available'],
server_root=self.settings['server_root_dir'],
))
elif cm.file_exists(path):
# it's not a directory, we have redirecting to do

Loading…
Cancel
Save