@nocobase/database 2.1.0-beta.7 → 2.1.0-beta.9
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/lib/collection.js
CHANGED
|
@@ -188,7 +188,7 @@ const _Collection = class _Collection extends import_events.EventEmitter {
|
|
|
188
188
|
label: `${this.name}.${field.name}`,
|
|
189
189
|
value: val
|
|
190
190
|
});
|
|
191
|
-
const { error } = joiSchema.validate(val);
|
|
191
|
+
const { error } = joiSchema.validate(val, { convert: false });
|
|
192
192
|
if (error) {
|
|
193
193
|
throw error;
|
|
194
194
|
}
|
|
@@ -149,6 +149,11 @@ const _EagerLoadingTree = class _EagerLoadingTree {
|
|
|
149
149
|
const { sourceKey } = association;
|
|
150
150
|
pushAttribute(eagerLoadingTreeParent, sourceKey);
|
|
151
151
|
}
|
|
152
|
+
if (associationType == "BelongsToArray") {
|
|
153
|
+
const { foreignKey, targetKey } = association;
|
|
154
|
+
pushAttribute(eagerLoadingTreeParent, foreignKey);
|
|
155
|
+
pushAttribute(child, targetKey);
|
|
156
|
+
}
|
|
152
157
|
eagerLoadingTreeParent.children.push(child);
|
|
153
158
|
if (include.include) {
|
|
154
159
|
traverseIncludeOption(include.include, child);
|
package/package.json
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nocobase/database",
|
|
3
|
-
"version": "2.1.0-beta.
|
|
3
|
+
"version": "2.1.0-beta.9",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "./lib/index.js",
|
|
6
6
|
"types": "./lib/index.d.ts",
|
|
7
7
|
"license": "Apache-2.0",
|
|
8
8
|
"dependencies": {
|
|
9
|
-
"@nocobase/logger": "2.1.0-beta.
|
|
10
|
-
"@nocobase/utils": "2.1.0-beta.
|
|
9
|
+
"@nocobase/logger": "2.1.0-beta.9",
|
|
10
|
+
"@nocobase/utils": "2.1.0-beta.9",
|
|
11
11
|
"async-mutex": "^0.3.2",
|
|
12
12
|
"chalk": "^4.1.1",
|
|
13
13
|
"cron-parser": "4.4.0",
|
|
@@ -38,5 +38,5 @@
|
|
|
38
38
|
"url": "git+https://github.com/nocobase/nocobase.git",
|
|
39
39
|
"directory": "packages/database"
|
|
40
40
|
},
|
|
41
|
-
"gitHead": "
|
|
41
|
+
"gitHead": "c3a2875e4cbbb43b1f2361e6f9f5f84a7d3f3c3c"
|
|
42
42
|
}
|