Commit 4cc07218 authored by Julia Radzhabova's avatar Julia Radzhabova

Update table settings in strict mode: change table style by one user and...

Update table settings in strict mode: change table style by one user and getting changes by another user (combodataview didn't update.).
parent 6019ee19
...@@ -430,7 +430,7 @@ define([ ...@@ -430,7 +430,7 @@ define([
if (this._initSettings) if (this._initSettings)
this.createDelayedElements(); this.createDelayedElements();
this.disableControls(this._locked); var updateState = this.disableControls(this._locked); // need to update combodataview after disabled state
if (props ) if (props )
{ {
...@@ -451,7 +451,7 @@ define([ ...@@ -451,7 +451,7 @@ define([
//for table-template //for table-template
value = props.get_TableStyle(); value = props.get_TableStyle();
if (this._state.TemplateId!==value || this._isTemplatesChanged) { if (this._state.TemplateId!==value || this._isTemplatesChanged || updateState) {
this.cmbTableTemplate.suspendEvents(); this.cmbTableTemplate.suspendEvents();
var rec = this.cmbTableTemplate.menuPicker.store.findWhere({ var rec = this.cmbTableTemplate.menuPicker.store.findWhere({
templateId: value templateId: value
...@@ -773,6 +773,7 @@ define([ ...@@ -773,6 +773,7 @@ define([
item.setDisabled(disable); item.setDisabled(disable);
}); });
this.linkAdvanced.toggleClass('disabled', disable); this.linkAdvanced.toggleClass('disabled', disable);
return !disable;
} }
}, },
......
...@@ -357,7 +357,7 @@ define([ ...@@ -357,7 +357,7 @@ define([
if (this._initSettings) if (this._initSettings)
this.createDelayedElements(); this.createDelayedElements();
this.disableControls(this._locked); var updateState = this.disableControls(this._locked); // need to update combodataview after disabled state
if (props ) if (props )
{ {
...@@ -366,7 +366,7 @@ define([ ...@@ -366,7 +366,7 @@ define([
//for table-template //for table-template
var value = props.get_TableStyle(); var value = props.get_TableStyle();
if (this._state.TemplateId!==value || this._isTemplatesChanged) { if (this._state.TemplateId!==value || this._isTemplatesChanged || updateState) {
this.cmbTableTemplate.suspendEvents(); this.cmbTableTemplate.suspendEvents();
var rec = this.cmbTableTemplate.menuPicker.store.findWhere({ var rec = this.cmbTableTemplate.menuPicker.store.findWhere({
templateId: value templateId: value
...@@ -663,6 +663,7 @@ define([ ...@@ -663,6 +663,7 @@ define([
item.setDisabled(disable); item.setDisabled(disable);
}); });
this.linkAdvanced.toggleClass('disabled', disable); this.linkAdvanced.toggleClass('disabled', disable);
return !disable;
} }
}, },
......
...@@ -325,7 +325,7 @@ define([ ...@@ -325,7 +325,7 @@ define([
if (this._initSettings) if (this._initSettings)
this.createDelayedControls(); this.createDelayedControls();
this.disableControls(this._locked); var updateState = this.disableControls(this._locked); // need to update combodataview after disabled state
if (props )//formatTableInfo if (props )//formatTableInfo
{ {
...@@ -395,7 +395,7 @@ define([ ...@@ -395,7 +395,7 @@ define([
//for table-template //for table-template
value = props.asc_getTableStyleName(); value = props.asc_getTableStyleName();
if (this._state.TemplateName!==value || this._isTemplatesChanged) { if (this._state.TemplateName!==value || this._isTemplatesChanged || updateState) {
this.cmbTableTemplate.suspendEvents(); this.cmbTableTemplate.suspendEvents();
var rec = this.cmbTableTemplate.menuPicker.store.findWhere({ var rec = this.cmbTableTemplate.menuPicker.store.findWhere({
name: value name: value
...@@ -508,6 +508,7 @@ define([ ...@@ -508,6 +508,7 @@ define([
item.setDisabled(disable); item.setDisabled(disable);
}); });
this.linkAdvanced.toggleClass('disabled', disable); this.linkAdvanced.toggleClass('disabled', disable);
return !disable;
} }
}, },
......
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