models

package
v0.3.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 31, 2024 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DB *pop.Connection

DB is a connection to your database to be used throughout your application.

Functions

This section is empty.

Types

type Project

type Project struct {
	ID          uuid.UUID    `json:"id" db:"id"`
	NsID        string       `json:"ns_id" db:"ns_id"`
	Name        string       `json:"name" db:"name"`
	Description nulls.String `json:"description" db:"description"`
	CreatedAt   time.Time    `json:"created_at" db:"created_at"`
	UpdatedAt   time.Time    `json:"updated_at" db:"updated_at"`
}

Project is used by pop to map your projects database table to your go code.

func (Project) String

func (p Project) String() string

String is not required by pop and may be deleted

func (*Project) Validate

func (p *Project) Validate(tx *pop.Connection) (*validate.Errors, error)

Validate gets run every time you call a "pop.Validate*" (pop.ValidateAndSave, pop.ValidateAndCreate, pop.ValidateAndUpdate) method. This method is not required and may be deleted.

func (*Project) ValidateCreate

func (p *Project) ValidateCreate(tx *pop.Connection) (*validate.Errors, error)

ValidateCreate gets run every time you call "pop.ValidateAndCreate" method. This method is not required and may be deleted.

func (*Project) ValidateUpdate

func (p *Project) ValidateUpdate(tx *pop.Connection) (*validate.Errors, error)

ValidateUpdate gets run every time you call "pop.ValidateAndUpdate" method. This method is not required and may be deleted.

type Projects

type Projects []Project

Projects is not required by pop and may be deleted

func (Projects) String

func (p Projects) String() string

String is not required by pop and may be deleted

type Role

type Role struct {
	ID          uuid.UUID    `json:"id" db:"id"`
	Policy      string       `json:"policy" db:"policy"`
	Name        string       `json:"name" db:"name"`
	Description nulls.String `json:"description" db:"description"`
	CreatedAt   time.Time    `json:"created_at" db:"created_at"`
	UpdatedAt   time.Time    `json:"updated_at" db:"updated_at"`
}

Role is used by pop to map your roles database table to your go code.

func (Role) String

func (r Role) String() string

String is not required by pop and may be deleted

func (*Role) Validate

func (r *Role) Validate(tx *pop.Connection) (*validate.Errors, error)

Validate gets run every time you call a "pop.Validate*" (pop.ValidateAndSave, pop.ValidateAndCreate, pop.ValidateAndUpdate) method. This method is not required and may be deleted.

func (*Role) ValidateCreate

func (r *Role) ValidateCreate(tx *pop.Connection) (*validate.Errors, error)

ValidateCreate gets run every time you call "pop.ValidateAndCreate" method. This method is not required and may be deleted.

func (*Role) ValidateUpdate

func (r *Role) ValidateUpdate(tx *pop.Connection) (*validate.Errors, error)

ValidateUpdate gets run every time you call "pop.ValidateAndUpdate" method. This method is not required and may be deleted.

type Roles

type Roles []Role

Roles is not required by pop and may be deleted

func (Roles) String

func (r Roles) String() string

String is not required by pop and may be deleted

type Workspace

type Workspace struct {
	ID          uuid.UUID    `json:"id" db:"id"`
	Name        string       `json:"name" db:"name"`
	Description nulls.String `json:"description" db:"description"`
	CreatedAt   time.Time    `json:"created_at" db:"created_at"`
	UpdatedAt   time.Time    `json:"updated_at" db:"updated_at"`
}

Workspace is used by pop to map your workspaces database table to your go code.

func (Workspace) String

func (w Workspace) String() string

String is not required by pop and may be deleted

func (*Workspace) Validate

func (w *Workspace) Validate(tx *pop.Connection) (*validate.Errors, error)

Validate gets run every time you call a "pop.Validate*" (pop.ValidateAndSave, pop.ValidateAndCreate, pop.ValidateAndUpdate) method. This method is not required and may be deleted.

func (*Workspace) ValidateCreate

func (w *Workspace) ValidateCreate(tx *pop.Connection) (*validate.Errors, error)

ValidateCreate gets run every time you call "pop.ValidateAndCreate" method. This method is not required and may be deleted.

func (*Workspace) ValidateUpdate

func (w *Workspace) ValidateUpdate(tx *pop.Connection) (*validate.Errors, error)

