* fixes #8939, #9061, closes #9168

* fixes

* fixing mssql error
This commit is contained in:
Umed Khudoiberdiev 2022-07-06 16:44:17 +05:00 committed by GitHub
parent 0b542225cc
commit d285fd0a2b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 21 additions and 5 deletions

View File

@ -691,7 +691,7 @@ Steps to run this project:
packageJson.dependencies["oracledb"] = "^5.1.0"
break
case "mssql":
packageJson.dependencies["mssql"] = "^6.3.0"
packageJson.dependencies["mssql"] = "^7.3.0"
break
case "mongodb":
packageJson.dependencies["mongodb"] = "^3.0.8"

View File

@ -25,7 +25,9 @@ export type FindOptionsOrderProperty<Property> = Property extends Promise<
* Order by find options.
*/
export type FindOptionsOrder<Entity> = {
[P in keyof Entity]?: FindOptionsOrderProperty<NonNullable<Entity[P]>>
[P in keyof Entity]?: P extends "toString"
? unknown
: FindOptionsOrderProperty<NonNullable<Entity[P]>>
}
/**

View File

@ -25,7 +25,9 @@ export type FindOptionsRelationsProperty<Property> = Property extends Promise<
* Relations find options.
*/
export type FindOptionsRelations<Entity> = {
[P in keyof Entity]?: FindOptionsRelationsProperty<NonNullable<Entity[P]>>
[P in keyof Entity]?: P extends "toString"
? unknown
: FindOptionsRelationsProperty<NonNullable<Entity[P]>>
}
/**

View File

@ -25,7 +25,9 @@ export type FindOptionsSelectProperty<Property> = Property extends Promise<
* Select find options.
*/
export type FindOptionsSelect<Entity> = {
[P in keyof Entity]?: FindOptionsSelectProperty<NonNullable<Entity[P]>>
[P in keyof Entity]?: P extends "toString"
? unknown
: FindOptionsSelectProperty<NonNullable<Entity[P]>>
}
/**

View File

@ -32,5 +32,7 @@ export type FindOptionsWhereProperty<Property> = Property extends Promise<
* Used for find operations.
*/
export type FindOptionsWhere<Entity> = {
[P in keyof Entity]?: FindOptionsWhereProperty<NonNullable<Entity[P]>>
[P in keyof Entity]?: P extends "toString"
? unknown
: FindOptionsWhereProperty<NonNullable<Entity[P]>>
}

View File

@ -30,4 +30,12 @@ export class Post {
@Column(() => Counters)
counters: Counters
toString() {
return this.title
}
doSomething() {
return 123
}
}