@mikro-orm/knex 5.7.15-dev.30 → 5.7.15-dev.32
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,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mikro-orm/knex",
|
|
3
|
-
"version": "5.7.15-dev.
|
|
3
|
+
"version": "5.7.15-dev.32",
|
|
4
4
|
"description": "TypeScript ORM for Node.js based on Data Mapper, Unit of Work and Identity Map patterns. Supports MongoDB, MySQL, PostgreSQL and SQLite databases as well as usage with vanilla JavaScript.",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"module": "index.mjs",
|
|
@@ -66,9 +66,9 @@
|
|
|
66
66
|
"@mikro-orm/core": "^5.7.14"
|
|
67
67
|
},
|
|
68
68
|
"peerDependencies": {
|
|
69
|
-
"@mikro-orm/core": "~5.7.15-dev.
|
|
70
|
-
"@mikro-orm/entity-generator": "~5.7.15-dev.
|
|
71
|
-
"@mikro-orm/migrations": "~5.7.15-dev.
|
|
69
|
+
"@mikro-orm/core": "~5.7.15-dev.32",
|
|
70
|
+
"@mikro-orm/entity-generator": "~5.7.15-dev.32",
|
|
71
|
+
"@mikro-orm/migrations": "~5.7.15-dev.32",
|
|
72
72
|
"better-sqlite3": "*",
|
|
73
73
|
"mssql": "*",
|
|
74
74
|
"mysql": "*",
|
|
@@ -128,12 +128,13 @@ class QueryBuilderHelper {
|
|
|
128
128
|
const pivotMeta = this.metadata.find(prop.pivotEntity);
|
|
129
129
|
const ret = {
|
|
130
130
|
[`${ownerAlias}.${prop.name}#${pivotAlias}`]: {
|
|
131
|
-
prop, type,
|
|
131
|
+
prop, type, ownerAlias,
|
|
132
132
|
alias: pivotAlias,
|
|
133
133
|
inverseAlias: alias,
|
|
134
134
|
joinColumns: prop.joinColumns,
|
|
135
135
|
inverseJoinColumns: prop.inverseJoinColumns,
|
|
136
136
|
primaryKeys: prop.referencedColumnNames,
|
|
137
|
+
cond: {},
|
|
137
138
|
table: pivotMeta.tableName,
|
|
138
139
|
schema: this.driver.getSchemaName(pivotMeta),
|
|
139
140
|
path: path.endsWith('[pivot]') ? path : `${path}[pivot]`,
|
|
@@ -143,7 +144,7 @@ class QueryBuilderHelper {
|
|
|
143
144
|
return ret;
|
|
144
145
|
}
|
|
145
146
|
const prop2 = prop.owner ? pivotMeta.relations[1] : pivotMeta.relations[0];
|
|
146
|
-
ret[`${pivotAlias}.${prop2.name}#${alias}`] = this.joinManyToOneReference(prop2, pivotAlias, alias, type);
|
|
147
|
+
ret[`${pivotAlias}.${prop2.name}#${alias}`] = this.joinManyToOneReference(prop2, pivotAlias, alias, type, cond);
|
|
147
148
|
ret[`${pivotAlias}.${prop2.name}#${alias}`].path = path;
|
|
148
149
|
return ret;
|
|
149
150
|
}
|