@budibase/server 2.6.20 → 2.6.21
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.
|
@@ -39,6 +39,7 @@ const constants_1 = require("../../constants");
|
|
|
39
39
|
const utils_1 = require("./utils");
|
|
40
40
|
const automationUtils = __importStar(require("../automationUtils"));
|
|
41
41
|
const types_1 = require("@budibase/types");
|
|
42
|
+
const backend_core_1 = require("@budibase/backend-core");
|
|
42
43
|
var SortOrder;
|
|
43
44
|
(function (SortOrder) {
|
|
44
45
|
SortOrder["ASCENDING"] = "ascending";
|
|
@@ -140,7 +141,10 @@ function typeCoercion(filters, table) {
|
|
|
140
141
|
const searchParam = filters[key];
|
|
141
142
|
if (typeof searchParam === "object") {
|
|
142
143
|
for (let [property, value] of Object.entries(searchParam)) {
|
|
143
|
-
|
|
144
|
+
// We need to strip numerical prefixes here, so that we can look up
|
|
145
|
+
// the correct field name in the schema
|
|
146
|
+
const columnName = backend_core_1.db.removeKeyNumbering(property);
|
|
147
|
+
const column = table.schema[columnName];
|
|
144
148
|
// convert string inputs
|
|
145
149
|
if (!column || typeof value !== "string") {
|
|
146
150
|
continue;
|