-
Notifications
You must be signed in to change notification settings - Fork 24
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* feat: add getUser controller * feat: adjust userFindById controller * feat: add userFindById controller * feat: add userFindById controller * feat: add userFindById controller * feat: add userFindById controller * feat: create and test userFindById controller
- Loading branch information
1 parent
fa249bc
commit 6c4e188
Showing
7 changed files
with
134 additions
and
5 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
import type { UserModel } from './user-create-model.js'; | ||
|
||
export type UserFindByIdModel = { | ||
id: string; | ||
}; | ||
|
||
export type UserFindByIdResponse = null | UserModel; |
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 |
---|---|---|
@@ -1 +1,2 @@ | ||
export * from './user-create-schema.js'; | ||
export * from './user-find-by-id-schema.js'; |
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 Joi from 'joi'; | ||
|
||
export const userFindByIdParamsSchema = Joi.object({ | ||
id: Joi.string().guid().required(), | ||
}); | ||
|
||
export const userFindByIdSchema = Joi.object({ | ||
params: userFindByIdParamsSchema, | ||
path: Joi.string().required(), | ||
}); |