Skip to content

Commit

Permalink
feat(authN): change SapID to UniqueUserId (#85) (#93)
Browse files Browse the repository at this point in the history
* feat(authN): change SapID to UniqueUserId (#85)

Change name of variable SapId to UniqueUserId
Add user Type variable to distinguish technical user and human user

* Automatic application of license header

---------

Co-authored-by: License Bot <[email protected]>
Co-authored-by: David Rochow <[email protected]>
Co-authored-by: Michael Reimsbach <[email protected]>
  • Loading branch information
4 people authored Aug 1, 2024
1 parent e6985b0 commit a7c6260
Show file tree
Hide file tree
Showing 26 changed files with 397 additions and 131 deletions.
177 changes: 145 additions & 32 deletions internal/api/graphql/graph/generated.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 7 additions & 5 deletions internal/api/graphql/graph/model/models.go
Original file line number Diff line number Diff line change
Expand Up @@ -316,16 +316,18 @@ func NewIssueVariantEntity(issueVariant *IssueVariantInput) entity.IssueVariant

func NewUser(user *entity.User) User {
return User{
ID: fmt.Sprintf("%d", user.Id),
SapID: &user.SapID,
Name: &user.Name,
ID: fmt.Sprintf("%d", user.Id),
UniqueUserID: &user.UniqueUserID,
Name: &user.Name,
Type: int(user.Type),
}
}

func NewUserEntity(user *UserInput) entity.User {
return entity.User{
Name: lo.FromPtr(user.Name),
SapID: lo.FromPtr(user.SapID),
Name: lo.FromPtr(user.Name),
UniqueUserID: lo.FromPtr(user.UniqueUserID),
Type: entity.GetUserTypeFromString(lo.FromPtr(user.Type)),
}
}

Expand Down
11 changes: 7 additions & 4 deletions internal/api/graphql/graph/model/models_gen.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@ query ($filter: ActivityFilter, $first: Int, $after: String) {
edges {
node {
id
sapID
uniqueUserId
type
name
}
cursor
Expand Down Expand Up @@ -165,7 +166,8 @@ query ($filter: ActivityFilter, $first: Int, $after: String) {
description
author {
id
sapID
uniqueUserId
type
name
}
activity {
Expand Down Expand Up @@ -260,4 +262,4 @@ query ($filter: ActivityFilter, $first: Int, $after: String) {
nextPageAfter
}
}
}
}
Loading

0 comments on commit a7c6260

Please sign in to comment.