diff --git a/apps/spreadsheeteditor/main/app/controller/DataTab.js b/apps/spreadsheeteditor/main/app/controller/DataTab.js
index e99a4eb9ff..c7b3679712 100644
--- a/apps/spreadsheeteditor/main/app/controller/DataTab.js
+++ b/apps/spreadsheeteditor/main/app/controller/DataTab.js
@@ -629,15 +629,17 @@ define([
},
onNeedUpdateExternalReferenceOnOpen: function() {
+ var value = this.api.asc_getUpdateLinks();
Common.UI.warning({
- msg: this.warnUpdateExternalData,
- buttons: [{value: 'ok', caption: this.textUpdate, primary: true}, {value: 'cancel', caption: this.textDontUpdate}],
+ msg: value ? this.warnUpdateExternalAutoupdate : this.warnUpdateExternalData,
+ buttons: [{value: 'ok', caption: value ? this.textContinue : this.textUpdate, primary: true}, {value: 'cancel', caption: value ? this.textTurnOff : this.textDontUpdate}],
maxwidth: 600,
callback: _.bind(function(btn) {
if (btn==='ok') {
var links = this.api.asc_getExternalReferences();
links && (links.length>0) && this.api.asc_updateExternalReferences(links);
}
+ value && this.api.asc_setUpdateLinks(btn==='ok', true);
}, this)
});
},
@@ -705,7 +707,10 @@ define([
warnUpdateExternalData: 'This workbook contains links to one or more external sources that could be unsafe.
If you trust the links, update them to get the latest data.',
textUpdate: 'Update',
textDontUpdate: 'Don\'t Update',
- textAddExternalData: 'The link to an external source has been added. You can update such links in the Data tab.'
+ textAddExternalData: 'The link to an external source has been added. You can update such links in the Data tab.',
+ warnUpdateExternalAutoupdate: 'This workbook contains links that are updated automatically from external sources that could be unsafe.
If you trust the links, press \'Continue\' to update.',
+ textTurnOff: 'Turn off auto update',
+ textContinue: 'Continue'
}, SSE.Controllers.DataTab || {}));
});
\ No newline at end of file
diff --git a/apps/spreadsheeteditor/main/app/view/ExternalLinksDlg.js b/apps/spreadsheeteditor/main/app/view/ExternalLinksDlg.js
index c929ade71d..a4959b9273 100644
--- a/apps/spreadsheeteditor/main/app/view/ExternalLinksDlg.js
+++ b/apps/spreadsheeteditor/main/app/view/ExternalLinksDlg.js
@@ -63,7 +63,7 @@ define([
'
| ', + ' | ', '', '', '', @@ -71,10 +71,15 @@ define([ ' | ', '
| ', + ' | ', '', ' | ', '
| ', + '', + ' | ', + '