-
Notifications
You must be signed in to change notification settings - Fork 38
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(bugs): fix bugs introduced by previous commits
- Loading branch information
1 parent
23d6b61
commit 89eb4b8
Showing
9 changed files
with
196 additions
and
38 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,138 @@ | ||
// This file has been auto-generated by Warthog. Do not update directly as it | ||
// will be re-written. If you need to change this file, update models or add | ||
// new TypeGraphQL objects | ||
import { | ||
ArgsType, | ||
Field as TypeGraphQLField, | ||
ID, | ||
InputType as TypeGraphQLInputType | ||
} from 'type-graphql'; | ||
import { registerEnumType } from 'type-graphql'; | ||
import { BaseWhereInput, PaginationArgs } from '../../../src'; | ||
import { User } from '../src/user.model'; | ||
|
||
export enum UserOrderByEnum { | ||
createdAt_ASC = 'createdAt_ASC', | ||
createdAt_DESC = 'createdAt_DESC', | ||
|
||
updatedAt_ASC = 'updatedAt_ASC', | ||
updatedAt_DESC = 'updatedAt_DESC', | ||
|
||
deletedAt_ASC = 'deletedAt_ASC', | ||
deletedAt_DESC = 'deletedAt_DESC', | ||
|
||
firstName_ASC = 'firstName_ASC', | ||
firstName_DESC = 'firstName_DESC', | ||
|
||
lastName_ASC = 'lastName_ASC', | ||
lastName_DESC = 'lastName_DESC', | ||
|
||
email_ASC = 'email_ASC', | ||
email_DESC = 'email_DESC' | ||
} | ||
|
||
registerEnumType(UserOrderByEnum, { | ||
name: 'UserOrderByInput' | ||
}); | ||
|
||
@TypeGraphQLInputType() | ||
export class UserWhereInput extends BaseWhereInput { | ||
@TypeGraphQLField({ nullable: true }) | ||
firstName_eq?: string; | ||
|
||
@TypeGraphQLField({ nullable: true }) | ||
firstName_contains?: string; | ||
|
||
@TypeGraphQLField({ nullable: true }) | ||
firstName_startsWith?: string; | ||
|
||
@TypeGraphQLField({ nullable: true }) | ||
firstName_endsWith?: string; | ||
|
||
@TypeGraphQLField(type => [String], { nullable: true }) | ||
firstName_in?: string[]; | ||
|
||
@TypeGraphQLField({ nullable: true }) | ||
lastName_eq?: string; | ||
|
||
@TypeGraphQLField({ nullable: true }) | ||
lastName_contains?: string; | ||
|
||
@TypeGraphQLField({ nullable: true }) | ||
lastName_startsWith?: string; | ||
|
||
@TypeGraphQLField({ nullable: true }) | ||
lastName_endsWith?: string; | ||
|
||
@TypeGraphQLField(type => [String], { nullable: true }) | ||
lastName_in?: string[]; | ||
|
||
@TypeGraphQLField({ nullable: true }) | ||
email_eq?: string; | ||
|
||
@TypeGraphQLField({ nullable: true }) | ||
email_contains?: string; | ||
|
||
@TypeGraphQLField({ nullable: true }) | ||
email_startsWith?: string; | ||
|
||
@TypeGraphQLField({ nullable: true }) | ||
email_endsWith?: string; | ||
|
||
@TypeGraphQLField(type => [String], { nullable: true }) | ||
email_in?: string[]; | ||
} | ||
|
||
@TypeGraphQLInputType() | ||
export class UserWhereUniqueInput { | ||
@TypeGraphQLField(type => String, { nullable: true }) | ||
id?: string; | ||
|
||
@TypeGraphQLField(type => String, { nullable: true }) | ||
email?: string; | ||
} | ||
|
||
@TypeGraphQLInputType() | ||
export class UserCreateInput { | ||
@TypeGraphQLField() | ||
firstName!: string; | ||
|
||
@TypeGraphQLField({ nullable: true }) | ||
lastName?: string; | ||
|
||
@TypeGraphQLField() | ||
email!: string; | ||
} | ||
|
||
@TypeGraphQLInputType() | ||
export class UserUpdateInput { | ||
@TypeGraphQLField({ nullable: true }) | ||
firstName?: string; | ||
|
||
@TypeGraphQLField({ nullable: true }) | ||
lastName?: string; | ||
|
||
@TypeGraphQLField({ nullable: true }) | ||
email?: string; | ||
} | ||
|
||
@ArgsType() | ||
export class UserWhereArgs extends PaginationArgs { | ||
@TypeGraphQLField(type => UserWhereInput, { nullable: true }) | ||
where?: UserWhereInput; | ||
|
||
@TypeGraphQLField(type => UserOrderByEnum, { nullable: true }) | ||
orderBy?: UserOrderByEnum; | ||
} | ||
|
||
@ArgsType() | ||
export class UserCreateManyArgs { | ||
@TypeGraphQLField(type => [UserCreateInput]) | ||
data!: UserCreateInput[]; | ||
} | ||
|
||
@ArgsType() | ||
export class UserUpdateArgs { | ||
@TypeGraphQLField() data!: UserUpdateInput; | ||
@TypeGraphQLField() where!: UserWhereUniqueInput; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
export * from './classes'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
import { SnakeNamingStrategy } from 'warthog'; | ||
|
||
module.exports = { | ||
cli: { | ||
entitiesDir: 'src/models', | ||
migrationsDir: 'src/migration', | ||
subscribersDir: 'src/subscriber' | ||
}, | ||
database: process.env.TYPEORM_DATABASE, | ||
entities: process.env.TYPEORM_ENTITIES || ['src/**/*.model.ts'], | ||
host: process.env.TYPEORM_HOST || 'localhost', | ||
logger: 'advanced-console', | ||
logging: process.env.TYPEORM_LOGGING || 'all', | ||
migrations: ['src/migration/**/*.ts'], | ||
namingStrategy: new SnakeNamingStrategy(), | ||
password: process.env.TYPEORM_PASSWORD, | ||
port: parseInt(process.env.TYPEORM_PORT || '', 10) || 5432, | ||
subscribers: ['src/**/*.model.ts'], | ||
synchronize: | ||
typeof process.env.TYPEORM_SYNCHRONIZE !== 'undefined' | ||
? process.env.TYPEORM_SYNCHRONIZE | ||
: process.env.NODE_ENV === 'development', | ||
type: 'postgres', | ||
username: process.env.TYPEORM_USERNAME | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters