mirror of
https://git.mirrors.martin98.com/https://github.com/SigNoz/signoz
synced 2025-08-12 12:49:06 +08:00
fix: removed timestamp and id from being passed to query from log details drawer
This commit is contained in:
parent
f11b9644cf
commit
073d42c416
@ -30,13 +30,11 @@ import { ILog } from 'types/api/logs/log';
|
|||||||
import { DataTypes } from 'types/api/queryBuilder/queryAutocompleteResponse';
|
import { DataTypes } from 'types/api/queryBuilder/queryAutocompleteResponse';
|
||||||
|
|
||||||
import { ActionItemProps } from './ActionItem';
|
import { ActionItemProps } from './ActionItem';
|
||||||
|
import { RESTRICTED_FIELDS } from './constant';
|
||||||
import FieldRenderer from './FieldRenderer';
|
import FieldRenderer from './FieldRenderer';
|
||||||
import { TableViewActions } from './TableView/TableViewActions';
|
import { TableViewActions } from './TableView/TableViewActions';
|
||||||
import { filterKeyForField, findKeyPath, flattenObject } from './utils';
|
import { filterKeyForField, findKeyPath, flattenObject } from './utils';
|
||||||
|
|
||||||
// Fields which should be restricted from adding it to query
|
|
||||||
const RESTRICTED_FIELDS = ['timestamp'];
|
|
||||||
|
|
||||||
interface TableViewProps {
|
interface TableViewProps {
|
||||||
logData: ILog;
|
logData: ILog;
|
||||||
fieldSearchInput: string;
|
fieldSearchInput: string;
|
||||||
|
@ -18,6 +18,7 @@ import { useLocation } from 'react-router-dom';
|
|||||||
import { DataTypes } from 'types/api/queryBuilder/queryAutocompleteResponse';
|
import { DataTypes } from 'types/api/queryBuilder/queryAutocompleteResponse';
|
||||||
import { FORBID_DOM_PURIFY_TAGS } from 'utils/app';
|
import { FORBID_DOM_PURIFY_TAGS } from 'utils/app';
|
||||||
|
|
||||||
|
import { RESTRICTED_FIELDS } from '../constant';
|
||||||
import { DataType } from '../TableView';
|
import { DataType } from '../TableView';
|
||||||
import {
|
import {
|
||||||
filterKeyForField,
|
filterKeyForField,
|
||||||
@ -142,7 +143,7 @@ export function TableViewActions(
|
|||||||
<CopyClipboardHOC entityKey={fieldFilterKey} textToCopy={textToCopy}>
|
<CopyClipboardHOC entityKey={fieldFilterKey} textToCopy={textToCopy}>
|
||||||
{renderFieldContent()}
|
{renderFieldContent()}
|
||||||
</CopyClipboardHOC>
|
</CopyClipboardHOC>
|
||||||
{!isListViewPanel && (
|
{!isListViewPanel && !RESTRICTED_FIELDS.includes(fieldFilterKey) && (
|
||||||
<span className="action-btn">
|
<span className="action-btn">
|
||||||
<Tooltip title="Filter for value">
|
<Tooltip title="Filter for value">
|
||||||
<Button
|
<Button
|
||||||
|
@ -2,3 +2,6 @@ export const DROPDOWN_KEY = {
|
|||||||
FILTER_IN: 'filterIn',
|
FILTER_IN: 'filterIn',
|
||||||
FILTER_OUT: 'filterOut',
|
FILTER_OUT: 'filterOut',
|
||||||
};
|
};
|
||||||
|
|
||||||
|
// Fields which should be restricted from adding it to query
|
||||||
|
export const RESTRICTED_FIELDS = ['timestamp', 'id'];
|
||||||
|
Loading…
x
Reference in New Issue
Block a user