Merge pull request #1012 from ONLYOFFICE/fix/bugfix

[DE mobile] Fix track changes
This commit is contained in:
Julia Radzhabova 2021-07-23 00:45:06 +03:00 committed by GitHub
commit 60474c780b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -17,7 +17,10 @@ class InitReview extends Component {
Common.Notifications.on('document:ready', () => { Common.Notifications.on('document:ready', () => {
const api = Common.EditorApi.get(); const api = Common.EditorApi.get();
const appOptions = props.storeAppOptions; const appOptions = props.storeAppOptions;
api.asc_SetTrackRevisions(appOptions.isReviewOnly || LocalStorage.getBool("de-mobile-track-changes-" + (appOptions.fileKey || '')));
var trackChanges = typeof (appOptions.customization) == 'object' ? appOptions.customization.trackChanges : undefined;
api.asc_SetTrackRevisions(appOptions.isReviewOnly || trackChanges===true || (trackChanges!==false) && LocalStorage.getBool("de-mobile-track-changes-" + (appOptions.fileKey || '')));
// Init display mode // Init display mode
if (!appOptions.canReview) { if (!appOptions.canReview) {
const canViewReview = appOptions.isEdit || api.asc_HaveRevisionsChanges(true); const canViewReview = appOptions.isEdit || api.asc_HaveRevisionsChanges(true);