diff --git a/apps/documenteditor/main/app/controller/Links.js b/apps/documenteditor/main/app/controller/Links.js
index e68fd3772..4a76a9bbf 100644
--- a/apps/documenteditor/main/app/controller/Links.js
+++ b/apps/documenteditor/main/app/controller/Links.js
@@ -312,7 +312,7 @@ define([
},
onTableContentsOpen: function(menu) {
- this.api.asc_getButtonsTOC(menu.items[0].id, menu.items[1].id);
+ this.api.asc_getButtonsTOC(menu.items[0].options.previewId, menu.items[1].options.previewId);
},
onNotesClick: function(type) {
diff --git a/apps/documenteditor/main/app/view/Links.js b/apps/documenteditor/main/app/view/Links.js
index c02f2178c..04b925479 100644
--- a/apps/documenteditor/main/app/view/Links.js
+++ b/apps/documenteditor/main/app/view/Links.js
@@ -235,15 +235,15 @@ define([
(new Promise(function (accept, reject) {
accept();
})).then(function(){
- var contentsTemplate = _.template('');
+ var contentsTemplate = _.template('');
me.btnsContents.forEach( function(btn) {
btn.updateHint( me.tipContents );
var _menu = new Common.UI.Menu({
cls: 'toc-menu shifted-left',
items: [
- {template: contentsTemplate, offsety: 0, value: 0, id: 'id-toolbar-toc-0'},
- {template: contentsTemplate, offsety: 72, value: 1, id: 'id-toolbar-toc-1'},
+ {template: contentsTemplate, offsety: 0, value: 0, previewId: 'id-toolbar-toc-0'},
+ {template: contentsTemplate, offsety: 72, value: 1, previewId: 'id-toolbar-toc-1'},
{caption: me.textContentsSettings, value: 'settings'},
{caption: me.textContentsRemove, value: 'remove'}
]
@@ -255,8 +255,8 @@ define([
me.contentsMenu = new Common.UI.Menu({
cls: 'toc-menu shifted-left',
items: [
- {template: contentsTemplate, offsety: 0, value: 0, id: 'id-toolbar-toc-menu-0'},
- {template: contentsTemplate, offsety: 72, value: 1, id: 'id-toolbar-toc-menu-1'},
+ {template: contentsTemplate, offsety: 0, value: 0, previewId: 'id-toolbar-toc-menu-0'},
+ {template: contentsTemplate, offsety: 72, value: 1, previewId: 'id-toolbar-toc-menu-1'},
{caption: me.textContentsSettings, value: 'settings'},
{caption: me.textContentsRemove, value: 'remove'}
]