Skip to content

Commit

Permalink
fix(cross-filters): add a control panel to range filter (apache#13692)
Browse files Browse the repository at this point in the history
  • Loading branch information
villebro authored Mar 18, 2021
1 parent 69a5ed9 commit 81b6420
Showing 1 changed file with 26 additions and 4 deletions.
30 changes: 26 additions & 4 deletions superset-frontend/src/filters/components/Range/controlPanel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,34 @@
* specific language governing permissions and limitations
* under the License.
*/
import { ControlPanelConfig, sections } from '@superset-ui/chart-controls';
import { t } from '@superset-ui/core';
import {
ControlPanelConfig,
sections,
sharedControls,
} from '@superset-ui/chart-controls';

const config: ControlPanelConfig = {
// @ts-ignore
controlPanelSections: [sections.legacyRegularTime],
// TODO: here to add the relevant controls
controlPanelSections: [
sections.legacyRegularTime,
{
label: t('Query'),
expanded: true,
controlSetRows: [
[
{
name: 'groupby',
config: {
...sharedControls.groupby,
label: 'Column',
description:
'The numeric column based on which to calculate the range',
},
},
],
],
},
],
};

export default config;

0 comments on commit 81b6420

Please sign in to comment.