mirror of
https://github.com/apache/superset.git
synced 2026-04-23 01:55:09 +00:00
Deleted unused components in exploreV2 (#1613)
* Deleted unused components in exploreV2 * Deleted constants.js
This commit is contained in:
@@ -1,13 +1,8 @@
|
||||
import { defaultOpts } from '../stores/store';
|
||||
import * as actions from '../actions/exploreActions';
|
||||
import { addToArr, removeFromArr, alterInArr } from '../../../utils/reducerUtils';
|
||||
|
||||
export const exploreReducer = function (state, action) {
|
||||
const actionHandlers = {
|
||||
[actions.SET_DATASOURCE]() {
|
||||
return Object.assign({}, state, { datasourceId: action.datasourceId });
|
||||
},
|
||||
|
||||
[actions.FETCH_STARTED]() {
|
||||
return Object.assign({}, state, { isDatasourceMetaLoading: true });
|
||||
},
|
||||
@@ -33,10 +28,6 @@ export const exploreReducer = function (state, action) {
|
||||
return Object.assign({}, state, newState);
|
||||
},
|
||||
|
||||
[actions.TOGGLE_SEARCHBOX]() {
|
||||
return Object.assign({}, state, { searchBox: action.searchBox });
|
||||
},
|
||||
|
||||
[actions.SET_FILTER_COLUMN_OPTS]() {
|
||||
return Object.assign({}, state, { filterColumnOpts: action.filterColumnOpts });
|
||||
},
|
||||
@@ -55,9 +46,6 @@ export const exploreReducer = function (state, action) {
|
||||
[actions.CHANGE_FILTER_VALUE]() {
|
||||
return alterInArr(state, 'filters', action.filter, { value: action.value });
|
||||
},
|
||||
[actions.CLEAR_ALL_OPTS]() {
|
||||
return Object.assign({}, state, defaultOpts);
|
||||
},
|
||||
[actions.SET_FIELD_VALUE]() {
|
||||
const newFormData = Object.assign({}, state.viz.form_data);
|
||||
newFormData[action.key] = action.value ? action.value : (!state.viz.form_data[action.key]);
|
||||
|
||||
Reference in New Issue
Block a user