mirror of
https://github.com/zitadel/zitadel.git
synced 2025-08-12 04:07:31 +00:00
fix: some backend bugs (#1438)
* fix: fix setup * fix oidc app change * fix: fix migration and proto * fix: fix granted projects * setup1 apis instead of apps * fix: add object detail with creation date * fix user phone change * add localizer to AddOIDCAppResponse * fix test * fix domain test * fix: converter Co-authored-by: Livio Amstutz <livio.a@gmail.com>
This commit is contained in:
@@ -232,6 +232,17 @@ func IDPProviderTypeFromPb(typ idp_pb.IDPOwnerType) domain.IdentityProviderType
|
||||
}
|
||||
}
|
||||
|
||||
func IDPProviderTypeModelFromPb(typ idp_pb.IDPOwnerType) iam_model.IDPProviderType {
|
||||
switch typ {
|
||||
case idp_pb.IDPOwnerType_IDP_OWNER_TYPE_ORG:
|
||||
return iam_model.IDPProviderTypeOrg
|
||||
case idp_pb.IDPOwnerType_IDP_OWNER_TYPE_SYSTEM:
|
||||
return iam_model.IDPProviderTypeSystem
|
||||
default:
|
||||
return iam_model.IDPProviderTypeOrg
|
||||
}
|
||||
}
|
||||
|
||||
func IDPIDQueryToModel(query *idp_pb.IDPIDQuery) *iam_model.IDPConfigSearchQuery {
|
||||
return &iam_model.IDPConfigSearchQuery{
|
||||
Key: iam_model.IDPConfigSearchKeyIdpConfigID, //TODO: whats the difference between idpconfigid and aggregateid search key?
|
||||
@@ -247,3 +258,11 @@ func IDPNameQueryToModel(query *idp_pb.IDPNameQuery) *iam_model.IDPConfigSearchQ
|
||||
Value: query.Name,
|
||||
}
|
||||
}
|
||||
|
||||
func IDPOwnerTypeQueryToModel(query *idp_pb.IDPOwnerTypeQuery) *iam_model.IDPConfigSearchQuery {
|
||||
return &iam_model.IDPConfigSearchQuery{
|
||||
Key: iam_model.IDPConfigSearchKeyName,
|
||||
Method: domain.SearchMethodEquals,
|
||||
Value: IDPProviderTypeModelFromPb(query.OwnerType),
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user