package models

import "time"

// RepoMember stores the explicit permission a user has been granted on a repository.
// The repository owner always has implicit admin access and is never stored here.
type RepoMember struct {
	ID         int64     `xorm:"'id' pk autoincr"`
	RepoID     int64     `xorm:"'repo_id' notnull index"`
	UserID     int64     `xorm:"'user_id' notnull index"`
	Permission string    `xorm:"'permission' notnull"` // read | write | admin
	CreatedAt  time.Time `xorm:"'created_at' created"`
}
