Reuse constants
This commit is contained in:
parent
73380eced6
commit
8bc90787ae
|
@ -1,56 +1,7 @@
|
||||||
/**
|
/**
|
||||||
* Operator options for lucene queries
|
* Operator options for lucene queries
|
||||||
*/
|
*/
|
||||||
export const OperatorOptions = {
|
export { OperatorOptions, SqlNumberTypeRangeMap } from "@budibase/data-utils"
|
||||||
Equals: {
|
|
||||||
value: "equal",
|
|
||||||
label: "Equals",
|
|
||||||
},
|
|
||||||
NotEquals: {
|
|
||||||
value: "notEqual",
|
|
||||||
label: "Not equals",
|
|
||||||
},
|
|
||||||
Empty: {
|
|
||||||
value: "empty",
|
|
||||||
label: "Is empty",
|
|
||||||
},
|
|
||||||
NotEmpty: {
|
|
||||||
value: "notEmpty",
|
|
||||||
label: "Is not empty",
|
|
||||||
},
|
|
||||||
StartsWith: {
|
|
||||||
value: "string",
|
|
||||||
label: "Starts with",
|
|
||||||
},
|
|
||||||
Like: {
|
|
||||||
value: "fuzzy",
|
|
||||||
label: "Like",
|
|
||||||
},
|
|
||||||
MoreThan: {
|
|
||||||
value: "rangeLow",
|
|
||||||
label: "More than or equal to",
|
|
||||||
},
|
|
||||||
LessThan: {
|
|
||||||
value: "rangeHigh",
|
|
||||||
label: "Less than or equal to",
|
|
||||||
},
|
|
||||||
Contains: {
|
|
||||||
value: "contains",
|
|
||||||
label: "Contains",
|
|
||||||
},
|
|
||||||
NotContains: {
|
|
||||||
value: "notContains",
|
|
||||||
label: "Does not contain",
|
|
||||||
},
|
|
||||||
In: {
|
|
||||||
value: "oneOf",
|
|
||||||
label: "Is in",
|
|
||||||
},
|
|
||||||
ContainsAny: {
|
|
||||||
value: "containsAny",
|
|
||||||
label: "Has any",
|
|
||||||
},
|
|
||||||
}
|
|
||||||
|
|
||||||
// Cookie names
|
// Cookie names
|
||||||
export const Cookies = {
|
export const Cookies = {
|
||||||
|
@ -127,27 +78,6 @@ export const Roles = {
|
||||||
PUBLIC: "PUBLIC",
|
PUBLIC: "PUBLIC",
|
||||||
BUILDER: "BUILDER",
|
BUILDER: "BUILDER",
|
||||||
}
|
}
|
||||||
/**
|
|
||||||
* Maximum minimum range for SQL number values
|
|
||||||
*/
|
|
||||||
export const SqlNumberTypeRangeMap = {
|
|
||||||
integer: {
|
|
||||||
max: 2147483647,
|
|
||||||
min: -2147483648,
|
|
||||||
},
|
|
||||||
int: {
|
|
||||||
max: 2147483647,
|
|
||||||
min: -2147483648,
|
|
||||||
},
|
|
||||||
smallint: {
|
|
||||||
max: 32767,
|
|
||||||
min: -32768,
|
|
||||||
},
|
|
||||||
mediumint: {
|
|
||||||
max: 8388607,
|
|
||||||
min: -8388608,
|
|
||||||
},
|
|
||||||
}
|
|
||||||
|
|
||||||
export const Themes = [
|
export const Themes = [
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue