@budibase/frontend-core 1.0.212-alpha.4 → 1.0.213

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,14 +1,14 @@
1
1
  {
2
2
  "name": "@budibase/frontend-core",
3
- "version": "1.0.212-alpha.4",
3
+ "version": "1.0.213",
4
4
  "description": "Budibase frontend core libraries used in builder and client",
5
5
  "author": "Budibase",
6
6
  "license": "MPL-2.0",
7
7
  "svelte": "src/index.js",
8
8
  "dependencies": {
9
- "@budibase/bbui": "^1.0.212-alpha.4",
9
+ "@budibase/bbui": "^1.0.213",
10
10
  "lodash": "^4.17.21",
11
11
  "svelte": "^3.46.2"
12
12
  },
13
- "gitHead": "03cdf3688a0c34a7303a83d81b24e03b8589ce54"
13
+ "gitHead": "f9dc1b530dd896d3b828559c34806831b6073f49"
14
14
  }
package/src/api/flags.js CHANGED
@@ -22,13 +22,4 @@ export const buildFlagEndpoints = API => ({
22
22
  },
23
23
  })
24
24
  },
25
- /**
26
- * Allows us to experimentally toggle a beta UI feature through a cookie.
27
- * @param value the feature to toggle
28
- */
29
- toggleUiFeature: async ({ value }) => {
30
- return await API.post({
31
- url: `/api/beta/${value}`,
32
- })
33
- },
34
25
  })
package/src/api/other.js CHANGED
@@ -54,14 +54,4 @@ export const buildOtherEndpoints = API => ({
54
54
  url: "/api/permission/builtin",
55
55
  })
56
56
  },
57
-
58
- /**
59
- * Check if they are part of the budibase beta program.
60
- */
61
- checkBetaAccess: async email => {
62
- return await API.get({
63
- url: `${process.env.FEATURE_PREVIEW_URL}/api/beta/access?email=${email}`,
64
- external: true,
65
- })
66
- },
67
57
  })
package/src/api/rows.js CHANGED
@@ -65,15 +65,12 @@ export const buildRowEndpoints = API => ({
65
65
  * Exports rows.
66
66
  * @param tableId the table ID to export the rows from
67
67
  * @param rows the array of rows to export
68
- * @param format the format to export (csv or json)
69
- * @param columns which columns to export (all if undefined)
70
68
  */
71
- exportRows: async ({ tableId, rows, format, columns }) => {
69
+ exportRows: async ({ tableId, rows, format }) => {
72
70
  return await API.post({
73
71
  url: `/api/${tableId}/rows/exportRows?format=${format}`,
74
72
  body: {
75
73
  rows,
76
- columns,
77
74
  },
78
75
  parseResponse: async response => {
79
76
  return await response.text()
package/src/constants.js CHANGED
@@ -63,25 +63,3 @@ export const TableNames = {
63
63
  * - Coerce types for search endpoint
64
64
  */
65
65
  export const ApiVersion = "1"
66
-
67
- /**
68
- * Maximum minimum range for SQL number values
69
- */
70
- export const SqlNumberTypeRangeMap = {
71
- integer: {
72
- max: 2147483647,
73
- min: -2147483648,
74
- },
75
- int: {
76
- max: 2147483647,
77
- min: -2147483648,
78
- },
79
- smallint: {
80
- max: 32767,
81
- min: -32768,
82
- },
83
- mediumint: {
84
- max: 8388607,
85
- min: -8388608,
86
- },
87
- }
@@ -1,5 +1,5 @@
1
1
  import { Helpers } from "@budibase/bbui"
2
- import { OperatorOptions, SqlNumberTypeRangeMap } from "../constants"
2
+ import { OperatorOptions } from "../constants"
3
3
 
4
4
  /**
5
5
  * Returns the valid operator options for a certain data type
@@ -94,7 +94,7 @@ export const buildLuceneQuery = filter => {
94
94
  }
95
95
  if (Array.isArray(filter)) {
96
96
  filter.forEach(expression => {
97
- let { operator, field, type, value, externalType } = expression
97
+ let { operator, field, type, value } = expression
98
98
  // Parse all values into correct types
99
99
  if (type === "datetime" && value) {
100
100
  value = new Date(value).toISOString()
@@ -106,14 +106,16 @@ export const buildLuceneQuery = filter => {
106
106
  value = `${value}`?.toLowerCase() === "true"
107
107
  }
108
108
  if (operator.startsWith("range")) {
109
- const minint =
110
- SqlNumberTypeRangeMap[externalType]?.min || Number.MIN_SAFE_INTEGER
111
- const maxint =
112
- SqlNumberTypeRangeMap[externalType]?.max || Number.MAX_SAFE_INTEGER
113
109
  if (!query.range[field]) {
114
110
  query.range[field] = {
115
- low: type === "number" ? minint : "0000-00-00T00:00:00.000Z",
116
- high: type === "number" ? maxint : "9999-00-00T00:00:00.000Z",
111
+ low:
112
+ type === "number"
113
+ ? Number.MIN_SAFE_INTEGER
114
+ : "0000-00-00T00:00:00.000Z",
115
+ high:
116
+ type === "number"
117
+ ? Number.MAX_SAFE_INTEGER
118
+ : "9999-00-00T00:00:00.000Z",
117
119
  }
118
120
  }
119
121
  if (operator === "rangeLow" && value != null && value !== "") {