ValidateUpdate gets run every time you call "pop.ValidateAndUpdate" method. This method is not required and may be deleted.

type WorkspaceProjectMapping

type WorkspaceProjectMapping struct {
	ID          uuid.UUID `json:"id" db:"id"`
	WorkspaceID uuid.UUID `json:"workspace_id" db:"workspace_id"`
	ProjectID   uuid.UUID `json:"project_id" db:"project_id"`
	CreatedAt   time.Time `json:"created_at" db:"created_at"`
	UpdatedAt   time.Time `json:"updated_at" db:"updated_at"`
}

WorkspaceProjectMapping is used by pop to map your workspace_project_mappings database table to your go code.

func (WorkspaceProjectMapping) String

func (w WorkspaceProjectMapping) String() string

String is not required by pop and may be deleted

func (*WorkspaceProjectMapping) Validate

func (w *WorkspaceProjectMapping) Validate(tx *pop.Connection) (*validate.Errors, error)

Validate gets run every time you call a "pop.Validate*" (pop.ValidateAndSave, pop.ValidateAndCreate, pop.ValidateAndUpdate) method. This method is not required and may be deleted.

func (*WorkspaceProjectMapping) ValidateCreate

func (w *WorkspaceProjectMapping) ValidateCreate(tx *pop.Connection) (*validate.Errors, error)

ValidateCreate gets run every time you call "pop.ValidateAndCreate" method. This method is not required and may be deleted.

func (*WorkspaceProjectMapping) ValidateUpdate

func (w *WorkspaceProjectMapping) ValidateUpdate(tx *pop.Connection) (*validate.Errors, error)

ValidateUpdate gets run every time you call "pop.ValidateAndUpdate" method. This method is not required and may be deleted.

type WorkspaceProjectMappings

type WorkspaceProjectMappings []WorkspaceProjectMapping

WorkspaceProjectMappings is not required by pop and may be deleted

func (WorkspaceProjectMappings) String

func (w WorkspaceProjectMappings) String() string

String is not required by pop and may be deleted

type WorkspaceUserRoleMapping

type WorkspaceUserRoleMapping struct {
	ID          uuid.UUID `json:"id" db:"id"`
	WorkspaceID uuid.UUID `json:"workspace_id" db:"workspace_id"`
	UserID      string    `json:"user_id" db:"user_id"`
	RoleID      uuid.UUID `json:"role_id" db:"role_id"`
	CreatedAt   time.Time `json:"created_at" db:"created_at"`
	UpdatedAt   time.Time `json:"updated_at" db:"updated_at"`
}

WorkspaceUserRoleMapping is used by pop to map your workspace_user_role_mappings database table to your go code.

func (WorkspaceUserRoleMapping) String

func (w WorkspaceUserRoleMapping) String() string

String is not required by pop and may be deleted

func (*WorkspaceUserRoleMapping) Validate

func (w *WorkspaceUserRoleMapping) Validate(tx *pop.Connection) (*validate.Errors, error)

Validate gets run every time you call a "pop.Validate*" (pop.ValidateAndSave, pop.ValidateAndCreate, pop.ValidateAndUpdate) method. This method is not required and may be deleted.

func (*WorkspaceUserRoleMapping) ValidateCreate

func (w *WorkspaceUserRoleMapping) ValidateCreate(tx *pop.Connection) (*validate.Errors, error)

ValidateCreate gets run every time you call "pop.ValidateAndCreate" method. This method is not required and may be deleted.

func (*WorkspaceUserRoleMapping) ValidateUpdate

func (w *WorkspaceUserRoleMapping) ValidateUpdate(tx *pop.Connection) (*validate.Errors, error)

ValidateUpdate gets run every time you call "pop.ValidateAndUpdate" method. This method is not required and may be deleted.

type WorkspaceUserRoleMappings

type WorkspaceUserRoleMappings []WorkspaceUserRoleMapping

WorkspaceUserRoleMappings is not required by pop and may be deleted

func (WorkspaceUserRoleMappings) String

func (w WorkspaceUserRoleMappings) String() string

String is not required by pop and may be deleted

type Workspaces

type Workspaces []Workspace

Workspaces is not required by pop and may be deleted

func (Workspaces) String

func (w Workspaces) String() string

String is not required by pop and may be deleted

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL