Change NULL const to NULL_STRING to avoid confusion
parent
31f0ed3773
commit
a6754857eb
|
@ -1,7 +1,7 @@
|
||||||
import React, {Component, PropTypes} from 'react'
|
import React, {Component, PropTypes} from 'react'
|
||||||
import Dropdown from 'shared/components/Dropdown'
|
import Dropdown from 'shared/components/Dropdown'
|
||||||
|
|
||||||
import {NULL, NUMBER} from 'shared/constants/queryFillOptions'
|
import {NULL_STRING, NUMBER} from 'shared/constants/queryFillOptions'
|
||||||
|
|
||||||
import queryFills from 'hson!shared/data/queryFills.hson'
|
import queryFills from 'hson!shared/data/queryFills.hson'
|
||||||
|
|
||||||
|
@ -25,7 +25,7 @@ class FillQuery extends Component {
|
||||||
static defaultProps = {
|
static defaultProps = {
|
||||||
size: 'sm',
|
size: 'sm',
|
||||||
theme: 'blue',
|
theme: 'blue',
|
||||||
value: NULL,
|
value: NULL_STRING,
|
||||||
}
|
}
|
||||||
|
|
||||||
handleDropdown = item => {
|
handleDropdown = item => {
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
export const LINEAR = 'linear'
|
export const LINEAR = 'linear'
|
||||||
export const NONE = 'none'
|
export const NONE = 'none'
|
||||||
export const NULL = 'null'
|
export const NULL_STRING = 'null'
|
||||||
export const NUMBER = 'number'
|
export const NUMBER = 'number'
|
||||||
export const PREVIOUS = 'previous'
|
export const PREVIOUS = 'previous'
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
import {NULL} from 'shared/constants/queryFillOptions'
|
import {NULL_STRING} from 'shared/constants/queryFillOptions'
|
||||||
|
|
||||||
const defaultQueryConfig = ({id, isKapacitorRule = false}) => {
|
const defaultQueryConfig = ({id, isKapacitorRule = false}) => {
|
||||||
const queryConfig = {
|
const queryConfig = {
|
||||||
|
@ -12,7 +12,7 @@ const defaultQueryConfig = ({id, isKapacitorRule = false}) => {
|
||||||
time: null,
|
time: null,
|
||||||
tags: [],
|
tags: [],
|
||||||
},
|
},
|
||||||
fill: NULL,
|
fill: NULL_STRING,
|
||||||
areTagsAccepted: true,
|
areTagsAccepted: true,
|
||||||
rawText: null,
|
rawText: null,
|
||||||
status: null,
|
status: null,
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
import defaultQueryConfig from 'utils/defaultQueryConfig'
|
import defaultQueryConfig from 'utils/defaultQueryConfig'
|
||||||
import {DEFAULT_DASHBOARD_GROUP_BY_INTERVAL} from 'shared/constants'
|
import {DEFAULT_DASHBOARD_GROUP_BY_INTERVAL} from 'shared/constants'
|
||||||
import {DEFAULT_DATA_EXPLORER_GROUP_BY_INTERVAL} from 'src/data_explorer/constants'
|
import {DEFAULT_DATA_EXPLORER_GROUP_BY_INTERVAL} from 'src/data_explorer/constants'
|
||||||
|
import {NULL_STRING} from 'shared/constants/queryFillOptions'
|
||||||
|
|
||||||
export function editRawText(query, rawText) {
|
export function editRawText(query, rawText) {
|
||||||
return Object.assign({}, query, {rawText})
|
return Object.assign({}, query, {rawText})
|
||||||
|
|
Loading…
Reference in New Issue