Merge pull request #30 from ONLYOFFICE/feature/bugfix-5.0.4

Feature/bugfix 5.0.4
This commit is contained in:
Julia Radzhabova 2017-11-02 15:29:42 +03:00 committed by GitHub
commit 8eb5acdbb8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 22 additions and 14 deletions

View file

@ -802,6 +802,8 @@ define([
saveTxtReplyId = uids[i] + '-R';
comment = this.findComment(saveTxtId);
if (!comment) continue;
if (this.subEditStrings[saveTxtId] && !hint) {
comment.set('editTextInPopover', true);
text = this.subEditStrings[saveTxtId];
@ -905,6 +907,8 @@ define([
saveTxtReplyId = uids[i] + '-R';
comment = this.findComment(saveTxtId);
if (!comment) continue;
if (this.subEditStrings[saveTxtId]) {
comment.set('editTextInPopover', true);
text = this.subEditStrings[saveTxtId];

View file

@ -91,14 +91,15 @@ var ApplicationController = new(function(){
if (docConfig) {
permissions = $.extend(permissions, docConfig.permissions);
var docInfo = new Asc.asc_CDocInfo();
var _permissions = $.extend({}, docConfig.permissions),
docInfo = new Asc.asc_CDocInfo();
docInfo.put_Id(docConfig.key);
docInfo.put_Url(docConfig.url);
docInfo.put_Title(docConfig.title);
docInfo.put_Format(docConfig.fileType);
docInfo.put_VKey(docConfig.vkey);
docInfo.put_Token(docConfig.token);
docInfo.put_Permissions(permissions);
docInfo.put_Permissions(_permissions);
if (api) {
api.asc_registerCallback('asc_onGetEditorPermissions', onEditorPermissions);

View file

@ -299,7 +299,8 @@ define([
if (data.doc) {
this.permissions = $.extend(this.permissions, data.doc.permissions);
var _user = new Asc.asc_CUserInfo();
var _permissions = $.extend({}, data.doc.permissions),
_user = new Asc.asc_CUserInfo();
_user.put_Id(this.appOptions.user.id);
_user.put_FullName(this.appOptions.user.fullname);
@ -313,7 +314,7 @@ define([
docInfo.put_UserInfo(_user);
docInfo.put_CallbackUrl(this.editorConfig.callbackUrl);
docInfo.put_Token(data.doc.token);
docInfo.put_Permissions(this.permissions);
docInfo.put_Permissions(_permissions);
//docInfo.put_OfflineApp(this.editorConfig.nativeApp === true);
}

View file

@ -344,8 +344,6 @@ define([
var count = this.api.getCountPages();
if (count !== this.pages.get('count'))
this.pages.set('count', count);
this.btnPrev.setDisabled(slideNum<=0);
this.btnNext.setDisabled(slideNum>=count-1);
this.txtGoToPage.setValue(slideNum + 1);
this.txtGoToPage.checkValidate();
}

View file

@ -217,7 +217,8 @@ define([
if (data.doc) {
this.permissions = $.extend(this.permissions, data.doc.permissions);
var _user = new Asc.asc_CUserInfo();
var _permissions = $.extend({}, data.doc.permissions),
_user = new Asc.asc_CUserInfo();
_user.put_Id(this.appOptions.user.id);
_user.put_FullName(this.appOptions.user.fullname);
@ -231,7 +232,7 @@ define([
docInfo.put_UserInfo(_user);
docInfo.put_CallbackUrl(this.editorConfig.callbackUrl);
docInfo.put_Token(data.doc.token);
docInfo.put_Permissions(this.permissions);
docInfo.put_Permissions(_permissions);
}
this.api.asc_registerCallback('asc_onGetEditorPermissions', _.bind(this.onEditorPermissions, this));

View file

@ -89,14 +89,15 @@ var ApplicationController = new(function(){
if (docConfig) {
permissions = $.extend(permissions, docConfig.permissions);
var docInfo = new Asc.asc_CDocInfo();
var _permissions = $.extend({}, docConfig.permissions),
docInfo = new Asc.asc_CDocInfo();
docInfo.put_Id(docConfig.key);
docInfo.put_Url(docConfig.url);
docInfo.put_Title(docConfig.title);
docInfo.put_Format(docConfig.fileType);
docInfo.put_VKey(docConfig.vkey);
docInfo.put_Token(docConfig.token);
docInfo.put_Permissions(permissions);
docInfo.put_Permissions(_permissions);
if (api) {
api.asc_registerCallback('asc_onGetEditorPermissions', onEditorPermissions);

View file

@ -334,7 +334,8 @@ define([
if (data.doc) {
this.permissions = _.extend(this.permissions, data.doc.permissions);
var _user = new Asc.asc_CUserInfo();
var _permissions = $.extend({}, data.doc.permissions),
_user = new Asc.asc_CUserInfo();
_user.put_Id(this.appOptions.user.id);
_user.put_FullName(this.appOptions.user.fullname);
@ -348,7 +349,7 @@ define([
docInfo.put_UserInfo(_user);
docInfo.put_CallbackUrl(this.editorConfig.callbackUrl);
docInfo.put_Token(data.doc.token);
docInfo.put_Permissions(this.permissions);
docInfo.put_Permissions(_permissions);
this.headerView.setDocumentCaption(data.doc.title);
}

View file

@ -220,7 +220,8 @@ define([
if ( data.doc ) {
this.permissions = $.extend(this.permissions, data.doc.permissions);
var _user = new Asc.asc_CUserInfo();
var _permissions = $.extend({}, data.doc.permissions),
_user = new Asc.asc_CUserInfo();
_user.put_Id(this.appOptions.user.id);
_user.put_FullName(this.appOptions.user.fullname);
@ -234,7 +235,7 @@ define([
docInfo.put_UserInfo(_user);
docInfo.put_CallbackUrl(this.editorConfig.callbackUrl);
docInfo.put_Token(data.doc.token);
docInfo.put_Permissions(this.permissions);
docInfo.put_Permissions(_permissions);
}
this.api.asc_registerCallback('asc_onGetEditorPermissions', _.bind(this.onEditorPermissions, this));