Commit 109908a1 authored by Julia Radzhabova's avatar Julia Radzhabova

Versions History: изменено поле urlDiff на changesUrl.

parent 8b69324a
...@@ -165,7 +165,8 @@ ...@@ -165,7 +165,8 @@
{ {
'version': revision.data, 'version': revision.data,
'url': 'http://isa2', 'url': 'http://isa2',
'urlDiff': 'http://isa2' 'urlDiff': 'http://isa2',
'changesUrl': 'http://isa2'
} }
); );
} }
......
...@@ -100,18 +100,19 @@ define([ ...@@ -100,18 +100,19 @@ define([
if (historyStore && data!==null) { if (historyStore && data!==null) {
var rev, revisions = historyStore.findRevisions(data.version), var rev, revisions = historyStore.findRevisions(data.version),
urlGetTime = new Date(); urlGetTime = new Date();
var diff = opts.data.urlDiff || opts.data.changesUrl;
if (revisions && revisions.length>0) { if (revisions && revisions.length>0) {
for(var i=0; i<revisions.length; i++) { for(var i=0; i<revisions.length; i++) {
rev = revisions[i]; rev = revisions[i];
rev.set('url', opts.data.url, {silent: true}); rev.set('url', opts.data.url, {silent: true});
rev.set('urlDiff', opts.data.urlDiff, {silent: true}); rev.set('urlDiff', diff, {silent: true});
rev.set('urlGetTime', urlGetTime, {silent: true}); rev.set('urlGetTime', urlGetTime, {silent: true});
} }
} }
var hist = new Asc.asc_CVersionHistory(); var hist = new Asc.asc_CVersionHistory();
hist.asc_setUrl(opts.data.url); hist.asc_setUrl(opts.data.url);
hist.asc_setUrlChanges(opts.data.urlDiff); hist.asc_setUrlChanges(diff);
hist.asc_setDocId(_.isEmpty(opts.data.urlDiff) ? this.currentDocId : this.currentDocIdPrev); hist.asc_setDocId(_.isEmpty(diff) ? this.currentDocId : this.currentDocIdPrev);
hist.asc_setCurrentChangeId(this.currentChangeId); hist.asc_setCurrentChangeId(this.currentChangeId);
hist.asc_setArrColors(this.currentArrColors); hist.asc_setArrColors(this.currentArrColors);
this.api.asc_showRevision(hist); this.api.asc_showRevision(hist);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment