diff --git a/apps/spreadsheeteditor/mobile/src/view/FilterOptions.jsx b/apps/spreadsheeteditor/mobile/src/view/FilterOptions.jsx
index 87191bf85..885570b96 100644
--- a/apps/spreadsheeteditor/mobile/src/view/FilterOptions.jsx
+++ b/apps/spreadsheeteditor/mobile/src/view/FilterOptions.jsx
@@ -2,10 +2,13 @@ import React, {useEffect, useState} from 'react';
import {f7, List, Popover, Sheet, ListItem, Icon, Row, Button, ListButton, Page, Navbar, Segmented, BlockTitle, NavRight, Link, Toggle,View} from 'framework7-react';
import { useTranslation } from 'react-i18next';
import { Device } from '../../../../common/mobile/utils/device';
+import {observer, inject} from "mobx-react";
-const FilterOptions = (props) => {
+const FilterOptions = inject('storeAppOptions')(observer(props => {
const { t } = useTranslation();
const _t = t('View.Edit', {returnObjects: true});
+ const storeAppOptions = props.storeAppOptions;
+ const canModifyFilter = storeAppOptions.canModifyFilter;
let is_all_checked = props.listVal.every(item => item.check);
const HandleClearFilter = () => {
@@ -27,57 +30,71 @@ const FilterOptions = (props) => {
}).open();
}
};
-
+
return (
-
- {Device.phone &&
-
-
-
-
-
- }
-
-
-
-
-
- {props.onSort('sortdown'); onValidChecked();}}>
-
-
- {props.onSort('sortup'); onValidChecked();}}>
-
-
-
-
-
-
-
- {_t.textClearFilter}
- props.onDeleteFilter()} id="btn-delete-filter">{_t.textDeleteFilter}
-
-
- {props.onUpdateCell('all', e.target.checked); onValidChecked();}} name='filter-cellAll' checkbox checked={is_all_checked}>{_t.textSelectAll}
- {props.listVal.map((value) =>
- {props.onUpdateCell(value.id, e.target.checked); onValidChecked();}} key={value.value} name='filter-cell' value={value.value} title={value.cellvalue} checkbox checked={value.check} />
- )}
-
+
+ {Device.phone &&
+
+
+
+
+
+ }
+
+
+
+
+ {
+ props.onSort('sortdown');
+ onValidChecked();
+ }}>
+
+
+ {
+ props.onSort('sortup');
+ onValidChecked();
+ }}>
+
+
+
+
+
+
+ {_t.textClearFilter}
+ props.onDeleteFilter()}
+ id="btn-delete-filter">{_t.textDeleteFilter}
+
+
+ {
+ props.onUpdateCell('all', e.target.checked);
+ onValidChecked();
+ }} name='filter-cellAll' checkbox checked={is_all_checked}>{_t.textSelectAll}
+ {props.listVal.map((value) =>
+ {
+ props.onUpdateCell(value.id, e.target.checked);
+ onValidChecked();
+ }} key={value.value} name='filter-cell' value={value.value} title={value.cellvalue} checkbox
+ checked={value.check}/>
+ )}
+
)
-};
+}));
const FilterView = (props) => {
return (
!Device.phone ?
-
-
- :
-
-
-
+
+
+ :
+
+
+
)
}
diff --git a/apps/spreadsheeteditor/mobile/src/view/add/AddOther.jsx b/apps/spreadsheeteditor/mobile/src/view/add/AddOther.jsx
index f793a0d46..23ad2f553 100644
--- a/apps/spreadsheeteditor/mobile/src/view/add/AddOther.jsx
+++ b/apps/spreadsheeteditor/mobile/src/view/add/AddOther.jsx
@@ -3,10 +3,12 @@ import { inject, observer } from 'mobx-react';
import {List, ListItem, Icon} from 'framework7-react';
import { useTranslation } from 'react-i18next';
-const AddOther = inject("storeFocusObjects")(observer(props => {
+const AddOther = inject("storeFocusObjects", "storeAppOptions")(observer(props => {
const { t } = useTranslation();
const _t = t('View.Add', {returnObjects: true});
const storeFocusObjects = props.storeFocusObjects;
+ const storeAppOptions = props.storeAppOptions;
+ const canModifyFilter = storeAppOptions.canModifyFilter;
const isHyperLink = storeFocusObjects.selections.indexOf('hyperlink') > -1;
const hideAddComment = props.hideAddComment();
const wsProps = props.wsProps;
@@ -22,7 +24,7 @@ const AddOther = inject("storeFocusObjects")(observer(props => {
}}>
}
-
+