Merge authentication into master - #7
Open
H3nSte1n wants to merge 19 commits into
Open
Conversation
… creates jwt-tokens
H3nSte1n
commented
Sep 2, 2020
H3nSte1n
commented
Sep 2, 2020
H3nSte1n
left a comment
Author
There was a problem hiding this comment.
Interfaces würde ich den namen z.b. TokenDataInterface geben und dementsprechend auch das file so nennen. Ist schneller und besser ersichtlich um was es sich handelt.
H3nSte1n
commented
Sep 2, 2020
H3nSte1n
commented
Sep 2, 2020
Author
Owner
|
JSDoc werd ich mir anschauen |
rukemn
marked this pull request as ready for review
September 6, 2020 11:57
added user role enum validation, added role-based permissions using "accesscontrol" - npmpackage, added first exemplary query building in CustomerController to check permissions
H3nSte1n
commented
Sep 19, 2020
|
|
||
| private buildGetCustomerQuery = (user: IUser) : mongoose.DocumentQuery<ICustomer[], ICustomer, {}> => { | ||
| let permit = permits.can(user.role).readAny("customer"); | ||
| if (permit.granted) { |
Author
There was a problem hiding this comment.
Du hast hier ziemlich viel doppelten Code drin. Kannst du das evt. zusammenfassen?
|
|
||
| constructor(){ | ||
| public static getInstance = () => { | ||
| if(! ProductController.constroller){ |
Author
There was a problem hiding this comment.
oben schon beschrieben mit der Möglichkeit ohne curly brackets zu arbeiten.
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Merge authentication into master