[SSE] Fix Bug 52947
This commit is contained in:
parent
acd44354ee
commit
f4010ee3d4
|
@ -395,6 +395,8 @@ class MainController extends Component {
|
||||||
storeFocusObjects.setEditFormulaMode(isFormula);
|
storeFocusObjects.setEditFormulaMode(isFormula);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
storeFocusObjects.setFunctionsDisabled(state === Asc.c_oAscCellEditorState.editText);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -19,7 +19,9 @@ export class storeFocusObjects {
|
||||||
editFormulaMode: observable,
|
editFormulaMode: observable,
|
||||||
setEditFormulaMode: action,
|
setEditFormulaMode: action,
|
||||||
isEditCell: observable,
|
isEditCell: observable,
|
||||||
setEditCell: action
|
setEditCell: action,
|
||||||
|
functionsDisable: observable,
|
||||||
|
setFunctionsDisabled: action,
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -122,4 +124,10 @@ export class storeFocusObjects {
|
||||||
this.isEditCell = value;
|
this.isEditCell = value;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
functionsDisable = false;
|
||||||
|
|
||||||
|
setFunctionsDisabled(value) {
|
||||||
|
this.functionsDisable = value;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
|
@ -87,6 +87,7 @@ const CellEditorView = props => {
|
||||||
const isPhone = Device.isPhone;
|
const isPhone = Device.isPhone;
|
||||||
const storeAppOptions = props.storeAppOptions;
|
const storeAppOptions = props.storeAppOptions;
|
||||||
const storeFunctions = props.storeFunctions;
|
const storeFunctions = props.storeFunctions;
|
||||||
|
const {functionsDisable} = props.storeFocusObjects;
|
||||||
const functions = storeFunctions.functions;
|
const functions = storeFunctions.functions;
|
||||||
const isEdit = storeAppOptions.isEdit;
|
const isEdit = storeAppOptions.isEdit;
|
||||||
const funcArr = props.funcArr;
|
const funcArr = props.funcArr;
|
||||||
|
@ -100,7 +101,7 @@ const CellEditorView = props => {
|
||||||
<View id="idx-celleditor" style={viewStyle} routes={routes} className={expanded ? 'cell-editor expanded' : 'cell-editor collapsed'}>
|
<View id="idx-celleditor" style={viewStyle} routes={routes} className={expanded ? 'cell-editor expanded' : 'cell-editor collapsed'}>
|
||||||
<div id="box-cell-name" className="ce-group">
|
<div id="box-cell-name" className="ce-group">
|
||||||
<span id="idx-cell-name">{props.cellName}</span>
|
<span id="idx-cell-name">{props.cellName}</span>
|
||||||
<a href="#" id="idx-btn-function" className='link icon-only' disabled={(!isEdit && true) || props.stateCoauth} onClick={() => {props.onClickToOpenAddOptions('function', '#idx-btn-function');}}>
|
<a href="#" id="idx-btn-function" className='link icon-only' disabled={(!isEdit && true) || props.stateCoauth || functionsDisable} onClick={() => {props.onClickToOpenAddOptions('function', '#idx-btn-function');}}>
|
||||||
<i className="icon icon-function" />
|
<i className="icon icon-function" />
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
|
@ -154,4 +155,4 @@ const routes = [
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
||||||
export default inject("storeAppOptions", "storeFunctions")(observer(CellEditorView));
|
export default inject("storeAppOptions", "storeFunctions", "storeFocusObjects")(observer(CellEditorView));
|
||||||
|
|
Loading…
Reference in a new issue