-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #173 from mapeveri/feat/172
Create account bounded context #172
- Loading branch information
Showing
103 changed files
with
494 additions
and
213 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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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,4 @@ | ||
import UpdateUserCommandHandler from '@src/account/application/user/command/updateUserCommandHandler'; | ||
import SignupUserCommandHandler from '@src/account/application/auth/command/signupUserCommandHandler'; | ||
|
||
export const commands = [SignupUserCommandHandler, UpdateUserCommandHandler]; |
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,15 @@ | ||
import RefreshTokenPostController from '@src/account/app/controllers/v1/auth/refreshTokenPostController'; | ||
import UserPutController from '@src/account/app/controllers/v1/user/userPutController'; | ||
import SignupPostController from '@src/account/app/controllers/v1/auth/signupPostController'; | ||
import LoginPostController from '@src/account/app/controllers/v1/auth/loginPostController'; | ||
import MeGetController from '@src/account/app/controllers/v1/auth/meGetController'; | ||
import UserGetController from '@src/account/app/controllers/v1/user/userGetController'; | ||
|
||
export const controllers = [ | ||
LoginPostController, | ||
SignupPostController, | ||
RefreshTokenPostController, | ||
MeGetController, | ||
UserGetController, | ||
UserPutController, | ||
]; |
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,3 @@ | ||
import { UserSchema } from '@src/account/infrastructure/persistence/mikroOrm/entities/user'; | ||
|
||
export const entitySchemas = [UserSchema]; |
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,4 @@ | ||
import FindUserQueryHandler from '@src/account/application/user/query/findUserQueryHandler'; | ||
import GetUserSocialLoginQueryHandler from '@src/account/application/auth/query/getUserSocialLoginQueryHandler'; | ||
|
||
export const queries = [GetUserSocialLoginQueryHandler, FindUserQueryHandler]; |
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,10 @@ | ||
import { USER_REPOSITORY } from '@src/account/domain/user/userRepository'; | ||
|
||
import MikroOrmUserRepository from '@src/account/infrastructure/persistence/mikroOrm/repositories/mikroOrmUserRepository'; | ||
|
||
export const repositories = [ | ||
{ | ||
provide: USER_REPOSITORY, | ||
useClass: MikroOrmUserRepository, | ||
}, | ||
]; |
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,16 @@ | ||
import { Module } from '@nestjs/common'; | ||
|
||
import { controllers } from '@src/account/_dependencyInjection/controllers'; | ||
import { commands } from '@src/account/_dependencyInjection/commandHandlers'; | ||
import { queries } from '@src/account/_dependencyInjection/queryHandlers'; | ||
import { repositories } from '@src/account/_dependencyInjection/repositories'; | ||
import { MikroOrmModule } from '@mikro-orm/nestjs'; | ||
import { entitySchemas as accountEntitySchemas } from '@src/account/_dependencyInjection/entitySchemas'; | ||
|
||
@Module({ | ||
imports: [MikroOrmModule.forFeature([...accountEntitySchemas])], | ||
exports: [], | ||
controllers: [...controllers], | ||
providers: [...commands, ...queries, ...repositories], | ||
}) | ||
export class AccountModule {} |
2 changes: 1 addition & 1 deletion
2
...ontrollers/v1/auth/loginPostController.ts → ...ontrollers/v1/auth/loginPostController.ts
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
File renamed without changes.
File renamed without changes.
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
File renamed without changes.
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
File renamed without changes.
File renamed without changes.
4 changes: 2 additions & 2 deletions
4
...ntrollers/v1/auth/signupPostController.ts → ...ntrollers/v1/auth/signupPostController.ts
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
File renamed without changes.
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
File renamed without changes.
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
File renamed without changes.
File renamed without changes.
10 changes: 5 additions & 5 deletions
10
.../auth/command/signupUserCommandHandler.ts → .../auth/command/signupUserCommandHandler.ts
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
File renamed without changes.
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
File renamed without changes.
File renamed without changes.
8 changes: 4 additions & 4 deletions
8
.../user/command/updateUserCommandHandler.ts → .../user/command/updateUserCommandHandler.ts
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
File renamed without changes.
4 changes: 2 additions & 2 deletions
4
...cation/user/query/findUserQueryHandler.ts → ...cation/user/query/findUserQueryHandler.ts
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
2 changes: 1 addition & 1 deletion
2
...pplication/user/query/findUserResponse.ts → ...pplication/user/query/findUserResponse.ts
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
4 changes: 2 additions & 2 deletions
4
src/languages/domain/user/user.ts → src/account/domain/user/user.ts
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
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
6 changes: 3 additions & 3 deletions
6
...ure/persistence/mikroOrm/entities/user.ts → ...ure/persistence/mikroOrm/entities/user.ts
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
Empty file.
6 changes: 3 additions & 3 deletions
6
...rm/repositories/mikroOrmUserRepository.ts → ...rm/repositories/mikroOrmUserRepository.ts
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
2 changes: 1 addition & 1 deletion
2
.../persistence/mikroOrm/types/userIdType.ts → .../persistence/mikroOrm/types/userIdType.ts
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 |
---|---|---|
@@ -1,8 +1,11 @@ | ||
import { Module } from '@nestjs/common'; | ||
import { LanguageModule } from './languages/language.module'; | ||
import { SharedModule } from './shared/shared.module'; | ||
import { AccountModule } from '@src/account/account.module'; | ||
import { MikroOrmModule } from '@mikro-orm/nestjs'; | ||
import mikroOrmConfiguration from '@src/mikroOrmConfig'; | ||
|
||
@Module({ | ||
imports: [SharedModule, LanguageModule], | ||
imports: [SharedModule, MikroOrmModule.forRoot(mikroOrmConfiguration), AccountModule, LanguageModule], | ||
}) | ||
export class AppModule {} |
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
Oops, something went wrong.