Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
W
web-apps
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boris Kocherov
web-apps
Commits
faa1d536
Commit
faa1d536
authored
Feb 17, 2017
by
Julia Radzhabova
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[DE] Set token for history version.
parent
2ce099aa
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
1 deletion
+7
-1
apps/common/main/lib/controller/History.js
apps/common/main/lib/controller/History.js
+6
-1
apps/common/main/lib/model/HistoryVersion.js
apps/common/main/lib/model/HistoryVersion.js
+1
-0
No files found.
apps/common/main/lib/controller/History.js
View file @
faa1d536
...
...
@@ -134,12 +134,14 @@ define([
},
10
);
}
else
{
var
urlDiff
=
record
.
get
(
'
urlDiff
'
),
token
=
record
.
get
(
'
token
'
),
hist
=
new
Asc
.
asc_CVersionHistory
();
hist
.
asc_setDocId
(
_
.
isEmpty
(
urlDiff
)
?
this
.
currentDocId
:
this
.
currentDocIdPrev
);
hist
.
asc_setUrl
(
url
);
hist
.
asc_setUrlChanges
(
urlDiff
);
hist
.
asc_setCurrentChangeId
(
this
.
currentChangeId
);
hist
.
asc_setArrColors
(
this
.
currentArrColors
);
hist
.
asc_setToken
(
token
);
this
.
api
.
asc_showRevision
(
hist
);
var
commentsController
=
this
.
getApplication
().
getController
(
'
Common.Controllers.Comments
'
);
...
...
@@ -166,7 +168,8 @@ define([
var
diff
=
(
this
.
currentChangeId
===
undefined
)
?
null
:
opts
.
data
.
changesUrl
,
// if revision has changes, but serverVersion !== app.buildVersion -> hide revision changes
url
=
(
!
_
.
isEmpty
(
diff
)
&&
opts
.
data
.
previous
)
?
opts
.
data
.
previous
.
url
:
opts
.
data
.
url
,
docId
=
opts
.
data
.
key
?
opts
.
data
.
key
:
this
.
currentDocId
,
docIdPrev
=
opts
.
data
.
previous
&&
opts
.
data
.
previous
.
key
?
opts
.
data
.
previous
.
key
:
this
.
currentDocIdPrev
;
docIdPrev
=
opts
.
data
.
previous
&&
opts
.
data
.
previous
.
key
?
opts
.
data
.
previous
.
key
:
this
.
currentDocIdPrev
,
token
=
opts
.
data
.
token
;
if
(
revisions
&&
revisions
.
length
>
0
)
{
for
(
var
i
=
0
;
i
<
revisions
.
length
;
i
++
)
{
...
...
@@ -178,6 +181,7 @@ define([
rev
.
set
(
'
docId
'
,
docId
,
{
silent
:
true
});
rev
.
set
(
'
docIdPrev
'
,
docIdPrev
,
{
silent
:
true
});
}
rev
.
set
(
'
token
'
,
token
,
{
silent
:
true
});
}
}
var
hist
=
new
Asc
.
asc_CVersionHistory
();
...
...
@@ -186,6 +190,7 @@ define([
hist
.
asc_setDocId
(
_
.
isEmpty
(
diff
)
?
docId
:
docIdPrev
);
hist
.
asc_setCurrentChangeId
(
this
.
currentChangeId
);
hist
.
asc_setArrColors
(
this
.
currentArrColors
);
hist
.
asc_setToken
(
token
);
this
.
api
.
asc_showRevision
(
hist
);
var
commentsController
=
this
.
getApplication
().
getController
(
'
Common.Controllers.Comments
'
);
...
...
apps/common/main/lib/model/HistoryVersion.js
View file @
faa1d536
...
...
@@ -64,6 +64,7 @@ define([
urlGetTime
:
''
,
docId
:
''
,
docIdPrev
:
''
,
token
:
''
,
arrColors
:
[],
// array of user colors for all changes of current version
markedAsVersion
:
false
,
canRestore
:
false
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment