zitadel/internal/project/model/project_grant_member_view.go
Fabi 7a6ca24625
feat: multiple domains (#188)
* check uniqueness on create and register user

* change user email, reserve release unique email

* usergrant unique aggregate

* usergrant uniqueness

* validate UserGrant

* fix tests

* domain is set on username in all orgs

* domain in admin

* org domain sql

* zitadel domain org name

* org domains

* org iam policy

* default org iam policy

* SETUP

* load login names

* login by login name

* login name

* fix: merge master

* fix: merge master

* Update internal/user/repository/eventsourcing/user.go

Co-authored-by: Livio Amstutz <livio.a@gmail.com>

* fix: fix unique domains

* fix: rename env variable

Co-authored-by: adlerhurst <silvan.reusser@gmail.com>
Co-authored-by: Livio Amstutz <livio.a@gmail.com>
2020-06-16 11:40:18 +02:00

60 lines
1.3 KiB
Go

package model
import (
"github.com/caos/zitadel/internal/model"
"time"
)
type ProjectGrantMemberView struct {
UserID string
GrantID string
ProjectID string
UserName string
Email string
FirstName string
LastName string
Roles []string
CreationDate time.Time
ChangeDate time.Time
Sequence uint64
}
type ProjectGrantMemberSearchRequest struct {
Offset uint64
Limit uint64
SortingColumn ProjectGrantMemberSearchKey
Asc bool
Queries []*ProjectGrantMemberSearchQuery
}
type ProjectGrantMemberSearchKey int32
const (
PROJECTGRANTMEMBERSEARCHKEY_UNSPECIFIED ProjectGrantMemberSearchKey = iota
PROJECTGRANTMEMBERSEARCHKEY_USER_NAME
PROJECTGRANTMEMBERSEARCHKEY_EMAIL
PROJECTGRANTMEMBERSEARCHKEY_FIRST_NAME
PROJECTGRANTMEMBERSEARCHKEY_LAST_NAME
PROJECTGRANTMEMBERSEARCHKEY_GRANT_ID
PROJECTGRANTMEMBERSEARCHKEY_USER_ID
)
type ProjectGrantMemberSearchQuery struct {
Key ProjectGrantMemberSearchKey
Method model.SearchMethod
Value interface{}
}
type ProjectGrantMemberSearchResponse struct {
Offset uint64
Limit uint64
TotalResult uint64
Result []*ProjectGrantMemberView
}
func (r *ProjectGrantMemberSearchRequest) EnsureLimit(limit uint64) {
if r.Limit == 0 || r.Limit > limit {
r.Limit = limit
}
}