mirror of https://github.com/apache/superset.git
chore: remove a few obsolete logic (#11676)
This commit is contained in:
parent
2b107ed33d
commit
7d27996867
|
@ -85,23 +85,21 @@ export function fetchAllSlices(userId) {
|
|||
datasource,
|
||||
};
|
||||
}
|
||||
if (['markup', 'separator'].indexOf(slice.viz_type) === -1) {
|
||||
slices[slice.id] = {
|
||||
slice_id: slice.id,
|
||||
slice_url: slice.url,
|
||||
slice_name: slice.slice_name,
|
||||
edit_url: slice.edit_url,
|
||||
form_data,
|
||||
datasource_name: slice.datasource_name_text,
|
||||
datasource_url: slice.datasource_url,
|
||||
changed_on: new Date(slice.changed_on_utc).getTime(),
|
||||
description: slice.description,
|
||||
description_markdown: slice.description_markeddown,
|
||||
viz_type: slice.viz_type,
|
||||
modified: slice.changed_on_delta_humanized,
|
||||
changed_on_humanized: slice.changed_on_delta_humanized,
|
||||
};
|
||||
}
|
||||
slices[slice.id] = {
|
||||
slice_id: slice.id,
|
||||
slice_url: slice.url,
|
||||
slice_name: slice.slice_name,
|
||||
edit_url: slice.edit_url,
|
||||
form_data,
|
||||
datasource_name: slice.datasource_name_text,
|
||||
datasource_url: slice.datasource_url,
|
||||
changed_on: new Date(slice.changed_on_utc).getTime(),
|
||||
description: slice.description,
|
||||
description_markdown: slice.description_markeddown,
|
||||
viz_type: slice.viz_type,
|
||||
modified: slice.changed_on_delta_humanized,
|
||||
changed_on_humanized: slice.changed_on_delta_humanized,
|
||||
};
|
||||
});
|
||||
|
||||
return dispatch(setAllSlices(slices));
|
||||
|
|
|
@ -35,8 +35,6 @@ import { NEW_TAB_ID, DASHBOARD_ROOT_ID } from '../../util/constants';
|
|||
import { RENDER_TAB, RENDER_TAB_CONTENT } from './Tab';
|
||||
import { TAB_TYPE } from '../../util/componentTypes';
|
||||
|
||||
const MAX_TAB_COUNT = 10;
|
||||
|
||||
const propTypes = {
|
||||
id: PropTypes.string.isRequired,
|
||||
parentId: PropTypes.string.isRequired,
|
||||
|
@ -305,7 +303,6 @@ class Tabs extends React.PureComponent {
|
|||
this.handleClickTab(tabIds.indexOf(key));
|
||||
}}
|
||||
onEdit={this.handleEdit}
|
||||
hideAdd={tabIds.length >= MAX_TAB_COUNT}
|
||||
data-test="nav-list"
|
||||
type={editMode ? 'editable-card' : 'card'}
|
||||
>
|
||||
|
|
|
@ -63,9 +63,6 @@ export const SAVE_TYPE_NEWDASHBOARD = 'newDashboard';
|
|||
// could be overwritten by server-side config
|
||||
export const DASHBOARD_POSITION_DATA_LIMIT = 65535;
|
||||
|
||||
// filter indicators display length
|
||||
export const FILTER_INDICATORS_DISPLAY_LENGTH = 3;
|
||||
|
||||
// in-component element types: can be added into
|
||||
// directPathToChild, used for in dashboard navigation and focus
|
||||
export const IN_COMPONENT_ELEMENT_TYPES = ['LABEL'];
|
||||
|
|
Loading…
Reference in New Issue