Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Uptime] Move status filter to monitor list #65049

Merged
merged 20 commits into from
May 5, 2020
Merged
Show file tree
Hide file tree
Changes from 14 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ export interface GetPingHistogramParams {
dateEnd: string;
filters?: string;
monitorId?: string;
statusFilter?: string;
}

export interface HistogramResult {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ interface Props {

const Container: React.FC<Props & ResponsiveWrapperProps> = ({ height }) => {
const {
statusFilter,
absoluteDateRangeStart,
absoluteDateRangeEnd,
dateRangeStart: dateStart,
Expand All @@ -32,8 +31,8 @@ const Container: React.FC<Props & ResponsiveWrapperProps> = ({ height }) => {
const { loading, data, esKuery, lastRefresh } = useSelector(selectPingHistogram);

useEffect(() => {
dispatch(getPingHistogram({ monitorId, dateStart, dateEnd, statusFilter, filters: esKuery }));
}, [dateStart, dateEnd, monitorId, statusFilter, lastRefresh, esKuery, dispatch]);
dispatch(getPingHistogram({ monitorId, dateStart, dateEnd, filters: esKuery }));
}, [dateStart, dateEnd, monitorId, lastRefresh, esKuery, dispatch]);
return (
<PingHistogramComponent
data={data}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,7 @@

import React, { useState } from 'react';
import { EuiFilterGroup } from '@elastic/eui';
import { i18n } from '@kbn/i18n';
import { FilterPopoverProps, FilterPopover } from './filter_popover';
import { FilterStatusButton } from './filter_status_button';
import { OverviewFilters } from '../../../../common/runtime_types/overview_filters';
import { filterLabels } from './translations';
import { useFilterUpdate } from '../../../hooks/use_filter_update';
Expand Down Expand Up @@ -81,22 +79,6 @@ export const FilterGroupComponent: React.FC<PresentationalComponentProps> = ({

return (
<EuiFilterGroup>
<FilterStatusButton
content={i18n.translate('xpack.uptime.filterBar.filterUpLabel', {
defaultMessage: 'Up',
})}
dataTestSubj="xpack.uptime.filterBar.filterStatusUp"
value="up"
withNext={true}
/>
<FilterStatusButton
content={i18n.translate('xpack.uptime.filterBar.filterDownLabel', {
defaultMessage: 'Down',
})}
dataTestSubj="xpack.uptime.filterBar.filterStatusDown"
value="down"
withNext={false}
/>
{filterPopoverProps.map(item => (
<FilterPopover key={item.id} {...item} />
))}
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading