fnp
/
fnpeditor.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Moving caret back to selected node when documentCanvas is shown again
[fnpeditor.git]
/
modules
/
data
/
data.js
diff --git
a/modules/data/data.js
b/modules/data/data.js
index
e2cdbb1
..
108f2ea
100644
(file)
--- a/
modules/data/data.js
+++ b/
modules/data/data.js
@@
-6,6
+6,7
@@
return function(sandbox) {
\r
var doc = sandbox.getBootstrappedData().document;
\r
var document_id = sandbox.getBootstrappedData().document_id;
\r
\r
var doc = sandbox.getBootstrappedData().document;
\r
var document_id = sandbox.getBootstrappedData().document_id;
\r
+ var document_version = sandbox.getBootstrappedData().version
\r
var history = sandbox.getBootstrappedData().history;
\r
\r
\r
var history = sandbox.getBootstrappedData().history;
\r
\r
\r
@@
-113,14
+114,18
@@
return function(sandbox) {
data: JSON.stringify(options),
\r
success: function(data) {
\r
doc = data.document;
\r
data: JSON.stringify(options),
\r
success: function(data) {
\r
doc = data.document;
\r
+ document_version = data.version;
\r
reloadHistory();
\r
reloadHistory();
\r
- sandbox.publish('documentReverted',
{document: data.document, version: data.version}
);
\r
+ sandbox.publish('documentReverted',
data
);
\r
},
\r
});
\r
}
\r
},
\r
getDocumentId: function() {
\r
return document_id;
\r
},
\r
});
\r
}
\r
},
\r
getDocumentId: function() {
\r
return document_id;
\r
+ },
\r
+ getDocumentVersion: function() {
\r
+ return document_version;
\r
}
\r
}
\r
};
\r
}
\r
}
\r
};
\r