@nocobase/database 1.3.50-beta → 1.3.51
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.
|
@@ -91,13 +91,19 @@ const _MultipleRelationRepository = class _MultipleRelationRepository extends im
|
|
|
91
91
|
];
|
|
92
92
|
}
|
|
93
93
|
async count(options) {
|
|
94
|
+
var _a;
|
|
94
95
|
const transaction2 = await this.getTransaction(options);
|
|
95
96
|
const sourceModel = await this.getSourceModel(transaction2);
|
|
96
97
|
if (!sourceModel) return 0;
|
|
97
98
|
const queryOptions = this.buildQueryOptions(options);
|
|
99
|
+
const include = (_a = queryOptions.include) == null ? void 0 : _a.filter((item) => {
|
|
100
|
+
var _a2;
|
|
101
|
+
const association = (_a2 = this.targetModel.associations) == null ? void 0 : _a2[item.association];
|
|
102
|
+
return (association == null ? void 0 : association.associationType) !== "BelongsToArray";
|
|
103
|
+
});
|
|
98
104
|
const count = await sourceModel[this.accessors().get]({
|
|
99
105
|
where: queryOptions.where,
|
|
100
|
-
include
|
|
106
|
+
include,
|
|
101
107
|
includeIgnoreAttributes: false,
|
|
102
108
|
attributes: [
|
|
103
109
|
[
|
package/package.json
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nocobase/database",
|
|
3
|
-
"version": "1.3.
|
|
3
|
+
"version": "1.3.51",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "./lib/index.js",
|
|
6
6
|
"types": "./lib/index.d.ts",
|
|
7
7
|
"license": "AGPL-3.0",
|
|
8
8
|
"dependencies": {
|
|
9
|
-
"@nocobase/logger": "1.3.
|
|
10
|
-
"@nocobase/utils": "1.3.
|
|
9
|
+
"@nocobase/logger": "1.3.51",
|
|
10
|
+
"@nocobase/utils": "1.3.51",
|
|
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": "01f2b933a0681d99c5928d91d41f3f0c0ecae988"
|
|
42
42
|
}
|