drop file ext off notebook name in notebook

This commit is contained in:
Zachary Sailer 2013-07-20 10:16:08 -07:00 committed by MinRK
parent f55381d55b
commit 6114d4c338
3 changed files with 6 additions and 6 deletions

View File

@ -1530,7 +1530,8 @@ var IPython = (function (IPython) {
* @return {String} This notebook's name
*/
Notebook.prototype.get_notebook_name = function () {
return this.notebook_name;
nbname = this.notebook_name.substring(0,this.notebook_name.length-6);
return nbname;
};
/**
@ -1680,7 +1681,6 @@ var IPython = (function (IPython) {
// time the ajax call for autosave tuning purposes.
var start = new Date().getTime();
console.log(JSON.stringify(data))
// We do the call with settings so we can set cache to false.
var settings = {
processData : false,
@ -1748,8 +1748,9 @@ var IPython = (function (IPython) {
};
Notebook.prototype.notebook_rename = function (new_name) {
Notebook.prototype.notebook_rename = function (nbname) {
var that = this;
var new_name = nbname + '.ipynb'
var name = {'notebook_name': new_name};
var settings = {
processData : false,

View File

@ -115,7 +115,6 @@ var IPython = (function (IPython) {
SaveWidget.prototype.update_notebook_name = function () {
var nbname = IPython.notebook.get_notebook_name();
console.log("UPDATED")
this.element.find('span#notebook_name').html(nbname);
};

View File

@ -225,8 +225,8 @@ var IPython = (function (IPython) {
var callbacks = {
'object_info_reply': $.proxy(this._show, this)
}
var oir_token = this.extract_oir_token(line)
cell.kernel.object_info_request(oir_token, callbacks);
var oir_token = this.extract_oir_token(line);
var msg_id = cell.session.kernel.object_info_request(oir_token, callbacks);
}
// make an imediate completion request