[SSE mobile] Fix Bug 53220

This commit is contained in:
SergeyEzhin 2021-10-19 20:16:14 +04:00
parent 224366ea99
commit 15b48fe3fb
2 changed files with 10 additions and 7 deletions

View file

@ -410,15 +410,18 @@ class MainController extends Component {
onChangeProtectSheet() {
const storeWorksheets = this.props.storeWorksheets;
let {wsLock, wsProps} = this.getWSProps(true);
storeWorksheets.setWsLock(wsLock);
storeWorksheets.setWsProps(wsProps);
if(wsProps) {
storeWorksheets.setWsLock(wsLock);
storeWorksheets.setWsProps(wsProps);
}
}
getWSProps(update) {
const storeAppOptions = this.props.storeAppOptions;
let wsProtection = {};
if (!storeAppOptions.config || !storeAppOptions.isEdit && !storeAppOptions.isRestrictedEdit) return;
if (!storeAppOptions.config || !storeAppOptions.isEdit && !storeAppOptions.isRestrictedEdit)
return wsProtection;
if (update) {
let wsLock = !!this.api.asc_isProtectedSheet();
@ -436,9 +439,9 @@ class MainController extends Component {
}
wsProtection = {wsLock, wsProps};
return wsProtection;
}
return wsProtection;
}
_onLongActionEnd(type, id) {

View file

@ -101,7 +101,7 @@ export class storeWorksheets {
this.isProtectedWorkbook = value;
}
wsProps = {};
wsProps;
setWsProps(value) {
this.wsProps = value;
}