dtable-ui-component 7.0.13 → 7.0.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/ActionSheet/index.js +58 -49
- package/lib/ActivityIndicator/index.js +17 -16
- package/lib/AsyncUserSelect/index.js +20 -46
- package/lib/AsyncUserSelect/user-item.js +6 -5
- package/lib/AutoNumberFormatter/index.js +4 -3
- package/lib/Badge/index.js +27 -29
- package/lib/ButtonFormatter/index.js +8 -6
- package/lib/CTimeFormatter/index.js +4 -3
- package/lib/CheckboxEditor/index.js +16 -13
- package/lib/CheckboxEditor/mb-editor.js +20 -9
- package/lib/CheckboxEditor/pc-editor.js +24 -12
- package/lib/CheckboxFormatter/index.js +5 -4
- package/lib/CollaboratorEditor/index.js +17 -14
- package/lib/CollaboratorEditor/mb-editor/index.js +19 -11
- package/lib/CollaboratorEditor/pc-editor/index.js +35 -26
- package/lib/CollaboratorFormatter/index.js +10 -8
- package/lib/CollaboratorItem/index.js +5 -4
- package/lib/CollapsibleSettingLayout/index.js +8 -10
- package/lib/Comment/body/comment.js +19 -11
- package/lib/Comment/body/index.js +8 -8
- package/lib/Comment/footer/btns/index.js +7 -4
- package/lib/Comment/footer/index.js +21 -10
- package/lib/Comment/footer/input/index.js +55 -34
- package/lib/Comment/footer/input/participant/index.js +6 -5
- package/lib/Comment/footer/participants/index.js +5 -4
- package/lib/Comment/footer/participants/participant/index.js +3 -1
- package/lib/Comment/footer/participants/participant-select/index.js +26 -10
- package/lib/Comment/index.js +57 -39
- package/lib/Comment/utils/utilities.js +22 -16
- package/lib/CreatorFormatter/index.js +8 -6
- package/lib/DTableColorPicker/ColorPickerPortal/index.js +26 -28
- package/lib/DTableColorPicker/index.js +53 -67
- package/lib/DTableColorPicker/utils.js +7 -5
- package/lib/DTableColumnIcon/index.js +7 -6
- package/lib/DTableCommonAddTool/index.js +10 -8
- package/lib/DTableCustomFooter/index.js +3 -1
- package/lib/DTableCustomizeSearchInput/index.js +41 -26
- package/lib/DTableCustomizeSelect/index.js +24 -19
- package/lib/DTableDropdownItem/index.js +28 -24
- package/lib/DTableDropdownMenu/index.js +17 -14
- package/lib/DTableEmptyTip/index.js +5 -4
- package/lib/DTableFiltersPopover/index.js +42 -27
- package/lib/DTableFiltersPopover/utils/filter-item-utils.js +3 -1
- package/lib/DTableFiltersPopover/utils/index.js +114 -64
- package/lib/DTableFiltersPopover/widgets/collaborator-filter/index.js +9 -8
- package/lib/DTableFiltersPopover/widgets/department-select-filter/department-multiple-select-filter.js +13 -16
- package/lib/DTableFiltersPopover/widgets/department-select-filter/department-single-select-filter.js +15 -18
- package/lib/DTableFiltersPopover/widgets/filter-calendar.js +14 -8
- package/lib/DTableFiltersPopover/widgets/filter-group.js +57 -36
- package/lib/DTableFiltersPopover/widgets/filter-item.js +165 -106
- package/lib/DTableFiltersPopover/widgets/filter-list/index.js +162 -137
- package/lib/DTableFiltersPopover/widgets/rate-item.js +25 -20
- package/lib/DTableIcon/index.js +11 -10
- package/lib/DTableIcon/svg-icon.js +11 -9
- package/lib/DTableModalHeader/index.js +7 -7
- package/lib/DTablePopover/index.js +16 -12
- package/lib/DTableRadio/index.js +9 -10
- package/lib/DTableRadioGroup/index.js +20 -11
- package/lib/DTableSearchInput/index.js +29 -19
- package/lib/DTableSelect/dtable-select-label.js +6 -7
- package/lib/DTableSelect/index.js +26 -25
- package/lib/DTableSelect/select-dropdown-indicator/index.js +3 -1
- package/lib/DTableSelect/utils.js +83 -47
- package/lib/DTableSubDropdownMenu/index.js +16 -12
- package/lib/DTableSubDropdownToggle/index.js +16 -17
- package/lib/DTableSwitch/index.js +11 -12
- package/lib/DTableToolTip/index.js +12 -11
- package/lib/DateEditor/index.js +28 -30
- package/lib/DateEditor/mb-editor/index.js +31 -18
- package/lib/DateEditor/pc-editor.js +46 -27
- package/lib/DateFormatter/index.js +5 -4
- package/lib/DatePicker/index.js +15 -9
- package/lib/DatePicker/utils.js +7 -5
- package/lib/DeleteTip/index.js +6 -5
- package/lib/DepartmentMultipleSelectEditor/index.js +26 -28
- package/lib/DepartmentSelectFilter/index.js +13 -8
- package/lib/DepartmentSingleSelectEditor/index.js +16 -13
- package/lib/DepartmentSingleSelectEditor/mb-editor/index.js +49 -50
- package/lib/DepartmentSingleSelectEditor/pc-editor/department-single-select.js +64 -42
- package/lib/DepartmentSingleSelectEditor/pc-editor/index.js +19 -13
- package/lib/DepartmentSingleSelectFormatter/index.js +6 -4
- package/lib/DigitalSignEditor/index.js +16 -13
- package/lib/DigitalSignEditor/mb-editor/index.js +24 -16
- package/lib/DigitalSignEditor/pc-editor/index.js +31 -23
- package/lib/DigitalSignEditor/service.js +5 -3
- package/lib/DigitalSignEditor/signature-board/index.js +10 -7
- package/lib/DigitalSignEditor/utils.js +4 -2
- package/lib/DigitalSignFormatter/index.js +15 -12
- package/lib/DigitalSignFormatter/utils.js +6 -5
- package/lib/Drawer/index.js +3 -2
- package/lib/DurationEditor/index.js +31 -21
- package/lib/DurationFormatter/index.js +5 -4
- package/lib/EditEditorButton/index.js +3 -1
- package/lib/EmailFormatter/index.js +4 -3
- package/lib/FieldDisplaySetting/field-item.js +13 -13
- package/lib/FieldDisplaySetting/index.js +20 -20
- package/lib/FileEditor/files-previewer/index.js +16 -13
- package/lib/FileEditor/files-previewer/mb-previewer/file-previewer/index.js +20 -12
- package/lib/FileEditor/files-previewer/mb-previewer/index.js +8 -7
- package/lib/FileEditor/files-previewer/pc-previewer/file-previewer/dropdown-menu.js +4 -3
- package/lib/FileEditor/files-previewer/pc-previewer/file-previewer/file-name-editor/index.js +6 -5
- package/lib/FileEditor/files-previewer/pc-previewer/file-previewer/index.js +24 -17
- package/lib/FileEditor/files-previewer/pc-previewer/index.js +57 -29
- package/lib/FileEditor/index.js +16 -13
- package/lib/FileEditor/mb-editor/index.js +20 -28
- package/lib/FileEditor/pc-editor/addition-previewer/index.js +4 -2
- package/lib/FileEditor/pc-editor/addition-previewer/local-file-addition/index.js +31 -17
- package/lib/FileEditor/pc-editor/index.js +30 -22
- package/lib/FileFormatter/index.js +20 -27
- package/lib/FileItemFormatter/index.js +10 -7
- package/lib/FileUploader/index.js +46 -29
- package/lib/FormulaFormatter/index.js +44 -24
- package/lib/GeolocationEditor/index.js +32 -27
- package/lib/GeolocationEditor/map-editor-utils.js +23 -21
- package/lib/GeolocationEditor/mb-editor/country-editor.js +14 -17
- package/lib/GeolocationEditor/mb-editor/index.js +28 -22
- package/lib/GeolocationEditor/mb-editor/location-editor.js +15 -18
- package/lib/GeolocationEditor/mb-editor/map-editor/index.js +77 -47
- package/lib/GeolocationEditor/mb-editor/map-selection-editor/index.js +89 -50
- package/lib/GeolocationEditor/mb-editor/province-city-editor.js +14 -17
- package/lib/GeolocationEditor/mb-editor/province-editor.js +14 -17
- package/lib/GeolocationEditor/pc-editor/country-editor.js +25 -12
- package/lib/GeolocationEditor/pc-editor/index.js +41 -27
- package/lib/GeolocationEditor/pc-editor/location-editor.js +33 -28
- package/lib/GeolocationEditor/pc-editor/map-editor/index.js +67 -43
- package/lib/GeolocationEditor/pc-editor/map-editor/large-editor/index.js +69 -42
- package/lib/GeolocationEditor/pc-editor/map-selection-editor/index.js +86 -42
- package/lib/GeolocationEditor/pc-editor/map-selection-editor/large-editor/index.js +85 -39
- package/lib/GeolocationEditor/pc-editor/province-city-editor.js +26 -20
- package/lib/GeolocationEditor/pc-editor/province-editor.js +15 -8
- package/lib/GeolocationEditor/pc-editor/selector-header-item.js +6 -5
- package/lib/GeolocationEditor/pc-editor/selector-list.js +8 -7
- package/lib/GeolocationFormatter/index.js +5 -4
- package/lib/HtmlLongTextFormatter/index.js +13 -5
- package/lib/Icon/index.js +13 -15
- package/lib/Icon/load-sprite.js +13 -2
- package/lib/IconButton/index.js +12 -13
- package/lib/ImageEditor/images-previewer/image-preview/index.js +22 -13
- package/lib/ImageEditor/images-previewer/index.js +9 -3
- package/lib/ImageEditor/index.js +16 -13
- package/lib/ImageEditor/mb-editor/index.js +20 -28
- package/lib/ImageEditor/pc-editor/addition-previewer/image-link/index.js +6 -2
- package/lib/ImageEditor/pc-editor/addition-previewer/index.js +5 -3
- package/lib/ImageEditor/pc-editor/addition-previewer/local-image-addition/index.js +26 -12
- package/lib/ImageEditor/pc-editor/images-previewer/index.js +10 -4
- package/lib/ImageEditor/pc-editor/index.js +16 -11
- package/lib/ImageFormatter/images-lazy-load.js +11 -19
- package/lib/ImageFormatter/index.js +14 -12
- package/lib/ImagePreviewerLightbox/index.js +15 -19
- package/lib/ImageThumbnail/index.js +15 -12
- package/lib/InputItem/custom-input.js +55 -35
- package/lib/InputItem/custom-keyboard.js +42 -42
- package/lib/InputItem/index.js +82 -63
- package/lib/InputItem/input.js +9 -11
- package/lib/LastModifierFormatter/index.js +8 -6
- package/lib/LinkEditor/index.js +53 -33
- package/lib/LinkEditor/link-editor-option.js +4 -3
- package/lib/LinkEditor/mb-popover/index.js +22 -9
- package/lib/LinkEditor/pc-popover/index.js +13 -7
- package/lib/LinkFormatter/index.js +37 -21
- package/lib/List/index.js +17 -19
- package/lib/List/list-item.js +59 -55
- package/lib/LongTextFormatter/index.js +5 -4
- package/lib/MBEditorHeader/index.js +9 -8
- package/lib/MTimeFormatter/index.js +4 -3
- package/lib/MobileFullScreenPage/body/index.js +6 -4
- package/lib/MobileFullScreenPage/header/index.js +10 -8
- package/lib/MobileFullScreenPage/index.js +12 -14
- package/lib/MobileModal/index.js +7 -8
- package/lib/MobileOperationSheet/index.js +8 -7
- package/lib/MobileSelector/empty/index.js +3 -1
- package/lib/MobileSelector/index.js +7 -5
- package/lib/MobileSelector/option/index.js +5 -3
- package/lib/MobileSelector/options/index.css +0 -4
- package/lib/MobileSelector/options/index.js +3 -1
- package/lib/MobileSelector/search/index.js +5 -3
- package/lib/MobileUpload/index.js +5 -4
- package/lib/Modal/alert.js +2 -2
- package/lib/Modal/modal.js +28 -30
- package/lib/Modal/prompt.js +14 -14
- package/lib/MultipleSelectEditor/index.js +7 -7
- package/lib/MultipleSelectFormatter/index.js +9 -7
- package/lib/NotificationPopover/index.js +5 -4
- package/lib/NumberEditor/index.js +21 -12
- package/lib/NumberFormatter/index.js +5 -4
- package/lib/PhoneNumberLink/index.js +5 -3
- package/lib/Picker/AbstractPicker.js +35 -33
- package/lib/Popover/index.js +9 -11
- package/lib/Popover/item.js +22 -24
- package/lib/Progress/index.js +18 -17
- package/lib/Radio/Radio.js +17 -15
- package/lib/Radio/RadioItem.js +23 -19
- package/lib/RateFormatter/index.js +15 -15
- package/lib/RoleStatusEditor/index.js +18 -19
- package/lib/RowExpand/index.js +7 -6
- package/lib/RowExpandDialog/body/index.js +57 -40
- package/lib/RowExpandDialog/column-content/index.js +10 -6
- package/lib/RowExpandDialog/header/index.js +12 -9
- package/lib/RowExpandDialog/index.js +59 -63
- package/lib/RowExpandEditor/add-btn/index.js +7 -6
- package/lib/RowExpandEditor/checkbox-editor/index.js +7 -6
- package/lib/RowExpandEditor/checkbox-editor/mb-editor/index.js +5 -4
- package/lib/RowExpandEditor/checkbox-editor/pc-editor.js +10 -8
- package/lib/RowExpandEditor/collaborator-editor/index.js +7 -6
- package/lib/RowExpandEditor/collaborator-editor/mb-editor/index.js +33 -22
- package/lib/RowExpandEditor/collaborator-editor/pc-editor/index.js +40 -26
- package/lib/RowExpandEditor/date-editor/index.js +7 -6
- package/lib/RowExpandEditor/date-editor/mb-editor.js +18 -12
- package/lib/RowExpandEditor/date-editor/pc-editor.js +20 -15
- package/lib/RowExpandEditor/department-editor/index.js +7 -6
- package/lib/RowExpandEditor/department-editor/mb-editor.js +11 -16
- package/lib/RowExpandEditor/department-editor/pc-editor.js +14 -19
- package/lib/RowExpandEditor/digital-sign-editor/index.js +7 -6
- package/lib/RowExpandEditor/digital-sign-editor/mb-editor/index.js +38 -24
- package/lib/RowExpandEditor/digital-sign-editor/pc-editor/index.js +39 -25
- package/lib/RowExpandEditor/duration-editor/index.js +7 -6
- package/lib/RowExpandEditor/duration-editor/mb-editor.js +17 -10
- package/lib/RowExpandEditor/duration-editor/pc-editor.js +19 -13
- package/lib/RowExpandEditor/email-editor/index.js +7 -6
- package/lib/RowExpandEditor/email-editor/mb-editor/index.js +20 -10
- package/lib/RowExpandEditor/email-editor/pc-editor/index.js +25 -14
- package/lib/RowExpandEditor/file-editor/index.js +7 -6
- package/lib/RowExpandEditor/file-editor/mb-editor/index.js +31 -18
- package/lib/RowExpandEditor/file-editor/pc-editor/index.js +23 -16
- package/lib/RowExpandEditor/geolocation-editor/index.js +7 -6
- package/lib/RowExpandEditor/geolocation-editor/mb-editor/index.js +29 -17
- package/lib/RowExpandEditor/geolocation-editor/pc-editor/index.js +26 -13
- package/lib/RowExpandEditor/image-editor/index.js +7 -6
- package/lib/RowExpandEditor/image-editor/mb-editor/index.js +26 -16
- package/lib/RowExpandEditor/image-editor/pc-editor/index.js +24 -14
- package/lib/RowExpandEditor/index.js +16 -11
- package/lib/RowExpandEditor/long-text-editor/index.js +7 -6
- package/lib/RowExpandEditor/long-text-editor/mb-editor/editor/index.js +18 -17
- package/lib/RowExpandEditor/long-text-editor/mb-editor/index.js +16 -10
- package/lib/RowExpandEditor/long-text-editor/pc-editor/index.js +23 -16
- package/lib/RowExpandEditor/multiple-select-editor/index.js +7 -6
- package/lib/RowExpandEditor/multiple-select-editor/mb-editor/index.js +20 -12
- package/lib/RowExpandEditor/multiple-select-editor/pc-editor/index.js +38 -27
- package/lib/RowExpandEditor/number-editor/index.js +7 -6
- package/lib/RowExpandEditor/number-editor/mb-editor/index.js +14 -8
- package/lib/RowExpandEditor/number-editor/pc-editor.js +20 -13
- package/lib/RowExpandEditor/rate-editor/index.js +7 -6
- package/lib/RowExpandEditor/rate-editor/mb-editor.js +26 -13
- package/lib/RowExpandEditor/rate-editor/pc-editor.js +41 -25
- package/lib/RowExpandEditor/single-select-editor/index.js +7 -6
- package/lib/RowExpandEditor/single-select-editor/mb-editor/index.js +32 -21
- package/lib/RowExpandEditor/single-select-editor/pc-editor/index.js +37 -25
- package/lib/RowExpandEditor/text-editor/index.js +7 -6
- package/lib/RowExpandEditor/text-editor/mb-editor/index.js +5 -4
- package/lib/RowExpandEditor/text-editor/pc-editor/index.js +26 -15
- package/lib/RowExpandEditor/url-editor/index.js +7 -6
- package/lib/RowExpandEditor/url-editor/mb-editor/index.js +15 -7
- package/lib/RowExpandEditor/url-editor/pc-editor/index.js +20 -11
- package/lib/RowExpandFormatter/department-formatter/index.js +6 -3
- package/lib/RowExpandFormatter/department-formatter/mb-formatter.js +4 -2
- package/lib/RowExpandFormatter/department-formatter/pc-formatter.js +4 -2
- package/lib/RowExpandFormatter/email-formatter/index.js +8 -5
- package/lib/RowExpandFormatter/file-formatter/index.js +9 -8
- package/lib/RowExpandFormatter/file-formatter/row-expand-file-item-formatter.js +14 -12
- package/lib/RowExpandFormatter/formula-formatter/index.js +51 -30
- package/lib/RowExpandFormatter/image-formatter/index.js +11 -9
- package/lib/RowExpandFormatter/image-formatter/row-expand-image-item-formatter.js +10 -9
- package/lib/RowExpandFormatter/index.js +52 -34
- package/lib/RowExpandFormatter/link-formatter/collaborator-item-formatter.js +15 -9
- package/lib/RowExpandFormatter/link-formatter/index.js +25 -17
- package/lib/RowExpandFormatter/link-formatter/value-display-utils.js +5 -3
- package/lib/RowExpandFormatter/rate-formatter/index.js +14 -13
- package/lib/RowExpandFormatter/text/index.js +5 -4
- package/lib/RowExpandFormatter/url-formatter/index.js +9 -6
- package/lib/RowExpandView/body/index.js +43 -32
- package/lib/RowExpandView/column-content/index.js +7 -3
- package/lib/RowExpandView/index.js +52 -53
- package/lib/SelectItem/index.js +7 -5
- package/lib/SelectOptionGroup/index.js +40 -30
- package/lib/SelectedDepartments/index.js +12 -10
- package/lib/SimpleLongTextFormatter/index.js +18 -12
- package/lib/SimpleLongTextFormatter/normalize-long-text-value.js +4 -3
- package/lib/SimpleLongTextFormatter/widgets/LongTextPreview.js +21 -12
- package/lib/SimpleLongTextFormatter/widgets/dtable-markdown-viewer.js +4 -3
- package/lib/SingleSelectEditor/index.js +7 -7
- package/lib/SingleSelectFormatter/index.js +9 -8
- package/lib/TabBar/Tab.js +26 -24
- package/lib/TabBar/index.js +28 -24
- package/lib/Tabs/index.js +13 -10
- package/lib/TextEditor/index.js +23 -14
- package/lib/TextFormatter/index.js +4 -3
- package/lib/TextareaItem/index.js +53 -48
- package/lib/Toast/index.js +9 -8
- package/lib/UrlFormatter/index.js +4 -3
- package/lib/common/editor-base.js +12 -7
- package/lib/formatterConfig/index.js +3 -3
- package/lib/hooks/common-hooks.js +4 -2
- package/lib/select-editor/index.js +16 -13
- package/lib/select-editor/mb-editor/index.js +28 -17
- package/lib/select-editor/pc-editor/index.js +47 -32
- package/lib/toaster/alert.js +8 -7
- package/lib/toaster/toast.js +4 -3
- package/lib/toaster/toastManager.js +13 -13
- package/lib/toaster/toaster.js +12 -9
- package/lib/utils/cell.js +11 -8
- package/lib/utils/class.js +3 -3
- package/lib/utils/column-utils.js +14 -8
- package/lib/utils/departments.js +6 -5
- package/lib/utils/getLocale.js +11 -5
- package/lib/utils/object-utils.js +5 -4
- package/lib/utils/url.js +29 -22
- package/lib/utils/utils.js +6 -2
- package/package.json +2 -2
|
@@ -21,8 +21,12 @@ class FilterGroup extends _react.Component {
|
|
|
21
21
|
constructor() {
|
|
22
22
|
super(...arguments);
|
|
23
23
|
this.onSelectGroupConjunction = conjunctionOption => {
|
|
24
|
-
const
|
|
25
|
-
|
|
24
|
+
const {
|
|
25
|
+
filterConjunction
|
|
26
|
+
} = this.props;
|
|
27
|
+
const {
|
|
28
|
+
filterConjunction: newConjunction
|
|
29
|
+
} = conjunctionOption;
|
|
26
30
|
if (newConjunction === filterConjunction) {
|
|
27
31
|
return;
|
|
28
32
|
}
|
|
@@ -30,17 +34,22 @@ class FilterGroup extends _react.Component {
|
|
|
30
34
|
};
|
|
31
35
|
this.deleteFilterGroup = event => {
|
|
32
36
|
event.nativeEvent.stopImmediatePropagation();
|
|
33
|
-
const
|
|
37
|
+
const {
|
|
38
|
+
index
|
|
39
|
+
} = this.props;
|
|
34
40
|
this.props.deleteFilterGroup(index);
|
|
35
41
|
};
|
|
36
42
|
this.modifyConjunctionInGroup = new_filter_conjunction => {
|
|
37
|
-
const
|
|
43
|
+
const {
|
|
44
|
+
index
|
|
45
|
+
} = this.props;
|
|
38
46
|
this.props.modifyConjunctionInGroup(index, new_filter_conjunction);
|
|
39
47
|
};
|
|
40
48
|
this.addFilterIntoGroup = () => {
|
|
41
|
-
const
|
|
42
|
-
columns
|
|
43
|
-
index
|
|
49
|
+
const {
|
|
50
|
+
columns,
|
|
51
|
+
index
|
|
52
|
+
} = this.props;
|
|
44
53
|
const newFilter = (0, _utils.getDefaultFilter)(columns);
|
|
45
54
|
if (!newFilter) {
|
|
46
55
|
return;
|
|
@@ -48,18 +57,23 @@ class FilterGroup extends _react.Component {
|
|
|
48
57
|
this.props.addFilterIntoGroup(index, newFilter);
|
|
49
58
|
};
|
|
50
59
|
this.deleteFilterInGroup = filter_index => {
|
|
51
|
-
const
|
|
60
|
+
const {
|
|
61
|
+
index
|
|
62
|
+
} = this.props;
|
|
52
63
|
this.props.deleteFilterInGroup(index, filter_index);
|
|
53
64
|
};
|
|
54
65
|
this.updateFilterInGroup = (filter_index, new_filter) => {
|
|
55
|
-
const
|
|
66
|
+
const {
|
|
67
|
+
index
|
|
68
|
+
} = this.props;
|
|
56
69
|
this.props.updateFilterInGroup(index, filter_index, new_filter);
|
|
57
70
|
};
|
|
58
71
|
this.renderConjunction = () => {
|
|
59
|
-
const
|
|
60
|
-
index
|
|
61
|
-
filterConjunction
|
|
62
|
-
conjunctionOptions
|
|
72
|
+
const {
|
|
73
|
+
index,
|
|
74
|
+
filterConjunction,
|
|
75
|
+
conjunctionOptions
|
|
76
|
+
} = this.props;
|
|
63
77
|
switch (index) {
|
|
64
78
|
case 0:
|
|
65
79
|
{
|
|
@@ -84,29 +98,35 @@ class FilterGroup extends _react.Component {
|
|
|
84
98
|
}
|
|
85
99
|
};
|
|
86
100
|
this.renderGroupFilters = () => {
|
|
87
|
-
const
|
|
88
|
-
columns
|
|
89
|
-
conjunctionOptions
|
|
90
|
-
columnOptions
|
|
91
|
-
filter
|
|
92
|
-
groupIndex
|
|
93
|
-
collaborators
|
|
94
|
-
lang
|
|
95
|
-
userDepartmentIdsMap
|
|
96
|
-
departments
|
|
97
|
-
firstDayOfWeek
|
|
98
|
-
readOnly
|
|
99
|
-
|
|
100
|
-
|
|
101
|
+
const {
|
|
102
|
+
columns,
|
|
103
|
+
conjunctionOptions,
|
|
104
|
+
columnOptions,
|
|
105
|
+
filter,
|
|
106
|
+
index: groupIndex,
|
|
107
|
+
collaborators,
|
|
108
|
+
lang,
|
|
109
|
+
userDepartmentIdsMap,
|
|
110
|
+
departments,
|
|
111
|
+
firstDayOfWeek,
|
|
112
|
+
readOnly
|
|
113
|
+
} = this.props;
|
|
114
|
+
const {
|
|
115
|
+
filters: subFilters,
|
|
116
|
+
filter_conjunction
|
|
117
|
+
} = filter;
|
|
101
118
|
const subFilterConjunction = _constants.SUPPORT_CONJUNCTIONS.includes(filter_conjunction) ? filter_conjunction : _dtableUtils.FILTER_CONJUNCTION_TYPE.AND;
|
|
102
119
|
const subFiltersLength = Array.isArray(subFilters) ? subFilters.length : 0;
|
|
103
120
|
if (subFiltersLength === 0) {
|
|
104
121
|
return null;
|
|
105
122
|
}
|
|
106
123
|
return subFilters.map((currentFilter, subFilterIndex) => {
|
|
107
|
-
const
|
|
108
|
-
|
|
109
|
-
|
|
124
|
+
const {
|
|
125
|
+
column_key: sub_filter_column_key
|
|
126
|
+
} = currentFilter;
|
|
127
|
+
const {
|
|
128
|
+
error_message
|
|
129
|
+
} = _dtableUtils.ValidateFilter.validate(currentFilter, columns);
|
|
110
130
|
const filterColumn = columns.find(column => column.key === sub_filter_column_key) || {};
|
|
111
131
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_filterItem.default, {
|
|
112
132
|
isInModal: this.props.isInModal,
|
|
@@ -126,17 +146,18 @@ class FilterGroup extends _react.Component {
|
|
|
126
146
|
updateConjunction: this.modifyConjunctionInGroup,
|
|
127
147
|
deleteFilter: this.deleteFilterInGroup,
|
|
128
148
|
updateFilter: this.updateFilterInGroup
|
|
129
|
-
},
|
|
149
|
+
}, `filter-in-group-${groupIndex}-${subFilterIndex}`);
|
|
130
150
|
});
|
|
131
151
|
};
|
|
132
152
|
}
|
|
133
153
|
render() {
|
|
134
|
-
const
|
|
135
|
-
level
|
|
136
|
-
index
|
|
137
|
-
readOnly
|
|
154
|
+
const {
|
|
155
|
+
level,
|
|
156
|
+
index,
|
|
157
|
+
readOnly
|
|
158
|
+
} = this.props;
|
|
138
159
|
return /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
|
|
139
|
-
className: (0, _classnames.default)('filter-item', 'filter-group',
|
|
160
|
+
className: (0, _classnames.default)('filter-item', 'filter-group', `level-${level}`),
|
|
140
161
|
children: [!readOnly && /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
|
|
141
162
|
className: "delete-filter seatable-icon-btn",
|
|
142
163
|
onClick: this.deleteFilterGroup,
|
|
@@ -32,16 +32,21 @@ class FilterItem extends _react.default.Component {
|
|
|
32
32
|
super(_props);
|
|
33
33
|
_this = this;
|
|
34
34
|
this.initSelectOptions = props => {
|
|
35
|
-
const
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
35
|
+
const {
|
|
36
|
+
filter,
|
|
37
|
+
filterColumn
|
|
38
|
+
} = props;
|
|
39
|
+
let {
|
|
40
|
+
filterPredicateList,
|
|
41
|
+
filterTermModifierList
|
|
42
|
+
} = (0, _utils.getColumnOptions)(filterColumn);
|
|
40
43
|
// The value of the calculation formula column does not exist in the shared view
|
|
41
44
|
this.filterPredicateOptions = filterPredicateList ? filterPredicateList.map(predicate => {
|
|
42
45
|
return _filterItemUtils.default.generatorPredicateOption(predicate);
|
|
43
46
|
}).filter(item => item) : [];
|
|
44
|
-
const
|
|
47
|
+
const {
|
|
48
|
+
filter_predicate
|
|
49
|
+
} = filter;
|
|
45
50
|
if ((0, _dtableUtils.isDateColumn)(filterColumn)) {
|
|
46
51
|
if (filter_predicate === _dtableUtils.FILTER_PREDICATE_TYPE.IS_WITHIN) {
|
|
47
52
|
filterTermModifierList = _dtableUtils.filterTermModifierIsWithin;
|
|
@@ -53,7 +58,9 @@ class FilterItem extends _react.default.Component {
|
|
|
53
58
|
};
|
|
54
59
|
this.onDeleteFilter = event => {
|
|
55
60
|
event.nativeEvent.stopImmediatePropagation();
|
|
56
|
-
const
|
|
61
|
+
const {
|
|
62
|
+
index
|
|
63
|
+
} = this.props;
|
|
57
64
|
this.props.deleteFilter(index);
|
|
58
65
|
};
|
|
59
66
|
this.resetState = filter => {
|
|
@@ -62,17 +69,22 @@ class FilterItem extends _react.default.Component {
|
|
|
62
69
|
});
|
|
63
70
|
};
|
|
64
71
|
this.onSelectConjunction = value => {
|
|
65
|
-
const
|
|
72
|
+
const {
|
|
73
|
+
filterConjunction
|
|
74
|
+
} = this.props;
|
|
66
75
|
if (filterConjunction === value.filterConjunction) {
|
|
67
76
|
return;
|
|
68
77
|
}
|
|
69
78
|
this.props.updateConjunction(value.filterConjunction);
|
|
70
79
|
};
|
|
71
80
|
this.onSelectColumn = value => {
|
|
72
|
-
const
|
|
73
|
-
index
|
|
74
|
-
filter
|
|
75
|
-
|
|
81
|
+
const {
|
|
82
|
+
index,
|
|
83
|
+
filter
|
|
84
|
+
} = this.props;
|
|
85
|
+
const {
|
|
86
|
+
column
|
|
87
|
+
} = value;
|
|
76
88
|
if (column.key === filter.column_key) return;
|
|
77
89
|
let newFilter = (0, _utils.getFilterByColumn)(column, filter);
|
|
78
90
|
if (!newFilter) return;
|
|
@@ -80,11 +92,14 @@ class FilterItem extends _react.default.Component {
|
|
|
80
92
|
this.props.updateFilter(index, newFilter);
|
|
81
93
|
};
|
|
82
94
|
this.onSelectPredicate = value => {
|
|
83
|
-
const
|
|
84
|
-
index
|
|
85
|
-
filter
|
|
86
|
-
filterColumn
|
|
87
|
-
|
|
95
|
+
const {
|
|
96
|
+
index,
|
|
97
|
+
filter,
|
|
98
|
+
filterColumn
|
|
99
|
+
} = this.props;
|
|
100
|
+
const {
|
|
101
|
+
filterPredicate
|
|
102
|
+
} = value;
|
|
88
103
|
if (filter.filter_predicate === filterPredicate) {
|
|
89
104
|
return;
|
|
90
105
|
}
|
|
@@ -93,10 +108,13 @@ class FilterItem extends _react.default.Component {
|
|
|
93
108
|
this.props.updateFilter(index, newFilter);
|
|
94
109
|
};
|
|
95
110
|
this.onSelectTermModifier = value => {
|
|
96
|
-
const
|
|
97
|
-
index
|
|
98
|
-
filter
|
|
99
|
-
|
|
111
|
+
const {
|
|
112
|
+
index,
|
|
113
|
+
filter
|
|
114
|
+
} = this.props;
|
|
115
|
+
const {
|
|
116
|
+
filterTermModifier
|
|
117
|
+
} = value;
|
|
100
118
|
const inputRangeLabel = [_dtableUtils.FILTER_TERM_MODIFIER_TYPE.EXACT_DATE, _dtableUtils.FILTER_TERM_MODIFIER_TYPE.NUMBER_OF_DAYS_AGO, _dtableUtils.FILTER_TERM_MODIFIER_TYPE.NUMBER_OF_DAYS_FROM_NOW, _dtableUtils.FILTER_TERM_MODIFIER_TYPE.THE_NEXT_NUMBERS_OF_DAYS, _dtableUtils.FILTER_TERM_MODIFIER_TYPE.THE_PAST_NUMBERS_OF_DAYS];
|
|
101
119
|
if (filter.filter_term_modifier === filterTermModifier) {
|
|
102
120
|
return;
|
|
@@ -113,10 +131,13 @@ class FilterItem extends _react.default.Component {
|
|
|
113
131
|
this.props.updateFilter(index, newFilter);
|
|
114
132
|
};
|
|
115
133
|
this.onSelectSingle = value => {
|
|
116
|
-
const
|
|
117
|
-
index
|
|
118
|
-
filter
|
|
119
|
-
|
|
134
|
+
const {
|
|
135
|
+
index,
|
|
136
|
+
filter
|
|
137
|
+
} = this.props;
|
|
138
|
+
const {
|
|
139
|
+
columnOption: option
|
|
140
|
+
} = value;
|
|
120
141
|
if (filter.filter_term === option.id) {
|
|
121
142
|
return;
|
|
122
143
|
}
|
|
@@ -125,26 +146,31 @@ class FilterItem extends _react.default.Component {
|
|
|
125
146
|
this.props.updateFilter(index, newFilter);
|
|
126
147
|
};
|
|
127
148
|
this.onSelectMultiple = value => {
|
|
128
|
-
const
|
|
129
|
-
index
|
|
130
|
-
filter
|
|
149
|
+
const {
|
|
150
|
+
index,
|
|
151
|
+
filter
|
|
152
|
+
} = this.props;
|
|
131
153
|
let newFilter = (0, _utils.getUpdatedFilterBySelectMultiple)(filter, value);
|
|
132
154
|
this.resetState(newFilter);
|
|
133
155
|
this.props.updateFilter(index, newFilter);
|
|
134
156
|
};
|
|
135
157
|
this.onSelectCollaborator = _ref => {
|
|
136
|
-
let
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
158
|
+
let {
|
|
159
|
+
columnOption: collaborator
|
|
160
|
+
} = _ref;
|
|
161
|
+
const {
|
|
162
|
+
index,
|
|
163
|
+
filter
|
|
164
|
+
} = this.props;
|
|
140
165
|
let newFilter = (0, _utils.getUpdatedFilterByCollaborator)(filter, collaborator);
|
|
141
166
|
this.resetState(newFilter);
|
|
142
167
|
this.props.updateFilter(index, newFilter);
|
|
143
168
|
};
|
|
144
169
|
this.onSelectCreator = value => {
|
|
145
|
-
const
|
|
146
|
-
index
|
|
147
|
-
filter
|
|
170
|
+
const {
|
|
171
|
+
index,
|
|
172
|
+
filter
|
|
173
|
+
} = this.props;
|
|
148
174
|
const collaborator = value && (value.columnOption || value.value || value);
|
|
149
175
|
if (!collaborator || !collaborator.email) {
|
|
150
176
|
return;
|
|
@@ -175,10 +201,13 @@ class FilterItem extends _react.default.Component {
|
|
|
175
201
|
this.onFilterTermChanged(value);
|
|
176
202
|
};
|
|
177
203
|
this.onFilterTermChanged = newFilterTerm => {
|
|
178
|
-
const
|
|
179
|
-
index
|
|
180
|
-
filter
|
|
181
|
-
|
|
204
|
+
const {
|
|
205
|
+
index,
|
|
206
|
+
filter
|
|
207
|
+
} = this.props;
|
|
208
|
+
const {
|
|
209
|
+
filterTerm
|
|
210
|
+
} = this.state;
|
|
182
211
|
if (newFilterTerm !== filterTerm) {
|
|
183
212
|
this.setState({
|
|
184
213
|
filterTerm: newFilterTerm
|
|
@@ -203,11 +232,14 @@ class FilterItem extends _react.default.Component {
|
|
|
203
232
|
this.onFilterTermChanged(index);
|
|
204
233
|
};
|
|
205
234
|
this.getInputComponent = type => {
|
|
206
|
-
const
|
|
207
|
-
filterColumn
|
|
208
|
-
readOnly
|
|
209
|
-
isInModal
|
|
210
|
-
|
|
235
|
+
const {
|
|
236
|
+
filterColumn,
|
|
237
|
+
readOnly,
|
|
238
|
+
isInModal
|
|
239
|
+
} = this.props;
|
|
240
|
+
const {
|
|
241
|
+
filterTerm
|
|
242
|
+
} = this.state;
|
|
211
243
|
if (type === _constants.INPUT_CMP_TYPE_MAP.TEXT) {
|
|
212
244
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_DTableSearchInput.default, {
|
|
213
245
|
value: filterTerm,
|
|
@@ -250,12 +282,13 @@ class FilterItem extends _react.default.Component {
|
|
|
250
282
|
}
|
|
251
283
|
};
|
|
252
284
|
this.renderConjunction = () => {
|
|
253
|
-
const
|
|
254
|
-
index
|
|
255
|
-
filterConjunction
|
|
256
|
-
conjunctionOptions
|
|
257
|
-
readOnly
|
|
258
|
-
isInModal
|
|
285
|
+
const {
|
|
286
|
+
index,
|
|
287
|
+
filterConjunction,
|
|
288
|
+
conjunctionOptions,
|
|
289
|
+
readOnly,
|
|
290
|
+
isInModal
|
|
291
|
+
} = this.props;
|
|
259
292
|
switch (index) {
|
|
260
293
|
case 0:
|
|
261
294
|
{
|
|
@@ -284,10 +317,13 @@ class FilterItem extends _react.default.Component {
|
|
|
284
317
|
this.renderMultipleSelectOption = function () {
|
|
285
318
|
let options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];
|
|
286
319
|
let filterTerm = arguments.length > 1 ? arguments[1] : undefined;
|
|
287
|
-
const
|
|
288
|
-
filter
|
|
289
|
-
readOnly
|
|
290
|
-
|
|
320
|
+
const {
|
|
321
|
+
filter,
|
|
322
|
+
readOnly
|
|
323
|
+
} = _this.props;
|
|
324
|
+
const {
|
|
325
|
+
filter_predicate
|
|
326
|
+
} = filter;
|
|
291
327
|
let isSupportMultipleSelect = false;
|
|
292
328
|
// The first two options are used for single selection, and the last four options are used for multiple selection
|
|
293
329
|
const supportMultipleSelectOptions = [_dtableUtils.FILTER_PREDICATE_TYPE.IS_ANY_OF, _dtableUtils.FILTER_PREDICATE_TYPE.IS_NONE_OF, _dtableUtils.FILTER_PREDICATE_TYPE.HAS_ANY_OF, _dtableUtils.FILTER_PREDICATE_TYPE.HAS_ALL_OF, _dtableUtils.FILTER_PREDICATE_TYPE.HAS_NONE_OF, _dtableUtils.FILTER_PREDICATE_TYPE.IS_EXACTLY];
|
|
@@ -346,19 +382,24 @@ class FilterItem extends _react.default.Component {
|
|
|
346
382
|
});
|
|
347
383
|
};
|
|
348
384
|
this.renderFilterTerm = filterColumn => {
|
|
349
|
-
const
|
|
350
|
-
index
|
|
351
|
-
filter
|
|
352
|
-
collaborators
|
|
353
|
-
userDepartmentIdsMap
|
|
354
|
-
departments
|
|
355
|
-
lang
|
|
356
|
-
firstDayOfWeek
|
|
357
|
-
readOnly
|
|
358
|
-
|
|
359
|
-
const
|
|
360
|
-
|
|
361
|
-
|
|
385
|
+
const {
|
|
386
|
+
index,
|
|
387
|
+
filter,
|
|
388
|
+
collaborators,
|
|
389
|
+
userDepartmentIdsMap,
|
|
390
|
+
departments,
|
|
391
|
+
lang,
|
|
392
|
+
firstDayOfWeek,
|
|
393
|
+
readOnly
|
|
394
|
+
} = this.props;
|
|
395
|
+
const {
|
|
396
|
+
type
|
|
397
|
+
} = filterColumn;
|
|
398
|
+
const {
|
|
399
|
+
filter_term,
|
|
400
|
+
filter_predicate,
|
|
401
|
+
filter_term_modifier
|
|
402
|
+
} = filter;
|
|
362
403
|
// predicate is empty or not empty
|
|
363
404
|
if (_constants.EMPTY_PREDICATE.includes(filter_predicate)) {
|
|
364
405
|
return null;
|
|
@@ -415,9 +456,9 @@ class FilterItem extends _react.default.Component {
|
|
|
415
456
|
case _dtableUtils.CellType.SINGLE_SELECT:
|
|
416
457
|
{
|
|
417
458
|
// get options
|
|
418
|
-
let
|
|
419
|
-
|
|
420
|
-
|
|
459
|
+
let {
|
|
460
|
+
options = []
|
|
461
|
+
} = filterColumn.data || {};
|
|
421
462
|
if ([_dtableUtils.FILTER_PREDICATE_TYPE.IS_ANY_OF, _dtableUtils.FILTER_PREDICATE_TYPE.IS_NONE_OF].includes(filter_predicate)) {
|
|
422
463
|
return this.renderMultipleSelectOption(options, filter_term);
|
|
423
464
|
}
|
|
@@ -460,9 +501,9 @@ class FilterItem extends _react.default.Component {
|
|
|
460
501
|
}
|
|
461
502
|
case _dtableUtils.CellType.MULTIPLE_SELECT:
|
|
462
503
|
{
|
|
463
|
-
let
|
|
464
|
-
|
|
465
|
-
|
|
504
|
+
let {
|
|
505
|
+
options = []
|
|
506
|
+
} = filterColumn.data || {};
|
|
466
507
|
return this.renderMultipleSelectOption(options, filter_term);
|
|
467
508
|
}
|
|
468
509
|
case _dtableUtils.CellType.DEPARTMENT_SINGLE_SELECT:
|
|
@@ -521,8 +562,9 @@ class FilterItem extends _react.default.Component {
|
|
|
521
562
|
}
|
|
522
563
|
case _dtableUtils.CellType.RATE:
|
|
523
564
|
{
|
|
524
|
-
let
|
|
525
|
-
rate_max_number
|
|
565
|
+
let {
|
|
566
|
+
rate_max_number
|
|
567
|
+
} = filterColumn.data || {};
|
|
526
568
|
let rateList = [];
|
|
527
569
|
for (let i = 0; i < rate_max_number; i++) {
|
|
528
570
|
let rateItem = /*#__PURE__*/(0, _jsxRuntime.jsx)(_rateItem.default, {
|
|
@@ -559,16 +601,19 @@ class FilterItem extends _react.default.Component {
|
|
|
559
601
|
}
|
|
560
602
|
};
|
|
561
603
|
this.renderFormulaFilterTerm = (filterPredicate, filterTerm, index, filterColumn) => {
|
|
562
|
-
const
|
|
563
|
-
data
|
|
564
|
-
|
|
565
|
-
|
|
604
|
+
const {
|
|
605
|
+
data
|
|
606
|
+
} = filterColumn || {};
|
|
607
|
+
const {
|
|
608
|
+
result_type
|
|
609
|
+
} = data || {};
|
|
566
610
|
if (filterPredicate === _dtableUtils.FILTER_PREDICATE_TYPE.IS_CURRENT_USER_ID) {
|
|
567
611
|
return null;
|
|
568
612
|
}
|
|
569
613
|
if (result_type === _dtableUtils.FORMULA_RESULT_TYPE.NUMBER) {
|
|
570
|
-
const
|
|
571
|
-
format
|
|
614
|
+
const {
|
|
615
|
+
format
|
|
616
|
+
} = filterColumn.data || {};
|
|
572
617
|
if (format === _dtableUtils.CellType.DURATION) {
|
|
573
618
|
return this.getInputComponent(_constants.INPUT_CMP_TYPE_MAP.DURATION, filterColumn);
|
|
574
619
|
}
|
|
@@ -586,15 +631,18 @@ class FilterItem extends _react.default.Component {
|
|
|
586
631
|
return this.renderFilterTermByArrayType(filterPredicate, filterTerm, index, filterColumn);
|
|
587
632
|
};
|
|
588
633
|
this.renderFilterTermByArrayType = (filterPredicate, filterTerm, index, filterColumn) => {
|
|
589
|
-
const
|
|
590
|
-
collaborators
|
|
591
|
-
departments
|
|
592
|
-
readOnly
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
634
|
+
const {
|
|
635
|
+
collaborators,
|
|
636
|
+
departments,
|
|
637
|
+
readOnly
|
|
638
|
+
} = this.props;
|
|
639
|
+
const {
|
|
640
|
+
data
|
|
641
|
+
} = filterColumn || {};
|
|
642
|
+
const {
|
|
643
|
+
array_type,
|
|
644
|
+
array_data
|
|
645
|
+
} = data || {};
|
|
598
646
|
if (!array_type) {
|
|
599
647
|
return null;
|
|
600
648
|
}
|
|
@@ -603,9 +651,9 @@ class FilterItem extends _react.default.Component {
|
|
|
603
651
|
data: array_data
|
|
604
652
|
};
|
|
605
653
|
if (array_type === _dtableUtils.CellType.SINGLE_SELECT || array_type === _dtableUtils.CellType.MULTIPLE_SELECT) {
|
|
606
|
-
let
|
|
607
|
-
|
|
608
|
-
|
|
654
|
+
let {
|
|
655
|
+
options = []
|
|
656
|
+
} = array_data || {};
|
|
609
657
|
return this.renderMultipleSelectOption(options, filterTerm);
|
|
610
658
|
}
|
|
611
659
|
if (array_type === _dtableUtils.CellType.DEPARTMENT_SINGLE_SELECT) {
|
|
@@ -637,7 +685,9 @@ class FilterItem extends _react.default.Component {
|
|
|
637
685
|
return this.getInputComponent(_constants.INPUT_CMP_TYPE_MAP.TEXT);
|
|
638
686
|
};
|
|
639
687
|
this.isRenderErrorTips = () => {
|
|
640
|
-
const
|
|
688
|
+
const {
|
|
689
|
+
errMsg
|
|
690
|
+
} = this.props;
|
|
641
691
|
return errMsg && errMsg !== _dtableUtils.FILTER_ERR_MSG.INCOMPLETE_FILTER;
|
|
642
692
|
};
|
|
643
693
|
this.renderErrorMessage = () => {
|
|
@@ -667,7 +717,9 @@ class FilterItem extends _react.default.Component {
|
|
|
667
717
|
this.initSelectOptions(_props);
|
|
668
718
|
}
|
|
669
719
|
UNSAFE_componentWillReceiveProps(nextProps) {
|
|
670
|
-
const
|
|
720
|
+
const {
|
|
721
|
+
filter
|
|
722
|
+
} = this.props;
|
|
671
723
|
if (nextProps.filter !== filter) {
|
|
672
724
|
this.initSelectOptions(nextProps);
|
|
673
725
|
this.setState({
|
|
@@ -681,15 +733,20 @@ class FilterItem extends _react.default.Component {
|
|
|
681
733
|
return shouldUpdated;
|
|
682
734
|
}
|
|
683
735
|
render() {
|
|
684
|
-
const
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
736
|
+
const {
|
|
737
|
+
filterPredicateOptions,
|
|
738
|
+
filterTermModifierOptions
|
|
739
|
+
} = this;
|
|
740
|
+
const {
|
|
741
|
+
filter,
|
|
742
|
+
filterColumn,
|
|
743
|
+
filterColumnOptions,
|
|
744
|
+
readOnly
|
|
745
|
+
} = this.props;
|
|
746
|
+
const {
|
|
747
|
+
filter_predicate,
|
|
748
|
+
filter_term_modifier
|
|
749
|
+
} = filter;
|
|
693
750
|
const activeColumn = _filterItemUtils.default.generatorColumnOption(filterColumn);
|
|
694
751
|
const activePredicate = _filterItemUtils.default.generatorPredicateOption(filter_predicate, true);
|
|
695
752
|
let activeTermModifier = null;
|
|
@@ -699,7 +756,9 @@ class FilterItem extends _react.default.Component {
|
|
|
699
756
|
} else if ((0, _columnUtils.isCheckboxColumn)(filterColumn)) {
|
|
700
757
|
_isCheckboxColumn = true;
|
|
701
758
|
}
|
|
702
|
-
const
|
|
759
|
+
const {
|
|
760
|
+
type
|
|
761
|
+
} = filterColumn;
|
|
703
762
|
const computedColumnTypes = [_dtableUtils.CellType.FORMULA, _dtableUtils.CellType.LINK_FORMULA, _dtableUtils.CellType.LINK];
|
|
704
763
|
const isContainPredicate = [_dtableUtils.FILTER_PREDICATE_TYPE.CONTAINS, _dtableUtils.FILTER_PREDICATE_TYPE.NOT_CONTAIN].includes(filter_predicate);
|
|
705
764
|
const isRenderErrorTips = this.isRenderErrorTips();
|
|
@@ -735,7 +794,7 @@ class FilterItem extends _react.default.Component {
|
|
|
735
794
|
isLocked: readOnly
|
|
736
795
|
})
|
|
737
796
|
}), /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
|
|
738
|
-
className:
|
|
797
|
+
className: `filter-predicate ml-2 ${_isCheckboxColumn ? 'filter-checkbox-predicate' : ''}`,
|
|
739
798
|
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_DTableCustomizeSelect.default, {
|
|
740
799
|
value: activePredicate,
|
|
741
800
|
options: filterPredicateOptions,
|