Make filters work on export csv action (#8389)
- Create a new component state `contextStoreFiltersComponentState` and refactor `contextStoreTargetedRecordsRuleComponentState` - Refactor `computeContextStoreFilters` to use filters when no records are selected
This commit is contained in:
@ -0,0 +1,11 @@
|
||||
import { ContextStoreComponentInstanceContext } from '@/context-store/states/contexts/ContextStoreComponentInstanceContext';
|
||||
import { Filter } from '@/object-record/object-filter-dropdown/types/Filter';
|
||||
import { createComponentStateV2 } from '@/ui/utilities/state/component-state/utils/createComponentStateV2';
|
||||
|
||||
export const contextStoreFiltersComponentState = createComponentStateV2<
|
||||
Filter[]
|
||||
>({
|
||||
key: 'contextStoreFiltersComponentState',
|
||||
defaultValue: [],
|
||||
componentInstanceContext: ContextStoreComponentInstanceContext,
|
||||
});
|
||||
@ -1,5 +1,4 @@
|
||||
import { ContextStoreComponentInstanceContext } from '@/context-store/states/contexts/ContextStoreComponentInstanceContext';
|
||||
import { Filter } from '@/object-record/object-filter-dropdown/types/Filter';
|
||||
import { createComponentStateV2 } from '@/ui/utilities/state/component-state/utils/createComponentStateV2';
|
||||
|
||||
type ContextStoreTargetedRecordsRuleSelectionMode = {
|
||||
@ -10,7 +9,6 @@ type ContextStoreTargetedRecordsRuleSelectionMode = {
|
||||
type ContextStoreTargetedRecordsRuleExclusionMode = {
|
||||
mode: 'exclusion';
|
||||
excludedRecordIds: string[];
|
||||
filters: Filter[];
|
||||
};
|
||||
|
||||
export type ContextStoreTargetedRecordsRule =
|
||||
|
||||
Reference in New Issue
Block a user