ent

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Sep 8, 2026 License: MIT Imports: 34 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Operation types.
	OpCreate    = ent.OpCreate
	OpDelete    = ent.OpDelete
	OpDeleteOne = ent.OpDeleteOne
	OpUpdate    = ent.OpUpdate
	OpUpdateOne = ent.OpUpdateOne

	// Node types.
	TypeCustomFieldDef        = "CustomFieldDef"
	TypeDimensionOption       = "DimensionOption"
	TypeEvidence              = "Evidence"
	TypeItem                  = "Item"
	TypeItemAugment           = "ItemAugment"
	TypeOpportunityAssessment = "OpportunityAssessment"
	TypeOpportunitySpec       = "OpportunitySpec"
	TypePortfolioDimension    = "PortfolioDimension"
	TypeProfileAssignment     = "ProfileAssignment"
	TypeRankOverride          = "RankOverride"
	TypeRelease               = "Release"
	TypeReportDataset         = "ReportDataset"
	TypeSyncMeta              = "SyncMeta"
)

Variables

View Source
var ErrTxStarted = errors.New("ent: cannot start a transaction within a transaction")

ErrTxStarted is returned when trying to start a new transaction from a transactional client.

Functions

func Asc

func Asc(fields ...string) func(*sql.Selector)

Asc applies the given fields in ASC order.

func Desc

func Desc(fields ...string) func(*sql.Selector)

Desc applies the given fields in DESC order.

func IsConstraintError

func IsConstraintError(err error) bool

IsConstraintError returns a boolean indicating whether the error is a constraint failure.

func IsNotFound

func IsNotFound(err error) bool

IsNotFound returns a boolean indicating whether the error is a not found error.

func IsNotLoaded

func IsNotLoaded(err error) bool

IsNotLoaded returns a boolean indicating whether the error is a not loaded error.

func IsNotSingular

func IsNotSingular(err error) bool

IsNotSingular returns a boolean indicating whether the error is a not singular error.

func IsValidationError

func IsValidationError(err error) bool

IsValidationError returns a boolean indicating whether the error is a validation error.

func MaskNotFound

func MaskNotFound(err error) error

MaskNotFound masks not found error.

func NewContext

func NewContext(parent context.Context, c *Client) context.Context

NewContext returns a new context with the given Client attached.

func NewTxContext

func NewTxContext(parent context.Context, tx *Tx) context.Context

NewTxContext returns a new context with the given Tx attached.

Types

type AggregateFunc

type AggregateFunc func(*sql.Selector) string

AggregateFunc applies an aggregation step on the group-by traversal/selector.

func As

As is a pseudo aggregation function for renaming another other functions with custom names. For example:

GroupBy(field1, field2).
Aggregate(ent.As(ent.Sum(field1), "sum_field1"), (ent.As(ent.Sum(field2), "sum_field2")).
Scan(ctx, &v)

func Count

func Count() AggregateFunc

Count applies the "count" aggregation function on each group.

func Max

func Max(field string) AggregateFunc

Max applies the "max" aggregation function on the given field of each group.

func Mean

func Mean(field string) AggregateFunc

Mean applies the "mean" aggregation function on the given field of each group.

func Min

func Min(field string) AggregateFunc

Min applies the "min" aggregation function on the given field of each group.

func Sum

func Sum(field string) AggregateFunc

Sum applies the "sum" aggregation function on the given field of each group.

type Client

type Client struct {

	// Schema is the client for creating, migrating and dropping schema.
	Schema *migrate.Schema
	// CustomFieldDef is the client for interacting with the CustomFieldDef builders.
	CustomFieldDef *CustomFieldDefClient
	// DimensionOption is the client for interacting with the DimensionOption builders.
	DimensionOption *DimensionOptionClient
	// Evidence is the client for interacting with the Evidence builders.
	Evidence *EvidenceClient
	// Item is the client for interacting with the Item builders.
	Item *ItemClient
	// ItemAugment is the client for interacting with the ItemAugment builders.
	ItemAugment *ItemAugmentClient
	// OpportunityAssessment is the client for interacting with the OpportunityAssessment builders.
	OpportunityAssessment *OpportunityAssessmentClient
	// OpportunitySpec is the client for interacting with the OpportunitySpec builders.
	OpportunitySpec *OpportunitySpecClient
	// PortfolioDimension is the client for interacting with the PortfolioDimension builders.
	PortfolioDimension *PortfolioDimensionClient
	// ProfileAssignment is the client for interacting with the ProfileAssignment builders.
	ProfileAssignment *ProfileAssignmentClient
	// RankOverride is the client for interacting with the RankOverride builders.
	RankOverride *RankOverrideClient
	// Release is the client for interacting with the Release builders.
	Release *ReleaseClient
	// ReportDataset is the client for interacting with the ReportDataset builders.
	ReportDataset *ReportDatasetClient
	// SyncMeta is the client for interacting with the SyncMeta builders.
	SyncMeta *SyncMetaClient
	// contains filtered or unexported fields
}

Client is the client that holds all ent builders.

func FromContext

func FromContext(ctx context.Context) *Client

FromContext returns a Client stored inside a context, or nil if there isn't one.

func NewClient

func NewClient(opts ...Option) *Client

NewClient creates a new client configured with the given options.

func Open

func Open(driverName, dataSourceName string, options ...Option) (*Client, error)

Open opens a database/sql.DB specified by the driver name and the data source name, and returns a new client attached to it. Optional parameters can be added for configuring the client.

func (*Client) BeginTx

func (c *Client) BeginTx(ctx context.Context, opts *sql.TxOptions) (*Tx, error)

BeginTx returns a transactional client with specified options.

func (*Client) Close

func (c *Client) Close() error

Close closes the database connection and prevents new queries from starting.

func (*Client) Debug

func (c *Client) Debug() *Client

Debug returns a new debug-client. It's used to get verbose logging on specific operations.

client.Debug().
	CustomFieldDef.
	Query().
	Count(ctx)

func (*Client) Intercept

func (c *Client) Intercept(interceptors ...Interceptor)

Intercept adds the query interceptors to all the entity clients. In order to add interceptors to a specific client, call: `client.Node.Intercept(...)`.

func (*Client) Mutate

func (c *Client) Mutate(ctx context.Context, m Mutation) (Value, error)

Mutate implements the ent.Mutator interface.

func (*Client) Tx

func (c *Client) Tx(ctx context.Context) (*Tx, error)

Tx returns a new transactional client. The provided context is used until the transaction is committed or rolled back.

func (*Client) Use

func (c *Client) Use(hooks ...Hook)

Use adds the mutation hooks to all the entity clients. In order to add hooks to a specific client, call: `client.Node.Use(...)`.

type CommitFunc

type CommitFunc func(context.Context, *Tx) error

The CommitFunc type is an adapter to allow the use of ordinary function as a Committer. If f is a function with the appropriate signature, CommitFunc(f) is a Committer that calls f.

func (CommitFunc) Commit

func (f CommitFunc) Commit(ctx context.Context, tx *Tx) error

Commit calls f(ctx, m).

type CommitHook

type CommitHook func(Committer) Committer

CommitHook defines the "commit middleware". A function that gets a Committer and returns a Committer. For example:

hook := func(next ent.Committer) ent.Committer {
	return ent.CommitFunc(func(ctx context.Context, tx *ent.Tx) error {
		// Do some stuff before.
		if err := next.Commit(ctx, tx); err != nil {
			return err
		}
		// Do some stuff after.
		return nil
	})
}

type Committer

type Committer interface {
	Commit(context.Context, *Tx) error
}

Committer is the interface that wraps the Commit method.

type ConstraintError

type ConstraintError struct {
	// contains filtered or unexported fields
}

ConstraintError returns when trying to create/update one or more entities and one or more of their constraints failed. For example, violation of edge or field uniqueness.

func (ConstraintError) Error

func (e ConstraintError) Error() string

Error implements the error interface.

func (*ConstraintError) Unwrap

func (e *ConstraintError) Unwrap() error

Unwrap implements the errors.Wrapper interface.

type CustomFieldDef

type CustomFieldDef struct {

	// ID of the ent.
	ID string `json:"id,omitempty"`
	// Provider holds the value of the "provider" field.
	Provider string `json:"provider,omitempty"`
	// Key holds the value of the "key" field.
	Key string `json:"key,omitempty"`
	// Name holds the value of the "name" field.
	Name string `json:"name,omitempty"`
	// FieldType holds the value of the "field_type" field.
	FieldType string `json:"field_type,omitempty"`
	// Kinds holds the value of the "kinds" field.
	Kinds []string `json:"kinds,omitempty"`
	// Metadata holds the value of the "metadata" field.
	Metadata map[string]interface{} `json:"metadata,omitempty"`
	// SyncedAt holds the value of the "synced_at" field.
	SyncedAt time.Time `json:"synced_at,omitempty"`
	// contains filtered or unexported fields
}

CustomFieldDef is the model entity for the CustomFieldDef schema.

func (*CustomFieldDef) String

func (_m *CustomFieldDef) String() string

String implements the fmt.Stringer.

func (*CustomFieldDef) Unwrap

func (_m *CustomFieldDef) Unwrap() *CustomFieldDef

Unwrap unwraps the CustomFieldDef entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*CustomFieldDef) Update

Update returns a builder for updating this CustomFieldDef. Note that you need to call CustomFieldDef.Unwrap() before calling this method if this CustomFieldDef was returned from a transaction, and the transaction was committed or rolled back.

func (*CustomFieldDef) Value

func (_m *CustomFieldDef) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the CustomFieldDef. This includes values selected through modifiers, order, etc.

type CustomFieldDefClient

type CustomFieldDefClient struct {
	// contains filtered or unexported fields
}

CustomFieldDefClient is a client for the CustomFieldDef schema.

func NewCustomFieldDefClient

func NewCustomFieldDefClient(c config) *CustomFieldDefClient

NewCustomFieldDefClient returns a client for the CustomFieldDef from the given config.

func (*CustomFieldDefClient) Create

Create returns a builder for creating a CustomFieldDef entity.

func (*CustomFieldDefClient) CreateBulk

CreateBulk returns a builder for creating a bulk of CustomFieldDef entities.

func (*CustomFieldDefClient) Delete

Delete returns a delete builder for CustomFieldDef.

func (*CustomFieldDefClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*CustomFieldDefClient) DeleteOneID

DeleteOneID returns a builder for deleting the given entity by its id.

func (*CustomFieldDefClient) Get

Get returns a CustomFieldDef entity by its id.

func (*CustomFieldDefClient) GetX

GetX is like Get, but panics if an error occurs.

func (*CustomFieldDefClient) Hooks

func (c *CustomFieldDefClient) Hooks() []Hook

Hooks returns the client hooks.

func (*CustomFieldDefClient) Intercept

func (c *CustomFieldDefClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `customfielddef.Intercept(f(g(h())))`.

func (*CustomFieldDefClient) Interceptors

func (c *CustomFieldDefClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*CustomFieldDefClient) MapCreateBulk

func (c *CustomFieldDefClient) MapCreateBulk(slice any, setFunc func(*CustomFieldDefCreate, int)) *CustomFieldDefCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*CustomFieldDefClient) Query

Query returns a query builder for CustomFieldDef.

func (*CustomFieldDefClient) Update

Update returns an update builder for CustomFieldDef.

func (*CustomFieldDefClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*CustomFieldDefClient) UpdateOneID

UpdateOneID returns an update builder for the given id.

func (*CustomFieldDefClient) Use

func (c *CustomFieldDefClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `customfielddef.Hooks(f(g(h())))`.

type CustomFieldDefCreate

type CustomFieldDefCreate struct {
	// contains filtered or unexported fields
}

CustomFieldDefCreate is the builder for creating a CustomFieldDef entity.

func (*CustomFieldDefCreate) Exec

func (_c *CustomFieldDefCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*CustomFieldDefCreate) ExecX

func (_c *CustomFieldDefCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*CustomFieldDefCreate) Mutation

Mutation returns the CustomFieldDefMutation object of the builder.

func (*CustomFieldDefCreate) OnConflict

OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:

client.CustomFieldDef.Create().
	SetProvider(v).
	OnConflict(
		// Update the row with the new values
		// the was proposed for insertion.
		sql.ResolveWithNewValues(),
	).
	// Override some of the fields with custom
	// update values.
	Update(func(u *ent.CustomFieldDefUpsert) {
		SetProvider(v+v).
	}).
	Exec(ctx)

func (*CustomFieldDefCreate) OnConflictColumns

func (_c *CustomFieldDefCreate) OnConflictColumns(columns ...string) *CustomFieldDefUpsertOne

OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:

client.CustomFieldDef.Create().
	OnConflict(sql.ConflictColumns(columns...)).
	Exec(ctx)

func (*CustomFieldDefCreate) Save

Save creates the CustomFieldDef in the database.

func (*CustomFieldDefCreate) SaveX

SaveX calls Save and panics if Save returns an error.

func (*CustomFieldDefCreate) SetFieldType

func (_c *CustomFieldDefCreate) SetFieldType(v string) *CustomFieldDefCreate

SetFieldType sets the "field_type" field.

func (*CustomFieldDefCreate) SetID

SetID sets the "id" field.

func (*CustomFieldDefCreate) SetKey

SetKey sets the "key" field.

func (*CustomFieldDefCreate) SetKinds

SetKinds sets the "kinds" field.

func (*CustomFieldDefCreate) SetMetadata

func (_c *CustomFieldDefCreate) SetMetadata(v map[string]interface{}) *CustomFieldDefCreate

SetMetadata sets the "metadata" field.

func (*CustomFieldDefCreate) SetName

SetName sets the "name" field.

func (*CustomFieldDefCreate) SetNillableFieldType

func (_c *CustomFieldDefCreate) SetNillableFieldType(v *string) *CustomFieldDefCreate

SetNillableFieldType sets the "field_type" field if the given value is not nil.

func (*CustomFieldDefCreate) SetNillableName

func (_c *CustomFieldDefCreate) SetNillableName(v *string) *CustomFieldDefCreate

SetNillableName sets the "name" field if the given value is not nil.

func (*CustomFieldDefCreate) SetNillableSyncedAt

func (_c *CustomFieldDefCreate) SetNillableSyncedAt(v *time.Time) *CustomFieldDefCreate

SetNillableSyncedAt sets the "synced_at" field if the given value is not nil.

func (*CustomFieldDefCreate) SetProvider

func (_c *CustomFieldDefCreate) SetProvider(v string) *CustomFieldDefCreate

SetProvider sets the "provider" field.

func (*CustomFieldDefCreate) SetSyncedAt

func (_c *CustomFieldDefCreate) SetSyncedAt(v time.Time) *CustomFieldDefCreate

SetSyncedAt sets the "synced_at" field.

type CustomFieldDefCreateBulk

type CustomFieldDefCreateBulk struct {
	// contains filtered or unexported fields
}

CustomFieldDefCreateBulk is the builder for creating many CustomFieldDef entities in bulk.

func (*CustomFieldDefCreateBulk) Exec

Exec executes the query.

func (*CustomFieldDefCreateBulk) ExecX

func (_c *CustomFieldDefCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*CustomFieldDefCreateBulk) OnConflict

OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:

client.CustomFieldDef.CreateBulk(builders...).
	OnConflict(
		// Update the row with the new values
		// the was proposed for insertion.
		sql.ResolveWithNewValues(),
	).
	// Override some of the fields with custom
	// update values.
	Update(func(u *ent.CustomFieldDefUpsert) {
		SetProvider(v+v).
	}).
	Exec(ctx)

func (*CustomFieldDefCreateBulk) OnConflictColumns

func (_c *CustomFieldDefCreateBulk) OnConflictColumns(columns ...string) *CustomFieldDefUpsertBulk

OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:

client.CustomFieldDef.Create().
	OnConflict(sql.ConflictColumns(columns...)).
	Exec(ctx)

func (*CustomFieldDefCreateBulk) Save

Save creates the CustomFieldDef entities in the database.

func (*CustomFieldDefCreateBulk) SaveX

SaveX is like Save, but panics if an error occurs.

type CustomFieldDefDelete

type CustomFieldDefDelete struct {
	// contains filtered or unexported fields
}

CustomFieldDefDelete is the builder for deleting a CustomFieldDef entity.

func (*CustomFieldDefDelete) Exec

func (_d *CustomFieldDefDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*CustomFieldDefDelete) ExecX

func (_d *CustomFieldDefDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*CustomFieldDefDelete) Where

Where appends a list predicates to the CustomFieldDefDelete builder.

type CustomFieldDefDeleteOne

type CustomFieldDefDeleteOne struct {
	// contains filtered or unexported fields
}

CustomFieldDefDeleteOne is the builder for deleting a single CustomFieldDef entity.

func (*CustomFieldDefDeleteOne) Exec

Exec executes the deletion query.

func (*CustomFieldDefDeleteOne) ExecX

func (_d *CustomFieldDefDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*CustomFieldDefDeleteOne) Where

Where appends a list predicates to the CustomFieldDefDelete builder.

type CustomFieldDefGroupBy

type CustomFieldDefGroupBy struct {
	// contains filtered or unexported fields
}

CustomFieldDefGroupBy is the group-by builder for CustomFieldDef entities.

func (*CustomFieldDefGroupBy) Aggregate

Aggregate adds the given aggregation functions to the group-by query.

func (*CustomFieldDefGroupBy) Bool

func (s *CustomFieldDefGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*CustomFieldDefGroupBy) BoolX

func (s *CustomFieldDefGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*CustomFieldDefGroupBy) Bools

func (s *CustomFieldDefGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*CustomFieldDefGroupBy) BoolsX

func (s *CustomFieldDefGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*CustomFieldDefGroupBy) Float64

func (s *CustomFieldDefGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*CustomFieldDefGroupBy) Float64X

func (s *CustomFieldDefGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*CustomFieldDefGroupBy) Float64s

func (s *CustomFieldDefGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*CustomFieldDefGroupBy) Float64sX

func (s *CustomFieldDefGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*CustomFieldDefGroupBy) Int

func (s *CustomFieldDefGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*CustomFieldDefGroupBy) IntX

func (s *CustomFieldDefGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*CustomFieldDefGroupBy) Ints

func (s *CustomFieldDefGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*CustomFieldDefGroupBy) IntsX

func (s *CustomFieldDefGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*CustomFieldDefGroupBy) Scan

func (_g *CustomFieldDefGroupBy) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*CustomFieldDefGroupBy) ScanX

func (s *CustomFieldDefGroupBy) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*CustomFieldDefGroupBy) String

func (s *CustomFieldDefGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*CustomFieldDefGroupBy) StringX

func (s *CustomFieldDefGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*CustomFieldDefGroupBy) Strings

func (s *CustomFieldDefGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*CustomFieldDefGroupBy) StringsX

func (s *CustomFieldDefGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type CustomFieldDefMutation

type CustomFieldDefMutation struct {
	// contains filtered or unexported fields
}

CustomFieldDefMutation represents an operation that mutates the CustomFieldDef nodes in the graph.

func (*CustomFieldDefMutation) AddField

func (m *CustomFieldDefMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*CustomFieldDefMutation) AddedEdges

func (m *CustomFieldDefMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*CustomFieldDefMutation) AddedField

func (m *CustomFieldDefMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*CustomFieldDefMutation) AddedFields

func (m *CustomFieldDefMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*CustomFieldDefMutation) AddedIDs

func (m *CustomFieldDefMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*CustomFieldDefMutation) AppendKinds

func (m *CustomFieldDefMutation) AppendKinds(s []string)

AppendKinds adds s to the "kinds" field.

func (*CustomFieldDefMutation) AppendedKinds

func (m *CustomFieldDefMutation) AppendedKinds() ([]string, bool)

AppendedKinds returns the list of values that were appended to the "kinds" field in this mutation.

func (*CustomFieldDefMutation) ClearEdge

func (m *CustomFieldDefMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*CustomFieldDefMutation) ClearField

func (m *CustomFieldDefMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*CustomFieldDefMutation) ClearFieldType

func (m *CustomFieldDefMutation) ClearFieldType()

ClearFieldType clears the value of the "field_type" field.

func (*CustomFieldDefMutation) ClearKinds

func (m *CustomFieldDefMutation) ClearKinds()

ClearKinds clears the value of the "kinds" field.

func (*CustomFieldDefMutation) ClearMetadata

func (m *CustomFieldDefMutation) ClearMetadata()

ClearMetadata clears the value of the "metadata" field.

func (*CustomFieldDefMutation) ClearName

func (m *CustomFieldDefMutation) ClearName()

ClearName clears the value of the "name" field.

func (*CustomFieldDefMutation) ClearedEdges

func (m *CustomFieldDefMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*CustomFieldDefMutation) ClearedFields

func (m *CustomFieldDefMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (CustomFieldDefMutation) Client

func (m CustomFieldDefMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*CustomFieldDefMutation) EdgeCleared

func (m *CustomFieldDefMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*CustomFieldDefMutation) Field

func (m *CustomFieldDefMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*CustomFieldDefMutation) FieldCleared

func (m *CustomFieldDefMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*CustomFieldDefMutation) FieldType

func (m *CustomFieldDefMutation) FieldType() (r string, exists bool)

FieldType returns the value of the "field_type" field in the mutation.

func (*CustomFieldDefMutation) FieldTypeCleared

func (m *CustomFieldDefMutation) FieldTypeCleared() bool

FieldTypeCleared returns if the "field_type" field was cleared in this mutation.

func (*CustomFieldDefMutation) Fields

func (m *CustomFieldDefMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*CustomFieldDefMutation) ID

func (m *CustomFieldDefMutation) ID() (id string, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*CustomFieldDefMutation) IDs

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*CustomFieldDefMutation) Key

func (m *CustomFieldDefMutation) Key() (r string, exists bool)

Key returns the value of the "key" field in the mutation.

func (*CustomFieldDefMutation) Kinds

func (m *CustomFieldDefMutation) Kinds() (r []string, exists bool)

Kinds returns the value of the "kinds" field in the mutation.

func (*CustomFieldDefMutation) KindsCleared

func (m *CustomFieldDefMutation) KindsCleared() bool

KindsCleared returns if the "kinds" field was cleared in this mutation.

func (*CustomFieldDefMutation) Metadata

func (m *CustomFieldDefMutation) Metadata() (r map[string]interface{}, exists bool)

Metadata returns the value of the "metadata" field in the mutation.

func (*CustomFieldDefMutation) MetadataCleared

func (m *CustomFieldDefMutation) MetadataCleared() bool

MetadataCleared returns if the "metadata" field was cleared in this mutation.

func (*CustomFieldDefMutation) Name

func (m *CustomFieldDefMutation) Name() (r string, exists bool)

Name returns the value of the "name" field in the mutation.

func (*CustomFieldDefMutation) NameCleared

func (m *CustomFieldDefMutation) NameCleared() bool

NameCleared returns if the "name" field was cleared in this mutation.

func (*CustomFieldDefMutation) OldField

func (m *CustomFieldDefMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*CustomFieldDefMutation) OldFieldType

func (m *CustomFieldDefMutation) OldFieldType(ctx context.Context) (v string, err error)

OldFieldType returns the old "field_type" field's value of the CustomFieldDef entity. If the CustomFieldDef object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*CustomFieldDefMutation) OldKey

func (m *CustomFieldDefMutation) OldKey(ctx context.Context) (v string, err error)

OldKey returns the old "key" field's value of the CustomFieldDef entity. If the CustomFieldDef object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*CustomFieldDefMutation) OldKinds

func (m *CustomFieldDefMutation) OldKinds(ctx context.Context) (v []string, err error)

OldKinds returns the old "kinds" field's value of the CustomFieldDef entity. If the CustomFieldDef object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*CustomFieldDefMutation) OldMetadata

func (m *CustomFieldDefMutation) OldMetadata(ctx context.Context) (v map[string]interface{}, err error)

OldMetadata returns the old "metadata" field's value of the CustomFieldDef entity. If the CustomFieldDef object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*CustomFieldDefMutation) OldName

func (m *CustomFieldDefMutation) OldName(ctx context.Context) (v string, err error)

OldName returns the old "name" field's value of the CustomFieldDef entity. If the CustomFieldDef object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*CustomFieldDefMutation) OldProvider

func (m *CustomFieldDefMutation) OldProvider(ctx context.Context) (v string, err error)

OldProvider returns the old "provider" field's value of the CustomFieldDef entity. If the CustomFieldDef object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*CustomFieldDefMutation) OldSyncedAt

func (m *CustomFieldDefMutation) OldSyncedAt(ctx context.Context) (v time.Time, err error)

OldSyncedAt returns the old "synced_at" field's value of the CustomFieldDef entity. If the CustomFieldDef object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*CustomFieldDefMutation) Op

func (m *CustomFieldDefMutation) Op() Op

Op returns the operation name.

func (*CustomFieldDefMutation) Provider

func (m *CustomFieldDefMutation) Provider() (r string, exists bool)

Provider returns the value of the "provider" field in the mutation.

func (*CustomFieldDefMutation) RemovedEdges

func (m *CustomFieldDefMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*CustomFieldDefMutation) RemovedIDs

func (m *CustomFieldDefMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*CustomFieldDefMutation) ResetEdge

func (m *CustomFieldDefMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*CustomFieldDefMutation) ResetField

func (m *CustomFieldDefMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*CustomFieldDefMutation) ResetFieldType

func (m *CustomFieldDefMutation) ResetFieldType()

ResetFieldType resets all changes to the "field_type" field.

func (*CustomFieldDefMutation) ResetKey

func (m *CustomFieldDefMutation) ResetKey()

ResetKey resets all changes to the "key" field.

func (*CustomFieldDefMutation) ResetKinds

func (m *CustomFieldDefMutation) ResetKinds()

ResetKinds resets all changes to the "kinds" field.

func (*CustomFieldDefMutation) ResetMetadata

func (m *CustomFieldDefMutation) ResetMetadata()

ResetMetadata resets all changes to the "metadata" field.

func (*CustomFieldDefMutation) ResetName

func (m *CustomFieldDefMutation) ResetName()

ResetName resets all changes to the "name" field.

func (*CustomFieldDefMutation) ResetProvider

func (m *CustomFieldDefMutation) ResetProvider()

ResetProvider resets all changes to the "provider" field.

func (*CustomFieldDefMutation) ResetSyncedAt

func (m *CustomFieldDefMutation) ResetSyncedAt()

ResetSyncedAt resets all changes to the "synced_at" field.

func (*CustomFieldDefMutation) SetField

func (m *CustomFieldDefMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*CustomFieldDefMutation) SetFieldType

func (m *CustomFieldDefMutation) SetFieldType(s string)

SetFieldType sets the "field_type" field.

func (*CustomFieldDefMutation) SetID

func (m *CustomFieldDefMutation) SetID(id string)

SetID sets the value of the id field. Note that this operation is only accepted on creation of CustomFieldDef entities.

func (*CustomFieldDefMutation) SetKey

func (m *CustomFieldDefMutation) SetKey(s string)

SetKey sets the "key" field.

func (*CustomFieldDefMutation) SetKinds

func (m *CustomFieldDefMutation) SetKinds(s []string)

SetKinds sets the "kinds" field.

func (*CustomFieldDefMutation) SetMetadata

func (m *CustomFieldDefMutation) SetMetadata(value map[string]interface{})

SetMetadata sets the "metadata" field.

func (*CustomFieldDefMutation) SetName

func (m *CustomFieldDefMutation) SetName(s string)

SetName sets the "name" field.

func (*CustomFieldDefMutation) SetOp

func (m *CustomFieldDefMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*CustomFieldDefMutation) SetProvider

func (m *CustomFieldDefMutation) SetProvider(s string)

SetProvider sets the "provider" field.

func (*CustomFieldDefMutation) SetSyncedAt

func (m *CustomFieldDefMutation) SetSyncedAt(t time.Time)

SetSyncedAt sets the "synced_at" field.

func (*CustomFieldDefMutation) SyncedAt

func (m *CustomFieldDefMutation) SyncedAt() (r time.Time, exists bool)

SyncedAt returns the value of the "synced_at" field in the mutation.

func (CustomFieldDefMutation) Tx

func (m CustomFieldDefMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*CustomFieldDefMutation) Type

func (m *CustomFieldDefMutation) Type() string

Type returns the node type of this mutation (CustomFieldDef).

func (*CustomFieldDefMutation) Where

Where appends a list predicates to the CustomFieldDefMutation builder.

func (*CustomFieldDefMutation) WhereP

func (m *CustomFieldDefMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the CustomFieldDefMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

type CustomFieldDefQuery

type CustomFieldDefQuery struct {
	// contains filtered or unexported fields
}

CustomFieldDefQuery is the builder for querying CustomFieldDef entities.

func (*CustomFieldDefQuery) Aggregate

Aggregate returns a CustomFieldDefSelect configured with the given aggregations.

func (*CustomFieldDefQuery) All

All executes the query and returns a list of CustomFieldDefs.

func (*CustomFieldDefQuery) AllX

AllX is like All, but panics if an error occurs.

func (*CustomFieldDefQuery) Clone

Clone returns a duplicate of the CustomFieldDefQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*CustomFieldDefQuery) Count

func (_q *CustomFieldDefQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*CustomFieldDefQuery) CountX

func (_q *CustomFieldDefQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*CustomFieldDefQuery) Exist

func (_q *CustomFieldDefQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*CustomFieldDefQuery) ExistX

func (_q *CustomFieldDefQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*CustomFieldDefQuery) First

First returns the first CustomFieldDef entity from the query. Returns a *NotFoundError when no CustomFieldDef was found.

func (*CustomFieldDefQuery) FirstID

func (_q *CustomFieldDefQuery) FirstID(ctx context.Context) (id string, err error)

FirstID returns the first CustomFieldDef ID from the query. Returns a *NotFoundError when no CustomFieldDef ID was found.

func (*CustomFieldDefQuery) FirstIDX

func (_q *CustomFieldDefQuery) FirstIDX(ctx context.Context) string

FirstIDX is like FirstID, but panics if an error occurs.

func (*CustomFieldDefQuery) FirstX

FirstX is like First, but panics if an error occurs.

func (*CustomFieldDefQuery) GroupBy

func (_q *CustomFieldDefQuery) GroupBy(field string, fields ...string) *CustomFieldDefGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	Provider string `json:"provider,omitempty"`
	Count int `json:"count,omitempty"`
}

client.CustomFieldDef.Query().
	GroupBy(customfielddef.FieldProvider).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*CustomFieldDefQuery) IDs

func (_q *CustomFieldDefQuery) IDs(ctx context.Context) (ids []string, err error)

IDs executes the query and returns a list of CustomFieldDef IDs.

func (*CustomFieldDefQuery) IDsX

func (_q *CustomFieldDefQuery) IDsX(ctx context.Context) []string

IDsX is like IDs, but panics if an error occurs.

func (*CustomFieldDefQuery) Limit

func (_q *CustomFieldDefQuery) Limit(limit int) *CustomFieldDefQuery

Limit the number of records to be returned by this query.

func (*CustomFieldDefQuery) Offset

func (_q *CustomFieldDefQuery) Offset(offset int) *CustomFieldDefQuery

Offset to start from.

func (*CustomFieldDefQuery) Only

Only returns a single CustomFieldDef entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one CustomFieldDef entity is found. Returns a *NotFoundError when no CustomFieldDef entities are found.

func (*CustomFieldDefQuery) OnlyID

func (_q *CustomFieldDefQuery) OnlyID(ctx context.Context) (id string, err error)

OnlyID is like Only, but returns the only CustomFieldDef ID in the query. Returns a *NotSingularError when more than one CustomFieldDef ID is found. Returns a *NotFoundError when no entities are found.

func (*CustomFieldDefQuery) OnlyIDX

func (_q *CustomFieldDefQuery) OnlyIDX(ctx context.Context) string

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*CustomFieldDefQuery) OnlyX

OnlyX is like Only, but panics if an error occurs.

func (*CustomFieldDefQuery) Order

Order specifies how the records should be ordered.

func (*CustomFieldDefQuery) Select

func (_q *CustomFieldDefQuery) Select(fields ...string) *CustomFieldDefSelect

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	Provider string `json:"provider,omitempty"`
}

client.CustomFieldDef.Query().
	Select(customfielddef.FieldProvider).
	Scan(ctx, &v)

func (*CustomFieldDefQuery) Unique

func (_q *CustomFieldDefQuery) Unique(unique bool) *CustomFieldDefQuery

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*CustomFieldDefQuery) Where

Where adds a new predicate for the CustomFieldDefQuery builder.

type CustomFieldDefSelect

type CustomFieldDefSelect struct {
	*CustomFieldDefQuery
	// contains filtered or unexported fields
}

CustomFieldDefSelect is the builder for selecting fields of CustomFieldDef entities.

func (*CustomFieldDefSelect) Aggregate

Aggregate adds the given aggregation functions to the selector query.

func (*CustomFieldDefSelect) Bool

func (s *CustomFieldDefSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*CustomFieldDefSelect) BoolX

func (s *CustomFieldDefSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*CustomFieldDefSelect) Bools

func (s *CustomFieldDefSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*CustomFieldDefSelect) BoolsX

func (s *CustomFieldDefSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*CustomFieldDefSelect) Float64

func (s *CustomFieldDefSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*CustomFieldDefSelect) Float64X

func (s *CustomFieldDefSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*CustomFieldDefSelect) Float64s

func (s *CustomFieldDefSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*CustomFieldDefSelect) Float64sX

func (s *CustomFieldDefSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*CustomFieldDefSelect) Int

func (s *CustomFieldDefSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*CustomFieldDefSelect) IntX

func (s *CustomFieldDefSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*CustomFieldDefSelect) Ints

func (s *CustomFieldDefSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*CustomFieldDefSelect) IntsX

func (s *CustomFieldDefSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*CustomFieldDefSelect) Scan

func (_s *CustomFieldDefSelect) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*CustomFieldDefSelect) ScanX

func (s *CustomFieldDefSelect) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*CustomFieldDefSelect) String

func (s *CustomFieldDefSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*CustomFieldDefSelect) StringX

func (s *CustomFieldDefSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*CustomFieldDefSelect) Strings

func (s *CustomFieldDefSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*CustomFieldDefSelect) StringsX

func (s *CustomFieldDefSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type CustomFieldDefUpdate

type CustomFieldDefUpdate struct {
	// contains filtered or unexported fields
}

CustomFieldDefUpdate is the builder for updating CustomFieldDef entities.

func (*CustomFieldDefUpdate) AppendKinds

func (_u *CustomFieldDefUpdate) AppendKinds(v []string) *CustomFieldDefUpdate

AppendKinds appends value to the "kinds" field.

func (*CustomFieldDefUpdate) ClearFieldType

func (_u *CustomFieldDefUpdate) ClearFieldType() *CustomFieldDefUpdate

ClearFieldType clears the value of the "field_type" field.

func (*CustomFieldDefUpdate) ClearKinds

func (_u *CustomFieldDefUpdate) ClearKinds() *CustomFieldDefUpdate

ClearKinds clears the value of the "kinds" field.

func (*CustomFieldDefUpdate) ClearMetadata

func (_u *CustomFieldDefUpdate) ClearMetadata() *CustomFieldDefUpdate

ClearMetadata clears the value of the "metadata" field.

func (*CustomFieldDefUpdate) ClearName

func (_u *CustomFieldDefUpdate) ClearName() *CustomFieldDefUpdate

ClearName clears the value of the "name" field.

func (*CustomFieldDefUpdate) Exec

func (_u *CustomFieldDefUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*CustomFieldDefUpdate) ExecX

func (_u *CustomFieldDefUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*CustomFieldDefUpdate) Mutation

Mutation returns the CustomFieldDefMutation object of the builder.

func (*CustomFieldDefUpdate) Save

func (_u *CustomFieldDefUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*CustomFieldDefUpdate) SaveX

func (_u *CustomFieldDefUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*CustomFieldDefUpdate) SetFieldType

func (_u *CustomFieldDefUpdate) SetFieldType(v string) *CustomFieldDefUpdate

SetFieldType sets the "field_type" field.

func (*CustomFieldDefUpdate) SetKey

SetKey sets the "key" field.

func (*CustomFieldDefUpdate) SetKinds

SetKinds sets the "kinds" field.

func (*CustomFieldDefUpdate) SetMetadata

func (_u *CustomFieldDefUpdate) SetMetadata(v map[string]interface{}) *CustomFieldDefUpdate

SetMetadata sets the "metadata" field.

func (*CustomFieldDefUpdate) SetName

SetName sets the "name" field.

func (*CustomFieldDefUpdate) SetNillableFieldType

func (_u *CustomFieldDefUpdate) SetNillableFieldType(v *string) *CustomFieldDefUpdate

SetNillableFieldType sets the "field_type" field if the given value is not nil.

func (*CustomFieldDefUpdate) SetNillableKey

func (_u *CustomFieldDefUpdate) SetNillableKey(v *string) *CustomFieldDefUpdate

SetNillableKey sets the "key" field if the given value is not nil.

func (*CustomFieldDefUpdate) SetNillableName

func (_u *CustomFieldDefUpdate) SetNillableName(v *string) *CustomFieldDefUpdate

SetNillableName sets the "name" field if the given value is not nil.

func (*CustomFieldDefUpdate) SetNillableProvider

func (_u *CustomFieldDefUpdate) SetNillableProvider(v *string) *CustomFieldDefUpdate

SetNillableProvider sets the "provider" field if the given value is not nil.

func (*CustomFieldDefUpdate) SetNillableSyncedAt

func (_u *CustomFieldDefUpdate) SetNillableSyncedAt(v *time.Time) *CustomFieldDefUpdate

SetNillableSyncedAt sets the "synced_at" field if the given value is not nil.

func (*CustomFieldDefUpdate) SetProvider

func (_u *CustomFieldDefUpdate) SetProvider(v string) *CustomFieldDefUpdate

SetProvider sets the "provider" field.

func (*CustomFieldDefUpdate) SetSyncedAt

func (_u *CustomFieldDefUpdate) SetSyncedAt(v time.Time) *CustomFieldDefUpdate

SetSyncedAt sets the "synced_at" field.

func (*CustomFieldDefUpdate) Where

Where appends a list predicates to the CustomFieldDefUpdate builder.

type CustomFieldDefUpdateOne

type CustomFieldDefUpdateOne struct {
	// contains filtered or unexported fields
}

CustomFieldDefUpdateOne is the builder for updating a single CustomFieldDef entity.

func (*CustomFieldDefUpdateOne) AppendKinds

AppendKinds appends value to the "kinds" field.

func (*CustomFieldDefUpdateOne) ClearFieldType

func (_u *CustomFieldDefUpdateOne) ClearFieldType() *CustomFieldDefUpdateOne

ClearFieldType clears the value of the "field_type" field.

func (*CustomFieldDefUpdateOne) ClearKinds

ClearKinds clears the value of the "kinds" field.

func (*CustomFieldDefUpdateOne) ClearMetadata

func (_u *CustomFieldDefUpdateOne) ClearMetadata() *CustomFieldDefUpdateOne

ClearMetadata clears the value of the "metadata" field.

func (*CustomFieldDefUpdateOne) ClearName

ClearName clears the value of the "name" field.

func (*CustomFieldDefUpdateOne) Exec

Exec executes the query on the entity.

func (*CustomFieldDefUpdateOne) ExecX

func (_u *CustomFieldDefUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*CustomFieldDefUpdateOne) Mutation

Mutation returns the CustomFieldDefMutation object of the builder.

func (*CustomFieldDefUpdateOne) Save

Save executes the query and returns the updated CustomFieldDef entity.

func (*CustomFieldDefUpdateOne) SaveX

SaveX is like Save, but panics if an error occurs.

func (*CustomFieldDefUpdateOne) Select

func (_u *CustomFieldDefUpdateOne) Select(field string, fields ...string) *CustomFieldDefUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*CustomFieldDefUpdateOne) SetFieldType

SetFieldType sets the "field_type" field.

func (*CustomFieldDefUpdateOne) SetKey

SetKey sets the "key" field.

func (*CustomFieldDefUpdateOne) SetKinds

SetKinds sets the "kinds" field.

func (*CustomFieldDefUpdateOne) SetMetadata

func (_u *CustomFieldDefUpdateOne) SetMetadata(v map[string]interface{}) *CustomFieldDefUpdateOne

SetMetadata sets the "metadata" field.

func (*CustomFieldDefUpdateOne) SetName

SetName sets the "name" field.

func (*CustomFieldDefUpdateOne) SetNillableFieldType

func (_u *CustomFieldDefUpdateOne) SetNillableFieldType(v *string) *CustomFieldDefUpdateOne

SetNillableFieldType sets the "field_type" field if the given value is not nil.

func (*CustomFieldDefUpdateOne) SetNillableKey

func (_u *CustomFieldDefUpdateOne) SetNillableKey(v *string) *CustomFieldDefUpdateOne

SetNillableKey sets the "key" field if the given value is not nil.

func (*CustomFieldDefUpdateOne) SetNillableName

func (_u *CustomFieldDefUpdateOne) SetNillableName(v *string) *CustomFieldDefUpdateOne

SetNillableName sets the "name" field if the given value is not nil.

func (*CustomFieldDefUpdateOne) SetNillableProvider

func (_u *CustomFieldDefUpdateOne) SetNillableProvider(v *string) *CustomFieldDefUpdateOne

SetNillableProvider sets the "provider" field if the given value is not nil.

func (*CustomFieldDefUpdateOne) SetNillableSyncedAt

func (_u *CustomFieldDefUpdateOne) SetNillableSyncedAt(v *time.Time) *CustomFieldDefUpdateOne

SetNillableSyncedAt sets the "synced_at" field if the given value is not nil.

func (*CustomFieldDefUpdateOne) SetProvider

SetProvider sets the "provider" field.

func (*CustomFieldDefUpdateOne) SetSyncedAt

SetSyncedAt sets the "synced_at" field.

func (*CustomFieldDefUpdateOne) Where

Where appends a list predicates to the CustomFieldDefUpdate builder.

type CustomFieldDefUpsert

type CustomFieldDefUpsert struct {
	*sql.UpdateSet
}

CustomFieldDefUpsert is the "OnConflict" setter.

func (*CustomFieldDefUpsert) ClearFieldType

func (u *CustomFieldDefUpsert) ClearFieldType() *CustomFieldDefUpsert

ClearFieldType clears the value of the "field_type" field.

func (*CustomFieldDefUpsert) ClearKinds

func (u *CustomFieldDefUpsert) ClearKinds() *CustomFieldDefUpsert

ClearKinds clears the value of the "kinds" field.

func (*CustomFieldDefUpsert) ClearMetadata

func (u *CustomFieldDefUpsert) ClearMetadata() *CustomFieldDefUpsert

ClearMetadata clears the value of the "metadata" field.

func (*CustomFieldDefUpsert) ClearName

ClearName clears the value of the "name" field.

func (*CustomFieldDefUpsert) SetFieldType

func (u *CustomFieldDefUpsert) SetFieldType(v string) *CustomFieldDefUpsert

SetFieldType sets the "field_type" field.

func (*CustomFieldDefUpsert) SetKey

SetKey sets the "key" field.

func (*CustomFieldDefUpsert) SetKinds

SetKinds sets the "kinds" field.

func (*CustomFieldDefUpsert) SetMetadata

func (u *CustomFieldDefUpsert) SetMetadata(v map[string]interface{}) *CustomFieldDefUpsert

SetMetadata sets the "metadata" field.

func (*CustomFieldDefUpsert) SetName

SetName sets the "name" field.

func (*CustomFieldDefUpsert) SetProvider

SetProvider sets the "provider" field.

func (*CustomFieldDefUpsert) SetSyncedAt

SetSyncedAt sets the "synced_at" field.

func (*CustomFieldDefUpsert) UpdateFieldType

func (u *CustomFieldDefUpsert) UpdateFieldType() *CustomFieldDefUpsert

UpdateFieldType sets the "field_type" field to the value that was provided on create.

func (*CustomFieldDefUpsert) UpdateKey

UpdateKey sets the "key" field to the value that was provided on create.

func (*CustomFieldDefUpsert) UpdateKinds

func (u *CustomFieldDefUpsert) UpdateKinds() *CustomFieldDefUpsert

UpdateKinds sets the "kinds" field to the value that was provided on create.

func (*CustomFieldDefUpsert) UpdateMetadata

func (u *CustomFieldDefUpsert) UpdateMetadata() *CustomFieldDefUpsert

UpdateMetadata sets the "metadata" field to the value that was provided on create.

func (*CustomFieldDefUpsert) UpdateName

func (u *CustomFieldDefUpsert) UpdateName() *CustomFieldDefUpsert

UpdateName sets the "name" field to the value that was provided on create.

func (*CustomFieldDefUpsert) UpdateProvider

func (u *CustomFieldDefUpsert) UpdateProvider() *CustomFieldDefUpsert

UpdateProvider sets the "provider" field to the value that was provided on create.

func (*CustomFieldDefUpsert) UpdateSyncedAt

func (u *CustomFieldDefUpsert) UpdateSyncedAt() *CustomFieldDefUpsert

UpdateSyncedAt sets the "synced_at" field to the value that was provided on create.

type CustomFieldDefUpsertBulk

type CustomFieldDefUpsertBulk struct {
	// contains filtered or unexported fields
}

CustomFieldDefUpsertBulk is the builder for "upsert"-ing a bulk of CustomFieldDef nodes.

func (*CustomFieldDefUpsertBulk) ClearFieldType

ClearFieldType clears the value of the "field_type" field.

func (*CustomFieldDefUpsertBulk) ClearKinds

ClearKinds clears the value of the "kinds" field.

func (*CustomFieldDefUpsertBulk) ClearMetadata

ClearMetadata clears the value of the "metadata" field.

func (*CustomFieldDefUpsertBulk) ClearName

ClearName clears the value of the "name" field.

func (*CustomFieldDefUpsertBulk) DoNothing

DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.

func (*CustomFieldDefUpsertBulk) Exec

Exec executes the query.

func (*CustomFieldDefUpsertBulk) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*CustomFieldDefUpsertBulk) Ignore

Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:

client.CustomFieldDef.Create().
	OnConflict(sql.ResolveWithIgnore()).
	Exec(ctx)

func (*CustomFieldDefUpsertBulk) SetFieldType

SetFieldType sets the "field_type" field.

func (*CustomFieldDefUpsertBulk) SetKey

SetKey sets the "key" field.

func (*CustomFieldDefUpsertBulk) SetKinds

SetKinds sets the "kinds" field.

func (*CustomFieldDefUpsertBulk) SetMetadata

func (u *CustomFieldDefUpsertBulk) SetMetadata(v map[string]interface{}) *CustomFieldDefUpsertBulk

SetMetadata sets the "metadata" field.

func (*CustomFieldDefUpsertBulk) SetName

SetName sets the "name" field.

func (*CustomFieldDefUpsertBulk) SetProvider

SetProvider sets the "provider" field.

func (*CustomFieldDefUpsertBulk) SetSyncedAt

SetSyncedAt sets the "synced_at" field.

func (*CustomFieldDefUpsertBulk) Update

Update allows overriding fields `UPDATE` values. See the CustomFieldDefCreateBulk.OnConflict documentation for more info.

func (*CustomFieldDefUpsertBulk) UpdateFieldType

func (u *CustomFieldDefUpsertBulk) UpdateFieldType() *CustomFieldDefUpsertBulk

UpdateFieldType sets the "field_type" field to the value that was provided on create.

func (*CustomFieldDefUpsertBulk) UpdateKey

UpdateKey sets the "key" field to the value that was provided on create.

func (*CustomFieldDefUpsertBulk) UpdateKinds

UpdateKinds sets the "kinds" field to the value that was provided on create.

func (*CustomFieldDefUpsertBulk) UpdateMetadata

UpdateMetadata sets the "metadata" field to the value that was provided on create.

func (*CustomFieldDefUpsertBulk) UpdateName

UpdateName sets the "name" field to the value that was provided on create.

func (*CustomFieldDefUpsertBulk) UpdateNewValues

func (u *CustomFieldDefUpsertBulk) UpdateNewValues() *CustomFieldDefUpsertBulk

UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:

client.CustomFieldDef.Create().
	OnConflict(
		sql.ResolveWithNewValues(),
		sql.ResolveWith(func(u *sql.UpdateSet) {
			u.SetIgnore(customfielddef.FieldID)
		}),
	).
	Exec(ctx)

func (*CustomFieldDefUpsertBulk) UpdateProvider

UpdateProvider sets the "provider" field to the value that was provided on create.

func (*CustomFieldDefUpsertBulk) UpdateSyncedAt

UpdateSyncedAt sets the "synced_at" field to the value that was provided on create.

type CustomFieldDefUpsertOne

type CustomFieldDefUpsertOne struct {
	// contains filtered or unexported fields
}

CustomFieldDefUpsertOne is the builder for "upsert"-ing

one CustomFieldDef node.

func (*CustomFieldDefUpsertOne) ClearFieldType

func (u *CustomFieldDefUpsertOne) ClearFieldType() *CustomFieldDefUpsertOne

ClearFieldType clears the value of the "field_type" field.

func (*CustomFieldDefUpsertOne) ClearKinds

ClearKinds clears the value of the "kinds" field.

func (*CustomFieldDefUpsertOne) ClearMetadata

ClearMetadata clears the value of the "metadata" field.

func (*CustomFieldDefUpsertOne) ClearName

ClearName clears the value of the "name" field.

func (*CustomFieldDefUpsertOne) DoNothing

DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.

func (*CustomFieldDefUpsertOne) Exec

Exec executes the query.

func (*CustomFieldDefUpsertOne) ExecX

func (u *CustomFieldDefUpsertOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*CustomFieldDefUpsertOne) ID

func (u *CustomFieldDefUpsertOne) ID(ctx context.Context) (id string, err error)

Exec executes the UPSERT query and returns the inserted/updated ID.

func (*CustomFieldDefUpsertOne) IDX

IDX is like ID, but panics if an error occurs.

func (*CustomFieldDefUpsertOne) Ignore

Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:

client.CustomFieldDef.Create().
    OnConflict(sql.ResolveWithIgnore()).
    Exec(ctx)

func (*CustomFieldDefUpsertOne) SetFieldType

SetFieldType sets the "field_type" field.

func (*CustomFieldDefUpsertOne) SetKey

SetKey sets the "key" field.

func (*CustomFieldDefUpsertOne) SetKinds

SetKinds sets the "kinds" field.

func (*CustomFieldDefUpsertOne) SetMetadata

func (u *CustomFieldDefUpsertOne) SetMetadata(v map[string]interface{}) *CustomFieldDefUpsertOne

SetMetadata sets the "metadata" field.

func (*CustomFieldDefUpsertOne) SetName

SetName sets the "name" field.

func (*CustomFieldDefUpsertOne) SetProvider

SetProvider sets the "provider" field.

func (*CustomFieldDefUpsertOne) SetSyncedAt

SetSyncedAt sets the "synced_at" field.

func (*CustomFieldDefUpsertOne) Update

Update allows overriding fields `UPDATE` values. See the CustomFieldDefCreate.OnConflict documentation for more info.

func (*CustomFieldDefUpsertOne) UpdateFieldType

func (u *CustomFieldDefUpsertOne) UpdateFieldType() *CustomFieldDefUpsertOne

UpdateFieldType sets the "field_type" field to the value that was provided on create.

func (*CustomFieldDefUpsertOne) UpdateKey

UpdateKey sets the "key" field to the value that was provided on create.

func (*CustomFieldDefUpsertOne) UpdateKinds

UpdateKinds sets the "kinds" field to the value that was provided on create.

func (*CustomFieldDefUpsertOne) UpdateMetadata

func (u *CustomFieldDefUpsertOne) UpdateMetadata() *CustomFieldDefUpsertOne

UpdateMetadata sets the "metadata" field to the value that was provided on create.

func (*CustomFieldDefUpsertOne) UpdateName

UpdateName sets the "name" field to the value that was provided on create.

func (*CustomFieldDefUpsertOne) UpdateNewValues

func (u *CustomFieldDefUpsertOne) UpdateNewValues() *CustomFieldDefUpsertOne

UpdateNewValues updates the mutable fields using the new values that were set on create except the ID field. Using this option is equivalent to using:

client.CustomFieldDef.Create().
	OnConflict(
		sql.ResolveWithNewValues(),
		sql.ResolveWith(func(u *sql.UpdateSet) {
			u.SetIgnore(customfielddef.FieldID)
		}),
	).
	Exec(ctx)

func (*CustomFieldDefUpsertOne) UpdateProvider

func (u *CustomFieldDefUpsertOne) UpdateProvider() *CustomFieldDefUpsertOne

UpdateProvider sets the "provider" field to the value that was provided on create.

func (*CustomFieldDefUpsertOne) UpdateSyncedAt

func (u *CustomFieldDefUpsertOne) UpdateSyncedAt() *CustomFieldDefUpsertOne

UpdateSyncedAt sets the "synced_at" field to the value that was provided on create.

type CustomFieldDefs

type CustomFieldDefs []*CustomFieldDef

CustomFieldDefs is a parsable slice of CustomFieldDef.

type DimensionOption

type DimensionOption struct {

	// ID of the ent.
	ID string `json:"id,omitempty"`
	// DimensionRowID holds the value of the "dimension_row_id" field.
	DimensionRowID string `json:"dimension_row_id,omitempty"`
	// OptionID holds the value of the "option_id" field.
	OptionID string `json:"option_id,omitempty"`
	// Label holds the value of the "label" field.
	Label string `json:"label,omitempty"`
	// Questions holds the value of the "questions" field.
	Questions []assessment.DimensionQuestion `json:"questions,omitempty"`
	// Sequence holds the value of the "sequence" field.
	Sequence int `json:"sequence,omitempty"`
	// contains filtered or unexported fields
}

DimensionOption is the model entity for the DimensionOption schema.

func (*DimensionOption) String

func (_m *DimensionOption) String() string

String implements the fmt.Stringer.

func (*DimensionOption) Unwrap

func (_m *DimensionOption) Unwrap() *DimensionOption

Unwrap unwraps the DimensionOption entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*DimensionOption) Update

Update returns a builder for updating this DimensionOption. Note that you need to call DimensionOption.Unwrap() before calling this method if this DimensionOption was returned from a transaction, and the transaction was committed or rolled back.

func (*DimensionOption) Value

func (_m *DimensionOption) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the DimensionOption. This includes values selected through modifiers, order, etc.

type DimensionOptionClient

type DimensionOptionClient struct {
	// contains filtered or unexported fields
}

DimensionOptionClient is a client for the DimensionOption schema.

func NewDimensionOptionClient

func NewDimensionOptionClient(c config) *DimensionOptionClient

NewDimensionOptionClient returns a client for the DimensionOption from the given config.

func (*DimensionOptionClient) Create

Create returns a builder for creating a DimensionOption entity.

func (*DimensionOptionClient) CreateBulk

CreateBulk returns a builder for creating a bulk of DimensionOption entities.

func (*DimensionOptionClient) Delete

Delete returns a delete builder for DimensionOption.

func (*DimensionOptionClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*DimensionOptionClient) DeleteOneID

DeleteOneID returns a builder for deleting the given entity by its id.

func (*DimensionOptionClient) Get

Get returns a DimensionOption entity by its id.

func (*DimensionOptionClient) GetX

GetX is like Get, but panics if an error occurs.

func (*DimensionOptionClient) Hooks

func (c *DimensionOptionClient) Hooks() []Hook

Hooks returns the client hooks.

func (*DimensionOptionClient) Intercept

func (c *DimensionOptionClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `dimensionoption.Intercept(f(g(h())))`.

func (*DimensionOptionClient) Interceptors

func (c *DimensionOptionClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*DimensionOptionClient) MapCreateBulk

func (c *DimensionOptionClient) MapCreateBulk(slice any, setFunc func(*DimensionOptionCreate, int)) *DimensionOptionCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*DimensionOptionClient) Query

Query returns a query builder for DimensionOption.

func (*DimensionOptionClient) Update

Update returns an update builder for DimensionOption.

func (*DimensionOptionClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*DimensionOptionClient) UpdateOneID

UpdateOneID returns an update builder for the given id.

func (*DimensionOptionClient) Use

func (c *DimensionOptionClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `dimensionoption.Hooks(f(g(h())))`.

type DimensionOptionCreate

type DimensionOptionCreate struct {
	// contains filtered or unexported fields
}

DimensionOptionCreate is the builder for creating a DimensionOption entity.

func (*DimensionOptionCreate) Exec

Exec executes the query.

func (*DimensionOptionCreate) ExecX

func (_c *DimensionOptionCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*DimensionOptionCreate) Mutation

Mutation returns the DimensionOptionMutation object of the builder.

func (*DimensionOptionCreate) OnConflict

OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:

client.DimensionOption.Create().
	SetDimensionRowID(v).
	OnConflict(
		// Update the row with the new values
		// the was proposed for insertion.
		sql.ResolveWithNewValues(),
	).
	// Override some of the fields with custom
	// update values.
	Update(func(u *ent.DimensionOptionUpsert) {
		SetDimensionRowID(v+v).
	}).
	Exec(ctx)

func (*DimensionOptionCreate) OnConflictColumns

func (_c *DimensionOptionCreate) OnConflictColumns(columns ...string) *DimensionOptionUpsertOne

OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:

client.DimensionOption.Create().
	OnConflict(sql.ConflictColumns(columns...)).
	Exec(ctx)

func (*DimensionOptionCreate) Save

Save creates the DimensionOption in the database.

func (*DimensionOptionCreate) SaveX

SaveX calls Save and panics if Save returns an error.

func (*DimensionOptionCreate) SetDimensionRowID

func (_c *DimensionOptionCreate) SetDimensionRowID(v string) *DimensionOptionCreate

SetDimensionRowID sets the "dimension_row_id" field.

func (*DimensionOptionCreate) SetID

SetID sets the "id" field.

func (*DimensionOptionCreate) SetLabel

SetLabel sets the "label" field.

func (*DimensionOptionCreate) SetNillableSequence

func (_c *DimensionOptionCreate) SetNillableSequence(v *int) *DimensionOptionCreate

SetNillableSequence sets the "sequence" field if the given value is not nil.

func (*DimensionOptionCreate) SetOptionID

SetOptionID sets the "option_id" field.

func (*DimensionOptionCreate) SetQuestions

SetQuestions sets the "questions" field.

func (*DimensionOptionCreate) SetSequence

func (_c *DimensionOptionCreate) SetSequence(v int) *DimensionOptionCreate

SetSequence sets the "sequence" field.

type DimensionOptionCreateBulk

type DimensionOptionCreateBulk struct {
	// contains filtered or unexported fields
}

DimensionOptionCreateBulk is the builder for creating many DimensionOption entities in bulk.

func (*DimensionOptionCreateBulk) Exec

Exec executes the query.

func (*DimensionOptionCreateBulk) ExecX

func (_c *DimensionOptionCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*DimensionOptionCreateBulk) OnConflict

OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:

client.DimensionOption.CreateBulk(builders...).
	OnConflict(
		// Update the row with the new values
		// the was proposed for insertion.
		sql.ResolveWithNewValues(),
	).
	// Override some of the fields with custom
	// update values.
	Update(func(u *ent.DimensionOptionUpsert) {
		SetDimensionRowID(v+v).
	}).
	Exec(ctx)

func (*DimensionOptionCreateBulk) OnConflictColumns

func (_c *DimensionOptionCreateBulk) OnConflictColumns(columns ...string) *DimensionOptionUpsertBulk

OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:

client.DimensionOption.Create().
	OnConflict(sql.ConflictColumns(columns...)).
	Exec(ctx)

func (*DimensionOptionCreateBulk) Save

Save creates the DimensionOption entities in the database.

func (*DimensionOptionCreateBulk) SaveX

SaveX is like Save, but panics if an error occurs.

type DimensionOptionDelete

type DimensionOptionDelete struct {
	// contains filtered or unexported fields
}

DimensionOptionDelete is the builder for deleting a DimensionOption entity.

func (*DimensionOptionDelete) Exec

func (_d *DimensionOptionDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*DimensionOptionDelete) ExecX

func (_d *DimensionOptionDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*DimensionOptionDelete) Where

Where appends a list predicates to the DimensionOptionDelete builder.

type DimensionOptionDeleteOne

type DimensionOptionDeleteOne struct {
	// contains filtered or unexported fields
}

DimensionOptionDeleteOne is the builder for deleting a single DimensionOption entity.

func (*DimensionOptionDeleteOne) Exec

Exec executes the deletion query.

func (*DimensionOptionDeleteOne) ExecX

func (_d *DimensionOptionDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*DimensionOptionDeleteOne) Where

Where appends a list predicates to the DimensionOptionDelete builder.

type DimensionOptionGroupBy

type DimensionOptionGroupBy struct {
	// contains filtered or unexported fields
}

DimensionOptionGroupBy is the group-by builder for DimensionOption entities.

func (*DimensionOptionGroupBy) Aggregate

Aggregate adds the given aggregation functions to the group-by query.

func (*DimensionOptionGroupBy) Bool

func (s *DimensionOptionGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*DimensionOptionGroupBy) BoolX

func (s *DimensionOptionGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*DimensionOptionGroupBy) Bools

func (s *DimensionOptionGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*DimensionOptionGroupBy) BoolsX

func (s *DimensionOptionGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*DimensionOptionGroupBy) Float64

func (s *DimensionOptionGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*DimensionOptionGroupBy) Float64X

func (s *DimensionOptionGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*DimensionOptionGroupBy) Float64s

func (s *DimensionOptionGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*DimensionOptionGroupBy) Float64sX

func (s *DimensionOptionGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*DimensionOptionGroupBy) Int

func (s *DimensionOptionGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*DimensionOptionGroupBy) IntX

func (s *DimensionOptionGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*DimensionOptionGroupBy) Ints

func (s *DimensionOptionGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*DimensionOptionGroupBy) IntsX

func (s *DimensionOptionGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*DimensionOptionGroupBy) Scan

func (_g *DimensionOptionGroupBy) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*DimensionOptionGroupBy) ScanX

func (s *DimensionOptionGroupBy) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*DimensionOptionGroupBy) String

func (s *DimensionOptionGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*DimensionOptionGroupBy) StringX

func (s *DimensionOptionGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*DimensionOptionGroupBy) Strings

func (s *DimensionOptionGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*DimensionOptionGroupBy) StringsX

func (s *DimensionOptionGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type DimensionOptionMutation

type DimensionOptionMutation struct {
	// contains filtered or unexported fields
}

DimensionOptionMutation represents an operation that mutates the DimensionOption nodes in the graph.

func (*DimensionOptionMutation) AddField

func (m *DimensionOptionMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*DimensionOptionMutation) AddSequence

func (m *DimensionOptionMutation) AddSequence(i int)

AddSequence adds i to the "sequence" field.

func (*DimensionOptionMutation) AddedEdges

func (m *DimensionOptionMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*DimensionOptionMutation) AddedField

func (m *DimensionOptionMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*DimensionOptionMutation) AddedFields

func (m *DimensionOptionMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*DimensionOptionMutation) AddedIDs

func (m *DimensionOptionMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*DimensionOptionMutation) AddedSequence

func (m *DimensionOptionMutation) AddedSequence() (r int, exists bool)

AddedSequence returns the value that was added to the "sequence" field in this mutation.

func (*DimensionOptionMutation) AppendQuestions

func (m *DimensionOptionMutation) AppendQuestions(aq []assessment.DimensionQuestion)

AppendQuestions adds aq to the "questions" field.

func (*DimensionOptionMutation) AppendedQuestions

func (m *DimensionOptionMutation) AppendedQuestions() ([]assessment.DimensionQuestion, bool)

AppendedQuestions returns the list of values that were appended to the "questions" field in this mutation.

func (*DimensionOptionMutation) ClearEdge

func (m *DimensionOptionMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*DimensionOptionMutation) ClearField

func (m *DimensionOptionMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*DimensionOptionMutation) ClearQuestions

func (m *DimensionOptionMutation) ClearQuestions()

ClearQuestions clears the value of the "questions" field.

func (*DimensionOptionMutation) ClearedEdges

func (m *DimensionOptionMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*DimensionOptionMutation) ClearedFields

func (m *DimensionOptionMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (DimensionOptionMutation) Client

func (m DimensionOptionMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*DimensionOptionMutation) DimensionRowID

func (m *DimensionOptionMutation) DimensionRowID() (r string, exists bool)

DimensionRowID returns the value of the "dimension_row_id" field in the mutation.

func (*DimensionOptionMutation) EdgeCleared

func (m *DimensionOptionMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*DimensionOptionMutation) Field

func (m *DimensionOptionMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*DimensionOptionMutation) FieldCleared

func (m *DimensionOptionMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*DimensionOptionMutation) Fields

func (m *DimensionOptionMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*DimensionOptionMutation) ID

func (m *DimensionOptionMutation) ID() (id string, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*DimensionOptionMutation) IDs

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*DimensionOptionMutation) Label

func (m *DimensionOptionMutation) Label() (r string, exists bool)

Label returns the value of the "label" field in the mutation.

func (*DimensionOptionMutation) OldDimensionRowID

func (m *DimensionOptionMutation) OldDimensionRowID(ctx context.Context) (v string, err error)

OldDimensionRowID returns the old "dimension_row_id" field's value of the DimensionOption entity. If the DimensionOption object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*DimensionOptionMutation) OldField

func (m *DimensionOptionMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*DimensionOptionMutation) OldLabel

func (m *DimensionOptionMutation) OldLabel(ctx context.Context) (v string, err error)

OldLabel returns the old "label" field's value of the DimensionOption entity. If the DimensionOption object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*DimensionOptionMutation) OldOptionID

func (m *DimensionOptionMutation) OldOptionID(ctx context.Context) (v string, err error)

OldOptionID returns the old "option_id" field's value of the DimensionOption entity. If the DimensionOption object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*DimensionOptionMutation) OldQuestions

func (m *DimensionOptionMutation) OldQuestions(ctx context.Context) (v []assessment.DimensionQuestion, err error)

OldQuestions returns the old "questions" field's value of the DimensionOption entity. If the DimensionOption object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*DimensionOptionMutation) OldSequence

func (m *DimensionOptionMutation) OldSequence(ctx context.Context) (v int, err error)

OldSequence returns the old "sequence" field's value of the DimensionOption entity. If the DimensionOption object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*DimensionOptionMutation) Op

func (m *DimensionOptionMutation) Op() Op

Op returns the operation name.

func (*DimensionOptionMutation) OptionID

func (m *DimensionOptionMutation) OptionID() (r string, exists bool)

OptionID returns the value of the "option_id" field in the mutation.

func (*DimensionOptionMutation) Questions

func (m *DimensionOptionMutation) Questions() (r []assessment.DimensionQuestion, exists bool)

Questions returns the value of the "questions" field in the mutation.

func (*DimensionOptionMutation) QuestionsCleared

func (m *DimensionOptionMutation) QuestionsCleared() bool

QuestionsCleared returns if the "questions" field was cleared in this mutation.

func (*DimensionOptionMutation) RemovedEdges

func (m *DimensionOptionMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*DimensionOptionMutation) RemovedIDs

func (m *DimensionOptionMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*DimensionOptionMutation) ResetDimensionRowID

func (m *DimensionOptionMutation) ResetDimensionRowID()

ResetDimensionRowID resets all changes to the "dimension_row_id" field.

func (*DimensionOptionMutation) ResetEdge

func (m *DimensionOptionMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*DimensionOptionMutation) ResetField

func (m *DimensionOptionMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*DimensionOptionMutation) ResetLabel

func (m *DimensionOptionMutation) ResetLabel()

ResetLabel resets all changes to the "label" field.

func (*DimensionOptionMutation) ResetOptionID

func (m *DimensionOptionMutation) ResetOptionID()

ResetOptionID resets all changes to the "option_id" field.

func (*DimensionOptionMutation) ResetQuestions

func (m *DimensionOptionMutation) ResetQuestions()

ResetQuestions resets all changes to the "questions" field.

func (*DimensionOptionMutation) ResetSequence

func (m *DimensionOptionMutation) ResetSequence()

ResetSequence resets all changes to the "sequence" field.

func (*DimensionOptionMutation) Sequence

func (m *DimensionOptionMutation) Sequence() (r int, exists bool)

Sequence returns the value of the "sequence" field in the mutation.

func (*DimensionOptionMutation) SetDimensionRowID

func (m *DimensionOptionMutation) SetDimensionRowID(s string)

SetDimensionRowID sets the "dimension_row_id" field.

func (*DimensionOptionMutation) SetField

func (m *DimensionOptionMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*DimensionOptionMutation) SetID

func (m *DimensionOptionMutation) SetID(id string)

SetID sets the value of the id field. Note that this operation is only accepted on creation of DimensionOption entities.

func (*DimensionOptionMutation) SetLabel

func (m *DimensionOptionMutation) SetLabel(s string)

SetLabel sets the "label" field.

func (*DimensionOptionMutation) SetOp

func (m *DimensionOptionMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*DimensionOptionMutation) SetOptionID

func (m *DimensionOptionMutation) SetOptionID(s string)

SetOptionID sets the "option_id" field.

func (*DimensionOptionMutation) SetQuestions

SetQuestions sets the "questions" field.

func (*DimensionOptionMutation) SetSequence

func (m *DimensionOptionMutation) SetSequence(i int)

SetSequence sets the "sequence" field.

func (DimensionOptionMutation) Tx

func (m DimensionOptionMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*DimensionOptionMutation) Type

func (m *DimensionOptionMutation) Type() string

Type returns the node type of this mutation (DimensionOption).

func (*DimensionOptionMutation) Where

Where appends a list predicates to the DimensionOptionMutation builder.

func (*DimensionOptionMutation) WhereP

func (m *DimensionOptionMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the DimensionOptionMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

type DimensionOptionQuery

type DimensionOptionQuery struct {
	// contains filtered or unexported fields
}

DimensionOptionQuery is the builder for querying DimensionOption entities.

func (*DimensionOptionQuery) Aggregate

Aggregate returns a DimensionOptionSelect configured with the given aggregations.

func (*DimensionOptionQuery) All

All executes the query and returns a list of DimensionOptions.

func (*DimensionOptionQuery) AllX

AllX is like All, but panics if an error occurs.

func (*DimensionOptionQuery) Clone

Clone returns a duplicate of the DimensionOptionQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*DimensionOptionQuery) Count

func (_q *DimensionOptionQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*DimensionOptionQuery) CountX

func (_q *DimensionOptionQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*DimensionOptionQuery) Exist

func (_q *DimensionOptionQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*DimensionOptionQuery) ExistX

func (_q *DimensionOptionQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*DimensionOptionQuery) First

First returns the first DimensionOption entity from the query. Returns a *NotFoundError when no DimensionOption was found.

func (*DimensionOptionQuery) FirstID

func (_q *DimensionOptionQuery) FirstID(ctx context.Context) (id string, err error)

FirstID returns the first DimensionOption ID from the query. Returns a *NotFoundError when no DimensionOption ID was found.

func (*DimensionOptionQuery) FirstIDX

func (_q *DimensionOptionQuery) FirstIDX(ctx context.Context) string

FirstIDX is like FirstID, but panics if an error occurs.

func (*DimensionOptionQuery) FirstX

FirstX is like First, but panics if an error occurs.

func (*DimensionOptionQuery) GroupBy

func (_q *DimensionOptionQuery) GroupBy(field string, fields ...string) *DimensionOptionGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	DimensionRowID string `json:"dimension_row_id,omitempty"`
	Count int `json:"count,omitempty"`
}

client.DimensionOption.Query().
	GroupBy(dimensionoption.FieldDimensionRowID).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*DimensionOptionQuery) IDs

func (_q *DimensionOptionQuery) IDs(ctx context.Context) (ids []string, err error)

IDs executes the query and returns a list of DimensionOption IDs.

func (*DimensionOptionQuery) IDsX

func (_q *DimensionOptionQuery) IDsX(ctx context.Context) []string

IDsX is like IDs, but panics if an error occurs.

func (*DimensionOptionQuery) Limit

func (_q *DimensionOptionQuery) Limit(limit int) *DimensionOptionQuery

Limit the number of records to be returned by this query.

func (*DimensionOptionQuery) Offset

func (_q *DimensionOptionQuery) Offset(offset int) *DimensionOptionQuery

Offset to start from.

func (*DimensionOptionQuery) Only

Only returns a single DimensionOption entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one DimensionOption entity is found. Returns a *NotFoundError when no DimensionOption entities are found.

func (*DimensionOptionQuery) OnlyID

func (_q *DimensionOptionQuery) OnlyID(ctx context.Context) (id string, err error)

OnlyID is like Only, but returns the only DimensionOption ID in the query. Returns a *NotSingularError when more than one DimensionOption ID is found. Returns a *NotFoundError when no entities are found.

func (*DimensionOptionQuery) OnlyIDX

func (_q *DimensionOptionQuery) OnlyIDX(ctx context.Context) string

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*DimensionOptionQuery) OnlyX

OnlyX is like Only, but panics if an error occurs.

func (*DimensionOptionQuery) Order

Order specifies how the records should be ordered.

func (*DimensionOptionQuery) Select

func (_q *DimensionOptionQuery) Select(fields ...string) *DimensionOptionSelect

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	DimensionRowID string `json:"dimension_row_id,omitempty"`
}

client.DimensionOption.Query().
	Select(dimensionoption.FieldDimensionRowID).
	Scan(ctx, &v)

func (*DimensionOptionQuery) Unique

func (_q *DimensionOptionQuery) Unique(unique bool) *DimensionOptionQuery

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*DimensionOptionQuery) Where

Where adds a new predicate for the DimensionOptionQuery builder.

type DimensionOptionSelect

type DimensionOptionSelect struct {
	*DimensionOptionQuery
	// contains filtered or unexported fields
}

DimensionOptionSelect is the builder for selecting fields of DimensionOption entities.

func (*DimensionOptionSelect) Aggregate

Aggregate adds the given aggregation functions to the selector query.

func (*DimensionOptionSelect) Bool

func (s *DimensionOptionSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*DimensionOptionSelect) BoolX

func (s *DimensionOptionSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*DimensionOptionSelect) Bools

func (s *DimensionOptionSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*DimensionOptionSelect) BoolsX

func (s *DimensionOptionSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*DimensionOptionSelect) Float64

func (s *DimensionOptionSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*DimensionOptionSelect) Float64X

func (s *DimensionOptionSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*DimensionOptionSelect) Float64s

func (s *DimensionOptionSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*DimensionOptionSelect) Float64sX

func (s *DimensionOptionSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*DimensionOptionSelect) Int

func (s *DimensionOptionSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*DimensionOptionSelect) IntX

func (s *DimensionOptionSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*DimensionOptionSelect) Ints

func (s *DimensionOptionSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*DimensionOptionSelect) IntsX

func (s *DimensionOptionSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*DimensionOptionSelect) Scan

func (_s *DimensionOptionSelect) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*DimensionOptionSelect) ScanX

func (s *DimensionOptionSelect) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*DimensionOptionSelect) String

func (s *DimensionOptionSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*DimensionOptionSelect) StringX

func (s *DimensionOptionSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*DimensionOptionSelect) Strings

func (s *DimensionOptionSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*DimensionOptionSelect) StringsX

func (s *DimensionOptionSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type DimensionOptionUpdate

type DimensionOptionUpdate struct {
	// contains filtered or unexported fields
}

DimensionOptionUpdate is the builder for updating DimensionOption entities.

func (*DimensionOptionUpdate) AddSequence

func (_u *DimensionOptionUpdate) AddSequence(v int) *DimensionOptionUpdate

AddSequence adds value to the "sequence" field.

func (*DimensionOptionUpdate) AppendQuestions

AppendQuestions appends value to the "questions" field.

func (*DimensionOptionUpdate) ClearQuestions

func (_u *DimensionOptionUpdate) ClearQuestions() *DimensionOptionUpdate

ClearQuestions clears the value of the "questions" field.

func (*DimensionOptionUpdate) Exec

Exec executes the query.

func (*DimensionOptionUpdate) ExecX

func (_u *DimensionOptionUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*DimensionOptionUpdate) Mutation

Mutation returns the DimensionOptionMutation object of the builder.

func (*DimensionOptionUpdate) Save

func (_u *DimensionOptionUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*DimensionOptionUpdate) SaveX

func (_u *DimensionOptionUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*DimensionOptionUpdate) SetDimensionRowID

func (_u *DimensionOptionUpdate) SetDimensionRowID(v string) *DimensionOptionUpdate

SetDimensionRowID sets the "dimension_row_id" field.

func (*DimensionOptionUpdate) SetLabel

SetLabel sets the "label" field.

func (*DimensionOptionUpdate) SetNillableDimensionRowID

func (_u *DimensionOptionUpdate) SetNillableDimensionRowID(v *string) *DimensionOptionUpdate

SetNillableDimensionRowID sets the "dimension_row_id" field if the given value is not nil.

func (*DimensionOptionUpdate) SetNillableLabel

func (_u *DimensionOptionUpdate) SetNillableLabel(v *string) *DimensionOptionUpdate

SetNillableLabel sets the "label" field if the given value is not nil.

func (*DimensionOptionUpdate) SetNillableOptionID

func (_u *DimensionOptionUpdate) SetNillableOptionID(v *string) *DimensionOptionUpdate

SetNillableOptionID sets the "option_id" field if the given value is not nil.

func (*DimensionOptionUpdate) SetNillableSequence

func (_u *DimensionOptionUpdate) SetNillableSequence(v *int) *DimensionOptionUpdate

SetNillableSequence sets the "sequence" field if the given value is not nil.

func (*DimensionOptionUpdate) SetOptionID

SetOptionID sets the "option_id" field.

func (*DimensionOptionUpdate) SetQuestions

SetQuestions sets the "questions" field.

func (*DimensionOptionUpdate) SetSequence

func (_u *DimensionOptionUpdate) SetSequence(v int) *DimensionOptionUpdate

SetSequence sets the "sequence" field.

func (*DimensionOptionUpdate) Where

Where appends a list predicates to the DimensionOptionUpdate builder.

type DimensionOptionUpdateOne

type DimensionOptionUpdateOne struct {
	// contains filtered or unexported fields
}

DimensionOptionUpdateOne is the builder for updating a single DimensionOption entity.

func (*DimensionOptionUpdateOne) AddSequence

AddSequence adds value to the "sequence" field.

func (*DimensionOptionUpdateOne) AppendQuestions

AppendQuestions appends value to the "questions" field.

func (*DimensionOptionUpdateOne) ClearQuestions

func (_u *DimensionOptionUpdateOne) ClearQuestions() *DimensionOptionUpdateOne

ClearQuestions clears the value of the "questions" field.

func (*DimensionOptionUpdateOne) Exec

Exec executes the query on the entity.

func (*DimensionOptionUpdateOne) ExecX

func (_u *DimensionOptionUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*DimensionOptionUpdateOne) Mutation

Mutation returns the DimensionOptionMutation object of the builder.

func (*DimensionOptionUpdateOne) Save

Save executes the query and returns the updated DimensionOption entity.

func (*DimensionOptionUpdateOne) SaveX

SaveX is like Save, but panics if an error occurs.

func (*DimensionOptionUpdateOne) Select

func (_u *DimensionOptionUpdateOne) Select(field string, fields ...string) *DimensionOptionUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*DimensionOptionUpdateOne) SetDimensionRowID

func (_u *DimensionOptionUpdateOne) SetDimensionRowID(v string) *DimensionOptionUpdateOne

SetDimensionRowID sets the "dimension_row_id" field.

func (*DimensionOptionUpdateOne) SetLabel

SetLabel sets the "label" field.

func (*DimensionOptionUpdateOne) SetNillableDimensionRowID

func (_u *DimensionOptionUpdateOne) SetNillableDimensionRowID(v *string) *DimensionOptionUpdateOne

SetNillableDimensionRowID sets the "dimension_row_id" field if the given value is not nil.

func (*DimensionOptionUpdateOne) SetNillableLabel

func (_u *DimensionOptionUpdateOne) SetNillableLabel(v *string) *DimensionOptionUpdateOne

SetNillableLabel sets the "label" field if the given value is not nil.

func (*DimensionOptionUpdateOne) SetNillableOptionID

func (_u *DimensionOptionUpdateOne) SetNillableOptionID(v *string) *DimensionOptionUpdateOne

SetNillableOptionID sets the "option_id" field if the given value is not nil.

func (*DimensionOptionUpdateOne) SetNillableSequence

func (_u *DimensionOptionUpdateOne) SetNillableSequence(v *int) *DimensionOptionUpdateOne

SetNillableSequence sets the "sequence" field if the given value is not nil.

func (*DimensionOptionUpdateOne) SetOptionID

SetOptionID sets the "option_id" field.

func (*DimensionOptionUpdateOne) SetQuestions

SetQuestions sets the "questions" field.

func (*DimensionOptionUpdateOne) SetSequence

SetSequence sets the "sequence" field.

func (*DimensionOptionUpdateOne) Where

Where appends a list predicates to the DimensionOptionUpdate builder.

type DimensionOptionUpsert

type DimensionOptionUpsert struct {
	*sql.UpdateSet
}

DimensionOptionUpsert is the "OnConflict" setter.

func (*DimensionOptionUpsert) AddSequence

func (u *DimensionOptionUpsert) AddSequence(v int) *DimensionOptionUpsert

AddSequence adds v to the "sequence" field.

func (*DimensionOptionUpsert) ClearQuestions

func (u *DimensionOptionUpsert) ClearQuestions() *DimensionOptionUpsert

ClearQuestions clears the value of the "questions" field.

func (*DimensionOptionUpsert) SetDimensionRowID

func (u *DimensionOptionUpsert) SetDimensionRowID(v string) *DimensionOptionUpsert

SetDimensionRowID sets the "dimension_row_id" field.

func (*DimensionOptionUpsert) SetLabel

SetLabel sets the "label" field.

func (*DimensionOptionUpsert) SetOptionID

SetOptionID sets the "option_id" field.

func (*DimensionOptionUpsert) SetQuestions

SetQuestions sets the "questions" field.

func (*DimensionOptionUpsert) SetSequence

func (u *DimensionOptionUpsert) SetSequence(v int) *DimensionOptionUpsert

SetSequence sets the "sequence" field.

func (*DimensionOptionUpsert) UpdateDimensionRowID

func (u *DimensionOptionUpsert) UpdateDimensionRowID() *DimensionOptionUpsert

UpdateDimensionRowID sets the "dimension_row_id" field to the value that was provided on create.

func (*DimensionOptionUpsert) UpdateLabel

func (u *DimensionOptionUpsert) UpdateLabel() *DimensionOptionUpsert

UpdateLabel sets the "label" field to the value that was provided on create.

func (*DimensionOptionUpsert) UpdateOptionID

func (u *DimensionOptionUpsert) UpdateOptionID() *DimensionOptionUpsert

UpdateOptionID sets the "option_id" field to the value that was provided on create.

func (*DimensionOptionUpsert) UpdateQuestions

func (u *DimensionOptionUpsert) UpdateQuestions() *DimensionOptionUpsert

UpdateQuestions sets the "questions" field to the value that was provided on create.

func (*DimensionOptionUpsert) UpdateSequence

func (u *DimensionOptionUpsert) UpdateSequence() *DimensionOptionUpsert

UpdateSequence sets the "sequence" field to the value that was provided on create.

type DimensionOptionUpsertBulk

type DimensionOptionUpsertBulk struct {
	// contains filtered or unexported fields
}

DimensionOptionUpsertBulk is the builder for "upsert"-ing a bulk of DimensionOption nodes.

func (*DimensionOptionUpsertBulk) AddSequence

AddSequence adds v to the "sequence" field.

func (*DimensionOptionUpsertBulk) ClearQuestions

ClearQuestions clears the value of the "questions" field.

func (*DimensionOptionUpsertBulk) DoNothing

DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.

func (*DimensionOptionUpsertBulk) Exec

Exec executes the query.

func (*DimensionOptionUpsertBulk) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*DimensionOptionUpsertBulk) Ignore

Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:

client.DimensionOption.Create().
	OnConflict(sql.ResolveWithIgnore()).
	Exec(ctx)

func (*DimensionOptionUpsertBulk) SetDimensionRowID

SetDimensionRowID sets the "dimension_row_id" field.

func (*DimensionOptionUpsertBulk) SetLabel

SetLabel sets the "label" field.

func (*DimensionOptionUpsertBulk) SetOptionID

SetOptionID sets the "option_id" field.

func (*DimensionOptionUpsertBulk) SetQuestions

SetQuestions sets the "questions" field.

func (*DimensionOptionUpsertBulk) SetSequence

SetSequence sets the "sequence" field.

func (*DimensionOptionUpsertBulk) Update

Update allows overriding fields `UPDATE` values. See the DimensionOptionCreateBulk.OnConflict documentation for more info.

func (*DimensionOptionUpsertBulk) UpdateDimensionRowID

func (u *DimensionOptionUpsertBulk) UpdateDimensionRowID() *DimensionOptionUpsertBulk

UpdateDimensionRowID sets the "dimension_row_id" field to the value that was provided on create.

func (*DimensionOptionUpsertBulk) UpdateLabel

UpdateLabel sets the "label" field to the value that was provided on create.

func (*DimensionOptionUpsertBulk) UpdateNewValues

UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:

client.DimensionOption.Create().
	OnConflict(
		sql.ResolveWithNewValues(),
		sql.ResolveWith(func(u *sql.UpdateSet) {
			u.SetIgnore(dimensionoption.FieldID)
		}),
	).
	Exec(ctx)

func (*DimensionOptionUpsertBulk) UpdateOptionID

UpdateOptionID sets the "option_id" field to the value that was provided on create.

func (*DimensionOptionUpsertBulk) UpdateQuestions

UpdateQuestions sets the "questions" field to the value that was provided on create.

func (*DimensionOptionUpsertBulk) UpdateSequence

UpdateSequence sets the "sequence" field to the value that was provided on create.

type DimensionOptionUpsertOne

type DimensionOptionUpsertOne struct {
	// contains filtered or unexported fields
}

DimensionOptionUpsertOne is the builder for "upsert"-ing

one DimensionOption node.

func (*DimensionOptionUpsertOne) AddSequence

AddSequence adds v to the "sequence" field.

func (*DimensionOptionUpsertOne) ClearQuestions

ClearQuestions clears the value of the "questions" field.

func (*DimensionOptionUpsertOne) DoNothing

DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.

func (*DimensionOptionUpsertOne) Exec

Exec executes the query.

func (*DimensionOptionUpsertOne) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*DimensionOptionUpsertOne) ID

func (u *DimensionOptionUpsertOne) ID(ctx context.Context) (id string, err error)

Exec executes the UPSERT query and returns the inserted/updated ID.

func (*DimensionOptionUpsertOne) IDX

IDX is like ID, but panics if an error occurs.

func (*DimensionOptionUpsertOne) Ignore

Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:

client.DimensionOption.Create().
    OnConflict(sql.ResolveWithIgnore()).
    Exec(ctx)

func (*DimensionOptionUpsertOne) SetDimensionRowID

func (u *DimensionOptionUpsertOne) SetDimensionRowID(v string) *DimensionOptionUpsertOne

SetDimensionRowID sets the "dimension_row_id" field.

func (*DimensionOptionUpsertOne) SetLabel

SetLabel sets the "label" field.

func (*DimensionOptionUpsertOne) SetOptionID

SetOptionID sets the "option_id" field.

func (*DimensionOptionUpsertOne) SetQuestions

SetQuestions sets the "questions" field.

func (*DimensionOptionUpsertOne) SetSequence

SetSequence sets the "sequence" field.

func (*DimensionOptionUpsertOne) Update

Update allows overriding fields `UPDATE` values. See the DimensionOptionCreate.OnConflict documentation for more info.

func (*DimensionOptionUpsertOne) UpdateDimensionRowID

func (u *DimensionOptionUpsertOne) UpdateDimensionRowID() *DimensionOptionUpsertOne

UpdateDimensionRowID sets the "dimension_row_id" field to the value that was provided on create.

func (*DimensionOptionUpsertOne) UpdateLabel

UpdateLabel sets the "label" field to the value that was provided on create.

func (*DimensionOptionUpsertOne) UpdateNewValues

func (u *DimensionOptionUpsertOne) UpdateNewValues() *DimensionOptionUpsertOne

UpdateNewValues updates the mutable fields using the new values that were set on create except the ID field. Using this option is equivalent to using:

client.DimensionOption.Create().
	OnConflict(
		sql.ResolveWithNewValues(),
		sql.ResolveWith(func(u *sql.UpdateSet) {
			u.SetIgnore(dimensionoption.FieldID)
		}),
	).
	Exec(ctx)

func (*DimensionOptionUpsertOne) UpdateOptionID

UpdateOptionID sets the "option_id" field to the value that was provided on create.

func (*DimensionOptionUpsertOne) UpdateQuestions

func (u *DimensionOptionUpsertOne) UpdateQuestions() *DimensionOptionUpsertOne

UpdateQuestions sets the "questions" field to the value that was provided on create.

func (*DimensionOptionUpsertOne) UpdateSequence

UpdateSequence sets the "sequence" field to the value that was provided on create.

type DimensionOptions

type DimensionOptions []*DimensionOption

DimensionOptions is a parsable slice of DimensionOption.

type Evidence

type Evidence struct {

	// ID of the ent.
	ID string `json:"id,omitempty"`
	// System holds the value of the "system" field.
	System string `json:"system,omitempty"`
	// Sensitivity holds the value of the "sensitivity" field.
	Sensitivity string `json:"sensitivity,omitempty"`
	// CapturedBy holds the value of the "captured_by" field.
	CapturedBy string `json:"captured_by,omitempty"`
	// CapturedAt holds the value of the "captured_at" field.
	CapturedAt *time.Time `json:"captured_at,omitempty"`
	// SourceURI holds the value of the "source_uri" field.
	SourceURI string `json:"source_uri,omitempty"`
	// Verified holds the value of the "verified" field.
	Verified bool `json:"verified,omitempty"`
	// Canonical holds the value of the "canonical" field.
	Canonical assessment.Evidence `json:"canonical,omitempty"`
	// CreatedAt holds the value of the "created_at" field.
	CreatedAt time.Time `json:"created_at,omitempty"`
	// UpdatedAt holds the value of the "updated_at" field.
	UpdatedAt time.Time `json:"updated_at,omitempty"`
	// contains filtered or unexported fields
}

Evidence is the model entity for the Evidence schema.

func (*Evidence) String

func (_m *Evidence) String() string

String implements the fmt.Stringer.

func (*Evidence) Unwrap

func (_m *Evidence) Unwrap() *Evidence

Unwrap unwraps the Evidence entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*Evidence) Update

func (_m *Evidence) Update() *EvidenceUpdateOne

Update returns a builder for updating this Evidence. Note that you need to call Evidence.Unwrap() before calling this method if this Evidence was returned from a transaction, and the transaction was committed or rolled back.

func (*Evidence) Value

func (_m *Evidence) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the Evidence. This includes values selected through modifiers, order, etc.

type EvidenceClient

type EvidenceClient struct {
	// contains filtered or unexported fields
}

EvidenceClient is a client for the Evidence schema.

func NewEvidenceClient

func NewEvidenceClient(c config) *EvidenceClient

NewEvidenceClient returns a client for the Evidence from the given config.

func (*EvidenceClient) Create

func (c *EvidenceClient) Create() *EvidenceCreate

Create returns a builder for creating a Evidence entity.

func (*EvidenceClient) CreateBulk

func (c *EvidenceClient) CreateBulk(builders ...*EvidenceCreate) *EvidenceCreateBulk

CreateBulk returns a builder for creating a bulk of Evidence entities.

func (*EvidenceClient) Delete

func (c *EvidenceClient) Delete() *EvidenceDelete

Delete returns a delete builder for Evidence.

func (*EvidenceClient) DeleteOne

func (c *EvidenceClient) DeleteOne(_m *Evidence) *EvidenceDeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*EvidenceClient) DeleteOneID

func (c *EvidenceClient) DeleteOneID(id string) *EvidenceDeleteOne

DeleteOneID returns a builder for deleting the given entity by its id.

func (*EvidenceClient) Get

func (c *EvidenceClient) Get(ctx context.Context, id string) (*Evidence, error)

Get returns a Evidence entity by its id.

func (*EvidenceClient) GetX

func (c *EvidenceClient) GetX(ctx context.Context, id string) *Evidence

GetX is like Get, but panics if an error occurs.

func (*EvidenceClient) Hooks

func (c *EvidenceClient) Hooks() []Hook

Hooks returns the client hooks.

func (*EvidenceClient) Intercept

func (c *EvidenceClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `evidence.Intercept(f(g(h())))`.

func (*EvidenceClient) Interceptors

func (c *EvidenceClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*EvidenceClient) MapCreateBulk

func (c *EvidenceClient) MapCreateBulk(slice any, setFunc func(*EvidenceCreate, int)) *EvidenceCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*EvidenceClient) Query

func (c *EvidenceClient) Query() *EvidenceQuery

Query returns a query builder for Evidence.

func (*EvidenceClient) Update

func (c *EvidenceClient) Update() *EvidenceUpdate

Update returns an update builder for Evidence.

func (*EvidenceClient) UpdateOne

func (c *EvidenceClient) UpdateOne(_m *Evidence) *EvidenceUpdateOne

UpdateOne returns an update builder for the given entity.

func (*EvidenceClient) UpdateOneID

func (c *EvidenceClient) UpdateOneID(id string) *EvidenceUpdateOne

UpdateOneID returns an update builder for the given id.

func (*EvidenceClient) Use

func (c *EvidenceClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `evidence.Hooks(f(g(h())))`.

type EvidenceCreate

type EvidenceCreate struct {
	// contains filtered or unexported fields
}

EvidenceCreate is the builder for creating a Evidence entity.

func (*EvidenceCreate) Exec

func (_c *EvidenceCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*EvidenceCreate) ExecX

func (_c *EvidenceCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*EvidenceCreate) Mutation

func (_c *EvidenceCreate) Mutation() *EvidenceMutation

Mutation returns the EvidenceMutation object of the builder.

func (*EvidenceCreate) OnConflict

func (_c *EvidenceCreate) OnConflict(opts ...sql.ConflictOption) *EvidenceUpsertOne

OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:

client.Evidence.Create().
	SetSystem(v).
	OnConflict(
		// Update the row with the new values
		// the was proposed for insertion.
		sql.ResolveWithNewValues(),
	).
	// Override some of the fields with custom
	// update values.
	Update(func(u *ent.EvidenceUpsert) {
		SetSystem(v+v).
	}).
	Exec(ctx)

func (*EvidenceCreate) OnConflictColumns

func (_c *EvidenceCreate) OnConflictColumns(columns ...string) *EvidenceUpsertOne

OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:

client.Evidence.Create().
	OnConflict(sql.ConflictColumns(columns...)).
	Exec(ctx)

func (*EvidenceCreate) Save

func (_c *EvidenceCreate) Save(ctx context.Context) (*Evidence, error)

Save creates the Evidence in the database.

func (*EvidenceCreate) SaveX

func (_c *EvidenceCreate) SaveX(ctx context.Context) *Evidence

SaveX calls Save and panics if Save returns an error.

func (*EvidenceCreate) SetCanonical

func (_c *EvidenceCreate) SetCanonical(v assessment.Evidence) *EvidenceCreate

SetCanonical sets the "canonical" field.

func (*EvidenceCreate) SetCapturedAt

func (_c *EvidenceCreate) SetCapturedAt(v time.Time) *EvidenceCreate

SetCapturedAt sets the "captured_at" field.

func (*EvidenceCreate) SetCapturedBy

func (_c *EvidenceCreate) SetCapturedBy(v string) *EvidenceCreate

SetCapturedBy sets the "captured_by" field.

func (*EvidenceCreate) SetCreatedAt

func (_c *EvidenceCreate) SetCreatedAt(v time.Time) *EvidenceCreate

SetCreatedAt sets the "created_at" field.

func (*EvidenceCreate) SetID

func (_c *EvidenceCreate) SetID(v string) *EvidenceCreate

SetID sets the "id" field.

func (*EvidenceCreate) SetNillableCapturedAt

func (_c *EvidenceCreate) SetNillableCapturedAt(v *time.Time) *EvidenceCreate

SetNillableCapturedAt sets the "captured_at" field if the given value is not nil.

func (*EvidenceCreate) SetNillableCapturedBy

func (_c *EvidenceCreate) SetNillableCapturedBy(v *string) *EvidenceCreate

SetNillableCapturedBy sets the "captured_by" field if the given value is not nil.

func (*EvidenceCreate) SetNillableCreatedAt

func (_c *EvidenceCreate) SetNillableCreatedAt(v *time.Time) *EvidenceCreate

SetNillableCreatedAt sets the "created_at" field if the given value is not nil.

func (*EvidenceCreate) SetNillableSensitivity

func (_c *EvidenceCreate) SetNillableSensitivity(v *string) *EvidenceCreate

SetNillableSensitivity sets the "sensitivity" field if the given value is not nil.

func (*EvidenceCreate) SetNillableSourceURI

func (_c *EvidenceCreate) SetNillableSourceURI(v *string) *EvidenceCreate

SetNillableSourceURI sets the "source_uri" field if the given value is not nil.

func (*EvidenceCreate) SetNillableSystem

func (_c *EvidenceCreate) SetNillableSystem(v *string) *EvidenceCreate

SetNillableSystem sets the "system" field if the given value is not nil.

func (*EvidenceCreate) SetNillableUpdatedAt

func (_c *EvidenceCreate) SetNillableUpdatedAt(v *time.Time) *EvidenceCreate

SetNillableUpdatedAt sets the "updated_at" field if the given value is not nil.

func (*EvidenceCreate) SetNillableVerified

func (_c *EvidenceCreate) SetNillableVerified(v *bool) *EvidenceCreate

SetNillableVerified sets the "verified" field if the given value is not nil.

func (*EvidenceCreate) SetSensitivity

func (_c *EvidenceCreate) SetSensitivity(v string) *EvidenceCreate

SetSensitivity sets the "sensitivity" field.

func (*EvidenceCreate) SetSourceURI

func (_c *EvidenceCreate) SetSourceURI(v string) *EvidenceCreate

SetSourceURI sets the "source_uri" field.

func (*EvidenceCreate) SetSystem

func (_c *EvidenceCreate) SetSystem(v string) *EvidenceCreate

SetSystem sets the "system" field.

func (*EvidenceCreate) SetUpdatedAt

func (_c *EvidenceCreate) SetUpdatedAt(v time.Time) *EvidenceCreate

SetUpdatedAt sets the "updated_at" field.

func (*EvidenceCreate) SetVerified

func (_c *EvidenceCreate) SetVerified(v bool) *EvidenceCreate

SetVerified sets the "verified" field.

type EvidenceCreateBulk

type EvidenceCreateBulk struct {
	// contains filtered or unexported fields
}

EvidenceCreateBulk is the builder for creating many Evidence entities in bulk.

func (*EvidenceCreateBulk) Exec

func (_c *EvidenceCreateBulk) Exec(ctx context.Context) error

Exec executes the query.

func (*EvidenceCreateBulk) ExecX

func (_c *EvidenceCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*EvidenceCreateBulk) OnConflict

func (_c *EvidenceCreateBulk) OnConflict(opts ...sql.ConflictOption) *EvidenceUpsertBulk

OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:

client.Evidence.CreateBulk(builders...).
	OnConflict(
		// Update the row with the new values
		// the was proposed for insertion.
		sql.ResolveWithNewValues(),
	).
	// Override some of the fields with custom
	// update values.
	Update(func(u *ent.EvidenceUpsert) {
		SetSystem(v+v).
	}).
	Exec(ctx)

func (*EvidenceCreateBulk) OnConflictColumns

func (_c *EvidenceCreateBulk) OnConflictColumns(columns ...string) *EvidenceUpsertBulk

OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:

client.Evidence.Create().
	OnConflict(sql.ConflictColumns(columns...)).
	Exec(ctx)

func (*EvidenceCreateBulk) Save

func (_c *EvidenceCreateBulk) Save(ctx context.Context) ([]*Evidence, error)

Save creates the Evidence entities in the database.

func (*EvidenceCreateBulk) SaveX

func (_c *EvidenceCreateBulk) SaveX(ctx context.Context) []*Evidence

SaveX is like Save, but panics if an error occurs.

type EvidenceDelete

type EvidenceDelete struct {
	// contains filtered or unexported fields
}

EvidenceDelete is the builder for deleting a Evidence entity.

func (*EvidenceDelete) Exec

func (_d *EvidenceDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*EvidenceDelete) ExecX

func (_d *EvidenceDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*EvidenceDelete) Where

func (_d *EvidenceDelete) Where(ps ...predicate.Evidence) *EvidenceDelete

Where appends a list predicates to the EvidenceDelete builder.

type EvidenceDeleteOne

type EvidenceDeleteOne struct {
	// contains filtered or unexported fields
}

EvidenceDeleteOne is the builder for deleting a single Evidence entity.

func (*EvidenceDeleteOne) Exec

func (_d *EvidenceDeleteOne) Exec(ctx context.Context) error

Exec executes the deletion query.

func (*EvidenceDeleteOne) ExecX

func (_d *EvidenceDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*EvidenceDeleteOne) Where

Where appends a list predicates to the EvidenceDelete builder.

type EvidenceGroupBy

type EvidenceGroupBy struct {
	// contains filtered or unexported fields
}

EvidenceGroupBy is the group-by builder for Evidence entities.

func (*EvidenceGroupBy) Aggregate

func (_g *EvidenceGroupBy) Aggregate(fns ...AggregateFunc) *EvidenceGroupBy

Aggregate adds the given aggregation functions to the group-by query.

func (*EvidenceGroupBy) Bool

func (s *EvidenceGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*EvidenceGroupBy) BoolX

func (s *EvidenceGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*EvidenceGroupBy) Bools

func (s *EvidenceGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*EvidenceGroupBy) BoolsX

func (s *EvidenceGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*EvidenceGroupBy) Float64

func (s *EvidenceGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*EvidenceGroupBy) Float64X

func (s *EvidenceGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*EvidenceGroupBy) Float64s

func (s *EvidenceGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*EvidenceGroupBy) Float64sX

func (s *EvidenceGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*EvidenceGroupBy) Int

func (s *EvidenceGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*EvidenceGroupBy) IntX

func (s *EvidenceGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*EvidenceGroupBy) Ints

func (s *EvidenceGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*EvidenceGroupBy) IntsX

func (s *EvidenceGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*EvidenceGroupBy) Scan

func (_g *EvidenceGroupBy) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*EvidenceGroupBy) ScanX

func (s *EvidenceGroupBy) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*EvidenceGroupBy) String

func (s *EvidenceGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*EvidenceGroupBy) StringX

func (s *EvidenceGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*EvidenceGroupBy) Strings

func (s *EvidenceGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*EvidenceGroupBy) StringsX

func (s *EvidenceGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type EvidenceMutation

type EvidenceMutation struct {
	// contains filtered or unexported fields
}

EvidenceMutation represents an operation that mutates the Evidence nodes in the graph.

func (*EvidenceMutation) AddField

func (m *EvidenceMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*EvidenceMutation) AddedEdges

func (m *EvidenceMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*EvidenceMutation) AddedField

func (m *EvidenceMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*EvidenceMutation) AddedFields

func (m *EvidenceMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*EvidenceMutation) AddedIDs

func (m *EvidenceMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*EvidenceMutation) Canonical

func (m *EvidenceMutation) Canonical() (r assessment.Evidence, exists bool)

Canonical returns the value of the "canonical" field in the mutation.

func (*EvidenceMutation) CapturedAt

func (m *EvidenceMutation) CapturedAt() (r time.Time, exists bool)

CapturedAt returns the value of the "captured_at" field in the mutation.

func (*EvidenceMutation) CapturedAtCleared

func (m *EvidenceMutation) CapturedAtCleared() bool

CapturedAtCleared returns if the "captured_at" field was cleared in this mutation.

func (*EvidenceMutation) CapturedBy

func (m *EvidenceMutation) CapturedBy() (r string, exists bool)

CapturedBy returns the value of the "captured_by" field in the mutation.

func (*EvidenceMutation) CapturedByCleared

func (m *EvidenceMutation) CapturedByCleared() bool

CapturedByCleared returns if the "captured_by" field was cleared in this mutation.

func (*EvidenceMutation) ClearCapturedAt

func (m *EvidenceMutation) ClearCapturedAt()

ClearCapturedAt clears the value of the "captured_at" field.

func (*EvidenceMutation) ClearCapturedBy

func (m *EvidenceMutation) ClearCapturedBy()

ClearCapturedBy clears the value of the "captured_by" field.

func (*EvidenceMutation) ClearEdge

func (m *EvidenceMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*EvidenceMutation) ClearField

func (m *EvidenceMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*EvidenceMutation) ClearSensitivity

func (m *EvidenceMutation) ClearSensitivity()

ClearSensitivity clears the value of the "sensitivity" field.

func (*EvidenceMutation) ClearSourceURI

func (m *EvidenceMutation) ClearSourceURI()

ClearSourceURI clears the value of the "source_uri" field.

func (*EvidenceMutation) ClearSystem

func (m *EvidenceMutation) ClearSystem()

ClearSystem clears the value of the "system" field.

func (*EvidenceMutation) ClearedEdges

func (m *EvidenceMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*EvidenceMutation) ClearedFields

func (m *EvidenceMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (EvidenceMutation) Client

func (m EvidenceMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*EvidenceMutation) CreatedAt

func (m *EvidenceMutation) CreatedAt() (r time.Time, exists bool)

CreatedAt returns the value of the "created_at" field in the mutation.

func (*EvidenceMutation) EdgeCleared

func (m *EvidenceMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*EvidenceMutation) Field

func (m *EvidenceMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*EvidenceMutation) FieldCleared

func (m *EvidenceMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*EvidenceMutation) Fields

func (m *EvidenceMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*EvidenceMutation) ID

func (m *EvidenceMutation) ID() (id string, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*EvidenceMutation) IDs

func (m *EvidenceMutation) IDs(ctx context.Context) ([]string, error)

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*EvidenceMutation) OldCanonical

func (m *EvidenceMutation) OldCanonical(ctx context.Context) (v assessment.Evidence, err error)

OldCanonical returns the old "canonical" field's value of the Evidence entity. If the Evidence object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*EvidenceMutation) OldCapturedAt

func (m *EvidenceMutation) OldCapturedAt(ctx context.Context) (v *time.Time, err error)

OldCapturedAt returns the old "captured_at" field's value of the Evidence entity. If the Evidence object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*EvidenceMutation) OldCapturedBy

func (m *EvidenceMutation) OldCapturedBy(ctx context.Context) (v string, err error)

OldCapturedBy returns the old "captured_by" field's value of the Evidence entity. If the Evidence object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*EvidenceMutation) OldCreatedAt

func (m *EvidenceMutation) OldCreatedAt(ctx context.Context) (v time.Time, err error)

OldCreatedAt returns the old "created_at" field's value of the Evidence entity. If the Evidence object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*EvidenceMutation) OldField

func (m *EvidenceMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*EvidenceMutation) OldSensitivity

func (m *EvidenceMutation) OldSensitivity(ctx context.Context) (v string, err error)

OldSensitivity returns the old "sensitivity" field's value of the Evidence entity. If the Evidence object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*EvidenceMutation) OldSourceURI

func (m *EvidenceMutation) OldSourceURI(ctx context.Context) (v string, err error)

OldSourceURI returns the old "source_uri" field's value of the Evidence entity. If the Evidence object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*EvidenceMutation) OldSystem

func (m *EvidenceMutation) OldSystem(ctx context.Context) (v string, err error)

OldSystem returns the old "system" field's value of the Evidence entity. If the Evidence object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*EvidenceMutation) OldUpdatedAt

func (m *EvidenceMutation) OldUpdatedAt(ctx context.Context) (v time.Time, err error)

OldUpdatedAt returns the old "updated_at" field's value of the Evidence entity. If the Evidence object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*EvidenceMutation) OldVerified

func (m *EvidenceMutation) OldVerified(ctx context.Context) (v bool, err error)

OldVerified returns the old "verified" field's value of the Evidence entity. If the Evidence object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*EvidenceMutation) Op

func (m *EvidenceMutation) Op() Op

Op returns the operation name.

func (*EvidenceMutation) RemovedEdges

func (m *EvidenceMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*EvidenceMutation) RemovedIDs

func (m *EvidenceMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*EvidenceMutation) ResetCanonical

func (m *EvidenceMutation) ResetCanonical()

ResetCanonical resets all changes to the "canonical" field.

func (*EvidenceMutation) ResetCapturedAt

func (m *EvidenceMutation) ResetCapturedAt()

ResetCapturedAt resets all changes to the "captured_at" field.

func (*EvidenceMutation) ResetCapturedBy

func (m *EvidenceMutation) ResetCapturedBy()

ResetCapturedBy resets all changes to the "captured_by" field.

func (*EvidenceMutation) ResetCreatedAt

func (m *EvidenceMutation) ResetCreatedAt()

ResetCreatedAt resets all changes to the "created_at" field.

func (*EvidenceMutation) ResetEdge

func (m *EvidenceMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*EvidenceMutation) ResetField

func (m *EvidenceMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*EvidenceMutation) ResetSensitivity

func (m *EvidenceMutation) ResetSensitivity()

ResetSensitivity resets all changes to the "sensitivity" field.

func (*EvidenceMutation) ResetSourceURI

func (m *EvidenceMutation) ResetSourceURI()

ResetSourceURI resets all changes to the "source_uri" field.

func (*EvidenceMutation) ResetSystem

func (m *EvidenceMutation) ResetSystem()

ResetSystem resets all changes to the "system" field.

func (*EvidenceMutation) ResetUpdatedAt

func (m *EvidenceMutation) ResetUpdatedAt()

ResetUpdatedAt resets all changes to the "updated_at" field.

func (*EvidenceMutation) ResetVerified

func (m *EvidenceMutation) ResetVerified()

ResetVerified resets all changes to the "verified" field.

func (*EvidenceMutation) Sensitivity

func (m *EvidenceMutation) Sensitivity() (r string, exists bool)

Sensitivity returns the value of the "sensitivity" field in the mutation.

func (*EvidenceMutation) SensitivityCleared

func (m *EvidenceMutation) SensitivityCleared() bool

SensitivityCleared returns if the "sensitivity" field was cleared in this mutation.

func (*EvidenceMutation) SetCanonical

func (m *EvidenceMutation) SetCanonical(a assessment.Evidence)

SetCanonical sets the "canonical" field.

func (*EvidenceMutation) SetCapturedAt

func (m *EvidenceMutation) SetCapturedAt(t time.Time)

SetCapturedAt sets the "captured_at" field.

func (*EvidenceMutation) SetCapturedBy

func (m *EvidenceMutation) SetCapturedBy(s string)

SetCapturedBy sets the "captured_by" field.

func (*EvidenceMutation) SetCreatedAt

func (m *EvidenceMutation) SetCreatedAt(t time.Time)

SetCreatedAt sets the "created_at" field.

func (*EvidenceMutation) SetField

func (m *EvidenceMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*EvidenceMutation) SetID

func (m *EvidenceMutation) SetID(id string)

SetID sets the value of the id field. Note that this operation is only accepted on creation of Evidence entities.

func (*EvidenceMutation) SetOp

func (m *EvidenceMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*EvidenceMutation) SetSensitivity

func (m *EvidenceMutation) SetSensitivity(s string)

SetSensitivity sets the "sensitivity" field.

func (*EvidenceMutation) SetSourceURI

func (m *EvidenceMutation) SetSourceURI(s string)

SetSourceURI sets the "source_uri" field.

func (*EvidenceMutation) SetSystem

func (m *EvidenceMutation) SetSystem(s string)

SetSystem sets the "system" field.

func (*EvidenceMutation) SetUpdatedAt

func (m *EvidenceMutation) SetUpdatedAt(t time.Time)

SetUpdatedAt sets the "updated_at" field.

func (*EvidenceMutation) SetVerified

func (m *EvidenceMutation) SetVerified(b bool)

SetVerified sets the "verified" field.

func (*EvidenceMutation) SourceURI

func (m *EvidenceMutation) SourceURI() (r string, exists bool)

SourceURI returns the value of the "source_uri" field in the mutation.

func (*EvidenceMutation) SourceURICleared

func (m *EvidenceMutation) SourceURICleared() bool

SourceURICleared returns if the "source_uri" field was cleared in this mutation.

func (*EvidenceMutation) System

func (m *EvidenceMutation) System() (r string, exists bool)

System returns the value of the "system" field in the mutation.

func (*EvidenceMutation) SystemCleared

func (m *EvidenceMutation) SystemCleared() bool

SystemCleared returns if the "system" field was cleared in this mutation.

func (EvidenceMutation) Tx

func (m EvidenceMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*EvidenceMutation) Type

func (m *EvidenceMutation) Type() string

Type returns the node type of this mutation (Evidence).

func (*EvidenceMutation) UpdatedAt

func (m *EvidenceMutation) UpdatedAt() (r time.Time, exists bool)

UpdatedAt returns the value of the "updated_at" field in the mutation.

func (*EvidenceMutation) Verified

func (m *EvidenceMutation) Verified() (r bool, exists bool)

Verified returns the value of the "verified" field in the mutation.

func (*EvidenceMutation) Where

func (m *EvidenceMutation) Where(ps ...predicate.Evidence)

Where appends a list predicates to the EvidenceMutation builder.

func (*EvidenceMutation) WhereP

func (m *EvidenceMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the EvidenceMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

type EvidenceQuery

type EvidenceQuery struct {
	// contains filtered or unexported fields
}

EvidenceQuery is the builder for querying Evidence entities.

func (*EvidenceQuery) Aggregate

func (_q *EvidenceQuery) Aggregate(fns ...AggregateFunc) *EvidenceSelect

Aggregate returns a EvidenceSelect configured with the given aggregations.

func (*EvidenceQuery) All

func (_q *EvidenceQuery) All(ctx context.Context) ([]*Evidence, error)

All executes the query and returns a list of Evidences.

func (*EvidenceQuery) AllX

func (_q *EvidenceQuery) AllX(ctx context.Context) []*Evidence

AllX is like All, but panics if an error occurs.

func (*EvidenceQuery) Clone

func (_q *EvidenceQuery) Clone() *EvidenceQuery

Clone returns a duplicate of the EvidenceQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*EvidenceQuery) Count

func (_q *EvidenceQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*EvidenceQuery) CountX

func (_q *EvidenceQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*EvidenceQuery) Exist

func (_q *EvidenceQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*EvidenceQuery) ExistX

func (_q *EvidenceQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*EvidenceQuery) First

func (_q *EvidenceQuery) First(ctx context.Context) (*Evidence, error)

First returns the first Evidence entity from the query. Returns a *NotFoundError when no Evidence was found.

func (*EvidenceQuery) FirstID

func (_q *EvidenceQuery) FirstID(ctx context.Context) (id string, err error)

FirstID returns the first Evidence ID from the query. Returns a *NotFoundError when no Evidence ID was found.

func (*EvidenceQuery) FirstIDX

func (_q *EvidenceQuery) FirstIDX(ctx context.Context) string

FirstIDX is like FirstID, but panics if an error occurs.

func (*EvidenceQuery) FirstX

func (_q *EvidenceQuery) FirstX(ctx context.Context) *Evidence

FirstX is like First, but panics if an error occurs.

func (*EvidenceQuery) GroupBy

func (_q *EvidenceQuery) GroupBy(field string, fields ...string) *EvidenceGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	System string `json:"system,omitempty"`
	Count int `json:"count,omitempty"`
}

client.Evidence.Query().
	GroupBy(evidence.FieldSystem).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*EvidenceQuery) IDs

func (_q *EvidenceQuery) IDs(ctx context.Context) (ids []string, err error)

IDs executes the query and returns a list of Evidence IDs.

func (*EvidenceQuery) IDsX

func (_q *EvidenceQuery) IDsX(ctx context.Context) []string

IDsX is like IDs, but panics if an error occurs.

func (*EvidenceQuery) Limit

func (_q *EvidenceQuery) Limit(limit int) *EvidenceQuery

Limit the number of records to be returned by this query.

func (*EvidenceQuery) Offset

func (_q *EvidenceQuery) Offset(offset int) *EvidenceQuery

Offset to start from.

func (*EvidenceQuery) Only

func (_q *EvidenceQuery) Only(ctx context.Context) (*Evidence, error)

Only returns a single Evidence entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one Evidence entity is found. Returns a *NotFoundError when no Evidence entities are found.

func (*EvidenceQuery) OnlyID

func (_q *EvidenceQuery) OnlyID(ctx context.Context) (id string, err error)

OnlyID is like Only, but returns the only Evidence ID in the query. Returns a *NotSingularError when more than one Evidence ID is found. Returns a *NotFoundError when no entities are found.

func (*EvidenceQuery) OnlyIDX

func (_q *EvidenceQuery) OnlyIDX(ctx context.Context) string

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*EvidenceQuery) OnlyX

func (_q *EvidenceQuery) OnlyX(ctx context.Context) *Evidence

OnlyX is like Only, but panics if an error occurs.

func (*EvidenceQuery) Order

Order specifies how the records should be ordered.

func (*EvidenceQuery) Select

func (_q *EvidenceQuery) Select(fields ...string) *EvidenceSelect

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	System string `json:"system,omitempty"`
}

client.Evidence.Query().
	Select(evidence.FieldSystem).
	Scan(ctx, &v)

func (*EvidenceQuery) Unique

func (_q *EvidenceQuery) Unique(unique bool) *EvidenceQuery

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*EvidenceQuery) Where

func (_q *EvidenceQuery) Where(ps ...predicate.Evidence) *EvidenceQuery

Where adds a new predicate for the EvidenceQuery builder.

type EvidenceSelect

type EvidenceSelect struct {
	*EvidenceQuery
	// contains filtered or unexported fields
}

EvidenceSelect is the builder for selecting fields of Evidence entities.

func (*EvidenceSelect) Aggregate

func (_s *EvidenceSelect) Aggregate(fns ...AggregateFunc) *EvidenceSelect

Aggregate adds the given aggregation functions to the selector query.

func (*EvidenceSelect) Bool

func (s *EvidenceSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*EvidenceSelect) BoolX

func (s *EvidenceSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*EvidenceSelect) Bools

func (s *EvidenceSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*EvidenceSelect) BoolsX

func (s *EvidenceSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*EvidenceSelect) Float64

func (s *EvidenceSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*EvidenceSelect) Float64X

func (s *EvidenceSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*EvidenceSelect) Float64s

func (s *EvidenceSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*EvidenceSelect) Float64sX

func (s *EvidenceSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*EvidenceSelect) Int

func (s *EvidenceSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*EvidenceSelect) IntX

func (s *EvidenceSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*EvidenceSelect) Ints

func (s *EvidenceSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*EvidenceSelect) IntsX

func (s *EvidenceSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*EvidenceSelect) Scan

func (_s *EvidenceSelect) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*EvidenceSelect) ScanX

func (s *EvidenceSelect) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*EvidenceSelect) String

func (s *EvidenceSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*EvidenceSelect) StringX

func (s *EvidenceSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*EvidenceSelect) Strings

func (s *EvidenceSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*EvidenceSelect) StringsX

func (s *EvidenceSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type EvidenceUpdate

type EvidenceUpdate struct {
	// contains filtered or unexported fields
}

EvidenceUpdate is the builder for updating Evidence entities.

func (*EvidenceUpdate) ClearCapturedAt

func (_u *EvidenceUpdate) ClearCapturedAt() *EvidenceUpdate

ClearCapturedAt clears the value of the "captured_at" field.

func (*EvidenceUpdate) ClearCapturedBy

func (_u *EvidenceUpdate) ClearCapturedBy() *EvidenceUpdate

ClearCapturedBy clears the value of the "captured_by" field.

func (*EvidenceUpdate) ClearSensitivity

func (_u *EvidenceUpdate) ClearSensitivity() *EvidenceUpdate

ClearSensitivity clears the value of the "sensitivity" field.

func (*EvidenceUpdate) ClearSourceURI

func (_u *EvidenceUpdate) ClearSourceURI() *EvidenceUpdate

ClearSourceURI clears the value of the "source_uri" field.

func (*EvidenceUpdate) ClearSystem

func (_u *EvidenceUpdate) ClearSystem() *EvidenceUpdate

ClearSystem clears the value of the "system" field.

func (*EvidenceUpdate) Exec

func (_u *EvidenceUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*EvidenceUpdate) ExecX

func (_u *EvidenceUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*EvidenceUpdate) Mutation

func (_u *EvidenceUpdate) Mutation() *EvidenceMutation

Mutation returns the EvidenceMutation object of the builder.

func (*EvidenceUpdate) Save

func (_u *EvidenceUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*EvidenceUpdate) SaveX

func (_u *EvidenceUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*EvidenceUpdate) SetCanonical

func (_u *EvidenceUpdate) SetCanonical(v assessment.Evidence) *EvidenceUpdate

SetCanonical sets the "canonical" field.

func (*EvidenceUpdate) SetCapturedAt

func (_u *EvidenceUpdate) SetCapturedAt(v time.Time) *EvidenceUpdate

SetCapturedAt sets the "captured_at" field.

func (*EvidenceUpdate) SetCapturedBy

func (_u *EvidenceUpdate) SetCapturedBy(v string) *EvidenceUpdate

SetCapturedBy sets the "captured_by" field.

func (*EvidenceUpdate) SetNillableCanonical

func (_u *EvidenceUpdate) SetNillableCanonical(v *assessment.Evidence) *EvidenceUpdate

SetNillableCanonical sets the "canonical" field if the given value is not nil.

func (*EvidenceUpdate) SetNillableCapturedAt

func (_u *EvidenceUpdate) SetNillableCapturedAt(v *time.Time) *EvidenceUpdate

SetNillableCapturedAt sets the "captured_at" field if the given value is not nil.

func (*EvidenceUpdate) SetNillableCapturedBy

func (_u *EvidenceUpdate) SetNillableCapturedBy(v *string) *EvidenceUpdate

SetNillableCapturedBy sets the "captured_by" field if the given value is not nil.

func (*EvidenceUpdate) SetNillableSensitivity

func (_u *EvidenceUpdate) SetNillableSensitivity(v *string) *EvidenceUpdate

SetNillableSensitivity sets the "sensitivity" field if the given value is not nil.

func (*EvidenceUpdate) SetNillableSourceURI

func (_u *EvidenceUpdate) SetNillableSourceURI(v *string) *EvidenceUpdate

SetNillableSourceURI sets the "source_uri" field if the given value is not nil.

func (*EvidenceUpdate) SetNillableSystem

func (_u *EvidenceUpdate) SetNillableSystem(v *string) *EvidenceUpdate

SetNillableSystem sets the "system" field if the given value is not nil.

func (*EvidenceUpdate) SetNillableVerified

func (_u *EvidenceUpdate) SetNillableVerified(v *bool) *EvidenceUpdate

SetNillableVerified sets the "verified" field if the given value is not nil.

func (*EvidenceUpdate) SetSensitivity

func (_u *EvidenceUpdate) SetSensitivity(v string) *EvidenceUpdate

SetSensitivity sets the "sensitivity" field.

func (*EvidenceUpdate) SetSourceURI

func (_u *EvidenceUpdate) SetSourceURI(v string) *EvidenceUpdate

SetSourceURI sets the "source_uri" field.

func (*EvidenceUpdate) SetSystem

func (_u *EvidenceUpdate) SetSystem(v string) *EvidenceUpdate

SetSystem sets the "system" field.

func (*EvidenceUpdate) SetUpdatedAt

func (_u *EvidenceUpdate) SetUpdatedAt(v time.Time) *EvidenceUpdate

SetUpdatedAt sets the "updated_at" field.

func (*EvidenceUpdate) SetVerified

func (_u *EvidenceUpdate) SetVerified(v bool) *EvidenceUpdate

SetVerified sets the "verified" field.

func (*EvidenceUpdate) Where

func (_u *EvidenceUpdate) Where(ps ...predicate.Evidence) *EvidenceUpdate

Where appends a list predicates to the EvidenceUpdate builder.

type EvidenceUpdateOne

type EvidenceUpdateOne struct {
	// contains filtered or unexported fields
}

EvidenceUpdateOne is the builder for updating a single Evidence entity.

func (*EvidenceUpdateOne) ClearCapturedAt

func (_u *EvidenceUpdateOne) ClearCapturedAt() *EvidenceUpdateOne

ClearCapturedAt clears the value of the "captured_at" field.

func (*EvidenceUpdateOne) ClearCapturedBy

func (_u *EvidenceUpdateOne) ClearCapturedBy() *EvidenceUpdateOne

ClearCapturedBy clears the value of the "captured_by" field.

func (*EvidenceUpdateOne) ClearSensitivity

func (_u *EvidenceUpdateOne) ClearSensitivity() *EvidenceUpdateOne

ClearSensitivity clears the value of the "sensitivity" field.

func (*EvidenceUpdateOne) ClearSourceURI

func (_u *EvidenceUpdateOne) ClearSourceURI() *EvidenceUpdateOne

ClearSourceURI clears the value of the "source_uri" field.

func (*EvidenceUpdateOne) ClearSystem

func (_u *EvidenceUpdateOne) ClearSystem() *EvidenceUpdateOne

ClearSystem clears the value of the "system" field.

func (*EvidenceUpdateOne) Exec

func (_u *EvidenceUpdateOne) Exec(ctx context.Context) error

Exec executes the query on the entity.

func (*EvidenceUpdateOne) ExecX

func (_u *EvidenceUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*EvidenceUpdateOne) Mutation

func (_u *EvidenceUpdateOne) Mutation() *EvidenceMutation

Mutation returns the EvidenceMutation object of the builder.

func (*EvidenceUpdateOne) Save

func (_u *EvidenceUpdateOne) Save(ctx context.Context) (*Evidence, error)

Save executes the query and returns the updated Evidence entity.

func (*EvidenceUpdateOne) SaveX

func (_u *EvidenceUpdateOne) SaveX(ctx context.Context) *Evidence

SaveX is like Save, but panics if an error occurs.

func (*EvidenceUpdateOne) Select

func (_u *EvidenceUpdateOne) Select(field string, fields ...string) *EvidenceUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*EvidenceUpdateOne) SetCanonical

SetCanonical sets the "canonical" field.

func (*EvidenceUpdateOne) SetCapturedAt

func (_u *EvidenceUpdateOne) SetCapturedAt(v time.Time) *EvidenceUpdateOne

SetCapturedAt sets the "captured_at" field.

func (*EvidenceUpdateOne) SetCapturedBy

func (_u *EvidenceUpdateOne) SetCapturedBy(v string) *EvidenceUpdateOne

SetCapturedBy sets the "captured_by" field.

func (*EvidenceUpdateOne) SetNillableCanonical

func (_u *EvidenceUpdateOne) SetNillableCanonical(v *assessment.Evidence) *EvidenceUpdateOne

SetNillableCanonical sets the "canonical" field if the given value is not nil.

func (*EvidenceUpdateOne) SetNillableCapturedAt

func (_u *EvidenceUpdateOne) SetNillableCapturedAt(v *time.Time) *EvidenceUpdateOne

SetNillableCapturedAt sets the "captured_at" field if the given value is not nil.

func (*EvidenceUpdateOne) SetNillableCapturedBy

func (_u *EvidenceUpdateOne) SetNillableCapturedBy(v *string) *EvidenceUpdateOne

SetNillableCapturedBy sets the "captured_by" field if the given value is not nil.

func (*EvidenceUpdateOne) SetNillableSensitivity

func (_u *EvidenceUpdateOne) SetNillableSensitivity(v *string) *EvidenceUpdateOne

SetNillableSensitivity sets the "sensitivity" field if the given value is not nil.

func (*EvidenceUpdateOne) SetNillableSourceURI

func (_u *EvidenceUpdateOne) SetNillableSourceURI(v *string) *EvidenceUpdateOne

SetNillableSourceURI sets the "source_uri" field if the given value is not nil.

func (*EvidenceUpdateOne) SetNillableSystem

func (_u *EvidenceUpdateOne) SetNillableSystem(v *string) *EvidenceUpdateOne

SetNillableSystem sets the "system" field if the given value is not nil.

func (*EvidenceUpdateOne) SetNillableVerified

func (_u *EvidenceUpdateOne) SetNillableVerified(v *bool) *EvidenceUpdateOne

SetNillableVerified sets the "verified" field if the given value is not nil.

func (*EvidenceUpdateOne) SetSensitivity

func (_u *EvidenceUpdateOne) SetSensitivity(v string) *EvidenceUpdateOne

SetSensitivity sets the "sensitivity" field.

func (*EvidenceUpdateOne) SetSourceURI

func (_u *EvidenceUpdateOne) SetSourceURI(v string) *EvidenceUpdateOne

SetSourceURI sets the "source_uri" field.

func (*EvidenceUpdateOne) SetSystem

func (_u *EvidenceUpdateOne) SetSystem(v string) *EvidenceUpdateOne

SetSystem sets the "system" field.

func (*EvidenceUpdateOne) SetUpdatedAt

func (_u *EvidenceUpdateOne) SetUpdatedAt(v time.Time) *EvidenceUpdateOne

SetUpdatedAt sets the "updated_at" field.

func (*EvidenceUpdateOne) SetVerified

func (_u *EvidenceUpdateOne) SetVerified(v bool) *EvidenceUpdateOne

SetVerified sets the "verified" field.

func (*EvidenceUpdateOne) Where

Where appends a list predicates to the EvidenceUpdate builder.

type EvidenceUpsert

type EvidenceUpsert struct {
	*sql.UpdateSet
}

EvidenceUpsert is the "OnConflict" setter.

func (*EvidenceUpsert) ClearCapturedAt

func (u *EvidenceUpsert) ClearCapturedAt() *EvidenceUpsert

ClearCapturedAt clears the value of the "captured_at" field.

func (*EvidenceUpsert) ClearCapturedBy

func (u *EvidenceUpsert) ClearCapturedBy() *EvidenceUpsert

ClearCapturedBy clears the value of the "captured_by" field.

func (*EvidenceUpsert) ClearSensitivity

func (u *EvidenceUpsert) ClearSensitivity() *EvidenceUpsert

ClearSensitivity clears the value of the "sensitivity" field.

func (*EvidenceUpsert) ClearSourceURI

func (u *EvidenceUpsert) ClearSourceURI() *EvidenceUpsert

ClearSourceURI clears the value of the "source_uri" field.

func (*EvidenceUpsert) ClearSystem

func (u *EvidenceUpsert) ClearSystem() *EvidenceUpsert

ClearSystem clears the value of the "system" field.

func (*EvidenceUpsert) SetCanonical

func (u *EvidenceUpsert) SetCanonical(v assessment.Evidence) *EvidenceUpsert

SetCanonical sets the "canonical" field.

func (*EvidenceUpsert) SetCapturedAt

func (u *EvidenceUpsert) SetCapturedAt(v time.Time) *EvidenceUpsert

SetCapturedAt sets the "captured_at" field.

func (*EvidenceUpsert) SetCapturedBy

func (u *EvidenceUpsert) SetCapturedBy(v string) *EvidenceUpsert

SetCapturedBy sets the "captured_by" field.

func (*EvidenceUpsert) SetSensitivity

func (u *EvidenceUpsert) SetSensitivity(v string) *EvidenceUpsert

SetSensitivity sets the "sensitivity" field.

func (*EvidenceUpsert) SetSourceURI

func (u *EvidenceUpsert) SetSourceURI(v string) *EvidenceUpsert

SetSourceURI sets the "source_uri" field.

func (*EvidenceUpsert) SetSystem

func (u *EvidenceUpsert) SetSystem(v string) *EvidenceUpsert

SetSystem sets the "system" field.

func (*EvidenceUpsert) SetUpdatedAt

func (u *EvidenceUpsert) SetUpdatedAt(v time.Time) *EvidenceUpsert

SetUpdatedAt sets the "updated_at" field.

func (*EvidenceUpsert) SetVerified

func (u *EvidenceUpsert) SetVerified(v bool) *EvidenceUpsert

SetVerified sets the "verified" field.

func (*EvidenceUpsert) UpdateCanonical

func (u *EvidenceUpsert) UpdateCanonical() *EvidenceUpsert

UpdateCanonical sets the "canonical" field to the value that was provided on create.

func (*EvidenceUpsert) UpdateCapturedAt

func (u *EvidenceUpsert) UpdateCapturedAt() *EvidenceUpsert

UpdateCapturedAt sets the "captured_at" field to the value that was provided on create.

func (*EvidenceUpsert) UpdateCapturedBy

func (u *EvidenceUpsert) UpdateCapturedBy() *EvidenceUpsert

UpdateCapturedBy sets the "captured_by" field to the value that was provided on create.

func (*EvidenceUpsert) UpdateSensitivity

func (u *EvidenceUpsert) UpdateSensitivity() *EvidenceUpsert

UpdateSensitivity sets the "sensitivity" field to the value that was provided on create.

func (*EvidenceUpsert) UpdateSourceURI

func (u *EvidenceUpsert) UpdateSourceURI() *EvidenceUpsert

UpdateSourceURI sets the "source_uri" field to the value that was provided on create.

func (*EvidenceUpsert) UpdateSystem

func (u *EvidenceUpsert) UpdateSystem() *EvidenceUpsert

UpdateSystem sets the "system" field to the value that was provided on create.

func (*EvidenceUpsert) UpdateUpdatedAt

func (u *EvidenceUpsert) UpdateUpdatedAt() *EvidenceUpsert

UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.

func (*EvidenceUpsert) UpdateVerified

func (u *EvidenceUpsert) UpdateVerified() *EvidenceUpsert

UpdateVerified sets the "verified" field to the value that was provided on create.

type EvidenceUpsertBulk

type EvidenceUpsertBulk struct {
	// contains filtered or unexported fields
}

EvidenceUpsertBulk is the builder for "upsert"-ing a bulk of Evidence nodes.

func (*EvidenceUpsertBulk) ClearCapturedAt

func (u *EvidenceUpsertBulk) ClearCapturedAt() *EvidenceUpsertBulk

ClearCapturedAt clears the value of the "captured_at" field.

func (*EvidenceUpsertBulk) ClearCapturedBy

func (u *EvidenceUpsertBulk) ClearCapturedBy() *EvidenceUpsertBulk

ClearCapturedBy clears the value of the "captured_by" field.

func (*EvidenceUpsertBulk) ClearSensitivity

func (u *EvidenceUpsertBulk) ClearSensitivity() *EvidenceUpsertBulk

ClearSensitivity clears the value of the "sensitivity" field.

func (*EvidenceUpsertBulk) ClearSourceURI

func (u *EvidenceUpsertBulk) ClearSourceURI() *EvidenceUpsertBulk

ClearSourceURI clears the value of the "source_uri" field.

func (*EvidenceUpsertBulk) ClearSystem

func (u *EvidenceUpsertBulk) ClearSystem() *EvidenceUpsertBulk

ClearSystem clears the value of the "system" field.

func (*EvidenceUpsertBulk) DoNothing

func (u *EvidenceUpsertBulk) DoNothing() *EvidenceUpsertBulk

DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.

func (*EvidenceUpsertBulk) Exec

func (u *EvidenceUpsertBulk) Exec(ctx context.Context) error

Exec executes the query.

func (*EvidenceUpsertBulk) ExecX

func (u *EvidenceUpsertBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*EvidenceUpsertBulk) Ignore

Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:

client.Evidence.Create().
	OnConflict(sql.ResolveWithIgnore()).
	Exec(ctx)

func (*EvidenceUpsertBulk) SetCanonical

SetCanonical sets the "canonical" field.

func (*EvidenceUpsertBulk) SetCapturedAt

func (u *EvidenceUpsertBulk) SetCapturedAt(v time.Time) *EvidenceUpsertBulk

SetCapturedAt sets the "captured_at" field.

func (*EvidenceUpsertBulk) SetCapturedBy

func (u *EvidenceUpsertBulk) SetCapturedBy(v string) *EvidenceUpsertBulk

SetCapturedBy sets the "captured_by" field.

func (*EvidenceUpsertBulk) SetSensitivity

func (u *EvidenceUpsertBulk) SetSensitivity(v string) *EvidenceUpsertBulk

SetSensitivity sets the "sensitivity" field.

func (*EvidenceUpsertBulk) SetSourceURI

func (u *EvidenceUpsertBulk) SetSourceURI(v string) *EvidenceUpsertBulk

SetSourceURI sets the "source_uri" field.

func (*EvidenceUpsertBulk) SetSystem

func (u *EvidenceUpsertBulk) SetSystem(v string) *EvidenceUpsertBulk

SetSystem sets the "system" field.

func (*EvidenceUpsertBulk) SetUpdatedAt

func (u *EvidenceUpsertBulk) SetUpdatedAt(v time.Time) *EvidenceUpsertBulk

SetUpdatedAt sets the "updated_at" field.

func (*EvidenceUpsertBulk) SetVerified

func (u *EvidenceUpsertBulk) SetVerified(v bool) *EvidenceUpsertBulk

SetVerified sets the "verified" field.

func (*EvidenceUpsertBulk) Update

func (u *EvidenceUpsertBulk) Update(set func(*EvidenceUpsert)) *EvidenceUpsertBulk

Update allows overriding fields `UPDATE` values. See the EvidenceCreateBulk.OnConflict documentation for more info.

func (*EvidenceUpsertBulk) UpdateCanonical

func (u *EvidenceUpsertBulk) UpdateCanonical() *EvidenceUpsertBulk

UpdateCanonical sets the "canonical" field to the value that was provided on create.

func (*EvidenceUpsertBulk) UpdateCapturedAt

func (u *EvidenceUpsertBulk) UpdateCapturedAt() *EvidenceUpsertBulk

UpdateCapturedAt sets the "captured_at" field to the value that was provided on create.

func (*EvidenceUpsertBulk) UpdateCapturedBy

func (u *EvidenceUpsertBulk) UpdateCapturedBy() *EvidenceUpsertBulk

UpdateCapturedBy sets the "captured_by" field to the value that was provided on create.

func (*EvidenceUpsertBulk) UpdateNewValues

func (u *EvidenceUpsertBulk) UpdateNewValues() *EvidenceUpsertBulk

UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:

client.Evidence.Create().
	OnConflict(
		sql.ResolveWithNewValues(),
		sql.ResolveWith(func(u *sql.UpdateSet) {
			u.SetIgnore(evidence.FieldID)
		}),
	).
	Exec(ctx)

func (*EvidenceUpsertBulk) UpdateSensitivity

func (u *EvidenceUpsertBulk) UpdateSensitivity() *EvidenceUpsertBulk

UpdateSensitivity sets the "sensitivity" field to the value that was provided on create.

func (*EvidenceUpsertBulk) UpdateSourceURI

func (u *EvidenceUpsertBulk) UpdateSourceURI() *EvidenceUpsertBulk

UpdateSourceURI sets the "source_uri" field to the value that was provided on create.

func (*EvidenceUpsertBulk) UpdateSystem

func (u *EvidenceUpsertBulk) UpdateSystem() *EvidenceUpsertBulk

UpdateSystem sets the "system" field to the value that was provided on create.

func (*EvidenceUpsertBulk) UpdateUpdatedAt

func (u *EvidenceUpsertBulk) UpdateUpdatedAt() *EvidenceUpsertBulk

UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.

func (*EvidenceUpsertBulk) UpdateVerified

func (u *EvidenceUpsertBulk) UpdateVerified() *EvidenceUpsertBulk

UpdateVerified sets the "verified" field to the value that was provided on create.

type EvidenceUpsertOne

type EvidenceUpsertOne struct {
	// contains filtered or unexported fields
}

EvidenceUpsertOne is the builder for "upsert"-ing

one Evidence node.

func (*EvidenceUpsertOne) ClearCapturedAt

func (u *EvidenceUpsertOne) ClearCapturedAt() *EvidenceUpsertOne

ClearCapturedAt clears the value of the "captured_at" field.

func (*EvidenceUpsertOne) ClearCapturedBy

func (u *EvidenceUpsertOne) ClearCapturedBy() *EvidenceUpsertOne

ClearCapturedBy clears the value of the "captured_by" field.

func (*EvidenceUpsertOne) ClearSensitivity

func (u *EvidenceUpsertOne) ClearSensitivity() *EvidenceUpsertOne

ClearSensitivity clears the value of the "sensitivity" field.

func (*EvidenceUpsertOne) ClearSourceURI

func (u *EvidenceUpsertOne) ClearSourceURI() *EvidenceUpsertOne

ClearSourceURI clears the value of the "source_uri" field.

func (*EvidenceUpsertOne) ClearSystem

func (u *EvidenceUpsertOne) ClearSystem() *EvidenceUpsertOne

ClearSystem clears the value of the "system" field.

func (*EvidenceUpsertOne) DoNothing

func (u *EvidenceUpsertOne) DoNothing() *EvidenceUpsertOne

DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.

func (*EvidenceUpsertOne) Exec

func (u *EvidenceUpsertOne) Exec(ctx context.Context) error

Exec executes the query.

func (*EvidenceUpsertOne) ExecX

func (u *EvidenceUpsertOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*EvidenceUpsertOne) ID

func (u *EvidenceUpsertOne) ID(ctx context.Context) (id string, err error)

Exec executes the UPSERT query and returns the inserted/updated ID.

func (*EvidenceUpsertOne) IDX

IDX is like ID, but panics if an error occurs.

func (*EvidenceUpsertOne) Ignore

func (u *EvidenceUpsertOne) Ignore() *EvidenceUpsertOne

Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:

client.Evidence.Create().
    OnConflict(sql.ResolveWithIgnore()).
    Exec(ctx)

func (*EvidenceUpsertOne) SetCanonical

SetCanonical sets the "canonical" field.

func (*EvidenceUpsertOne) SetCapturedAt

func (u *EvidenceUpsertOne) SetCapturedAt(v time.Time) *EvidenceUpsertOne

SetCapturedAt sets the "captured_at" field.

func (*EvidenceUpsertOne) SetCapturedBy

func (u *EvidenceUpsertOne) SetCapturedBy(v string) *EvidenceUpsertOne

SetCapturedBy sets the "captured_by" field.

func (*EvidenceUpsertOne) SetSensitivity

func (u *EvidenceUpsertOne) SetSensitivity(v string) *EvidenceUpsertOne

SetSensitivity sets the "sensitivity" field.

func (*EvidenceUpsertOne) SetSourceURI

func (u *EvidenceUpsertOne) SetSourceURI(v string) *EvidenceUpsertOne

SetSourceURI sets the "source_uri" field.

func (*EvidenceUpsertOne) SetSystem

func (u *EvidenceUpsertOne) SetSystem(v string) *EvidenceUpsertOne

SetSystem sets the "system" field.

func (*EvidenceUpsertOne) SetUpdatedAt

func (u *EvidenceUpsertOne) SetUpdatedAt(v time.Time) *EvidenceUpsertOne

SetUpdatedAt sets the "updated_at" field.

func (*EvidenceUpsertOne) SetVerified

func (u *EvidenceUpsertOne) SetVerified(v bool) *EvidenceUpsertOne

SetVerified sets the "verified" field.

func (*EvidenceUpsertOne) Update

func (u *EvidenceUpsertOne) Update(set func(*EvidenceUpsert)) *EvidenceUpsertOne

Update allows overriding fields `UPDATE` values. See the EvidenceCreate.OnConflict documentation for more info.

func (*EvidenceUpsertOne) UpdateCanonical

func (u *EvidenceUpsertOne) UpdateCanonical() *EvidenceUpsertOne

UpdateCanonical sets the "canonical" field to the value that was provided on create.

func (*EvidenceUpsertOne) UpdateCapturedAt

func (u *EvidenceUpsertOne) UpdateCapturedAt() *EvidenceUpsertOne

UpdateCapturedAt sets the "captured_at" field to the value that was provided on create.

func (*EvidenceUpsertOne) UpdateCapturedBy

func (u *EvidenceUpsertOne) UpdateCapturedBy() *EvidenceUpsertOne

UpdateCapturedBy sets the "captured_by" field to the value that was provided on create.

func (*EvidenceUpsertOne) UpdateNewValues

func (u *EvidenceUpsertOne) UpdateNewValues() *EvidenceUpsertOne

UpdateNewValues updates the mutable fields using the new values that were set on create except the ID field. Using this option is equivalent to using:

client.Evidence.Create().
	OnConflict(
		sql.ResolveWithNewValues(),
		sql.ResolveWith(func(u *sql.UpdateSet) {
			u.SetIgnore(evidence.FieldID)
		}),
	).
	Exec(ctx)

func (*EvidenceUpsertOne) UpdateSensitivity

func (u *EvidenceUpsertOne) UpdateSensitivity() *EvidenceUpsertOne

UpdateSensitivity sets the "sensitivity" field to the value that was provided on create.

func (*EvidenceUpsertOne) UpdateSourceURI

func (u *EvidenceUpsertOne) UpdateSourceURI() *EvidenceUpsertOne

UpdateSourceURI sets the "source_uri" field to the value that was provided on create.

func (*EvidenceUpsertOne) UpdateSystem

func (u *EvidenceUpsertOne) UpdateSystem() *EvidenceUpsertOne

UpdateSystem sets the "system" field to the value that was provided on create.

func (*EvidenceUpsertOne) UpdateUpdatedAt

func (u *EvidenceUpsertOne) UpdateUpdatedAt() *EvidenceUpsertOne

UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.

func (*EvidenceUpsertOne) UpdateVerified

func (u *EvidenceUpsertOne) UpdateVerified() *EvidenceUpsertOne

UpdateVerified sets the "verified" field to the value that was provided on create.

type Evidences

type Evidences []*Evidence

Evidences is a parsable slice of Evidence.

type Hook

type Hook = ent.Hook

ent aliases to avoid import conflicts in user's code.

type InterceptFunc

type InterceptFunc = ent.InterceptFunc

ent aliases to avoid import conflicts in user's code.

type Interceptor

type Interceptor = ent.Interceptor

ent aliases to avoid import conflicts in user's code.

type Item

type Item struct {

	// ID of the ent.
	ID string `json:"id,omitempty"`
	// Provider holds the value of the "provider" field.
	Provider string `json:"provider,omitempty"`
	// SourceID holds the value of the "source_id" field.
	SourceID string `json:"source_id,omitempty"`
	// SourceRef holds the value of the "source_ref" field.
	SourceRef string `json:"source_ref,omitempty"`
	// SourceURL holds the value of the "source_url" field.
	SourceURL string `json:"source_url,omitempty"`
	// WorkspaceRef holds the value of the "workspace_ref" field.
	WorkspaceRef string `json:"workspace_ref,omitempty"`
	// Kind holds the value of the "kind" field.
	Kind string `json:"kind,omitempty"`
	// Name holds the value of the "name" field.
	Name string `json:"name,omitempty"`
	// Description holds the value of the "description" field.
	Description string `json:"description,omitempty"`
	// StatusID holds the value of the "status_id" field.
	StatusID string `json:"status_id,omitempty"`
	// StatusName holds the value of the "status_name" field.
	StatusName string `json:"status_name,omitempty"`
	// StatusCategory holds the value of the "status_category" field.
	StatusCategory string `json:"status_category,omitempty"`
	// StatusComplete holds the value of the "status_complete" field.
	StatusComplete bool `json:"status_complete,omitempty"`
	// Progress holds the value of the "progress" field.
	Progress *float64 `json:"progress,omitempty"`
	// ParentID holds the value of the "parent_id" field.
	ParentID string `json:"parent_id,omitempty"`
	// ReleaseID holds the value of the "release_id" field.
	ReleaseID string `json:"release_id,omitempty"`
	// StartDate holds the value of the "start_date" field.
	StartDate *time.Time `json:"start_date,omitempty"`
	// DueDate holds the value of the "due_date" field.
	DueDate *time.Time `json:"due_date,omitempty"`
	// CreatedAt holds the value of the "created_at" field.
	CreatedAt *time.Time `json:"created_at,omitempty"`
	// UpdatedAt holds the value of the "updated_at" field.
	UpdatedAt *time.Time `json:"updated_at,omitempty"`
	// OwnerID holds the value of the "owner_id" field.
	OwnerID string `json:"owner_id,omitempty"`
	// OwnerName holds the value of the "owner_name" field.
	OwnerName string `json:"owner_name,omitempty"`
	// OwnerEmail holds the value of the "owner_email" field.
	OwnerEmail string `json:"owner_email,omitempty"`
	// Moscow holds the value of the "moscow" field.
	Moscow string `json:"moscow,omitempty"`
	// Kano holds the value of the "kano" field.
	Kano string `json:"kano,omitempty"`
	// Rice holds the value of the "rice" field.
	Rice map[string]float64 `json:"rice,omitempty"`
	// Tags holds the value of the "tags" field.
	Tags []string `json:"tags,omitempty"`
	// CustomFields holds the value of the "custom_fields" field.
	CustomFields []map[string]interface{} `json:"custom_fields,omitempty"`
	// Metadata holds the value of the "metadata" field.
	Metadata map[string]interface{} `json:"metadata,omitempty"`
	// SyncedAt holds the value of the "synced_at" field.
	SyncedAt time.Time `json:"synced_at,omitempty"`
	// contains filtered or unexported fields
}

Item is the model entity for the Item schema.

func (*Item) String

func (_m *Item) String() string

String implements the fmt.Stringer.

func (*Item) Unwrap

func (_m *Item) Unwrap() *Item

Unwrap unwraps the Item entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*Item) Update

func (_m *Item) Update() *ItemUpdateOne

Update returns a builder for updating this Item. Note that you need to call Item.Unwrap() before calling this method if this Item was returned from a transaction, and the transaction was committed or rolled back.

func (*Item) Value

func (_m *Item) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the Item. This includes values selected through modifiers, order, etc.

type ItemAugment

type ItemAugment struct {

	// ID of the ent.
	ID string `json:"id,omitempty"`
	// Provider holds the value of the "provider" field.
	Provider string `json:"provider,omitempty"`
	// SourceRef holds the value of the "source_ref" field.
	SourceRef string `json:"source_ref,omitempty"`
	// Moscow holds the value of the "moscow" field.
	Moscow string `json:"moscow,omitempty"`
	// Kano holds the value of the "kano" field.
	Kano string `json:"kano,omitempty"`
	// Rice holds the value of the "rice" field.
	Rice map[string]float64 `json:"rice,omitempty"`
	// OkrRefs holds the value of the "okr_refs" field.
	OkrRefs []string `json:"okr_refs,omitempty"`
	// Notes holds the value of the "notes" field.
	Notes string `json:"notes,omitempty"`
	// Metadata holds the value of the "metadata" field.
	Metadata map[string]interface{} `json:"metadata,omitempty"`
	// UpdatedAt holds the value of the "updated_at" field.
	UpdatedAt time.Time `json:"updated_at,omitempty"`
	// contains filtered or unexported fields
}

ItemAugment is the model entity for the ItemAugment schema.

func (*ItemAugment) String

func (_m *ItemAugment) String() string

String implements the fmt.Stringer.

func (*ItemAugment) Unwrap

func (_m *ItemAugment) Unwrap() *ItemAugment

Unwrap unwraps the ItemAugment entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*ItemAugment) Update

func (_m *ItemAugment) Update() *ItemAugmentUpdateOne

Update returns a builder for updating this ItemAugment. Note that you need to call ItemAugment.Unwrap() before calling this method if this ItemAugment was returned from a transaction, and the transaction was committed or rolled back.

func (*ItemAugment) Value

func (_m *ItemAugment) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the ItemAugment. This includes values selected through modifiers, order, etc.

type ItemAugmentClient

type ItemAugmentClient struct {
	// contains filtered or unexported fields
}

ItemAugmentClient is a client for the ItemAugment schema.

func NewItemAugmentClient

func NewItemAugmentClient(c config) *ItemAugmentClient

NewItemAugmentClient returns a client for the ItemAugment from the given config.

func (*ItemAugmentClient) Create

func (c *ItemAugmentClient) Create() *ItemAugmentCreate

Create returns a builder for creating a ItemAugment entity.

func (*ItemAugmentClient) CreateBulk

func (c *ItemAugmentClient) CreateBulk(builders ...*ItemAugmentCreate) *ItemAugmentCreateBulk

CreateBulk returns a builder for creating a bulk of ItemAugment entities.

func (*ItemAugmentClient) Delete

func (c *ItemAugmentClient) Delete() *ItemAugmentDelete

Delete returns a delete builder for ItemAugment.

func (*ItemAugmentClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*ItemAugmentClient) DeleteOneID

func (c *ItemAugmentClient) DeleteOneID(id string) *ItemAugmentDeleteOne

DeleteOneID returns a builder for deleting the given entity by its id.

func (*ItemAugmentClient) Get

Get returns a ItemAugment entity by its id.

func (*ItemAugmentClient) GetX

GetX is like Get, but panics if an error occurs.

func (*ItemAugmentClient) Hooks

func (c *ItemAugmentClient) Hooks() []Hook

Hooks returns the client hooks.

func (*ItemAugmentClient) Intercept

func (c *ItemAugmentClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `itemaugment.Intercept(f(g(h())))`.

func (*ItemAugmentClient) Interceptors

func (c *ItemAugmentClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*ItemAugmentClient) MapCreateBulk

func (c *ItemAugmentClient) MapCreateBulk(slice any, setFunc func(*ItemAugmentCreate, int)) *ItemAugmentCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*ItemAugmentClient) Query

func (c *ItemAugmentClient) Query() *ItemAugmentQuery

Query returns a query builder for ItemAugment.

func (*ItemAugmentClient) Update

func (c *ItemAugmentClient) Update() *ItemAugmentUpdate

Update returns an update builder for ItemAugment.

func (*ItemAugmentClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*ItemAugmentClient) UpdateOneID

func (c *ItemAugmentClient) UpdateOneID(id string) *ItemAugmentUpdateOne

UpdateOneID returns an update builder for the given id.

func (*ItemAugmentClient) Use

func (c *ItemAugmentClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `itemaugment.Hooks(f(g(h())))`.

type ItemAugmentCreate

type ItemAugmentCreate struct {
	// contains filtered or unexported fields
}

ItemAugmentCreate is the builder for creating a ItemAugment entity.

func (*ItemAugmentCreate) Exec

func (_c *ItemAugmentCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*ItemAugmentCreate) ExecX

func (_c *ItemAugmentCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ItemAugmentCreate) Mutation

func (_c *ItemAugmentCreate) Mutation() *ItemAugmentMutation

Mutation returns the ItemAugmentMutation object of the builder.

func (*ItemAugmentCreate) OnConflict

func (_c *ItemAugmentCreate) OnConflict(opts ...sql.ConflictOption) *ItemAugmentUpsertOne

OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:

client.ItemAugment.Create().
	SetProvider(v).
	OnConflict(
		// Update the row with the new values
		// the was proposed for insertion.
		sql.ResolveWithNewValues(),
	).
	// Override some of the fields with custom
	// update values.
	Update(func(u *ent.ItemAugmentUpsert) {
		SetProvider(v+v).
	}).
	Exec(ctx)

func (*ItemAugmentCreate) OnConflictColumns

func (_c *ItemAugmentCreate) OnConflictColumns(columns ...string) *ItemAugmentUpsertOne

OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:

client.ItemAugment.Create().
	OnConflict(sql.ConflictColumns(columns...)).
	Exec(ctx)

func (*ItemAugmentCreate) Save

Save creates the ItemAugment in the database.

func (*ItemAugmentCreate) SaveX

func (_c *ItemAugmentCreate) SaveX(ctx context.Context) *ItemAugment

SaveX calls Save and panics if Save returns an error.

func (*ItemAugmentCreate) SetID

SetID sets the "id" field.

func (*ItemAugmentCreate) SetKano

func (_c *ItemAugmentCreate) SetKano(v string) *ItemAugmentCreate

SetKano sets the "kano" field.

func (*ItemAugmentCreate) SetMetadata

func (_c *ItemAugmentCreate) SetMetadata(v map[string]interface{}) *ItemAugmentCreate

SetMetadata sets the "metadata" field.

func (*ItemAugmentCreate) SetMoscow

func (_c *ItemAugmentCreate) SetMoscow(v string) *ItemAugmentCreate

SetMoscow sets the "moscow" field.

func (*ItemAugmentCreate) SetNillableKano

func (_c *ItemAugmentCreate) SetNillableKano(v *string) *ItemAugmentCreate

SetNillableKano sets the "kano" field if the given value is not nil.

func (*ItemAugmentCreate) SetNillableMoscow

func (_c *ItemAugmentCreate) SetNillableMoscow(v *string) *ItemAugmentCreate

SetNillableMoscow sets the "moscow" field if the given value is not nil.

func (*ItemAugmentCreate) SetNillableNotes

func (_c *ItemAugmentCreate) SetNillableNotes(v *string) *ItemAugmentCreate

SetNillableNotes sets the "notes" field if the given value is not nil.

func (*ItemAugmentCreate) SetNillableUpdatedAt

func (_c *ItemAugmentCreate) SetNillableUpdatedAt(v *time.Time) *ItemAugmentCreate

SetNillableUpdatedAt sets the "updated_at" field if the given value is not nil.

func (*ItemAugmentCreate) SetNotes

func (_c *ItemAugmentCreate) SetNotes(v string) *ItemAugmentCreate

SetNotes sets the "notes" field.

func (*ItemAugmentCreate) SetOkrRefs

func (_c *ItemAugmentCreate) SetOkrRefs(v []string) *ItemAugmentCreate

SetOkrRefs sets the "okr_refs" field.

func (*ItemAugmentCreate) SetProvider

func (_c *ItemAugmentCreate) SetProvider(v string) *ItemAugmentCreate

SetProvider sets the "provider" field.

func (*ItemAugmentCreate) SetRice

func (_c *ItemAugmentCreate) SetRice(v map[string]float64) *ItemAugmentCreate

SetRice sets the "rice" field.

func (*ItemAugmentCreate) SetSourceRef

func (_c *ItemAugmentCreate) SetSourceRef(v string) *ItemAugmentCreate

SetSourceRef sets the "source_ref" field.

func (*ItemAugmentCreate) SetUpdatedAt

func (_c *ItemAugmentCreate) SetUpdatedAt(v time.Time) *ItemAugmentCreate

SetUpdatedAt sets the "updated_at" field.

type ItemAugmentCreateBulk

type ItemAugmentCreateBulk struct {
	// contains filtered or unexported fields
}

ItemAugmentCreateBulk is the builder for creating many ItemAugment entities in bulk.

func (*ItemAugmentCreateBulk) Exec

Exec executes the query.

func (*ItemAugmentCreateBulk) ExecX

func (_c *ItemAugmentCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ItemAugmentCreateBulk) OnConflict

OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:

client.ItemAugment.CreateBulk(builders...).
	OnConflict(
		// Update the row with the new values
		// the was proposed for insertion.
		sql.ResolveWithNewValues(),
	).
	// Override some of the fields with custom
	// update values.
	Update(func(u *ent.ItemAugmentUpsert) {
		SetProvider(v+v).
	}).
	Exec(ctx)

func (*ItemAugmentCreateBulk) OnConflictColumns

func (_c *ItemAugmentCreateBulk) OnConflictColumns(columns ...string) *ItemAugmentUpsertBulk

OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:

client.ItemAugment.Create().
	OnConflict(sql.ConflictColumns(columns...)).
	Exec(ctx)

func (*ItemAugmentCreateBulk) Save

Save creates the ItemAugment entities in the database.

func (*ItemAugmentCreateBulk) SaveX

SaveX is like Save, but panics if an error occurs.

type ItemAugmentDelete

type ItemAugmentDelete struct {
	// contains filtered or unexported fields
}

ItemAugmentDelete is the builder for deleting a ItemAugment entity.

func (*ItemAugmentDelete) Exec

func (_d *ItemAugmentDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*ItemAugmentDelete) ExecX

func (_d *ItemAugmentDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*ItemAugmentDelete) Where

Where appends a list predicates to the ItemAugmentDelete builder.

type ItemAugmentDeleteOne

type ItemAugmentDeleteOne struct {
	// contains filtered or unexported fields
}

ItemAugmentDeleteOne is the builder for deleting a single ItemAugment entity.

func (*ItemAugmentDeleteOne) Exec

func (_d *ItemAugmentDeleteOne) Exec(ctx context.Context) error

Exec executes the deletion query.

func (*ItemAugmentDeleteOne) ExecX

func (_d *ItemAugmentDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ItemAugmentDeleteOne) Where

Where appends a list predicates to the ItemAugmentDelete builder.

type ItemAugmentGroupBy

type ItemAugmentGroupBy struct {
	// contains filtered or unexported fields
}

ItemAugmentGroupBy is the group-by builder for ItemAugment entities.

func (*ItemAugmentGroupBy) Aggregate

func (_g *ItemAugmentGroupBy) Aggregate(fns ...AggregateFunc) *ItemAugmentGroupBy

Aggregate adds the given aggregation functions to the group-by query.

func (*ItemAugmentGroupBy) Bool

func (s *ItemAugmentGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*ItemAugmentGroupBy) BoolX

func (s *ItemAugmentGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*ItemAugmentGroupBy) Bools

func (s *ItemAugmentGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*ItemAugmentGroupBy) BoolsX

func (s *ItemAugmentGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*ItemAugmentGroupBy) Float64

func (s *ItemAugmentGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*ItemAugmentGroupBy) Float64X

func (s *ItemAugmentGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*ItemAugmentGroupBy) Float64s

func (s *ItemAugmentGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*ItemAugmentGroupBy) Float64sX

func (s *ItemAugmentGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*ItemAugmentGroupBy) Int

func (s *ItemAugmentGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*ItemAugmentGroupBy) IntX

func (s *ItemAugmentGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*ItemAugmentGroupBy) Ints

func (s *ItemAugmentGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*ItemAugmentGroupBy) IntsX

func (s *ItemAugmentGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*ItemAugmentGroupBy) Scan

func (_g *ItemAugmentGroupBy) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*ItemAugmentGroupBy) ScanX

func (s *ItemAugmentGroupBy) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*ItemAugmentGroupBy) String

func (s *ItemAugmentGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*ItemAugmentGroupBy) StringX

func (s *ItemAugmentGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*ItemAugmentGroupBy) Strings

func (s *ItemAugmentGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*ItemAugmentGroupBy) StringsX

func (s *ItemAugmentGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type ItemAugmentMutation

type ItemAugmentMutation struct {
	// contains filtered or unexported fields
}

ItemAugmentMutation represents an operation that mutates the ItemAugment nodes in the graph.

func (*ItemAugmentMutation) AddField

func (m *ItemAugmentMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*ItemAugmentMutation) AddedEdges

func (m *ItemAugmentMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*ItemAugmentMutation) AddedField

func (m *ItemAugmentMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*ItemAugmentMutation) AddedFields

func (m *ItemAugmentMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*ItemAugmentMutation) AddedIDs

func (m *ItemAugmentMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*ItemAugmentMutation) AppendOkrRefs

func (m *ItemAugmentMutation) AppendOkrRefs(s []string)

AppendOkrRefs adds s to the "okr_refs" field.

func (*ItemAugmentMutation) AppendedOkrRefs

func (m *ItemAugmentMutation) AppendedOkrRefs() ([]string, bool)

AppendedOkrRefs returns the list of values that were appended to the "okr_refs" field in this mutation.

func (*ItemAugmentMutation) ClearEdge

func (m *ItemAugmentMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*ItemAugmentMutation) ClearField

func (m *ItemAugmentMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*ItemAugmentMutation) ClearKano

func (m *ItemAugmentMutation) ClearKano()

ClearKano clears the value of the "kano" field.

func (*ItemAugmentMutation) ClearMetadata

func (m *ItemAugmentMutation) ClearMetadata()

ClearMetadata clears the value of the "metadata" field.

func (*ItemAugmentMutation) ClearMoscow

func (m *ItemAugmentMutation) ClearMoscow()

ClearMoscow clears the value of the "moscow" field.

func (*ItemAugmentMutation) ClearNotes

func (m *ItemAugmentMutation) ClearNotes()

ClearNotes clears the value of the "notes" field.

func (*ItemAugmentMutation) ClearOkrRefs

func (m *ItemAugmentMutation) ClearOkrRefs()

ClearOkrRefs clears the value of the "okr_refs" field.

func (*ItemAugmentMutation) ClearRice

func (m *ItemAugmentMutation) ClearRice()

ClearRice clears the value of the "rice" field.

func (*ItemAugmentMutation) ClearedEdges

func (m *ItemAugmentMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*ItemAugmentMutation) ClearedFields

func (m *ItemAugmentMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (ItemAugmentMutation) Client

func (m ItemAugmentMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*ItemAugmentMutation) EdgeCleared

func (m *ItemAugmentMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*ItemAugmentMutation) Field

func (m *ItemAugmentMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*ItemAugmentMutation) FieldCleared

func (m *ItemAugmentMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*ItemAugmentMutation) Fields

func (m *ItemAugmentMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*ItemAugmentMutation) ID

func (m *ItemAugmentMutation) ID() (id string, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*ItemAugmentMutation) IDs

func (m *ItemAugmentMutation) IDs(ctx context.Context) ([]string, error)

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*ItemAugmentMutation) Kano

func (m *ItemAugmentMutation) Kano() (r string, exists bool)

Kano returns the value of the "kano" field in the mutation.

func (*ItemAugmentMutation) KanoCleared

func (m *ItemAugmentMutation) KanoCleared() bool

KanoCleared returns if the "kano" field was cleared in this mutation.

func (*ItemAugmentMutation) Metadata

func (m *ItemAugmentMutation) Metadata() (r map[string]interface{}, exists bool)

Metadata returns the value of the "metadata" field in the mutation.

func (*ItemAugmentMutation) MetadataCleared

func (m *ItemAugmentMutation) MetadataCleared() bool

MetadataCleared returns if the "metadata" field was cleared in this mutation.

func (*ItemAugmentMutation) Moscow

func (m *ItemAugmentMutation) Moscow() (r string, exists bool)

Moscow returns the value of the "moscow" field in the mutation.

func (*ItemAugmentMutation) MoscowCleared

func (m *ItemAugmentMutation) MoscowCleared() bool

MoscowCleared returns if the "moscow" field was cleared in this mutation.

func (*ItemAugmentMutation) Notes

func (m *ItemAugmentMutation) Notes() (r string, exists bool)

Notes returns the value of the "notes" field in the mutation.

func (*ItemAugmentMutation) NotesCleared

func (m *ItemAugmentMutation) NotesCleared() bool

NotesCleared returns if the "notes" field was cleared in this mutation.

func (*ItemAugmentMutation) OkrRefs

func (m *ItemAugmentMutation) OkrRefs() (r []string, exists bool)

OkrRefs returns the value of the "okr_refs" field in the mutation.

func (*ItemAugmentMutation) OkrRefsCleared

func (m *ItemAugmentMutation) OkrRefsCleared() bool

OkrRefsCleared returns if the "okr_refs" field was cleared in this mutation.

func (*ItemAugmentMutation) OldField

func (m *ItemAugmentMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*ItemAugmentMutation) OldKano

func (m *ItemAugmentMutation) OldKano(ctx context.Context) (v string, err error)

OldKano returns the old "kano" field's value of the ItemAugment entity. If the ItemAugment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemAugmentMutation) OldMetadata

func (m *ItemAugmentMutation) OldMetadata(ctx context.Context) (v map[string]interface{}, err error)

OldMetadata returns the old "metadata" field's value of the ItemAugment entity. If the ItemAugment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemAugmentMutation) OldMoscow

func (m *ItemAugmentMutation) OldMoscow(ctx context.Context) (v string, err error)

OldMoscow returns the old "moscow" field's value of the ItemAugment entity. If the ItemAugment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemAugmentMutation) OldNotes

func (m *ItemAugmentMutation) OldNotes(ctx context.Context) (v string, err error)

OldNotes returns the old "notes" field's value of the ItemAugment entity. If the ItemAugment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemAugmentMutation) OldOkrRefs

func (m *ItemAugmentMutation) OldOkrRefs(ctx context.Context) (v []string, err error)

OldOkrRefs returns the old "okr_refs" field's value of the ItemAugment entity. If the ItemAugment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemAugmentMutation) OldProvider

func (m *ItemAugmentMutation) OldProvider(ctx context.Context) (v string, err error)

OldProvider returns the old "provider" field's value of the ItemAugment entity. If the ItemAugment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemAugmentMutation) OldRice

func (m *ItemAugmentMutation) OldRice(ctx context.Context) (v map[string]float64, err error)

OldRice returns the old "rice" field's value of the ItemAugment entity. If the ItemAugment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemAugmentMutation) OldSourceRef

func (m *ItemAugmentMutation) OldSourceRef(ctx context.Context) (v string, err error)

OldSourceRef returns the old "source_ref" field's value of the ItemAugment entity. If the ItemAugment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemAugmentMutation) OldUpdatedAt

func (m *ItemAugmentMutation) OldUpdatedAt(ctx context.Context) (v time.Time, err error)

OldUpdatedAt returns the old "updated_at" field's value of the ItemAugment entity. If the ItemAugment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemAugmentMutation) Op

func (m *ItemAugmentMutation) Op() Op

Op returns the operation name.

func (*ItemAugmentMutation) Provider

func (m *ItemAugmentMutation) Provider() (r string, exists bool)

Provider returns the value of the "provider" field in the mutation.

func (*ItemAugmentMutation) RemovedEdges

func (m *ItemAugmentMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*ItemAugmentMutation) RemovedIDs

func (m *ItemAugmentMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*ItemAugmentMutation) ResetEdge

func (m *ItemAugmentMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*ItemAugmentMutation) ResetField

func (m *ItemAugmentMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*ItemAugmentMutation) ResetKano

func (m *ItemAugmentMutation) ResetKano()

ResetKano resets all changes to the "kano" field.

func (*ItemAugmentMutation) ResetMetadata

func (m *ItemAugmentMutation) ResetMetadata()

ResetMetadata resets all changes to the "metadata" field.

func (*ItemAugmentMutation) ResetMoscow

func (m *ItemAugmentMutation) ResetMoscow()

ResetMoscow resets all changes to the "moscow" field.

func (*ItemAugmentMutation) ResetNotes

func (m *ItemAugmentMutation) ResetNotes()

ResetNotes resets all changes to the "notes" field.

func (*ItemAugmentMutation) ResetOkrRefs

func (m *ItemAugmentMutation) ResetOkrRefs()

ResetOkrRefs resets all changes to the "okr_refs" field.

func (*ItemAugmentMutation) ResetProvider

func (m *ItemAugmentMutation) ResetProvider()

ResetProvider resets all changes to the "provider" field.

func (*ItemAugmentMutation) ResetRice

func (m *ItemAugmentMutation) ResetRice()

ResetRice resets all changes to the "rice" field.

func (*ItemAugmentMutation) ResetSourceRef

func (m *ItemAugmentMutation) ResetSourceRef()

ResetSourceRef resets all changes to the "source_ref" field.

func (*ItemAugmentMutation) ResetUpdatedAt

func (m *ItemAugmentMutation) ResetUpdatedAt()

ResetUpdatedAt resets all changes to the "updated_at" field.

func (*ItemAugmentMutation) Rice

func (m *ItemAugmentMutation) Rice() (r map[string]float64, exists bool)

Rice returns the value of the "rice" field in the mutation.

func (*ItemAugmentMutation) RiceCleared

func (m *ItemAugmentMutation) RiceCleared() bool

RiceCleared returns if the "rice" field was cleared in this mutation.

func (*ItemAugmentMutation) SetField

func (m *ItemAugmentMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*ItemAugmentMutation) SetID

func (m *ItemAugmentMutation) SetID(id string)

SetID sets the value of the id field. Note that this operation is only accepted on creation of ItemAugment entities.

func (*ItemAugmentMutation) SetKano

func (m *ItemAugmentMutation) SetKano(s string)

SetKano sets the "kano" field.

func (*ItemAugmentMutation) SetMetadata

func (m *ItemAugmentMutation) SetMetadata(value map[string]interface{})

SetMetadata sets the "metadata" field.

func (*ItemAugmentMutation) SetMoscow

func (m *ItemAugmentMutation) SetMoscow(s string)

SetMoscow sets the "moscow" field.

func (*ItemAugmentMutation) SetNotes

func (m *ItemAugmentMutation) SetNotes(s string)

SetNotes sets the "notes" field.

func (*ItemAugmentMutation) SetOkrRefs

func (m *ItemAugmentMutation) SetOkrRefs(s []string)

SetOkrRefs sets the "okr_refs" field.

func (*ItemAugmentMutation) SetOp

func (m *ItemAugmentMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*ItemAugmentMutation) SetProvider

func (m *ItemAugmentMutation) SetProvider(s string)

SetProvider sets the "provider" field.

func (*ItemAugmentMutation) SetRice

func (m *ItemAugmentMutation) SetRice(value map[string]float64)

SetRice sets the "rice" field.

func (*ItemAugmentMutation) SetSourceRef

func (m *ItemAugmentMutation) SetSourceRef(s string)

SetSourceRef sets the "source_ref" field.

func (*ItemAugmentMutation) SetUpdatedAt

func (m *ItemAugmentMutation) SetUpdatedAt(t time.Time)

SetUpdatedAt sets the "updated_at" field.

func (*ItemAugmentMutation) SourceRef

func (m *ItemAugmentMutation) SourceRef() (r string, exists bool)

SourceRef returns the value of the "source_ref" field in the mutation.

func (ItemAugmentMutation) Tx

func (m ItemAugmentMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*ItemAugmentMutation) Type

func (m *ItemAugmentMutation) Type() string

Type returns the node type of this mutation (ItemAugment).

func (*ItemAugmentMutation) UpdatedAt

func (m *ItemAugmentMutation) UpdatedAt() (r time.Time, exists bool)

UpdatedAt returns the value of the "updated_at" field in the mutation.

func (*ItemAugmentMutation) Where

func (m *ItemAugmentMutation) Where(ps ...predicate.ItemAugment)

Where appends a list predicates to the ItemAugmentMutation builder.

func (*ItemAugmentMutation) WhereP

func (m *ItemAugmentMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the ItemAugmentMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

type ItemAugmentQuery

type ItemAugmentQuery struct {
	// contains filtered or unexported fields
}

ItemAugmentQuery is the builder for querying ItemAugment entities.

func (*ItemAugmentQuery) Aggregate

func (_q *ItemAugmentQuery) Aggregate(fns ...AggregateFunc) *ItemAugmentSelect

Aggregate returns a ItemAugmentSelect configured with the given aggregations.

func (*ItemAugmentQuery) All

func (_q *ItemAugmentQuery) All(ctx context.Context) ([]*ItemAugment, error)

All executes the query and returns a list of ItemAugments.

func (*ItemAugmentQuery) AllX

func (_q *ItemAugmentQuery) AllX(ctx context.Context) []*ItemAugment

AllX is like All, but panics if an error occurs.

func (*ItemAugmentQuery) Clone

func (_q *ItemAugmentQuery) Clone() *ItemAugmentQuery

Clone returns a duplicate of the ItemAugmentQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*ItemAugmentQuery) Count

func (_q *ItemAugmentQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*ItemAugmentQuery) CountX

func (_q *ItemAugmentQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*ItemAugmentQuery) Exist

func (_q *ItemAugmentQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*ItemAugmentQuery) ExistX

func (_q *ItemAugmentQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*ItemAugmentQuery) First

func (_q *ItemAugmentQuery) First(ctx context.Context) (*ItemAugment, error)

First returns the first ItemAugment entity from the query. Returns a *NotFoundError when no ItemAugment was found.

func (*ItemAugmentQuery) FirstID

func (_q *ItemAugmentQuery) FirstID(ctx context.Context) (id string, err error)

FirstID returns the first ItemAugment ID from the query. Returns a *NotFoundError when no ItemAugment ID was found.

func (*ItemAugmentQuery) FirstIDX

func (_q *ItemAugmentQuery) FirstIDX(ctx context.Context) string

FirstIDX is like FirstID, but panics if an error occurs.

func (*ItemAugmentQuery) FirstX

func (_q *ItemAugmentQuery) FirstX(ctx context.Context) *ItemAugment

FirstX is like First, but panics if an error occurs.

func (*ItemAugmentQuery) GroupBy

func (_q *ItemAugmentQuery) GroupBy(field string, fields ...string) *ItemAugmentGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	Provider string `json:"provider,omitempty"`
	Count int `json:"count,omitempty"`
}

client.ItemAugment.Query().
	GroupBy(itemaugment.FieldProvider).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*ItemAugmentQuery) IDs

func (_q *ItemAugmentQuery) IDs(ctx context.Context) (ids []string, err error)

IDs executes the query and returns a list of ItemAugment IDs.

func (*ItemAugmentQuery) IDsX

func (_q *ItemAugmentQuery) IDsX(ctx context.Context) []string

IDsX is like IDs, but panics if an error occurs.

func (*ItemAugmentQuery) Limit

func (_q *ItemAugmentQuery) Limit(limit int) *ItemAugmentQuery

Limit the number of records to be returned by this query.

func (*ItemAugmentQuery) Offset

func (_q *ItemAugmentQuery) Offset(offset int) *ItemAugmentQuery

Offset to start from.

func (*ItemAugmentQuery) Only

func (_q *ItemAugmentQuery) Only(ctx context.Context) (*ItemAugment, error)

Only returns a single ItemAugment entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one ItemAugment entity is found. Returns a *NotFoundError when no ItemAugment entities are found.

func (*ItemAugmentQuery) OnlyID

func (_q *ItemAugmentQuery) OnlyID(ctx context.Context) (id string, err error)

OnlyID is like Only, but returns the only ItemAugment ID in the query. Returns a *NotSingularError when more than one ItemAugment ID is found. Returns a *NotFoundError when no entities are found.

func (*ItemAugmentQuery) OnlyIDX

func (_q *ItemAugmentQuery) OnlyIDX(ctx context.Context) string

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*ItemAugmentQuery) OnlyX

func (_q *ItemAugmentQuery) OnlyX(ctx context.Context) *ItemAugment

OnlyX is like Only, but panics if an error occurs.

func (*ItemAugmentQuery) Order

Order specifies how the records should be ordered.

func (*ItemAugmentQuery) Select

func (_q *ItemAugmentQuery) Select(fields ...string) *ItemAugmentSelect

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	Provider string `json:"provider,omitempty"`
}

client.ItemAugment.Query().
	Select(itemaugment.FieldProvider).
	Scan(ctx, &v)

func (*ItemAugmentQuery) Unique

func (_q *ItemAugmentQuery) Unique(unique bool) *ItemAugmentQuery

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*ItemAugmentQuery) Where

Where adds a new predicate for the ItemAugmentQuery builder.

type ItemAugmentSelect

type ItemAugmentSelect struct {
	*ItemAugmentQuery
	// contains filtered or unexported fields
}

ItemAugmentSelect is the builder for selecting fields of ItemAugment entities.

func (*ItemAugmentSelect) Aggregate

func (_s *ItemAugmentSelect) Aggregate(fns ...AggregateFunc) *ItemAugmentSelect

Aggregate adds the given aggregation functions to the selector query.

func (*ItemAugmentSelect) Bool

func (s *ItemAugmentSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*ItemAugmentSelect) BoolX

func (s *ItemAugmentSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*ItemAugmentSelect) Bools

func (s *ItemAugmentSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*ItemAugmentSelect) BoolsX

func (s *ItemAugmentSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*ItemAugmentSelect) Float64

func (s *ItemAugmentSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*ItemAugmentSelect) Float64X

func (s *ItemAugmentSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*ItemAugmentSelect) Float64s

func (s *ItemAugmentSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*ItemAugmentSelect) Float64sX

func (s *ItemAugmentSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*ItemAugmentSelect) Int

func (s *ItemAugmentSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*ItemAugmentSelect) IntX

func (s *ItemAugmentSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*ItemAugmentSelect) Ints

func (s *ItemAugmentSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*ItemAugmentSelect) IntsX

func (s *ItemAugmentSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*ItemAugmentSelect) Scan

func (_s *ItemAugmentSelect) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*ItemAugmentSelect) ScanX

func (s *ItemAugmentSelect) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*ItemAugmentSelect) String

func (s *ItemAugmentSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*ItemAugmentSelect) StringX

func (s *ItemAugmentSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*ItemAugmentSelect) Strings

func (s *ItemAugmentSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*ItemAugmentSelect) StringsX

func (s *ItemAugmentSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type ItemAugmentUpdate

type ItemAugmentUpdate struct {
	// contains filtered or unexported fields
}

ItemAugmentUpdate is the builder for updating ItemAugment entities.

func (*ItemAugmentUpdate) AppendOkrRefs

func (_u *ItemAugmentUpdate) AppendOkrRefs(v []string) *ItemAugmentUpdate

AppendOkrRefs appends value to the "okr_refs" field.

func (*ItemAugmentUpdate) ClearKano

func (_u *ItemAugmentUpdate) ClearKano() *ItemAugmentUpdate

ClearKano clears the value of the "kano" field.

func (*ItemAugmentUpdate) ClearMetadata

func (_u *ItemAugmentUpdate) ClearMetadata() *ItemAugmentUpdate

ClearMetadata clears the value of the "metadata" field.

func (*ItemAugmentUpdate) ClearMoscow

func (_u *ItemAugmentUpdate) ClearMoscow() *ItemAugmentUpdate

ClearMoscow clears the value of the "moscow" field.

func (*ItemAugmentUpdate) ClearNotes

func (_u *ItemAugmentUpdate) ClearNotes() *ItemAugmentUpdate

ClearNotes clears the value of the "notes" field.

func (*ItemAugmentUpdate) ClearOkrRefs

func (_u *ItemAugmentUpdate) ClearOkrRefs() *ItemAugmentUpdate

ClearOkrRefs clears the value of the "okr_refs" field.

func (*ItemAugmentUpdate) ClearRice

func (_u *ItemAugmentUpdate) ClearRice() *ItemAugmentUpdate

ClearRice clears the value of the "rice" field.

func (*ItemAugmentUpdate) Exec

func (_u *ItemAugmentUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*ItemAugmentUpdate) ExecX

func (_u *ItemAugmentUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ItemAugmentUpdate) Mutation

func (_u *ItemAugmentUpdate) Mutation() *ItemAugmentMutation

Mutation returns the ItemAugmentMutation object of the builder.

func (*ItemAugmentUpdate) Save

func (_u *ItemAugmentUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*ItemAugmentUpdate) SaveX

func (_u *ItemAugmentUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*ItemAugmentUpdate) SetKano

func (_u *ItemAugmentUpdate) SetKano(v string) *ItemAugmentUpdate

SetKano sets the "kano" field.

func (*ItemAugmentUpdate) SetMetadata

func (_u *ItemAugmentUpdate) SetMetadata(v map[string]interface{}) *ItemAugmentUpdate

SetMetadata sets the "metadata" field.

func (*ItemAugmentUpdate) SetMoscow

func (_u *ItemAugmentUpdate) SetMoscow(v string) *ItemAugmentUpdate

SetMoscow sets the "moscow" field.

func (*ItemAugmentUpdate) SetNillableKano

func (_u *ItemAugmentUpdate) SetNillableKano(v *string) *ItemAugmentUpdate

SetNillableKano sets the "kano" field if the given value is not nil.

func (*ItemAugmentUpdate) SetNillableMoscow

func (_u *ItemAugmentUpdate) SetNillableMoscow(v *string) *ItemAugmentUpdate

SetNillableMoscow sets the "moscow" field if the given value is not nil.

func (*ItemAugmentUpdate) SetNillableNotes

func (_u *ItemAugmentUpdate) SetNillableNotes(v *string) *ItemAugmentUpdate

SetNillableNotes sets the "notes" field if the given value is not nil.

func (*ItemAugmentUpdate) SetNillableProvider

func (_u *ItemAugmentUpdate) SetNillableProvider(v *string) *ItemAugmentUpdate

SetNillableProvider sets the "provider" field if the given value is not nil.

func (*ItemAugmentUpdate) SetNillableSourceRef

func (_u *ItemAugmentUpdate) SetNillableSourceRef(v *string) *ItemAugmentUpdate

SetNillableSourceRef sets the "source_ref" field if the given value is not nil.

func (*ItemAugmentUpdate) SetNillableUpdatedAt

func (_u *ItemAugmentUpdate) SetNillableUpdatedAt(v *time.Time) *ItemAugmentUpdate

SetNillableUpdatedAt sets the "updated_at" field if the given value is not nil.

func (*ItemAugmentUpdate) SetNotes

func (_u *ItemAugmentUpdate) SetNotes(v string) *ItemAugmentUpdate

SetNotes sets the "notes" field.

func (*ItemAugmentUpdate) SetOkrRefs

func (_u *ItemAugmentUpdate) SetOkrRefs(v []string) *ItemAugmentUpdate

SetOkrRefs sets the "okr_refs" field.

func (*ItemAugmentUpdate) SetProvider

func (_u *ItemAugmentUpdate) SetProvider(v string) *ItemAugmentUpdate

SetProvider sets the "provider" field.

func (*ItemAugmentUpdate) SetRice

func (_u *ItemAugmentUpdate) SetRice(v map[string]float64) *ItemAugmentUpdate

SetRice sets the "rice" field.

func (*ItemAugmentUpdate) SetSourceRef

func (_u *ItemAugmentUpdate) SetSourceRef(v string) *ItemAugmentUpdate

SetSourceRef sets the "source_ref" field.

func (*ItemAugmentUpdate) SetUpdatedAt

func (_u *ItemAugmentUpdate) SetUpdatedAt(v time.Time) *ItemAugmentUpdate

SetUpdatedAt sets the "updated_at" field.

func (*ItemAugmentUpdate) Where

Where appends a list predicates to the ItemAugmentUpdate builder.

type ItemAugmentUpdateOne

type ItemAugmentUpdateOne struct {
	// contains filtered or unexported fields
}

ItemAugmentUpdateOne is the builder for updating a single ItemAugment entity.

func (*ItemAugmentUpdateOne) AppendOkrRefs

func (_u *ItemAugmentUpdateOne) AppendOkrRefs(v []string) *ItemAugmentUpdateOne

AppendOkrRefs appends value to the "okr_refs" field.

func (*ItemAugmentUpdateOne) ClearKano

func (_u *ItemAugmentUpdateOne) ClearKano() *ItemAugmentUpdateOne

ClearKano clears the value of the "kano" field.

func (*ItemAugmentUpdateOne) ClearMetadata

func (_u *ItemAugmentUpdateOne) ClearMetadata() *ItemAugmentUpdateOne

ClearMetadata clears the value of the "metadata" field.

func (*ItemAugmentUpdateOne) ClearMoscow

func (_u *ItemAugmentUpdateOne) ClearMoscow() *ItemAugmentUpdateOne

ClearMoscow clears the value of the "moscow" field.

func (*ItemAugmentUpdateOne) ClearNotes

func (_u *ItemAugmentUpdateOne) ClearNotes() *ItemAugmentUpdateOne

ClearNotes clears the value of the "notes" field.

func (*ItemAugmentUpdateOne) ClearOkrRefs

func (_u *ItemAugmentUpdateOne) ClearOkrRefs() *ItemAugmentUpdateOne

ClearOkrRefs clears the value of the "okr_refs" field.

func (*ItemAugmentUpdateOne) ClearRice

func (_u *ItemAugmentUpdateOne) ClearRice() *ItemAugmentUpdateOne

ClearRice clears the value of the "rice" field.

func (*ItemAugmentUpdateOne) Exec

func (_u *ItemAugmentUpdateOne) Exec(ctx context.Context) error

Exec executes the query on the entity.

func (*ItemAugmentUpdateOne) ExecX

func (_u *ItemAugmentUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ItemAugmentUpdateOne) Mutation

func (_u *ItemAugmentUpdateOne) Mutation() *ItemAugmentMutation

Mutation returns the ItemAugmentMutation object of the builder.

func (*ItemAugmentUpdateOne) Save

Save executes the query and returns the updated ItemAugment entity.

func (*ItemAugmentUpdateOne) SaveX

SaveX is like Save, but panics if an error occurs.

func (*ItemAugmentUpdateOne) Select

func (_u *ItemAugmentUpdateOne) Select(field string, fields ...string) *ItemAugmentUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*ItemAugmentUpdateOne) SetKano

SetKano sets the "kano" field.

func (*ItemAugmentUpdateOne) SetMetadata

func (_u *ItemAugmentUpdateOne) SetMetadata(v map[string]interface{}) *ItemAugmentUpdateOne

SetMetadata sets the "metadata" field.

func (*ItemAugmentUpdateOne) SetMoscow

SetMoscow sets the "moscow" field.

func (*ItemAugmentUpdateOne) SetNillableKano

func (_u *ItemAugmentUpdateOne) SetNillableKano(v *string) *ItemAugmentUpdateOne

SetNillableKano sets the "kano" field if the given value is not nil.

func (*ItemAugmentUpdateOne) SetNillableMoscow

func (_u *ItemAugmentUpdateOne) SetNillableMoscow(v *string) *ItemAugmentUpdateOne

SetNillableMoscow sets the "moscow" field if the given value is not nil.

func (*ItemAugmentUpdateOne) SetNillableNotes

func (_u *ItemAugmentUpdateOne) SetNillableNotes(v *string) *ItemAugmentUpdateOne

SetNillableNotes sets the "notes" field if the given value is not nil.

func (*ItemAugmentUpdateOne) SetNillableProvider

func (_u *ItemAugmentUpdateOne) SetNillableProvider(v *string) *ItemAugmentUpdateOne

SetNillableProvider sets the "provider" field if the given value is not nil.

func (*ItemAugmentUpdateOne) SetNillableSourceRef

func (_u *ItemAugmentUpdateOne) SetNillableSourceRef(v *string) *ItemAugmentUpdateOne

SetNillableSourceRef sets the "source_ref" field if the given value is not nil.

func (*ItemAugmentUpdateOne) SetNillableUpdatedAt

func (_u *ItemAugmentUpdateOne) SetNillableUpdatedAt(v *time.Time) *ItemAugmentUpdateOne

SetNillableUpdatedAt sets the "updated_at" field if the given value is not nil.

func (*ItemAugmentUpdateOne) SetNotes

SetNotes sets the "notes" field.

func (*ItemAugmentUpdateOne) SetOkrRefs

func (_u *ItemAugmentUpdateOne) SetOkrRefs(v []string) *ItemAugmentUpdateOne

SetOkrRefs sets the "okr_refs" field.

func (*ItemAugmentUpdateOne) SetProvider

func (_u *ItemAugmentUpdateOne) SetProvider(v string) *ItemAugmentUpdateOne

SetProvider sets the "provider" field.

func (*ItemAugmentUpdateOne) SetRice

SetRice sets the "rice" field.

func (*ItemAugmentUpdateOne) SetSourceRef

func (_u *ItemAugmentUpdateOne) SetSourceRef(v string) *ItemAugmentUpdateOne

SetSourceRef sets the "source_ref" field.

func (*ItemAugmentUpdateOne) SetUpdatedAt

func (_u *ItemAugmentUpdateOne) SetUpdatedAt(v time.Time) *ItemAugmentUpdateOne

SetUpdatedAt sets the "updated_at" field.

func (*ItemAugmentUpdateOne) Where

Where appends a list predicates to the ItemAugmentUpdate builder.

type ItemAugmentUpsert

type ItemAugmentUpsert struct {
	*sql.UpdateSet
}

ItemAugmentUpsert is the "OnConflict" setter.

func (*ItemAugmentUpsert) ClearKano

func (u *ItemAugmentUpsert) ClearKano() *ItemAugmentUpsert

ClearKano clears the value of the "kano" field.

func (*ItemAugmentUpsert) ClearMetadata

func (u *ItemAugmentUpsert) ClearMetadata() *ItemAugmentUpsert

ClearMetadata clears the value of the "metadata" field.

func (*ItemAugmentUpsert) ClearMoscow

func (u *ItemAugmentUpsert) ClearMoscow() *ItemAugmentUpsert

ClearMoscow clears the value of the "moscow" field.

func (*ItemAugmentUpsert) ClearNotes

func (u *ItemAugmentUpsert) ClearNotes() *ItemAugmentUpsert

ClearNotes clears the value of the "notes" field.

func (*ItemAugmentUpsert) ClearOkrRefs

func (u *ItemAugmentUpsert) ClearOkrRefs() *ItemAugmentUpsert

ClearOkrRefs clears the value of the "okr_refs" field.

func (*ItemAugmentUpsert) ClearRice

func (u *ItemAugmentUpsert) ClearRice() *ItemAugmentUpsert

ClearRice clears the value of the "rice" field.

func (*ItemAugmentUpsert) SetKano

SetKano sets the "kano" field.

func (*ItemAugmentUpsert) SetMetadata

func (u *ItemAugmentUpsert) SetMetadata(v map[string]interface{}) *ItemAugmentUpsert

SetMetadata sets the "metadata" field.

func (*ItemAugmentUpsert) SetMoscow

func (u *ItemAugmentUpsert) SetMoscow(v string) *ItemAugmentUpsert

SetMoscow sets the "moscow" field.

func (*ItemAugmentUpsert) SetNotes

func (u *ItemAugmentUpsert) SetNotes(v string) *ItemAugmentUpsert

SetNotes sets the "notes" field.

func (*ItemAugmentUpsert) SetOkrRefs

func (u *ItemAugmentUpsert) SetOkrRefs(v []string) *ItemAugmentUpsert

SetOkrRefs sets the "okr_refs" field.

func (*ItemAugmentUpsert) SetProvider

func (u *ItemAugmentUpsert) SetProvider(v string) *ItemAugmentUpsert

SetProvider sets the "provider" field.

func (*ItemAugmentUpsert) SetRice

SetRice sets the "rice" field.

func (*ItemAugmentUpsert) SetSourceRef

func (u *ItemAugmentUpsert) SetSourceRef(v string) *ItemAugmentUpsert

SetSourceRef sets the "source_ref" field.

func (*ItemAugmentUpsert) SetUpdatedAt

func (u *ItemAugmentUpsert) SetUpdatedAt(v time.Time) *ItemAugmentUpsert

SetUpdatedAt sets the "updated_at" field.

func (*ItemAugmentUpsert) UpdateKano

func (u *ItemAugmentUpsert) UpdateKano() *ItemAugmentUpsert

UpdateKano sets the "kano" field to the value that was provided on create.

func (*ItemAugmentUpsert) UpdateMetadata

func (u *ItemAugmentUpsert) UpdateMetadata() *ItemAugmentUpsert

UpdateMetadata sets the "metadata" field to the value that was provided on create.

func (*ItemAugmentUpsert) UpdateMoscow

func (u *ItemAugmentUpsert) UpdateMoscow() *ItemAugmentUpsert

UpdateMoscow sets the "moscow" field to the value that was provided on create.

func (*ItemAugmentUpsert) UpdateNotes

func (u *ItemAugmentUpsert) UpdateNotes() *ItemAugmentUpsert

UpdateNotes sets the "notes" field to the value that was provided on create.

func (*ItemAugmentUpsert) UpdateOkrRefs

func (u *ItemAugmentUpsert) UpdateOkrRefs() *ItemAugmentUpsert

UpdateOkrRefs sets the "okr_refs" field to the value that was provided on create.

func (*ItemAugmentUpsert) UpdateProvider

func (u *ItemAugmentUpsert) UpdateProvider() *ItemAugmentUpsert

UpdateProvider sets the "provider" field to the value that was provided on create.

func (*ItemAugmentUpsert) UpdateRice

func (u *ItemAugmentUpsert) UpdateRice() *ItemAugmentUpsert

UpdateRice sets the "rice" field to the value that was provided on create.

func (*ItemAugmentUpsert) UpdateSourceRef

func (u *ItemAugmentUpsert) UpdateSourceRef() *ItemAugmentUpsert

UpdateSourceRef sets the "source_ref" field to the value that was provided on create.

func (*ItemAugmentUpsert) UpdateUpdatedAt

func (u *ItemAugmentUpsert) UpdateUpdatedAt() *ItemAugmentUpsert

UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.

type ItemAugmentUpsertBulk

type ItemAugmentUpsertBulk struct {
	// contains filtered or unexported fields
}

ItemAugmentUpsertBulk is the builder for "upsert"-ing a bulk of ItemAugment nodes.

func (*ItemAugmentUpsertBulk) ClearKano

ClearKano clears the value of the "kano" field.

func (*ItemAugmentUpsertBulk) ClearMetadata

func (u *ItemAugmentUpsertBulk) ClearMetadata() *ItemAugmentUpsertBulk

ClearMetadata clears the value of the "metadata" field.

func (*ItemAugmentUpsertBulk) ClearMoscow

func (u *ItemAugmentUpsertBulk) ClearMoscow() *ItemAugmentUpsertBulk

ClearMoscow clears the value of the "moscow" field.

func (*ItemAugmentUpsertBulk) ClearNotes

ClearNotes clears the value of the "notes" field.

func (*ItemAugmentUpsertBulk) ClearOkrRefs

func (u *ItemAugmentUpsertBulk) ClearOkrRefs() *ItemAugmentUpsertBulk

ClearOkrRefs clears the value of the "okr_refs" field.

func (*ItemAugmentUpsertBulk) ClearRice

ClearRice clears the value of the "rice" field.

func (*ItemAugmentUpsertBulk) DoNothing

DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.

func (*ItemAugmentUpsertBulk) Exec

Exec executes the query.

func (*ItemAugmentUpsertBulk) ExecX

func (u *ItemAugmentUpsertBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ItemAugmentUpsertBulk) Ignore

Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:

client.ItemAugment.Create().
	OnConflict(sql.ResolveWithIgnore()).
	Exec(ctx)

func (*ItemAugmentUpsertBulk) SetKano

SetKano sets the "kano" field.

func (*ItemAugmentUpsertBulk) SetMetadata

func (u *ItemAugmentUpsertBulk) SetMetadata(v map[string]interface{}) *ItemAugmentUpsertBulk

SetMetadata sets the "metadata" field.

func (*ItemAugmentUpsertBulk) SetMoscow

SetMoscow sets the "moscow" field.

func (*ItemAugmentUpsertBulk) SetNotes

SetNotes sets the "notes" field.

func (*ItemAugmentUpsertBulk) SetOkrRefs

SetOkrRefs sets the "okr_refs" field.

func (*ItemAugmentUpsertBulk) SetProvider

SetProvider sets the "provider" field.

func (*ItemAugmentUpsertBulk) SetRice

SetRice sets the "rice" field.

func (*ItemAugmentUpsertBulk) SetSourceRef

SetSourceRef sets the "source_ref" field.

func (*ItemAugmentUpsertBulk) SetUpdatedAt

SetUpdatedAt sets the "updated_at" field.

func (*ItemAugmentUpsertBulk) Update

Update allows overriding fields `UPDATE` values. See the ItemAugmentCreateBulk.OnConflict documentation for more info.

func (*ItemAugmentUpsertBulk) UpdateKano

UpdateKano sets the "kano" field to the value that was provided on create.

func (*ItemAugmentUpsertBulk) UpdateMetadata

func (u *ItemAugmentUpsertBulk) UpdateMetadata() *ItemAugmentUpsertBulk

UpdateMetadata sets the "metadata" field to the value that was provided on create.

func (*ItemAugmentUpsertBulk) UpdateMoscow

func (u *ItemAugmentUpsertBulk) UpdateMoscow() *ItemAugmentUpsertBulk

UpdateMoscow sets the "moscow" field to the value that was provided on create.

func (*ItemAugmentUpsertBulk) UpdateNewValues

func (u *ItemAugmentUpsertBulk) UpdateNewValues() *ItemAugmentUpsertBulk

UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:

client.ItemAugment.Create().
	OnConflict(
		sql.ResolveWithNewValues(),
		sql.ResolveWith(func(u *sql.UpdateSet) {
			u.SetIgnore(itemaugment.FieldID)
		}),
	).
	Exec(ctx)

func (*ItemAugmentUpsertBulk) UpdateNotes

func (u *ItemAugmentUpsertBulk) UpdateNotes() *ItemAugmentUpsertBulk

UpdateNotes sets the "notes" field to the value that was provided on create.

func (*ItemAugmentUpsertBulk) UpdateOkrRefs

func (u *ItemAugmentUpsertBulk) UpdateOkrRefs() *ItemAugmentUpsertBulk

UpdateOkrRefs sets the "okr_refs" field to the value that was provided on create.

func (*ItemAugmentUpsertBulk) UpdateProvider

func (u *ItemAugmentUpsertBulk) UpdateProvider() *ItemAugmentUpsertBulk

UpdateProvider sets the "provider" field to the value that was provided on create.

func (*ItemAugmentUpsertBulk) UpdateRice

UpdateRice sets the "rice" field to the value that was provided on create.

func (*ItemAugmentUpsertBulk) UpdateSourceRef

func (u *ItemAugmentUpsertBulk) UpdateSourceRef() *ItemAugmentUpsertBulk

UpdateSourceRef sets the "source_ref" field to the value that was provided on create.

func (*ItemAugmentUpsertBulk) UpdateUpdatedAt

func (u *ItemAugmentUpsertBulk) UpdateUpdatedAt() *ItemAugmentUpsertBulk

UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.

type ItemAugmentUpsertOne

type ItemAugmentUpsertOne struct {
	// contains filtered or unexported fields
}

ItemAugmentUpsertOne is the builder for "upsert"-ing

one ItemAugment node.

func (*ItemAugmentUpsertOne) ClearKano

ClearKano clears the value of the "kano" field.

func (*ItemAugmentUpsertOne) ClearMetadata

func (u *ItemAugmentUpsertOne) ClearMetadata() *ItemAugmentUpsertOne

ClearMetadata clears the value of the "metadata" field.

func (*ItemAugmentUpsertOne) ClearMoscow

func (u *ItemAugmentUpsertOne) ClearMoscow() *ItemAugmentUpsertOne

ClearMoscow clears the value of the "moscow" field.

func (*ItemAugmentUpsertOne) ClearNotes

func (u *ItemAugmentUpsertOne) ClearNotes() *ItemAugmentUpsertOne

ClearNotes clears the value of the "notes" field.

func (*ItemAugmentUpsertOne) ClearOkrRefs

func (u *ItemAugmentUpsertOne) ClearOkrRefs() *ItemAugmentUpsertOne

ClearOkrRefs clears the value of the "okr_refs" field.

func (*ItemAugmentUpsertOne) ClearRice

ClearRice clears the value of the "rice" field.

func (*ItemAugmentUpsertOne) DoNothing

DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.

func (*ItemAugmentUpsertOne) Exec

Exec executes the query.

func (*ItemAugmentUpsertOne) ExecX

func (u *ItemAugmentUpsertOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ItemAugmentUpsertOne) ID

func (u *ItemAugmentUpsertOne) ID(ctx context.Context) (id string, err error)

Exec executes the UPSERT query and returns the inserted/updated ID.

func (*ItemAugmentUpsertOne) IDX

IDX is like ID, but panics if an error occurs.

func (*ItemAugmentUpsertOne) Ignore

Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:

client.ItemAugment.Create().
    OnConflict(sql.ResolveWithIgnore()).
    Exec(ctx)

func (*ItemAugmentUpsertOne) SetKano

SetKano sets the "kano" field.

func (*ItemAugmentUpsertOne) SetMetadata

func (u *ItemAugmentUpsertOne) SetMetadata(v map[string]interface{}) *ItemAugmentUpsertOne

SetMetadata sets the "metadata" field.

func (*ItemAugmentUpsertOne) SetMoscow

SetMoscow sets the "moscow" field.

func (*ItemAugmentUpsertOne) SetNotes

SetNotes sets the "notes" field.

func (*ItemAugmentUpsertOne) SetOkrRefs

func (u *ItemAugmentUpsertOne) SetOkrRefs(v []string) *ItemAugmentUpsertOne

SetOkrRefs sets the "okr_refs" field.

func (*ItemAugmentUpsertOne) SetProvider

SetProvider sets the "provider" field.

func (*ItemAugmentUpsertOne) SetRice

SetRice sets the "rice" field.

func (*ItemAugmentUpsertOne) SetSourceRef

func (u *ItemAugmentUpsertOne) SetSourceRef(v string) *ItemAugmentUpsertOne

SetSourceRef sets the "source_ref" field.

func (*ItemAugmentUpsertOne) SetUpdatedAt

func (u *ItemAugmentUpsertOne) SetUpdatedAt(v time.Time) *ItemAugmentUpsertOne

SetUpdatedAt sets the "updated_at" field.

func (*ItemAugmentUpsertOne) Update

Update allows overriding fields `UPDATE` values. See the ItemAugmentCreate.OnConflict documentation for more info.

func (*ItemAugmentUpsertOne) UpdateKano

func (u *ItemAugmentUpsertOne) UpdateKano() *ItemAugmentUpsertOne

UpdateKano sets the "kano" field to the value that was provided on create.

func (*ItemAugmentUpsertOne) UpdateMetadata

func (u *ItemAugmentUpsertOne) UpdateMetadata() *ItemAugmentUpsertOne

UpdateMetadata sets the "metadata" field to the value that was provided on create.

func (*ItemAugmentUpsertOne) UpdateMoscow

func (u *ItemAugmentUpsertOne) UpdateMoscow() *ItemAugmentUpsertOne

UpdateMoscow sets the "moscow" field to the value that was provided on create.

func (*ItemAugmentUpsertOne) UpdateNewValues

func (u *ItemAugmentUpsertOne) UpdateNewValues() *ItemAugmentUpsertOne

UpdateNewValues updates the mutable fields using the new values that were set on create except the ID field. Using this option is equivalent to using:

client.ItemAugment.Create().
	OnConflict(
		sql.ResolveWithNewValues(),
		sql.ResolveWith(func(u *sql.UpdateSet) {
			u.SetIgnore(itemaugment.FieldID)
		}),
	).
	Exec(ctx)

func (*ItemAugmentUpsertOne) UpdateNotes

func (u *ItemAugmentUpsertOne) UpdateNotes() *ItemAugmentUpsertOne

UpdateNotes sets the "notes" field to the value that was provided on create.

func (*ItemAugmentUpsertOne) UpdateOkrRefs

func (u *ItemAugmentUpsertOne) UpdateOkrRefs() *ItemAugmentUpsertOne

UpdateOkrRefs sets the "okr_refs" field to the value that was provided on create.

func (*ItemAugmentUpsertOne) UpdateProvider

func (u *ItemAugmentUpsertOne) UpdateProvider() *ItemAugmentUpsertOne

UpdateProvider sets the "provider" field to the value that was provided on create.

func (*ItemAugmentUpsertOne) UpdateRice

func (u *ItemAugmentUpsertOne) UpdateRice() *ItemAugmentUpsertOne

UpdateRice sets the "rice" field to the value that was provided on create.

func (*ItemAugmentUpsertOne) UpdateSourceRef

func (u *ItemAugmentUpsertOne) UpdateSourceRef() *ItemAugmentUpsertOne

UpdateSourceRef sets the "source_ref" field to the value that was provided on create.

func (*ItemAugmentUpsertOne) UpdateUpdatedAt

func (u *ItemAugmentUpsertOne) UpdateUpdatedAt() *ItemAugmentUpsertOne

UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.

type ItemAugments

type ItemAugments []*ItemAugment

ItemAugments is a parsable slice of ItemAugment.

type ItemClient

type ItemClient struct {
	// contains filtered or unexported fields
}

ItemClient is a client for the Item schema.

func NewItemClient

func NewItemClient(c config) *ItemClient

NewItemClient returns a client for the Item from the given config.

func (*ItemClient) Create

func (c *ItemClient) Create() *ItemCreate

Create returns a builder for creating a Item entity.

func (*ItemClient) CreateBulk

func (c *ItemClient) CreateBulk(builders ...*ItemCreate) *ItemCreateBulk

CreateBulk returns a builder for creating a bulk of Item entities.

func (*ItemClient) Delete

func (c *ItemClient) Delete() *ItemDelete

Delete returns a delete builder for Item.

func (*ItemClient) DeleteOne

func (c *ItemClient) DeleteOne(_m *Item) *ItemDeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*ItemClient) DeleteOneID

func (c *ItemClient) DeleteOneID(id string) *ItemDeleteOne

DeleteOneID returns a builder for deleting the given entity by its id.

func (*ItemClient) Get

func (c *ItemClient) Get(ctx context.Context, id string) (*Item, error)

Get returns a Item entity by its id.

func (*ItemClient) GetX

func (c *ItemClient) GetX(ctx context.Context, id string) *Item

GetX is like Get, but panics if an error occurs.

func (*ItemClient) Hooks

func (c *ItemClient) Hooks() []Hook

Hooks returns the client hooks.

func (*ItemClient) Intercept

func (c *ItemClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `item.Intercept(f(g(h())))`.

func (*ItemClient) Interceptors

func (c *ItemClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*ItemClient) MapCreateBulk

func (c *ItemClient) MapCreateBulk(slice any, setFunc func(*ItemCreate, int)) *ItemCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*ItemClient) Query

func (c *ItemClient) Query() *ItemQuery

Query returns a query builder for Item.

func (*ItemClient) Update

func (c *ItemClient) Update() *ItemUpdate

Update returns an update builder for Item.

func (*ItemClient) UpdateOne

func (c *ItemClient) UpdateOne(_m *Item) *ItemUpdateOne

UpdateOne returns an update builder for the given entity.

func (*ItemClient) UpdateOneID

func (c *ItemClient) UpdateOneID(id string) *ItemUpdateOne

UpdateOneID returns an update builder for the given id.

func (*ItemClient) Use

func (c *ItemClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `item.Hooks(f(g(h())))`.

type ItemCreate

type ItemCreate struct {
	// contains filtered or unexported fields
}

ItemCreate is the builder for creating a Item entity.

func (*ItemCreate) Exec

func (_c *ItemCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*ItemCreate) ExecX

func (_c *ItemCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ItemCreate) Mutation

func (_c *ItemCreate) Mutation() *ItemMutation

Mutation returns the ItemMutation object of the builder.

func (*ItemCreate) OnConflict

func (_c *ItemCreate) OnConflict(opts ...sql.ConflictOption) *ItemUpsertOne

OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:

client.Item.Create().
	SetProvider(v).
	OnConflict(
		// Update the row with the new values
		// the was proposed for insertion.
		sql.ResolveWithNewValues(),
	).
	// Override some of the fields with custom
	// update values.
	Update(func(u *ent.ItemUpsert) {
		SetProvider(v+v).
	}).
	Exec(ctx)

func (*ItemCreate) OnConflictColumns

func (_c *ItemCreate) OnConflictColumns(columns ...string) *ItemUpsertOne

OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:

client.Item.Create().
	OnConflict(sql.ConflictColumns(columns...)).
	Exec(ctx)

func (*ItemCreate) Save

func (_c *ItemCreate) Save(ctx context.Context) (*Item, error)

Save creates the Item in the database.

func (*ItemCreate) SaveX

func (_c *ItemCreate) SaveX(ctx context.Context) *Item

SaveX calls Save and panics if Save returns an error.

func (*ItemCreate) SetCreatedAt

func (_c *ItemCreate) SetCreatedAt(v time.Time) *ItemCreate

SetCreatedAt sets the "created_at" field.

func (*ItemCreate) SetCustomFields

func (_c *ItemCreate) SetCustomFields(v []map[string]interface{}) *ItemCreate

SetCustomFields sets the "custom_fields" field.

func (*ItemCreate) SetDescription

func (_c *ItemCreate) SetDescription(v string) *ItemCreate

SetDescription sets the "description" field.

func (*ItemCreate) SetDueDate

func (_c *ItemCreate) SetDueDate(v time.Time) *ItemCreate

SetDueDate sets the "due_date" field.

func (*ItemCreate) SetID

func (_c *ItemCreate) SetID(v string) *ItemCreate

SetID sets the "id" field.

func (*ItemCreate) SetKano

func (_c *ItemCreate) SetKano(v string) *ItemCreate

SetKano sets the "kano" field.

func (*ItemCreate) SetKind

func (_c *ItemCreate) SetKind(v string) *ItemCreate

SetKind sets the "kind" field.

func (*ItemCreate) SetMetadata

func (_c *ItemCreate) SetMetadata(v map[string]interface{}) *ItemCreate

SetMetadata sets the "metadata" field.

func (*ItemCreate) SetMoscow

func (_c *ItemCreate) SetMoscow(v string) *ItemCreate

SetMoscow sets the "moscow" field.

func (*ItemCreate) SetName

func (_c *ItemCreate) SetName(v string) *ItemCreate

SetName sets the "name" field.

func (*ItemCreate) SetNillableCreatedAt

func (_c *ItemCreate) SetNillableCreatedAt(v *time.Time) *ItemCreate

SetNillableCreatedAt sets the "created_at" field if the given value is not nil.

func (*ItemCreate) SetNillableDescription

func (_c *ItemCreate) SetNillableDescription(v *string) *ItemCreate

SetNillableDescription sets the "description" field if the given value is not nil.

func (*ItemCreate) SetNillableDueDate

func (_c *ItemCreate) SetNillableDueDate(v *time.Time) *ItemCreate

SetNillableDueDate sets the "due_date" field if the given value is not nil.

func (*ItemCreate) SetNillableKano

func (_c *ItemCreate) SetNillableKano(v *string) *ItemCreate

SetNillableKano sets the "kano" field if the given value is not nil.

func (*ItemCreate) SetNillableMoscow

func (_c *ItemCreate) SetNillableMoscow(v *string) *ItemCreate

SetNillableMoscow sets the "moscow" field if the given value is not nil.

func (*ItemCreate) SetNillableName

func (_c *ItemCreate) SetNillableName(v *string) *ItemCreate

SetNillableName sets the "name" field if the given value is not nil.

func (*ItemCreate) SetNillableOwnerEmail

func (_c *ItemCreate) SetNillableOwnerEmail(v *string) *ItemCreate

SetNillableOwnerEmail sets the "owner_email" field if the given value is not nil.

func (*ItemCreate) SetNillableOwnerID

func (_c *ItemCreate) SetNillableOwnerID(v *string) *ItemCreate

SetNillableOwnerID sets the "owner_id" field if the given value is not nil.

func (*ItemCreate) SetNillableOwnerName

func (_c *ItemCreate) SetNillableOwnerName(v *string) *ItemCreate

SetNillableOwnerName sets the "owner_name" field if the given value is not nil.

func (*ItemCreate) SetNillableParentID

func (_c *ItemCreate) SetNillableParentID(v *string) *ItemCreate

SetNillableParentID sets the "parent_id" field if the given value is not nil.

func (*ItemCreate) SetNillableProgress

func (_c *ItemCreate) SetNillableProgress(v *float64) *ItemCreate

SetNillableProgress sets the "progress" field if the given value is not nil.

func (*ItemCreate) SetNillableReleaseID

func (_c *ItemCreate) SetNillableReleaseID(v *string) *ItemCreate

SetNillableReleaseID sets the "release_id" field if the given value is not nil.

func (*ItemCreate) SetNillableSourceRef

func (_c *ItemCreate) SetNillableSourceRef(v *string) *ItemCreate

SetNillableSourceRef sets the "source_ref" field if the given value is not nil.

func (*ItemCreate) SetNillableSourceURL

func (_c *ItemCreate) SetNillableSourceURL(v *string) *ItemCreate

SetNillableSourceURL sets the "source_url" field if the given value is not nil.

func (*ItemCreate) SetNillableStartDate

func (_c *ItemCreate) SetNillableStartDate(v *time.Time) *ItemCreate

SetNillableStartDate sets the "start_date" field if the given value is not nil.

func (*ItemCreate) SetNillableStatusCategory

func (_c *ItemCreate) SetNillableStatusCategory(v *string) *ItemCreate

SetNillableStatusCategory sets the "status_category" field if the given value is not nil.

func (*ItemCreate) SetNillableStatusComplete

func (_c *ItemCreate) SetNillableStatusComplete(v *bool) *ItemCreate

SetNillableStatusComplete sets the "status_complete" field if the given value is not nil.

func (*ItemCreate) SetNillableStatusID

func (_c *ItemCreate) SetNillableStatusID(v *string) *ItemCreate

SetNillableStatusID sets the "status_id" field if the given value is not nil.

func (*ItemCreate) SetNillableStatusName

func (_c *ItemCreate) SetNillableStatusName(v *string) *ItemCreate

SetNillableStatusName sets the "status_name" field if the given value is not nil.

func (*ItemCreate) SetNillableSyncedAt

func (_c *ItemCreate) SetNillableSyncedAt(v *time.Time) *ItemCreate

SetNillableSyncedAt sets the "synced_at" field if the given value is not nil.

func (*ItemCreate) SetNillableUpdatedAt

func (_c *ItemCreate) SetNillableUpdatedAt(v *time.Time) *ItemCreate

SetNillableUpdatedAt sets the "updated_at" field if the given value is not nil.

func (*ItemCreate) SetNillableWorkspaceRef

func (_c *ItemCreate) SetNillableWorkspaceRef(v *string) *ItemCreate

SetNillableWorkspaceRef sets the "workspace_ref" field if the given value is not nil.

func (*ItemCreate) SetOwnerEmail

func (_c *ItemCreate) SetOwnerEmail(v string) *ItemCreate

SetOwnerEmail sets the "owner_email" field.

func (*ItemCreate) SetOwnerID

func (_c *ItemCreate) SetOwnerID(v string) *ItemCreate

SetOwnerID sets the "owner_id" field.

func (*ItemCreate) SetOwnerName

func (_c *ItemCreate) SetOwnerName(v string) *ItemCreate

SetOwnerName sets the "owner_name" field.

func (*ItemCreate) SetParentID

func (_c *ItemCreate) SetParentID(v string) *ItemCreate

SetParentID sets the "parent_id" field.

func (*ItemCreate) SetProgress

func (_c *ItemCreate) SetProgress(v float64) *ItemCreate

SetProgress sets the "progress" field.

func (*ItemCreate) SetProvider

func (_c *ItemCreate) SetProvider(v string) *ItemCreate

SetProvider sets the "provider" field.

func (*ItemCreate) SetReleaseID

func (_c *ItemCreate) SetReleaseID(v string) *ItemCreate

SetReleaseID sets the "release_id" field.

func (*ItemCreate) SetRice

func (_c *ItemCreate) SetRice(v map[string]float64) *ItemCreate

SetRice sets the "rice" field.

func (*ItemCreate) SetSourceID

func (_c *ItemCreate) SetSourceID(v string) *ItemCreate

SetSourceID sets the "source_id" field.

func (*ItemCreate) SetSourceRef

func (_c *ItemCreate) SetSourceRef(v string) *ItemCreate

SetSourceRef sets the "source_ref" field.

func (*ItemCreate) SetSourceURL

func (_c *ItemCreate) SetSourceURL(v string) *ItemCreate

SetSourceURL sets the "source_url" field.

func (*ItemCreate) SetStartDate

func (_c *ItemCreate) SetStartDate(v time.Time) *ItemCreate

SetStartDate sets the "start_date" field.

func (*ItemCreate) SetStatusCategory

func (_c *ItemCreate) SetStatusCategory(v string) *ItemCreate

SetStatusCategory sets the "status_category" field.

func (*ItemCreate) SetStatusComplete

func (_c *ItemCreate) SetStatusComplete(v bool) *ItemCreate

SetStatusComplete sets the "status_complete" field.

func (*ItemCreate) SetStatusID

func (_c *ItemCreate) SetStatusID(v string) *ItemCreate

SetStatusID sets the "status_id" field.

func (*ItemCreate) SetStatusName

func (_c *ItemCreate) SetStatusName(v string) *ItemCreate

SetStatusName sets the "status_name" field.

func (*ItemCreate) SetSyncedAt

func (_c *ItemCreate) SetSyncedAt(v time.Time) *ItemCreate

SetSyncedAt sets the "synced_at" field.

func (*ItemCreate) SetTags

func (_c *ItemCreate) SetTags(v []string) *ItemCreate

SetTags sets the "tags" field.

func (*ItemCreate) SetUpdatedAt

func (_c *ItemCreate) SetUpdatedAt(v time.Time) *ItemCreate

SetUpdatedAt sets the "updated_at" field.

func (*ItemCreate) SetWorkspaceRef

func (_c *ItemCreate) SetWorkspaceRef(v string) *ItemCreate

SetWorkspaceRef sets the "workspace_ref" field.

type ItemCreateBulk

type ItemCreateBulk struct {
	// contains filtered or unexported fields
}

ItemCreateBulk is the builder for creating many Item entities in bulk.

func (*ItemCreateBulk) Exec

func (_c *ItemCreateBulk) Exec(ctx context.Context) error

Exec executes the query.

func (*ItemCreateBulk) ExecX

func (_c *ItemCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ItemCreateBulk) OnConflict

func (_c *ItemCreateBulk) OnConflict(opts ...sql.ConflictOption) *ItemUpsertBulk

OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:

client.Item.CreateBulk(builders...).
	OnConflict(
		// Update the row with the new values
		// the was proposed for insertion.
		sql.ResolveWithNewValues(),
	).
	// Override some of the fields with custom
	// update values.
	Update(func(u *ent.ItemUpsert) {
		SetProvider(v+v).
	}).
	Exec(ctx)

func (*ItemCreateBulk) OnConflictColumns

func (_c *ItemCreateBulk) OnConflictColumns(columns ...string) *ItemUpsertBulk

OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:

client.Item.Create().
	OnConflict(sql.ConflictColumns(columns...)).
	Exec(ctx)

func (*ItemCreateBulk) Save

func (_c *ItemCreateBulk) Save(ctx context.Context) ([]*Item, error)

Save creates the Item entities in the database.

func (*ItemCreateBulk) SaveX

func (_c *ItemCreateBulk) SaveX(ctx context.Context) []*Item

SaveX is like Save, but panics if an error occurs.

type ItemDelete

type ItemDelete struct {
	// contains filtered or unexported fields
}

ItemDelete is the builder for deleting a Item entity.

func (*ItemDelete) Exec

func (_d *ItemDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*ItemDelete) ExecX

func (_d *ItemDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*ItemDelete) Where

func (_d *ItemDelete) Where(ps ...predicate.Item) *ItemDelete

Where appends a list predicates to the ItemDelete builder.

type ItemDeleteOne

type ItemDeleteOne struct {
	// contains filtered or unexported fields
}

ItemDeleteOne is the builder for deleting a single Item entity.

func (*ItemDeleteOne) Exec

func (_d *ItemDeleteOne) Exec(ctx context.Context) error

Exec executes the deletion query.

func (*ItemDeleteOne) ExecX

func (_d *ItemDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ItemDeleteOne) Where

func (_d *ItemDeleteOne) Where(ps ...predicate.Item) *ItemDeleteOne

Where appends a list predicates to the ItemDelete builder.

type ItemGroupBy

type ItemGroupBy struct {
	// contains filtered or unexported fields
}

ItemGroupBy is the group-by builder for Item entities.

func (*ItemGroupBy) Aggregate

func (_g *ItemGroupBy) Aggregate(fns ...AggregateFunc) *ItemGroupBy

Aggregate adds the given aggregation functions to the group-by query.

func (*ItemGroupBy) Bool

func (s *ItemGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*ItemGroupBy) BoolX

func (s *ItemGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*ItemGroupBy) Bools

func (s *ItemGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*ItemGroupBy) BoolsX

func (s *ItemGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*ItemGroupBy) Float64

func (s *ItemGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*ItemGroupBy) Float64X

func (s *ItemGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*ItemGroupBy) Float64s

func (s *ItemGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*ItemGroupBy) Float64sX

func (s *ItemGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*ItemGroupBy) Int

func (s *ItemGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*ItemGroupBy) IntX

func (s *ItemGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*ItemGroupBy) Ints

func (s *ItemGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*ItemGroupBy) IntsX

func (s *ItemGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*ItemGroupBy) Scan

func (_g *ItemGroupBy) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*ItemGroupBy) ScanX

func (s *ItemGroupBy) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*ItemGroupBy) String

func (s *ItemGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*ItemGroupBy) StringX

func (s *ItemGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*ItemGroupBy) Strings

func (s *ItemGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*ItemGroupBy) StringsX

func (s *ItemGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type ItemMutation

type ItemMutation struct {
	// contains filtered or unexported fields
}

ItemMutation represents an operation that mutates the Item nodes in the graph.

func (*ItemMutation) AddField

func (m *ItemMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*ItemMutation) AddProgress

func (m *ItemMutation) AddProgress(f float64)

AddProgress adds f to the "progress" field.

func (*ItemMutation) AddedEdges

func (m *ItemMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*ItemMutation) AddedField

func (m *ItemMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*ItemMutation) AddedFields

func (m *ItemMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*ItemMutation) AddedIDs

func (m *ItemMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*ItemMutation) AddedProgress

func (m *ItemMutation) AddedProgress() (r float64, exists bool)

AddedProgress returns the value that was added to the "progress" field in this mutation.

func (*ItemMutation) AppendCustomFields

func (m *ItemMutation) AppendCustomFields(value []map[string]interface{})

AppendCustomFields adds value to the "custom_fields" field.

func (*ItemMutation) AppendTags

func (m *ItemMutation) AppendTags(s []string)

AppendTags adds s to the "tags" field.

func (*ItemMutation) AppendedCustomFields

func (m *ItemMutation) AppendedCustomFields() ([]map[string]interface{}, bool)

AppendedCustomFields returns the list of values that were appended to the "custom_fields" field in this mutation.

func (*ItemMutation) AppendedTags

func (m *ItemMutation) AppendedTags() ([]string, bool)

AppendedTags returns the list of values that were appended to the "tags" field in this mutation.

func (*ItemMutation) ClearCreatedAt

func (m *ItemMutation) ClearCreatedAt()

ClearCreatedAt clears the value of the "created_at" field.

func (*ItemMutation) ClearCustomFields

func (m *ItemMutation) ClearCustomFields()

ClearCustomFields clears the value of the "custom_fields" field.

func (*ItemMutation) ClearDescription

func (m *ItemMutation) ClearDescription()

ClearDescription clears the value of the "description" field.

func (*ItemMutation) ClearDueDate

func (m *ItemMutation) ClearDueDate()

ClearDueDate clears the value of the "due_date" field.

func (*ItemMutation) ClearEdge

func (m *ItemMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*ItemMutation) ClearField

func (m *ItemMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*ItemMutation) ClearKano

func (m *ItemMutation) ClearKano()

ClearKano clears the value of the "kano" field.

func (*ItemMutation) ClearMetadata

func (m *ItemMutation) ClearMetadata()

ClearMetadata clears the value of the "metadata" field.

func (*ItemMutation) ClearMoscow

func (m *ItemMutation) ClearMoscow()

ClearMoscow clears the value of the "moscow" field.

func (*ItemMutation) ClearName

func (m *ItemMutation) ClearName()

ClearName clears the value of the "name" field.

func (*ItemMutation) ClearOwnerEmail

func (m *ItemMutation) ClearOwnerEmail()

ClearOwnerEmail clears the value of the "owner_email" field.

func (*ItemMutation) ClearOwnerID

func (m *ItemMutation) ClearOwnerID()

ClearOwnerID clears the value of the "owner_id" field.

func (*ItemMutation) ClearOwnerName

func (m *ItemMutation) ClearOwnerName()

ClearOwnerName clears the value of the "owner_name" field.

func (*ItemMutation) ClearParentID

func (m *ItemMutation) ClearParentID()

ClearParentID clears the value of the "parent_id" field.

func (*ItemMutation) ClearProgress

func (m *ItemMutation) ClearProgress()

ClearProgress clears the value of the "progress" field.

func (*ItemMutation) ClearReleaseID

func (m *ItemMutation) ClearReleaseID()

ClearReleaseID clears the value of the "release_id" field.

func (*ItemMutation) ClearRice

func (m *ItemMutation) ClearRice()

ClearRice clears the value of the "rice" field.

func (*ItemMutation) ClearSourceRef

func (m *ItemMutation) ClearSourceRef()

ClearSourceRef clears the value of the "source_ref" field.

func (*ItemMutation) ClearSourceURL

func (m *ItemMutation) ClearSourceURL()

ClearSourceURL clears the value of the "source_url" field.

func (*ItemMutation) ClearStartDate

func (m *ItemMutation) ClearStartDate()

ClearStartDate clears the value of the "start_date" field.

func (*ItemMutation) ClearStatusCategory

func (m *ItemMutation) ClearStatusCategory()

ClearStatusCategory clears the value of the "status_category" field.

func (*ItemMutation) ClearStatusID

func (m *ItemMutation) ClearStatusID()

ClearStatusID clears the value of the "status_id" field.

func (*ItemMutation) ClearStatusName

func (m *ItemMutation) ClearStatusName()

ClearStatusName clears the value of the "status_name" field.

func (*ItemMutation) ClearTags

func (m *ItemMutation) ClearTags()

ClearTags clears the value of the "tags" field.

func (*ItemMutation) ClearUpdatedAt

func (m *ItemMutation) ClearUpdatedAt()

ClearUpdatedAt clears the value of the "updated_at" field.

func (*ItemMutation) ClearWorkspaceRef

func (m *ItemMutation) ClearWorkspaceRef()

ClearWorkspaceRef clears the value of the "workspace_ref" field.

func (*ItemMutation) ClearedEdges

func (m *ItemMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*ItemMutation) ClearedFields

func (m *ItemMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (ItemMutation) Client

func (m ItemMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*ItemMutation) CreatedAt

func (m *ItemMutation) CreatedAt() (r time.Time, exists bool)

CreatedAt returns the value of the "created_at" field in the mutation.

func (*ItemMutation) CreatedAtCleared

func (m *ItemMutation) CreatedAtCleared() bool

CreatedAtCleared returns if the "created_at" field was cleared in this mutation.

func (*ItemMutation) CustomFields

func (m *ItemMutation) CustomFields() (r []map[string]interface{}, exists bool)

CustomFields returns the value of the "custom_fields" field in the mutation.

func (*ItemMutation) CustomFieldsCleared

func (m *ItemMutation) CustomFieldsCleared() bool

CustomFieldsCleared returns if the "custom_fields" field was cleared in this mutation.

func (*ItemMutation) Description

func (m *ItemMutation) Description() (r string, exists bool)

Description returns the value of the "description" field in the mutation.

func (*ItemMutation) DescriptionCleared

func (m *ItemMutation) DescriptionCleared() bool

DescriptionCleared returns if the "description" field was cleared in this mutation.

func (*ItemMutation) DueDate

func (m *ItemMutation) DueDate() (r time.Time, exists bool)

DueDate returns the value of the "due_date" field in the mutation.

func (*ItemMutation) DueDateCleared

func (m *ItemMutation) DueDateCleared() bool

DueDateCleared returns if the "due_date" field was cleared in this mutation.

func (*ItemMutation) EdgeCleared

func (m *ItemMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*ItemMutation) Field

func (m *ItemMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*ItemMutation) FieldCleared

func (m *ItemMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*ItemMutation) Fields

func (m *ItemMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*ItemMutation) ID

func (m *ItemMutation) ID() (id string, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*ItemMutation) IDs

func (m *ItemMutation) IDs(ctx context.Context) ([]string, error)

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*ItemMutation) Kano

func (m *ItemMutation) Kano() (r string, exists bool)

Kano returns the value of the "kano" field in the mutation.

func (*ItemMutation) KanoCleared

func (m *ItemMutation) KanoCleared() bool

KanoCleared returns if the "kano" field was cleared in this mutation.

func (*ItemMutation) Kind

func (m *ItemMutation) Kind() (r string, exists bool)

Kind returns the value of the "kind" field in the mutation.

func (*ItemMutation) Metadata

func (m *ItemMutation) Metadata() (r map[string]interface{}, exists bool)

Metadata returns the value of the "metadata" field in the mutation.

func (*ItemMutation) MetadataCleared

func (m *ItemMutation) MetadataCleared() bool

MetadataCleared returns if the "metadata" field was cleared in this mutation.

func (*ItemMutation) Moscow

func (m *ItemMutation) Moscow() (r string, exists bool)

Moscow returns the value of the "moscow" field in the mutation.

func (*ItemMutation) MoscowCleared

func (m *ItemMutation) MoscowCleared() bool

MoscowCleared returns if the "moscow" field was cleared in this mutation.

func (*ItemMutation) Name

func (m *ItemMutation) Name() (r string, exists bool)

Name returns the value of the "name" field in the mutation.

func (*ItemMutation) NameCleared

func (m *ItemMutation) NameCleared() bool

NameCleared returns if the "name" field was cleared in this mutation.

func (*ItemMutation) OldCreatedAt

func (m *ItemMutation) OldCreatedAt(ctx context.Context) (v *time.Time, err error)

OldCreatedAt returns the old "created_at" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) OldCustomFields

func (m *ItemMutation) OldCustomFields(ctx context.Context) (v []map[string]interface{}, err error)

OldCustomFields returns the old "custom_fields" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) OldDescription

func (m *ItemMutation) OldDescription(ctx context.Context) (v string, err error)

OldDescription returns the old "description" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) OldDueDate

func (m *ItemMutation) OldDueDate(ctx context.Context) (v *time.Time, err error)

OldDueDate returns the old "due_date" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) OldField

func (m *ItemMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*ItemMutation) OldKano

func (m *ItemMutation) OldKano(ctx context.Context) (v string, err error)

OldKano returns the old "kano" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) OldKind

func (m *ItemMutation) OldKind(ctx context.Context) (v string, err error)

OldKind returns the old "kind" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) OldMetadata

func (m *ItemMutation) OldMetadata(ctx context.Context) (v map[string]interface{}, err error)

OldMetadata returns the old "metadata" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) OldMoscow

func (m *ItemMutation) OldMoscow(ctx context.Context) (v string, err error)

OldMoscow returns the old "moscow" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) OldName

func (m *ItemMutation) OldName(ctx context.Context) (v string, err error)

OldName returns the old "name" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) OldOwnerEmail

func (m *ItemMutation) OldOwnerEmail(ctx context.Context) (v string, err error)

OldOwnerEmail returns the old "owner_email" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) OldOwnerID

func (m *ItemMutation) OldOwnerID(ctx context.Context) (v string, err error)

OldOwnerID returns the old "owner_id" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) OldOwnerName

func (m *ItemMutation) OldOwnerName(ctx context.Context) (v string, err error)

OldOwnerName returns the old "owner_name" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) OldParentID

func (m *ItemMutation) OldParentID(ctx context.Context) (v string, err error)

OldParentID returns the old "parent_id" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) OldProgress

func (m *ItemMutation) OldProgress(ctx context.Context) (v *float64, err error)

OldProgress returns the old "progress" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) OldProvider

func (m *ItemMutation) OldProvider(ctx context.Context) (v string, err error)

OldProvider returns the old "provider" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) OldReleaseID

func (m *ItemMutation) OldReleaseID(ctx context.Context) (v string, err error)

OldReleaseID returns the old "release_id" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) OldRice

func (m *ItemMutation) OldRice(ctx context.Context) (v map[string]float64, err error)

OldRice returns the old "rice" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) OldSourceID

func (m *ItemMutation) OldSourceID(ctx context.Context) (v string, err error)

OldSourceID returns the old "source_id" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) OldSourceRef

func (m *ItemMutation) OldSourceRef(ctx context.Context) (v string, err error)

OldSourceRef returns the old "source_ref" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) OldSourceURL

func (m *ItemMutation) OldSourceURL(ctx context.Context) (v string, err error)

OldSourceURL returns the old "source_url" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) OldStartDate

func (m *ItemMutation) OldStartDate(ctx context.Context) (v *time.Time, err error)

OldStartDate returns the old "start_date" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) OldStatusCategory

func (m *ItemMutation) OldStatusCategory(ctx context.Context) (v string, err error)

OldStatusCategory returns the old "status_category" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) OldStatusComplete

func (m *ItemMutation) OldStatusComplete(ctx context.Context) (v bool, err error)

OldStatusComplete returns the old "status_complete" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) OldStatusID

func (m *ItemMutation) OldStatusID(ctx context.Context) (v string, err error)

OldStatusID returns the old "status_id" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) OldStatusName

func (m *ItemMutation) OldStatusName(ctx context.Context) (v string, err error)

OldStatusName returns the old "status_name" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) OldSyncedAt

func (m *ItemMutation) OldSyncedAt(ctx context.Context) (v time.Time, err error)

OldSyncedAt returns the old "synced_at" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) OldTags

func (m *ItemMutation) OldTags(ctx context.Context) (v []string, err error)

OldTags returns the old "tags" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) OldUpdatedAt

func (m *ItemMutation) OldUpdatedAt(ctx context.Context) (v *time.Time, err error)

OldUpdatedAt returns the old "updated_at" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) OldWorkspaceRef

func (m *ItemMutation) OldWorkspaceRef(ctx context.Context) (v string, err error)

OldWorkspaceRef returns the old "workspace_ref" field's value of the Item entity. If the Item object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ItemMutation) Op

func (m *ItemMutation) Op() Op

Op returns the operation name.

func (*ItemMutation) OwnerEmail

func (m *ItemMutation) OwnerEmail() (r string, exists bool)

OwnerEmail returns the value of the "owner_email" field in the mutation.

func (*ItemMutation) OwnerEmailCleared

func (m *ItemMutation) OwnerEmailCleared() bool

OwnerEmailCleared returns if the "owner_email" field was cleared in this mutation.

func (*ItemMutation) OwnerID

func (m *ItemMutation) OwnerID() (r string, exists bool)

OwnerID returns the value of the "owner_id" field in the mutation.

func (*ItemMutation) OwnerIDCleared

func (m *ItemMutation) OwnerIDCleared() bool

OwnerIDCleared returns if the "owner_id" field was cleared in this mutation.

func (*ItemMutation) OwnerName

func (m *ItemMutation) OwnerName() (r string, exists bool)

OwnerName returns the value of the "owner_name" field in the mutation.

func (*ItemMutation) OwnerNameCleared

func (m *ItemMutation) OwnerNameCleared() bool

OwnerNameCleared returns if the "owner_name" field was cleared in this mutation.

func (*ItemMutation) ParentID

func (m *ItemMutation) ParentID() (r string, exists bool)

ParentID returns the value of the "parent_id" field in the mutation.

func (*ItemMutation) ParentIDCleared

func (m *ItemMutation) ParentIDCleared() bool

ParentIDCleared returns if the "parent_id" field was cleared in this mutation.

func (*ItemMutation) Progress

func (m *ItemMutation) Progress() (r float64, exists bool)

Progress returns the value of the "progress" field in the mutation.

func (*ItemMutation) ProgressCleared

func (m *ItemMutation) ProgressCleared() bool

ProgressCleared returns if the "progress" field was cleared in this mutation.

func (*ItemMutation) Provider

func (m *ItemMutation) Provider() (r string, exists bool)

Provider returns the value of the "provider" field in the mutation.

func (*ItemMutation) ReleaseID

func (m *ItemMutation) ReleaseID() (r string, exists bool)

ReleaseID returns the value of the "release_id" field in the mutation.

func (*ItemMutation) ReleaseIDCleared

func (m *ItemMutation) ReleaseIDCleared() bool

ReleaseIDCleared returns if the "release_id" field was cleared in this mutation.

func (*ItemMutation) RemovedEdges

func (m *ItemMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*ItemMutation) RemovedIDs

func (m *ItemMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*ItemMutation) ResetCreatedAt

func (m *ItemMutation) ResetCreatedAt()

ResetCreatedAt resets all changes to the "created_at" field.

func (*ItemMutation) ResetCustomFields

func (m *ItemMutation) ResetCustomFields()

ResetCustomFields resets all changes to the "custom_fields" field.

func (*ItemMutation) ResetDescription

func (m *ItemMutation) ResetDescription()

ResetDescription resets all changes to the "description" field.

func (*ItemMutation) ResetDueDate

func (m *ItemMutation) ResetDueDate()

ResetDueDate resets all changes to the "due_date" field.

func (*ItemMutation) ResetEdge

func (m *ItemMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*ItemMutation) ResetField

func (m *ItemMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*ItemMutation) ResetKano

func (m *ItemMutation) ResetKano()

ResetKano resets all changes to the "kano" field.

func (*ItemMutation) ResetKind

func (m *ItemMutation) ResetKind()

ResetKind resets all changes to the "kind" field.

func (*ItemMutation) ResetMetadata

func (m *ItemMutation) ResetMetadata()

ResetMetadata resets all changes to the "metadata" field.

func (*ItemMutation) ResetMoscow

func (m *ItemMutation) ResetMoscow()

ResetMoscow resets all changes to the "moscow" field.

func (*ItemMutation) ResetName

func (m *ItemMutation) ResetName()

ResetName resets all changes to the "name" field.

func (*ItemMutation) ResetOwnerEmail

func (m *ItemMutation) ResetOwnerEmail()

ResetOwnerEmail resets all changes to the "owner_email" field.

func (*ItemMutation) ResetOwnerID

func (m *ItemMutation) ResetOwnerID()

ResetOwnerID resets all changes to the "owner_id" field.

func (*ItemMutation) ResetOwnerName

func (m *ItemMutation) ResetOwnerName()

ResetOwnerName resets all changes to the "owner_name" field.

func (*ItemMutation) ResetParentID

func (m *ItemMutation) ResetParentID()

ResetParentID resets all changes to the "parent_id" field.

func (*ItemMutation) ResetProgress

func (m *ItemMutation) ResetProgress()

ResetProgress resets all changes to the "progress" field.

func (*ItemMutation) ResetProvider

func (m *ItemMutation) ResetProvider()

ResetProvider resets all changes to the "provider" field.

func (*ItemMutation) ResetReleaseID

func (m *ItemMutation) ResetReleaseID()

ResetReleaseID resets all changes to the "release_id" field.

func (*ItemMutation) ResetRice

func (m *ItemMutation) ResetRice()

ResetRice resets all changes to the "rice" field.

func (*ItemMutation) ResetSourceID

func (m *ItemMutation) ResetSourceID()

ResetSourceID resets all changes to the "source_id" field.

func (*ItemMutation) ResetSourceRef

func (m *ItemMutation) ResetSourceRef()

ResetSourceRef resets all changes to the "source_ref" field.

func (*ItemMutation) ResetSourceURL

func (m *ItemMutation) ResetSourceURL()

ResetSourceURL resets all changes to the "source_url" field.

func (*ItemMutation) ResetStartDate

func (m *ItemMutation) ResetStartDate()

ResetStartDate resets all changes to the "start_date" field.

func (*ItemMutation) ResetStatusCategory

func (m *ItemMutation) ResetStatusCategory()

ResetStatusCategory resets all changes to the "status_category" field.

func (*ItemMutation) ResetStatusComplete

func (m *ItemMutation) ResetStatusComplete()

ResetStatusComplete resets all changes to the "status_complete" field.

func (*ItemMutation) ResetStatusID

func (m *ItemMutation) ResetStatusID()

ResetStatusID resets all changes to the "status_id" field.

func (*ItemMutation) ResetStatusName

func (m *ItemMutation) ResetStatusName()

ResetStatusName resets all changes to the "status_name" field.

func (*ItemMutation) ResetSyncedAt

func (m *ItemMutation) ResetSyncedAt()

ResetSyncedAt resets all changes to the "synced_at" field.

func (*ItemMutation) ResetTags

func (m *ItemMutation) ResetTags()

ResetTags resets all changes to the "tags" field.

func (*ItemMutation) ResetUpdatedAt

func (m *ItemMutation) ResetUpdatedAt()

ResetUpdatedAt resets all changes to the "updated_at" field.

func (*ItemMutation) ResetWorkspaceRef

func (m *ItemMutation) ResetWorkspaceRef()

ResetWorkspaceRef resets all changes to the "workspace_ref" field.

func (*ItemMutation) Rice

func (m *ItemMutation) Rice() (r map[string]float64, exists bool)

Rice returns the value of the "rice" field in the mutation.

func (*ItemMutation) RiceCleared

func (m *ItemMutation) RiceCleared() bool

RiceCleared returns if the "rice" field was cleared in this mutation.

func (*ItemMutation) SetCreatedAt

func (m *ItemMutation) SetCreatedAt(t time.Time)

SetCreatedAt sets the "created_at" field.

func (*ItemMutation) SetCustomFields

func (m *ItemMutation) SetCustomFields(value []map[string]interface{})

SetCustomFields sets the "custom_fields" field.

func (*ItemMutation) SetDescription

func (m *ItemMutation) SetDescription(s string)

SetDescription sets the "description" field.

func (*ItemMutation) SetDueDate

func (m *ItemMutation) SetDueDate(t time.Time)

SetDueDate sets the "due_date" field.

func (*ItemMutation) SetField

func (m *ItemMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*ItemMutation) SetID

func (m *ItemMutation) SetID(id string)

SetID sets the value of the id field. Note that this operation is only accepted on creation of Item entities.

func (*ItemMutation) SetKano

func (m *ItemMutation) SetKano(s string)

SetKano sets the "kano" field.

func (*ItemMutation) SetKind

func (m *ItemMutation) SetKind(s string)

SetKind sets the "kind" field.

func (*ItemMutation) SetMetadata

func (m *ItemMutation) SetMetadata(value map[string]interface{})

SetMetadata sets the "metadata" field.

func (*ItemMutation) SetMoscow

func (m *ItemMutation) SetMoscow(s string)

SetMoscow sets the "moscow" field.

func (*ItemMutation) SetName

func (m *ItemMutation) SetName(s string)

SetName sets the "name" field.

func (*ItemMutation) SetOp

func (m *ItemMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*ItemMutation) SetOwnerEmail

func (m *ItemMutation) SetOwnerEmail(s string)

SetOwnerEmail sets the "owner_email" field.

func (*ItemMutation) SetOwnerID

func (m *ItemMutation) SetOwnerID(s string)

SetOwnerID sets the "owner_id" field.

func (*ItemMutation) SetOwnerName

func (m *ItemMutation) SetOwnerName(s string)

SetOwnerName sets the "owner_name" field.

func (*ItemMutation) SetParentID

func (m *ItemMutation) SetParentID(s string)

SetParentID sets the "parent_id" field.

func (*ItemMutation) SetProgress

func (m *ItemMutation) SetProgress(f float64)

SetProgress sets the "progress" field.

func (*ItemMutation) SetProvider

func (m *ItemMutation) SetProvider(s string)

SetProvider sets the "provider" field.

func (*ItemMutation) SetReleaseID

func (m *ItemMutation) SetReleaseID(s string)

SetReleaseID sets the "release_id" field.

func (*ItemMutation) SetRice

func (m *ItemMutation) SetRice(value map[string]float64)

SetRice sets the "rice" field.

func (*ItemMutation) SetSourceID

func (m *ItemMutation) SetSourceID(s string)

SetSourceID sets the "source_id" field.

func (*ItemMutation) SetSourceRef

func (m *ItemMutation) SetSourceRef(s string)

SetSourceRef sets the "source_ref" field.

func (*ItemMutation) SetSourceURL

func (m *ItemMutation) SetSourceURL(s string)

SetSourceURL sets the "source_url" field.

func (*ItemMutation) SetStartDate

func (m *ItemMutation) SetStartDate(t time.Time)

SetStartDate sets the "start_date" field.

func (*ItemMutation) SetStatusCategory

func (m *ItemMutation) SetStatusCategory(s string)

SetStatusCategory sets the "status_category" field.

func (*ItemMutation) SetStatusComplete

func (m *ItemMutation) SetStatusComplete(b bool)

SetStatusComplete sets the "status_complete" field.

func (*ItemMutation) SetStatusID

func (m *ItemMutation) SetStatusID(s string)

SetStatusID sets the "status_id" field.

func (*ItemMutation) SetStatusName

func (m *ItemMutation) SetStatusName(s string)

SetStatusName sets the "status_name" field.

func (*ItemMutation) SetSyncedAt

func (m *ItemMutation) SetSyncedAt(t time.Time)

SetSyncedAt sets the "synced_at" field.

func (*ItemMutation) SetTags

func (m *ItemMutation) SetTags(s []string)

SetTags sets the "tags" field.

func (*ItemMutation) SetUpdatedAt

func (m *ItemMutation) SetUpdatedAt(t time.Time)

SetUpdatedAt sets the "updated_at" field.

func (*ItemMutation) SetWorkspaceRef

func (m *ItemMutation) SetWorkspaceRef(s string)

SetWorkspaceRef sets the "workspace_ref" field.

func (*ItemMutation) SourceID

func (m *ItemMutation) SourceID() (r string, exists bool)

SourceID returns the value of the "source_id" field in the mutation.

func (*ItemMutation) SourceRef

func (m *ItemMutation) SourceRef() (r string, exists bool)

SourceRef returns the value of the "source_ref" field in the mutation.

func (*ItemMutation) SourceRefCleared

func (m *ItemMutation) SourceRefCleared() bool

SourceRefCleared returns if the "source_ref" field was cleared in this mutation.

func (*ItemMutation) SourceURL

func (m *ItemMutation) SourceURL() (r string, exists bool)

SourceURL returns the value of the "source_url" field in the mutation.

func (*ItemMutation) SourceURLCleared

func (m *ItemMutation) SourceURLCleared() bool

SourceURLCleared returns if the "source_url" field was cleared in this mutation.

func (*ItemMutation) StartDate

func (m *ItemMutation) StartDate() (r time.Time, exists bool)

StartDate returns the value of the "start_date" field in the mutation.

func (*ItemMutation) StartDateCleared

func (m *ItemMutation) StartDateCleared() bool

StartDateCleared returns if the "start_date" field was cleared in this mutation.

func (*ItemMutation) StatusCategory

func (m *ItemMutation) StatusCategory() (r string, exists bool)

StatusCategory returns the value of the "status_category" field in the mutation.

func (*ItemMutation) StatusCategoryCleared

func (m *ItemMutation) StatusCategoryCleared() bool

StatusCategoryCleared returns if the "status_category" field was cleared in this mutation.

func (*ItemMutation) StatusComplete

func (m *ItemMutation) StatusComplete() (r bool, exists bool)

StatusComplete returns the value of the "status_complete" field in the mutation.

func (*ItemMutation) StatusID

func (m *ItemMutation) StatusID() (r string, exists bool)

StatusID returns the value of the "status_id" field in the mutation.

func (*ItemMutation) StatusIDCleared

func (m *ItemMutation) StatusIDCleared() bool

StatusIDCleared returns if the "status_id" field was cleared in this mutation.

func (*ItemMutation) StatusName

func (m *ItemMutation) StatusName() (r string, exists bool)

StatusName returns the value of the "status_name" field in the mutation.

func (*ItemMutation) StatusNameCleared

func (m *ItemMutation) StatusNameCleared() bool

StatusNameCleared returns if the "status_name" field was cleared in this mutation.

func (*ItemMutation) SyncedAt

func (m *ItemMutation) SyncedAt() (r time.Time, exists bool)

SyncedAt returns the value of the "synced_at" field in the mutation.

func (*ItemMutation) Tags

func (m *ItemMutation) Tags() (r []string, exists bool)

Tags returns the value of the "tags" field in the mutation.

func (*ItemMutation) TagsCleared

func (m *ItemMutation) TagsCleared() bool

TagsCleared returns if the "tags" field was cleared in this mutation.

func (ItemMutation) Tx

func (m ItemMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*ItemMutation) Type

func (m *ItemMutation) Type() string

Type returns the node type of this mutation (Item).

func (*ItemMutation) UpdatedAt

func (m *ItemMutation) UpdatedAt() (r time.Time, exists bool)

UpdatedAt returns the value of the "updated_at" field in the mutation.

func (*ItemMutation) UpdatedAtCleared

func (m *ItemMutation) UpdatedAtCleared() bool

UpdatedAtCleared returns if the "updated_at" field was cleared in this mutation.

func (*ItemMutation) Where

func (m *ItemMutation) Where(ps ...predicate.Item)

Where appends a list predicates to the ItemMutation builder.

func (*ItemMutation) WhereP

func (m *ItemMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the ItemMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

func (*ItemMutation) WorkspaceRef

func (m *ItemMutation) WorkspaceRef() (r string, exists bool)

WorkspaceRef returns the value of the "workspace_ref" field in the mutation.

func (*ItemMutation) WorkspaceRefCleared

func (m *ItemMutation) WorkspaceRefCleared() bool

WorkspaceRefCleared returns if the "workspace_ref" field was cleared in this mutation.

type ItemQuery

type ItemQuery struct {
	// contains filtered or unexported fields
}

ItemQuery is the builder for querying Item entities.

func (*ItemQuery) Aggregate

func (_q *ItemQuery) Aggregate(fns ...AggregateFunc) *ItemSelect

Aggregate returns a ItemSelect configured with the given aggregations.

func (*ItemQuery) All

func (_q *ItemQuery) All(ctx context.Context) ([]*Item, error)

All executes the query and returns a list of Items.

func (*ItemQuery) AllX

func (_q *ItemQuery) AllX(ctx context.Context) []*Item

AllX is like All, but panics if an error occurs.

func (*ItemQuery) Clone

func (_q *ItemQuery) Clone() *ItemQuery

Clone returns a duplicate of the ItemQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*ItemQuery) Count

func (_q *ItemQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*ItemQuery) CountX

func (_q *ItemQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*ItemQuery) Exist

func (_q *ItemQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*ItemQuery) ExistX

func (_q *ItemQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*ItemQuery) First

func (_q *ItemQuery) First(ctx context.Context) (*Item, error)

First returns the first Item entity from the query. Returns a *NotFoundError when no Item was found.

func (*ItemQuery) FirstID

func (_q *ItemQuery) FirstID(ctx context.Context) (id string, err error)

FirstID returns the first Item ID from the query. Returns a *NotFoundError when no Item ID was found.

func (*ItemQuery) FirstIDX

func (_q *ItemQuery) FirstIDX(ctx context.Context) string

FirstIDX is like FirstID, but panics if an error occurs.

func (*ItemQuery) FirstX

func (_q *ItemQuery) FirstX(ctx context.Context) *Item

FirstX is like First, but panics if an error occurs.

func (*ItemQuery) GroupBy

func (_q *ItemQuery) GroupBy(field string, fields ...string) *ItemGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	Provider string `json:"provider,omitempty"`
	Count int `json:"count,omitempty"`
}

client.Item.Query().
	GroupBy(item.FieldProvider).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*ItemQuery) IDs

func (_q *ItemQuery) IDs(ctx context.Context) (ids []string, err error)

IDs executes the query and returns a list of Item IDs.

func (*ItemQuery) IDsX

func (_q *ItemQuery) IDsX(ctx context.Context) []string

IDsX is like IDs, but panics if an error occurs.

func (*ItemQuery) Limit

func (_q *ItemQuery) Limit(limit int) *ItemQuery

Limit the number of records to be returned by this query.

func (*ItemQuery) Offset

func (_q *ItemQuery) Offset(offset int) *ItemQuery

Offset to start from.

func (*ItemQuery) Only

func (_q *ItemQuery) Only(ctx context.Context) (*Item, error)

Only returns a single Item entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one Item entity is found. Returns a *NotFoundError when no Item entities are found.

func (*ItemQuery) OnlyID

func (_q *ItemQuery) OnlyID(ctx context.Context) (id string, err error)

OnlyID is like Only, but returns the only Item ID in the query. Returns a *NotSingularError when more than one Item ID is found. Returns a *NotFoundError when no entities are found.

func (*ItemQuery) OnlyIDX

func (_q *ItemQuery) OnlyIDX(ctx context.Context) string

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*ItemQuery) OnlyX

func (_q *ItemQuery) OnlyX(ctx context.Context) *Item

OnlyX is like Only, but panics if an error occurs.

func (*ItemQuery) Order

func (_q *ItemQuery) Order(o ...item.OrderOption) *ItemQuery

Order specifies how the records should be ordered.

func (*ItemQuery) Select

func (_q *ItemQuery) Select(fields ...string) *ItemSelect

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	Provider string `json:"provider,omitempty"`
}

client.Item.Query().
	Select(item.FieldProvider).
	Scan(ctx, &v)

func (*ItemQuery) Unique

func (_q *ItemQuery) Unique(unique bool) *ItemQuery

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*ItemQuery) Where

func (_q *ItemQuery) Where(ps ...predicate.Item) *ItemQuery

Where adds a new predicate for the ItemQuery builder.

type ItemSelect

type ItemSelect struct {
	*ItemQuery
	// contains filtered or unexported fields
}

ItemSelect is the builder for selecting fields of Item entities.

func (*ItemSelect) Aggregate

func (_s *ItemSelect) Aggregate(fns ...AggregateFunc) *ItemSelect

Aggregate adds the given aggregation functions to the selector query.

func (*ItemSelect) Bool

func (s *ItemSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*ItemSelect) BoolX

func (s *ItemSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*ItemSelect) Bools

func (s *ItemSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*ItemSelect) BoolsX

func (s *ItemSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*ItemSelect) Float64

func (s *ItemSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*ItemSelect) Float64X

func (s *ItemSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*ItemSelect) Float64s

func (s *ItemSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*ItemSelect) Float64sX

func (s *ItemSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*ItemSelect) Int

func (s *ItemSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*ItemSelect) IntX

func (s *ItemSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*ItemSelect) Ints

func (s *ItemSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*ItemSelect) IntsX

func (s *ItemSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*ItemSelect) Scan

func (_s *ItemSelect) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*ItemSelect) ScanX

func (s *ItemSelect) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*ItemSelect) String

func (s *ItemSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*ItemSelect) StringX

func (s *ItemSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*ItemSelect) Strings

func (s *ItemSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*ItemSelect) StringsX

func (s *ItemSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type ItemUpdate

type ItemUpdate struct {
	// contains filtered or unexported fields
}

ItemUpdate is the builder for updating Item entities.

func (*ItemUpdate) AddProgress

func (_u *ItemUpdate) AddProgress(v float64) *ItemUpdate

AddProgress adds value to the "progress" field.

func (*ItemUpdate) AppendCustomFields

func (_u *ItemUpdate) AppendCustomFields(v []map[string]interface{}) *ItemUpdate

AppendCustomFields appends value to the "custom_fields" field.

func (*ItemUpdate) AppendTags

func (_u *ItemUpdate) AppendTags(v []string) *ItemUpdate

AppendTags appends value to the "tags" field.

func (*ItemUpdate) ClearCreatedAt

func (_u *ItemUpdate) ClearCreatedAt() *ItemUpdate

ClearCreatedAt clears the value of the "created_at" field.

func (*ItemUpdate) ClearCustomFields

func (_u *ItemUpdate) ClearCustomFields() *ItemUpdate

ClearCustomFields clears the value of the "custom_fields" field.

func (*ItemUpdate) ClearDescription

func (_u *ItemUpdate) ClearDescription() *ItemUpdate

ClearDescription clears the value of the "description" field.

func (*ItemUpdate) ClearDueDate

func (_u *ItemUpdate) ClearDueDate() *ItemUpdate

ClearDueDate clears the value of the "due_date" field.

func (*ItemUpdate) ClearKano

func (_u *ItemUpdate) ClearKano() *ItemUpdate

ClearKano clears the value of the "kano" field.

func (*ItemUpdate) ClearMetadata

func (_u *ItemUpdate) ClearMetadata() *ItemUpdate

ClearMetadata clears the value of the "metadata" field.

func (*ItemUpdate) ClearMoscow

func (_u *ItemUpdate) ClearMoscow() *ItemUpdate

ClearMoscow clears the value of the "moscow" field.

func (*ItemUpdate) ClearName

func (_u *ItemUpdate) ClearName() *ItemUpdate

ClearName clears the value of the "name" field.

func (*ItemUpdate) ClearOwnerEmail

func (_u *ItemUpdate) ClearOwnerEmail() *ItemUpdate

ClearOwnerEmail clears the value of the "owner_email" field.

func (*ItemUpdate) ClearOwnerID

func (_u *ItemUpdate) ClearOwnerID() *ItemUpdate

ClearOwnerID clears the value of the "owner_id" field.

func (*ItemUpdate) ClearOwnerName

func (_u *ItemUpdate) ClearOwnerName() *ItemUpdate

ClearOwnerName clears the value of the "owner_name" field.

func (*ItemUpdate) ClearParentID

func (_u *ItemUpdate) ClearParentID() *ItemUpdate

ClearParentID clears the value of the "parent_id" field.

func (*ItemUpdate) ClearProgress

func (_u *ItemUpdate) ClearProgress() *ItemUpdate

ClearProgress clears the value of the "progress" field.

func (*ItemUpdate) ClearReleaseID

func (_u *ItemUpdate) ClearReleaseID() *ItemUpdate

ClearReleaseID clears the value of the "release_id" field.

func (*ItemUpdate) ClearRice

func (_u *ItemUpdate) ClearRice() *ItemUpdate

ClearRice clears the value of the "rice" field.

func (*ItemUpdate) ClearSourceRef

func (_u *ItemUpdate) ClearSourceRef() *ItemUpdate

ClearSourceRef clears the value of the "source_ref" field.

func (*ItemUpdate) ClearSourceURL

func (_u *ItemUpdate) ClearSourceURL() *ItemUpdate

ClearSourceURL clears the value of the "source_url" field.

func (*ItemUpdate) ClearStartDate

func (_u *ItemUpdate) ClearStartDate() *ItemUpdate

ClearStartDate clears the value of the "start_date" field.

func (*ItemUpdate) ClearStatusCategory

func (_u *ItemUpdate) ClearStatusCategory() *ItemUpdate

ClearStatusCategory clears the value of the "status_category" field.

func (*ItemUpdate) ClearStatusID

func (_u *ItemUpdate) ClearStatusID() *ItemUpdate

ClearStatusID clears the value of the "status_id" field.

func (*ItemUpdate) ClearStatusName

func (_u *ItemUpdate) ClearStatusName() *ItemUpdate

ClearStatusName clears the value of the "status_name" field.

func (*ItemUpdate) ClearTags

func (_u *ItemUpdate) ClearTags() *ItemUpdate

ClearTags clears the value of the "tags" field.

func (*ItemUpdate) ClearUpdatedAt

func (_u *ItemUpdate) ClearUpdatedAt() *ItemUpdate

ClearUpdatedAt clears the value of the "updated_at" field.

func (*ItemUpdate) ClearWorkspaceRef

func (_u *ItemUpdate) ClearWorkspaceRef() *ItemUpdate

ClearWorkspaceRef clears the value of the "workspace_ref" field.

func (*ItemUpdate) Exec

func (_u *ItemUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*ItemUpdate) ExecX

func (_u *ItemUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ItemUpdate) Mutation

func (_u *ItemUpdate) Mutation() *ItemMutation

Mutation returns the ItemMutation object of the builder.

func (*ItemUpdate) Save

func (_u *ItemUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*ItemUpdate) SaveX

func (_u *ItemUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*ItemUpdate) SetCreatedAt

func (_u *ItemUpdate) SetCreatedAt(v time.Time) *ItemUpdate

SetCreatedAt sets the "created_at" field.

func (*ItemUpdate) SetCustomFields

func (_u *ItemUpdate) SetCustomFields(v []map[string]interface{}) *ItemUpdate

SetCustomFields sets the "custom_fields" field.

func (*ItemUpdate) SetDescription

func (_u *ItemUpdate) SetDescription(v string) *ItemUpdate

SetDescription sets the "description" field.

func (*ItemUpdate) SetDueDate

func (_u *ItemUpdate) SetDueDate(v time.Time) *ItemUpdate

SetDueDate sets the "due_date" field.

func (*ItemUpdate) SetKano

func (_u *ItemUpdate) SetKano(v string) *ItemUpdate

SetKano sets the "kano" field.

func (*ItemUpdate) SetKind

func (_u *ItemUpdate) SetKind(v string) *ItemUpdate

SetKind sets the "kind" field.

func (*ItemUpdate) SetMetadata

func (_u *ItemUpdate) SetMetadata(v map[string]interface{}) *ItemUpdate

SetMetadata sets the "metadata" field.

func (*ItemUpdate) SetMoscow

func (_u *ItemUpdate) SetMoscow(v string) *ItemUpdate

SetMoscow sets the "moscow" field.

func (*ItemUpdate) SetName

func (_u *ItemUpdate) SetName(v string) *ItemUpdate

SetName sets the "name" field.

func (*ItemUpdate) SetNillableCreatedAt

func (_u *ItemUpdate) SetNillableCreatedAt(v *time.Time) *ItemUpdate

SetNillableCreatedAt sets the "created_at" field if the given value is not nil.

func (*ItemUpdate) SetNillableDescription

func (_u *ItemUpdate) SetNillableDescription(v *string) *ItemUpdate

SetNillableDescription sets the "description" field if the given value is not nil.

func (*ItemUpdate) SetNillableDueDate

func (_u *ItemUpdate) SetNillableDueDate(v *time.Time) *ItemUpdate

SetNillableDueDate sets the "due_date" field if the given value is not nil.

func (*ItemUpdate) SetNillableKano

func (_u *ItemUpdate) SetNillableKano(v *string) *ItemUpdate

SetNillableKano sets the "kano" field if the given value is not nil.

func (*ItemUpdate) SetNillableKind

func (_u *ItemUpdate) SetNillableKind(v *string) *ItemUpdate

SetNillableKind sets the "kind" field if the given value is not nil.

func (*ItemUpdate) SetNillableMoscow

func (_u *ItemUpdate) SetNillableMoscow(v *string) *ItemUpdate

SetNillableMoscow sets the "moscow" field if the given value is not nil.

func (*ItemUpdate) SetNillableName

func (_u *ItemUpdate) SetNillableName(v *string) *ItemUpdate

SetNillableName sets the "name" field if the given value is not nil.

func (*ItemUpdate) SetNillableOwnerEmail

func (_u *ItemUpdate) SetNillableOwnerEmail(v *string) *ItemUpdate

SetNillableOwnerEmail sets the "owner_email" field if the given value is not nil.

func (*ItemUpdate) SetNillableOwnerID

func (_u *ItemUpdate) SetNillableOwnerID(v *string) *ItemUpdate

SetNillableOwnerID sets the "owner_id" field if the given value is not nil.

func (*ItemUpdate) SetNillableOwnerName

func (_u *ItemUpdate) SetNillableOwnerName(v *string) *ItemUpdate

SetNillableOwnerName sets the "owner_name" field if the given value is not nil.

func (*ItemUpdate) SetNillableParentID

func (_u *ItemUpdate) SetNillableParentID(v *string) *ItemUpdate

SetNillableParentID sets the "parent_id" field if the given value is not nil.

func (*ItemUpdate) SetNillableProgress

func (_u *ItemUpdate) SetNillableProgress(v *float64) *ItemUpdate

SetNillableProgress sets the "progress" field if the given value is not nil.

func (*ItemUpdate) SetNillableProvider

func (_u *ItemUpdate) SetNillableProvider(v *string) *ItemUpdate

SetNillableProvider sets the "provider" field if the given value is not nil.

func (*ItemUpdate) SetNillableReleaseID

func (_u *ItemUpdate) SetNillableReleaseID(v *string) *ItemUpdate

SetNillableReleaseID sets the "release_id" field if the given value is not nil.

func (*ItemUpdate) SetNillableSourceID

func (_u *ItemUpdate) SetNillableSourceID(v *string) *ItemUpdate

SetNillableSourceID sets the "source_id" field if the given value is not nil.

func (*ItemUpdate) SetNillableSourceRef

func (_u *ItemUpdate) SetNillableSourceRef(v *string) *ItemUpdate

SetNillableSourceRef sets the "source_ref" field if the given value is not nil.

func (*ItemUpdate) SetNillableSourceURL

func (_u *ItemUpdate) SetNillableSourceURL(v *string) *ItemUpdate

SetNillableSourceURL sets the "source_url" field if the given value is not nil.

func (*ItemUpdate) SetNillableStartDate

func (_u *ItemUpdate) SetNillableStartDate(v *time.Time) *ItemUpdate

SetNillableStartDate sets the "start_date" field if the given value is not nil.

func (*ItemUpdate) SetNillableStatusCategory

func (_u *ItemUpdate) SetNillableStatusCategory(v *string) *ItemUpdate

SetNillableStatusCategory sets the "status_category" field if the given value is not nil.

func (*ItemUpdate) SetNillableStatusComplete

func (_u *ItemUpdate) SetNillableStatusComplete(v *bool) *ItemUpdate

SetNillableStatusComplete sets the "status_complete" field if the given value is not nil.

func (*ItemUpdate) SetNillableStatusID

func (_u *ItemUpdate) SetNillableStatusID(v *string) *ItemUpdate

SetNillableStatusID sets the "status_id" field if the given value is not nil.

func (*ItemUpdate) SetNillableStatusName

func (_u *ItemUpdate) SetNillableStatusName(v *string) *ItemUpdate

SetNillableStatusName sets the "status_name" field if the given value is not nil.

func (*ItemUpdate) SetNillableSyncedAt

func (_u *ItemUpdate) SetNillableSyncedAt(v *time.Time) *ItemUpdate

SetNillableSyncedAt sets the "synced_at" field if the given value is not nil.

func (*ItemUpdate) SetNillableUpdatedAt

func (_u *ItemUpdate) SetNillableUpdatedAt(v *time.Time) *ItemUpdate

SetNillableUpdatedAt sets the "updated_at" field if the given value is not nil.

func (*ItemUpdate) SetNillableWorkspaceRef

func (_u *ItemUpdate) SetNillableWorkspaceRef(v *string) *ItemUpdate

SetNillableWorkspaceRef sets the "workspace_ref" field if the given value is not nil.

func (*ItemUpdate) SetOwnerEmail

func (_u *ItemUpdate) SetOwnerEmail(v string) *ItemUpdate

SetOwnerEmail sets the "owner_email" field.

func (*ItemUpdate) SetOwnerID

func (_u *ItemUpdate) SetOwnerID(v string) *ItemUpdate

SetOwnerID sets the "owner_id" field.

func (*ItemUpdate) SetOwnerName

func (_u *ItemUpdate) SetOwnerName(v string) *ItemUpdate

SetOwnerName sets the "owner_name" field.

func (*ItemUpdate) SetParentID

func (_u *ItemUpdate) SetParentID(v string) *ItemUpdate

SetParentID sets the "parent_id" field.

func (*ItemUpdate) SetProgress

func (_u *ItemUpdate) SetProgress(v float64) *ItemUpdate

SetProgress sets the "progress" field.

func (*ItemUpdate) SetProvider

func (_u *ItemUpdate) SetProvider(v string) *ItemUpdate

SetProvider sets the "provider" field.

func (*ItemUpdate) SetReleaseID

func (_u *ItemUpdate) SetReleaseID(v string) *ItemUpdate

SetReleaseID sets the "release_id" field.

func (*ItemUpdate) SetRice

func (_u *ItemUpdate) SetRice(v map[string]float64) *ItemUpdate

SetRice sets the "rice" field.

func (*ItemUpdate) SetSourceID

func (_u *ItemUpdate) SetSourceID(v string) *ItemUpdate

SetSourceID sets the "source_id" field.

func (*ItemUpdate) SetSourceRef

func (_u *ItemUpdate) SetSourceRef(v string) *ItemUpdate

SetSourceRef sets the "source_ref" field.

func (*ItemUpdate) SetSourceURL

func (_u *ItemUpdate) SetSourceURL(v string) *ItemUpdate

SetSourceURL sets the "source_url" field.

func (*ItemUpdate) SetStartDate

func (_u *ItemUpdate) SetStartDate(v time.Time) *ItemUpdate

SetStartDate sets the "start_date" field.

func (*ItemUpdate) SetStatusCategory

func (_u *ItemUpdate) SetStatusCategory(v string) *ItemUpdate

SetStatusCategory sets the "status_category" field.

func (*ItemUpdate) SetStatusComplete

func (_u *ItemUpdate) SetStatusComplete(v bool) *ItemUpdate

SetStatusComplete sets the "status_complete" field.

func (*ItemUpdate) SetStatusID

func (_u *ItemUpdate) SetStatusID(v string) *ItemUpdate

SetStatusID sets the "status_id" field.

func (*ItemUpdate) SetStatusName

func (_u *ItemUpdate) SetStatusName(v string) *ItemUpdate

SetStatusName sets the "status_name" field.

func (*ItemUpdate) SetSyncedAt

func (_u *ItemUpdate) SetSyncedAt(v time.Time) *ItemUpdate

SetSyncedAt sets the "synced_at" field.

func (*ItemUpdate) SetTags

func (_u *ItemUpdate) SetTags(v []string) *ItemUpdate

SetTags sets the "tags" field.

func (*ItemUpdate) SetUpdatedAt

func (_u *ItemUpdate) SetUpdatedAt(v time.Time) *ItemUpdate

SetUpdatedAt sets the "updated_at" field.

func (*ItemUpdate) SetWorkspaceRef

func (_u *ItemUpdate) SetWorkspaceRef(v string) *ItemUpdate

SetWorkspaceRef sets the "workspace_ref" field.

func (*ItemUpdate) Where

func (_u *ItemUpdate) Where(ps ...predicate.Item) *ItemUpdate

Where appends a list predicates to the ItemUpdate builder.

type ItemUpdateOne

type ItemUpdateOne struct {
	// contains filtered or unexported fields
}

ItemUpdateOne is the builder for updating a single Item entity.

func (*ItemUpdateOne) AddProgress

func (_u *ItemUpdateOne) AddProgress(v float64) *ItemUpdateOne

AddProgress adds value to the "progress" field.

func (*ItemUpdateOne) AppendCustomFields

func (_u *ItemUpdateOne) AppendCustomFields(v []map[string]interface{}) *ItemUpdateOne

AppendCustomFields appends value to the "custom_fields" field.

func (*ItemUpdateOne) AppendTags

func (_u *ItemUpdateOne) AppendTags(v []string) *ItemUpdateOne

AppendTags appends value to the "tags" field.

func (*ItemUpdateOne) ClearCreatedAt

func (_u *ItemUpdateOne) ClearCreatedAt() *ItemUpdateOne

ClearCreatedAt clears the value of the "created_at" field.

func (*ItemUpdateOne) ClearCustomFields

func (_u *ItemUpdateOne) ClearCustomFields() *ItemUpdateOne

ClearCustomFields clears the value of the "custom_fields" field.

func (*ItemUpdateOne) ClearDescription

func (_u *ItemUpdateOne) ClearDescription() *ItemUpdateOne

ClearDescription clears the value of the "description" field.

func (*ItemUpdateOne) ClearDueDate

func (_u *ItemUpdateOne) ClearDueDate() *ItemUpdateOne

ClearDueDate clears the value of the "due_date" field.

func (*ItemUpdateOne) ClearKano

func (_u *ItemUpdateOne) ClearKano() *ItemUpdateOne

ClearKano clears the value of the "kano" field.

func (*ItemUpdateOne) ClearMetadata

func (_u *ItemUpdateOne) ClearMetadata() *ItemUpdateOne

ClearMetadata clears the value of the "metadata" field.

func (*ItemUpdateOne) ClearMoscow

func (_u *ItemUpdateOne) ClearMoscow() *ItemUpdateOne

ClearMoscow clears the value of the "moscow" field.

func (*ItemUpdateOne) ClearName

func (_u *ItemUpdateOne) ClearName() *ItemUpdateOne

ClearName clears the value of the "name" field.

func (*ItemUpdateOne) ClearOwnerEmail

func (_u *ItemUpdateOne) ClearOwnerEmail() *ItemUpdateOne

ClearOwnerEmail clears the value of the "owner_email" field.

func (*ItemUpdateOne) ClearOwnerID

func (_u *ItemUpdateOne) ClearOwnerID() *ItemUpdateOne

ClearOwnerID clears the value of the "owner_id" field.

func (*ItemUpdateOne) ClearOwnerName

func (_u *ItemUpdateOne) ClearOwnerName() *ItemUpdateOne

ClearOwnerName clears the value of the "owner_name" field.

func (*ItemUpdateOne) ClearParentID

func (_u *ItemUpdateOne) ClearParentID() *ItemUpdateOne

ClearParentID clears the value of the "parent_id" field.

func (*ItemUpdateOne) ClearProgress

func (_u *ItemUpdateOne) ClearProgress() *ItemUpdateOne

ClearProgress clears the value of the "progress" field.

func (*ItemUpdateOne) ClearReleaseID

func (_u *ItemUpdateOne) ClearReleaseID() *ItemUpdateOne

ClearReleaseID clears the value of the "release_id" field.

func (*ItemUpdateOne) ClearRice

func (_u *ItemUpdateOne) ClearRice() *ItemUpdateOne

ClearRice clears the value of the "rice" field.

func (*ItemUpdateOne) ClearSourceRef

func (_u *ItemUpdateOne) ClearSourceRef() *ItemUpdateOne

ClearSourceRef clears the value of the "source_ref" field.

func (*ItemUpdateOne) ClearSourceURL

func (_u *ItemUpdateOne) ClearSourceURL() *ItemUpdateOne

ClearSourceURL clears the value of the "source_url" field.

func (*ItemUpdateOne) ClearStartDate

func (_u *ItemUpdateOne) ClearStartDate() *ItemUpdateOne

ClearStartDate clears the value of the "start_date" field.

func (*ItemUpdateOne) ClearStatusCategory

func (_u *ItemUpdateOne) ClearStatusCategory() *ItemUpdateOne

ClearStatusCategory clears the value of the "status_category" field.

func (*ItemUpdateOne) ClearStatusID

func (_u *ItemUpdateOne) ClearStatusID() *ItemUpdateOne

ClearStatusID clears the value of the "status_id" field.

func (*ItemUpdateOne) ClearStatusName

func (_u *ItemUpdateOne) ClearStatusName() *ItemUpdateOne

ClearStatusName clears the value of the "status_name" field.

func (*ItemUpdateOne) ClearTags

func (_u *ItemUpdateOne) ClearTags() *ItemUpdateOne

ClearTags clears the value of the "tags" field.

func (*ItemUpdateOne) ClearUpdatedAt

func (_u *ItemUpdateOne) ClearUpdatedAt() *ItemUpdateOne

ClearUpdatedAt clears the value of the "updated_at" field.

func (*ItemUpdateOne) ClearWorkspaceRef

func (_u *ItemUpdateOne) ClearWorkspaceRef() *ItemUpdateOne

ClearWorkspaceRef clears the value of the "workspace_ref" field.

func (*ItemUpdateOne) Exec

func (_u *ItemUpdateOne) Exec(ctx context.Context) error

Exec executes the query on the entity.

func (*ItemUpdateOne) ExecX

func (_u *ItemUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ItemUpdateOne) Mutation

func (_u *ItemUpdateOne) Mutation() *ItemMutation

Mutation returns the ItemMutation object of the builder.

func (*ItemUpdateOne) Save

func (_u *ItemUpdateOne) Save(ctx context.Context) (*Item, error)

Save executes the query and returns the updated Item entity.

func (*ItemUpdateOne) SaveX

func (_u *ItemUpdateOne) SaveX(ctx context.Context) *Item

SaveX is like Save, but panics if an error occurs.

func (*ItemUpdateOne) Select

func (_u *ItemUpdateOne) Select(field string, fields ...string) *ItemUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*ItemUpdateOne) SetCreatedAt

func (_u *ItemUpdateOne) SetCreatedAt(v time.Time) *ItemUpdateOne

SetCreatedAt sets the "created_at" field.

func (*ItemUpdateOne) SetCustomFields

func (_u *ItemUpdateOne) SetCustomFields(v []map[string]interface{}) *ItemUpdateOne

SetCustomFields sets the "custom_fields" field.

func (*ItemUpdateOne) SetDescription

func (_u *ItemUpdateOne) SetDescription(v string) *ItemUpdateOne

SetDescription sets the "description" field.

func (*ItemUpdateOne) SetDueDate

func (_u *ItemUpdateOne) SetDueDate(v time.Time) *ItemUpdateOne

SetDueDate sets the "due_date" field.

func (*ItemUpdateOne) SetKano

func (_u *ItemUpdateOne) SetKano(v string) *ItemUpdateOne

SetKano sets the "kano" field.

func (*ItemUpdateOne) SetKind

func (_u *ItemUpdateOne) SetKind(v string) *ItemUpdateOne

SetKind sets the "kind" field.

func (*ItemUpdateOne) SetMetadata

func (_u *ItemUpdateOne) SetMetadata(v map[string]interface{}) *ItemUpdateOne

SetMetadata sets the "metadata" field.

func (*ItemUpdateOne) SetMoscow

func (_u *ItemUpdateOne) SetMoscow(v string) *ItemUpdateOne

SetMoscow sets the "moscow" field.

func (*ItemUpdateOne) SetName

func (_u *ItemUpdateOne) SetName(v string) *ItemUpdateOne

SetName sets the "name" field.

func (*ItemUpdateOne) SetNillableCreatedAt

func (_u *ItemUpdateOne) SetNillableCreatedAt(v *time.Time) *ItemUpdateOne

SetNillableCreatedAt sets the "created_at" field if the given value is not nil.

func (*ItemUpdateOne) SetNillableDescription

func (_u *ItemUpdateOne) SetNillableDescription(v *string) *ItemUpdateOne

SetNillableDescription sets the "description" field if the given value is not nil.

func (*ItemUpdateOne) SetNillableDueDate

func (_u *ItemUpdateOne) SetNillableDueDate(v *time.Time) *ItemUpdateOne

SetNillableDueDate sets the "due_date" field if the given value is not nil.

func (*ItemUpdateOne) SetNillableKano

func (_u *ItemUpdateOne) SetNillableKano(v *string) *ItemUpdateOne

SetNillableKano sets the "kano" field if the given value is not nil.

func (*ItemUpdateOne) SetNillableKind

func (_u *ItemUpdateOne) SetNillableKind(v *string) *ItemUpdateOne

SetNillableKind sets the "kind" field if the given value is not nil.

func (*ItemUpdateOne) SetNillableMoscow

func (_u *ItemUpdateOne) SetNillableMoscow(v *string) *ItemUpdateOne

SetNillableMoscow sets the "moscow" field if the given value is not nil.

func (*ItemUpdateOne) SetNillableName

func (_u *ItemUpdateOne) SetNillableName(v *string) *ItemUpdateOne

SetNillableName sets the "name" field if the given value is not nil.

func (*ItemUpdateOne) SetNillableOwnerEmail

func (_u *ItemUpdateOne) SetNillableOwnerEmail(v *string) *ItemUpdateOne

SetNillableOwnerEmail sets the "owner_email" field if the given value is not nil.

func (*ItemUpdateOne) SetNillableOwnerID

func (_u *ItemUpdateOne) SetNillableOwnerID(v *string) *ItemUpdateOne

SetNillableOwnerID sets the "owner_id" field if the given value is not nil.

func (*ItemUpdateOne) SetNillableOwnerName

func (_u *ItemUpdateOne) SetNillableOwnerName(v *string) *ItemUpdateOne

SetNillableOwnerName sets the "owner_name" field if the given value is not nil.

func (*ItemUpdateOne) SetNillableParentID

func (_u *ItemUpdateOne) SetNillableParentID(v *string) *ItemUpdateOne

SetNillableParentID sets the "parent_id" field if the given value is not nil.

func (*ItemUpdateOne) SetNillableProgress

func (_u *ItemUpdateOne) SetNillableProgress(v *float64) *ItemUpdateOne

SetNillableProgress sets the "progress" field if the given value is not nil.

func (*ItemUpdateOne) SetNillableProvider

func (_u *ItemUpdateOne) SetNillableProvider(v *string) *ItemUpdateOne

SetNillableProvider sets the "provider" field if the given value is not nil.

func (*ItemUpdateOne) SetNillableReleaseID

func (_u *ItemUpdateOne) SetNillableReleaseID(v *string) *ItemUpdateOne

SetNillableReleaseID sets the "release_id" field if the given value is not nil.

func (*ItemUpdateOne) SetNillableSourceID

func (_u *ItemUpdateOne) SetNillableSourceID(v *string) *ItemUpdateOne

SetNillableSourceID sets the "source_id" field if the given value is not nil.

func (*ItemUpdateOne) SetNillableSourceRef

func (_u *ItemUpdateOne) SetNillableSourceRef(v *string) *ItemUpdateOne

SetNillableSourceRef sets the "source_ref" field if the given value is not nil.

func (*ItemUpdateOne) SetNillableSourceURL

func (_u *ItemUpdateOne) SetNillableSourceURL(v *string) *ItemUpdateOne

SetNillableSourceURL sets the "source_url" field if the given value is not nil.

func (*ItemUpdateOne) SetNillableStartDate

func (_u *ItemUpdateOne) SetNillableStartDate(v *time.Time) *ItemUpdateOne

SetNillableStartDate sets the "start_date" field if the given value is not nil.

func (*ItemUpdateOne) SetNillableStatusCategory

func (_u *ItemUpdateOne) SetNillableStatusCategory(v *string) *ItemUpdateOne

SetNillableStatusCategory sets the "status_category" field if the given value is not nil.

func (*ItemUpdateOne) SetNillableStatusComplete

func (_u *ItemUpdateOne) SetNillableStatusComplete(v *bool) *ItemUpdateOne

SetNillableStatusComplete sets the "status_complete" field if the given value is not nil.

func (*ItemUpdateOne) SetNillableStatusID

func (_u *ItemUpdateOne) SetNillableStatusID(v *string) *ItemUpdateOne

SetNillableStatusID sets the "status_id" field if the given value is not nil.

func (*ItemUpdateOne) SetNillableStatusName

func (_u *ItemUpdateOne) SetNillableStatusName(v *string) *ItemUpdateOne

SetNillableStatusName sets the "status_name" field if the given value is not nil.

func (*ItemUpdateOne) SetNillableSyncedAt

func (_u *ItemUpdateOne) SetNillableSyncedAt(v *time.Time) *ItemUpdateOne

SetNillableSyncedAt sets the "synced_at" field if the given value is not nil.

func (*ItemUpdateOne) SetNillableUpdatedAt

func (_u *ItemUpdateOne) SetNillableUpdatedAt(v *time.Time) *ItemUpdateOne

SetNillableUpdatedAt sets the "updated_at" field if the given value is not nil.

func (*ItemUpdateOne) SetNillableWorkspaceRef

func (_u *ItemUpdateOne) SetNillableWorkspaceRef(v *string) *ItemUpdateOne

SetNillableWorkspaceRef sets the "workspace_ref" field if the given value is not nil.

func (*ItemUpdateOne) SetOwnerEmail

func (_u *ItemUpdateOne) SetOwnerEmail(v string) *ItemUpdateOne

SetOwnerEmail sets the "owner_email" field.

func (*ItemUpdateOne) SetOwnerID

func (_u *ItemUpdateOne) SetOwnerID(v string) *ItemUpdateOne

SetOwnerID sets the "owner_id" field.

func (*ItemUpdateOne) SetOwnerName

func (_u *ItemUpdateOne) SetOwnerName(v string) *ItemUpdateOne

SetOwnerName sets the "owner_name" field.

func (*ItemUpdateOne) SetParentID

func (_u *ItemUpdateOne) SetParentID(v string) *ItemUpdateOne

SetParentID sets the "parent_id" field.

func (*ItemUpdateOne) SetProgress

func (_u *ItemUpdateOne) SetProgress(v float64) *ItemUpdateOne

SetProgress sets the "progress" field.

func (*ItemUpdateOne) SetProvider

func (_u *ItemUpdateOne) SetProvider(v string) *ItemUpdateOne

SetProvider sets the "provider" field.

func (*ItemUpdateOne) SetReleaseID

func (_u *ItemUpdateOne) SetReleaseID(v string) *ItemUpdateOne

SetReleaseID sets the "release_id" field.

func (*ItemUpdateOne) SetRice

func (_u *ItemUpdateOne) SetRice(v map[string]float64) *ItemUpdateOne

SetRice sets the "rice" field.

func (*ItemUpdateOne) SetSourceID

func (_u *ItemUpdateOne) SetSourceID(v string) *ItemUpdateOne

SetSourceID sets the "source_id" field.

func (*ItemUpdateOne) SetSourceRef

func (_u *ItemUpdateOne) SetSourceRef(v string) *ItemUpdateOne

SetSourceRef sets the "source_ref" field.

func (*ItemUpdateOne) SetSourceURL

func (_u *ItemUpdateOne) SetSourceURL(v string) *ItemUpdateOne

SetSourceURL sets the "source_url" field.

func (*ItemUpdateOne) SetStartDate

func (_u *ItemUpdateOne) SetStartDate(v time.Time) *ItemUpdateOne

SetStartDate sets the "start_date" field.

func (*ItemUpdateOne) SetStatusCategory

func (_u *ItemUpdateOne) SetStatusCategory(v string) *ItemUpdateOne

SetStatusCategory sets the "status_category" field.

func (*ItemUpdateOne) SetStatusComplete

func (_u *ItemUpdateOne) SetStatusComplete(v bool) *ItemUpdateOne

SetStatusComplete sets the "status_complete" field.

func (*ItemUpdateOne) SetStatusID

func (_u *ItemUpdateOne) SetStatusID(v string) *ItemUpdateOne

SetStatusID sets the "status_id" field.

func (*ItemUpdateOne) SetStatusName

func (_u *ItemUpdateOne) SetStatusName(v string) *ItemUpdateOne

SetStatusName sets the "status_name" field.

func (*ItemUpdateOne) SetSyncedAt

func (_u *ItemUpdateOne) SetSyncedAt(v time.Time) *ItemUpdateOne

SetSyncedAt sets the "synced_at" field.

func (*ItemUpdateOne) SetTags

func (_u *ItemUpdateOne) SetTags(v []string) *ItemUpdateOne

SetTags sets the "tags" field.

func (*ItemUpdateOne) SetUpdatedAt

func (_u *ItemUpdateOne) SetUpdatedAt(v time.Time) *ItemUpdateOne

SetUpdatedAt sets the "updated_at" field.

func (*ItemUpdateOne) SetWorkspaceRef

func (_u *ItemUpdateOne) SetWorkspaceRef(v string) *ItemUpdateOne

SetWorkspaceRef sets the "workspace_ref" field.

func (*ItemUpdateOne) Where

func (_u *ItemUpdateOne) Where(ps ...predicate.Item) *ItemUpdateOne

Where appends a list predicates to the ItemUpdate builder.

type ItemUpsert

type ItemUpsert struct {
	*sql.UpdateSet
}

ItemUpsert is the "OnConflict" setter.

func (*ItemUpsert) AddProgress

func (u *ItemUpsert) AddProgress(v float64) *ItemUpsert

AddProgress adds v to the "progress" field.

func (*ItemUpsert) ClearCreatedAt

func (u *ItemUpsert) ClearCreatedAt() *ItemUpsert

ClearCreatedAt clears the value of the "created_at" field.

func (*ItemUpsert) ClearCustomFields

func (u *ItemUpsert) ClearCustomFields() *ItemUpsert

ClearCustomFields clears the value of the "custom_fields" field.

func (*ItemUpsert) ClearDescription

func (u *ItemUpsert) ClearDescription() *ItemUpsert

ClearDescription clears the value of the "description" field.

func (*ItemUpsert) ClearDueDate

func (u *ItemUpsert) ClearDueDate() *ItemUpsert

ClearDueDate clears the value of the "due_date" field.

func (*ItemUpsert) ClearKano

func (u *ItemUpsert) ClearKano() *ItemUpsert

ClearKano clears the value of the "kano" field.

func (*ItemUpsert) ClearMetadata

func (u *ItemUpsert) ClearMetadata() *ItemUpsert

ClearMetadata clears the value of the "metadata" field.

func (*ItemUpsert) ClearMoscow

func (u *ItemUpsert) ClearMoscow() *ItemUpsert

ClearMoscow clears the value of the "moscow" field.

func (*ItemUpsert) ClearName

func (u *ItemUpsert) ClearName() *ItemUpsert

ClearName clears the value of the "name" field.

func (*ItemUpsert) ClearOwnerEmail

func (u *ItemUpsert) ClearOwnerEmail() *ItemUpsert

ClearOwnerEmail clears the value of the "owner_email" field.

func (*ItemUpsert) ClearOwnerID

func (u *ItemUpsert) ClearOwnerID() *ItemUpsert

ClearOwnerID clears the value of the "owner_id" field.

func (*ItemUpsert) ClearOwnerName

func (u *ItemUpsert) ClearOwnerName() *ItemUpsert

ClearOwnerName clears the value of the "owner_name" field.

func (*ItemUpsert) ClearParentID

func (u *ItemUpsert) ClearParentID() *ItemUpsert

ClearParentID clears the value of the "parent_id" field.

func (*ItemUpsert) ClearProgress

func (u *ItemUpsert) ClearProgress() *ItemUpsert

ClearProgress clears the value of the "progress" field.

func (*ItemUpsert) ClearReleaseID

func (u *ItemUpsert) ClearReleaseID() *ItemUpsert

ClearReleaseID clears the value of the "release_id" field.

func (*ItemUpsert) ClearRice

func (u *ItemUpsert) ClearRice() *ItemUpsert

ClearRice clears the value of the "rice" field.

func (*ItemUpsert) ClearSourceRef

func (u *ItemUpsert) ClearSourceRef() *ItemUpsert

ClearSourceRef clears the value of the "source_ref" field.

func (*ItemUpsert) ClearSourceURL

func (u *ItemUpsert) ClearSourceURL() *ItemUpsert

ClearSourceURL clears the value of the "source_url" field.

func (*ItemUpsert) ClearStartDate

func (u *ItemUpsert) ClearStartDate() *ItemUpsert

ClearStartDate clears the value of the "start_date" field.

func (*ItemUpsert) ClearStatusCategory

func (u *ItemUpsert) ClearStatusCategory() *ItemUpsert

ClearStatusCategory clears the value of the "status_category" field.

func (*ItemUpsert) ClearStatusID

func (u *ItemUpsert) ClearStatusID() *ItemUpsert

ClearStatusID clears the value of the "status_id" field.

func (*ItemUpsert) ClearStatusName

func (u *ItemUpsert) ClearStatusName() *ItemUpsert

ClearStatusName clears the value of the "status_name" field.

func (*ItemUpsert) ClearTags

func (u *ItemUpsert) ClearTags() *ItemUpsert

ClearTags clears the value of the "tags" field.

func (*ItemUpsert) ClearUpdatedAt

func (u *ItemUpsert) ClearUpdatedAt() *ItemUpsert

ClearUpdatedAt clears the value of the "updated_at" field.

func (*ItemUpsert) ClearWorkspaceRef

func (u *ItemUpsert) ClearWorkspaceRef() *ItemUpsert

ClearWorkspaceRef clears the value of the "workspace_ref" field.

func (*ItemUpsert) SetCreatedAt

func (u *ItemUpsert) SetCreatedAt(v time.Time) *ItemUpsert

SetCreatedAt sets the "created_at" field.

func (*ItemUpsert) SetCustomFields

func (u *ItemUpsert) SetCustomFields(v []map[string]interface{}) *ItemUpsert

SetCustomFields sets the "custom_fields" field.

func (*ItemUpsert) SetDescription

func (u *ItemUpsert) SetDescription(v string) *ItemUpsert

SetDescription sets the "description" field.

func (*ItemUpsert) SetDueDate

func (u *ItemUpsert) SetDueDate(v time.Time) *ItemUpsert

SetDueDate sets the "due_date" field.

func (*ItemUpsert) SetKano

func (u *ItemUpsert) SetKano(v string) *ItemUpsert

SetKano sets the "kano" field.

func (*ItemUpsert) SetKind

func (u *ItemUpsert) SetKind(v string) *ItemUpsert

SetKind sets the "kind" field.

func (*ItemUpsert) SetMetadata

func (u *ItemUpsert) SetMetadata(v map[string]interface{}) *ItemUpsert

SetMetadata sets the "metadata" field.

func (*ItemUpsert) SetMoscow

func (u *ItemUpsert) SetMoscow(v string) *ItemUpsert

SetMoscow sets the "moscow" field.

func (*ItemUpsert) SetName

func (u *ItemUpsert) SetName(v string) *ItemUpsert

SetName sets the "name" field.

func (*ItemUpsert) SetOwnerEmail

func (u *ItemUpsert) SetOwnerEmail(v string) *ItemUpsert

SetOwnerEmail sets the "owner_email" field.

func (*ItemUpsert) SetOwnerID

func (u *ItemUpsert) SetOwnerID(v string) *ItemUpsert

SetOwnerID sets the "owner_id" field.

func (*ItemUpsert) SetOwnerName

func (u *ItemUpsert) SetOwnerName(v string) *ItemUpsert

SetOwnerName sets the "owner_name" field.

func (*ItemUpsert) SetParentID

func (u *ItemUpsert) SetParentID(v string) *ItemUpsert

SetParentID sets the "parent_id" field.

func (*ItemUpsert) SetProgress

func (u *ItemUpsert) SetProgress(v float64) *ItemUpsert

SetProgress sets the "progress" field.

func (*ItemUpsert) SetProvider

func (u *ItemUpsert) SetProvider(v string) *ItemUpsert

SetProvider sets the "provider" field.

func (*ItemUpsert) SetReleaseID

func (u *ItemUpsert) SetReleaseID(v string) *ItemUpsert

SetReleaseID sets the "release_id" field.

func (*ItemUpsert) SetRice

func (u *ItemUpsert) SetRice(v map[string]float64) *ItemUpsert

SetRice sets the "rice" field.

func (*ItemUpsert) SetSourceID

func (u *ItemUpsert) SetSourceID(v string) *ItemUpsert

SetSourceID sets the "source_id" field.

func (*ItemUpsert) SetSourceRef

func (u *ItemUpsert) SetSourceRef(v string) *ItemUpsert

SetSourceRef sets the "source_ref" field.

func (*ItemUpsert) SetSourceURL

func (u *ItemUpsert) SetSourceURL(v string) *ItemUpsert

SetSourceURL sets the "source_url" field.

func (*ItemUpsert) SetStartDate

func (u *ItemUpsert) SetStartDate(v time.Time) *ItemUpsert

SetStartDate sets the "start_date" field.

func (*ItemUpsert) SetStatusCategory

func (u *ItemUpsert) SetStatusCategory(v string) *ItemUpsert

SetStatusCategory sets the "status_category" field.

func (*ItemUpsert) SetStatusComplete

func (u *ItemUpsert) SetStatusComplete(v bool) *ItemUpsert

SetStatusComplete sets the "status_complete" field.

func (*ItemUpsert) SetStatusID

func (u *ItemUpsert) SetStatusID(v string) *ItemUpsert

SetStatusID sets the "status_id" field.

func (*ItemUpsert) SetStatusName

func (u *ItemUpsert) SetStatusName(v string) *ItemUpsert

SetStatusName sets the "status_name" field.

func (*ItemUpsert) SetSyncedAt

func (u *ItemUpsert) SetSyncedAt(v time.Time) *ItemUpsert

SetSyncedAt sets the "synced_at" field.

func (*ItemUpsert) SetTags

func (u *ItemUpsert) SetTags(v []string) *ItemUpsert

SetTags sets the "tags" field.

func (*ItemUpsert) SetUpdatedAt

func (u *ItemUpsert) SetUpdatedAt(v time.Time) *ItemUpsert

SetUpdatedAt sets the "updated_at" field.

func (*ItemUpsert) SetWorkspaceRef

func (u *ItemUpsert) SetWorkspaceRef(v string) *ItemUpsert

SetWorkspaceRef sets the "workspace_ref" field.

func (*ItemUpsert) UpdateCreatedAt

func (u *ItemUpsert) UpdateCreatedAt() *ItemUpsert

UpdateCreatedAt sets the "created_at" field to the value that was provided on create.

func (*ItemUpsert) UpdateCustomFields

func (u *ItemUpsert) UpdateCustomFields() *ItemUpsert

UpdateCustomFields sets the "custom_fields" field to the value that was provided on create.

func (*ItemUpsert) UpdateDescription

func (u *ItemUpsert) UpdateDescription() *ItemUpsert

UpdateDescription sets the "description" field to the value that was provided on create.

func (*ItemUpsert) UpdateDueDate

func (u *ItemUpsert) UpdateDueDate() *ItemUpsert

UpdateDueDate sets the "due_date" field to the value that was provided on create.

func (*ItemUpsert) UpdateKano

func (u *ItemUpsert) UpdateKano() *ItemUpsert

UpdateKano sets the "kano" field to the value that was provided on create.

func (*ItemUpsert) UpdateKind

func (u *ItemUpsert) UpdateKind() *ItemUpsert

UpdateKind sets the "kind" field to the value that was provided on create.

func (*ItemUpsert) UpdateMetadata

func (u *ItemUpsert) UpdateMetadata() *ItemUpsert

UpdateMetadata sets the "metadata" field to the value that was provided on create.

func (*ItemUpsert) UpdateMoscow

func (u *ItemUpsert) UpdateMoscow() *ItemUpsert

UpdateMoscow sets the "moscow" field to the value that was provided on create.

func (*ItemUpsert) UpdateName

func (u *ItemUpsert) UpdateName() *ItemUpsert

UpdateName sets the "name" field to the value that was provided on create.

func (*ItemUpsert) UpdateOwnerEmail

func (u *ItemUpsert) UpdateOwnerEmail() *ItemUpsert

UpdateOwnerEmail sets the "owner_email" field to the value that was provided on create.

func (*ItemUpsert) UpdateOwnerID

func (u *ItemUpsert) UpdateOwnerID() *ItemUpsert

UpdateOwnerID sets the "owner_id" field to the value that was provided on create.

func (*ItemUpsert) UpdateOwnerName

func (u *ItemUpsert) UpdateOwnerName() *ItemUpsert

UpdateOwnerName sets the "owner_name" field to the value that was provided on create.

func (*ItemUpsert) UpdateParentID

func (u *ItemUpsert) UpdateParentID() *ItemUpsert

UpdateParentID sets the "parent_id" field to the value that was provided on create.

func (*ItemUpsert) UpdateProgress

func (u *ItemUpsert) UpdateProgress() *ItemUpsert

UpdateProgress sets the "progress" field to the value that was provided on create.

func (*ItemUpsert) UpdateProvider

func (u *ItemUpsert) UpdateProvider() *ItemUpsert

UpdateProvider sets the "provider" field to the value that was provided on create.

func (*ItemUpsert) UpdateReleaseID

func (u *ItemUpsert) UpdateReleaseID() *ItemUpsert

UpdateReleaseID sets the "release_id" field to the value that was provided on create.

func (*ItemUpsert) UpdateRice

func (u *ItemUpsert) UpdateRice() *ItemUpsert

UpdateRice sets the "rice" field to the value that was provided on create.

func (*ItemUpsert) UpdateSourceID

func (u *ItemUpsert) UpdateSourceID() *ItemUpsert

UpdateSourceID sets the "source_id" field to the value that was provided on create.

func (*ItemUpsert) UpdateSourceRef

func (u *ItemUpsert) UpdateSourceRef() *ItemUpsert

UpdateSourceRef sets the "source_ref" field to the value that was provided on create.

func (*ItemUpsert) UpdateSourceURL

func (u *ItemUpsert) UpdateSourceURL() *ItemUpsert

UpdateSourceURL sets the "source_url" field to the value that was provided on create.

func (*ItemUpsert) UpdateStartDate

func (u *ItemUpsert) UpdateStartDate() *ItemUpsert

UpdateStartDate sets the "start_date" field to the value that was provided on create.

func (*ItemUpsert) UpdateStatusCategory

func (u *ItemUpsert) UpdateStatusCategory() *ItemUpsert

UpdateStatusCategory sets the "status_category" field to the value that was provided on create.

func (*ItemUpsert) UpdateStatusComplete

func (u *ItemUpsert) UpdateStatusComplete() *ItemUpsert

UpdateStatusComplete sets the "status_complete" field to the value that was provided on create.

func (*ItemUpsert) UpdateStatusID

func (u *ItemUpsert) UpdateStatusID() *ItemUpsert

UpdateStatusID sets the "status_id" field to the value that was provided on create.

func (*ItemUpsert) UpdateStatusName

func (u *ItemUpsert) UpdateStatusName() *ItemUpsert

UpdateStatusName sets the "status_name" field to the value that was provided on create.

func (*ItemUpsert) UpdateSyncedAt

func (u *ItemUpsert) UpdateSyncedAt() *ItemUpsert

UpdateSyncedAt sets the "synced_at" field to the value that was provided on create.

func (*ItemUpsert) UpdateTags

func (u *ItemUpsert) UpdateTags() *ItemUpsert

UpdateTags sets the "tags" field to the value that was provided on create.

func (*ItemUpsert) UpdateUpdatedAt

func (u *ItemUpsert) UpdateUpdatedAt() *ItemUpsert

UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.

func (*ItemUpsert) UpdateWorkspaceRef

func (u *ItemUpsert) UpdateWorkspaceRef() *ItemUpsert

UpdateWorkspaceRef sets the "workspace_ref" field to the value that was provided on create.

type ItemUpsertBulk

type ItemUpsertBulk struct {
	// contains filtered or unexported fields
}

ItemUpsertBulk is the builder for "upsert"-ing a bulk of Item nodes.

func (*ItemUpsertBulk) AddProgress

func (u *ItemUpsertBulk) AddProgress(v float64) *ItemUpsertBulk

AddProgress adds v to the "progress" field.

func (*ItemUpsertBulk) ClearCreatedAt

func (u *ItemUpsertBulk) ClearCreatedAt() *ItemUpsertBulk

ClearCreatedAt clears the value of the "created_at" field.

func (*ItemUpsertBulk) ClearCustomFields

func (u *ItemUpsertBulk) ClearCustomFields() *ItemUpsertBulk

ClearCustomFields clears the value of the "custom_fields" field.

func (*ItemUpsertBulk) ClearDescription

func (u *ItemUpsertBulk) ClearDescription() *ItemUpsertBulk

ClearDescription clears the value of the "description" field.

func (*ItemUpsertBulk) ClearDueDate

func (u *ItemUpsertBulk) ClearDueDate() *ItemUpsertBulk

ClearDueDate clears the value of the "due_date" field.

func (*ItemUpsertBulk) ClearKano

func (u *ItemUpsertBulk) ClearKano() *ItemUpsertBulk

ClearKano clears the value of the "kano" field.

func (*ItemUpsertBulk) ClearMetadata

func (u *ItemUpsertBulk) ClearMetadata() *ItemUpsertBulk

ClearMetadata clears the value of the "metadata" field.

func (*ItemUpsertBulk) ClearMoscow

func (u *ItemUpsertBulk) ClearMoscow() *ItemUpsertBulk

ClearMoscow clears the value of the "moscow" field.

func (*ItemUpsertBulk) ClearName

func (u *ItemUpsertBulk) ClearName() *ItemUpsertBulk

ClearName clears the value of the "name" field.

func (*ItemUpsertBulk) ClearOwnerEmail

func (u *ItemUpsertBulk) ClearOwnerEmail() *ItemUpsertBulk

ClearOwnerEmail clears the value of the "owner_email" field.

func (*ItemUpsertBulk) ClearOwnerID

func (u *ItemUpsertBulk) ClearOwnerID() *ItemUpsertBulk

ClearOwnerID clears the value of the "owner_id" field.

func (*ItemUpsertBulk) ClearOwnerName

func (u *ItemUpsertBulk) ClearOwnerName() *ItemUpsertBulk

ClearOwnerName clears the value of the "owner_name" field.

func (*ItemUpsertBulk) ClearParentID

func (u *ItemUpsertBulk) ClearParentID() *ItemUpsertBulk

ClearParentID clears the value of the "parent_id" field.

func (*ItemUpsertBulk) ClearProgress

func (u *ItemUpsertBulk) ClearProgress() *ItemUpsertBulk

ClearProgress clears the value of the "progress" field.

func (*ItemUpsertBulk) ClearReleaseID

func (u *ItemUpsertBulk) ClearReleaseID() *ItemUpsertBulk

ClearReleaseID clears the value of the "release_id" field.

func (*ItemUpsertBulk) ClearRice

func (u *ItemUpsertBulk) ClearRice() *ItemUpsertBulk

ClearRice clears the value of the "rice" field.

func (*ItemUpsertBulk) ClearSourceRef

func (u *ItemUpsertBulk) ClearSourceRef() *ItemUpsertBulk

ClearSourceRef clears the value of the "source_ref" field.

func (*ItemUpsertBulk) ClearSourceURL

func (u *ItemUpsertBulk) ClearSourceURL() *ItemUpsertBulk

ClearSourceURL clears the value of the "source_url" field.

func (*ItemUpsertBulk) ClearStartDate

func (u *ItemUpsertBulk) ClearStartDate() *ItemUpsertBulk

ClearStartDate clears the value of the "start_date" field.

func (*ItemUpsertBulk) ClearStatusCategory

func (u *ItemUpsertBulk) ClearStatusCategory() *ItemUpsertBulk

ClearStatusCategory clears the value of the "status_category" field.

func (*ItemUpsertBulk) ClearStatusID

func (u *ItemUpsertBulk) ClearStatusID() *ItemUpsertBulk

ClearStatusID clears the value of the "status_id" field.

func (*ItemUpsertBulk) ClearStatusName

func (u *ItemUpsertBulk) ClearStatusName() *ItemUpsertBulk

ClearStatusName clears the value of the "status_name" field.

func (*ItemUpsertBulk) ClearTags

func (u *ItemUpsertBulk) ClearTags() *ItemUpsertBulk

ClearTags clears the value of the "tags" field.

func (*ItemUpsertBulk) ClearUpdatedAt

func (u *ItemUpsertBulk) ClearUpdatedAt() *ItemUpsertBulk

ClearUpdatedAt clears the value of the "updated_at" field.

func (*ItemUpsertBulk) ClearWorkspaceRef

func (u *ItemUpsertBulk) ClearWorkspaceRef() *ItemUpsertBulk

ClearWorkspaceRef clears the value of the "workspace_ref" field.

func (*ItemUpsertBulk) DoNothing

func (u *ItemUpsertBulk) DoNothing() *ItemUpsertBulk

DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.

func (*ItemUpsertBulk) Exec

func (u *ItemUpsertBulk) Exec(ctx context.Context) error

Exec executes the query.

func (*ItemUpsertBulk) ExecX

func (u *ItemUpsertBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ItemUpsertBulk) Ignore

func (u *ItemUpsertBulk) Ignore() *ItemUpsertBulk

Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:

client.Item.Create().
	OnConflict(sql.ResolveWithIgnore()).
	Exec(ctx)

func (*ItemUpsertBulk) SetCreatedAt

func (u *ItemUpsertBulk) SetCreatedAt(v time.Time) *ItemUpsertBulk

SetCreatedAt sets the "created_at" field.

func (*ItemUpsertBulk) SetCustomFields

func (u *ItemUpsertBulk) SetCustomFields(v []map[string]interface{}) *ItemUpsertBulk

SetCustomFields sets the "custom_fields" field.

func (*ItemUpsertBulk) SetDescription

func (u *ItemUpsertBulk) SetDescription(v string) *ItemUpsertBulk

SetDescription sets the "description" field.

func (*ItemUpsertBulk) SetDueDate

func (u *ItemUpsertBulk) SetDueDate(v time.Time) *ItemUpsertBulk

SetDueDate sets the "due_date" field.

func (*ItemUpsertBulk) SetKano

func (u *ItemUpsertBulk) SetKano(v string) *ItemUpsertBulk

SetKano sets the "kano" field.

func (*ItemUpsertBulk) SetKind

func (u *ItemUpsertBulk) SetKind(v string) *ItemUpsertBulk

SetKind sets the "kind" field.

func (*ItemUpsertBulk) SetMetadata

func (u *ItemUpsertBulk) SetMetadata(v map[string]interface{}) *ItemUpsertBulk

SetMetadata sets the "metadata" field.

func (*ItemUpsertBulk) SetMoscow

func (u *ItemUpsertBulk) SetMoscow(v string) *ItemUpsertBulk

SetMoscow sets the "moscow" field.

func (*ItemUpsertBulk) SetName

func (u *ItemUpsertBulk) SetName(v string) *ItemUpsertBulk

SetName sets the "name" field.

func (*ItemUpsertBulk) SetOwnerEmail

func (u *ItemUpsertBulk) SetOwnerEmail(v string) *ItemUpsertBulk

SetOwnerEmail sets the "owner_email" field.

func (*ItemUpsertBulk) SetOwnerID

func (u *ItemUpsertBulk) SetOwnerID(v string) *ItemUpsertBulk

SetOwnerID sets the "owner_id" field.

func (*ItemUpsertBulk) SetOwnerName

func (u *ItemUpsertBulk) SetOwnerName(v string) *ItemUpsertBulk

SetOwnerName sets the "owner_name" field.

func (*ItemUpsertBulk) SetParentID

func (u *ItemUpsertBulk) SetParentID(v string) *ItemUpsertBulk

SetParentID sets the "parent_id" field.

func (*ItemUpsertBulk) SetProgress

func (u *ItemUpsertBulk) SetProgress(v float64) *ItemUpsertBulk

SetProgress sets the "progress" field.

func (*ItemUpsertBulk) SetProvider

func (u *ItemUpsertBulk) SetProvider(v string) *ItemUpsertBulk

SetProvider sets the "provider" field.

func (*ItemUpsertBulk) SetReleaseID

func (u *ItemUpsertBulk) SetReleaseID(v string) *ItemUpsertBulk

SetReleaseID sets the "release_id" field.

func (*ItemUpsertBulk) SetRice

func (u *ItemUpsertBulk) SetRice(v map[string]float64) *ItemUpsertBulk

SetRice sets the "rice" field.

func (*ItemUpsertBulk) SetSourceID

func (u *ItemUpsertBulk) SetSourceID(v string) *ItemUpsertBulk

SetSourceID sets the "source_id" field.

func (*ItemUpsertBulk) SetSourceRef

func (u *ItemUpsertBulk) SetSourceRef(v string) *ItemUpsertBulk

SetSourceRef sets the "source_ref" field.

func (*ItemUpsertBulk) SetSourceURL

func (u *ItemUpsertBulk) SetSourceURL(v string) *ItemUpsertBulk

SetSourceURL sets the "source_url" field.

func (*ItemUpsertBulk) SetStartDate

func (u *ItemUpsertBulk) SetStartDate(v time.Time) *ItemUpsertBulk

SetStartDate sets the "start_date" field.

func (*ItemUpsertBulk) SetStatusCategory

func (u *ItemUpsertBulk) SetStatusCategory(v string) *ItemUpsertBulk

SetStatusCategory sets the "status_category" field.

func (*ItemUpsertBulk) SetStatusComplete

func (u *ItemUpsertBulk) SetStatusComplete(v bool) *ItemUpsertBulk

SetStatusComplete sets the "status_complete" field.

func (*ItemUpsertBulk) SetStatusID

func (u *ItemUpsertBulk) SetStatusID(v string) *ItemUpsertBulk

SetStatusID sets the "status_id" field.

func (*ItemUpsertBulk) SetStatusName

func (u *ItemUpsertBulk) SetStatusName(v string) *ItemUpsertBulk

SetStatusName sets the "status_name" field.

func (*ItemUpsertBulk) SetSyncedAt

func (u *ItemUpsertBulk) SetSyncedAt(v time.Time) *ItemUpsertBulk

SetSyncedAt sets the "synced_at" field.

func (*ItemUpsertBulk) SetTags

func (u *ItemUpsertBulk) SetTags(v []string) *ItemUpsertBulk

SetTags sets the "tags" field.

func (*ItemUpsertBulk) SetUpdatedAt

func (u *ItemUpsertBulk) SetUpdatedAt(v time.Time) *ItemUpsertBulk

SetUpdatedAt sets the "updated_at" field.

func (*ItemUpsertBulk) SetWorkspaceRef

func (u *ItemUpsertBulk) SetWorkspaceRef(v string) *ItemUpsertBulk

SetWorkspaceRef sets the "workspace_ref" field.

func (*ItemUpsertBulk) Update

func (u *ItemUpsertBulk) Update(set func(*ItemUpsert)) *ItemUpsertBulk

Update allows overriding fields `UPDATE` values. See the ItemCreateBulk.OnConflict documentation for more info.

func (*ItemUpsertBulk) UpdateCreatedAt

func (u *ItemUpsertBulk) UpdateCreatedAt() *ItemUpsertBulk

UpdateCreatedAt sets the "created_at" field to the value that was provided on create.

func (*ItemUpsertBulk) UpdateCustomFields

func (u *ItemUpsertBulk) UpdateCustomFields() *ItemUpsertBulk

UpdateCustomFields sets the "custom_fields" field to the value that was provided on create.

func (*ItemUpsertBulk) UpdateDescription

func (u *ItemUpsertBulk) UpdateDescription() *ItemUpsertBulk

UpdateDescription sets the "description" field to the value that was provided on create.

func (*ItemUpsertBulk) UpdateDueDate

func (u *ItemUpsertBulk) UpdateDueDate() *ItemUpsertBulk

UpdateDueDate sets the "due_date" field to the value that was provided on create.

func (*ItemUpsertBulk) UpdateKano

func (u *ItemUpsertBulk) UpdateKano() *ItemUpsertBulk

UpdateKano sets the "kano" field to the value that was provided on create.

func (*ItemUpsertBulk) UpdateKind

func (u *ItemUpsertBulk) UpdateKind() *ItemUpsertBulk

UpdateKind sets the "kind" field to the value that was provided on create.

func (*ItemUpsertBulk) UpdateMetadata

func (u *ItemUpsertBulk) UpdateMetadata() *ItemUpsertBulk

UpdateMetadata sets the "metadata" field to the value that was provided on create.

func (*ItemUpsertBulk) UpdateMoscow

func (u *ItemUpsertBulk) UpdateMoscow() *ItemUpsertBulk

UpdateMoscow sets the "moscow" field to the value that was provided on create.

func (*ItemUpsertBulk) UpdateName

func (u *ItemUpsertBulk) UpdateName() *ItemUpsertBulk

UpdateName sets the "name" field to the value that was provided on create.

func (*ItemUpsertBulk) UpdateNewValues

func (u *ItemUpsertBulk) UpdateNewValues() *ItemUpsertBulk

UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:

client.Item.Create().
	OnConflict(
		sql.ResolveWithNewValues(),
		sql.ResolveWith(func(u *sql.UpdateSet) {
			u.SetIgnore(item.FieldID)
		}),
	).
	Exec(ctx)

func (*ItemUpsertBulk) UpdateOwnerEmail

func (u *ItemUpsertBulk) UpdateOwnerEmail() *ItemUpsertBulk

UpdateOwnerEmail sets the "owner_email" field to the value that was provided on create.

func (*ItemUpsertBulk) UpdateOwnerID

func (u *ItemUpsertBulk) UpdateOwnerID() *ItemUpsertBulk

UpdateOwnerID sets the "owner_id" field to the value that was provided on create.

func (*ItemUpsertBulk) UpdateOwnerName

func (u *ItemUpsertBulk) UpdateOwnerName() *ItemUpsertBulk

UpdateOwnerName sets the "owner_name" field to the value that was provided on create.

func (*ItemUpsertBulk) UpdateParentID

func (u *ItemUpsertBulk) UpdateParentID() *ItemUpsertBulk

UpdateParentID sets the "parent_id" field to the value that was provided on create.

func (*ItemUpsertBulk) UpdateProgress

func (u *ItemUpsertBulk) UpdateProgress() *ItemUpsertBulk

UpdateProgress sets the "progress" field to the value that was provided on create.

func (*ItemUpsertBulk) UpdateProvider

func (u *ItemUpsertBulk) UpdateProvider() *ItemUpsertBulk

UpdateProvider sets the "provider" field to the value that was provided on create.

func (*ItemUpsertBulk) UpdateReleaseID

func (u *ItemUpsertBulk) UpdateReleaseID() *ItemUpsertBulk

UpdateReleaseID sets the "release_id" field to the value that was provided on create.

func (*ItemUpsertBulk) UpdateRice

func (u *ItemUpsertBulk) UpdateRice() *ItemUpsertBulk

UpdateRice sets the "rice" field to the value that was provided on create.

func (*ItemUpsertBulk) UpdateSourceID

func (u *ItemUpsertBulk) UpdateSourceID() *ItemUpsertBulk

UpdateSourceID sets the "source_id" field to the value that was provided on create.

func (*ItemUpsertBulk) UpdateSourceRef

func (u *ItemUpsertBulk) UpdateSourceRef() *ItemUpsertBulk

UpdateSourceRef sets the "source_ref" field to the value that was provided on create.

func (*ItemUpsertBulk) UpdateSourceURL

func (u *ItemUpsertBulk) UpdateSourceURL() *ItemUpsertBulk

UpdateSourceURL sets the "source_url" field to the value that was provided on create.

func (*ItemUpsertBulk) UpdateStartDate

func (u *ItemUpsertBulk) UpdateStartDate() *ItemUpsertBulk

UpdateStartDate sets the "start_date" field to the value that was provided on create.

func (*ItemUpsertBulk) UpdateStatusCategory

func (u *ItemUpsertBulk) UpdateStatusCategory() *ItemUpsertBulk

UpdateStatusCategory sets the "status_category" field to the value that was provided on create.

func (*ItemUpsertBulk) UpdateStatusComplete

func (u *ItemUpsertBulk) UpdateStatusComplete() *ItemUpsertBulk

UpdateStatusComplete sets the "status_complete" field to the value that was provided on create.

func (*ItemUpsertBulk) UpdateStatusID

func (u *ItemUpsertBulk) UpdateStatusID() *ItemUpsertBulk

UpdateStatusID sets the "status_id" field to the value that was provided on create.

func (*ItemUpsertBulk) UpdateStatusName

func (u *ItemUpsertBulk) UpdateStatusName() *ItemUpsertBulk

UpdateStatusName sets the "status_name" field to the value that was provided on create.

func (*ItemUpsertBulk) UpdateSyncedAt

func (u *ItemUpsertBulk) UpdateSyncedAt() *ItemUpsertBulk

UpdateSyncedAt sets the "synced_at" field to the value that was provided on create.

func (*ItemUpsertBulk) UpdateTags

func (u *ItemUpsertBulk) UpdateTags() *ItemUpsertBulk

UpdateTags sets the "tags" field to the value that was provided on create.

func (*ItemUpsertBulk) UpdateUpdatedAt

func (u *ItemUpsertBulk) UpdateUpdatedAt() *ItemUpsertBulk

UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.

func (*ItemUpsertBulk) UpdateWorkspaceRef

func (u *ItemUpsertBulk) UpdateWorkspaceRef() *ItemUpsertBulk

UpdateWorkspaceRef sets the "workspace_ref" field to the value that was provided on create.

type ItemUpsertOne

type ItemUpsertOne struct {
	// contains filtered or unexported fields
}

ItemUpsertOne is the builder for "upsert"-ing

one Item node.

func (*ItemUpsertOne) AddProgress

func (u *ItemUpsertOne) AddProgress(v float64) *ItemUpsertOne

AddProgress adds v to the "progress" field.

func (*ItemUpsertOne) ClearCreatedAt

func (u *ItemUpsertOne) ClearCreatedAt() *ItemUpsertOne

ClearCreatedAt clears the value of the "created_at" field.

func (*ItemUpsertOne) ClearCustomFields

func (u *ItemUpsertOne) ClearCustomFields() *ItemUpsertOne

ClearCustomFields clears the value of the "custom_fields" field.

func (*ItemUpsertOne) ClearDescription

func (u *ItemUpsertOne) ClearDescription() *ItemUpsertOne

ClearDescription clears the value of the "description" field.

func (*ItemUpsertOne) ClearDueDate

func (u *ItemUpsertOne) ClearDueDate() *ItemUpsertOne

ClearDueDate clears the value of the "due_date" field.

func (*ItemUpsertOne) ClearKano

func (u *ItemUpsertOne) ClearKano() *ItemUpsertOne

ClearKano clears the value of the "kano" field.

func (*ItemUpsertOne) ClearMetadata

func (u *ItemUpsertOne) ClearMetadata() *ItemUpsertOne

ClearMetadata clears the value of the "metadata" field.

func (*ItemUpsertOne) ClearMoscow

func (u *ItemUpsertOne) ClearMoscow() *ItemUpsertOne

ClearMoscow clears the value of the "moscow" field.

func (*ItemUpsertOne) ClearName

func (u *ItemUpsertOne) ClearName() *ItemUpsertOne

ClearName clears the value of the "name" field.

func (*ItemUpsertOne) ClearOwnerEmail

func (u *ItemUpsertOne) ClearOwnerEmail() *ItemUpsertOne

ClearOwnerEmail clears the value of the "owner_email" field.

func (*ItemUpsertOne) ClearOwnerID

func (u *ItemUpsertOne) ClearOwnerID() *ItemUpsertOne

ClearOwnerID clears the value of the "owner_id" field.

func (*ItemUpsertOne) ClearOwnerName

func (u *ItemUpsertOne) ClearOwnerName() *ItemUpsertOne

ClearOwnerName clears the value of the "owner_name" field.

func (*ItemUpsertOne) ClearParentID

func (u *ItemUpsertOne) ClearParentID() *ItemUpsertOne

ClearParentID clears the value of the "parent_id" field.

func (*ItemUpsertOne) ClearProgress

func (u *ItemUpsertOne) ClearProgress() *ItemUpsertOne

ClearProgress clears the value of the "progress" field.

func (*ItemUpsertOne) ClearReleaseID

func (u *ItemUpsertOne) ClearReleaseID() *ItemUpsertOne

ClearReleaseID clears the value of the "release_id" field.

func (*ItemUpsertOne) ClearRice

func (u *ItemUpsertOne) ClearRice() *ItemUpsertOne

ClearRice clears the value of the "rice" field.

func (*ItemUpsertOne) ClearSourceRef

func (u *ItemUpsertOne) ClearSourceRef() *ItemUpsertOne

ClearSourceRef clears the value of the "source_ref" field.

func (*ItemUpsertOne) ClearSourceURL

func (u *ItemUpsertOne) ClearSourceURL() *ItemUpsertOne

ClearSourceURL clears the value of the "source_url" field.

func (*ItemUpsertOne) ClearStartDate

func (u *ItemUpsertOne) ClearStartDate() *ItemUpsertOne

ClearStartDate clears the value of the "start_date" field.

func (*ItemUpsertOne) ClearStatusCategory

func (u *ItemUpsertOne) ClearStatusCategory() *ItemUpsertOne

ClearStatusCategory clears the value of the "status_category" field.

func (*ItemUpsertOne) ClearStatusID

func (u *ItemUpsertOne) ClearStatusID() *ItemUpsertOne

ClearStatusID clears the value of the "status_id" field.

func (*ItemUpsertOne) ClearStatusName

func (u *ItemUpsertOne) ClearStatusName() *ItemUpsertOne

ClearStatusName clears the value of the "status_name" field.

func (*ItemUpsertOne) ClearTags

func (u *ItemUpsertOne) ClearTags() *ItemUpsertOne

ClearTags clears the value of the "tags" field.

func (*ItemUpsertOne) ClearUpdatedAt

func (u *ItemUpsertOne) ClearUpdatedAt() *ItemUpsertOne

ClearUpdatedAt clears the value of the "updated_at" field.

func (*ItemUpsertOne) ClearWorkspaceRef

func (u *ItemUpsertOne) ClearWorkspaceRef() *ItemUpsertOne

ClearWorkspaceRef clears the value of the "workspace_ref" field.

func (*ItemUpsertOne) DoNothing

func (u *ItemUpsertOne) DoNothing() *ItemUpsertOne

DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.

func (*ItemUpsertOne) Exec

func (u *ItemUpsertOne) Exec(ctx context.Context) error

Exec executes the query.

func (*ItemUpsertOne) ExecX

func (u *ItemUpsertOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ItemUpsertOne) ID

func (u *ItemUpsertOne) ID(ctx context.Context) (id string, err error)

Exec executes the UPSERT query and returns the inserted/updated ID.

func (*ItemUpsertOne) IDX

func (u *ItemUpsertOne) IDX(ctx context.Context) string

IDX is like ID, but panics if an error occurs.

func (*ItemUpsertOne) Ignore

func (u *ItemUpsertOne) Ignore() *ItemUpsertOne

Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:

client.Item.Create().
    OnConflict(sql.ResolveWithIgnore()).
    Exec(ctx)

func (*ItemUpsertOne) SetCreatedAt

func (u *ItemUpsertOne) SetCreatedAt(v time.Time) *ItemUpsertOne

SetCreatedAt sets the "created_at" field.

func (*ItemUpsertOne) SetCustomFields

func (u *ItemUpsertOne) SetCustomFields(v []map[string]interface{}) *ItemUpsertOne

SetCustomFields sets the "custom_fields" field.

func (*ItemUpsertOne) SetDescription

func (u *ItemUpsertOne) SetDescription(v string) *ItemUpsertOne

SetDescription sets the "description" field.

func (*ItemUpsertOne) SetDueDate

func (u *ItemUpsertOne) SetDueDate(v time.Time) *ItemUpsertOne

SetDueDate sets the "due_date" field.

func (*ItemUpsertOne) SetKano

func (u *ItemUpsertOne) SetKano(v string) *ItemUpsertOne

SetKano sets the "kano" field.

func (*ItemUpsertOne) SetKind

func (u *ItemUpsertOne) SetKind(v string) *ItemUpsertOne

SetKind sets the "kind" field.

func (*ItemUpsertOne) SetMetadata

func (u *ItemUpsertOne) SetMetadata(v map[string]interface{}) *ItemUpsertOne

SetMetadata sets the "metadata" field.

func (*ItemUpsertOne) SetMoscow

func (u *ItemUpsertOne) SetMoscow(v string) *ItemUpsertOne

SetMoscow sets the "moscow" field.

func (*ItemUpsertOne) SetName

func (u *ItemUpsertOne) SetName(v string) *ItemUpsertOne

SetName sets the "name" field.

func (*ItemUpsertOne) SetOwnerEmail

func (u *ItemUpsertOne) SetOwnerEmail(v string) *ItemUpsertOne

SetOwnerEmail sets the "owner_email" field.

func (*ItemUpsertOne) SetOwnerID

func (u *ItemUpsertOne) SetOwnerID(v string) *ItemUpsertOne

SetOwnerID sets the "owner_id" field.

func (*ItemUpsertOne) SetOwnerName

func (u *ItemUpsertOne) SetOwnerName(v string) *ItemUpsertOne

SetOwnerName sets the "owner_name" field.

func (*ItemUpsertOne) SetParentID

func (u *ItemUpsertOne) SetParentID(v string) *ItemUpsertOne

SetParentID sets the "parent_id" field.

func (*ItemUpsertOne) SetProgress

func (u *ItemUpsertOne) SetProgress(v float64) *ItemUpsertOne

SetProgress sets the "progress" field.

func (*ItemUpsertOne) SetProvider

func (u *ItemUpsertOne) SetProvider(v string) *ItemUpsertOne

SetProvider sets the "provider" field.

func (*ItemUpsertOne) SetReleaseID

func (u *ItemUpsertOne) SetReleaseID(v string) *ItemUpsertOne

SetReleaseID sets the "release_id" field.

func (*ItemUpsertOne) SetRice

func (u *ItemUpsertOne) SetRice(v map[string]float64) *ItemUpsertOne

SetRice sets the "rice" field.

func (*ItemUpsertOne) SetSourceID

func (u *ItemUpsertOne) SetSourceID(v string) *ItemUpsertOne

SetSourceID sets the "source_id" field.

func (*ItemUpsertOne) SetSourceRef

func (u *ItemUpsertOne) SetSourceRef(v string) *ItemUpsertOne

SetSourceRef sets the "source_ref" field.

func (*ItemUpsertOne) SetSourceURL

func (u *ItemUpsertOne) SetSourceURL(v string) *ItemUpsertOne

SetSourceURL sets the "source_url" field.

func (*ItemUpsertOne) SetStartDate

func (u *ItemUpsertOne) SetStartDate(v time.Time) *ItemUpsertOne

SetStartDate sets the "start_date" field.

func (*ItemUpsertOne) SetStatusCategory

func (u *ItemUpsertOne) SetStatusCategory(v string) *ItemUpsertOne

SetStatusCategory sets the "status_category" field.

func (*ItemUpsertOne) SetStatusComplete

func (u *ItemUpsertOne) SetStatusComplete(v bool) *ItemUpsertOne

SetStatusComplete sets the "status_complete" field.

func (*ItemUpsertOne) SetStatusID

func (u *ItemUpsertOne) SetStatusID(v string) *ItemUpsertOne

SetStatusID sets the "status_id" field.

func (*ItemUpsertOne) SetStatusName

func (u *ItemUpsertOne) SetStatusName(v string) *ItemUpsertOne

SetStatusName sets the "status_name" field.

func (*ItemUpsertOne) SetSyncedAt

func (u *ItemUpsertOne) SetSyncedAt(v time.Time) *ItemUpsertOne

SetSyncedAt sets the "synced_at" field.

func (*ItemUpsertOne) SetTags

func (u *ItemUpsertOne) SetTags(v []string) *ItemUpsertOne

SetTags sets the "tags" field.

func (*ItemUpsertOne) SetUpdatedAt

func (u *ItemUpsertOne) SetUpdatedAt(v time.Time) *ItemUpsertOne

SetUpdatedAt sets the "updated_at" field.

func (*ItemUpsertOne) SetWorkspaceRef

func (u *ItemUpsertOne) SetWorkspaceRef(v string) *ItemUpsertOne

SetWorkspaceRef sets the "workspace_ref" field.

func (*ItemUpsertOne) Update

func (u *ItemUpsertOne) Update(set func(*ItemUpsert)) *ItemUpsertOne

Update allows overriding fields `UPDATE` values. See the ItemCreate.OnConflict documentation for more info.

func (*ItemUpsertOne) UpdateCreatedAt

func (u *ItemUpsertOne) UpdateCreatedAt() *ItemUpsertOne

UpdateCreatedAt sets the "created_at" field to the value that was provided on create.

func (*ItemUpsertOne) UpdateCustomFields

func (u *ItemUpsertOne) UpdateCustomFields() *ItemUpsertOne

UpdateCustomFields sets the "custom_fields" field to the value that was provided on create.

func (*ItemUpsertOne) UpdateDescription

func (u *ItemUpsertOne) UpdateDescription() *ItemUpsertOne

UpdateDescription sets the "description" field to the value that was provided on create.

func (*ItemUpsertOne) UpdateDueDate

func (u *ItemUpsertOne) UpdateDueDate() *ItemUpsertOne

UpdateDueDate sets the "due_date" field to the value that was provided on create.

func (*ItemUpsertOne) UpdateKano

func (u *ItemUpsertOne) UpdateKano() *ItemUpsertOne

UpdateKano sets the "kano" field to the value that was provided on create.

func (*ItemUpsertOne) UpdateKind

func (u *ItemUpsertOne) UpdateKind() *ItemUpsertOne

UpdateKind sets the "kind" field to the value that was provided on create.

func (*ItemUpsertOne) UpdateMetadata

func (u *ItemUpsertOne) UpdateMetadata() *ItemUpsertOne

UpdateMetadata sets the "metadata" field to the value that was provided on create.

func (*ItemUpsertOne) UpdateMoscow

func (u *ItemUpsertOne) UpdateMoscow() *ItemUpsertOne

UpdateMoscow sets the "moscow" field to the value that was provided on create.

func (*ItemUpsertOne) UpdateName

func (u *ItemUpsertOne) UpdateName() *ItemUpsertOne

UpdateName sets the "name" field to the value that was provided on create.

func (*ItemUpsertOne) UpdateNewValues

func (u *ItemUpsertOne) UpdateNewValues() *ItemUpsertOne

UpdateNewValues updates the mutable fields using the new values that were set on create except the ID field. Using this option is equivalent to using:

client.Item.Create().
	OnConflict(
		sql.ResolveWithNewValues(),
		sql.ResolveWith(func(u *sql.UpdateSet) {
			u.SetIgnore(item.FieldID)
		}),
	).
	Exec(ctx)

func (*ItemUpsertOne) UpdateOwnerEmail

func (u *ItemUpsertOne) UpdateOwnerEmail() *ItemUpsertOne

UpdateOwnerEmail sets the "owner_email" field to the value that was provided on create.

func (*ItemUpsertOne) UpdateOwnerID

func (u *ItemUpsertOne) UpdateOwnerID() *ItemUpsertOne

UpdateOwnerID sets the "owner_id" field to the value that was provided on create.

func (*ItemUpsertOne) UpdateOwnerName

func (u *ItemUpsertOne) UpdateOwnerName() *ItemUpsertOne

UpdateOwnerName sets the "owner_name" field to the value that was provided on create.

func (*ItemUpsertOne) UpdateParentID

func (u *ItemUpsertOne) UpdateParentID() *ItemUpsertOne

UpdateParentID sets the "parent_id" field to the value that was provided on create.

func (*ItemUpsertOne) UpdateProgress

func (u *ItemUpsertOne) UpdateProgress() *ItemUpsertOne

UpdateProgress sets the "progress" field to the value that was provided on create.

func (*ItemUpsertOne) UpdateProvider

func (u *ItemUpsertOne) UpdateProvider() *ItemUpsertOne

UpdateProvider sets the "provider" field to the value that was provided on create.

func (*ItemUpsertOne) UpdateReleaseID

func (u *ItemUpsertOne) UpdateReleaseID() *ItemUpsertOne

UpdateReleaseID sets the "release_id" field to the value that was provided on create.

func (*ItemUpsertOne) UpdateRice

func (u *ItemUpsertOne) UpdateRice() *ItemUpsertOne

UpdateRice sets the "rice" field to the value that was provided on create.

func (*ItemUpsertOne) UpdateSourceID

func (u *ItemUpsertOne) UpdateSourceID() *ItemUpsertOne

UpdateSourceID sets the "source_id" field to the value that was provided on create.

func (*ItemUpsertOne) UpdateSourceRef

func (u *ItemUpsertOne) UpdateSourceRef() *ItemUpsertOne

UpdateSourceRef sets the "source_ref" field to the value that was provided on create.

func (*ItemUpsertOne) UpdateSourceURL

func (u *ItemUpsertOne) UpdateSourceURL() *ItemUpsertOne

UpdateSourceURL sets the "source_url" field to the value that was provided on create.

func (*ItemUpsertOne) UpdateStartDate

func (u *ItemUpsertOne) UpdateStartDate() *ItemUpsertOne

UpdateStartDate sets the "start_date" field to the value that was provided on create.

func (*ItemUpsertOne) UpdateStatusCategory

func (u *ItemUpsertOne) UpdateStatusCategory() *ItemUpsertOne

UpdateStatusCategory sets the "status_category" field to the value that was provided on create.

func (*ItemUpsertOne) UpdateStatusComplete

func (u *ItemUpsertOne) UpdateStatusComplete() *ItemUpsertOne

UpdateStatusComplete sets the "status_complete" field to the value that was provided on create.

func (*ItemUpsertOne) UpdateStatusID

func (u *ItemUpsertOne) UpdateStatusID() *ItemUpsertOne

UpdateStatusID sets the "status_id" field to the value that was provided on create.

func (*ItemUpsertOne) UpdateStatusName

func (u *ItemUpsertOne) UpdateStatusName() *ItemUpsertOne

UpdateStatusName sets the "status_name" field to the value that was provided on create.

func (*ItemUpsertOne) UpdateSyncedAt

func (u *ItemUpsertOne) UpdateSyncedAt() *ItemUpsertOne

UpdateSyncedAt sets the "synced_at" field to the value that was provided on create.

func (*ItemUpsertOne) UpdateTags

func (u *ItemUpsertOne) UpdateTags() *ItemUpsertOne

UpdateTags sets the "tags" field to the value that was provided on create.

func (*ItemUpsertOne) UpdateUpdatedAt

func (u *ItemUpsertOne) UpdateUpdatedAt() *ItemUpsertOne

UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.

func (*ItemUpsertOne) UpdateWorkspaceRef

func (u *ItemUpsertOne) UpdateWorkspaceRef() *ItemUpsertOne

UpdateWorkspaceRef sets the "workspace_ref" field to the value that was provided on create.

type Items

type Items []*Item

Items is a parsable slice of Item.

type MutateFunc

type MutateFunc = ent.MutateFunc

ent aliases to avoid import conflicts in user's code.

type Mutation

type Mutation = ent.Mutation

ent aliases to avoid import conflicts in user's code.

type Mutator

type Mutator = ent.Mutator

ent aliases to avoid import conflicts in user's code.

type NotFoundError

type NotFoundError struct {
	// contains filtered or unexported fields
}

NotFoundError returns when trying to fetch a specific entity and it was not found in the database.

func (*NotFoundError) Error

func (e *NotFoundError) Error() string

Error implements the error interface.

type NotLoadedError

type NotLoadedError struct {
	// contains filtered or unexported fields
}

NotLoadedError returns when trying to get a node that was not loaded by the query.

func (*NotLoadedError) Error

func (e *NotLoadedError) Error() string

Error implements the error interface.

type NotSingularError

type NotSingularError struct {
	// contains filtered or unexported fields
}

NotSingularError returns when trying to fetch a singular entity and more then one was found in the database.

func (*NotSingularError) Error

func (e *NotSingularError) Error() string

Error implements the error interface.

type Op

type Op = ent.Op

ent aliases to avoid import conflicts in user's code.

type OpportunityAssessment

type OpportunityAssessment struct {

	// ID of the ent.
	ID string `json:"id,omitempty"`
	// OpportunitySpecID holds the value of the "opportunity_spec_id" field.
	OpportunitySpecID string `json:"opportunity_spec_id,omitempty"`
	// RmiID holds the value of the "rmi_id" field.
	RmiID string `json:"rmi_id,omitempty"`
	// Title holds the value of the "title" field.
	Title string `json:"title,omitempty"`
	// CycleNumber holds the value of the "cycle_number" field.
	CycleNumber int `json:"cycle_number,omitempty"`
	// AssessedAt holds the value of the "assessed_at" field.
	AssessedAt time.Time `json:"assessed_at,omitempty"`
	// SupersedesID holds the value of the "supersedes_id" field.
	SupersedesID string `json:"supersedes_id,omitempty"`
	// Current holds the value of the "current" field.
	Current bool `json:"current,omitempty"`
	// MoscowClass holds the value of the "moscow_class" field.
	MoscowClass string `json:"moscow_class,omitempty"`
	// RiceScore holds the value of the "rice_score" field.
	RiceScore *float64 `json:"rice_score,omitempty"`
	// RiceComputable holds the value of the "rice_computable" field.
	RiceComputable bool `json:"rice_computable,omitempty"`
	// OpportunityRankCalculated holds the value of the "opportunity_rank_calculated" field.
	OpportunityRankCalculated *int `json:"opportunity_rank_calculated,omitempty"`
	// OpportunityRankFinal holds the value of the "opportunity_rank_final" field.
	OpportunityRankFinal *int `json:"opportunity_rank_final,omitempty"`
	// KanoCategory holds the value of the "kano_category" field.
	KanoCategory string `json:"kano_category,omitempty"`
	// MihCategory holds the value of the "mih_category" field.
	MihCategory string `json:"mih_category,omitempty"`
	// CompassProfileID holds the value of the "compass_profile_id" field.
	CompassProfileID string `json:"compass_profile_id,omitempty"`
	// Canonical holds the value of the "canonical" field.
	Canonical assessment.OpportunityAssessment `json:"canonical,omitempty"`
	// CreatedAt holds the value of the "created_at" field.
	CreatedAt time.Time `json:"created_at,omitempty"`
	// UpdatedAt holds the value of the "updated_at" field.
	UpdatedAt time.Time `json:"updated_at,omitempty"`
	// contains filtered or unexported fields
}

OpportunityAssessment is the model entity for the OpportunityAssessment schema.

func (*OpportunityAssessment) String

func (_m *OpportunityAssessment) String() string

String implements the fmt.Stringer.

func (*OpportunityAssessment) Unwrap

Unwrap unwraps the OpportunityAssessment entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*OpportunityAssessment) Update

Update returns a builder for updating this OpportunityAssessment. Note that you need to call OpportunityAssessment.Unwrap() before calling this method if this OpportunityAssessment was returned from a transaction, and the transaction was committed or rolled back.

func (*OpportunityAssessment) Value

func (_m *OpportunityAssessment) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the OpportunityAssessment. This includes values selected through modifiers, order, etc.

type OpportunityAssessmentClient

type OpportunityAssessmentClient struct {
	// contains filtered or unexported fields
}

OpportunityAssessmentClient is a client for the OpportunityAssessment schema.

func NewOpportunityAssessmentClient

func NewOpportunityAssessmentClient(c config) *OpportunityAssessmentClient

NewOpportunityAssessmentClient returns a client for the OpportunityAssessment from the given config.

func (*OpportunityAssessmentClient) Create

Create returns a builder for creating a OpportunityAssessment entity.

func (*OpportunityAssessmentClient) CreateBulk

CreateBulk returns a builder for creating a bulk of OpportunityAssessment entities.

func (*OpportunityAssessmentClient) Delete

Delete returns a delete builder for OpportunityAssessment.

func (*OpportunityAssessmentClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*OpportunityAssessmentClient) DeleteOneID

DeleteOneID returns a builder for deleting the given entity by its id.

func (*OpportunityAssessmentClient) Get

Get returns a OpportunityAssessment entity by its id.

func (*OpportunityAssessmentClient) GetX

GetX is like Get, but panics if an error occurs.

func (*OpportunityAssessmentClient) Hooks

func (c *OpportunityAssessmentClient) Hooks() []Hook

Hooks returns the client hooks.

func (*OpportunityAssessmentClient) Intercept

func (c *OpportunityAssessmentClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `opportunityassessment.Intercept(f(g(h())))`.

func (*OpportunityAssessmentClient) Interceptors

func (c *OpportunityAssessmentClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*OpportunityAssessmentClient) MapCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*OpportunityAssessmentClient) Query

Query returns a query builder for OpportunityAssessment.

func (*OpportunityAssessmentClient) Update

Update returns an update builder for OpportunityAssessment.

func (*OpportunityAssessmentClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*OpportunityAssessmentClient) UpdateOneID

UpdateOneID returns an update builder for the given id.

func (*OpportunityAssessmentClient) Use

func (c *OpportunityAssessmentClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `opportunityassessment.Hooks(f(g(h())))`.

type OpportunityAssessmentCreate

type OpportunityAssessmentCreate struct {
	// contains filtered or unexported fields
}

OpportunityAssessmentCreate is the builder for creating a OpportunityAssessment entity.

func (*OpportunityAssessmentCreate) Exec

Exec executes the query.

func (*OpportunityAssessmentCreate) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*OpportunityAssessmentCreate) Mutation

Mutation returns the OpportunityAssessmentMutation object of the builder.

func (*OpportunityAssessmentCreate) OnConflict

OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:

client.OpportunityAssessment.Create().
	SetOpportunitySpecID(v).
	OnConflict(
		// Update the row with the new values
		// the was proposed for insertion.
		sql.ResolveWithNewValues(),
	).
	// Override some of the fields with custom
	// update values.
	Update(func(u *ent.OpportunityAssessmentUpsert) {
		SetOpportunitySpecID(v+v).
	}).
	Exec(ctx)

func (*OpportunityAssessmentCreate) OnConflictColumns

func (_c *OpportunityAssessmentCreate) OnConflictColumns(columns ...string) *OpportunityAssessmentUpsertOne

OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:

client.OpportunityAssessment.Create().
	OnConflict(sql.ConflictColumns(columns...)).
	Exec(ctx)

func (*OpportunityAssessmentCreate) Save

Save creates the OpportunityAssessment in the database.

func (*OpportunityAssessmentCreate) SaveX

SaveX calls Save and panics if Save returns an error.

func (*OpportunityAssessmentCreate) SetAssessedAt

SetAssessedAt sets the "assessed_at" field.

func (*OpportunityAssessmentCreate) SetCanonical

SetCanonical sets the "canonical" field.

func (*OpportunityAssessmentCreate) SetCompassProfileID

SetCompassProfileID sets the "compass_profile_id" field.

func (*OpportunityAssessmentCreate) SetCreatedAt

SetCreatedAt sets the "created_at" field.

func (*OpportunityAssessmentCreate) SetCurrent

SetCurrent sets the "current" field.

func (*OpportunityAssessmentCreate) SetCycleNumber

SetCycleNumber sets the "cycle_number" field.

func (*OpportunityAssessmentCreate) SetID

SetID sets the "id" field.

func (*OpportunityAssessmentCreate) SetKanoCategory

SetKanoCategory sets the "kano_category" field.

func (*OpportunityAssessmentCreate) SetMihCategory

SetMihCategory sets the "mih_category" field.

func (*OpportunityAssessmentCreate) SetMoscowClass

SetMoscowClass sets the "moscow_class" field.

func (*OpportunityAssessmentCreate) SetNillableCompassProfileID

func (_c *OpportunityAssessmentCreate) SetNillableCompassProfileID(v *string) *OpportunityAssessmentCreate

SetNillableCompassProfileID sets the "compass_profile_id" field if the given value is not nil.

func (*OpportunityAssessmentCreate) SetNillableCreatedAt

func (_c *OpportunityAssessmentCreate) SetNillableCreatedAt(v *time.Time) *OpportunityAssessmentCreate

SetNillableCreatedAt sets the "created_at" field if the given value is not nil.

func (*OpportunityAssessmentCreate) SetNillableCurrent

func (_c *OpportunityAssessmentCreate) SetNillableCurrent(v *bool) *OpportunityAssessmentCreate

SetNillableCurrent sets the "current" field if the given value is not nil.

func (*OpportunityAssessmentCreate) SetNillableCycleNumber

func (_c *OpportunityAssessmentCreate) SetNillableCycleNumber(v *int) *OpportunityAssessmentCreate

SetNillableCycleNumber sets the "cycle_number" field if the given value is not nil.

func (*OpportunityAssessmentCreate) SetNillableKanoCategory

func (_c *OpportunityAssessmentCreate) SetNillableKanoCategory(v *string) *OpportunityAssessmentCreate

SetNillableKanoCategory sets the "kano_category" field if the given value is not nil.

func (*OpportunityAssessmentCreate) SetNillableMihCategory

func (_c *OpportunityAssessmentCreate) SetNillableMihCategory(v *string) *OpportunityAssessmentCreate

SetNillableMihCategory sets the "mih_category" field if the given value is not nil.

func (*OpportunityAssessmentCreate) SetNillableMoscowClass

func (_c *OpportunityAssessmentCreate) SetNillableMoscowClass(v *string) *OpportunityAssessmentCreate

SetNillableMoscowClass sets the "moscow_class" field if the given value is not nil.

func (*OpportunityAssessmentCreate) SetNillableOpportunityRankCalculated

func (_c *OpportunityAssessmentCreate) SetNillableOpportunityRankCalculated(v *int) *OpportunityAssessmentCreate

SetNillableOpportunityRankCalculated sets the "opportunity_rank_calculated" field if the given value is not nil.

func (*OpportunityAssessmentCreate) SetNillableOpportunityRankFinal

func (_c *OpportunityAssessmentCreate) SetNillableOpportunityRankFinal(v *int) *OpportunityAssessmentCreate

SetNillableOpportunityRankFinal sets the "opportunity_rank_final" field if the given value is not nil.

func (*OpportunityAssessmentCreate) SetNillableRiceComputable

func (_c *OpportunityAssessmentCreate) SetNillableRiceComputable(v *bool) *OpportunityAssessmentCreate

SetNillableRiceComputable sets the "rice_computable" field if the given value is not nil.

func (*OpportunityAssessmentCreate) SetNillableRiceScore

func (_c *OpportunityAssessmentCreate) SetNillableRiceScore(v *float64) *OpportunityAssessmentCreate

SetNillableRiceScore sets the "rice_score" field if the given value is not nil.

func (*OpportunityAssessmentCreate) SetNillableRmiID

SetNillableRmiID sets the "rmi_id" field if the given value is not nil.

func (*OpportunityAssessmentCreate) SetNillableSupersedesID

func (_c *OpportunityAssessmentCreate) SetNillableSupersedesID(v *string) *OpportunityAssessmentCreate

SetNillableSupersedesID sets the "supersedes_id" field if the given value is not nil.

func (*OpportunityAssessmentCreate) SetNillableTitle

SetNillableTitle sets the "title" field if the given value is not nil.

func (*OpportunityAssessmentCreate) SetNillableUpdatedAt

func (_c *OpportunityAssessmentCreate) SetNillableUpdatedAt(v *time.Time) *OpportunityAssessmentCreate

SetNillableUpdatedAt sets the "updated_at" field if the given value is not nil.

func (*OpportunityAssessmentCreate) SetOpportunityRankCalculated

func (_c *OpportunityAssessmentCreate) SetOpportunityRankCalculated(v int) *OpportunityAssessmentCreate

SetOpportunityRankCalculated sets the "opportunity_rank_calculated" field.

func (*OpportunityAssessmentCreate) SetOpportunityRankFinal

func (_c *OpportunityAssessmentCreate) SetOpportunityRankFinal(v int) *OpportunityAssessmentCreate

SetOpportunityRankFinal sets the "opportunity_rank_final" field.

func (*OpportunityAssessmentCreate) SetOpportunitySpecID

func (_c *OpportunityAssessmentCreate) SetOpportunitySpecID(v string) *OpportunityAssessmentCreate

SetOpportunitySpecID sets the "opportunity_spec_id" field.

func (*OpportunityAssessmentCreate) SetRiceComputable

SetRiceComputable sets the "rice_computable" field.

func (*OpportunityAssessmentCreate) SetRiceScore

SetRiceScore sets the "rice_score" field.

func (*OpportunityAssessmentCreate) SetRmiID

SetRmiID sets the "rmi_id" field.

func (*OpportunityAssessmentCreate) SetSupersedesID

SetSupersedesID sets the "supersedes_id" field.

func (*OpportunityAssessmentCreate) SetTitle

SetTitle sets the "title" field.

func (*OpportunityAssessmentCreate) SetUpdatedAt

SetUpdatedAt sets the "updated_at" field.

type OpportunityAssessmentCreateBulk

type OpportunityAssessmentCreateBulk struct {
	// contains filtered or unexported fields
}

OpportunityAssessmentCreateBulk is the builder for creating many OpportunityAssessment entities in bulk.

func (*OpportunityAssessmentCreateBulk) Exec

Exec executes the query.

func (*OpportunityAssessmentCreateBulk) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*OpportunityAssessmentCreateBulk) OnConflict

OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:

client.OpportunityAssessment.CreateBulk(builders...).
	OnConflict(
		// Update the row with the new values
		// the was proposed for insertion.
		sql.ResolveWithNewValues(),
	).
	// Override some of the fields with custom
	// update values.
	Update(func(u *ent.OpportunityAssessmentUpsert) {
		SetOpportunitySpecID(v+v).
	}).
	Exec(ctx)

func (*OpportunityAssessmentCreateBulk) OnConflictColumns

func (_c *OpportunityAssessmentCreateBulk) OnConflictColumns(columns ...string) *OpportunityAssessmentUpsertBulk

OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:

client.OpportunityAssessment.Create().
	OnConflict(sql.ConflictColumns(columns...)).
	Exec(ctx)

func (*OpportunityAssessmentCreateBulk) Save

Save creates the OpportunityAssessment entities in the database.

func (*OpportunityAssessmentCreateBulk) SaveX

SaveX is like Save, but panics if an error occurs.

type OpportunityAssessmentDelete

type OpportunityAssessmentDelete struct {
	// contains filtered or unexported fields
}

OpportunityAssessmentDelete is the builder for deleting a OpportunityAssessment entity.

func (*OpportunityAssessmentDelete) Exec

Exec executes the deletion query and returns how many vertices were deleted.

func (*OpportunityAssessmentDelete) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*OpportunityAssessmentDelete) Where

Where appends a list predicates to the OpportunityAssessmentDelete builder.

type OpportunityAssessmentDeleteOne

type OpportunityAssessmentDeleteOne struct {
	// contains filtered or unexported fields
}

OpportunityAssessmentDeleteOne is the builder for deleting a single OpportunityAssessment entity.

func (*OpportunityAssessmentDeleteOne) Exec

Exec executes the deletion query.

func (*OpportunityAssessmentDeleteOne) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*OpportunityAssessmentDeleteOne) Where

Where appends a list predicates to the OpportunityAssessmentDelete builder.

type OpportunityAssessmentGroupBy

type OpportunityAssessmentGroupBy struct {
	// contains filtered or unexported fields
}

OpportunityAssessmentGroupBy is the group-by builder for OpportunityAssessment entities.

func (*OpportunityAssessmentGroupBy) Aggregate

Aggregate adds the given aggregation functions to the group-by query.

func (*OpportunityAssessmentGroupBy) Bool

func (s *OpportunityAssessmentGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*OpportunityAssessmentGroupBy) BoolX

func (s *OpportunityAssessmentGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*OpportunityAssessmentGroupBy) Bools

func (s *OpportunityAssessmentGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*OpportunityAssessmentGroupBy) BoolsX

func (s *OpportunityAssessmentGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*OpportunityAssessmentGroupBy) Float64

func (s *OpportunityAssessmentGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*OpportunityAssessmentGroupBy) Float64X

func (s *OpportunityAssessmentGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*OpportunityAssessmentGroupBy) Float64s

func (s *OpportunityAssessmentGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*OpportunityAssessmentGroupBy) Float64sX

func (s *OpportunityAssessmentGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*OpportunityAssessmentGroupBy) Int

func (s *OpportunityAssessmentGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*OpportunityAssessmentGroupBy) IntX

func (s *OpportunityAssessmentGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*OpportunityAssessmentGroupBy) Ints

func (s *OpportunityAssessmentGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*OpportunityAssessmentGroupBy) IntsX

func (s *OpportunityAssessmentGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*OpportunityAssessmentGroupBy) Scan

Scan applies the selector query and scans the result into the given value.

func (*OpportunityAssessmentGroupBy) ScanX

func (s *OpportunityAssessmentGroupBy) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*OpportunityAssessmentGroupBy) String

func (s *OpportunityAssessmentGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*OpportunityAssessmentGroupBy) StringX

func (s *OpportunityAssessmentGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*OpportunityAssessmentGroupBy) Strings

func (s *OpportunityAssessmentGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*OpportunityAssessmentGroupBy) StringsX

func (s *OpportunityAssessmentGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type OpportunityAssessmentMutation

type OpportunityAssessmentMutation struct {
	// contains filtered or unexported fields
}

OpportunityAssessmentMutation represents an operation that mutates the OpportunityAssessment nodes in the graph.

func (*OpportunityAssessmentMutation) AddCycleNumber

func (m *OpportunityAssessmentMutation) AddCycleNumber(i int)

AddCycleNumber adds i to the "cycle_number" field.

func (*OpportunityAssessmentMutation) AddField

func (m *OpportunityAssessmentMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*OpportunityAssessmentMutation) AddOpportunityRankCalculated

func (m *OpportunityAssessmentMutation) AddOpportunityRankCalculated(i int)

AddOpportunityRankCalculated adds i to the "opportunity_rank_calculated" field.

func (*OpportunityAssessmentMutation) AddOpportunityRankFinal

func (m *OpportunityAssessmentMutation) AddOpportunityRankFinal(i int)

AddOpportunityRankFinal adds i to the "opportunity_rank_final" field.

func (*OpportunityAssessmentMutation) AddRiceScore

func (m *OpportunityAssessmentMutation) AddRiceScore(f float64)

AddRiceScore adds f to the "rice_score" field.

func (*OpportunityAssessmentMutation) AddedCycleNumber

func (m *OpportunityAssessmentMutation) AddedCycleNumber() (r int, exists bool)

AddedCycleNumber returns the value that was added to the "cycle_number" field in this mutation.

func (*OpportunityAssessmentMutation) AddedEdges

func (m *OpportunityAssessmentMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*OpportunityAssessmentMutation) AddedField

func (m *OpportunityAssessmentMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*OpportunityAssessmentMutation) AddedFields

func (m *OpportunityAssessmentMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*OpportunityAssessmentMutation) AddedIDs

func (m *OpportunityAssessmentMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*OpportunityAssessmentMutation) AddedOpportunityRankCalculated

func (m *OpportunityAssessmentMutation) AddedOpportunityRankCalculated() (r int, exists bool)

AddedOpportunityRankCalculated returns the value that was added to the "opportunity_rank_calculated" field in this mutation.

func (*OpportunityAssessmentMutation) AddedOpportunityRankFinal

func (m *OpportunityAssessmentMutation) AddedOpportunityRankFinal() (r int, exists bool)

AddedOpportunityRankFinal returns the value that was added to the "opportunity_rank_final" field in this mutation.

func (*OpportunityAssessmentMutation) AddedRiceScore

func (m *OpportunityAssessmentMutation) AddedRiceScore() (r float64, exists bool)

AddedRiceScore returns the value that was added to the "rice_score" field in this mutation.

func (*OpportunityAssessmentMutation) AssessedAt

func (m *OpportunityAssessmentMutation) AssessedAt() (r time.Time, exists bool)

AssessedAt returns the value of the "assessed_at" field in the mutation.

func (*OpportunityAssessmentMutation) Canonical

Canonical returns the value of the "canonical" field in the mutation.

func (*OpportunityAssessmentMutation) ClearCompassProfileID

func (m *OpportunityAssessmentMutation) ClearCompassProfileID()

ClearCompassProfileID clears the value of the "compass_profile_id" field.

func (*OpportunityAssessmentMutation) ClearEdge

func (m *OpportunityAssessmentMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*OpportunityAssessmentMutation) ClearField

func (m *OpportunityAssessmentMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*OpportunityAssessmentMutation) ClearKanoCategory

func (m *OpportunityAssessmentMutation) ClearKanoCategory()

ClearKanoCategory clears the value of the "kano_category" field.

func (*OpportunityAssessmentMutation) ClearMihCategory

func (m *OpportunityAssessmentMutation) ClearMihCategory()

ClearMihCategory clears the value of the "mih_category" field.

func (*OpportunityAssessmentMutation) ClearMoscowClass

func (m *OpportunityAssessmentMutation) ClearMoscowClass()

ClearMoscowClass clears the value of the "moscow_class" field.

func (*OpportunityAssessmentMutation) ClearOpportunityRankCalculated

func (m *OpportunityAssessmentMutation) ClearOpportunityRankCalculated()

ClearOpportunityRankCalculated clears the value of the "opportunity_rank_calculated" field.

func (*OpportunityAssessmentMutation) ClearOpportunityRankFinal

func (m *OpportunityAssessmentMutation) ClearOpportunityRankFinal()

ClearOpportunityRankFinal clears the value of the "opportunity_rank_final" field.

func (*OpportunityAssessmentMutation) ClearRiceScore

func (m *OpportunityAssessmentMutation) ClearRiceScore()

ClearRiceScore clears the value of the "rice_score" field.

func (*OpportunityAssessmentMutation) ClearRmiID

func (m *OpportunityAssessmentMutation) ClearRmiID()

ClearRmiID clears the value of the "rmi_id" field.

func (*OpportunityAssessmentMutation) ClearSupersedesID

func (m *OpportunityAssessmentMutation) ClearSupersedesID()

ClearSupersedesID clears the value of the "supersedes_id" field.

func (*OpportunityAssessmentMutation) ClearTitle

func (m *OpportunityAssessmentMutation) ClearTitle()

ClearTitle clears the value of the "title" field.

func (*OpportunityAssessmentMutation) ClearedEdges

func (m *OpportunityAssessmentMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*OpportunityAssessmentMutation) ClearedFields

func (m *OpportunityAssessmentMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (OpportunityAssessmentMutation) Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*OpportunityAssessmentMutation) CompassProfileID

func (m *OpportunityAssessmentMutation) CompassProfileID() (r string, exists bool)

CompassProfileID returns the value of the "compass_profile_id" field in the mutation.

func (*OpportunityAssessmentMutation) CompassProfileIDCleared

func (m *OpportunityAssessmentMutation) CompassProfileIDCleared() bool

CompassProfileIDCleared returns if the "compass_profile_id" field was cleared in this mutation.

func (*OpportunityAssessmentMutation) CreatedAt

func (m *OpportunityAssessmentMutation) CreatedAt() (r time.Time, exists bool)

CreatedAt returns the value of the "created_at" field in the mutation.

func (*OpportunityAssessmentMutation) Current

func (m *OpportunityAssessmentMutation) Current() (r bool, exists bool)

Current returns the value of the "current" field in the mutation.

func (*OpportunityAssessmentMutation) CycleNumber

func (m *OpportunityAssessmentMutation) CycleNumber() (r int, exists bool)

CycleNumber returns the value of the "cycle_number" field in the mutation.

func (*OpportunityAssessmentMutation) EdgeCleared

func (m *OpportunityAssessmentMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*OpportunityAssessmentMutation) Field

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*OpportunityAssessmentMutation) FieldCleared

func (m *OpportunityAssessmentMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*OpportunityAssessmentMutation) Fields

func (m *OpportunityAssessmentMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*OpportunityAssessmentMutation) ID

func (m *OpportunityAssessmentMutation) ID() (id string, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*OpportunityAssessmentMutation) IDs

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*OpportunityAssessmentMutation) KanoCategory

func (m *OpportunityAssessmentMutation) KanoCategory() (r string, exists bool)

KanoCategory returns the value of the "kano_category" field in the mutation.

func (*OpportunityAssessmentMutation) KanoCategoryCleared

func (m *OpportunityAssessmentMutation) KanoCategoryCleared() bool

KanoCategoryCleared returns if the "kano_category" field was cleared in this mutation.

func (*OpportunityAssessmentMutation) MihCategory

func (m *OpportunityAssessmentMutation) MihCategory() (r string, exists bool)

MihCategory returns the value of the "mih_category" field in the mutation.

func (*OpportunityAssessmentMutation) MihCategoryCleared

func (m *OpportunityAssessmentMutation) MihCategoryCleared() bool

MihCategoryCleared returns if the "mih_category" field was cleared in this mutation.

func (*OpportunityAssessmentMutation) MoscowClass

func (m *OpportunityAssessmentMutation) MoscowClass() (r string, exists bool)

MoscowClass returns the value of the "moscow_class" field in the mutation.

func (*OpportunityAssessmentMutation) MoscowClassCleared

func (m *OpportunityAssessmentMutation) MoscowClassCleared() bool

MoscowClassCleared returns if the "moscow_class" field was cleared in this mutation.

func (*OpportunityAssessmentMutation) OldAssessedAt

func (m *OpportunityAssessmentMutation) OldAssessedAt(ctx context.Context) (v time.Time, err error)

OldAssessedAt returns the old "assessed_at" field's value of the OpportunityAssessment entity. If the OpportunityAssessment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*OpportunityAssessmentMutation) OldCanonical

OldCanonical returns the old "canonical" field's value of the OpportunityAssessment entity. If the OpportunityAssessment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*OpportunityAssessmentMutation) OldCompassProfileID

func (m *OpportunityAssessmentMutation) OldCompassProfileID(ctx context.Context) (v string, err error)

OldCompassProfileID returns the old "compass_profile_id" field's value of the OpportunityAssessment entity. If the OpportunityAssessment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*OpportunityAssessmentMutation) OldCreatedAt

func (m *OpportunityAssessmentMutation) OldCreatedAt(ctx context.Context) (v time.Time, err error)

OldCreatedAt returns the old "created_at" field's value of the OpportunityAssessment entity. If the OpportunityAssessment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*OpportunityAssessmentMutation) OldCurrent

func (m *OpportunityAssessmentMutation) OldCurrent(ctx context.Context) (v bool, err error)

OldCurrent returns the old "current" field's value of the OpportunityAssessment entity. If the OpportunityAssessment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*OpportunityAssessmentMutation) OldCycleNumber

func (m *OpportunityAssessmentMutation) OldCycleNumber(ctx context.Context) (v int, err error)

OldCycleNumber returns the old "cycle_number" field's value of the OpportunityAssessment entity. If the OpportunityAssessment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*OpportunityAssessmentMutation) OldField

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*OpportunityAssessmentMutation) OldKanoCategory

func (m *OpportunityAssessmentMutation) OldKanoCategory(ctx context.Context) (v string, err error)

OldKanoCategory returns the old "kano_category" field's value of the OpportunityAssessment entity. If the OpportunityAssessment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*OpportunityAssessmentMutation) OldMihCategory

func (m *OpportunityAssessmentMutation) OldMihCategory(ctx context.Context) (v string, err error)

OldMihCategory returns the old "mih_category" field's value of the OpportunityAssessment entity. If the OpportunityAssessment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*OpportunityAssessmentMutation) OldMoscowClass

func (m *OpportunityAssessmentMutation) OldMoscowClass(ctx context.Context) (v string, err error)

OldMoscowClass returns the old "moscow_class" field's value of the OpportunityAssessment entity. If the OpportunityAssessment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*OpportunityAssessmentMutation) OldOpportunityRankCalculated

func (m *OpportunityAssessmentMutation) OldOpportunityRankCalculated(ctx context.Context) (v *int, err error)

OldOpportunityRankCalculated returns the old "opportunity_rank_calculated" field's value of the OpportunityAssessment entity. If the OpportunityAssessment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*OpportunityAssessmentMutation) OldOpportunityRankFinal

func (m *OpportunityAssessmentMutation) OldOpportunityRankFinal(ctx context.Context) (v *int, err error)

OldOpportunityRankFinal returns the old "opportunity_rank_final" field's value of the OpportunityAssessment entity. If the OpportunityAssessment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*OpportunityAssessmentMutation) OldOpportunitySpecID

func (m *OpportunityAssessmentMutation) OldOpportunitySpecID(ctx context.Context) (v string, err error)

OldOpportunitySpecID returns the old "opportunity_spec_id" field's value of the OpportunityAssessment entity. If the OpportunityAssessment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*OpportunityAssessmentMutation) OldRiceComputable

func (m *OpportunityAssessmentMutation) OldRiceComputable(ctx context.Context) (v bool, err error)

OldRiceComputable returns the old "rice_computable" field's value of the OpportunityAssessment entity. If the OpportunityAssessment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*OpportunityAssessmentMutation) OldRiceScore

func (m *OpportunityAssessmentMutation) OldRiceScore(ctx context.Context) (v *float64, err error)

OldRiceScore returns the old "rice_score" field's value of the OpportunityAssessment entity. If the OpportunityAssessment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*OpportunityAssessmentMutation) OldRmiID

func (m *OpportunityAssessmentMutation) OldRmiID(ctx context.Context) (v string, err error)

OldRmiID returns the old "rmi_id" field's value of the OpportunityAssessment entity. If the OpportunityAssessment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*OpportunityAssessmentMutation) OldSupersedesID

func (m *OpportunityAssessmentMutation) OldSupersedesID(ctx context.Context) (v string, err error)

OldSupersedesID returns the old "supersedes_id" field's value of the OpportunityAssessment entity. If the OpportunityAssessment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*OpportunityAssessmentMutation) OldTitle

func (m *OpportunityAssessmentMutation) OldTitle(ctx context.Context) (v string, err error)

OldTitle returns the old "title" field's value of the OpportunityAssessment entity. If the OpportunityAssessment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*OpportunityAssessmentMutation) OldUpdatedAt

func (m *OpportunityAssessmentMutation) OldUpdatedAt(ctx context.Context) (v time.Time, err error)

OldUpdatedAt returns the old "updated_at" field's value of the OpportunityAssessment entity. If the OpportunityAssessment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*OpportunityAssessmentMutation) Op

Op returns the operation name.

func (*OpportunityAssessmentMutation) OpportunityRankCalculated

func (m *OpportunityAssessmentMutation) OpportunityRankCalculated() (r int, exists bool)

OpportunityRankCalculated returns the value of the "opportunity_rank_calculated" field in the mutation.

func (*OpportunityAssessmentMutation) OpportunityRankCalculatedCleared

func (m *OpportunityAssessmentMutation) OpportunityRankCalculatedCleared() bool

OpportunityRankCalculatedCleared returns if the "opportunity_rank_calculated" field was cleared in this mutation.

func (*OpportunityAssessmentMutation) OpportunityRankFinal

func (m *OpportunityAssessmentMutation) OpportunityRankFinal() (r int, exists bool)

OpportunityRankFinal returns the value of the "opportunity_rank_final" field in the mutation.

func (*OpportunityAssessmentMutation) OpportunityRankFinalCleared

func (m *OpportunityAssessmentMutation) OpportunityRankFinalCleared() bool

OpportunityRankFinalCleared returns if the "opportunity_rank_final" field was cleared in this mutation.

func (*OpportunityAssessmentMutation) OpportunitySpecID

func (m *OpportunityAssessmentMutation) OpportunitySpecID() (r string, exists bool)

OpportunitySpecID returns the value of the "opportunity_spec_id" field in the mutation.

func (*OpportunityAssessmentMutation) RemovedEdges

func (m *OpportunityAssessmentMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*OpportunityAssessmentMutation) RemovedIDs

func (m *OpportunityAssessmentMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*OpportunityAssessmentMutation) ResetAssessedAt

func (m *OpportunityAssessmentMutation) ResetAssessedAt()

ResetAssessedAt resets all changes to the "assessed_at" field.

func (*OpportunityAssessmentMutation) ResetCanonical

func (m *OpportunityAssessmentMutation) ResetCanonical()

ResetCanonical resets all changes to the "canonical" field.

func (*OpportunityAssessmentMutation) ResetCompassProfileID

func (m *OpportunityAssessmentMutation) ResetCompassProfileID()

ResetCompassProfileID resets all changes to the "compass_profile_id" field.

func (*OpportunityAssessmentMutation) ResetCreatedAt

func (m *OpportunityAssessmentMutation) ResetCreatedAt()

ResetCreatedAt resets all changes to the "created_at" field.

func (*OpportunityAssessmentMutation) ResetCurrent

func (m *OpportunityAssessmentMutation) ResetCurrent()

ResetCurrent resets all changes to the "current" field.

func (*OpportunityAssessmentMutation) ResetCycleNumber

func (m *OpportunityAssessmentMutation) ResetCycleNumber()

ResetCycleNumber resets all changes to the "cycle_number" field.

func (*OpportunityAssessmentMutation) ResetEdge

func (m *OpportunityAssessmentMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*OpportunityAssessmentMutation) ResetField

func (m *OpportunityAssessmentMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*OpportunityAssessmentMutation) ResetKanoCategory

func (m *OpportunityAssessmentMutation) ResetKanoCategory()

ResetKanoCategory resets all changes to the "kano_category" field.

func (*OpportunityAssessmentMutation) ResetMihCategory

func (m *OpportunityAssessmentMutation) ResetMihCategory()

ResetMihCategory resets all changes to the "mih_category" field.

func (*OpportunityAssessmentMutation) ResetMoscowClass

func (m *OpportunityAssessmentMutation) ResetMoscowClass()

ResetMoscowClass resets all changes to the "moscow_class" field.

func (*OpportunityAssessmentMutation) ResetOpportunityRankCalculated

func (m *OpportunityAssessmentMutation) ResetOpportunityRankCalculated()

ResetOpportunityRankCalculated resets all changes to the "opportunity_rank_calculated" field.

func (*OpportunityAssessmentMutation) ResetOpportunityRankFinal

func (m *OpportunityAssessmentMutation) ResetOpportunityRankFinal()

ResetOpportunityRankFinal resets all changes to the "opportunity_rank_final" field.

func (*OpportunityAssessmentMutation) ResetOpportunitySpecID

func (m *OpportunityAssessmentMutation) ResetOpportunitySpecID()

ResetOpportunitySpecID resets all changes to the "opportunity_spec_id" field.

func (*OpportunityAssessmentMutation) ResetRiceComputable

func (m *OpportunityAssessmentMutation) ResetRiceComputable()

ResetRiceComputable resets all changes to the "rice_computable" field.

func (*OpportunityAssessmentMutation) ResetRiceScore

func (m *OpportunityAssessmentMutation) ResetRiceScore()

ResetRiceScore resets all changes to the "rice_score" field.

func (*OpportunityAssessmentMutation) ResetRmiID

func (m *OpportunityAssessmentMutation) ResetRmiID()

ResetRmiID resets all changes to the "rmi_id" field.

func (*OpportunityAssessmentMutation) ResetSupersedesID

func (m *OpportunityAssessmentMutation) ResetSupersedesID()

ResetSupersedesID resets all changes to the "supersedes_id" field.

func (*OpportunityAssessmentMutation) ResetTitle

func (m *OpportunityAssessmentMutation) ResetTitle()

ResetTitle resets all changes to the "title" field.

func (*OpportunityAssessmentMutation) ResetUpdatedAt

func (m *OpportunityAssessmentMutation) ResetUpdatedAt()

ResetUpdatedAt resets all changes to the "updated_at" field.

func (*OpportunityAssessmentMutation) RiceComputable

func (m *OpportunityAssessmentMutation) RiceComputable() (r bool, exists bool)

RiceComputable returns the value of the "rice_computable" field in the mutation.

func (*OpportunityAssessmentMutation) RiceScore

func (m *OpportunityAssessmentMutation) RiceScore() (r float64, exists bool)

RiceScore returns the value of the "rice_score" field in the mutation.

func (*OpportunityAssessmentMutation) RiceScoreCleared

func (m *OpportunityAssessmentMutation) RiceScoreCleared() bool

RiceScoreCleared returns if the "rice_score" field was cleared in this mutation.

func (*OpportunityAssessmentMutation) RmiID

func (m *OpportunityAssessmentMutation) RmiID() (r string, exists bool)

RmiID returns the value of the "rmi_id" field in the mutation.

func (*OpportunityAssessmentMutation) RmiIDCleared

func (m *OpportunityAssessmentMutation) RmiIDCleared() bool

RmiIDCleared returns if the "rmi_id" field was cleared in this mutation.

func (*OpportunityAssessmentMutation) SetAssessedAt

func (m *OpportunityAssessmentMutation) SetAssessedAt(t time.Time)

SetAssessedAt sets the "assessed_at" field.

func (*OpportunityAssessmentMutation) SetCanonical

SetCanonical sets the "canonical" field.

func (*OpportunityAssessmentMutation) SetCompassProfileID

func (m *OpportunityAssessmentMutation) SetCompassProfileID(s string)

SetCompassProfileID sets the "compass_profile_id" field.

func (*OpportunityAssessmentMutation) SetCreatedAt

func (m *OpportunityAssessmentMutation) SetCreatedAt(t time.Time)

SetCreatedAt sets the "created_at" field.

func (*OpportunityAssessmentMutation) SetCurrent

func (m *OpportunityAssessmentMutation) SetCurrent(b bool)

SetCurrent sets the "current" field.

func (*OpportunityAssessmentMutation) SetCycleNumber

func (m *OpportunityAssessmentMutation) SetCycleNumber(i int)

SetCycleNumber sets the "cycle_number" field.

func (*OpportunityAssessmentMutation) SetField

func (m *OpportunityAssessmentMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*OpportunityAssessmentMutation) SetID

SetID sets the value of the id field. Note that this operation is only accepted on creation of OpportunityAssessment entities.

func (*OpportunityAssessmentMutation) SetKanoCategory

func (m *OpportunityAssessmentMutation) SetKanoCategory(s string)

SetKanoCategory sets the "kano_category" field.

func (*OpportunityAssessmentMutation) SetMihCategory

func (m *OpportunityAssessmentMutation) SetMihCategory(s string)

SetMihCategory sets the "mih_category" field.

func (*OpportunityAssessmentMutation) SetMoscowClass

func (m *OpportunityAssessmentMutation) SetMoscowClass(s string)

SetMoscowClass sets the "moscow_class" field.

func (*OpportunityAssessmentMutation) SetOp

func (m *OpportunityAssessmentMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*OpportunityAssessmentMutation) SetOpportunityRankCalculated

func (m *OpportunityAssessmentMutation) SetOpportunityRankCalculated(i int)

SetOpportunityRankCalculated sets the "opportunity_rank_calculated" field.

func (*OpportunityAssessmentMutation) SetOpportunityRankFinal

func (m *OpportunityAssessmentMutation) SetOpportunityRankFinal(i int)

SetOpportunityRankFinal sets the "opportunity_rank_final" field.

func (*OpportunityAssessmentMutation) SetOpportunitySpecID

func (m *OpportunityAssessmentMutation) SetOpportunitySpecID(s string)

SetOpportunitySpecID sets the "opportunity_spec_id" field.

func (*OpportunityAssessmentMutation) SetRiceComputable

func (m *OpportunityAssessmentMutation) SetRiceComputable(b bool)

SetRiceComputable sets the "rice_computable" field.

func (*OpportunityAssessmentMutation) SetRiceScore

func (m *OpportunityAssessmentMutation) SetRiceScore(f float64)

SetRiceScore sets the "rice_score" field.

func (*OpportunityAssessmentMutation) SetRmiID

func (m *OpportunityAssessmentMutation) SetRmiID(s string)

SetRmiID sets the "rmi_id" field.

func (*OpportunityAssessmentMutation) SetSupersedesID

func (m *OpportunityAssessmentMutation) SetSupersedesID(s string)

SetSupersedesID sets the "supersedes_id" field.

func (*OpportunityAssessmentMutation) SetTitle

func (m *OpportunityAssessmentMutation) SetTitle(s string)

SetTitle sets the "title" field.

func (*OpportunityAssessmentMutation) SetUpdatedAt

func (m *OpportunityAssessmentMutation) SetUpdatedAt(t time.Time)

SetUpdatedAt sets the "updated_at" field.

func (*OpportunityAssessmentMutation) SupersedesID

func (m *OpportunityAssessmentMutation) SupersedesID() (r string, exists bool)

SupersedesID returns the value of the "supersedes_id" field in the mutation.

func (*OpportunityAssessmentMutation) SupersedesIDCleared

func (m *OpportunityAssessmentMutation) SupersedesIDCleared() bool

SupersedesIDCleared returns if the "supersedes_id" field was cleared in this mutation.

func (*OpportunityAssessmentMutation) Title

func (m *OpportunityAssessmentMutation) Title() (r string, exists bool)

Title returns the value of the "title" field in the mutation.

func (*OpportunityAssessmentMutation) TitleCleared

func (m *OpportunityAssessmentMutation) TitleCleared() bool

TitleCleared returns if the "title" field was cleared in this mutation.

func (OpportunityAssessmentMutation) Tx

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*OpportunityAssessmentMutation) Type

Type returns the node type of this mutation (OpportunityAssessment).

func (*OpportunityAssessmentMutation) UpdatedAt

func (m *OpportunityAssessmentMutation) UpdatedAt() (r time.Time, exists bool)

UpdatedAt returns the value of the "updated_at" field in the mutation.

func (*OpportunityAssessmentMutation) Where

Where appends a list predicates to the OpportunityAssessmentMutation builder.

func (*OpportunityAssessmentMutation) WhereP

func (m *OpportunityAssessmentMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the OpportunityAssessmentMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

type OpportunityAssessmentQuery

type OpportunityAssessmentQuery struct {
	// contains filtered or unexported fields
}

OpportunityAssessmentQuery is the builder for querying OpportunityAssessment entities.

func (*OpportunityAssessmentQuery) Aggregate

Aggregate returns a OpportunityAssessmentSelect configured with the given aggregations.

func (*OpportunityAssessmentQuery) All

All executes the query and returns a list of OpportunityAssessments.

func (*OpportunityAssessmentQuery) AllX

AllX is like All, but panics if an error occurs.

func (*OpportunityAssessmentQuery) Clone

Clone returns a duplicate of the OpportunityAssessmentQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*OpportunityAssessmentQuery) Count

Count returns the count of the given query.

func (*OpportunityAssessmentQuery) CountX

CountX is like Count, but panics if an error occurs.

func (*OpportunityAssessmentQuery) Exist

Exist returns true if the query has elements in the graph.

func (*OpportunityAssessmentQuery) ExistX

ExistX is like Exist, but panics if an error occurs.

func (*OpportunityAssessmentQuery) First

First returns the first OpportunityAssessment entity from the query. Returns a *NotFoundError when no OpportunityAssessment was found.

func (*OpportunityAssessmentQuery) FirstID

func (_q *OpportunityAssessmentQuery) FirstID(ctx context.Context) (id string, err error)

FirstID returns the first OpportunityAssessment ID from the query. Returns a *NotFoundError when no OpportunityAssessment ID was found.

func (*OpportunityAssessmentQuery) FirstIDX

FirstIDX is like FirstID, but panics if an error occurs.

func (*OpportunityAssessmentQuery) FirstX

FirstX is like First, but panics if an error occurs.

func (*OpportunityAssessmentQuery) GroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	OpportunitySpecID string `json:"opportunity_spec_id,omitempty"`
	Count int `json:"count,omitempty"`
}

client.OpportunityAssessment.Query().
	GroupBy(opportunityassessment.FieldOpportunitySpecID).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*OpportunityAssessmentQuery) IDs

func (_q *OpportunityAssessmentQuery) IDs(ctx context.Context) (ids []string, err error)

IDs executes the query and returns a list of OpportunityAssessment IDs.

func (*OpportunityAssessmentQuery) IDsX

IDsX is like IDs, but panics if an error occurs.

func (*OpportunityAssessmentQuery) Limit

Limit the number of records to be returned by this query.

func (*OpportunityAssessmentQuery) Offset

Offset to start from.

func (*OpportunityAssessmentQuery) Only

Only returns a single OpportunityAssessment entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one OpportunityAssessment entity is found. Returns a *NotFoundError when no OpportunityAssessment entities are found.

func (*OpportunityAssessmentQuery) OnlyID

func (_q *OpportunityAssessmentQuery) OnlyID(ctx context.Context) (id string, err error)

OnlyID is like Only, but returns the only OpportunityAssessment ID in the query. Returns a *NotSingularError when more than one OpportunityAssessment ID is found. Returns a *NotFoundError when no entities are found.

func (*OpportunityAssessmentQuery) OnlyIDX

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*OpportunityAssessmentQuery) OnlyX

OnlyX is like Only, but panics if an error occurs.

func (*OpportunityAssessmentQuery) Order

Order specifies how the records should be ordered.

func (*OpportunityAssessmentQuery) Select

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	OpportunitySpecID string `json:"opportunity_spec_id,omitempty"`
}

client.OpportunityAssessment.Query().
	Select(opportunityassessment.FieldOpportunitySpecID).
	Scan(ctx, &v)

func (*OpportunityAssessmentQuery) Unique

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*OpportunityAssessmentQuery) Where

Where adds a new predicate for the OpportunityAssessmentQuery builder.

type OpportunityAssessmentSelect

type OpportunityAssessmentSelect struct {
	*OpportunityAssessmentQuery
	// contains filtered or unexported fields
}

OpportunityAssessmentSelect is the builder for selecting fields of OpportunityAssessment entities.

func (*OpportunityAssessmentSelect) Aggregate

Aggregate adds the given aggregation functions to the selector query.

func (*OpportunityAssessmentSelect) Bool

func (s *OpportunityAssessmentSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*OpportunityAssessmentSelect) BoolX

func (s *OpportunityAssessmentSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*OpportunityAssessmentSelect) Bools

func (s *OpportunityAssessmentSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*OpportunityAssessmentSelect) BoolsX

func (s *OpportunityAssessmentSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*OpportunityAssessmentSelect) Float64

func (s *OpportunityAssessmentSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*OpportunityAssessmentSelect) Float64X

func (s *OpportunityAssessmentSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*OpportunityAssessmentSelect) Float64s

func (s *OpportunityAssessmentSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*OpportunityAssessmentSelect) Float64sX

func (s *OpportunityAssessmentSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*OpportunityAssessmentSelect) Int

func (s *OpportunityAssessmentSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*OpportunityAssessmentSelect) IntX

func (s *OpportunityAssessmentSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*OpportunityAssessmentSelect) Ints

func (s *OpportunityAssessmentSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*OpportunityAssessmentSelect) IntsX

func (s *OpportunityAssessmentSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*OpportunityAssessmentSelect) Scan

Scan applies the selector query and scans the result into the given value.

func (*OpportunityAssessmentSelect) ScanX

func (s *OpportunityAssessmentSelect) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*OpportunityAssessmentSelect) String

func (s *OpportunityAssessmentSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*OpportunityAssessmentSelect) StringX

func (s *OpportunityAssessmentSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*OpportunityAssessmentSelect) Strings

func (s *OpportunityAssessmentSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*OpportunityAssessmentSelect) StringsX

func (s *OpportunityAssessmentSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type OpportunityAssessmentUpdate

type OpportunityAssessmentUpdate struct {
	// contains filtered or unexported fields
}

OpportunityAssessmentUpdate is the builder for updating OpportunityAssessment entities.

func (*OpportunityAssessmentUpdate) AddCycleNumber

AddCycleNumber adds value to the "cycle_number" field.

func (*OpportunityAssessmentUpdate) AddOpportunityRankCalculated

func (_u *OpportunityAssessmentUpdate) AddOpportunityRankCalculated(v int) *OpportunityAssessmentUpdate

AddOpportunityRankCalculated adds value to the "opportunity_rank_calculated" field.

func (*OpportunityAssessmentUpdate) AddOpportunityRankFinal

func (_u *OpportunityAssessmentUpdate) AddOpportunityRankFinal(v int) *OpportunityAssessmentUpdate

AddOpportunityRankFinal adds value to the "opportunity_rank_final" field.

func (*OpportunityAssessmentUpdate) AddRiceScore

AddRiceScore adds value to the "rice_score" field.

func (*OpportunityAssessmentUpdate) ClearCompassProfileID

func (_u *OpportunityAssessmentUpdate) ClearCompassProfileID() *OpportunityAssessmentUpdate

ClearCompassProfileID clears the value of the "compass_profile_id" field.

func (*OpportunityAssessmentUpdate) ClearKanoCategory

ClearKanoCategory clears the value of the "kano_category" field.

func (*OpportunityAssessmentUpdate) ClearMihCategory

ClearMihCategory clears the value of the "mih_category" field.

func (*OpportunityAssessmentUpdate) ClearMoscowClass

ClearMoscowClass clears the value of the "moscow_class" field.

func (*OpportunityAssessmentUpdate) ClearOpportunityRankCalculated

func (_u *OpportunityAssessmentUpdate) ClearOpportunityRankCalculated() *OpportunityAssessmentUpdate

ClearOpportunityRankCalculated clears the value of the "opportunity_rank_calculated" field.

func (*OpportunityAssessmentUpdate) ClearOpportunityRankFinal

func (_u *OpportunityAssessmentUpdate) ClearOpportunityRankFinal() *OpportunityAssessmentUpdate

ClearOpportunityRankFinal clears the value of the "opportunity_rank_final" field.

func (*OpportunityAssessmentUpdate) ClearRiceScore

ClearRiceScore clears the value of the "rice_score" field.

func (*OpportunityAssessmentUpdate) ClearRmiID

ClearRmiID clears the value of the "rmi_id" field.

func (*OpportunityAssessmentUpdate) ClearSupersedesID

ClearSupersedesID clears the value of the "supersedes_id" field.

func (*OpportunityAssessmentUpdate) ClearTitle

ClearTitle clears the value of the "title" field.

func (*OpportunityAssessmentUpdate) Exec

Exec executes the query.

func (*OpportunityAssessmentUpdate) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*OpportunityAssessmentUpdate) Mutation

Mutation returns the OpportunityAssessmentMutation object of the builder.

func (*OpportunityAssessmentUpdate) Save

Save executes the query and returns the number of nodes affected by the update operation.

func (*OpportunityAssessmentUpdate) SaveX

SaveX is like Save, but panics if an error occurs.

func (*OpportunityAssessmentUpdate) SetAssessedAt

SetAssessedAt sets the "assessed_at" field.

func (*OpportunityAssessmentUpdate) SetCanonical

SetCanonical sets the "canonical" field.

func (*OpportunityAssessmentUpdate) SetCompassProfileID

SetCompassProfileID sets the "compass_profile_id" field.

func (*OpportunityAssessmentUpdate) SetCurrent

SetCurrent sets the "current" field.

func (*OpportunityAssessmentUpdate) SetCycleNumber

SetCycleNumber sets the "cycle_number" field.

func (*OpportunityAssessmentUpdate) SetKanoCategory

SetKanoCategory sets the "kano_category" field.

func (*OpportunityAssessmentUpdate) SetMihCategory

SetMihCategory sets the "mih_category" field.

func (*OpportunityAssessmentUpdate) SetMoscowClass

SetMoscowClass sets the "moscow_class" field.

func (*OpportunityAssessmentUpdate) SetNillableAssessedAt

func (_u *OpportunityAssessmentUpdate) SetNillableAssessedAt(v *time.Time) *OpportunityAssessmentUpdate

SetNillableAssessedAt sets the "assessed_at" field if the given value is not nil.

func (*OpportunityAssessmentUpdate) SetNillableCanonical

SetNillableCanonical sets the "canonical" field if the given value is not nil.

func (*OpportunityAssessmentUpdate) SetNillableCompassProfileID

func (_u *OpportunityAssessmentUpdate) SetNillableCompassProfileID(v *string) *OpportunityAssessmentUpdate

SetNillableCompassProfileID sets the "compass_profile_id" field if the given value is not nil.

func (*OpportunityAssessmentUpdate) SetNillableCurrent

func (_u *OpportunityAssessmentUpdate) SetNillableCurrent(v *bool) *OpportunityAssessmentUpdate

SetNillableCurrent sets the "current" field if the given value is not nil.

func (*OpportunityAssessmentUpdate) SetNillableCycleNumber

func (_u *OpportunityAssessmentUpdate) SetNillableCycleNumber(v *int) *OpportunityAssessmentUpdate

SetNillableCycleNumber sets the "cycle_number" field if the given value is not nil.

func (*OpportunityAssessmentUpdate) SetNillableKanoCategory

func (_u *OpportunityAssessmentUpdate) SetNillableKanoCategory(v *string) *OpportunityAssessmentUpdate

SetNillableKanoCategory sets the "kano_category" field if the given value is not nil.

func (*OpportunityAssessmentUpdate) SetNillableMihCategory

func (_u *OpportunityAssessmentUpdate) SetNillableMihCategory(v *string) *OpportunityAssessmentUpdate

SetNillableMihCategory sets the "mih_category" field if the given value is not nil.

func (*OpportunityAssessmentUpdate) SetNillableMoscowClass

func (_u *OpportunityAssessmentUpdate) SetNillableMoscowClass(v *string) *OpportunityAssessmentUpdate

SetNillableMoscowClass sets the "moscow_class" field if the given value is not nil.

func (*OpportunityAssessmentUpdate) SetNillableOpportunityRankCalculated

func (_u *OpportunityAssessmentUpdate) SetNillableOpportunityRankCalculated(v *int) *OpportunityAssessmentUpdate

SetNillableOpportunityRankCalculated sets the "opportunity_rank_calculated" field if the given value is not nil.

func (*OpportunityAssessmentUpdate) SetNillableOpportunityRankFinal

func (_u *OpportunityAssessmentUpdate) SetNillableOpportunityRankFinal(v *int) *OpportunityAssessmentUpdate

SetNillableOpportunityRankFinal sets the "opportunity_rank_final" field if the given value is not nil.

func (*OpportunityAssessmentUpdate) SetNillableOpportunitySpecID

func (_u *OpportunityAssessmentUpdate) SetNillableOpportunitySpecID(v *string) *OpportunityAssessmentUpdate

SetNillableOpportunitySpecID sets the "opportunity_spec_id" field if the given value is not nil.

func (*OpportunityAssessmentUpdate) SetNillableRiceComputable

func (_u *OpportunityAssessmentUpdate) SetNillableRiceComputable(v *bool) *OpportunityAssessmentUpdate

SetNillableRiceComputable sets the "rice_computable" field if the given value is not nil.

func (*OpportunityAssessmentUpdate) SetNillableRiceScore

func (_u *OpportunityAssessmentUpdate) SetNillableRiceScore(v *float64) *OpportunityAssessmentUpdate

SetNillableRiceScore sets the "rice_score" field if the given value is not nil.

func (*OpportunityAssessmentUpdate) SetNillableRmiID

SetNillableRmiID sets the "rmi_id" field if the given value is not nil.

func (*OpportunityAssessmentUpdate) SetNillableSupersedesID

func (_u *OpportunityAssessmentUpdate) SetNillableSupersedesID(v *string) *OpportunityAssessmentUpdate

SetNillableSupersedesID sets the "supersedes_id" field if the given value is not nil.

func (*OpportunityAssessmentUpdate) SetNillableTitle

SetNillableTitle sets the "title" field if the given value is not nil.

func (*OpportunityAssessmentUpdate) SetOpportunityRankCalculated

func (_u *OpportunityAssessmentUpdate) SetOpportunityRankCalculated(v int) *OpportunityAssessmentUpdate

SetOpportunityRankCalculated sets the "opportunity_rank_calculated" field.

func (*OpportunityAssessmentUpdate) SetOpportunityRankFinal

func (_u *OpportunityAssessmentUpdate) SetOpportunityRankFinal(v int) *OpportunityAssessmentUpdate

SetOpportunityRankFinal sets the "opportunity_rank_final" field.

func (*OpportunityAssessmentUpdate) SetOpportunitySpecID

func (_u *OpportunityAssessmentUpdate) SetOpportunitySpecID(v string) *OpportunityAssessmentUpdate

SetOpportunitySpecID sets the "opportunity_spec_id" field.

func (*OpportunityAssessmentUpdate) SetRiceComputable

SetRiceComputable sets the "rice_computable" field.

func (*OpportunityAssessmentUpdate) SetRiceScore

SetRiceScore sets the "rice_score" field.

func (*OpportunityAssessmentUpdate) SetRmiID

SetRmiID sets the "rmi_id" field.

func (*OpportunityAssessmentUpdate) SetSupersedesID

SetSupersedesID sets the "supersedes_id" field.

func (*OpportunityAssessmentUpdate) SetTitle

SetTitle sets the "title" field.

func (*OpportunityAssessmentUpdate) SetUpdatedAt

SetUpdatedAt sets the "updated_at" field.

func (*OpportunityAssessmentUpdate) Where

Where appends a list predicates to the OpportunityAssessmentUpdate builder.

type OpportunityAssessmentUpdateOne

type OpportunityAssessmentUpdateOne struct {
	// contains filtered or unexported fields
}

OpportunityAssessmentUpdateOne is the builder for updating a single OpportunityAssessment entity.

func (*OpportunityAssessmentUpdateOne) AddCycleNumber

AddCycleNumber adds value to the "cycle_number" field.

func (*OpportunityAssessmentUpdateOne) AddOpportunityRankCalculated

func (_u *OpportunityAssessmentUpdateOne) AddOpportunityRankCalculated(v int) *OpportunityAssessmentUpdateOne

AddOpportunityRankCalculated adds value to the "opportunity_rank_calculated" field.

func (*OpportunityAssessmentUpdateOne) AddOpportunityRankFinal

func (_u *OpportunityAssessmentUpdateOne) AddOpportunityRankFinal(v int) *OpportunityAssessmentUpdateOne

AddOpportunityRankFinal adds value to the "opportunity_rank_final" field.

func (*OpportunityAssessmentUpdateOne) AddRiceScore

AddRiceScore adds value to the "rice_score" field.

func (*OpportunityAssessmentUpdateOne) ClearCompassProfileID

ClearCompassProfileID clears the value of the "compass_profile_id" field.

func (*OpportunityAssessmentUpdateOne) ClearKanoCategory

ClearKanoCategory clears the value of the "kano_category" field.

func (*OpportunityAssessmentUpdateOne) ClearMihCategory

ClearMihCategory clears the value of the "mih_category" field.

func (*OpportunityAssessmentUpdateOne) ClearMoscowClass

ClearMoscowClass clears the value of the "moscow_class" field.

func (*OpportunityAssessmentUpdateOne) ClearOpportunityRankCalculated

func (_u *OpportunityAssessmentUpdateOne) ClearOpportunityRankCalculated() *OpportunityAssessmentUpdateOne

ClearOpportunityRankCalculated clears the value of the "opportunity_rank_calculated" field.

func (*OpportunityAssessmentUpdateOne) ClearOpportunityRankFinal

func (_u *OpportunityAssessmentUpdateOne) ClearOpportunityRankFinal() *OpportunityAssessmentUpdateOne

ClearOpportunityRankFinal clears the value of the "opportunity_rank_final" field.

func (*OpportunityAssessmentUpdateOne) ClearRiceScore

ClearRiceScore clears the value of the "rice_score" field.

func (*OpportunityAssessmentUpdateOne) ClearRmiID

ClearRmiID clears the value of the "rmi_id" field.

func (*OpportunityAssessmentUpdateOne) ClearSupersedesID

ClearSupersedesID clears the value of the "supersedes_id" field.

func (*OpportunityAssessmentUpdateOne) ClearTitle

ClearTitle clears the value of the "title" field.

func (*OpportunityAssessmentUpdateOne) Exec

Exec executes the query on the entity.

func (*OpportunityAssessmentUpdateOne) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*OpportunityAssessmentUpdateOne) Mutation

Mutation returns the OpportunityAssessmentMutation object of the builder.

func (*OpportunityAssessmentUpdateOne) Save

Save executes the query and returns the updated OpportunityAssessment entity.

func (*OpportunityAssessmentUpdateOne) SaveX

SaveX is like Save, but panics if an error occurs.

func (*OpportunityAssessmentUpdateOne) Select

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*OpportunityAssessmentUpdateOne) SetAssessedAt

SetAssessedAt sets the "assessed_at" field.

func (*OpportunityAssessmentUpdateOne) SetCanonical

SetCanonical sets the "canonical" field.

func (*OpportunityAssessmentUpdateOne) SetCompassProfileID

SetCompassProfileID sets the "compass_profile_id" field.

func (*OpportunityAssessmentUpdateOne) SetCurrent

SetCurrent sets the "current" field.

func (*OpportunityAssessmentUpdateOne) SetCycleNumber

SetCycleNumber sets the "cycle_number" field.

func (*OpportunityAssessmentUpdateOne) SetKanoCategory

SetKanoCategory sets the "kano_category" field.

func (*OpportunityAssessmentUpdateOne) SetMihCategory

SetMihCategory sets the "mih_category" field.

func (*OpportunityAssessmentUpdateOne) SetMoscowClass

SetMoscowClass sets the "moscow_class" field.

func (*OpportunityAssessmentUpdateOne) SetNillableAssessedAt

SetNillableAssessedAt sets the "assessed_at" field if the given value is not nil.

func (*OpportunityAssessmentUpdateOne) SetNillableCanonical

SetNillableCanonical sets the "canonical" field if the given value is not nil.

func (*OpportunityAssessmentUpdateOne) SetNillableCompassProfileID

func (_u *OpportunityAssessmentUpdateOne) SetNillableCompassProfileID(v *string) *OpportunityAssessmentUpdateOne

SetNillableCompassProfileID sets the "compass_profile_id" field if the given value is not nil.

func (*OpportunityAssessmentUpdateOne) SetNillableCurrent

SetNillableCurrent sets the "current" field if the given value is not nil.

func (*OpportunityAssessmentUpdateOne) SetNillableCycleNumber

func (_u *OpportunityAssessmentUpdateOne) SetNillableCycleNumber(v *int) *OpportunityAssessmentUpdateOne

SetNillableCycleNumber sets the "cycle_number" field if the given value is not nil.

func (*OpportunityAssessmentUpdateOne) SetNillableKanoCategory

func (_u *OpportunityAssessmentUpdateOne) SetNillableKanoCategory(v *string) *OpportunityAssessmentUpdateOne

SetNillableKanoCategory sets the "kano_category" field if the given value is not nil.

func (*OpportunityAssessmentUpdateOne) SetNillableMihCategory

SetNillableMihCategory sets the "mih_category" field if the given value is not nil.

func (*OpportunityAssessmentUpdateOne) SetNillableMoscowClass

SetNillableMoscowClass sets the "moscow_class" field if the given value is not nil.

func (*OpportunityAssessmentUpdateOne) SetNillableOpportunityRankCalculated

func (_u *OpportunityAssessmentUpdateOne) SetNillableOpportunityRankCalculated(v *int) *OpportunityAssessmentUpdateOne

SetNillableOpportunityRankCalculated sets the "opportunity_rank_calculated" field if the given value is not nil.

func (*OpportunityAssessmentUpdateOne) SetNillableOpportunityRankFinal

func (_u *OpportunityAssessmentUpdateOne) SetNillableOpportunityRankFinal(v *int) *OpportunityAssessmentUpdateOne

SetNillableOpportunityRankFinal sets the "opportunity_rank_final" field if the given value is not nil.

func (*OpportunityAssessmentUpdateOne) SetNillableOpportunitySpecID

func (_u *OpportunityAssessmentUpdateOne) SetNillableOpportunitySpecID(v *string) *OpportunityAssessmentUpdateOne

SetNillableOpportunitySpecID sets the "opportunity_spec_id" field if the given value is not nil.

func (*OpportunityAssessmentUpdateOne) SetNillableRiceComputable

func (_u *OpportunityAssessmentUpdateOne) SetNillableRiceComputable(v *bool) *OpportunityAssessmentUpdateOne

SetNillableRiceComputable sets the "rice_computable" field if the given value is not nil.

func (*OpportunityAssessmentUpdateOne) SetNillableRiceScore

SetNillableRiceScore sets the "rice_score" field if the given value is not nil.

func (*OpportunityAssessmentUpdateOne) SetNillableRmiID

SetNillableRmiID sets the "rmi_id" field if the given value is not nil.

func (*OpportunityAssessmentUpdateOne) SetNillableSupersedesID

func (_u *OpportunityAssessmentUpdateOne) SetNillableSupersedesID(v *string) *OpportunityAssessmentUpdateOne

SetNillableSupersedesID sets the "supersedes_id" field if the given value is not nil.

func (*OpportunityAssessmentUpdateOne) SetNillableTitle

SetNillableTitle sets the "title" field if the given value is not nil.

func (*OpportunityAssessmentUpdateOne) SetOpportunityRankCalculated

func (_u *OpportunityAssessmentUpdateOne) SetOpportunityRankCalculated(v int) *OpportunityAssessmentUpdateOne

SetOpportunityRankCalculated sets the "opportunity_rank_calculated" field.

func (*OpportunityAssessmentUpdateOne) SetOpportunityRankFinal

func (_u *OpportunityAssessmentUpdateOne) SetOpportunityRankFinal(v int) *OpportunityAssessmentUpdateOne

SetOpportunityRankFinal sets the "opportunity_rank_final" field.

func (*OpportunityAssessmentUpdateOne) SetOpportunitySpecID

SetOpportunitySpecID sets the "opportunity_spec_id" field.

func (*OpportunityAssessmentUpdateOne) SetRiceComputable

SetRiceComputable sets the "rice_computable" field.

func (*OpportunityAssessmentUpdateOne) SetRiceScore

SetRiceScore sets the "rice_score" field.

func (*OpportunityAssessmentUpdateOne) SetRmiID

SetRmiID sets the "rmi_id" field.

func (*OpportunityAssessmentUpdateOne) SetSupersedesID

SetSupersedesID sets the "supersedes_id" field.

func (*OpportunityAssessmentUpdateOne) SetTitle

SetTitle sets the "title" field.

func (*OpportunityAssessmentUpdateOne) SetUpdatedAt

SetUpdatedAt sets the "updated_at" field.

func (*OpportunityAssessmentUpdateOne) Where

Where appends a list predicates to the OpportunityAssessmentUpdate builder.

type OpportunityAssessmentUpsert

type OpportunityAssessmentUpsert struct {
	*sql.UpdateSet
}

OpportunityAssessmentUpsert is the "OnConflict" setter.

func (*OpportunityAssessmentUpsert) AddCycleNumber

AddCycleNumber adds v to the "cycle_number" field.

func (*OpportunityAssessmentUpsert) AddOpportunityRankCalculated

func (u *OpportunityAssessmentUpsert) AddOpportunityRankCalculated(v int) *OpportunityAssessmentUpsert

AddOpportunityRankCalculated adds v to the "opportunity_rank_calculated" field.

func (*OpportunityAssessmentUpsert) AddOpportunityRankFinal

func (u *OpportunityAssessmentUpsert) AddOpportunityRankFinal(v int) *OpportunityAssessmentUpsert

AddOpportunityRankFinal adds v to the "opportunity_rank_final" field.

func (*OpportunityAssessmentUpsert) AddRiceScore

AddRiceScore adds v to the "rice_score" field.

func (*OpportunityAssessmentUpsert) ClearCompassProfileID

func (u *OpportunityAssessmentUpsert) ClearCompassProfileID() *OpportunityAssessmentUpsert

ClearCompassProfileID clears the value of the "compass_profile_id" field.

func (*OpportunityAssessmentUpsert) ClearKanoCategory

ClearKanoCategory clears the value of the "kano_category" field.

func (*OpportunityAssessmentUpsert) ClearMihCategory

ClearMihCategory clears the value of the "mih_category" field.

func (*OpportunityAssessmentUpsert) ClearMoscowClass

ClearMoscowClass clears the value of the "moscow_class" field.

func (*OpportunityAssessmentUpsert) ClearOpportunityRankCalculated

func (u *OpportunityAssessmentUpsert) ClearOpportunityRankCalculated() *OpportunityAssessmentUpsert

ClearOpportunityRankCalculated clears the value of the "opportunity_rank_calculated" field.

func (*OpportunityAssessmentUpsert) ClearOpportunityRankFinal

func (u *OpportunityAssessmentUpsert) ClearOpportunityRankFinal() *OpportunityAssessmentUpsert

ClearOpportunityRankFinal clears the value of the "opportunity_rank_final" field.

func (*OpportunityAssessmentUpsert) ClearRiceScore

ClearRiceScore clears the value of the "rice_score" field.

func (*OpportunityAssessmentUpsert) ClearRmiID

ClearRmiID clears the value of the "rmi_id" field.

func (*OpportunityAssessmentUpsert) ClearSupersedesID

ClearSupersedesID clears the value of the "supersedes_id" field.

func (*OpportunityAssessmentUpsert) ClearTitle

ClearTitle clears the value of the "title" field.

func (*OpportunityAssessmentUpsert) SetAssessedAt

SetAssessedAt sets the "assessed_at" field.

func (*OpportunityAssessmentUpsert) SetCanonical

SetCanonical sets the "canonical" field.

func (*OpportunityAssessmentUpsert) SetCompassProfileID

SetCompassProfileID sets the "compass_profile_id" field.

func (*OpportunityAssessmentUpsert) SetCurrent

SetCurrent sets the "current" field.

func (*OpportunityAssessmentUpsert) SetCycleNumber

SetCycleNumber sets the "cycle_number" field.

func (*OpportunityAssessmentUpsert) SetKanoCategory

SetKanoCategory sets the "kano_category" field.

func (*OpportunityAssessmentUpsert) SetMihCategory

SetMihCategory sets the "mih_category" field.

func (*OpportunityAssessmentUpsert) SetMoscowClass

SetMoscowClass sets the "moscow_class" field.

func (*OpportunityAssessmentUpsert) SetOpportunityRankCalculated

func (u *OpportunityAssessmentUpsert) SetOpportunityRankCalculated(v int) *OpportunityAssessmentUpsert

SetOpportunityRankCalculated sets the "opportunity_rank_calculated" field.

func (*OpportunityAssessmentUpsert) SetOpportunityRankFinal

func (u *OpportunityAssessmentUpsert) SetOpportunityRankFinal(v int) *OpportunityAssessmentUpsert

SetOpportunityRankFinal sets the "opportunity_rank_final" field.

func (*OpportunityAssessmentUpsert) SetOpportunitySpecID

SetOpportunitySpecID sets the "opportunity_spec_id" field.

func (*OpportunityAssessmentUpsert) SetRiceComputable

SetRiceComputable sets the "rice_computable" field.

func (*OpportunityAssessmentUpsert) SetRiceScore

SetRiceScore sets the "rice_score" field.

func (*OpportunityAssessmentUpsert) SetRmiID

SetRmiID sets the "rmi_id" field.

func (*OpportunityAssessmentUpsert) SetSupersedesID

SetSupersedesID sets the "supersedes_id" field.

func (*OpportunityAssessmentUpsert) SetTitle

SetTitle sets the "title" field.

func (*OpportunityAssessmentUpsert) SetUpdatedAt

SetUpdatedAt sets the "updated_at" field.

func (*OpportunityAssessmentUpsert) UpdateAssessedAt

UpdateAssessedAt sets the "assessed_at" field to the value that was provided on create.

func (*OpportunityAssessmentUpsert) UpdateCanonical

UpdateCanonical sets the "canonical" field to the value that was provided on create.

func (*OpportunityAssessmentUpsert) UpdateCompassProfileID

func (u *OpportunityAssessmentUpsert) UpdateCompassProfileID() *OpportunityAssessmentUpsert

UpdateCompassProfileID sets the "compass_profile_id" field to the value that was provided on create.

func (*OpportunityAssessmentUpsert) UpdateCurrent

UpdateCurrent sets the "current" field to the value that was provided on create.

func (*OpportunityAssessmentUpsert) UpdateCycleNumber

UpdateCycleNumber sets the "cycle_number" field to the value that was provided on create.

func (*OpportunityAssessmentUpsert) UpdateKanoCategory

UpdateKanoCategory sets the "kano_category" field to the value that was provided on create.

func (*OpportunityAssessmentUpsert) UpdateMihCategory

UpdateMihCategory sets the "mih_category" field to the value that was provided on create.

func (*OpportunityAssessmentUpsert) UpdateMoscowClass

UpdateMoscowClass sets the "moscow_class" field to the value that was provided on create.

func (*OpportunityAssessmentUpsert) UpdateOpportunityRankCalculated

func (u *OpportunityAssessmentUpsert) UpdateOpportunityRankCalculated() *OpportunityAssessmentUpsert

UpdateOpportunityRankCalculated sets the "opportunity_rank_calculated" field to the value that was provided on create.

func (*OpportunityAssessmentUpsert) UpdateOpportunityRankFinal

func (u *OpportunityAssessmentUpsert) UpdateOpportunityRankFinal() *OpportunityAssessmentUpsert

UpdateOpportunityRankFinal sets the "opportunity_rank_final" field to the value that was provided on create.

func (*OpportunityAssessmentUpsert) UpdateOpportunitySpecID

func (u *OpportunityAssessmentUpsert) UpdateOpportunitySpecID() *OpportunityAssessmentUpsert

UpdateOpportunitySpecID sets the "opportunity_spec_id" field to the value that was provided on create.

func (*OpportunityAssessmentUpsert) UpdateRiceComputable

func (u *OpportunityAssessmentUpsert) UpdateRiceComputable() *OpportunityAssessmentUpsert

UpdateRiceComputable sets the "rice_computable" field to the value that was provided on create.

func (*OpportunityAssessmentUpsert) UpdateRiceScore

UpdateRiceScore sets the "rice_score" field to the value that was provided on create.

func (*OpportunityAssessmentUpsert) UpdateRmiID

UpdateRmiID sets the "rmi_id" field to the value that was provided on create.

func (*OpportunityAssessmentUpsert) UpdateSupersedesID

UpdateSupersedesID sets the "supersedes_id" field to the value that was provided on create.

func (*OpportunityAssessmentUpsert) UpdateTitle

UpdateTitle sets the "title" field to the value that was provided on create.

func (*OpportunityAssessmentUpsert) UpdateUpdatedAt

UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.

type OpportunityAssessmentUpsertBulk

type OpportunityAssessmentUpsertBulk struct {
	// contains filtered or unexported fields
}

OpportunityAssessmentUpsertBulk is the builder for "upsert"-ing a bulk of OpportunityAssessment nodes.

func (*OpportunityAssessmentUpsertBulk) AddCycleNumber

AddCycleNumber adds v to the "cycle_number" field.

func (*OpportunityAssessmentUpsertBulk) AddOpportunityRankCalculated

func (u *OpportunityAssessmentUpsertBulk) AddOpportunityRankCalculated(v int) *OpportunityAssessmentUpsertBulk

AddOpportunityRankCalculated adds v to the "opportunity_rank_calculated" field.

func (*OpportunityAssessmentUpsertBulk) AddOpportunityRankFinal

AddOpportunityRankFinal adds v to the "opportunity_rank_final" field.

func (*OpportunityAssessmentUpsertBulk) AddRiceScore

AddRiceScore adds v to the "rice_score" field.

func (*OpportunityAssessmentUpsertBulk) ClearCompassProfileID

ClearCompassProfileID clears the value of the "compass_profile_id" field.

func (*OpportunityAssessmentUpsertBulk) ClearKanoCategory

ClearKanoCategory clears the value of the "kano_category" field.

func (*OpportunityAssessmentUpsertBulk) ClearMihCategory

ClearMihCategory clears the value of the "mih_category" field.

func (*OpportunityAssessmentUpsertBulk) ClearMoscowClass

ClearMoscowClass clears the value of the "moscow_class" field.

func (*OpportunityAssessmentUpsertBulk) ClearOpportunityRankCalculated

func (u *OpportunityAssessmentUpsertBulk) ClearOpportunityRankCalculated() *OpportunityAssessmentUpsertBulk

ClearOpportunityRankCalculated clears the value of the "opportunity_rank_calculated" field.

func (*OpportunityAssessmentUpsertBulk) ClearOpportunityRankFinal

func (u *OpportunityAssessmentUpsertBulk) ClearOpportunityRankFinal() *OpportunityAssessmentUpsertBulk

ClearOpportunityRankFinal clears the value of the "opportunity_rank_final" field.

func (*OpportunityAssessmentUpsertBulk) ClearRiceScore

ClearRiceScore clears the value of the "rice_score" field.

func (*OpportunityAssessmentUpsertBulk) ClearRmiID

ClearRmiID clears the value of the "rmi_id" field.

func (*OpportunityAssessmentUpsertBulk) ClearSupersedesID

ClearSupersedesID clears the value of the "supersedes_id" field.

func (*OpportunityAssessmentUpsertBulk) ClearTitle

ClearTitle clears the value of the "title" field.

func (*OpportunityAssessmentUpsertBulk) DoNothing

DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.

func (*OpportunityAssessmentUpsertBulk) Exec

Exec executes the query.

func (*OpportunityAssessmentUpsertBulk) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*OpportunityAssessmentUpsertBulk) Ignore

Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:

client.OpportunityAssessment.Create().
	OnConflict(sql.ResolveWithIgnore()).
	Exec(ctx)

func (*OpportunityAssessmentUpsertBulk) SetAssessedAt

SetAssessedAt sets the "assessed_at" field.

func (*OpportunityAssessmentUpsertBulk) SetCanonical

SetCanonical sets the "canonical" field.

func (*OpportunityAssessmentUpsertBulk) SetCompassProfileID

SetCompassProfileID sets the "compass_profile_id" field.

func (*OpportunityAssessmentUpsertBulk) SetCurrent

SetCurrent sets the "current" field.

func (*OpportunityAssessmentUpsertBulk) SetCycleNumber

SetCycleNumber sets the "cycle_number" field.

func (*OpportunityAssessmentUpsertBulk) SetKanoCategory

SetKanoCategory sets the "kano_category" field.

func (*OpportunityAssessmentUpsertBulk) SetMihCategory

SetMihCategory sets the "mih_category" field.

func (*OpportunityAssessmentUpsertBulk) SetMoscowClass

SetMoscowClass sets the "moscow_class" field.

func (*OpportunityAssessmentUpsertBulk) SetOpportunityRankCalculated

func (u *OpportunityAssessmentUpsertBulk) SetOpportunityRankCalculated(v int) *OpportunityAssessmentUpsertBulk

SetOpportunityRankCalculated sets the "opportunity_rank_calculated" field.

func (*OpportunityAssessmentUpsertBulk) SetOpportunityRankFinal

SetOpportunityRankFinal sets the "opportunity_rank_final" field.

func (*OpportunityAssessmentUpsertBulk) SetOpportunitySpecID

SetOpportunitySpecID sets the "opportunity_spec_id" field.

func (*OpportunityAssessmentUpsertBulk) SetRiceComputable

SetRiceComputable sets the "rice_computable" field.

func (*OpportunityAssessmentUpsertBulk) SetRiceScore

SetRiceScore sets the "rice_score" field.

func (*OpportunityAssessmentUpsertBulk) SetRmiID

SetRmiID sets the "rmi_id" field.

func (*OpportunityAssessmentUpsertBulk) SetSupersedesID

SetSupersedesID sets the "supersedes_id" field.

func (*OpportunityAssessmentUpsertBulk) SetTitle

SetTitle sets the "title" field.

func (*OpportunityAssessmentUpsertBulk) SetUpdatedAt

SetUpdatedAt sets the "updated_at" field.

func (*OpportunityAssessmentUpsertBulk) Update

Update allows overriding fields `UPDATE` values. See the OpportunityAssessmentCreateBulk.OnConflict documentation for more info.

func (*OpportunityAssessmentUpsertBulk) UpdateAssessedAt

UpdateAssessedAt sets the "assessed_at" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertBulk) UpdateCanonical

UpdateCanonical sets the "canonical" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertBulk) UpdateCompassProfileID

UpdateCompassProfileID sets the "compass_profile_id" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertBulk) UpdateCurrent

UpdateCurrent sets the "current" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertBulk) UpdateCycleNumber

UpdateCycleNumber sets the "cycle_number" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertBulk) UpdateKanoCategory

UpdateKanoCategory sets the "kano_category" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertBulk) UpdateMihCategory

UpdateMihCategory sets the "mih_category" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertBulk) UpdateMoscowClass

UpdateMoscowClass sets the "moscow_class" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertBulk) UpdateNewValues

UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:

client.OpportunityAssessment.Create().
	OnConflict(
		sql.ResolveWithNewValues(),
		sql.ResolveWith(func(u *sql.UpdateSet) {
			u.SetIgnore(opportunityassessment.FieldID)
		}),
	).
	Exec(ctx)

func (*OpportunityAssessmentUpsertBulk) UpdateOpportunityRankCalculated

func (u *OpportunityAssessmentUpsertBulk) UpdateOpportunityRankCalculated() *OpportunityAssessmentUpsertBulk

UpdateOpportunityRankCalculated sets the "opportunity_rank_calculated" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertBulk) UpdateOpportunityRankFinal

func (u *OpportunityAssessmentUpsertBulk) UpdateOpportunityRankFinal() *OpportunityAssessmentUpsertBulk

UpdateOpportunityRankFinal sets the "opportunity_rank_final" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertBulk) UpdateOpportunitySpecID

UpdateOpportunitySpecID sets the "opportunity_spec_id" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertBulk) UpdateRiceComputable

UpdateRiceComputable sets the "rice_computable" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertBulk) UpdateRiceScore

UpdateRiceScore sets the "rice_score" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertBulk) UpdateRmiID

UpdateRmiID sets the "rmi_id" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertBulk) UpdateSupersedesID

UpdateSupersedesID sets the "supersedes_id" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertBulk) UpdateTitle

UpdateTitle sets the "title" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertBulk) UpdateUpdatedAt

UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.

type OpportunityAssessmentUpsertOne

type OpportunityAssessmentUpsertOne struct {
	// contains filtered or unexported fields
}

OpportunityAssessmentUpsertOne is the builder for "upsert"-ing

one OpportunityAssessment node.

func (*OpportunityAssessmentUpsertOne) AddCycleNumber

AddCycleNumber adds v to the "cycle_number" field.

func (*OpportunityAssessmentUpsertOne) AddOpportunityRankCalculated

func (u *OpportunityAssessmentUpsertOne) AddOpportunityRankCalculated(v int) *OpportunityAssessmentUpsertOne

AddOpportunityRankCalculated adds v to the "opportunity_rank_calculated" field.

func (*OpportunityAssessmentUpsertOne) AddOpportunityRankFinal

func (u *OpportunityAssessmentUpsertOne) AddOpportunityRankFinal(v int) *OpportunityAssessmentUpsertOne

AddOpportunityRankFinal adds v to the "opportunity_rank_final" field.

func (*OpportunityAssessmentUpsertOne) AddRiceScore

AddRiceScore adds v to the "rice_score" field.

func (*OpportunityAssessmentUpsertOne) ClearCompassProfileID

ClearCompassProfileID clears the value of the "compass_profile_id" field.

func (*OpportunityAssessmentUpsertOne) ClearKanoCategory

ClearKanoCategory clears the value of the "kano_category" field.

func (*OpportunityAssessmentUpsertOne) ClearMihCategory

ClearMihCategory clears the value of the "mih_category" field.

func (*OpportunityAssessmentUpsertOne) ClearMoscowClass

ClearMoscowClass clears the value of the "moscow_class" field.

func (*OpportunityAssessmentUpsertOne) ClearOpportunityRankCalculated

func (u *OpportunityAssessmentUpsertOne) ClearOpportunityRankCalculated() *OpportunityAssessmentUpsertOne

ClearOpportunityRankCalculated clears the value of the "opportunity_rank_calculated" field.

func (*OpportunityAssessmentUpsertOne) ClearOpportunityRankFinal

func (u *OpportunityAssessmentUpsertOne) ClearOpportunityRankFinal() *OpportunityAssessmentUpsertOne

ClearOpportunityRankFinal clears the value of the "opportunity_rank_final" field.

func (*OpportunityAssessmentUpsertOne) ClearRiceScore

ClearRiceScore clears the value of the "rice_score" field.

func (*OpportunityAssessmentUpsertOne) ClearRmiID

ClearRmiID clears the value of the "rmi_id" field.

func (*OpportunityAssessmentUpsertOne) ClearSupersedesID

ClearSupersedesID clears the value of the "supersedes_id" field.

func (*OpportunityAssessmentUpsertOne) ClearTitle

ClearTitle clears the value of the "title" field.

func (*OpportunityAssessmentUpsertOne) DoNothing

DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.

func (*OpportunityAssessmentUpsertOne) Exec

Exec executes the query.

func (*OpportunityAssessmentUpsertOne) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*OpportunityAssessmentUpsertOne) ID

Exec executes the UPSERT query and returns the inserted/updated ID.

func (*OpportunityAssessmentUpsertOne) IDX

IDX is like ID, but panics if an error occurs.

func (*OpportunityAssessmentUpsertOne) Ignore

Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:

client.OpportunityAssessment.Create().
    OnConflict(sql.ResolveWithIgnore()).
    Exec(ctx)

func (*OpportunityAssessmentUpsertOne) SetAssessedAt

SetAssessedAt sets the "assessed_at" field.

func (*OpportunityAssessmentUpsertOne) SetCanonical

SetCanonical sets the "canonical" field.

func (*OpportunityAssessmentUpsertOne) SetCompassProfileID

SetCompassProfileID sets the "compass_profile_id" field.

func (*OpportunityAssessmentUpsertOne) SetCurrent

SetCurrent sets the "current" field.

func (*OpportunityAssessmentUpsertOne) SetCycleNumber

SetCycleNumber sets the "cycle_number" field.

func (*OpportunityAssessmentUpsertOne) SetKanoCategory

SetKanoCategory sets the "kano_category" field.

func (*OpportunityAssessmentUpsertOne) SetMihCategory

SetMihCategory sets the "mih_category" field.

func (*OpportunityAssessmentUpsertOne) SetMoscowClass

SetMoscowClass sets the "moscow_class" field.

func (*OpportunityAssessmentUpsertOne) SetOpportunityRankCalculated

func (u *OpportunityAssessmentUpsertOne) SetOpportunityRankCalculated(v int) *OpportunityAssessmentUpsertOne

SetOpportunityRankCalculated sets the "opportunity_rank_calculated" field.

func (*OpportunityAssessmentUpsertOne) SetOpportunityRankFinal

func (u *OpportunityAssessmentUpsertOne) SetOpportunityRankFinal(v int) *OpportunityAssessmentUpsertOne

SetOpportunityRankFinal sets the "opportunity_rank_final" field.

func (*OpportunityAssessmentUpsertOne) SetOpportunitySpecID

SetOpportunitySpecID sets the "opportunity_spec_id" field.

func (*OpportunityAssessmentUpsertOne) SetRiceComputable

SetRiceComputable sets the "rice_computable" field.

func (*OpportunityAssessmentUpsertOne) SetRiceScore

SetRiceScore sets the "rice_score" field.

func (*OpportunityAssessmentUpsertOne) SetRmiID

SetRmiID sets the "rmi_id" field.

func (*OpportunityAssessmentUpsertOne) SetSupersedesID

SetSupersedesID sets the "supersedes_id" field.

func (*OpportunityAssessmentUpsertOne) SetTitle

SetTitle sets the "title" field.

func (*OpportunityAssessmentUpsertOne) SetUpdatedAt

SetUpdatedAt sets the "updated_at" field.

func (*OpportunityAssessmentUpsertOne) Update

Update allows overriding fields `UPDATE` values. See the OpportunityAssessmentCreate.OnConflict documentation for more info.

func (*OpportunityAssessmentUpsertOne) UpdateAssessedAt

UpdateAssessedAt sets the "assessed_at" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertOne) UpdateCanonical

UpdateCanonical sets the "canonical" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertOne) UpdateCompassProfileID

UpdateCompassProfileID sets the "compass_profile_id" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertOne) UpdateCurrent

UpdateCurrent sets the "current" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertOne) UpdateCycleNumber

UpdateCycleNumber sets the "cycle_number" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertOne) UpdateKanoCategory

UpdateKanoCategory sets the "kano_category" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertOne) UpdateMihCategory

UpdateMihCategory sets the "mih_category" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertOne) UpdateMoscowClass

UpdateMoscowClass sets the "moscow_class" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertOne) UpdateNewValues

UpdateNewValues updates the mutable fields using the new values that were set on create except the ID field. Using this option is equivalent to using:

client.OpportunityAssessment.Create().
	OnConflict(
		sql.ResolveWithNewValues(),
		sql.ResolveWith(func(u *sql.UpdateSet) {
			u.SetIgnore(opportunityassessment.FieldID)
		}),
	).
	Exec(ctx)

func (*OpportunityAssessmentUpsertOne) UpdateOpportunityRankCalculated

func (u *OpportunityAssessmentUpsertOne) UpdateOpportunityRankCalculated() *OpportunityAssessmentUpsertOne

UpdateOpportunityRankCalculated sets the "opportunity_rank_calculated" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertOne) UpdateOpportunityRankFinal

func (u *OpportunityAssessmentUpsertOne) UpdateOpportunityRankFinal() *OpportunityAssessmentUpsertOne

UpdateOpportunityRankFinal sets the "opportunity_rank_final" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertOne) UpdateOpportunitySpecID

func (u *OpportunityAssessmentUpsertOne) UpdateOpportunitySpecID() *OpportunityAssessmentUpsertOne

UpdateOpportunitySpecID sets the "opportunity_spec_id" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertOne) UpdateRiceComputable

UpdateRiceComputable sets the "rice_computable" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertOne) UpdateRiceScore

UpdateRiceScore sets the "rice_score" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertOne) UpdateRmiID

UpdateRmiID sets the "rmi_id" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertOne) UpdateSupersedesID

UpdateSupersedesID sets the "supersedes_id" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertOne) UpdateTitle

UpdateTitle sets the "title" field to the value that was provided on create.

func (*OpportunityAssessmentUpsertOne) UpdateUpdatedAt

UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.

type OpportunityAssessments

type OpportunityAssessments []*OpportunityAssessment

OpportunityAssessments is a parsable slice of OpportunityAssessment.

type OpportunitySpec

type OpportunitySpec struct {

	// ID of the ent.
	ID string `json:"id,omitempty"`
	// Title holds the value of the "title" field.
	Title string `json:"title,omitempty"`
	// CreatedAt holds the value of the "created_at" field.
	CreatedAt time.Time `json:"created_at,omitempty"`
	// UpdatedAt holds the value of the "updated_at" field.
	UpdatedAt time.Time `json:"updated_at,omitempty"`
	// Canonical holds the value of the "canonical" field.
	Canonical canvas.OpportunitySpec `json:"canonical,omitempty"`
	// contains filtered or unexported fields
}

OpportunitySpec is the model entity for the OpportunitySpec schema.

func (*OpportunitySpec) String

func (_m *OpportunitySpec) String() string

String implements the fmt.Stringer.

func (*OpportunitySpec) Unwrap

func (_m *OpportunitySpec) Unwrap() *OpportunitySpec

Unwrap unwraps the OpportunitySpec entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*OpportunitySpec) Update

Update returns a builder for updating this OpportunitySpec. Note that you need to call OpportunitySpec.Unwrap() before calling this method if this OpportunitySpec was returned from a transaction, and the transaction was committed or rolled back.

func (*OpportunitySpec) Value

func (_m *OpportunitySpec) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the OpportunitySpec. This includes values selected through modifiers, order, etc.

type OpportunitySpecClient

type OpportunitySpecClient struct {
	// contains filtered or unexported fields
}

OpportunitySpecClient is a client for the OpportunitySpec schema.

func NewOpportunitySpecClient

func NewOpportunitySpecClient(c config) *OpportunitySpecClient

NewOpportunitySpecClient returns a client for the OpportunitySpec from the given config.

func (*OpportunitySpecClient) Create

Create returns a builder for creating a OpportunitySpec entity.

func (*OpportunitySpecClient) CreateBulk

CreateBulk returns a builder for creating a bulk of OpportunitySpec entities.

func (*OpportunitySpecClient) Delete

Delete returns a delete builder for OpportunitySpec.

func (*OpportunitySpecClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*OpportunitySpecClient) DeleteOneID

DeleteOneID returns a builder for deleting the given entity by its id.

func (*OpportunitySpecClient) Get

Get returns a OpportunitySpec entity by its id.

func (*OpportunitySpecClient) GetX

GetX is like Get, but panics if an error occurs.

func (*OpportunitySpecClient) Hooks

func (c *OpportunitySpecClient) Hooks() []Hook

Hooks returns the client hooks.

func (*OpportunitySpecClient) Intercept

func (c *OpportunitySpecClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `opportunityspec.Intercept(f(g(h())))`.

func (*OpportunitySpecClient) Interceptors

func (c *OpportunitySpecClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*OpportunitySpecClient) MapCreateBulk

func (c *OpportunitySpecClient) MapCreateBulk(slice any, setFunc func(*OpportunitySpecCreate, int)) *OpportunitySpecCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*OpportunitySpecClient) Query

Query returns a query builder for OpportunitySpec.

func (*OpportunitySpecClient) Update

Update returns an update builder for OpportunitySpec.

func (*OpportunitySpecClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*OpportunitySpecClient) UpdateOneID

UpdateOneID returns an update builder for the given id.

func (*OpportunitySpecClient) Use

func (c *OpportunitySpecClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `opportunityspec.Hooks(f(g(h())))`.

type OpportunitySpecCreate

type OpportunitySpecCreate struct {
	// contains filtered or unexported fields
}

OpportunitySpecCreate is the builder for creating a OpportunitySpec entity.

func (*OpportunitySpecCreate) Exec

Exec executes the query.

func (*OpportunitySpecCreate) ExecX

func (_c *OpportunitySpecCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*OpportunitySpecCreate) Mutation

Mutation returns the OpportunitySpecMutation object of the builder.

func (*OpportunitySpecCreate) OnConflict

OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:

client.OpportunitySpec.Create().
	SetTitle(v).
	OnConflict(
		// Update the row with the new values
		// the was proposed for insertion.
		sql.ResolveWithNewValues(),
	).
	// Override some of the fields with custom
	// update values.
	Update(func(u *ent.OpportunitySpecUpsert) {
		SetTitle(v+v).
	}).
	Exec(ctx)

func (*OpportunitySpecCreate) OnConflictColumns

func (_c *OpportunitySpecCreate) OnConflictColumns(columns ...string) *OpportunitySpecUpsertOne

OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:

client.OpportunitySpec.Create().
	OnConflict(sql.ConflictColumns(columns...)).
	Exec(ctx)

func (*OpportunitySpecCreate) Save

Save creates the OpportunitySpec in the database.

func (*OpportunitySpecCreate) SaveX

SaveX calls Save and panics if Save returns an error.

func (*OpportunitySpecCreate) SetCanonical

SetCanonical sets the "canonical" field.

func (*OpportunitySpecCreate) SetCreatedAt

SetCreatedAt sets the "created_at" field.

func (*OpportunitySpecCreate) SetID

SetID sets the "id" field.

func (*OpportunitySpecCreate) SetNillableCreatedAt

func (_c *OpportunitySpecCreate) SetNillableCreatedAt(v *time.Time) *OpportunitySpecCreate

SetNillableCreatedAt sets the "created_at" field if the given value is not nil.

func (*OpportunitySpecCreate) SetNillableTitle

func (_c *OpportunitySpecCreate) SetNillableTitle(v *string) *OpportunitySpecCreate

SetNillableTitle sets the "title" field if the given value is not nil.

func (*OpportunitySpecCreate) SetNillableUpdatedAt

func (_c *OpportunitySpecCreate) SetNillableUpdatedAt(v *time.Time) *OpportunitySpecCreate

SetNillableUpdatedAt sets the "updated_at" field if the given value is not nil.

func (*OpportunitySpecCreate) SetTitle

SetTitle sets the "title" field.

func (*OpportunitySpecCreate) SetUpdatedAt

SetUpdatedAt sets the "updated_at" field.

type OpportunitySpecCreateBulk

type OpportunitySpecCreateBulk struct {
	// contains filtered or unexported fields
}

OpportunitySpecCreateBulk is the builder for creating many OpportunitySpec entities in bulk.

func (*OpportunitySpecCreateBulk) Exec

Exec executes the query.

func (*OpportunitySpecCreateBulk) ExecX

func (_c *OpportunitySpecCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*OpportunitySpecCreateBulk) OnConflict

OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:

client.OpportunitySpec.CreateBulk(builders...).
	OnConflict(
		// Update the row with the new values
		// the was proposed for insertion.
		sql.ResolveWithNewValues(),
	).
	// Override some of the fields with custom
	// update values.
	Update(func(u *ent.OpportunitySpecUpsert) {
		SetTitle(v+v).
	}).
	Exec(ctx)

func (*OpportunitySpecCreateBulk) OnConflictColumns

func (_c *OpportunitySpecCreateBulk) OnConflictColumns(columns ...string) *OpportunitySpecUpsertBulk

OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:

client.OpportunitySpec.Create().
	OnConflict(sql.ConflictColumns(columns...)).
	Exec(ctx)

func (*OpportunitySpecCreateBulk) Save

Save creates the OpportunitySpec entities in the database.

func (*OpportunitySpecCreateBulk) SaveX

SaveX is like Save, but panics if an error occurs.

type OpportunitySpecDelete

type OpportunitySpecDelete struct {
	// contains filtered or unexported fields
}

OpportunitySpecDelete is the builder for deleting a OpportunitySpec entity.

func (*OpportunitySpecDelete) Exec

func (_d *OpportunitySpecDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*OpportunitySpecDelete) ExecX

func (_d *OpportunitySpecDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*OpportunitySpecDelete) Where

Where appends a list predicates to the OpportunitySpecDelete builder.

type OpportunitySpecDeleteOne

type OpportunitySpecDeleteOne struct {
	// contains filtered or unexported fields
}

OpportunitySpecDeleteOne is the builder for deleting a single OpportunitySpec entity.

func (*OpportunitySpecDeleteOne) Exec

Exec executes the deletion query.

func (*OpportunitySpecDeleteOne) ExecX

func (_d *OpportunitySpecDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*OpportunitySpecDeleteOne) Where

Where appends a list predicates to the OpportunitySpecDelete builder.

type OpportunitySpecGroupBy

type OpportunitySpecGroupBy struct {
	// contains filtered or unexported fields
}

OpportunitySpecGroupBy is the group-by builder for OpportunitySpec entities.

func (*OpportunitySpecGroupBy) Aggregate

Aggregate adds the given aggregation functions to the group-by query.

func (*OpportunitySpecGroupBy) Bool

func (s *OpportunitySpecGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*OpportunitySpecGroupBy) BoolX

func (s *OpportunitySpecGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*OpportunitySpecGroupBy) Bools

func (s *OpportunitySpecGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*OpportunitySpecGroupBy) BoolsX

func (s *OpportunitySpecGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*OpportunitySpecGroupBy) Float64

func (s *OpportunitySpecGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*OpportunitySpecGroupBy) Float64X

func (s *OpportunitySpecGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*OpportunitySpecGroupBy) Float64s

func (s *OpportunitySpecGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*OpportunitySpecGroupBy) Float64sX

func (s *OpportunitySpecGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*OpportunitySpecGroupBy) Int

func (s *OpportunitySpecGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*OpportunitySpecGroupBy) IntX

func (s *OpportunitySpecGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*OpportunitySpecGroupBy) Ints

func (s *OpportunitySpecGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*OpportunitySpecGroupBy) IntsX

func (s *OpportunitySpecGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*OpportunitySpecGroupBy) Scan

func (_g *OpportunitySpecGroupBy) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*OpportunitySpecGroupBy) ScanX

func (s *OpportunitySpecGroupBy) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*OpportunitySpecGroupBy) String

func (s *OpportunitySpecGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*OpportunitySpecGroupBy) StringX

func (s *OpportunitySpecGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*OpportunitySpecGroupBy) Strings

func (s *OpportunitySpecGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*OpportunitySpecGroupBy) StringsX

func (s *OpportunitySpecGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type OpportunitySpecMutation

type OpportunitySpecMutation struct {
	// contains filtered or unexported fields
}

OpportunitySpecMutation represents an operation that mutates the OpportunitySpec nodes in the graph.

func (*OpportunitySpecMutation) AddField

func (m *OpportunitySpecMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*OpportunitySpecMutation) AddedEdges

func (m *OpportunitySpecMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*OpportunitySpecMutation) AddedField

func (m *OpportunitySpecMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*OpportunitySpecMutation) AddedFields

func (m *OpportunitySpecMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*OpportunitySpecMutation) AddedIDs

func (m *OpportunitySpecMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*OpportunitySpecMutation) Canonical

func (m *OpportunitySpecMutation) Canonical() (r canvas.OpportunitySpec, exists bool)

Canonical returns the value of the "canonical" field in the mutation.

func (*OpportunitySpecMutation) ClearEdge

func (m *OpportunitySpecMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*OpportunitySpecMutation) ClearField

func (m *OpportunitySpecMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*OpportunitySpecMutation) ClearTitle

func (m *OpportunitySpecMutation) ClearTitle()

ClearTitle clears the value of the "title" field.

func (*OpportunitySpecMutation) ClearedEdges

func (m *OpportunitySpecMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*OpportunitySpecMutation) ClearedFields

func (m *OpportunitySpecMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (OpportunitySpecMutation) Client

func (m OpportunitySpecMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*OpportunitySpecMutation) CreatedAt

func (m *OpportunitySpecMutation) CreatedAt() (r time.Time, exists bool)

CreatedAt returns the value of the "created_at" field in the mutation.

func (*OpportunitySpecMutation) EdgeCleared

func (m *OpportunitySpecMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*OpportunitySpecMutation) Field

func (m *OpportunitySpecMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*OpportunitySpecMutation) FieldCleared

func (m *OpportunitySpecMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*OpportunitySpecMutation) Fields

func (m *OpportunitySpecMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*OpportunitySpecMutation) ID

func (m *OpportunitySpecMutation) ID() (id string, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*OpportunitySpecMutation) IDs

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*OpportunitySpecMutation) OldCanonical

func (m *OpportunitySpecMutation) OldCanonical(ctx context.Context) (v canvas.OpportunitySpec, err error)

OldCanonical returns the old "canonical" field's value of the OpportunitySpec entity. If the OpportunitySpec object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*OpportunitySpecMutation) OldCreatedAt

func (m *OpportunitySpecMutation) OldCreatedAt(ctx context.Context) (v time.Time, err error)

OldCreatedAt returns the old "created_at" field's value of the OpportunitySpec entity. If the OpportunitySpec object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*OpportunitySpecMutation) OldField

func (m *OpportunitySpecMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*OpportunitySpecMutation) OldTitle

func (m *OpportunitySpecMutation) OldTitle(ctx context.Context) (v string, err error)

OldTitle returns the old "title" field's value of the OpportunitySpec entity. If the OpportunitySpec object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*OpportunitySpecMutation) OldUpdatedAt

func (m *OpportunitySpecMutation) OldUpdatedAt(ctx context.Context) (v time.Time, err error)

OldUpdatedAt returns the old "updated_at" field's value of the OpportunitySpec entity. If the OpportunitySpec object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*OpportunitySpecMutation) Op

func (m *OpportunitySpecMutation) Op() Op

Op returns the operation name.

func (*OpportunitySpecMutation) RemovedEdges

func (m *OpportunitySpecMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*OpportunitySpecMutation) RemovedIDs

func (m *OpportunitySpecMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*OpportunitySpecMutation) ResetCanonical

func (m *OpportunitySpecMutation) ResetCanonical()

ResetCanonical resets all changes to the "canonical" field.

func (*OpportunitySpecMutation) ResetCreatedAt

func (m *OpportunitySpecMutation) ResetCreatedAt()

ResetCreatedAt resets all changes to the "created_at" field.

func (*OpportunitySpecMutation) ResetEdge

func (m *OpportunitySpecMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*OpportunitySpecMutation) ResetField

func (m *OpportunitySpecMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*OpportunitySpecMutation) ResetTitle

func (m *OpportunitySpecMutation) ResetTitle()

ResetTitle resets all changes to the "title" field.

func (*OpportunitySpecMutation) ResetUpdatedAt

func (m *OpportunitySpecMutation) ResetUpdatedAt()

ResetUpdatedAt resets all changes to the "updated_at" field.

func (*OpportunitySpecMutation) SetCanonical

func (m *OpportunitySpecMutation) SetCanonical(cs canvas.OpportunitySpec)

SetCanonical sets the "canonical" field.

func (*OpportunitySpecMutation) SetCreatedAt

func (m *OpportunitySpecMutation) SetCreatedAt(t time.Time)

SetCreatedAt sets the "created_at" field.

func (*OpportunitySpecMutation) SetField

func (m *OpportunitySpecMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*OpportunitySpecMutation) SetID

func (m *OpportunitySpecMutation) SetID(id string)

SetID sets the value of the id field. Note that this operation is only accepted on creation of OpportunitySpec entities.

func (*OpportunitySpecMutation) SetOp

func (m *OpportunitySpecMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*OpportunitySpecMutation) SetTitle

func (m *OpportunitySpecMutation) SetTitle(s string)

SetTitle sets the "title" field.

func (*OpportunitySpecMutation) SetUpdatedAt

func (m *OpportunitySpecMutation) SetUpdatedAt(t time.Time)

SetUpdatedAt sets the "updated_at" field.

func (*OpportunitySpecMutation) Title

func (m *OpportunitySpecMutation) Title() (r string, exists bool)

Title returns the value of the "title" field in the mutation.

func (*OpportunitySpecMutation) TitleCleared

func (m *OpportunitySpecMutation) TitleCleared() bool

TitleCleared returns if the "title" field was cleared in this mutation.

func (OpportunitySpecMutation) Tx

func (m OpportunitySpecMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*OpportunitySpecMutation) Type

func (m *OpportunitySpecMutation) Type() string

Type returns the node type of this mutation (OpportunitySpec).

func (*OpportunitySpecMutation) UpdatedAt

func (m *OpportunitySpecMutation) UpdatedAt() (r time.Time, exists bool)

UpdatedAt returns the value of the "updated_at" field in the mutation.

func (*OpportunitySpecMutation) Where

Where appends a list predicates to the OpportunitySpecMutation builder.

func (*OpportunitySpecMutation) WhereP

func (m *OpportunitySpecMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the OpportunitySpecMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

type OpportunitySpecQuery

type OpportunitySpecQuery struct {
	// contains filtered or unexported fields
}

OpportunitySpecQuery is the builder for querying OpportunitySpec entities.

func (*OpportunitySpecQuery) Aggregate

Aggregate returns a OpportunitySpecSelect configured with the given aggregations.

func (*OpportunitySpecQuery) All

All executes the query and returns a list of OpportunitySpecs.

func (*OpportunitySpecQuery) AllX

AllX is like All, but panics if an error occurs.

func (*OpportunitySpecQuery) Clone

Clone returns a duplicate of the OpportunitySpecQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*OpportunitySpecQuery) Count

func (_q *OpportunitySpecQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*OpportunitySpecQuery) CountX

func (_q *OpportunitySpecQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*OpportunitySpecQuery) Exist

func (_q *OpportunitySpecQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*OpportunitySpecQuery) ExistX

func (_q *OpportunitySpecQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*OpportunitySpecQuery) First

First returns the first OpportunitySpec entity from the query. Returns a *NotFoundError when no OpportunitySpec was found.

func (*OpportunitySpecQuery) FirstID

func (_q *OpportunitySpecQuery) FirstID(ctx context.Context) (id string, err error)

FirstID returns the first OpportunitySpec ID from the query. Returns a *NotFoundError when no OpportunitySpec ID was found.

func (*OpportunitySpecQuery) FirstIDX

func (_q *OpportunitySpecQuery) FirstIDX(ctx context.Context) string

FirstIDX is like FirstID, but panics if an error occurs.

func (*OpportunitySpecQuery) FirstX

FirstX is like First, but panics if an error occurs.

func (*OpportunitySpecQuery) GroupBy

func (_q *OpportunitySpecQuery) GroupBy(field string, fields ...string) *OpportunitySpecGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	Title string `json:"title,omitempty"`
	Count int `json:"count,omitempty"`
}

client.OpportunitySpec.Query().
	GroupBy(opportunityspec.FieldTitle).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*OpportunitySpecQuery) IDs

func (_q *OpportunitySpecQuery) IDs(ctx context.Context) (ids []string, err error)

IDs executes the query and returns a list of OpportunitySpec IDs.

func (*OpportunitySpecQuery) IDsX

func (_q *OpportunitySpecQuery) IDsX(ctx context.Context) []string

IDsX is like IDs, but panics if an error occurs.

func (*OpportunitySpecQuery) Limit

func (_q *OpportunitySpecQuery) Limit(limit int) *OpportunitySpecQuery

Limit the number of records to be returned by this query.

func (*OpportunitySpecQuery) Offset

func (_q *OpportunitySpecQuery) Offset(offset int) *OpportunitySpecQuery

Offset to start from.

func (*OpportunitySpecQuery) Only

Only returns a single OpportunitySpec entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one OpportunitySpec entity is found. Returns a *NotFoundError when no OpportunitySpec entities are found.

func (*OpportunitySpecQuery) OnlyID

func (_q *OpportunitySpecQuery) OnlyID(ctx context.Context) (id string, err error)

OnlyID is like Only, but returns the only OpportunitySpec ID in the query. Returns a *NotSingularError when more than one OpportunitySpec ID is found. Returns a *NotFoundError when no entities are found.

func (*OpportunitySpecQuery) OnlyIDX

func (_q *OpportunitySpecQuery) OnlyIDX(ctx context.Context) string

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*OpportunitySpecQuery) OnlyX

OnlyX is like Only, but panics if an error occurs.

func (*OpportunitySpecQuery) Order

Order specifies how the records should be ordered.

func (*OpportunitySpecQuery) Select

func (_q *OpportunitySpecQuery) Select(fields ...string) *OpportunitySpecSelect

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	Title string `json:"title,omitempty"`
}

client.OpportunitySpec.Query().
	Select(opportunityspec.FieldTitle).
	Scan(ctx, &v)

func (*OpportunitySpecQuery) Unique

func (_q *OpportunitySpecQuery) Unique(unique bool) *OpportunitySpecQuery

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*OpportunitySpecQuery) Where

Where adds a new predicate for the OpportunitySpecQuery builder.

type OpportunitySpecSelect

type OpportunitySpecSelect struct {
	*OpportunitySpecQuery
	// contains filtered or unexported fields
}

OpportunitySpecSelect is the builder for selecting fields of OpportunitySpec entities.

func (*OpportunitySpecSelect) Aggregate

Aggregate adds the given aggregation functions to the selector query.

func (*OpportunitySpecSelect) Bool

func (s *OpportunitySpecSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*OpportunitySpecSelect) BoolX

func (s *OpportunitySpecSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*OpportunitySpecSelect) Bools

func (s *OpportunitySpecSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*OpportunitySpecSelect) BoolsX

func (s *OpportunitySpecSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*OpportunitySpecSelect) Float64

func (s *OpportunitySpecSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*OpportunitySpecSelect) Float64X

func (s *OpportunitySpecSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*OpportunitySpecSelect) Float64s

func (s *OpportunitySpecSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*OpportunitySpecSelect) Float64sX

func (s *OpportunitySpecSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*OpportunitySpecSelect) Int

func (s *OpportunitySpecSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*OpportunitySpecSelect) IntX

func (s *OpportunitySpecSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*OpportunitySpecSelect) Ints

func (s *OpportunitySpecSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*OpportunitySpecSelect) IntsX

func (s *OpportunitySpecSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*OpportunitySpecSelect) Scan

func (_s *OpportunitySpecSelect) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*OpportunitySpecSelect) ScanX

func (s *OpportunitySpecSelect) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*OpportunitySpecSelect) String

func (s *OpportunitySpecSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*OpportunitySpecSelect) StringX

func (s *OpportunitySpecSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*OpportunitySpecSelect) Strings

func (s *OpportunitySpecSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*OpportunitySpecSelect) StringsX

func (s *OpportunitySpecSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type OpportunitySpecUpdate

type OpportunitySpecUpdate struct {
	// contains filtered or unexported fields
}

OpportunitySpecUpdate is the builder for updating OpportunitySpec entities.

func (*OpportunitySpecUpdate) ClearTitle

func (_u *OpportunitySpecUpdate) ClearTitle() *OpportunitySpecUpdate

ClearTitle clears the value of the "title" field.

func (*OpportunitySpecUpdate) Exec

Exec executes the query.

func (*OpportunitySpecUpdate) ExecX

func (_u *OpportunitySpecUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*OpportunitySpecUpdate) Mutation

Mutation returns the OpportunitySpecMutation object of the builder.

func (*OpportunitySpecUpdate) Save

func (_u *OpportunitySpecUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*OpportunitySpecUpdate) SaveX

func (_u *OpportunitySpecUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*OpportunitySpecUpdate) SetCanonical

SetCanonical sets the "canonical" field.

func (*OpportunitySpecUpdate) SetNillableCanonical

func (_u *OpportunitySpecUpdate) SetNillableCanonical(v *canvas.OpportunitySpec) *OpportunitySpecUpdate

SetNillableCanonical sets the "canonical" field if the given value is not nil.

func (*OpportunitySpecUpdate) SetNillableTitle

func (_u *OpportunitySpecUpdate) SetNillableTitle(v *string) *OpportunitySpecUpdate

SetNillableTitle sets the "title" field if the given value is not nil.

func (*OpportunitySpecUpdate) SetTitle

SetTitle sets the "title" field.

func (*OpportunitySpecUpdate) SetUpdatedAt

SetUpdatedAt sets the "updated_at" field.

func (*OpportunitySpecUpdate) Where

Where appends a list predicates to the OpportunitySpecUpdate builder.

type OpportunitySpecUpdateOne

type OpportunitySpecUpdateOne struct {
	// contains filtered or unexported fields
}

OpportunitySpecUpdateOne is the builder for updating a single OpportunitySpec entity.

func (*OpportunitySpecUpdateOne) ClearTitle

ClearTitle clears the value of the "title" field.

func (*OpportunitySpecUpdateOne) Exec

Exec executes the query on the entity.

func (*OpportunitySpecUpdateOne) ExecX

func (_u *OpportunitySpecUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*OpportunitySpecUpdateOne) Mutation

Mutation returns the OpportunitySpecMutation object of the builder.

func (*OpportunitySpecUpdateOne) Save

Save executes the query and returns the updated OpportunitySpec entity.

func (*OpportunitySpecUpdateOne) SaveX

SaveX is like Save, but panics if an error occurs.

func (*OpportunitySpecUpdateOne) Select

func (_u *OpportunitySpecUpdateOne) Select(field string, fields ...string) *OpportunitySpecUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*OpportunitySpecUpdateOne) SetCanonical

SetCanonical sets the "canonical" field.

func (*OpportunitySpecUpdateOne) SetNillableCanonical

SetNillableCanonical sets the "canonical" field if the given value is not nil.

func (*OpportunitySpecUpdateOne) SetNillableTitle

func (_u *OpportunitySpecUpdateOne) SetNillableTitle(v *string) *OpportunitySpecUpdateOne

SetNillableTitle sets the "title" field if the given value is not nil.

func (*OpportunitySpecUpdateOne) SetTitle

SetTitle sets the "title" field.

func (*OpportunitySpecUpdateOne) SetUpdatedAt

SetUpdatedAt sets the "updated_at" field.

func (*OpportunitySpecUpdateOne) Where

Where appends a list predicates to the OpportunitySpecUpdate builder.

type OpportunitySpecUpsert

type OpportunitySpecUpsert struct {
	*sql.UpdateSet
}

OpportunitySpecUpsert is the "OnConflict" setter.

func (*OpportunitySpecUpsert) ClearTitle

ClearTitle clears the value of the "title" field.

func (*OpportunitySpecUpsert) SetCanonical

SetCanonical sets the "canonical" field.

func (*OpportunitySpecUpsert) SetTitle

SetTitle sets the "title" field.

func (*OpportunitySpecUpsert) SetUpdatedAt

SetUpdatedAt sets the "updated_at" field.

func (*OpportunitySpecUpsert) UpdateCanonical

func (u *OpportunitySpecUpsert) UpdateCanonical() *OpportunitySpecUpsert

UpdateCanonical sets the "canonical" field to the value that was provided on create.

func (*OpportunitySpecUpsert) UpdateTitle

func (u *OpportunitySpecUpsert) UpdateTitle() *OpportunitySpecUpsert

UpdateTitle sets the "title" field to the value that was provided on create.

func (*OpportunitySpecUpsert) UpdateUpdatedAt

func (u *OpportunitySpecUpsert) UpdateUpdatedAt() *OpportunitySpecUpsert

UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.

type OpportunitySpecUpsertBulk

type OpportunitySpecUpsertBulk struct {
	// contains filtered or unexported fields
}

OpportunitySpecUpsertBulk is the builder for "upsert"-ing a bulk of OpportunitySpec nodes.

func (*OpportunitySpecUpsertBulk) ClearTitle

ClearTitle clears the value of the "title" field.

func (*OpportunitySpecUpsertBulk) DoNothing

DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.

func (*OpportunitySpecUpsertBulk) Exec

Exec executes the query.

func (*OpportunitySpecUpsertBulk) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*OpportunitySpecUpsertBulk) Ignore

Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:

client.OpportunitySpec.Create().
	OnConflict(sql.ResolveWithIgnore()).
	Exec(ctx)

func (*OpportunitySpecUpsertBulk) SetCanonical

SetCanonical sets the "canonical" field.

func (*OpportunitySpecUpsertBulk) SetTitle

SetTitle sets the "title" field.

func (*OpportunitySpecUpsertBulk) SetUpdatedAt

SetUpdatedAt sets the "updated_at" field.

func (*OpportunitySpecUpsertBulk) Update

Update allows overriding fields `UPDATE` values. See the OpportunitySpecCreateBulk.OnConflict documentation for more info.

func (*OpportunitySpecUpsertBulk) UpdateCanonical

UpdateCanonical sets the "canonical" field to the value that was provided on create.

func (*OpportunitySpecUpsertBulk) UpdateNewValues

UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:

client.OpportunitySpec.Create().
	OnConflict(
		sql.ResolveWithNewValues(),
		sql.ResolveWith(func(u *sql.UpdateSet) {
			u.SetIgnore(opportunityspec.FieldID)
		}),
	).
	Exec(ctx)

func (*OpportunitySpecUpsertBulk) UpdateTitle

UpdateTitle sets the "title" field to the value that was provided on create.

func (*OpportunitySpecUpsertBulk) UpdateUpdatedAt

UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.

type OpportunitySpecUpsertOne

type OpportunitySpecUpsertOne struct {
	// contains filtered or unexported fields
}

OpportunitySpecUpsertOne is the builder for "upsert"-ing

one OpportunitySpec node.

func (*OpportunitySpecUpsertOne) ClearTitle

ClearTitle clears the value of the "title" field.

func (*OpportunitySpecUpsertOne) DoNothing

DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.

func (*OpportunitySpecUpsertOne) Exec

Exec executes the query.

func (*OpportunitySpecUpsertOne) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*OpportunitySpecUpsertOne) ID

func (u *OpportunitySpecUpsertOne) ID(ctx context.Context) (id string, err error)

Exec executes the UPSERT query and returns the inserted/updated ID.

func (*OpportunitySpecUpsertOne) IDX

IDX is like ID, but panics if an error occurs.

func (*OpportunitySpecUpsertOne) Ignore

Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:

client.OpportunitySpec.Create().
    OnConflict(sql.ResolveWithIgnore()).
    Exec(ctx)

func (*OpportunitySpecUpsertOne) SetCanonical

SetCanonical sets the "canonical" field.

func (*OpportunitySpecUpsertOne) SetTitle

SetTitle sets the "title" field.

func (*OpportunitySpecUpsertOne) SetUpdatedAt

SetUpdatedAt sets the "updated_at" field.

func (*OpportunitySpecUpsertOne) Update

Update allows overriding fields `UPDATE` values. See the OpportunitySpecCreate.OnConflict documentation for more info.

func (*OpportunitySpecUpsertOne) UpdateCanonical

func (u *OpportunitySpecUpsertOne) UpdateCanonical() *OpportunitySpecUpsertOne

UpdateCanonical sets the "canonical" field to the value that was provided on create.

func (*OpportunitySpecUpsertOne) UpdateNewValues

func (u *OpportunitySpecUpsertOne) UpdateNewValues() *OpportunitySpecUpsertOne

UpdateNewValues updates the mutable fields using the new values that were set on create except the ID field. Using this option is equivalent to using:

client.OpportunitySpec.Create().
	OnConflict(
		sql.ResolveWithNewValues(),
		sql.ResolveWith(func(u *sql.UpdateSet) {
			u.SetIgnore(opportunityspec.FieldID)
		}),
	).
	Exec(ctx)

func (*OpportunitySpecUpsertOne) UpdateTitle

UpdateTitle sets the "title" field to the value that was provided on create.

func (*OpportunitySpecUpsertOne) UpdateUpdatedAt

func (u *OpportunitySpecUpsertOne) UpdateUpdatedAt() *OpportunitySpecUpsertOne

UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.

type OpportunitySpecs

type OpportunitySpecs []*OpportunitySpec

OpportunitySpecs is a parsable slice of OpportunitySpec.

type Option

type Option func(*config)

Option function to configure the client.

func Debug

func Debug() Option

Debug enables debug logging on the ent.Driver.

func Driver

func Driver(driver dialect.Driver) Option

Driver configures the client driver.

func Log

func Log(fn func(...any)) Option

Log sets the logging function for debug mode.

type OrderFunc

type OrderFunc func(*sql.Selector)

OrderFunc applies an ordering on the sql selector. Deprecated: Use Asc/Desc functions or the package builders instead.

type Policy

type Policy = ent.Policy

ent aliases to avoid import conflicts in user's code.

type PortfolioDimension

type PortfolioDimension struct {

	// ID of the ent.
	ID string `json:"id,omitempty"`
	// DimensionID holds the value of the "dimension_id" field.
	DimensionID string `json:"dimension_id,omitempty"`
	// Version holds the value of the "version" field.
	Version string `json:"version,omitempty"`
	// Name holds the value of the "name" field.
	Name string `json:"name,omitempty"`
	// Kind holds the value of the "kind" field.
	Kind string `json:"kind,omitempty"`
	// BuiltIn holds the value of the "built_in" field.
	BuiltIn bool `json:"built_in,omitempty"`
	// CreatedAt holds the value of the "created_at" field.
	CreatedAt time.Time `json:"created_at,omitempty"`
	// contains filtered or unexported fields
}

PortfolioDimension is the model entity for the PortfolioDimension schema.

func (*PortfolioDimension) String

func (_m *PortfolioDimension) String() string

String implements the fmt.Stringer.

func (*PortfolioDimension) Unwrap

func (_m *PortfolioDimension) Unwrap() *PortfolioDimension

Unwrap unwraps the PortfolioDimension entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*PortfolioDimension) Update

Update returns a builder for updating this PortfolioDimension. Note that you need to call PortfolioDimension.Unwrap() before calling this method if this PortfolioDimension was returned from a transaction, and the transaction was committed or rolled back.

func (*PortfolioDimension) Value

func (_m *PortfolioDimension) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the PortfolioDimension. This includes values selected through modifiers, order, etc.

type PortfolioDimensionClient

type PortfolioDimensionClient struct {
	// contains filtered or unexported fields
}

PortfolioDimensionClient is a client for the PortfolioDimension schema.

func NewPortfolioDimensionClient

func NewPortfolioDimensionClient(c config) *PortfolioDimensionClient

NewPortfolioDimensionClient returns a client for the PortfolioDimension from the given config.

func (*PortfolioDimensionClient) Create

Create returns a builder for creating a PortfolioDimension entity.

func (*PortfolioDimensionClient) CreateBulk

CreateBulk returns a builder for creating a bulk of PortfolioDimension entities.

func (*PortfolioDimensionClient) Delete

Delete returns a delete builder for PortfolioDimension.

func (*PortfolioDimensionClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*PortfolioDimensionClient) DeleteOneID

DeleteOneID returns a builder for deleting the given entity by its id.

func (*PortfolioDimensionClient) Get

Get returns a PortfolioDimension entity by its id.

func (*PortfolioDimensionClient) GetX

GetX is like Get, but panics if an error occurs.

func (*PortfolioDimensionClient) Hooks

func (c *PortfolioDimensionClient) Hooks() []Hook

Hooks returns the client hooks.

func (*PortfolioDimensionClient) Intercept

func (c *PortfolioDimensionClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `portfoliodimension.Intercept(f(g(h())))`.

func (*PortfolioDimensionClient) Interceptors

func (c *PortfolioDimensionClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*PortfolioDimensionClient) MapCreateBulk

func (c *PortfolioDimensionClient) MapCreateBulk(slice any, setFunc func(*PortfolioDimensionCreate, int)) *PortfolioDimensionCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*PortfolioDimensionClient) Query

Query returns a query builder for PortfolioDimension.

func (*PortfolioDimensionClient) Update

Update returns an update builder for PortfolioDimension.

func (*PortfolioDimensionClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*PortfolioDimensionClient) UpdateOneID

UpdateOneID returns an update builder for the given id.

func (*PortfolioDimensionClient) Use

func (c *PortfolioDimensionClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `portfoliodimension.Hooks(f(g(h())))`.

type PortfolioDimensionCreate

type PortfolioDimensionCreate struct {
	// contains filtered or unexported fields
}

PortfolioDimensionCreate is the builder for creating a PortfolioDimension entity.

func (*PortfolioDimensionCreate) Exec

Exec executes the query.

func (*PortfolioDimensionCreate) ExecX

func (_c *PortfolioDimensionCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*PortfolioDimensionCreate) Mutation

Mutation returns the PortfolioDimensionMutation object of the builder.

func (*PortfolioDimensionCreate) OnConflict

OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:

client.PortfolioDimension.Create().
	SetDimensionID(v).
	OnConflict(
		// Update the row with the new values
		// the was proposed for insertion.
		sql.ResolveWithNewValues(),
	).
	// Override some of the fields with custom
	// update values.
	Update(func(u *ent.PortfolioDimensionUpsert) {
		SetDimensionID(v+v).
	}).
	Exec(ctx)

func (*PortfolioDimensionCreate) OnConflictColumns

func (_c *PortfolioDimensionCreate) OnConflictColumns(columns ...string) *PortfolioDimensionUpsertOne

OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:

client.PortfolioDimension.Create().
	OnConflict(sql.ConflictColumns(columns...)).
	Exec(ctx)

func (*PortfolioDimensionCreate) Save

Save creates the PortfolioDimension in the database.

func (*PortfolioDimensionCreate) SaveX

SaveX calls Save and panics if Save returns an error.

func (*PortfolioDimensionCreate) SetBuiltIn

SetBuiltIn sets the "built_in" field.

func (*PortfolioDimensionCreate) SetCreatedAt

SetCreatedAt sets the "created_at" field.

func (*PortfolioDimensionCreate) SetDimensionID

SetDimensionID sets the "dimension_id" field.

func (*PortfolioDimensionCreate) SetID

SetID sets the "id" field.

func (*PortfolioDimensionCreate) SetKind

SetKind sets the "kind" field.

func (*PortfolioDimensionCreate) SetName

SetName sets the "name" field.

func (*PortfolioDimensionCreate) SetNillableBuiltIn

func (_c *PortfolioDimensionCreate) SetNillableBuiltIn(v *bool) *PortfolioDimensionCreate

SetNillableBuiltIn sets the "built_in" field if the given value is not nil.

func (*PortfolioDimensionCreate) SetNillableCreatedAt

func (_c *PortfolioDimensionCreate) SetNillableCreatedAt(v *time.Time) *PortfolioDimensionCreate

SetNillableCreatedAt sets the "created_at" field if the given value is not nil.

func (*PortfolioDimensionCreate) SetVersion

SetVersion sets the "version" field.

type PortfolioDimensionCreateBulk

type PortfolioDimensionCreateBulk struct {
	// contains filtered or unexported fields
}

PortfolioDimensionCreateBulk is the builder for creating many PortfolioDimension entities in bulk.

func (*PortfolioDimensionCreateBulk) Exec

Exec executes the query.

func (*PortfolioDimensionCreateBulk) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*PortfolioDimensionCreateBulk) OnConflict

OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:

client.PortfolioDimension.CreateBulk(builders...).
	OnConflict(
		// Update the row with the new values
		// the was proposed for insertion.
		sql.ResolveWithNewValues(),
	).
	// Override some of the fields with custom
	// update values.
	Update(func(u *ent.PortfolioDimensionUpsert) {
		SetDimensionID(v+v).
	}).
	Exec(ctx)

func (*PortfolioDimensionCreateBulk) OnConflictColumns

func (_c *PortfolioDimensionCreateBulk) OnConflictColumns(columns ...string) *PortfolioDimensionUpsertBulk

OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:

client.PortfolioDimension.Create().
	OnConflict(sql.ConflictColumns(columns...)).
	Exec(ctx)

func (*PortfolioDimensionCreateBulk) Save

Save creates the PortfolioDimension entities in the database.

func (*PortfolioDimensionCreateBulk) SaveX

SaveX is like Save, but panics if an error occurs.

type PortfolioDimensionDelete

type PortfolioDimensionDelete struct {
	// contains filtered or unexported fields
}

PortfolioDimensionDelete is the builder for deleting a PortfolioDimension entity.

func (*PortfolioDimensionDelete) Exec

Exec executes the deletion query and returns how many vertices were deleted.

func (*PortfolioDimensionDelete) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*PortfolioDimensionDelete) Where

Where appends a list predicates to the PortfolioDimensionDelete builder.

type PortfolioDimensionDeleteOne

type PortfolioDimensionDeleteOne struct {
	// contains filtered or unexported fields
}

PortfolioDimensionDeleteOne is the builder for deleting a single PortfolioDimension entity.

func (*PortfolioDimensionDeleteOne) Exec

Exec executes the deletion query.

func (*PortfolioDimensionDeleteOne) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*PortfolioDimensionDeleteOne) Where

Where appends a list predicates to the PortfolioDimensionDelete builder.

type PortfolioDimensionGroupBy

type PortfolioDimensionGroupBy struct {
	// contains filtered or unexported fields
}

PortfolioDimensionGroupBy is the group-by builder for PortfolioDimension entities.

func (*PortfolioDimensionGroupBy) Aggregate

Aggregate adds the given aggregation functions to the group-by query.

func (*PortfolioDimensionGroupBy) Bool

func (s *PortfolioDimensionGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*PortfolioDimensionGroupBy) BoolX

func (s *PortfolioDimensionGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*PortfolioDimensionGroupBy) Bools

func (s *PortfolioDimensionGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*PortfolioDimensionGroupBy) BoolsX

func (s *PortfolioDimensionGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*PortfolioDimensionGroupBy) Float64

func (s *PortfolioDimensionGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*PortfolioDimensionGroupBy) Float64X

func (s *PortfolioDimensionGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*PortfolioDimensionGroupBy) Float64s

func (s *PortfolioDimensionGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*PortfolioDimensionGroupBy) Float64sX

func (s *PortfolioDimensionGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*PortfolioDimensionGroupBy) Int

func (s *PortfolioDimensionGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*PortfolioDimensionGroupBy) IntX

func (s *PortfolioDimensionGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*PortfolioDimensionGroupBy) Ints

func (s *PortfolioDimensionGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*PortfolioDimensionGroupBy) IntsX

func (s *PortfolioDimensionGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*PortfolioDimensionGroupBy) Scan

Scan applies the selector query and scans the result into the given value.

func (*PortfolioDimensionGroupBy) ScanX

func (s *PortfolioDimensionGroupBy) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*PortfolioDimensionGroupBy) String

func (s *PortfolioDimensionGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*PortfolioDimensionGroupBy) StringX

func (s *PortfolioDimensionGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*PortfolioDimensionGroupBy) Strings

func (s *PortfolioDimensionGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*PortfolioDimensionGroupBy) StringsX

func (s *PortfolioDimensionGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type PortfolioDimensionMutation

type PortfolioDimensionMutation struct {
	// contains filtered or unexported fields
}

PortfolioDimensionMutation represents an operation that mutates the PortfolioDimension nodes in the graph.

func (*PortfolioDimensionMutation) AddField

func (m *PortfolioDimensionMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*PortfolioDimensionMutation) AddedEdges

func (m *PortfolioDimensionMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*PortfolioDimensionMutation) AddedField

func (m *PortfolioDimensionMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*PortfolioDimensionMutation) AddedFields

func (m *PortfolioDimensionMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*PortfolioDimensionMutation) AddedIDs

func (m *PortfolioDimensionMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*PortfolioDimensionMutation) BuiltIn

func (m *PortfolioDimensionMutation) BuiltIn() (r bool, exists bool)

BuiltIn returns the value of the "built_in" field in the mutation.

func (*PortfolioDimensionMutation) ClearEdge

func (m *PortfolioDimensionMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*PortfolioDimensionMutation) ClearField

func (m *PortfolioDimensionMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*PortfolioDimensionMutation) ClearedEdges

func (m *PortfolioDimensionMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*PortfolioDimensionMutation) ClearedFields

func (m *PortfolioDimensionMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (PortfolioDimensionMutation) Client

func (m PortfolioDimensionMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*PortfolioDimensionMutation) CreatedAt

func (m *PortfolioDimensionMutation) CreatedAt() (r time.Time, exists bool)

CreatedAt returns the value of the "created_at" field in the mutation.

func (*PortfolioDimensionMutation) DimensionID

func (m *PortfolioDimensionMutation) DimensionID() (r string, exists bool)

DimensionID returns the value of the "dimension_id" field in the mutation.

func (*PortfolioDimensionMutation) EdgeCleared

func (m *PortfolioDimensionMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*PortfolioDimensionMutation) Field

func (m *PortfolioDimensionMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*PortfolioDimensionMutation) FieldCleared

func (m *PortfolioDimensionMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*PortfolioDimensionMutation) Fields

func (m *PortfolioDimensionMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*PortfolioDimensionMutation) ID

func (m *PortfolioDimensionMutation) ID() (id string, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*PortfolioDimensionMutation) IDs

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*PortfolioDimensionMutation) Kind

func (m *PortfolioDimensionMutation) Kind() (r string, exists bool)

Kind returns the value of the "kind" field in the mutation.

func (*PortfolioDimensionMutation) Name

func (m *PortfolioDimensionMutation) Name() (r string, exists bool)

Name returns the value of the "name" field in the mutation.

func (*PortfolioDimensionMutation) OldBuiltIn

func (m *PortfolioDimensionMutation) OldBuiltIn(ctx context.Context) (v bool, err error)

OldBuiltIn returns the old "built_in" field's value of the PortfolioDimension entity. If the PortfolioDimension object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*PortfolioDimensionMutation) OldCreatedAt

func (m *PortfolioDimensionMutation) OldCreatedAt(ctx context.Context) (v time.Time, err error)

OldCreatedAt returns the old "created_at" field's value of the PortfolioDimension entity. If the PortfolioDimension object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*PortfolioDimensionMutation) OldDimensionID

func (m *PortfolioDimensionMutation) OldDimensionID(ctx context.Context) (v string, err error)

OldDimensionID returns the old "dimension_id" field's value of the PortfolioDimension entity. If the PortfolioDimension object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*PortfolioDimensionMutation) OldField

func (m *PortfolioDimensionMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*PortfolioDimensionMutation) OldKind

func (m *PortfolioDimensionMutation) OldKind(ctx context.Context) (v string, err error)

OldKind returns the old "kind" field's value of the PortfolioDimension entity. If the PortfolioDimension object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*PortfolioDimensionMutation) OldName

func (m *PortfolioDimensionMutation) OldName(ctx context.Context) (v string, err error)

OldName returns the old "name" field's value of the PortfolioDimension entity. If the PortfolioDimension object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*PortfolioDimensionMutation) OldVersion

func (m *PortfolioDimensionMutation) OldVersion(ctx context.Context) (v string, err error)

OldVersion returns the old "version" field's value of the PortfolioDimension entity. If the PortfolioDimension object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*PortfolioDimensionMutation) Op

Op returns the operation name.

func (*PortfolioDimensionMutation) RemovedEdges

func (m *PortfolioDimensionMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*PortfolioDimensionMutation) RemovedIDs

func (m *PortfolioDimensionMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*PortfolioDimensionMutation) ResetBuiltIn

func (m *PortfolioDimensionMutation) ResetBuiltIn()

ResetBuiltIn resets all changes to the "built_in" field.

func (*PortfolioDimensionMutation) ResetCreatedAt

func (m *PortfolioDimensionMutation) ResetCreatedAt()

ResetCreatedAt resets all changes to the "created_at" field.

func (*PortfolioDimensionMutation) ResetDimensionID

func (m *PortfolioDimensionMutation) ResetDimensionID()

ResetDimensionID resets all changes to the "dimension_id" field.

func (*PortfolioDimensionMutation) ResetEdge

func (m *PortfolioDimensionMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*PortfolioDimensionMutation) ResetField

func (m *PortfolioDimensionMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*PortfolioDimensionMutation) ResetKind

func (m *PortfolioDimensionMutation) ResetKind()

ResetKind resets all changes to the "kind" field.

func (*PortfolioDimensionMutation) ResetName

func (m *PortfolioDimensionMutation) ResetName()

ResetName resets all changes to the "name" field.

func (*PortfolioDimensionMutation) ResetVersion

func (m *PortfolioDimensionMutation) ResetVersion()

ResetVersion resets all changes to the "version" field.

func (*PortfolioDimensionMutation) SetBuiltIn

func (m *PortfolioDimensionMutation) SetBuiltIn(b bool)

SetBuiltIn sets the "built_in" field.

func (*PortfolioDimensionMutation) SetCreatedAt

func (m *PortfolioDimensionMutation) SetCreatedAt(t time.Time)

SetCreatedAt sets the "created_at" field.

func (*PortfolioDimensionMutation) SetDimensionID

func (m *PortfolioDimensionMutation) SetDimensionID(s string)

SetDimensionID sets the "dimension_id" field.

func (*PortfolioDimensionMutation) SetField

func (m *PortfolioDimensionMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*PortfolioDimensionMutation) SetID

func (m *PortfolioDimensionMutation) SetID(id string)

SetID sets the value of the id field. Note that this operation is only accepted on creation of PortfolioDimension entities.

func (*PortfolioDimensionMutation) SetKind

func (m *PortfolioDimensionMutation) SetKind(s string)

SetKind sets the "kind" field.

func (*PortfolioDimensionMutation) SetName

func (m *PortfolioDimensionMutation) SetName(s string)

SetName sets the "name" field.

func (*PortfolioDimensionMutation) SetOp

func (m *PortfolioDimensionMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*PortfolioDimensionMutation) SetVersion

func (m *PortfolioDimensionMutation) SetVersion(s string)

SetVersion sets the "version" field.

func (PortfolioDimensionMutation) Tx

func (m PortfolioDimensionMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*PortfolioDimensionMutation) Type

Type returns the node type of this mutation (PortfolioDimension).

func (*PortfolioDimensionMutation) Version

func (m *PortfolioDimensionMutation) Version() (r string, exists bool)

Version returns the value of the "version" field in the mutation.

func (*PortfolioDimensionMutation) Where

Where appends a list predicates to the PortfolioDimensionMutation builder.

func (*PortfolioDimensionMutation) WhereP

func (m *PortfolioDimensionMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the PortfolioDimensionMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

type PortfolioDimensionQuery

type PortfolioDimensionQuery struct {
	// contains filtered or unexported fields
}

PortfolioDimensionQuery is the builder for querying PortfolioDimension entities.

func (*PortfolioDimensionQuery) Aggregate

Aggregate returns a PortfolioDimensionSelect configured with the given aggregations.

func (*PortfolioDimensionQuery) All

All executes the query and returns a list of PortfolioDimensions.

func (*PortfolioDimensionQuery) AllX

AllX is like All, but panics if an error occurs.

func (*PortfolioDimensionQuery) Clone

Clone returns a duplicate of the PortfolioDimensionQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*PortfolioDimensionQuery) Count

func (_q *PortfolioDimensionQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*PortfolioDimensionQuery) CountX

func (_q *PortfolioDimensionQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*PortfolioDimensionQuery) Exist

func (_q *PortfolioDimensionQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*PortfolioDimensionQuery) ExistX

func (_q *PortfolioDimensionQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*PortfolioDimensionQuery) First

First returns the first PortfolioDimension entity from the query. Returns a *NotFoundError when no PortfolioDimension was found.

func (*PortfolioDimensionQuery) FirstID

func (_q *PortfolioDimensionQuery) FirstID(ctx context.Context) (id string, err error)

FirstID returns the first PortfolioDimension ID from the query. Returns a *NotFoundError when no PortfolioDimension ID was found.

func (*PortfolioDimensionQuery) FirstIDX

func (_q *PortfolioDimensionQuery) FirstIDX(ctx context.Context) string

FirstIDX is like FirstID, but panics if an error occurs.

func (*PortfolioDimensionQuery) FirstX

FirstX is like First, but panics if an error occurs.

func (*PortfolioDimensionQuery) GroupBy

func (_q *PortfolioDimensionQuery) GroupBy(field string, fields ...string) *PortfolioDimensionGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	DimensionID string `json:"dimension_id,omitempty"`
	Count int `json:"count,omitempty"`
}

client.PortfolioDimension.Query().
	GroupBy(portfoliodimension.FieldDimensionID).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*PortfolioDimensionQuery) IDs

func (_q *PortfolioDimensionQuery) IDs(ctx context.Context) (ids []string, err error)

IDs executes the query and returns a list of PortfolioDimension IDs.

func (*PortfolioDimensionQuery) IDsX

IDsX is like IDs, but panics if an error occurs.

func (*PortfolioDimensionQuery) Limit

Limit the number of records to be returned by this query.

func (*PortfolioDimensionQuery) Offset

Offset to start from.

func (*PortfolioDimensionQuery) Only

Only returns a single PortfolioDimension entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one PortfolioDimension entity is found. Returns a *NotFoundError when no PortfolioDimension entities are found.

func (*PortfolioDimensionQuery) OnlyID

func (_q *PortfolioDimensionQuery) OnlyID(ctx context.Context) (id string, err error)

OnlyID is like Only, but returns the only PortfolioDimension ID in the query. Returns a *NotSingularError when more than one PortfolioDimension ID is found. Returns a *NotFoundError when no entities are found.

func (*PortfolioDimensionQuery) OnlyIDX

func (_q *PortfolioDimensionQuery) OnlyIDX(ctx context.Context) string

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*PortfolioDimensionQuery) OnlyX

OnlyX is like Only, but panics if an error occurs.

func (*PortfolioDimensionQuery) Order

Order specifies how the records should be ordered.

func (*PortfolioDimensionQuery) Select

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	DimensionID string `json:"dimension_id,omitempty"`
}

client.PortfolioDimension.Query().
	Select(portfoliodimension.FieldDimensionID).
	Scan(ctx, &v)

func (*PortfolioDimensionQuery) Unique

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*PortfolioDimensionQuery) Where

Where adds a new predicate for the PortfolioDimensionQuery builder.

type PortfolioDimensionSelect

type PortfolioDimensionSelect struct {
	*PortfolioDimensionQuery
	// contains filtered or unexported fields
}

PortfolioDimensionSelect is the builder for selecting fields of PortfolioDimension entities.

func (*PortfolioDimensionSelect) Aggregate

Aggregate adds the given aggregation functions to the selector query.

func (*PortfolioDimensionSelect) Bool

func (s *PortfolioDimensionSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*PortfolioDimensionSelect) BoolX

func (s *PortfolioDimensionSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*PortfolioDimensionSelect) Bools

func (s *PortfolioDimensionSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*PortfolioDimensionSelect) BoolsX

func (s *PortfolioDimensionSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*PortfolioDimensionSelect) Float64

func (s *PortfolioDimensionSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*PortfolioDimensionSelect) Float64X

func (s *PortfolioDimensionSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*PortfolioDimensionSelect) Float64s

func (s *PortfolioDimensionSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*PortfolioDimensionSelect) Float64sX

func (s *PortfolioDimensionSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*PortfolioDimensionSelect) Int

func (s *PortfolioDimensionSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*PortfolioDimensionSelect) IntX

func (s *PortfolioDimensionSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*PortfolioDimensionSelect) Ints

func (s *PortfolioDimensionSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*PortfolioDimensionSelect) IntsX

func (s *PortfolioDimensionSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*PortfolioDimensionSelect) Scan

Scan applies the selector query and scans the result into the given value.

func (*PortfolioDimensionSelect) ScanX

func (s *PortfolioDimensionSelect) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*PortfolioDimensionSelect) String

func (s *PortfolioDimensionSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*PortfolioDimensionSelect) StringX

func (s *PortfolioDimensionSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*PortfolioDimensionSelect) Strings

func (s *PortfolioDimensionSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*PortfolioDimensionSelect) StringsX

func (s *PortfolioDimensionSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type PortfolioDimensionUpdate

type PortfolioDimensionUpdate struct {
	// contains filtered or unexported fields
}

PortfolioDimensionUpdate is the builder for updating PortfolioDimension entities.

func (*PortfolioDimensionUpdate) Exec

Exec executes the query.

func (*PortfolioDimensionUpdate) ExecX

func (_u *PortfolioDimensionUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*PortfolioDimensionUpdate) Mutation

Mutation returns the PortfolioDimensionMutation object of the builder.

func (*PortfolioDimensionUpdate) Save

Save executes the query and returns the number of nodes affected by the update operation.

func (*PortfolioDimensionUpdate) SaveX

SaveX is like Save, but panics if an error occurs.

func (*PortfolioDimensionUpdate) SetBuiltIn

SetBuiltIn sets the "built_in" field.

func (*PortfolioDimensionUpdate) SetDimensionID

SetDimensionID sets the "dimension_id" field.

func (*PortfolioDimensionUpdate) SetKind

SetKind sets the "kind" field.

func (*PortfolioDimensionUpdate) SetName

SetName sets the "name" field.

func (*PortfolioDimensionUpdate) SetNillableBuiltIn

func (_u *PortfolioDimensionUpdate) SetNillableBuiltIn(v *bool) *PortfolioDimensionUpdate

SetNillableBuiltIn sets the "built_in" field if the given value is not nil.

func (*PortfolioDimensionUpdate) SetNillableDimensionID

func (_u *PortfolioDimensionUpdate) SetNillableDimensionID(v *string) *PortfolioDimensionUpdate

SetNillableDimensionID sets the "dimension_id" field if the given value is not nil.

func (*PortfolioDimensionUpdate) SetNillableKind

func (_u *PortfolioDimensionUpdate) SetNillableKind(v *string) *PortfolioDimensionUpdate

SetNillableKind sets the "kind" field if the given value is not nil.

func (*PortfolioDimensionUpdate) SetNillableName

func (_u *PortfolioDimensionUpdate) SetNillableName(v *string) *PortfolioDimensionUpdate

SetNillableName sets the "name" field if the given value is not nil.

func (*PortfolioDimensionUpdate) SetNillableVersion

func (_u *PortfolioDimensionUpdate) SetNillableVersion(v *string) *PortfolioDimensionUpdate

SetNillableVersion sets the "version" field if the given value is not nil.

func (*PortfolioDimensionUpdate) SetVersion

SetVersion sets the "version" field.

func (*PortfolioDimensionUpdate) Where

Where appends a list predicates to the PortfolioDimensionUpdate builder.

type PortfolioDimensionUpdateOne

type PortfolioDimensionUpdateOne struct {
	// contains filtered or unexported fields
}

PortfolioDimensionUpdateOne is the builder for updating a single PortfolioDimension entity.

func (*PortfolioDimensionUpdateOne) Exec

Exec executes the query on the entity.

func (*PortfolioDimensionUpdateOne) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*PortfolioDimensionUpdateOne) Mutation

Mutation returns the PortfolioDimensionMutation object of the builder.

func (*PortfolioDimensionUpdateOne) Save

Save executes the query and returns the updated PortfolioDimension entity.

func (*PortfolioDimensionUpdateOne) SaveX

SaveX is like Save, but panics if an error occurs.

func (*PortfolioDimensionUpdateOne) Select

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*PortfolioDimensionUpdateOne) SetBuiltIn

SetBuiltIn sets the "built_in" field.

func (*PortfolioDimensionUpdateOne) SetDimensionID

SetDimensionID sets the "dimension_id" field.

func (*PortfolioDimensionUpdateOne) SetKind

SetKind sets the "kind" field.

func (*PortfolioDimensionUpdateOne) SetName

SetName sets the "name" field.

func (*PortfolioDimensionUpdateOne) SetNillableBuiltIn

func (_u *PortfolioDimensionUpdateOne) SetNillableBuiltIn(v *bool) *PortfolioDimensionUpdateOne

SetNillableBuiltIn sets the "built_in" field if the given value is not nil.

func (*PortfolioDimensionUpdateOne) SetNillableDimensionID

func (_u *PortfolioDimensionUpdateOne) SetNillableDimensionID(v *string) *PortfolioDimensionUpdateOne

SetNillableDimensionID sets the "dimension_id" field if the given value is not nil.

func (*PortfolioDimensionUpdateOne) SetNillableKind

SetNillableKind sets the "kind" field if the given value is not nil.

func (*PortfolioDimensionUpdateOne) SetNillableName

SetNillableName sets the "name" field if the given value is not nil.

func (*PortfolioDimensionUpdateOne) SetNillableVersion

SetNillableVersion sets the "version" field if the given value is not nil.

func (*PortfolioDimensionUpdateOne) SetVersion

SetVersion sets the "version" field.

func (*PortfolioDimensionUpdateOne) Where

Where appends a list predicates to the PortfolioDimensionUpdate builder.

type PortfolioDimensionUpsert

type PortfolioDimensionUpsert struct {
	*sql.UpdateSet
}

PortfolioDimensionUpsert is the "OnConflict" setter.

func (*PortfolioDimensionUpsert) SetBuiltIn

SetBuiltIn sets the "built_in" field.

func (*PortfolioDimensionUpsert) SetDimensionID

SetDimensionID sets the "dimension_id" field.

func (*PortfolioDimensionUpsert) SetKind

SetKind sets the "kind" field.

func (*PortfolioDimensionUpsert) SetName

SetName sets the "name" field.

func (*PortfolioDimensionUpsert) SetVersion

SetVersion sets the "version" field.

func (*PortfolioDimensionUpsert) UpdateBuiltIn

UpdateBuiltIn sets the "built_in" field to the value that was provided on create.

func (*PortfolioDimensionUpsert) UpdateDimensionID

func (u *PortfolioDimensionUpsert) UpdateDimensionID() *PortfolioDimensionUpsert

UpdateDimensionID sets the "dimension_id" field to the value that was provided on create.

func (*PortfolioDimensionUpsert) UpdateKind

UpdateKind sets the "kind" field to the value that was provided on create.

func (*PortfolioDimensionUpsert) UpdateName

UpdateName sets the "name" field to the value that was provided on create.

func (*PortfolioDimensionUpsert) UpdateVersion

UpdateVersion sets the "version" field to the value that was provided on create.

type PortfolioDimensionUpsertBulk

type PortfolioDimensionUpsertBulk struct {
	// contains filtered or unexported fields
}

PortfolioDimensionUpsertBulk is the builder for "upsert"-ing a bulk of PortfolioDimension nodes.

func (*PortfolioDimensionUpsertBulk) DoNothing

DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.

func (*PortfolioDimensionUpsertBulk) Exec

Exec executes the query.

func (*PortfolioDimensionUpsertBulk) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*PortfolioDimensionUpsertBulk) Ignore

Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:

client.PortfolioDimension.Create().
	OnConflict(sql.ResolveWithIgnore()).
	Exec(ctx)

func (*PortfolioDimensionUpsertBulk) SetBuiltIn

SetBuiltIn sets the "built_in" field.

func (*PortfolioDimensionUpsertBulk) SetDimensionID

SetDimensionID sets the "dimension_id" field.

func (*PortfolioDimensionUpsertBulk) SetKind

SetKind sets the "kind" field.

func (*PortfolioDimensionUpsertBulk) SetName

SetName sets the "name" field.

func (*PortfolioDimensionUpsertBulk) SetVersion

SetVersion sets the "version" field.

func (*PortfolioDimensionUpsertBulk) Update

Update allows overriding fields `UPDATE` values. See the PortfolioDimensionCreateBulk.OnConflict documentation for more info.

func (*PortfolioDimensionUpsertBulk) UpdateBuiltIn

UpdateBuiltIn sets the "built_in" field to the value that was provided on create.

func (*PortfolioDimensionUpsertBulk) UpdateDimensionID

UpdateDimensionID sets the "dimension_id" field to the value that was provided on create.

func (*PortfolioDimensionUpsertBulk) UpdateKind

UpdateKind sets the "kind" field to the value that was provided on create.

func (*PortfolioDimensionUpsertBulk) UpdateName

UpdateName sets the "name" field to the value that was provided on create.

func (*PortfolioDimensionUpsertBulk) UpdateNewValues

UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:

client.PortfolioDimension.Create().
	OnConflict(
		sql.ResolveWithNewValues(),
		sql.ResolveWith(func(u *sql.UpdateSet) {
			u.SetIgnore(portfoliodimension.FieldID)
		}),
	).
	Exec(ctx)

func (*PortfolioDimensionUpsertBulk) UpdateVersion

UpdateVersion sets the "version" field to the value that was provided on create.

type PortfolioDimensionUpsertOne

type PortfolioDimensionUpsertOne struct {
	// contains filtered or unexported fields
}

PortfolioDimensionUpsertOne is the builder for "upsert"-ing

one PortfolioDimension node.

func (*PortfolioDimensionUpsertOne) DoNothing

DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.

func (*PortfolioDimensionUpsertOne) Exec

Exec executes the query.

func (*PortfolioDimensionUpsertOne) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*PortfolioDimensionUpsertOne) ID

Exec executes the UPSERT query and returns the inserted/updated ID.

func (*PortfolioDimensionUpsertOne) IDX

IDX is like ID, but panics if an error occurs.

func (*PortfolioDimensionUpsertOne) Ignore

Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:

client.PortfolioDimension.Create().
    OnConflict(sql.ResolveWithIgnore()).
    Exec(ctx)

func (*PortfolioDimensionUpsertOne) SetBuiltIn

SetBuiltIn sets the "built_in" field.

func (*PortfolioDimensionUpsertOne) SetDimensionID

SetDimensionID sets the "dimension_id" field.

func (*PortfolioDimensionUpsertOne) SetKind

SetKind sets the "kind" field.

func (*PortfolioDimensionUpsertOne) SetName

SetName sets the "name" field.

func (*PortfolioDimensionUpsertOne) SetVersion

SetVersion sets the "version" field.

func (*PortfolioDimensionUpsertOne) Update

Update allows overriding fields `UPDATE` values. See the PortfolioDimensionCreate.OnConflict documentation for more info.

func (*PortfolioDimensionUpsertOne) UpdateBuiltIn

UpdateBuiltIn sets the "built_in" field to the value that was provided on create.

func (*PortfolioDimensionUpsertOne) UpdateDimensionID

UpdateDimensionID sets the "dimension_id" field to the value that was provided on create.

func (*PortfolioDimensionUpsertOne) UpdateKind

UpdateKind sets the "kind" field to the value that was provided on create.

func (*PortfolioDimensionUpsertOne) UpdateName

UpdateName sets the "name" field to the value that was provided on create.

func (*PortfolioDimensionUpsertOne) UpdateNewValues

UpdateNewValues updates the mutable fields using the new values that were set on create except the ID field. Using this option is equivalent to using:

client.PortfolioDimension.Create().
	OnConflict(
		sql.ResolveWithNewValues(),
		sql.ResolveWith(func(u *sql.UpdateSet) {
			u.SetIgnore(portfoliodimension.FieldID)
		}),
	).
	Exec(ctx)

func (*PortfolioDimensionUpsertOne) UpdateVersion

UpdateVersion sets the "version" field to the value that was provided on create.

type PortfolioDimensions

type PortfolioDimensions []*PortfolioDimension

PortfolioDimensions is a parsable slice of PortfolioDimension.

type ProfileAssignment

type ProfileAssignment struct {

	// ID of the ent.
	ID string `json:"id,omitempty"`
	// ProfileID holds the value of the "profile_id" field.
	ProfileID string `json:"profile_id,omitempty"`
	// Secondary holds the value of the "secondary" field.
	Secondary []string `json:"secondary,omitempty"`
	// Rationale holds the value of the "rationale" field.
	Rationale string `json:"rationale,omitempty"`
	// ProposedBy holds the value of the "proposed_by" field.
	ProposedBy string `json:"proposed_by,omitempty"`
	// Status holds the value of the "status" field.
	Status string `json:"status,omitempty"`
	// ConfirmedBy holds the value of the "confirmed_by" field.
	ConfirmedBy string `json:"confirmed_by,omitempty"`
	// ConfirmedAt holds the value of the "confirmed_at" field.
	ConfirmedAt *time.Time `json:"confirmed_at,omitempty"`
	// EvidenceIds holds the value of the "evidence_ids" field.
	EvidenceIds []string `json:"evidence_ids,omitempty"`
	// CreatedAt holds the value of the "created_at" field.
	CreatedAt time.Time `json:"created_at,omitempty"`
	// UpdatedAt holds the value of the "updated_at" field.
	UpdatedAt time.Time `json:"updated_at,omitempty"`
	// contains filtered or unexported fields
}

ProfileAssignment is the model entity for the ProfileAssignment schema.

func (*ProfileAssignment) String

func (_m *ProfileAssignment) String() string

String implements the fmt.Stringer.

func (*ProfileAssignment) Unwrap

func (_m *ProfileAssignment) Unwrap() *ProfileAssignment

Unwrap unwraps the ProfileAssignment entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*ProfileAssignment) Update

Update returns a builder for updating this ProfileAssignment. Note that you need to call ProfileAssignment.Unwrap() before calling this method if this ProfileAssignment was returned from a transaction, and the transaction was committed or rolled back.

func (*ProfileAssignment) Value

func (_m *ProfileAssignment) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the ProfileAssignment. This includes values selected through modifiers, order, etc.

type ProfileAssignmentClient

type ProfileAssignmentClient struct {
	// contains filtered or unexported fields
}

ProfileAssignmentClient is a client for the ProfileAssignment schema.

func NewProfileAssignmentClient

func NewProfileAssignmentClient(c config) *ProfileAssignmentClient

NewProfileAssignmentClient returns a client for the ProfileAssignment from the given config.

func (*ProfileAssignmentClient) Create

Create returns a builder for creating a ProfileAssignment entity.

func (*ProfileAssignmentClient) CreateBulk

CreateBulk returns a builder for creating a bulk of ProfileAssignment entities.

func (*ProfileAssignmentClient) Delete

Delete returns a delete builder for ProfileAssignment.

func (*ProfileAssignmentClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*ProfileAssignmentClient) DeleteOneID

DeleteOneID returns a builder for deleting the given entity by its id.

func (*ProfileAssignmentClient) Get

Get returns a ProfileAssignment entity by its id.

func (*ProfileAssignmentClient) GetX

GetX is like Get, but panics if an error occurs.

func (*ProfileAssignmentClient) Hooks

func (c *ProfileAssignmentClient) Hooks() []Hook

Hooks returns the client hooks.

func (*ProfileAssignmentClient) Intercept

func (c *ProfileAssignmentClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `profileassignment.Intercept(f(g(h())))`.

func (*ProfileAssignmentClient) Interceptors

func (c *ProfileAssignmentClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*ProfileAssignmentClient) MapCreateBulk

func (c *ProfileAssignmentClient) MapCreateBulk(slice any, setFunc func(*ProfileAssignmentCreate, int)) *ProfileAssignmentCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*ProfileAssignmentClient) Query

Query returns a query builder for ProfileAssignment.

func (*ProfileAssignmentClient) Update

Update returns an update builder for ProfileAssignment.

func (*ProfileAssignmentClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*ProfileAssignmentClient) UpdateOneID

UpdateOneID returns an update builder for the given id.

func (*ProfileAssignmentClient) Use

func (c *ProfileAssignmentClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `profileassignment.Hooks(f(g(h())))`.

type ProfileAssignmentCreate

type ProfileAssignmentCreate struct {
	// contains filtered or unexported fields
}

ProfileAssignmentCreate is the builder for creating a ProfileAssignment entity.

func (*ProfileAssignmentCreate) Exec

Exec executes the query.

func (*ProfileAssignmentCreate) ExecX

func (_c *ProfileAssignmentCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ProfileAssignmentCreate) Mutation

Mutation returns the ProfileAssignmentMutation object of the builder.

func (*ProfileAssignmentCreate) OnConflict

OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:

client.ProfileAssignment.Create().
	SetProfileID(v).
	OnConflict(
		// Update the row with the new values
		// the was proposed for insertion.
		sql.ResolveWithNewValues(),
	).
	// Override some of the fields with custom
	// update values.
	Update(func(u *ent.ProfileAssignmentUpsert) {
		SetProfileID(v+v).
	}).
	Exec(ctx)

func (*ProfileAssignmentCreate) OnConflictColumns

func (_c *ProfileAssignmentCreate) OnConflictColumns(columns ...string) *ProfileAssignmentUpsertOne

OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:

client.ProfileAssignment.Create().
	OnConflict(sql.ConflictColumns(columns...)).
	Exec(ctx)

func (*ProfileAssignmentCreate) Save

Save creates the ProfileAssignment in the database.

func (*ProfileAssignmentCreate) SaveX

SaveX calls Save and panics if Save returns an error.

func (*ProfileAssignmentCreate) SetConfirmedAt

SetConfirmedAt sets the "confirmed_at" field.

func (*ProfileAssignmentCreate) SetConfirmedBy

SetConfirmedBy sets the "confirmed_by" field.

func (*ProfileAssignmentCreate) SetCreatedAt

SetCreatedAt sets the "created_at" field.

func (*ProfileAssignmentCreate) SetEvidenceIds

func (_c *ProfileAssignmentCreate) SetEvidenceIds(v []string) *ProfileAssignmentCreate

SetEvidenceIds sets the "evidence_ids" field.

func (*ProfileAssignmentCreate) SetID

SetID sets the "id" field.

func (*ProfileAssignmentCreate) SetNillableConfirmedAt

func (_c *ProfileAssignmentCreate) SetNillableConfirmedAt(v *time.Time) *ProfileAssignmentCreate

SetNillableConfirmedAt sets the "confirmed_at" field if the given value is not nil.

func (*ProfileAssignmentCreate) SetNillableConfirmedBy

func (_c *ProfileAssignmentCreate) SetNillableConfirmedBy(v *string) *ProfileAssignmentCreate

SetNillableConfirmedBy sets the "confirmed_by" field if the given value is not nil.

func (*ProfileAssignmentCreate) SetNillableCreatedAt

func (_c *ProfileAssignmentCreate) SetNillableCreatedAt(v *time.Time) *ProfileAssignmentCreate

SetNillableCreatedAt sets the "created_at" field if the given value is not nil.

func (*ProfileAssignmentCreate) SetNillableUpdatedAt

func (_c *ProfileAssignmentCreate) SetNillableUpdatedAt(v *time.Time) *ProfileAssignmentCreate

SetNillableUpdatedAt sets the "updated_at" field if the given value is not nil.

func (*ProfileAssignmentCreate) SetProfileID

SetProfileID sets the "profile_id" field.

func (*ProfileAssignmentCreate) SetProposedBy

SetProposedBy sets the "proposed_by" field.

func (*ProfileAssignmentCreate) SetRationale

SetRationale sets the "rationale" field.

func (*ProfileAssignmentCreate) SetSecondary

SetSecondary sets the "secondary" field.

func (*ProfileAssignmentCreate) SetStatus

SetStatus sets the "status" field.

func (*ProfileAssignmentCreate) SetUpdatedAt

SetUpdatedAt sets the "updated_at" field.

type ProfileAssignmentCreateBulk

type ProfileAssignmentCreateBulk struct {
	// contains filtered or unexported fields
}

ProfileAssignmentCreateBulk is the builder for creating many ProfileAssignment entities in bulk.

func (*ProfileAssignmentCreateBulk) Exec

Exec executes the query.

func (*ProfileAssignmentCreateBulk) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*ProfileAssignmentCreateBulk) OnConflict

OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:

client.ProfileAssignment.CreateBulk(builders...).
	OnConflict(
		// Update the row with the new values
		// the was proposed for insertion.
		sql.ResolveWithNewValues(),
	).
	// Override some of the fields with custom
	// update values.
	Update(func(u *ent.ProfileAssignmentUpsert) {
		SetProfileID(v+v).
	}).
	Exec(ctx)

func (*ProfileAssignmentCreateBulk) OnConflictColumns

func (_c *ProfileAssignmentCreateBulk) OnConflictColumns(columns ...string) *ProfileAssignmentUpsertBulk

OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:

client.ProfileAssignment.Create().
	OnConflict(sql.ConflictColumns(columns...)).
	Exec(ctx)

func (*ProfileAssignmentCreateBulk) Save

Save creates the ProfileAssignment entities in the database.

func (*ProfileAssignmentCreateBulk) SaveX

SaveX is like Save, but panics if an error occurs.

type ProfileAssignmentDelete

type ProfileAssignmentDelete struct {
	// contains filtered or unexported fields
}

ProfileAssignmentDelete is the builder for deleting a ProfileAssignment entity.

func (*ProfileAssignmentDelete) Exec

func (_d *ProfileAssignmentDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*ProfileAssignmentDelete) ExecX

func (_d *ProfileAssignmentDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*ProfileAssignmentDelete) Where

Where appends a list predicates to the ProfileAssignmentDelete builder.

type ProfileAssignmentDeleteOne

type ProfileAssignmentDeleteOne struct {
	// contains filtered or unexported fields
}

ProfileAssignmentDeleteOne is the builder for deleting a single ProfileAssignment entity.

func (*ProfileAssignmentDeleteOne) Exec

Exec executes the deletion query.

func (*ProfileAssignmentDeleteOne) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*ProfileAssignmentDeleteOne) Where

Where appends a list predicates to the ProfileAssignmentDelete builder.

type ProfileAssignmentGroupBy

type ProfileAssignmentGroupBy struct {
	// contains filtered or unexported fields
}

ProfileAssignmentGroupBy is the group-by builder for ProfileAssignment entities.

func (*ProfileAssignmentGroupBy) Aggregate

Aggregate adds the given aggregation functions to the group-by query.

func (*ProfileAssignmentGroupBy) Bool

func (s *ProfileAssignmentGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*ProfileAssignmentGroupBy) BoolX

func (s *ProfileAssignmentGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*ProfileAssignmentGroupBy) Bools

func (s *ProfileAssignmentGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*ProfileAssignmentGroupBy) BoolsX

func (s *ProfileAssignmentGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*ProfileAssignmentGroupBy) Float64

func (s *ProfileAssignmentGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*ProfileAssignmentGroupBy) Float64X

func (s *ProfileAssignmentGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*ProfileAssignmentGroupBy) Float64s

func (s *ProfileAssignmentGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*ProfileAssignmentGroupBy) Float64sX

func (s *ProfileAssignmentGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*ProfileAssignmentGroupBy) Int

func (s *ProfileAssignmentGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*ProfileAssignmentGroupBy) IntX

func (s *ProfileAssignmentGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*ProfileAssignmentGroupBy) Ints

func (s *ProfileAssignmentGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*ProfileAssignmentGroupBy) IntsX

func (s *ProfileAssignmentGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*ProfileAssignmentGroupBy) Scan

Scan applies the selector query and scans the result into the given value.

func (*ProfileAssignmentGroupBy) ScanX

func (s *ProfileAssignmentGroupBy) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*ProfileAssignmentGroupBy) String

func (s *ProfileAssignmentGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*ProfileAssignmentGroupBy) StringX

func (s *ProfileAssignmentGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*ProfileAssignmentGroupBy) Strings

func (s *ProfileAssignmentGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*ProfileAssignmentGroupBy) StringsX

func (s *ProfileAssignmentGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type ProfileAssignmentMutation

type ProfileAssignmentMutation struct {
	// contains filtered or unexported fields
}

ProfileAssignmentMutation represents an operation that mutates the ProfileAssignment nodes in the graph.

func (*ProfileAssignmentMutation) AddField

func (m *ProfileAssignmentMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*ProfileAssignmentMutation) AddedEdges

func (m *ProfileAssignmentMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*ProfileAssignmentMutation) AddedField

func (m *ProfileAssignmentMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*ProfileAssignmentMutation) AddedFields

func (m *ProfileAssignmentMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*ProfileAssignmentMutation) AddedIDs

func (m *ProfileAssignmentMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*ProfileAssignmentMutation) AppendEvidenceIds

func (m *ProfileAssignmentMutation) AppendEvidenceIds(s []string)

AppendEvidenceIds adds s to the "evidence_ids" field.

func (*ProfileAssignmentMutation) AppendSecondary

func (m *ProfileAssignmentMutation) AppendSecondary(s []string)

AppendSecondary adds s to the "secondary" field.

func (*ProfileAssignmentMutation) AppendedEvidenceIds

func (m *ProfileAssignmentMutation) AppendedEvidenceIds() ([]string, bool)

AppendedEvidenceIds returns the list of values that were appended to the "evidence_ids" field in this mutation.

func (*ProfileAssignmentMutation) AppendedSecondary

func (m *ProfileAssignmentMutation) AppendedSecondary() ([]string, bool)

AppendedSecondary returns the list of values that were appended to the "secondary" field in this mutation.

func (*ProfileAssignmentMutation) ClearConfirmedAt

func (m *ProfileAssignmentMutation) ClearConfirmedAt()

ClearConfirmedAt clears the value of the "confirmed_at" field.

func (*ProfileAssignmentMutation) ClearConfirmedBy

func (m *ProfileAssignmentMutation) ClearConfirmedBy()

ClearConfirmedBy clears the value of the "confirmed_by" field.

func (*ProfileAssignmentMutation) ClearEdge

func (m *ProfileAssignmentMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*ProfileAssignmentMutation) ClearEvidenceIds

func (m *ProfileAssignmentMutation) ClearEvidenceIds()

ClearEvidenceIds clears the value of the "evidence_ids" field.

func (*ProfileAssignmentMutation) ClearField

func (m *ProfileAssignmentMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*ProfileAssignmentMutation) ClearSecondary

func (m *ProfileAssignmentMutation) ClearSecondary()

ClearSecondary clears the value of the "secondary" field.

func (*ProfileAssignmentMutation) ClearedEdges

func (m *ProfileAssignmentMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*ProfileAssignmentMutation) ClearedFields

func (m *ProfileAssignmentMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (ProfileAssignmentMutation) Client

func (m ProfileAssignmentMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*ProfileAssignmentMutation) ConfirmedAt

func (m *ProfileAssignmentMutation) ConfirmedAt() (r time.Time, exists bool)

ConfirmedAt returns the value of the "confirmed_at" field in the mutation.

func (*ProfileAssignmentMutation) ConfirmedAtCleared

func (m *ProfileAssignmentMutation) ConfirmedAtCleared() bool

ConfirmedAtCleared returns if the "confirmed_at" field was cleared in this mutation.

func (*ProfileAssignmentMutation) ConfirmedBy

func (m *ProfileAssignmentMutation) ConfirmedBy() (r string, exists bool)

ConfirmedBy returns the value of the "confirmed_by" field in the mutation.

func (*ProfileAssignmentMutation) ConfirmedByCleared

func (m *ProfileAssignmentMutation) ConfirmedByCleared() bool

ConfirmedByCleared returns if the "confirmed_by" field was cleared in this mutation.

func (*ProfileAssignmentMutation) CreatedAt

func (m *ProfileAssignmentMutation) CreatedAt() (r time.Time, exists bool)

CreatedAt returns the value of the "created_at" field in the mutation.

func (*ProfileAssignmentMutation) EdgeCleared

func (m *ProfileAssignmentMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*ProfileAssignmentMutation) EvidenceIds

func (m *ProfileAssignmentMutation) EvidenceIds() (r []string, exists bool)

EvidenceIds returns the value of the "evidence_ids" field in the mutation.

func (*ProfileAssignmentMutation) EvidenceIdsCleared

func (m *ProfileAssignmentMutation) EvidenceIdsCleared() bool

EvidenceIdsCleared returns if the "evidence_ids" field was cleared in this mutation.

func (*ProfileAssignmentMutation) Field

func (m *ProfileAssignmentMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*ProfileAssignmentMutation) FieldCleared

func (m *ProfileAssignmentMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*ProfileAssignmentMutation) Fields

func (m *ProfileAssignmentMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*ProfileAssignmentMutation) ID

func (m *ProfileAssignmentMutation) ID() (id string, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*ProfileAssignmentMutation) IDs

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*ProfileAssignmentMutation) OldConfirmedAt

func (m *ProfileAssignmentMutation) OldConfirmedAt(ctx context.Context) (v *time.Time, err error)

OldConfirmedAt returns the old "confirmed_at" field's value of the ProfileAssignment entity. If the ProfileAssignment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ProfileAssignmentMutation) OldConfirmedBy

func (m *ProfileAssignmentMutation) OldConfirmedBy(ctx context.Context) (v string, err error)

OldConfirmedBy returns the old "confirmed_by" field's value of the ProfileAssignment entity. If the ProfileAssignment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ProfileAssignmentMutation) OldCreatedAt

func (m *ProfileAssignmentMutation) OldCreatedAt(ctx context.Context) (v time.Time, err error)

OldCreatedAt returns the old "created_at" field's value of the ProfileAssignment entity. If the ProfileAssignment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ProfileAssignmentMutation) OldEvidenceIds

func (m *ProfileAssignmentMutation) OldEvidenceIds(ctx context.Context) (v []string, err error)

OldEvidenceIds returns the old "evidence_ids" field's value of the ProfileAssignment entity. If the ProfileAssignment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ProfileAssignmentMutation) OldField

func (m *ProfileAssignmentMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*ProfileAssignmentMutation) OldProfileID

func (m *ProfileAssignmentMutation) OldProfileID(ctx context.Context) (v string, err error)

OldProfileID returns the old "profile_id" field's value of the ProfileAssignment entity. If the ProfileAssignment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ProfileAssignmentMutation) OldProposedBy

func (m *ProfileAssignmentMutation) OldProposedBy(ctx context.Context) (v string, err error)

OldProposedBy returns the old "proposed_by" field's value of the ProfileAssignment entity. If the ProfileAssignment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ProfileAssignmentMutation) OldRationale

func (m *ProfileAssignmentMutation) OldRationale(ctx context.Context) (v string, err error)

OldRationale returns the old "rationale" field's value of the ProfileAssignment entity. If the ProfileAssignment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ProfileAssignmentMutation) OldSecondary

func (m *ProfileAssignmentMutation) OldSecondary(ctx context.Context) (v []string, err error)

OldSecondary returns the old "secondary" field's value of the ProfileAssignment entity. If the ProfileAssignment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ProfileAssignmentMutation) OldStatus

func (m *ProfileAssignmentMutation) OldStatus(ctx context.Context) (v string, err error)

OldStatus returns the old "status" field's value of the ProfileAssignment entity. If the ProfileAssignment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ProfileAssignmentMutation) OldUpdatedAt

func (m *ProfileAssignmentMutation) OldUpdatedAt(ctx context.Context) (v time.Time, err error)

OldUpdatedAt returns the old "updated_at" field's value of the ProfileAssignment entity. If the ProfileAssignment object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ProfileAssignmentMutation) Op

func (m *ProfileAssignmentMutation) Op() Op

Op returns the operation name.

func (*ProfileAssignmentMutation) ProfileID

func (m *ProfileAssignmentMutation) ProfileID() (r string, exists bool)

ProfileID returns the value of the "profile_id" field in the mutation.

func (*ProfileAssignmentMutation) ProposedBy

func (m *ProfileAssignmentMutation) ProposedBy() (r string, exists bool)

ProposedBy returns the value of the "proposed_by" field in the mutation.

func (*ProfileAssignmentMutation) Rationale

func (m *ProfileAssignmentMutation) Rationale() (r string, exists bool)

Rationale returns the value of the "rationale" field in the mutation.

func (*ProfileAssignmentMutation) RemovedEdges

func (m *ProfileAssignmentMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*ProfileAssignmentMutation) RemovedIDs

func (m *ProfileAssignmentMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*ProfileAssignmentMutation) ResetConfirmedAt

func (m *ProfileAssignmentMutation) ResetConfirmedAt()

ResetConfirmedAt resets all changes to the "confirmed_at" field.

func (*ProfileAssignmentMutation) ResetConfirmedBy

func (m *ProfileAssignmentMutation) ResetConfirmedBy()

ResetConfirmedBy resets all changes to the "confirmed_by" field.

func (*ProfileAssignmentMutation) ResetCreatedAt

func (m *ProfileAssignmentMutation) ResetCreatedAt()

ResetCreatedAt resets all changes to the "created_at" field.

func (*ProfileAssignmentMutation) ResetEdge

func (m *ProfileAssignmentMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*ProfileAssignmentMutation) ResetEvidenceIds

func (m *ProfileAssignmentMutation) ResetEvidenceIds()

ResetEvidenceIds resets all changes to the "evidence_ids" field.

func (*ProfileAssignmentMutation) ResetField

func (m *ProfileAssignmentMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*ProfileAssignmentMutation) ResetProfileID

func (m *ProfileAssignmentMutation) ResetProfileID()

ResetProfileID resets all changes to the "profile_id" field.

func (*ProfileAssignmentMutation) ResetProposedBy

func (m *ProfileAssignmentMutation) ResetProposedBy()

ResetProposedBy resets all changes to the "proposed_by" field.

func (*ProfileAssignmentMutation) ResetRationale

func (m *ProfileAssignmentMutation) ResetRationale()

ResetRationale resets all changes to the "rationale" field.

func (*ProfileAssignmentMutation) ResetSecondary

func (m *ProfileAssignmentMutation) ResetSecondary()

ResetSecondary resets all changes to the "secondary" field.

func (*ProfileAssignmentMutation) ResetStatus

func (m *ProfileAssignmentMutation) ResetStatus()

ResetStatus resets all changes to the "status" field.

func (*ProfileAssignmentMutation) ResetUpdatedAt

func (m *ProfileAssignmentMutation) ResetUpdatedAt()

ResetUpdatedAt resets all changes to the "updated_at" field.

func (*ProfileAssignmentMutation) Secondary

func (m *ProfileAssignmentMutation) Secondary() (r []string, exists bool)

Secondary returns the value of the "secondary" field in the mutation.

func (*ProfileAssignmentMutation) SecondaryCleared

func (m *ProfileAssignmentMutation) SecondaryCleared() bool

SecondaryCleared returns if the "secondary" field was cleared in this mutation.

func (*ProfileAssignmentMutation) SetConfirmedAt

func (m *ProfileAssignmentMutation) SetConfirmedAt(t time.Time)

SetConfirmedAt sets the "confirmed_at" field.

func (*ProfileAssignmentMutation) SetConfirmedBy

func (m *ProfileAssignmentMutation) SetConfirmedBy(s string)

SetConfirmedBy sets the "confirmed_by" field.

func (*ProfileAssignmentMutation) SetCreatedAt

func (m *ProfileAssignmentMutation) SetCreatedAt(t time.Time)

SetCreatedAt sets the "created_at" field.

func (*ProfileAssignmentMutation) SetEvidenceIds

func (m *ProfileAssignmentMutation) SetEvidenceIds(s []string)

SetEvidenceIds sets the "evidence_ids" field.

func (*ProfileAssignmentMutation) SetField

func (m *ProfileAssignmentMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*ProfileAssignmentMutation) SetID

func (m *ProfileAssignmentMutation) SetID(id string)

SetID sets the value of the id field. Note that this operation is only accepted on creation of ProfileAssignment entities.

func (*ProfileAssignmentMutation) SetOp

func (m *ProfileAssignmentMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*ProfileAssignmentMutation) SetProfileID

func (m *ProfileAssignmentMutation) SetProfileID(s string)

SetProfileID sets the "profile_id" field.

func (*ProfileAssignmentMutation) SetProposedBy

func (m *ProfileAssignmentMutation) SetProposedBy(s string)

SetProposedBy sets the "proposed_by" field.

func (*ProfileAssignmentMutation) SetRationale

func (m *ProfileAssignmentMutation) SetRationale(s string)

SetRationale sets the "rationale" field.

func (*ProfileAssignmentMutation) SetSecondary

func (m *ProfileAssignmentMutation) SetSecondary(s []string)

SetSecondary sets the "secondary" field.

func (*ProfileAssignmentMutation) SetStatus

func (m *ProfileAssignmentMutation) SetStatus(s string)

SetStatus sets the "status" field.

func (*ProfileAssignmentMutation) SetUpdatedAt

func (m *ProfileAssignmentMutation) SetUpdatedAt(t time.Time)

SetUpdatedAt sets the "updated_at" field.

func (*ProfileAssignmentMutation) Status

func (m *ProfileAssignmentMutation) Status() (r string, exists bool)

Status returns the value of the "status" field in the mutation.

func (ProfileAssignmentMutation) Tx

func (m ProfileAssignmentMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*ProfileAssignmentMutation) Type

Type returns the node type of this mutation (ProfileAssignment).

func (*ProfileAssignmentMutation) UpdatedAt

func (m *ProfileAssignmentMutation) UpdatedAt() (r time.Time, exists bool)

UpdatedAt returns the value of the "updated_at" field in the mutation.

func (*ProfileAssignmentMutation) Where

Where appends a list predicates to the ProfileAssignmentMutation builder.

func (*ProfileAssignmentMutation) WhereP

func (m *ProfileAssignmentMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the ProfileAssignmentMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

type ProfileAssignmentQuery

type ProfileAssignmentQuery struct {
	// contains filtered or unexported fields
}

ProfileAssignmentQuery is the builder for querying ProfileAssignment entities.

func (*ProfileAssignmentQuery) Aggregate

Aggregate returns a ProfileAssignmentSelect configured with the given aggregations.

func (*ProfileAssignmentQuery) All

All executes the query and returns a list of ProfileAssignments.

func (*ProfileAssignmentQuery) AllX

AllX is like All, but panics if an error occurs.

func (*ProfileAssignmentQuery) Clone

Clone returns a duplicate of the ProfileAssignmentQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*ProfileAssignmentQuery) Count

func (_q *ProfileAssignmentQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*ProfileAssignmentQuery) CountX

func (_q *ProfileAssignmentQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*ProfileAssignmentQuery) Exist

func (_q *ProfileAssignmentQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*ProfileAssignmentQuery) ExistX

func (_q *ProfileAssignmentQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*ProfileAssignmentQuery) First

First returns the first ProfileAssignment entity from the query. Returns a *NotFoundError when no ProfileAssignment was found.

func (*ProfileAssignmentQuery) FirstID

func (_q *ProfileAssignmentQuery) FirstID(ctx context.Context) (id string, err error)

FirstID returns the first ProfileAssignment ID from the query. Returns a *NotFoundError when no ProfileAssignment ID was found.

func (*ProfileAssignmentQuery) FirstIDX

func (_q *ProfileAssignmentQuery) FirstIDX(ctx context.Context) string

FirstIDX is like FirstID, but panics if an error occurs.

func (*ProfileAssignmentQuery) FirstX

FirstX is like First, but panics if an error occurs.

func (*ProfileAssignmentQuery) GroupBy

func (_q *ProfileAssignmentQuery) GroupBy(field string, fields ...string) *ProfileAssignmentGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	ProfileID string `json:"profile_id,omitempty"`
	Count int `json:"count,omitempty"`
}

client.ProfileAssignment.Query().
	GroupBy(profileassignment.FieldProfileID).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*ProfileAssignmentQuery) IDs

func (_q *ProfileAssignmentQuery) IDs(ctx context.Context) (ids []string, err error)

IDs executes the query and returns a list of ProfileAssignment IDs.

func (*ProfileAssignmentQuery) IDsX

func (_q *ProfileAssignmentQuery) IDsX(ctx context.Context) []string

IDsX is like IDs, but panics if an error occurs.

func (*ProfileAssignmentQuery) Limit

Limit the number of records to be returned by this query.

func (*ProfileAssignmentQuery) Offset

Offset to start from.

func (*ProfileAssignmentQuery) Only

Only returns a single ProfileAssignment entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one ProfileAssignment entity is found. Returns a *NotFoundError when no ProfileAssignment entities are found.

func (*ProfileAssignmentQuery) OnlyID

func (_q *ProfileAssignmentQuery) OnlyID(ctx context.Context) (id string, err error)

OnlyID is like Only, but returns the only ProfileAssignment ID in the query. Returns a *NotSingularError when more than one ProfileAssignment ID is found. Returns a *NotFoundError when no entities are found.

func (*ProfileAssignmentQuery) OnlyIDX

func (_q *ProfileAssignmentQuery) OnlyIDX(ctx context.Context) string

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*ProfileAssignmentQuery) OnlyX

OnlyX is like Only, but panics if an error occurs.

func (*ProfileAssignmentQuery) Order

Order specifies how the records should be ordered.

func (*ProfileAssignmentQuery) Select

func (_q *ProfileAssignmentQuery) Select(fields ...string) *ProfileAssignmentSelect

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	ProfileID string `json:"profile_id,omitempty"`
}

client.ProfileAssignment.Query().
	Select(profileassignment.FieldProfileID).
	Scan(ctx, &v)

func (*ProfileAssignmentQuery) Unique

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*ProfileAssignmentQuery) Where

Where adds a new predicate for the ProfileAssignmentQuery builder.

type ProfileAssignmentSelect

type ProfileAssignmentSelect struct {
	*ProfileAssignmentQuery
	// contains filtered or unexported fields
}

ProfileAssignmentSelect is the builder for selecting fields of ProfileAssignment entities.

func (*ProfileAssignmentSelect) Aggregate

Aggregate adds the given aggregation functions to the selector query.

func (*ProfileAssignmentSelect) Bool

func (s *ProfileAssignmentSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*ProfileAssignmentSelect) BoolX

func (s *ProfileAssignmentSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*ProfileAssignmentSelect) Bools

func (s *ProfileAssignmentSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*ProfileAssignmentSelect) BoolsX

func (s *ProfileAssignmentSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*ProfileAssignmentSelect) Float64

func (s *ProfileAssignmentSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*ProfileAssignmentSelect) Float64X

func (s *ProfileAssignmentSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*ProfileAssignmentSelect) Float64s

func (s *ProfileAssignmentSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*ProfileAssignmentSelect) Float64sX

func (s *ProfileAssignmentSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*ProfileAssignmentSelect) Int

func (s *ProfileAssignmentSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*ProfileAssignmentSelect) IntX

func (s *ProfileAssignmentSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*ProfileAssignmentSelect) Ints

func (s *ProfileAssignmentSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*ProfileAssignmentSelect) IntsX

func (s *ProfileAssignmentSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*ProfileAssignmentSelect) Scan

func (_s *ProfileAssignmentSelect) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*ProfileAssignmentSelect) ScanX

func (s *ProfileAssignmentSelect) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*ProfileAssignmentSelect) String

func (s *ProfileAssignmentSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*ProfileAssignmentSelect) StringX

func (s *ProfileAssignmentSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*ProfileAssignmentSelect) Strings

func (s *ProfileAssignmentSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*ProfileAssignmentSelect) StringsX

func (s *ProfileAssignmentSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type ProfileAssignmentUpdate

type ProfileAssignmentUpdate struct {
	// contains filtered or unexported fields
}

ProfileAssignmentUpdate is the builder for updating ProfileAssignment entities.

func (*ProfileAssignmentUpdate) AppendEvidenceIds

func (_u *ProfileAssignmentUpdate) AppendEvidenceIds(v []string) *ProfileAssignmentUpdate

AppendEvidenceIds appends value to the "evidence_ids" field.

func (*ProfileAssignmentUpdate) AppendSecondary

func (_u *ProfileAssignmentUpdate) AppendSecondary(v []string) *ProfileAssignmentUpdate

AppendSecondary appends value to the "secondary" field.

func (*ProfileAssignmentUpdate) ClearConfirmedAt

func (_u *ProfileAssignmentUpdate) ClearConfirmedAt() *ProfileAssignmentUpdate

ClearConfirmedAt clears the value of the "confirmed_at" field.

func (*ProfileAssignmentUpdate) ClearConfirmedBy

func (_u *ProfileAssignmentUpdate) ClearConfirmedBy() *ProfileAssignmentUpdate

ClearConfirmedBy clears the value of the "confirmed_by" field.

func (*ProfileAssignmentUpdate) ClearEvidenceIds

func (_u *ProfileAssignmentUpdate) ClearEvidenceIds() *ProfileAssignmentUpdate

ClearEvidenceIds clears the value of the "evidence_ids" field.

func (*ProfileAssignmentUpdate) ClearSecondary

func (_u *ProfileAssignmentUpdate) ClearSecondary() *ProfileAssignmentUpdate

ClearSecondary clears the value of the "secondary" field.

func (*ProfileAssignmentUpdate) Exec

Exec executes the query.

func (*ProfileAssignmentUpdate) ExecX

func (_u *ProfileAssignmentUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ProfileAssignmentUpdate) Mutation

Mutation returns the ProfileAssignmentMutation object of the builder.

func (*ProfileAssignmentUpdate) Save

func (_u *ProfileAssignmentUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*ProfileAssignmentUpdate) SaveX

func (_u *ProfileAssignmentUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*ProfileAssignmentUpdate) SetConfirmedAt

SetConfirmedAt sets the "confirmed_at" field.

func (*ProfileAssignmentUpdate) SetConfirmedBy

SetConfirmedBy sets the "confirmed_by" field.

func (*ProfileAssignmentUpdate) SetEvidenceIds

func (_u *ProfileAssignmentUpdate) SetEvidenceIds(v []string) *ProfileAssignmentUpdate

SetEvidenceIds sets the "evidence_ids" field.

func (*ProfileAssignmentUpdate) SetNillableConfirmedAt

func (_u *ProfileAssignmentUpdate) SetNillableConfirmedAt(v *time.Time) *ProfileAssignmentUpdate

SetNillableConfirmedAt sets the "confirmed_at" field if the given value is not nil.

func (*ProfileAssignmentUpdate) SetNillableConfirmedBy

func (_u *ProfileAssignmentUpdate) SetNillableConfirmedBy(v *string) *ProfileAssignmentUpdate

SetNillableConfirmedBy sets the "confirmed_by" field if the given value is not nil.

func (*ProfileAssignmentUpdate) SetNillableProfileID

func (_u *ProfileAssignmentUpdate) SetNillableProfileID(v *string) *ProfileAssignmentUpdate

SetNillableProfileID sets the "profile_id" field if the given value is not nil.

func (*ProfileAssignmentUpdate) SetNillableProposedBy

func (_u *ProfileAssignmentUpdate) SetNillableProposedBy(v *string) *ProfileAssignmentUpdate

SetNillableProposedBy sets the "proposed_by" field if the given value is not nil.

func (*ProfileAssignmentUpdate) SetNillableRationale

func (_u *ProfileAssignmentUpdate) SetNillableRationale(v *string) *ProfileAssignmentUpdate

SetNillableRationale sets the "rationale" field if the given value is not nil.

func (*ProfileAssignmentUpdate) SetNillableStatus

func (_u *ProfileAssignmentUpdate) SetNillableStatus(v *string) *ProfileAssignmentUpdate

SetNillableStatus sets the "status" field if the given value is not nil.

func (*ProfileAssignmentUpdate) SetProfileID

SetProfileID sets the "profile_id" field.

func (*ProfileAssignmentUpdate) SetProposedBy

SetProposedBy sets the "proposed_by" field.

func (*ProfileAssignmentUpdate) SetRationale

SetRationale sets the "rationale" field.

func (*ProfileAssignmentUpdate) SetSecondary

SetSecondary sets the "secondary" field.

func (*ProfileAssignmentUpdate) SetStatus

SetStatus sets the "status" field.

func (*ProfileAssignmentUpdate) SetUpdatedAt

SetUpdatedAt sets the "updated_at" field.

func (*ProfileAssignmentUpdate) Where

Where appends a list predicates to the ProfileAssignmentUpdate builder.

type ProfileAssignmentUpdateOne

type ProfileAssignmentUpdateOne struct {
	// contains filtered or unexported fields
}

ProfileAssignmentUpdateOne is the builder for updating a single ProfileAssignment entity.

func (*ProfileAssignmentUpdateOne) AppendEvidenceIds

func (_u *ProfileAssignmentUpdateOne) AppendEvidenceIds(v []string) *ProfileAssignmentUpdateOne

AppendEvidenceIds appends value to the "evidence_ids" field.

func (*ProfileAssignmentUpdateOne) AppendSecondary

AppendSecondary appends value to the "secondary" field.

func (*ProfileAssignmentUpdateOne) ClearConfirmedAt

ClearConfirmedAt clears the value of the "confirmed_at" field.

func (*ProfileAssignmentUpdateOne) ClearConfirmedBy

ClearConfirmedBy clears the value of the "confirmed_by" field.

func (*ProfileAssignmentUpdateOne) ClearEvidenceIds

ClearEvidenceIds clears the value of the "evidence_ids" field.

func (*ProfileAssignmentUpdateOne) ClearSecondary

ClearSecondary clears the value of the "secondary" field.

func (*ProfileAssignmentUpdateOne) Exec

Exec executes the query on the entity.

func (*ProfileAssignmentUpdateOne) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*ProfileAssignmentUpdateOne) Mutation

Mutation returns the ProfileAssignmentMutation object of the builder.

func (*ProfileAssignmentUpdateOne) Save

Save executes the query and returns the updated ProfileAssignment entity.

func (*ProfileAssignmentUpdateOne) SaveX

SaveX is like Save, but panics if an error occurs.

func (*ProfileAssignmentUpdateOne) Select

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*ProfileAssignmentUpdateOne) SetConfirmedAt

SetConfirmedAt sets the "confirmed_at" field.

func (*ProfileAssignmentUpdateOne) SetConfirmedBy

SetConfirmedBy sets the "confirmed_by" field.

func (*ProfileAssignmentUpdateOne) SetEvidenceIds

SetEvidenceIds sets the "evidence_ids" field.

func (*ProfileAssignmentUpdateOne) SetNillableConfirmedAt

func (_u *ProfileAssignmentUpdateOne) SetNillableConfirmedAt(v *time.Time) *ProfileAssignmentUpdateOne

SetNillableConfirmedAt sets the "confirmed_at" field if the given value is not nil.

func (*ProfileAssignmentUpdateOne) SetNillableConfirmedBy

func (_u *ProfileAssignmentUpdateOne) SetNillableConfirmedBy(v *string) *ProfileAssignmentUpdateOne

SetNillableConfirmedBy sets the "confirmed_by" field if the given value is not nil.

func (*ProfileAssignmentUpdateOne) SetNillableProfileID

func (_u *ProfileAssignmentUpdateOne) SetNillableProfileID(v *string) *ProfileAssignmentUpdateOne

SetNillableProfileID sets the "profile_id" field if the given value is not nil.

func (*ProfileAssignmentUpdateOne) SetNillableProposedBy

func (_u *ProfileAssignmentUpdateOne) SetNillableProposedBy(v *string) *ProfileAssignmentUpdateOne

SetNillableProposedBy sets the "proposed_by" field if the given value is not nil.

func (*ProfileAssignmentUpdateOne) SetNillableRationale

func (_u *ProfileAssignmentUpdateOne) SetNillableRationale(v *string) *ProfileAssignmentUpdateOne

SetNillableRationale sets the "rationale" field if the given value is not nil.

func (*ProfileAssignmentUpdateOne) SetNillableStatus

SetNillableStatus sets the "status" field if the given value is not nil.

func (*ProfileAssignmentUpdateOne) SetProfileID

SetProfileID sets the "profile_id" field.

func (*ProfileAssignmentUpdateOne) SetProposedBy

SetProposedBy sets the "proposed_by" field.

func (*ProfileAssignmentUpdateOne) SetRationale

SetRationale sets the "rationale" field.

func (*ProfileAssignmentUpdateOne) SetSecondary

SetSecondary sets the "secondary" field.

func (*ProfileAssignmentUpdateOne) SetStatus

SetStatus sets the "status" field.

func (*ProfileAssignmentUpdateOne) SetUpdatedAt

SetUpdatedAt sets the "updated_at" field.

func (*ProfileAssignmentUpdateOne) Where

Where appends a list predicates to the ProfileAssignmentUpdate builder.

type ProfileAssignmentUpsert

type ProfileAssignmentUpsert struct {
	*sql.UpdateSet
}

ProfileAssignmentUpsert is the "OnConflict" setter.

func (*ProfileAssignmentUpsert) ClearConfirmedAt

func (u *ProfileAssignmentUpsert) ClearConfirmedAt() *ProfileAssignmentUpsert

ClearConfirmedAt clears the value of the "confirmed_at" field.

func (*ProfileAssignmentUpsert) ClearConfirmedBy

func (u *ProfileAssignmentUpsert) ClearConfirmedBy() *ProfileAssignmentUpsert

ClearConfirmedBy clears the value of the "confirmed_by" field.

func (*ProfileAssignmentUpsert) ClearEvidenceIds

func (u *ProfileAssignmentUpsert) ClearEvidenceIds() *ProfileAssignmentUpsert

ClearEvidenceIds clears the value of the "evidence_ids" field.

func (*ProfileAssignmentUpsert) ClearSecondary

func (u *ProfileAssignmentUpsert) ClearSecondary() *ProfileAssignmentUpsert

ClearSecondary clears the value of the "secondary" field.

func (*ProfileAssignmentUpsert) SetConfirmedAt

SetConfirmedAt sets the "confirmed_at" field.

func (*ProfileAssignmentUpsert) SetConfirmedBy

SetConfirmedBy sets the "confirmed_by" field.

func (*ProfileAssignmentUpsert) SetEvidenceIds

func (u *ProfileAssignmentUpsert) SetEvidenceIds(v []string) *ProfileAssignmentUpsert

SetEvidenceIds sets the "evidence_ids" field.

func (*ProfileAssignmentUpsert) SetProfileID

SetProfileID sets the "profile_id" field.

func (*ProfileAssignmentUpsert) SetProposedBy

SetProposedBy sets the "proposed_by" field.

func (*ProfileAssignmentUpsert) SetRationale

SetRationale sets the "rationale" field.

func (*ProfileAssignmentUpsert) SetSecondary

SetSecondary sets the "secondary" field.

func (*ProfileAssignmentUpsert) SetStatus

SetStatus sets the "status" field.

func (*ProfileAssignmentUpsert) SetUpdatedAt

SetUpdatedAt sets the "updated_at" field.

func (*ProfileAssignmentUpsert) UpdateConfirmedAt

func (u *ProfileAssignmentUpsert) UpdateConfirmedAt() *ProfileAssignmentUpsert

UpdateConfirmedAt sets the "confirmed_at" field to the value that was provided on create.

func (*ProfileAssignmentUpsert) UpdateConfirmedBy

func (u *ProfileAssignmentUpsert) UpdateConfirmedBy() *ProfileAssignmentUpsert

UpdateConfirmedBy sets the "confirmed_by" field to the value that was provided on create.

func (*ProfileAssignmentUpsert) UpdateEvidenceIds

func (u *ProfileAssignmentUpsert) UpdateEvidenceIds() *ProfileAssignmentUpsert

UpdateEvidenceIds sets the "evidence_ids" field to the value that was provided on create.

func (*ProfileAssignmentUpsert) UpdateProfileID

func (u *ProfileAssignmentUpsert) UpdateProfileID() *ProfileAssignmentUpsert

UpdateProfileID sets the "profile_id" field to the value that was provided on create.

func (*ProfileAssignmentUpsert) UpdateProposedBy

func (u *ProfileAssignmentUpsert) UpdateProposedBy() *ProfileAssignmentUpsert

UpdateProposedBy sets the "proposed_by" field to the value that was provided on create.

func (*ProfileAssignmentUpsert) UpdateRationale

func (u *ProfileAssignmentUpsert) UpdateRationale() *ProfileAssignmentUpsert

UpdateRationale sets the "rationale" field to the value that was provided on create.

func (*ProfileAssignmentUpsert) UpdateSecondary

func (u *ProfileAssignmentUpsert) UpdateSecondary() *ProfileAssignmentUpsert

UpdateSecondary sets the "secondary" field to the value that was provided on create.

func (*ProfileAssignmentUpsert) UpdateStatus

UpdateStatus sets the "status" field to the value that was provided on create.

func (*ProfileAssignmentUpsert) UpdateUpdatedAt

func (u *ProfileAssignmentUpsert) UpdateUpdatedAt() *ProfileAssignmentUpsert

UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.

type ProfileAssignmentUpsertBulk

type ProfileAssignmentUpsertBulk struct {
	// contains filtered or unexported fields
}

ProfileAssignmentUpsertBulk is the builder for "upsert"-ing a bulk of ProfileAssignment nodes.

func (*ProfileAssignmentUpsertBulk) ClearConfirmedAt

ClearConfirmedAt clears the value of the "confirmed_at" field.

func (*ProfileAssignmentUpsertBulk) ClearConfirmedBy

ClearConfirmedBy clears the value of the "confirmed_by" field.

func (*ProfileAssignmentUpsertBulk) ClearEvidenceIds

ClearEvidenceIds clears the value of the "evidence_ids" field.

func (*ProfileAssignmentUpsertBulk) ClearSecondary

ClearSecondary clears the value of the "secondary" field.

func (*ProfileAssignmentUpsertBulk) DoNothing

DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.

func (*ProfileAssignmentUpsertBulk) Exec

Exec executes the query.

func (*ProfileAssignmentUpsertBulk) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*ProfileAssignmentUpsertBulk) Ignore

Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:

client.ProfileAssignment.Create().
	OnConflict(sql.ResolveWithIgnore()).
	Exec(ctx)

func (*ProfileAssignmentUpsertBulk) SetConfirmedAt

SetConfirmedAt sets the "confirmed_at" field.

func (*ProfileAssignmentUpsertBulk) SetConfirmedBy

SetConfirmedBy sets the "confirmed_by" field.

func (*ProfileAssignmentUpsertBulk) SetEvidenceIds

SetEvidenceIds sets the "evidence_ids" field.

func (*ProfileAssignmentUpsertBulk) SetProfileID

SetProfileID sets the "profile_id" field.

func (*ProfileAssignmentUpsertBulk) SetProposedBy

SetProposedBy sets the "proposed_by" field.

func (*ProfileAssignmentUpsertBulk) SetRationale

SetRationale sets the "rationale" field.

func (*ProfileAssignmentUpsertBulk) SetSecondary

SetSecondary sets the "secondary" field.

func (*ProfileAssignmentUpsertBulk) SetStatus

SetStatus sets the "status" field.

func (*ProfileAssignmentUpsertBulk) SetUpdatedAt

SetUpdatedAt sets the "updated_at" field.

func (*ProfileAssignmentUpsertBulk) Update

Update allows overriding fields `UPDATE` values. See the ProfileAssignmentCreateBulk.OnConflict documentation for more info.

func (*ProfileAssignmentUpsertBulk) UpdateConfirmedAt

UpdateConfirmedAt sets the "confirmed_at" field to the value that was provided on create.

func (*ProfileAssignmentUpsertBulk) UpdateConfirmedBy

UpdateConfirmedBy sets the "confirmed_by" field to the value that was provided on create.

func (*ProfileAssignmentUpsertBulk) UpdateEvidenceIds

UpdateEvidenceIds sets the "evidence_ids" field to the value that was provided on create.

func (*ProfileAssignmentUpsertBulk) UpdateNewValues

UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:

client.ProfileAssignment.Create().
	OnConflict(
		sql.ResolveWithNewValues(),
		sql.ResolveWith(func(u *sql.UpdateSet) {
			u.SetIgnore(profileassignment.FieldID)
		}),
	).
	Exec(ctx)

func (*ProfileAssignmentUpsertBulk) UpdateProfileID

UpdateProfileID sets the "profile_id" field to the value that was provided on create.

func (*ProfileAssignmentUpsertBulk) UpdateProposedBy

UpdateProposedBy sets the "proposed_by" field to the value that was provided on create.

func (*ProfileAssignmentUpsertBulk) UpdateRationale

UpdateRationale sets the "rationale" field to the value that was provided on create.

func (*ProfileAssignmentUpsertBulk) UpdateSecondary

UpdateSecondary sets the "secondary" field to the value that was provided on create.

func (*ProfileAssignmentUpsertBulk) UpdateStatus

UpdateStatus sets the "status" field to the value that was provided on create.

func (*ProfileAssignmentUpsertBulk) UpdateUpdatedAt

UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.

type ProfileAssignmentUpsertOne

type ProfileAssignmentUpsertOne struct {
	// contains filtered or unexported fields
}

ProfileAssignmentUpsertOne is the builder for "upsert"-ing

one ProfileAssignment node.

func (*ProfileAssignmentUpsertOne) ClearConfirmedAt

ClearConfirmedAt clears the value of the "confirmed_at" field.

func (*ProfileAssignmentUpsertOne) ClearConfirmedBy

ClearConfirmedBy clears the value of the "confirmed_by" field.

func (*ProfileAssignmentUpsertOne) ClearEvidenceIds

ClearEvidenceIds clears the value of the "evidence_ids" field.

func (*ProfileAssignmentUpsertOne) ClearSecondary

ClearSecondary clears the value of the "secondary" field.

func (*ProfileAssignmentUpsertOne) DoNothing

DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.

func (*ProfileAssignmentUpsertOne) Exec

Exec executes the query.

func (*ProfileAssignmentUpsertOne) ExecX

ExecX is like Exec, but panics if an error occurs.

func (*ProfileAssignmentUpsertOne) ID

func (u *ProfileAssignmentUpsertOne) ID(ctx context.Context) (id string, err error)

Exec executes the UPSERT query and returns the inserted/updated ID.

func (*ProfileAssignmentUpsertOne) IDX

IDX is like ID, but panics if an error occurs.

func (*ProfileAssignmentUpsertOne) Ignore

Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:

client.ProfileAssignment.Create().
    OnConflict(sql.ResolveWithIgnore()).
    Exec(ctx)

func (*ProfileAssignmentUpsertOne) SetConfirmedAt

SetConfirmedAt sets the "confirmed_at" field.

func (*ProfileAssignmentUpsertOne) SetConfirmedBy

SetConfirmedBy sets the "confirmed_by" field.

func (*ProfileAssignmentUpsertOne) SetEvidenceIds

SetEvidenceIds sets the "evidence_ids" field.

func (*ProfileAssignmentUpsertOne) SetProfileID

SetProfileID sets the "profile_id" field.

func (*ProfileAssignmentUpsertOne) SetProposedBy

SetProposedBy sets the "proposed_by" field.

func (*ProfileAssignmentUpsertOne) SetRationale

SetRationale sets the "rationale" field.

func (*ProfileAssignmentUpsertOne) SetSecondary

SetSecondary sets the "secondary" field.

func (*ProfileAssignmentUpsertOne) SetStatus

SetStatus sets the "status" field.

func (*ProfileAssignmentUpsertOne) SetUpdatedAt

SetUpdatedAt sets the "updated_at" field.

func (*ProfileAssignmentUpsertOne) Update

Update allows overriding fields `UPDATE` values. See the ProfileAssignmentCreate.OnConflict documentation for more info.

func (*ProfileAssignmentUpsertOne) UpdateConfirmedAt

UpdateConfirmedAt sets the "confirmed_at" field to the value that was provided on create.

func (*ProfileAssignmentUpsertOne) UpdateConfirmedBy

UpdateConfirmedBy sets the "confirmed_by" field to the value that was provided on create.

func (*ProfileAssignmentUpsertOne) UpdateEvidenceIds

UpdateEvidenceIds sets the "evidence_ids" field to the value that was provided on create.

func (*ProfileAssignmentUpsertOne) UpdateNewValues

UpdateNewValues updates the mutable fields using the new values that were set on create except the ID field. Using this option is equivalent to using:

client.ProfileAssignment.Create().
	OnConflict(
		sql.ResolveWithNewValues(),
		sql.ResolveWith(func(u *sql.UpdateSet) {
			u.SetIgnore(profileassignment.FieldID)
		}),
	).
	Exec(ctx)

func (*ProfileAssignmentUpsertOne) UpdateProfileID

UpdateProfileID sets the "profile_id" field to the value that was provided on create.

func (*ProfileAssignmentUpsertOne) UpdateProposedBy

UpdateProposedBy sets the "proposed_by" field to the value that was provided on create.

func (*ProfileAssignmentUpsertOne) UpdateRationale

UpdateRationale sets the "rationale" field to the value that was provided on create.

func (*ProfileAssignmentUpsertOne) UpdateSecondary

UpdateSecondary sets the "secondary" field to the value that was provided on create.

func (*ProfileAssignmentUpsertOne) UpdateStatus

UpdateStatus sets the "status" field to the value that was provided on create.

func (*ProfileAssignmentUpsertOne) UpdateUpdatedAt

UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.

type ProfileAssignments

type ProfileAssignments []*ProfileAssignment

ProfileAssignments is a parsable slice of ProfileAssignment.

type Querier

type Querier = ent.Querier

ent aliases to avoid import conflicts in user's code.

type QuerierFunc

type QuerierFunc = ent.QuerierFunc

ent aliases to avoid import conflicts in user's code.

type Query

type Query = ent.Query

ent aliases to avoid import conflicts in user's code.

type QueryContext

type QueryContext = ent.QueryContext

ent aliases to avoid import conflicts in user's code.

type RankOverride

type RankOverride struct {

	// ID of the ent.
	ID string `json:"id,omitempty"`
	// FinalRank holds the value of the "final_rank" field.
	FinalRank int `json:"final_rank,omitempty"`
	// Rationale holds the value of the "rationale" field.
	Rationale string `json:"rationale,omitempty"`
	// ApprovedBy holds the value of the "approved_by" field.
	ApprovedBy string `json:"approved_by,omitempty"`
	// EvidenceIds holds the value of the "evidence_ids" field.
	EvidenceIds []string `json:"evidence_ids,omitempty"`
	// CreatedAt holds the value of the "created_at" field.
	CreatedAt time.Time `json:"created_at,omitempty"`
	// UpdatedAt holds the value of the "updated_at" field.
	UpdatedAt time.Time `json:"updated_at,omitempty"`
	// contains filtered or unexported fields
}

RankOverride is the model entity for the RankOverride schema.

func (*RankOverride) String

func (_m *RankOverride) String() string

String implements the fmt.Stringer.

func (*RankOverride) Unwrap

func (_m *RankOverride) Unwrap() *RankOverride

Unwrap unwraps the RankOverride entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*RankOverride) Update

func (_m *RankOverride) Update() *RankOverrideUpdateOne

Update returns a builder for updating this RankOverride. Note that you need to call RankOverride.Unwrap() before calling this method if this RankOverride was returned from a transaction, and the transaction was committed or rolled back.

func (*RankOverride) Value

func (_m *RankOverride) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the RankOverride. This includes values selected through modifiers, order, etc.

type RankOverrideClient

type RankOverrideClient struct {
	// contains filtered or unexported fields
}

RankOverrideClient is a client for the RankOverride schema.

func NewRankOverrideClient

func NewRankOverrideClient(c config) *RankOverrideClient

NewRankOverrideClient returns a client for the RankOverride from the given config.

func (*RankOverrideClient) Create

Create returns a builder for creating a RankOverride entity.

func (*RankOverrideClient) CreateBulk

func (c *RankOverrideClient) CreateBulk(builders ...*RankOverrideCreate) *RankOverrideCreateBulk

CreateBulk returns a builder for creating a bulk of RankOverride entities.

func (*RankOverrideClient) Delete

Delete returns a delete builder for RankOverride.

func (*RankOverrideClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*RankOverrideClient) DeleteOneID

func (c *RankOverrideClient) DeleteOneID(id string) *RankOverrideDeleteOne

DeleteOneID returns a builder for deleting the given entity by its id.

func (*RankOverrideClient) Get

Get returns a RankOverride entity by its id.

func (*RankOverrideClient) GetX

GetX is like Get, but panics if an error occurs.

func (*RankOverrideClient) Hooks

func (c *RankOverrideClient) Hooks() []Hook

Hooks returns the client hooks.

func (*RankOverrideClient) Intercept

func (c *RankOverrideClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `rankoverride.Intercept(f(g(h())))`.

func (*RankOverrideClient) Interceptors

func (c *RankOverrideClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*RankOverrideClient) MapCreateBulk

func (c *RankOverrideClient) MapCreateBulk(slice any, setFunc func(*RankOverrideCreate, int)) *RankOverrideCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*RankOverrideClient) Query

Query returns a query builder for RankOverride.

func (*RankOverrideClient) Update

Update returns an update builder for RankOverride.

func (*RankOverrideClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*RankOverrideClient) UpdateOneID

func (c *RankOverrideClient) UpdateOneID(id string) *RankOverrideUpdateOne

UpdateOneID returns an update builder for the given id.

func (*RankOverrideClient) Use

func (c *RankOverrideClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `rankoverride.Hooks(f(g(h())))`.

type RankOverrideCreate

type RankOverrideCreate struct {
	// contains filtered or unexported fields
}

RankOverrideCreate is the builder for creating a RankOverride entity.

func (*RankOverrideCreate) Exec

func (_c *RankOverrideCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*RankOverrideCreate) ExecX

func (_c *RankOverrideCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*RankOverrideCreate) Mutation

func (_c *RankOverrideCreate) Mutation() *RankOverrideMutation

Mutation returns the RankOverrideMutation object of the builder.

func (*RankOverrideCreate) OnConflict

OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:

client.RankOverride.Create().
	SetFinalRank(v).
	OnConflict(
		// Update the row with the new values
		// the was proposed for insertion.
		sql.ResolveWithNewValues(),
	).
	// Override some of the fields with custom
	// update values.
	Update(func(u *ent.RankOverrideUpsert) {
		SetFinalRank(v+v).
	}).
	Exec(ctx)

func (*RankOverrideCreate) OnConflictColumns

func (_c *RankOverrideCreate) OnConflictColumns(columns ...string) *RankOverrideUpsertOne

OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:

client.RankOverride.Create().
	OnConflict(sql.ConflictColumns(columns...)).
	Exec(ctx)

func (*RankOverrideCreate) Save

Save creates the RankOverride in the database.

func (*RankOverrideCreate) SaveX

SaveX calls Save and panics if Save returns an error.

func (*RankOverrideCreate) SetApprovedBy

func (_c *RankOverrideCreate) SetApprovedBy(v string) *RankOverrideCreate

SetApprovedBy sets the "approved_by" field.

func (*RankOverrideCreate) SetCreatedAt

func (_c *RankOverrideCreate) SetCreatedAt(v time.Time) *RankOverrideCreate

SetCreatedAt sets the "created_at" field.

func (*RankOverrideCreate) SetEvidenceIds

func (_c *RankOverrideCreate) SetEvidenceIds(v []string) *RankOverrideCreate

SetEvidenceIds sets the "evidence_ids" field.

func (*RankOverrideCreate) SetFinalRank

func (_c *RankOverrideCreate) SetFinalRank(v int) *RankOverrideCreate

SetFinalRank sets the "final_rank" field.

func (*RankOverrideCreate) SetID

SetID sets the "id" field.

func (*RankOverrideCreate) SetNillableCreatedAt

func (_c *RankOverrideCreate) SetNillableCreatedAt(v *time.Time) *RankOverrideCreate

SetNillableCreatedAt sets the "created_at" field if the given value is not nil.

func (*RankOverrideCreate) SetNillableUpdatedAt

func (_c *RankOverrideCreate) SetNillableUpdatedAt(v *time.Time) *RankOverrideCreate

SetNillableUpdatedAt sets the "updated_at" field if the given value is not nil.

func (*RankOverrideCreate) SetRationale

func (_c *RankOverrideCreate) SetRationale(v string) *RankOverrideCreate

SetRationale sets the "rationale" field.

func (*RankOverrideCreate) SetUpdatedAt

func (_c *RankOverrideCreate) SetUpdatedAt(v time.Time) *RankOverrideCreate

SetUpdatedAt sets the "updated_at" field.

type RankOverrideCreateBulk

type RankOverrideCreateBulk struct {
	// contains filtered or unexported fields
}

RankOverrideCreateBulk is the builder for creating many RankOverride entities in bulk.

func (*RankOverrideCreateBulk) Exec

Exec executes the query.

func (*RankOverrideCreateBulk) ExecX

func (_c *RankOverrideCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*RankOverrideCreateBulk) OnConflict

OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:

client.RankOverride.CreateBulk(builders...).
	OnConflict(
		// Update the row with the new values
		// the was proposed for insertion.
		sql.ResolveWithNewValues(),
	).
	// Override some of the fields with custom
	// update values.
	Update(func(u *ent.RankOverrideUpsert) {
		SetFinalRank(v+v).
	}).
	Exec(ctx)

func (*RankOverrideCreateBulk) OnConflictColumns

func (_c *RankOverrideCreateBulk) OnConflictColumns(columns ...string) *RankOverrideUpsertBulk

OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:

client.RankOverride.Create().
	OnConflict(sql.ConflictColumns(columns...)).
	Exec(ctx)

func (*RankOverrideCreateBulk) Save

Save creates the RankOverride entities in the database.

func (*RankOverrideCreateBulk) SaveX

SaveX is like Save, but panics if an error occurs.

type RankOverrideDelete

type RankOverrideDelete struct {
	// contains filtered or unexported fields
}

RankOverrideDelete is the builder for deleting a RankOverride entity.

func (*RankOverrideDelete) Exec

func (_d *RankOverrideDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*RankOverrideDelete) ExecX

func (_d *RankOverrideDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*RankOverrideDelete) Where

Where appends a list predicates to the RankOverrideDelete builder.

type RankOverrideDeleteOne

type RankOverrideDeleteOne struct {
	// contains filtered or unexported fields
}

RankOverrideDeleteOne is the builder for deleting a single RankOverride entity.

func (*RankOverrideDeleteOne) Exec

Exec executes the deletion query.

func (*RankOverrideDeleteOne) ExecX

func (_d *RankOverrideDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*RankOverrideDeleteOne) Where

Where appends a list predicates to the RankOverrideDelete builder.

type RankOverrideGroupBy

type RankOverrideGroupBy struct {
	// contains filtered or unexported fields
}

RankOverrideGroupBy is the group-by builder for RankOverride entities.

func (*RankOverrideGroupBy) Aggregate

func (_g *RankOverrideGroupBy) Aggregate(fns ...AggregateFunc) *RankOverrideGroupBy

Aggregate adds the given aggregation functions to the group-by query.

func (*RankOverrideGroupBy) Bool

func (s *RankOverrideGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*RankOverrideGroupBy) BoolX

func (s *RankOverrideGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*RankOverrideGroupBy) Bools

func (s *RankOverrideGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*RankOverrideGroupBy) BoolsX

func (s *RankOverrideGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*RankOverrideGroupBy) Float64

func (s *RankOverrideGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*RankOverrideGroupBy) Float64X

func (s *RankOverrideGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*RankOverrideGroupBy) Float64s

func (s *RankOverrideGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*RankOverrideGroupBy) Float64sX

func (s *RankOverrideGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*RankOverrideGroupBy) Int

func (s *RankOverrideGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*RankOverrideGroupBy) IntX

func (s *RankOverrideGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*RankOverrideGroupBy) Ints

func (s *RankOverrideGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*RankOverrideGroupBy) IntsX

func (s *RankOverrideGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*RankOverrideGroupBy) Scan

func (_g *RankOverrideGroupBy) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*RankOverrideGroupBy) ScanX

func (s *RankOverrideGroupBy) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*RankOverrideGroupBy) String

func (s *RankOverrideGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*RankOverrideGroupBy) StringX

func (s *RankOverrideGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*RankOverrideGroupBy) Strings

func (s *RankOverrideGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*RankOverrideGroupBy) StringsX

func (s *RankOverrideGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type RankOverrideMutation

type RankOverrideMutation struct {
	// contains filtered or unexported fields
}

RankOverrideMutation represents an operation that mutates the RankOverride nodes in the graph.

func (*RankOverrideMutation) AddField

func (m *RankOverrideMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*RankOverrideMutation) AddFinalRank

func (m *RankOverrideMutation) AddFinalRank(i int)

AddFinalRank adds i to the "final_rank" field.

func (*RankOverrideMutation) AddedEdges

func (m *RankOverrideMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*RankOverrideMutation) AddedField

func (m *RankOverrideMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*RankOverrideMutation) AddedFields

func (m *RankOverrideMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*RankOverrideMutation) AddedFinalRank

func (m *RankOverrideMutation) AddedFinalRank() (r int, exists bool)

AddedFinalRank returns the value that was added to the "final_rank" field in this mutation.

func (*RankOverrideMutation) AddedIDs

func (m *RankOverrideMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*RankOverrideMutation) AppendEvidenceIds

func (m *RankOverrideMutation) AppendEvidenceIds(s []string)

AppendEvidenceIds adds s to the "evidence_ids" field.

func (*RankOverrideMutation) AppendedEvidenceIds

func (m *RankOverrideMutation) AppendedEvidenceIds() ([]string, bool)

AppendedEvidenceIds returns the list of values that were appended to the "evidence_ids" field in this mutation.

func (*RankOverrideMutation) ApprovedBy

func (m *RankOverrideMutation) ApprovedBy() (r string, exists bool)

ApprovedBy returns the value of the "approved_by" field in the mutation.

func (*RankOverrideMutation) ClearEdge

func (m *RankOverrideMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*RankOverrideMutation) ClearEvidenceIds

func (m *RankOverrideMutation) ClearEvidenceIds()

ClearEvidenceIds clears the value of the "evidence_ids" field.

func (*RankOverrideMutation) ClearField

func (m *RankOverrideMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*RankOverrideMutation) ClearedEdges

func (m *RankOverrideMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*RankOverrideMutation) ClearedFields

func (m *RankOverrideMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (RankOverrideMutation) Client

func (m RankOverrideMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*RankOverrideMutation) CreatedAt

func (m *RankOverrideMutation) CreatedAt() (r time.Time, exists bool)

CreatedAt returns the value of the "created_at" field in the mutation.

func (*RankOverrideMutation) EdgeCleared

func (m *RankOverrideMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*RankOverrideMutation) EvidenceIds

func (m *RankOverrideMutation) EvidenceIds() (r []string, exists bool)

EvidenceIds returns the value of the "evidence_ids" field in the mutation.

func (*RankOverrideMutation) EvidenceIdsCleared

func (m *RankOverrideMutation) EvidenceIdsCleared() bool

EvidenceIdsCleared returns if the "evidence_ids" field was cleared in this mutation.

func (*RankOverrideMutation) Field

func (m *RankOverrideMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*RankOverrideMutation) FieldCleared

func (m *RankOverrideMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*RankOverrideMutation) Fields

func (m *RankOverrideMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*RankOverrideMutation) FinalRank

func (m *RankOverrideMutation) FinalRank() (r int, exists bool)

FinalRank returns the value of the "final_rank" field in the mutation.

func (*RankOverrideMutation) ID

func (m *RankOverrideMutation) ID() (id string, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*RankOverrideMutation) IDs

func (m *RankOverrideMutation) IDs(ctx context.Context) ([]string, error)

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*RankOverrideMutation) OldApprovedBy

func (m *RankOverrideMutation) OldApprovedBy(ctx context.Context) (v string, err error)

OldApprovedBy returns the old "approved_by" field's value of the RankOverride entity. If the RankOverride object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*RankOverrideMutation) OldCreatedAt

func (m *RankOverrideMutation) OldCreatedAt(ctx context.Context) (v time.Time, err error)

OldCreatedAt returns the old "created_at" field's value of the RankOverride entity. If the RankOverride object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*RankOverrideMutation) OldEvidenceIds

func (m *RankOverrideMutation) OldEvidenceIds(ctx context.Context) (v []string, err error)

OldEvidenceIds returns the old "evidence_ids" field's value of the RankOverride entity. If the RankOverride object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*RankOverrideMutation) OldField

func (m *RankOverrideMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*RankOverrideMutation) OldFinalRank

func (m *RankOverrideMutation) OldFinalRank(ctx context.Context) (v int, err error)

OldFinalRank returns the old "final_rank" field's value of the RankOverride entity. If the RankOverride object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*RankOverrideMutation) OldRationale

func (m *RankOverrideMutation) OldRationale(ctx context.Context) (v string, err error)

OldRationale returns the old "rationale" field's value of the RankOverride entity. If the RankOverride object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*RankOverrideMutation) OldUpdatedAt

func (m *RankOverrideMutation) OldUpdatedAt(ctx context.Context) (v time.Time, err error)

OldUpdatedAt returns the old "updated_at" field's value of the RankOverride entity. If the RankOverride object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*RankOverrideMutation) Op

func (m *RankOverrideMutation) Op() Op

Op returns the operation name.

func (*RankOverrideMutation) Rationale

func (m *RankOverrideMutation) Rationale() (r string, exists bool)

Rationale returns the value of the "rationale" field in the mutation.

func (*RankOverrideMutation) RemovedEdges

func (m *RankOverrideMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*RankOverrideMutation) RemovedIDs

func (m *RankOverrideMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*RankOverrideMutation) ResetApprovedBy

func (m *RankOverrideMutation) ResetApprovedBy()

ResetApprovedBy resets all changes to the "approved_by" field.

func (*RankOverrideMutation) ResetCreatedAt

func (m *RankOverrideMutation) ResetCreatedAt()

ResetCreatedAt resets all changes to the "created_at" field.

func (*RankOverrideMutation) ResetEdge

func (m *RankOverrideMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*RankOverrideMutation) ResetEvidenceIds

func (m *RankOverrideMutation) ResetEvidenceIds()

ResetEvidenceIds resets all changes to the "evidence_ids" field.

func (*RankOverrideMutation) ResetField

func (m *RankOverrideMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*RankOverrideMutation) ResetFinalRank

func (m *RankOverrideMutation) ResetFinalRank()

ResetFinalRank resets all changes to the "final_rank" field.

func (*RankOverrideMutation) ResetRationale

func (m *RankOverrideMutation) ResetRationale()

ResetRationale resets all changes to the "rationale" field.

func (*RankOverrideMutation) ResetUpdatedAt

func (m *RankOverrideMutation) ResetUpdatedAt()

ResetUpdatedAt resets all changes to the "updated_at" field.

func (*RankOverrideMutation) SetApprovedBy

func (m *RankOverrideMutation) SetApprovedBy(s string)

SetApprovedBy sets the "approved_by" field.

func (*RankOverrideMutation) SetCreatedAt

func (m *RankOverrideMutation) SetCreatedAt(t time.Time)

SetCreatedAt sets the "created_at" field.

func (*RankOverrideMutation) SetEvidenceIds

func (m *RankOverrideMutation) SetEvidenceIds(s []string)

SetEvidenceIds sets the "evidence_ids" field.

func (*RankOverrideMutation) SetField

func (m *RankOverrideMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*RankOverrideMutation) SetFinalRank

func (m *RankOverrideMutation) SetFinalRank(i int)

SetFinalRank sets the "final_rank" field.

func (*RankOverrideMutation) SetID

func (m *RankOverrideMutation) SetID(id string)

SetID sets the value of the id field. Note that this operation is only accepted on creation of RankOverride entities.

func (*RankOverrideMutation) SetOp

func (m *RankOverrideMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*RankOverrideMutation) SetRationale

func (m *RankOverrideMutation) SetRationale(s string)

SetRationale sets the "rationale" field.

func (*RankOverrideMutation) SetUpdatedAt

func (m *RankOverrideMutation) SetUpdatedAt(t time.Time)

SetUpdatedAt sets the "updated_at" field.

func (RankOverrideMutation) Tx

func (m RankOverrideMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*RankOverrideMutation) Type

func (m *RankOverrideMutation) Type() string

Type returns the node type of this mutation (RankOverride).

func (*RankOverrideMutation) UpdatedAt

func (m *RankOverrideMutation) UpdatedAt() (r time.Time, exists bool)

UpdatedAt returns the value of the "updated_at" field in the mutation.

func (*RankOverrideMutation) Where

Where appends a list predicates to the RankOverrideMutation builder.

func (*RankOverrideMutation) WhereP

func (m *RankOverrideMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the RankOverrideMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

type RankOverrideQuery

type RankOverrideQuery struct {
	// contains filtered or unexported fields
}

RankOverrideQuery is the builder for querying RankOverride entities.

func (*RankOverrideQuery) Aggregate

func (_q *RankOverrideQuery) Aggregate(fns ...AggregateFunc) *RankOverrideSelect

Aggregate returns a RankOverrideSelect configured with the given aggregations.

func (*RankOverrideQuery) All

func (_q *RankOverrideQuery) All(ctx context.Context) ([]*RankOverride, error)

All executes the query and returns a list of RankOverrides.

func (*RankOverrideQuery) AllX

func (_q *RankOverrideQuery) AllX(ctx context.Context) []*RankOverride

AllX is like All, but panics if an error occurs.

func (*RankOverrideQuery) Clone

func (_q *RankOverrideQuery) Clone() *RankOverrideQuery

Clone returns a duplicate of the RankOverrideQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*RankOverrideQuery) Count

func (_q *RankOverrideQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*RankOverrideQuery) CountX

func (_q *RankOverrideQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*RankOverrideQuery) Exist

func (_q *RankOverrideQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*RankOverrideQuery) ExistX

func (_q *RankOverrideQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*RankOverrideQuery) First

func (_q *RankOverrideQuery) First(ctx context.Context) (*RankOverride, error)

First returns the first RankOverride entity from the query. Returns a *NotFoundError when no RankOverride was found.

func (*RankOverrideQuery) FirstID

func (_q *RankOverrideQuery) FirstID(ctx context.Context) (id string, err error)

FirstID returns the first RankOverride ID from the query. Returns a *NotFoundError when no RankOverride ID was found.

func (*RankOverrideQuery) FirstIDX

func (_q *RankOverrideQuery) FirstIDX(ctx context.Context) string

FirstIDX is like FirstID, but panics if an error occurs.

func (*RankOverrideQuery) FirstX

func (_q *RankOverrideQuery) FirstX(ctx context.Context) *RankOverride

FirstX is like First, but panics if an error occurs.

func (*RankOverrideQuery) GroupBy

func (_q *RankOverrideQuery) GroupBy(field string, fields ...string) *RankOverrideGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	FinalRank int `json:"final_rank,omitempty"`
	Count int `json:"count,omitempty"`
}

client.RankOverride.Query().
	GroupBy(rankoverride.FieldFinalRank).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*RankOverrideQuery) IDs

func (_q *RankOverrideQuery) IDs(ctx context.Context) (ids []string, err error)

IDs executes the query and returns a list of RankOverride IDs.

func (*RankOverrideQuery) IDsX

func (_q *RankOverrideQuery) IDsX(ctx context.Context) []string

IDsX is like IDs, but panics if an error occurs.

func (*RankOverrideQuery) Limit

func (_q *RankOverrideQuery) Limit(limit int) *RankOverrideQuery

Limit the number of records to be returned by this query.

func (*RankOverrideQuery) Offset

func (_q *RankOverrideQuery) Offset(offset int) *RankOverrideQuery

Offset to start from.

func (*RankOverrideQuery) Only

Only returns a single RankOverride entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one RankOverride entity is found. Returns a *NotFoundError when no RankOverride entities are found.

func (*RankOverrideQuery) OnlyID

func (_q *RankOverrideQuery) OnlyID(ctx context.Context) (id string, err error)

OnlyID is like Only, but returns the only RankOverride ID in the query. Returns a *NotSingularError when more than one RankOverride ID is found. Returns a *NotFoundError when no entities are found.

func (*RankOverrideQuery) OnlyIDX

func (_q *RankOverrideQuery) OnlyIDX(ctx context.Context) string

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*RankOverrideQuery) OnlyX

OnlyX is like Only, but panics if an error occurs.

func (*RankOverrideQuery) Order

Order specifies how the records should be ordered.

func (*RankOverrideQuery) Select

func (_q *RankOverrideQuery) Select(fields ...string) *RankOverrideSelect

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	FinalRank int `json:"final_rank,omitempty"`
}

client.RankOverride.Query().
	Select(rankoverride.FieldFinalRank).
	Scan(ctx, &v)

func (*RankOverrideQuery) Unique

func (_q *RankOverrideQuery) Unique(unique bool) *RankOverrideQuery

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*RankOverrideQuery) Where

Where adds a new predicate for the RankOverrideQuery builder.

type RankOverrideSelect

type RankOverrideSelect struct {
	*RankOverrideQuery
	// contains filtered or unexported fields
}

RankOverrideSelect is the builder for selecting fields of RankOverride entities.

func (*RankOverrideSelect) Aggregate

func (_s *RankOverrideSelect) Aggregate(fns ...AggregateFunc) *RankOverrideSelect

Aggregate adds the given aggregation functions to the selector query.

func (*RankOverrideSelect) Bool

func (s *RankOverrideSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*RankOverrideSelect) BoolX

func (s *RankOverrideSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*RankOverrideSelect) Bools

func (s *RankOverrideSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*RankOverrideSelect) BoolsX

func (s *RankOverrideSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*RankOverrideSelect) Float64

func (s *RankOverrideSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*RankOverrideSelect) Float64X

func (s *RankOverrideSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*RankOverrideSelect) Float64s

func (s *RankOverrideSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*RankOverrideSelect) Float64sX

func (s *RankOverrideSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*RankOverrideSelect) Int

func (s *RankOverrideSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*RankOverrideSelect) IntX

func (s *RankOverrideSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*RankOverrideSelect) Ints

func (s *RankOverrideSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*RankOverrideSelect) IntsX

func (s *RankOverrideSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*RankOverrideSelect) Scan

func (_s *RankOverrideSelect) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*RankOverrideSelect) ScanX

func (s *RankOverrideSelect) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*RankOverrideSelect) String

func (s *RankOverrideSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*RankOverrideSelect) StringX

func (s *RankOverrideSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*RankOverrideSelect) Strings

func (s *RankOverrideSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*RankOverrideSelect) StringsX

func (s *RankOverrideSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type RankOverrideUpdate

type RankOverrideUpdate struct {
	// contains filtered or unexported fields
}

RankOverrideUpdate is the builder for updating RankOverride entities.

func (*RankOverrideUpdate) AddFinalRank

func (_u *RankOverrideUpdate) AddFinalRank(v int) *RankOverrideUpdate

AddFinalRank adds value to the "final_rank" field.

func (*RankOverrideUpdate) AppendEvidenceIds

func (_u *RankOverrideUpdate) AppendEvidenceIds(v []string) *RankOverrideUpdate

AppendEvidenceIds appends value to the "evidence_ids" field.

func (*RankOverrideUpdate) ClearEvidenceIds

func (_u *RankOverrideUpdate) ClearEvidenceIds() *RankOverrideUpdate

ClearEvidenceIds clears the value of the "evidence_ids" field.

func (*RankOverrideUpdate) Exec

func (_u *RankOverrideUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*RankOverrideUpdate) ExecX

func (_u *RankOverrideUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*RankOverrideUpdate) Mutation

func (_u *RankOverrideUpdate) Mutation() *RankOverrideMutation

Mutation returns the RankOverrideMutation object of the builder.

func (*RankOverrideUpdate) Save

func (_u *RankOverrideUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*RankOverrideUpdate) SaveX

func (_u *RankOverrideUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*RankOverrideUpdate) SetApprovedBy

func (_u *RankOverrideUpdate) SetApprovedBy(v string) *RankOverrideUpdate

SetApprovedBy sets the "approved_by" field.

func (*RankOverrideUpdate) SetEvidenceIds

func (_u *RankOverrideUpdate) SetEvidenceIds(v []string) *RankOverrideUpdate

SetEvidenceIds sets the "evidence_ids" field.

func (*RankOverrideUpdate) SetFinalRank

func (_u *RankOverrideUpdate) SetFinalRank(v int) *RankOverrideUpdate

SetFinalRank sets the "final_rank" field.

func (*RankOverrideUpdate) SetNillableApprovedBy

func (_u *RankOverrideUpdate) SetNillableApprovedBy(v *string) *RankOverrideUpdate

SetNillableApprovedBy sets the "approved_by" field if the given value is not nil.

func (*RankOverrideUpdate) SetNillableFinalRank

func (_u *RankOverrideUpdate) SetNillableFinalRank(v *int) *RankOverrideUpdate

SetNillableFinalRank sets the "final_rank" field if the given value is not nil.

func (*RankOverrideUpdate) SetNillableRationale

func (_u *RankOverrideUpdate) SetNillableRationale(v *string) *RankOverrideUpdate

SetNillableRationale sets the "rationale" field if the given value is not nil.

func (*RankOverrideUpdate) SetRationale

func (_u *RankOverrideUpdate) SetRationale(v string) *RankOverrideUpdate

SetRationale sets the "rationale" field.

func (*RankOverrideUpdate) SetUpdatedAt

func (_u *RankOverrideUpdate) SetUpdatedAt(v time.Time) *RankOverrideUpdate

SetUpdatedAt sets the "updated_at" field.

func (*RankOverrideUpdate) Where

Where appends a list predicates to the RankOverrideUpdate builder.

type RankOverrideUpdateOne

type RankOverrideUpdateOne struct {
	// contains filtered or unexported fields
}

RankOverrideUpdateOne is the builder for updating a single RankOverride entity.

func (*RankOverrideUpdateOne) AddFinalRank

func (_u *RankOverrideUpdateOne) AddFinalRank(v int) *RankOverrideUpdateOne

AddFinalRank adds value to the "final_rank" field.

func (*RankOverrideUpdateOne) AppendEvidenceIds

func (_u *RankOverrideUpdateOne) AppendEvidenceIds(v []string) *RankOverrideUpdateOne

AppendEvidenceIds appends value to the "evidence_ids" field.

func (*RankOverrideUpdateOne) ClearEvidenceIds

func (_u *RankOverrideUpdateOne) ClearEvidenceIds() *RankOverrideUpdateOne

ClearEvidenceIds clears the value of the "evidence_ids" field.

func (*RankOverrideUpdateOne) Exec

Exec executes the query on the entity.

func (*RankOverrideUpdateOne) ExecX

func (_u *RankOverrideUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*RankOverrideUpdateOne) Mutation

Mutation returns the RankOverrideMutation object of the builder.

func (*RankOverrideUpdateOne) Save

Save executes the query and returns the updated RankOverride entity.

func (*RankOverrideUpdateOne) SaveX

SaveX is like Save, but panics if an error occurs.

func (*RankOverrideUpdateOne) Select

func (_u *RankOverrideUpdateOne) Select(field string, fields ...string) *RankOverrideUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*RankOverrideUpdateOne) SetApprovedBy

func (_u *RankOverrideUpdateOne) SetApprovedBy(v string) *RankOverrideUpdateOne

SetApprovedBy sets the "approved_by" field.

func (*RankOverrideUpdateOne) SetEvidenceIds

func (_u *RankOverrideUpdateOne) SetEvidenceIds(v []string) *RankOverrideUpdateOne

SetEvidenceIds sets the "evidence_ids" field.

func (*RankOverrideUpdateOne) SetFinalRank

func (_u *RankOverrideUpdateOne) SetFinalRank(v int) *RankOverrideUpdateOne

SetFinalRank sets the "final_rank" field.

func (*RankOverrideUpdateOne) SetNillableApprovedBy

func (_u *RankOverrideUpdateOne) SetNillableApprovedBy(v *string) *RankOverrideUpdateOne

SetNillableApprovedBy sets the "approved_by" field if the given value is not nil.

func (*RankOverrideUpdateOne) SetNillableFinalRank

func (_u *RankOverrideUpdateOne) SetNillableFinalRank(v *int) *RankOverrideUpdateOne

SetNillableFinalRank sets the "final_rank" field if the given value is not nil.

func (*RankOverrideUpdateOne) SetNillableRationale

func (_u *RankOverrideUpdateOne) SetNillableRationale(v *string) *RankOverrideUpdateOne

SetNillableRationale sets the "rationale" field if the given value is not nil.

func (*RankOverrideUpdateOne) SetRationale

func (_u *RankOverrideUpdateOne) SetRationale(v string) *RankOverrideUpdateOne

SetRationale sets the "rationale" field.

func (*RankOverrideUpdateOne) SetUpdatedAt

SetUpdatedAt sets the "updated_at" field.

func (*RankOverrideUpdateOne) Where

Where appends a list predicates to the RankOverrideUpdate builder.

type RankOverrideUpsert

type RankOverrideUpsert struct {
	*sql.UpdateSet
}

RankOverrideUpsert is the "OnConflict" setter.

func (*RankOverrideUpsert) AddFinalRank

func (u *RankOverrideUpsert) AddFinalRank(v int) *RankOverrideUpsert

AddFinalRank adds v to the "final_rank" field.

func (*RankOverrideUpsert) ClearEvidenceIds

func (u *RankOverrideUpsert) ClearEvidenceIds() *RankOverrideUpsert

ClearEvidenceIds clears the value of the "evidence_ids" field.

func (*RankOverrideUpsert) SetApprovedBy

func (u *RankOverrideUpsert) SetApprovedBy(v string) *RankOverrideUpsert

SetApprovedBy sets the "approved_by" field.

func (*RankOverrideUpsert) SetEvidenceIds

func (u *RankOverrideUpsert) SetEvidenceIds(v []string) *RankOverrideUpsert

SetEvidenceIds sets the "evidence_ids" field.

func (*RankOverrideUpsert) SetFinalRank

func (u *RankOverrideUpsert) SetFinalRank(v int) *RankOverrideUpsert

SetFinalRank sets the "final_rank" field.

func (*RankOverrideUpsert) SetRationale

func (u *RankOverrideUpsert) SetRationale(v string) *RankOverrideUpsert

SetRationale sets the "rationale" field.

func (*RankOverrideUpsert) SetUpdatedAt

func (u *RankOverrideUpsert) SetUpdatedAt(v time.Time) *RankOverrideUpsert

SetUpdatedAt sets the "updated_at" field.

func (*RankOverrideUpsert) UpdateApprovedBy

func (u *RankOverrideUpsert) UpdateApprovedBy() *RankOverrideUpsert

UpdateApprovedBy sets the "approved_by" field to the value that was provided on create.

func (*RankOverrideUpsert) UpdateEvidenceIds

func (u *RankOverrideUpsert) UpdateEvidenceIds() *RankOverrideUpsert

UpdateEvidenceIds sets the "evidence_ids" field to the value that was provided on create.

func (*RankOverrideUpsert) UpdateFinalRank

func (u *RankOverrideUpsert) UpdateFinalRank() *RankOverrideUpsert

UpdateFinalRank sets the "final_rank" field to the value that was provided on create.

func (*RankOverrideUpsert) UpdateRationale

func (u *RankOverrideUpsert) UpdateRationale() *RankOverrideUpsert

UpdateRationale sets the "rationale" field to the value that was provided on create.

func (*RankOverrideUpsert) UpdateUpdatedAt

func (u *RankOverrideUpsert) UpdateUpdatedAt() *RankOverrideUpsert

UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.

type RankOverrideUpsertBulk

type RankOverrideUpsertBulk struct {
	// contains filtered or unexported fields
}

RankOverrideUpsertBulk is the builder for "upsert"-ing a bulk of RankOverride nodes.

func (*RankOverrideUpsertBulk) AddFinalRank

AddFinalRank adds v to the "final_rank" field.

func (*RankOverrideUpsertBulk) ClearEvidenceIds

func (u *RankOverrideUpsertBulk) ClearEvidenceIds() *RankOverrideUpsertBulk

ClearEvidenceIds clears the value of the "evidence_ids" field.

func (*RankOverrideUpsertBulk) DoNothing

DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.

func (*RankOverrideUpsertBulk) Exec

Exec executes the query.

func (*RankOverrideUpsertBulk) ExecX

func (u *RankOverrideUpsertBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*RankOverrideUpsertBulk) Ignore

Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:

client.RankOverride.Create().
	OnConflict(sql.ResolveWithIgnore()).
	Exec(ctx)

func (*RankOverrideUpsertBulk) SetApprovedBy

SetApprovedBy sets the "approved_by" field.

func (*RankOverrideUpsertBulk) SetEvidenceIds

func (u *RankOverrideUpsertBulk) SetEvidenceIds(v []string) *RankOverrideUpsertBulk

SetEvidenceIds sets the "evidence_ids" field.

func (*RankOverrideUpsertBulk) SetFinalRank

SetFinalRank sets the "final_rank" field.

func (*RankOverrideUpsertBulk) SetRationale

SetRationale sets the "rationale" field.

func (*RankOverrideUpsertBulk) SetUpdatedAt

SetUpdatedAt sets the "updated_at" field.

func (*RankOverrideUpsertBulk) Update

Update allows overriding fields `UPDATE` values. See the RankOverrideCreateBulk.OnConflict documentation for more info.

func (*RankOverrideUpsertBulk) UpdateApprovedBy

func (u *RankOverrideUpsertBulk) UpdateApprovedBy() *RankOverrideUpsertBulk

UpdateApprovedBy sets the "approved_by" field to the value that was provided on create.

func (*RankOverrideUpsertBulk) UpdateEvidenceIds

func (u *RankOverrideUpsertBulk) UpdateEvidenceIds() *RankOverrideUpsertBulk

UpdateEvidenceIds sets the "evidence_ids" field to the value that was provided on create.

func (*RankOverrideUpsertBulk) UpdateFinalRank

func (u *RankOverrideUpsertBulk) UpdateFinalRank() *RankOverrideUpsertBulk

UpdateFinalRank sets the "final_rank" field to the value that was provided on create.

func (*RankOverrideUpsertBulk) UpdateNewValues

func (u *RankOverrideUpsertBulk) UpdateNewValues() *RankOverrideUpsertBulk

UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:

client.RankOverride.Create().
	OnConflict(
		sql.ResolveWithNewValues(),
		sql.ResolveWith(func(u *sql.UpdateSet) {
			u.SetIgnore(rankoverride.FieldID)
		}),
	).
	Exec(ctx)

func (*RankOverrideUpsertBulk) UpdateRationale

func (u *RankOverrideUpsertBulk) UpdateRationale() *RankOverrideUpsertBulk

UpdateRationale sets the "rationale" field to the value that was provided on create.

func (*RankOverrideUpsertBulk) UpdateUpdatedAt

func (u *RankOverrideUpsertBulk) UpdateUpdatedAt() *RankOverrideUpsertBulk

UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.

type RankOverrideUpsertOne

type RankOverrideUpsertOne struct {
	// contains filtered or unexported fields
}

RankOverrideUpsertOne is the builder for "upsert"-ing

one RankOverride node.

func (*RankOverrideUpsertOne) AddFinalRank

func (u *RankOverrideUpsertOne) AddFinalRank(v int) *RankOverrideUpsertOne

AddFinalRank adds v to the "final_rank" field.

func (*RankOverrideUpsertOne) ClearEvidenceIds

func (u *RankOverrideUpsertOne) ClearEvidenceIds() *RankOverrideUpsertOne

ClearEvidenceIds clears the value of the "evidence_ids" field.

func (*RankOverrideUpsertOne) DoNothing

DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.

func (*RankOverrideUpsertOne) Exec

Exec executes the query.

func (*RankOverrideUpsertOne) ExecX

func (u *RankOverrideUpsertOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*RankOverrideUpsertOne) ID

func (u *RankOverrideUpsertOne) ID(ctx context.Context) (id string, err error)

Exec executes the UPSERT query and returns the inserted/updated ID.

func (*RankOverrideUpsertOne) IDX

IDX is like ID, but panics if an error occurs.

func (*RankOverrideUpsertOne) Ignore

Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:

client.RankOverride.Create().
    OnConflict(sql.ResolveWithIgnore()).
    Exec(ctx)

func (*RankOverrideUpsertOne) SetApprovedBy

func (u *RankOverrideUpsertOne) SetApprovedBy(v string) *RankOverrideUpsertOne

SetApprovedBy sets the "approved_by" field.

func (*RankOverrideUpsertOne) SetEvidenceIds

func (u *RankOverrideUpsertOne) SetEvidenceIds(v []string) *RankOverrideUpsertOne

SetEvidenceIds sets the "evidence_ids" field.

func (*RankOverrideUpsertOne) SetFinalRank

func (u *RankOverrideUpsertOne) SetFinalRank(v int) *RankOverrideUpsertOne

SetFinalRank sets the "final_rank" field.

func (*RankOverrideUpsertOne) SetRationale

SetRationale sets the "rationale" field.

func (*RankOverrideUpsertOne) SetUpdatedAt

SetUpdatedAt sets the "updated_at" field.

func (*RankOverrideUpsertOne) Update

Update allows overriding fields `UPDATE` values. See the RankOverrideCreate.OnConflict documentation for more info.

func (*RankOverrideUpsertOne) UpdateApprovedBy

func (u *RankOverrideUpsertOne) UpdateApprovedBy() *RankOverrideUpsertOne

UpdateApprovedBy sets the "approved_by" field to the value that was provided on create.

func (*RankOverrideUpsertOne) UpdateEvidenceIds

func (u *RankOverrideUpsertOne) UpdateEvidenceIds() *RankOverrideUpsertOne

UpdateEvidenceIds sets the "evidence_ids" field to the value that was provided on create.

func (*RankOverrideUpsertOne) UpdateFinalRank

func (u *RankOverrideUpsertOne) UpdateFinalRank() *RankOverrideUpsertOne

UpdateFinalRank sets the "final_rank" field to the value that was provided on create.

func (*RankOverrideUpsertOne) UpdateNewValues

func (u *RankOverrideUpsertOne) UpdateNewValues() *RankOverrideUpsertOne

UpdateNewValues updates the mutable fields using the new values that were set on create except the ID field. Using this option is equivalent to using:

client.RankOverride.Create().
	OnConflict(
		sql.ResolveWithNewValues(),
		sql.ResolveWith(func(u *sql.UpdateSet) {
			u.SetIgnore(rankoverride.FieldID)
		}),
	).
	Exec(ctx)

func (*RankOverrideUpsertOne) UpdateRationale

func (u *RankOverrideUpsertOne) UpdateRationale() *RankOverrideUpsertOne

UpdateRationale sets the "rationale" field to the value that was provided on create.

func (*RankOverrideUpsertOne) UpdateUpdatedAt

func (u *RankOverrideUpsertOne) UpdateUpdatedAt() *RankOverrideUpsertOne

UpdateUpdatedAt sets the "updated_at" field to the value that was provided on create.

type RankOverrides

type RankOverrides []*RankOverride

RankOverrides is a parsable slice of RankOverride.

type Release

type Release struct {

	// ID of the ent.
	ID string `json:"id,omitempty"`
	// Provider holds the value of the "provider" field.
	Provider string `json:"provider,omitempty"`
	// SourceID holds the value of the "source_id" field.
	SourceID string `json:"source_id,omitempty"`
	// SourceRef holds the value of the "source_ref" field.
	SourceRef string `json:"source_ref,omitempty"`
	// SourceURL holds the value of the "source_url" field.
	SourceURL string `json:"source_url,omitempty"`
	// Name holds the value of the "name" field.
	Name string `json:"name,omitempty"`
	// StartDate holds the value of the "start_date" field.
	StartDate *time.Time `json:"start_date,omitempty"`
	// ReleaseDate holds the value of the "release_date" field.
	ReleaseDate *time.Time `json:"release_date,omitempty"`
	// Released holds the value of the "released" field.
	Released bool `json:"released,omitempty"`
	// StatusID holds the value of the "status_id" field.
	StatusID string `json:"status_id,omitempty"`
	// StatusName holds the value of the "status_name" field.
	StatusName string `json:"status_name,omitempty"`
	// StatusCategory holds the value of the "status_category" field.
	StatusCategory string `json:"status_category,omitempty"`
	// Progress holds the value of the "progress" field.
	Progress *float64 `json:"progress,omitempty"`
	// Metadata holds the value of the "metadata" field.
	Metadata map[string]interface{} `json:"metadata,omitempty"`
	// SyncedAt holds the value of the "synced_at" field.
	SyncedAt time.Time `json:"synced_at,omitempty"`
	// contains filtered or unexported fields
}

Release is the model entity for the Release schema.

func (*Release) String

func (_m *Release) String() string

String implements the fmt.Stringer.

func (*Release) Unwrap

func (_m *Release) Unwrap() *Release

Unwrap unwraps the Release entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*Release) Update

func (_m *Release) Update() *ReleaseUpdateOne

Update returns a builder for updating this Release. Note that you need to call Release.Unwrap() before calling this method if this Release was returned from a transaction, and the transaction was committed or rolled back.

func (*Release) Value

func (_m *Release) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the Release. This includes values selected through modifiers, order, etc.

type ReleaseClient

type ReleaseClient struct {
	// contains filtered or unexported fields
}

ReleaseClient is a client for the Release schema.

func NewReleaseClient

func NewReleaseClient(c config) *ReleaseClient

NewReleaseClient returns a client for the Release from the given config.

func (*ReleaseClient) Create

func (c *ReleaseClient) Create() *ReleaseCreate

Create returns a builder for creating a Release entity.

func (*ReleaseClient) CreateBulk

func (c *ReleaseClient) CreateBulk(builders ...*ReleaseCreate) *ReleaseCreateBulk

CreateBulk returns a builder for creating a bulk of Release entities.

func (*ReleaseClient) Delete

func (c *ReleaseClient) Delete() *ReleaseDelete

Delete returns a delete builder for Release.

func (*ReleaseClient) DeleteOne

func (c *ReleaseClient) DeleteOne(_m *Release) *ReleaseDeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*ReleaseClient) DeleteOneID

func (c *ReleaseClient) DeleteOneID(id string) *ReleaseDeleteOne

DeleteOneID returns a builder for deleting the given entity by its id.

func (*ReleaseClient) Get

func (c *ReleaseClient) Get(ctx context.Context, id string) (*Release, error)

Get returns a Release entity by its id.

func (*ReleaseClient) GetX

func (c *ReleaseClient) GetX(ctx context.Context, id string) *Release

GetX is like Get, but panics if an error occurs.

func (*ReleaseClient) Hooks

func (c *ReleaseClient) Hooks() []Hook

Hooks returns the client hooks.

func (*ReleaseClient) Intercept

func (c *ReleaseClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `release.Intercept(f(g(h())))`.

func (*ReleaseClient) Interceptors

func (c *ReleaseClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*ReleaseClient) MapCreateBulk

func (c *ReleaseClient) MapCreateBulk(slice any, setFunc func(*ReleaseCreate, int)) *ReleaseCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*ReleaseClient) Query

func (c *ReleaseClient) Query() *ReleaseQuery

Query returns a query builder for Release.

func (*ReleaseClient) Update

func (c *ReleaseClient) Update() *ReleaseUpdate

Update returns an update builder for Release.

func (*ReleaseClient) UpdateOne

func (c *ReleaseClient) UpdateOne(_m *Release) *ReleaseUpdateOne

UpdateOne returns an update builder for the given entity.

func (*ReleaseClient) UpdateOneID

func (c *ReleaseClient) UpdateOneID(id string) *ReleaseUpdateOne

UpdateOneID returns an update builder for the given id.

func (*ReleaseClient) Use

func (c *ReleaseClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `release.Hooks(f(g(h())))`.

type ReleaseCreate

type ReleaseCreate struct {
	// contains filtered or unexported fields
}

ReleaseCreate is the builder for creating a Release entity.

func (*ReleaseCreate) Exec

func (_c *ReleaseCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*ReleaseCreate) ExecX

func (_c *ReleaseCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ReleaseCreate) Mutation

func (_c *ReleaseCreate) Mutation() *ReleaseMutation

Mutation returns the ReleaseMutation object of the builder.

func (*ReleaseCreate) OnConflict

func (_c *ReleaseCreate) OnConflict(opts ...sql.ConflictOption) *ReleaseUpsertOne

OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:

client.Release.Create().
	SetProvider(v).
	OnConflict(
		// Update the row with the new values
		// the was proposed for insertion.
		sql.ResolveWithNewValues(),
	).
	// Override some of the fields with custom
	// update values.
	Update(func(u *ent.ReleaseUpsert) {
		SetProvider(v+v).
	}).
	Exec(ctx)

func (*ReleaseCreate) OnConflictColumns

func (_c *ReleaseCreate) OnConflictColumns(columns ...string) *ReleaseUpsertOne

OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:

client.Release.Create().
	OnConflict(sql.ConflictColumns(columns...)).
	Exec(ctx)

func (*ReleaseCreate) Save

func (_c *ReleaseCreate) Save(ctx context.Context) (*Release, error)

Save creates the Release in the database.

func (*ReleaseCreate) SaveX

func (_c *ReleaseCreate) SaveX(ctx context.Context) *Release

SaveX calls Save and panics if Save returns an error.

func (*ReleaseCreate) SetID

func (_c *ReleaseCreate) SetID(v string) *ReleaseCreate

SetID sets the "id" field.

func (*ReleaseCreate) SetMetadata

func (_c *ReleaseCreate) SetMetadata(v map[string]interface{}) *ReleaseCreate

SetMetadata sets the "metadata" field.

func (*ReleaseCreate) SetName

func (_c *ReleaseCreate) SetName(v string) *ReleaseCreate

SetName sets the "name" field.

func (*ReleaseCreate) SetNillableName

func (_c *ReleaseCreate) SetNillableName(v *string) *ReleaseCreate

SetNillableName sets the "name" field if the given value is not nil.

func (*ReleaseCreate) SetNillableProgress

func (_c *ReleaseCreate) SetNillableProgress(v *float64) *ReleaseCreate

SetNillableProgress sets the "progress" field if the given value is not nil.

func (*ReleaseCreate) SetNillableReleaseDate

func (_c *ReleaseCreate) SetNillableReleaseDate(v *time.Time) *ReleaseCreate

SetNillableReleaseDate sets the "release_date" field if the given value is not nil.

func (*ReleaseCreate) SetNillableReleased

func (_c *ReleaseCreate) SetNillableReleased(v *bool) *ReleaseCreate

SetNillableReleased sets the "released" field if the given value is not nil.

func (*ReleaseCreate) SetNillableSourceRef

func (_c *ReleaseCreate) SetNillableSourceRef(v *string) *ReleaseCreate

SetNillableSourceRef sets the "source_ref" field if the given value is not nil.

func (*ReleaseCreate) SetNillableSourceURL

func (_c *ReleaseCreate) SetNillableSourceURL(v *string) *ReleaseCreate

SetNillableSourceURL sets the "source_url" field if the given value is not nil.

func (*ReleaseCreate) SetNillableStartDate

func (_c *ReleaseCreate) SetNillableStartDate(v *time.Time) *ReleaseCreate

SetNillableStartDate sets the "start_date" field if the given value is not nil.

func (*ReleaseCreate) SetNillableStatusCategory

func (_c *ReleaseCreate) SetNillableStatusCategory(v *string) *ReleaseCreate

SetNillableStatusCategory sets the "status_category" field if the given value is not nil.

func (*ReleaseCreate) SetNillableStatusID

func (_c *ReleaseCreate) SetNillableStatusID(v *string) *ReleaseCreate

SetNillableStatusID sets the "status_id" field if the given value is not nil.

func (*ReleaseCreate) SetNillableStatusName

func (_c *ReleaseCreate) SetNillableStatusName(v *string) *ReleaseCreate

SetNillableStatusName sets the "status_name" field if the given value is not nil.

func (*ReleaseCreate) SetNillableSyncedAt

func (_c *ReleaseCreate) SetNillableSyncedAt(v *time.Time) *ReleaseCreate

SetNillableSyncedAt sets the "synced_at" field if the given value is not nil.

func (*ReleaseCreate) SetProgress

func (_c *ReleaseCreate) SetProgress(v float64) *ReleaseCreate

SetProgress sets the "progress" field.

func (*ReleaseCreate) SetProvider

func (_c *ReleaseCreate) SetProvider(v string) *ReleaseCreate

SetProvider sets the "provider" field.

func (*ReleaseCreate) SetReleaseDate

func (_c *ReleaseCreate) SetReleaseDate(v time.Time) *ReleaseCreate

SetReleaseDate sets the "release_date" field.

func (*ReleaseCreate) SetReleased

func (_c *ReleaseCreate) SetReleased(v bool) *ReleaseCreate

SetReleased sets the "released" field.

func (*ReleaseCreate) SetSourceID

func (_c *ReleaseCreate) SetSourceID(v string) *ReleaseCreate

SetSourceID sets the "source_id" field.

func (*ReleaseCreate) SetSourceRef

func (_c *ReleaseCreate) SetSourceRef(v string) *ReleaseCreate

SetSourceRef sets the "source_ref" field.

func (*ReleaseCreate) SetSourceURL

func (_c *ReleaseCreate) SetSourceURL(v string) *ReleaseCreate

SetSourceURL sets the "source_url" field.

func (*ReleaseCreate) SetStartDate

func (_c *ReleaseCreate) SetStartDate(v time.Time) *ReleaseCreate

SetStartDate sets the "start_date" field.

func (*ReleaseCreate) SetStatusCategory

func (_c *ReleaseCreate) SetStatusCategory(v string) *ReleaseCreate

SetStatusCategory sets the "status_category" field.

func (*ReleaseCreate) SetStatusID

func (_c *ReleaseCreate) SetStatusID(v string) *ReleaseCreate

SetStatusID sets the "status_id" field.

func (*ReleaseCreate) SetStatusName

func (_c *ReleaseCreate) SetStatusName(v string) *ReleaseCreate

SetStatusName sets the "status_name" field.

func (*ReleaseCreate) SetSyncedAt

func (_c *ReleaseCreate) SetSyncedAt(v time.Time) *ReleaseCreate

SetSyncedAt sets the "synced_at" field.

type ReleaseCreateBulk

type ReleaseCreateBulk struct {
	// contains filtered or unexported fields
}

ReleaseCreateBulk is the builder for creating many Release entities in bulk.

func (*ReleaseCreateBulk) Exec

func (_c *ReleaseCreateBulk) Exec(ctx context.Context) error

Exec executes the query.

func (*ReleaseCreateBulk) ExecX

func (_c *ReleaseCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ReleaseCreateBulk) OnConflict

func (_c *ReleaseCreateBulk) OnConflict(opts ...sql.ConflictOption) *ReleaseUpsertBulk

OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:

client.Release.CreateBulk(builders...).
	OnConflict(
		// Update the row with the new values
		// the was proposed for insertion.
		sql.ResolveWithNewValues(),
	).
	// Override some of the fields with custom
	// update values.
	Update(func(u *ent.ReleaseUpsert) {
		SetProvider(v+v).
	}).
	Exec(ctx)

func (*ReleaseCreateBulk) OnConflictColumns

func (_c *ReleaseCreateBulk) OnConflictColumns(columns ...string) *ReleaseUpsertBulk

OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:

client.Release.Create().
	OnConflict(sql.ConflictColumns(columns...)).
	Exec(ctx)

func (*ReleaseCreateBulk) Save

func (_c *ReleaseCreateBulk) Save(ctx context.Context) ([]*Release, error)

Save creates the Release entities in the database.

func (*ReleaseCreateBulk) SaveX

func (_c *ReleaseCreateBulk) SaveX(ctx context.Context) []*Release

SaveX is like Save, but panics if an error occurs.

type ReleaseDelete

type ReleaseDelete struct {
	// contains filtered or unexported fields
}

ReleaseDelete is the builder for deleting a Release entity.

func (*ReleaseDelete) Exec

func (_d *ReleaseDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*ReleaseDelete) ExecX

func (_d *ReleaseDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*ReleaseDelete) Where

func (_d *ReleaseDelete) Where(ps ...predicate.Release) *ReleaseDelete

Where appends a list predicates to the ReleaseDelete builder.

type ReleaseDeleteOne

type ReleaseDeleteOne struct {
	// contains filtered or unexported fields
}

ReleaseDeleteOne is the builder for deleting a single Release entity.

func (*ReleaseDeleteOne) Exec

func (_d *ReleaseDeleteOne) Exec(ctx context.Context) error

Exec executes the deletion query.

func (*ReleaseDeleteOne) ExecX

func (_d *ReleaseDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ReleaseDeleteOne) Where

Where appends a list predicates to the ReleaseDelete builder.

type ReleaseGroupBy

type ReleaseGroupBy struct {
	// contains filtered or unexported fields
}

ReleaseGroupBy is the group-by builder for Release entities.

func (*ReleaseGroupBy) Aggregate

func (_g *ReleaseGroupBy) Aggregate(fns ...AggregateFunc) *ReleaseGroupBy

Aggregate adds the given aggregation functions to the group-by query.

func (*ReleaseGroupBy) Bool

func (s *ReleaseGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*ReleaseGroupBy) BoolX

func (s *ReleaseGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*ReleaseGroupBy) Bools

func (s *ReleaseGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*ReleaseGroupBy) BoolsX

func (s *ReleaseGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*ReleaseGroupBy) Float64

func (s *ReleaseGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*ReleaseGroupBy) Float64X

func (s *ReleaseGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*ReleaseGroupBy) Float64s

func (s *ReleaseGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*ReleaseGroupBy) Float64sX

func (s *ReleaseGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*ReleaseGroupBy) Int

func (s *ReleaseGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*ReleaseGroupBy) IntX

func (s *ReleaseGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*ReleaseGroupBy) Ints

func (s *ReleaseGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*ReleaseGroupBy) IntsX

func (s *ReleaseGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*ReleaseGroupBy) Scan

func (_g *ReleaseGroupBy) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*ReleaseGroupBy) ScanX

func (s *ReleaseGroupBy) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*ReleaseGroupBy) String

func (s *ReleaseGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*ReleaseGroupBy) StringX

func (s *ReleaseGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*ReleaseGroupBy) Strings

func (s *ReleaseGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*ReleaseGroupBy) StringsX

func (s *ReleaseGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type ReleaseMutation

type ReleaseMutation struct {
	// contains filtered or unexported fields
}

ReleaseMutation represents an operation that mutates the Release nodes in the graph.

func (*ReleaseMutation) AddField

func (m *ReleaseMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*ReleaseMutation) AddProgress

func (m *ReleaseMutation) AddProgress(f float64)

AddProgress adds f to the "progress" field.

func (*ReleaseMutation) AddedEdges

func (m *ReleaseMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*ReleaseMutation) AddedField

func (m *ReleaseMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*ReleaseMutation) AddedFields

func (m *ReleaseMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*ReleaseMutation) AddedIDs

func (m *ReleaseMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*ReleaseMutation) AddedProgress

func (m *ReleaseMutation) AddedProgress() (r float64, exists bool)

AddedProgress returns the value that was added to the "progress" field in this mutation.

func (*ReleaseMutation) ClearEdge

func (m *ReleaseMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*ReleaseMutation) ClearField

func (m *ReleaseMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*ReleaseMutation) ClearMetadata

func (m *ReleaseMutation) ClearMetadata()

ClearMetadata clears the value of the "metadata" field.

func (*ReleaseMutation) ClearName

func (m *ReleaseMutation) ClearName()

ClearName clears the value of the "name" field.

func (*ReleaseMutation) ClearProgress

func (m *ReleaseMutation) ClearProgress()

ClearProgress clears the value of the "progress" field.

func (*ReleaseMutation) ClearReleaseDate

func (m *ReleaseMutation) ClearReleaseDate()

ClearReleaseDate clears the value of the "release_date" field.

func (*ReleaseMutation) ClearSourceRef

func (m *ReleaseMutation) ClearSourceRef()

ClearSourceRef clears the value of the "source_ref" field.

func (*ReleaseMutation) ClearSourceURL

func (m *ReleaseMutation) ClearSourceURL()

ClearSourceURL clears the value of the "source_url" field.

func (*ReleaseMutation) ClearStartDate

func (m *ReleaseMutation) ClearStartDate()

ClearStartDate clears the value of the "start_date" field.

func (*ReleaseMutation) ClearStatusCategory

func (m *ReleaseMutation) ClearStatusCategory()

ClearStatusCategory clears the value of the "status_category" field.

func (*ReleaseMutation) ClearStatusID

func (m *ReleaseMutation) ClearStatusID()

ClearStatusID clears the value of the "status_id" field.

func (*ReleaseMutation) ClearStatusName

func (m *ReleaseMutation) ClearStatusName()

ClearStatusName clears the value of the "status_name" field.

func (*ReleaseMutation) ClearedEdges

func (m *ReleaseMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*ReleaseMutation) ClearedFields

func (m *ReleaseMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (ReleaseMutation) Client

func (m ReleaseMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*ReleaseMutation) EdgeCleared

func (m *ReleaseMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*ReleaseMutation) Field

func (m *ReleaseMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*ReleaseMutation) FieldCleared

func (m *ReleaseMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*ReleaseMutation) Fields

func (m *ReleaseMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*ReleaseMutation) ID

func (m *ReleaseMutation) ID() (id string, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*ReleaseMutation) IDs

func (m *ReleaseMutation) IDs(ctx context.Context) ([]string, error)

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*ReleaseMutation) Metadata

func (m *ReleaseMutation) Metadata() (r map[string]interface{}, exists bool)

Metadata returns the value of the "metadata" field in the mutation.

func (*ReleaseMutation) MetadataCleared

func (m *ReleaseMutation) MetadataCleared() bool

MetadataCleared returns if the "metadata" field was cleared in this mutation.

func (*ReleaseMutation) Name

func (m *ReleaseMutation) Name() (r string, exists bool)

Name returns the value of the "name" field in the mutation.

func (*ReleaseMutation) NameCleared

func (m *ReleaseMutation) NameCleared() bool

NameCleared returns if the "name" field was cleared in this mutation.

func (*ReleaseMutation) OldField

func (m *ReleaseMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*ReleaseMutation) OldMetadata

func (m *ReleaseMutation) OldMetadata(ctx context.Context) (v map[string]interface{}, err error)

OldMetadata returns the old "metadata" field's value of the Release entity. If the Release object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ReleaseMutation) OldName

func (m *ReleaseMutation) OldName(ctx context.Context) (v string, err error)

OldName returns the old "name" field's value of the Release entity. If the Release object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ReleaseMutation) OldProgress

func (m *ReleaseMutation) OldProgress(ctx context.Context) (v *float64, err error)

OldProgress returns the old "progress" field's value of the Release entity. If the Release object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ReleaseMutation) OldProvider

func (m *ReleaseMutation) OldProvider(ctx context.Context) (v string, err error)

OldProvider returns the old "provider" field's value of the Release entity. If the Release object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ReleaseMutation) OldReleaseDate

func (m *ReleaseMutation) OldReleaseDate(ctx context.Context) (v *time.Time, err error)

OldReleaseDate returns the old "release_date" field's value of the Release entity. If the Release object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ReleaseMutation) OldReleased

func (m *ReleaseMutation) OldReleased(ctx context.Context) (v bool, err error)

OldReleased returns the old "released" field's value of the Release entity. If the Release object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ReleaseMutation) OldSourceID

func (m *ReleaseMutation) OldSourceID(ctx context.Context) (v string, err error)

OldSourceID returns the old "source_id" field's value of the Release entity. If the Release object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ReleaseMutation) OldSourceRef

func (m *ReleaseMutation) OldSourceRef(ctx context.Context) (v string, err error)

OldSourceRef returns the old "source_ref" field's value of the Release entity. If the Release object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ReleaseMutation) OldSourceURL

func (m *ReleaseMutation) OldSourceURL(ctx context.Context) (v string, err error)

OldSourceURL returns the old "source_url" field's value of the Release entity. If the Release object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ReleaseMutation) OldStartDate

func (m *ReleaseMutation) OldStartDate(ctx context.Context) (v *time.Time, err error)

OldStartDate returns the old "start_date" field's value of the Release entity. If the Release object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ReleaseMutation) OldStatusCategory

func (m *ReleaseMutation) OldStatusCategory(ctx context.Context) (v string, err error)

OldStatusCategory returns the old "status_category" field's value of the Release entity. If the Release object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ReleaseMutation) OldStatusID

func (m *ReleaseMutation) OldStatusID(ctx context.Context) (v string, err error)

OldStatusID returns the old "status_id" field's value of the Release entity. If the Release object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ReleaseMutation) OldStatusName

func (m *ReleaseMutation) OldStatusName(ctx context.Context) (v string, err error)

OldStatusName returns the old "status_name" field's value of the Release entity. If the Release object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ReleaseMutation) OldSyncedAt

func (m *ReleaseMutation) OldSyncedAt(ctx context.Context) (v time.Time, err error)

OldSyncedAt returns the old "synced_at" field's value of the Release entity. If the Release object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ReleaseMutation) Op

func (m *ReleaseMutation) Op() Op

Op returns the operation name.

func (*ReleaseMutation) Progress

func (m *ReleaseMutation) Progress() (r float64, exists bool)

Progress returns the value of the "progress" field in the mutation.

func (*ReleaseMutation) ProgressCleared

func (m *ReleaseMutation) ProgressCleared() bool

ProgressCleared returns if the "progress" field was cleared in this mutation.

func (*ReleaseMutation) Provider

func (m *ReleaseMutation) Provider() (r string, exists bool)

Provider returns the value of the "provider" field in the mutation.

func (*ReleaseMutation) ReleaseDate

func (m *ReleaseMutation) ReleaseDate() (r time.Time, exists bool)

ReleaseDate returns the value of the "release_date" field in the mutation.

func (*ReleaseMutation) ReleaseDateCleared

func (m *ReleaseMutation) ReleaseDateCleared() bool

ReleaseDateCleared returns if the "release_date" field was cleared in this mutation.

func (*ReleaseMutation) Released

func (m *ReleaseMutation) Released() (r bool, exists bool)

Released returns the value of the "released" field in the mutation.

func (*ReleaseMutation) RemovedEdges

func (m *ReleaseMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*ReleaseMutation) RemovedIDs

func (m *ReleaseMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*ReleaseMutation) ResetEdge

func (m *ReleaseMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*ReleaseMutation) ResetField

func (m *ReleaseMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*ReleaseMutation) ResetMetadata

func (m *ReleaseMutation) ResetMetadata()

ResetMetadata resets all changes to the "metadata" field.

func (*ReleaseMutation) ResetName

func (m *ReleaseMutation) ResetName()

ResetName resets all changes to the "name" field.

func (*ReleaseMutation) ResetProgress

func (m *ReleaseMutation) ResetProgress()

ResetProgress resets all changes to the "progress" field.

func (*ReleaseMutation) ResetProvider

func (m *ReleaseMutation) ResetProvider()

ResetProvider resets all changes to the "provider" field.

func (*ReleaseMutation) ResetReleaseDate

func (m *ReleaseMutation) ResetReleaseDate()

ResetReleaseDate resets all changes to the "release_date" field.

func (*ReleaseMutation) ResetReleased

func (m *ReleaseMutation) ResetReleased()

ResetReleased resets all changes to the "released" field.

func (*ReleaseMutation) ResetSourceID

func (m *ReleaseMutation) ResetSourceID()

ResetSourceID resets all changes to the "source_id" field.

func (*ReleaseMutation) ResetSourceRef

func (m *ReleaseMutation) ResetSourceRef()

ResetSourceRef resets all changes to the "source_ref" field.

func (*ReleaseMutation) ResetSourceURL

func (m *ReleaseMutation) ResetSourceURL()

ResetSourceURL resets all changes to the "source_url" field.

func (*ReleaseMutation) ResetStartDate

func (m *ReleaseMutation) ResetStartDate()

ResetStartDate resets all changes to the "start_date" field.

func (*ReleaseMutation) ResetStatusCategory

func (m *ReleaseMutation) ResetStatusCategory()

ResetStatusCategory resets all changes to the "status_category" field.

func (*ReleaseMutation) ResetStatusID

func (m *ReleaseMutation) ResetStatusID()

ResetStatusID resets all changes to the "status_id" field.

func (*ReleaseMutation) ResetStatusName

func (m *ReleaseMutation) ResetStatusName()

ResetStatusName resets all changes to the "status_name" field.

func (*ReleaseMutation) ResetSyncedAt

func (m *ReleaseMutation) ResetSyncedAt()

ResetSyncedAt resets all changes to the "synced_at" field.

func (*ReleaseMutation) SetField

func (m *ReleaseMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*ReleaseMutation) SetID

func (m *ReleaseMutation) SetID(id string)

SetID sets the value of the id field. Note that this operation is only accepted on creation of Release entities.

func (*ReleaseMutation) SetMetadata

func (m *ReleaseMutation) SetMetadata(value map[string]interface{})

SetMetadata sets the "metadata" field.

func (*ReleaseMutation) SetName

func (m *ReleaseMutation) SetName(s string)

SetName sets the "name" field.

func (*ReleaseMutation) SetOp

func (m *ReleaseMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*ReleaseMutation) SetProgress

func (m *ReleaseMutation) SetProgress(f float64)

SetProgress sets the "progress" field.

func (*ReleaseMutation) SetProvider

func (m *ReleaseMutation) SetProvider(s string)

SetProvider sets the "provider" field.

func (*ReleaseMutation) SetReleaseDate

func (m *ReleaseMutation) SetReleaseDate(t time.Time)

SetReleaseDate sets the "release_date" field.

func (*ReleaseMutation) SetReleased

func (m *ReleaseMutation) SetReleased(b bool)

SetReleased sets the "released" field.

func (*ReleaseMutation) SetSourceID

func (m *ReleaseMutation) SetSourceID(s string)

SetSourceID sets the "source_id" field.

func (*ReleaseMutation) SetSourceRef

func (m *ReleaseMutation) SetSourceRef(s string)

SetSourceRef sets the "source_ref" field.

func (*ReleaseMutation) SetSourceURL

func (m *ReleaseMutation) SetSourceURL(s string)

SetSourceURL sets the "source_url" field.

func (*ReleaseMutation) SetStartDate

func (m *ReleaseMutation) SetStartDate(t time.Time)

SetStartDate sets the "start_date" field.

func (*ReleaseMutation) SetStatusCategory

func (m *ReleaseMutation) SetStatusCategory(s string)

SetStatusCategory sets the "status_category" field.

func (*ReleaseMutation) SetStatusID

func (m *ReleaseMutation) SetStatusID(s string)

SetStatusID sets the "status_id" field.

func (*ReleaseMutation) SetStatusName

func (m *ReleaseMutation) SetStatusName(s string)

SetStatusName sets the "status_name" field.

func (*ReleaseMutation) SetSyncedAt

func (m *ReleaseMutation) SetSyncedAt(t time.Time)

SetSyncedAt sets the "synced_at" field.

func (*ReleaseMutation) SourceID

func (m *ReleaseMutation) SourceID() (r string, exists bool)

SourceID returns the value of the "source_id" field in the mutation.

func (*ReleaseMutation) SourceRef

func (m *ReleaseMutation) SourceRef() (r string, exists bool)

SourceRef returns the value of the "source_ref" field in the mutation.

func (*ReleaseMutation) SourceRefCleared

func (m *ReleaseMutation) SourceRefCleared() bool

SourceRefCleared returns if the "source_ref" field was cleared in this mutation.

func (*ReleaseMutation) SourceURL

func (m *ReleaseMutation) SourceURL() (r string, exists bool)

SourceURL returns the value of the "source_url" field in the mutation.

func (*ReleaseMutation) SourceURLCleared

func (m *ReleaseMutation) SourceURLCleared() bool

SourceURLCleared returns if the "source_url" field was cleared in this mutation.

func (*ReleaseMutation) StartDate

func (m *ReleaseMutation) StartDate() (r time.Time, exists bool)

StartDate returns the value of the "start_date" field in the mutation.

func (*ReleaseMutation) StartDateCleared

func (m *ReleaseMutation) StartDateCleared() bool

StartDateCleared returns if the "start_date" field was cleared in this mutation.

func (*ReleaseMutation) StatusCategory

func (m *ReleaseMutation) StatusCategory() (r string, exists bool)

StatusCategory returns the value of the "status_category" field in the mutation.

func (*ReleaseMutation) StatusCategoryCleared

func (m *ReleaseMutation) StatusCategoryCleared() bool

StatusCategoryCleared returns if the "status_category" field was cleared in this mutation.

func (*ReleaseMutation) StatusID

func (m *ReleaseMutation) StatusID() (r string, exists bool)

StatusID returns the value of the "status_id" field in the mutation.

func (*ReleaseMutation) StatusIDCleared

func (m *ReleaseMutation) StatusIDCleared() bool

StatusIDCleared returns if the "status_id" field was cleared in this mutation.

func (*ReleaseMutation) StatusName

func (m *ReleaseMutation) StatusName() (r string, exists bool)

StatusName returns the value of the "status_name" field in the mutation.

func (*ReleaseMutation) StatusNameCleared

func (m *ReleaseMutation) StatusNameCleared() bool

StatusNameCleared returns if the "status_name" field was cleared in this mutation.

func (*ReleaseMutation) SyncedAt

func (m *ReleaseMutation) SyncedAt() (r time.Time, exists bool)

SyncedAt returns the value of the "synced_at" field in the mutation.

func (ReleaseMutation) Tx

func (m ReleaseMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*ReleaseMutation) Type

func (m *ReleaseMutation) Type() string

Type returns the node type of this mutation (Release).

func (*ReleaseMutation) Where

func (m *ReleaseMutation) Where(ps ...predicate.Release)

Where appends a list predicates to the ReleaseMutation builder.

func (*ReleaseMutation) WhereP

func (m *ReleaseMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the ReleaseMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

type ReleaseQuery

type ReleaseQuery struct {
	// contains filtered or unexported fields
}

ReleaseQuery is the builder for querying Release entities.

func (*ReleaseQuery) Aggregate

func (_q *ReleaseQuery) Aggregate(fns ...AggregateFunc) *ReleaseSelect

Aggregate returns a ReleaseSelect configured with the given aggregations.

func (*ReleaseQuery) All

func (_q *ReleaseQuery) All(ctx context.Context) ([]*Release, error)

All executes the query and returns a list of Releases.

func (*ReleaseQuery) AllX

func (_q *ReleaseQuery) AllX(ctx context.Context) []*Release

AllX is like All, but panics if an error occurs.

func (*ReleaseQuery) Clone

func (_q *ReleaseQuery) Clone() *ReleaseQuery

Clone returns a duplicate of the ReleaseQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*ReleaseQuery) Count

func (_q *ReleaseQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*ReleaseQuery) CountX

func (_q *ReleaseQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*ReleaseQuery) Exist

func (_q *ReleaseQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*ReleaseQuery) ExistX

func (_q *ReleaseQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*ReleaseQuery) First

func (_q *ReleaseQuery) First(ctx context.Context) (*Release, error)

First returns the first Release entity from the query. Returns a *NotFoundError when no Release was found.

func (*ReleaseQuery) FirstID

func (_q *ReleaseQuery) FirstID(ctx context.Context) (id string, err error)

FirstID returns the first Release ID from the query. Returns a *NotFoundError when no Release ID was found.

func (*ReleaseQuery) FirstIDX

func (_q *ReleaseQuery) FirstIDX(ctx context.Context) string

FirstIDX is like FirstID, but panics if an error occurs.

func (*ReleaseQuery) FirstX

func (_q *ReleaseQuery) FirstX(ctx context.Context) *Release

FirstX is like First, but panics if an error occurs.

func (*ReleaseQuery) GroupBy

func (_q *ReleaseQuery) GroupBy(field string, fields ...string) *ReleaseGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	Provider string `json:"provider,omitempty"`
	Count int `json:"count,omitempty"`
}

client.Release.Query().
	GroupBy(release.FieldProvider).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*ReleaseQuery) IDs

func (_q *ReleaseQuery) IDs(ctx context.Context) (ids []string, err error)

IDs executes the query and returns a list of Release IDs.

func (*ReleaseQuery) IDsX

func (_q *ReleaseQuery) IDsX(ctx context.Context) []string

IDsX is like IDs, but panics if an error occurs.

func (*ReleaseQuery) Limit

func (_q *ReleaseQuery) Limit(limit int) *ReleaseQuery

Limit the number of records to be returned by this query.

func (*ReleaseQuery) Offset

func (_q *ReleaseQuery) Offset(offset int) *ReleaseQuery

Offset to start from.

func (*ReleaseQuery) Only

func (_q *ReleaseQuery) Only(ctx context.Context) (*Release, error)

Only returns a single Release entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one Release entity is found. Returns a *NotFoundError when no Release entities are found.

func (*ReleaseQuery) OnlyID

func (_q *ReleaseQuery) OnlyID(ctx context.Context) (id string, err error)

OnlyID is like Only, but returns the only Release ID in the query. Returns a *NotSingularError when more than one Release ID is found. Returns a *NotFoundError when no entities are found.

func (*ReleaseQuery) OnlyIDX

func (_q *ReleaseQuery) OnlyIDX(ctx context.Context) string

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*ReleaseQuery) OnlyX

func (_q *ReleaseQuery) OnlyX(ctx context.Context) *Release

OnlyX is like Only, but panics if an error occurs.

func (*ReleaseQuery) Order

func (_q *ReleaseQuery) Order(o ...release.OrderOption) *ReleaseQuery

Order specifies how the records should be ordered.

func (*ReleaseQuery) Select

func (_q *ReleaseQuery) Select(fields ...string) *ReleaseSelect

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	Provider string `json:"provider,omitempty"`
}

client.Release.Query().
	Select(release.FieldProvider).
	Scan(ctx, &v)

func (*ReleaseQuery) Unique

func (_q *ReleaseQuery) Unique(unique bool) *ReleaseQuery

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*ReleaseQuery) Where

func (_q *ReleaseQuery) Where(ps ...predicate.Release) *ReleaseQuery

Where adds a new predicate for the ReleaseQuery builder.

type ReleaseSelect

type ReleaseSelect struct {
	*ReleaseQuery
	// contains filtered or unexported fields
}

ReleaseSelect is the builder for selecting fields of Release entities.

func (*ReleaseSelect) Aggregate

func (_s *ReleaseSelect) Aggregate(fns ...AggregateFunc) *ReleaseSelect

Aggregate adds the given aggregation functions to the selector query.

func (*ReleaseSelect) Bool

func (s *ReleaseSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*ReleaseSelect) BoolX

func (s *ReleaseSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*ReleaseSelect) Bools

func (s *ReleaseSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*ReleaseSelect) BoolsX

func (s *ReleaseSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*ReleaseSelect) Float64

func (s *ReleaseSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*ReleaseSelect) Float64X

func (s *ReleaseSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*ReleaseSelect) Float64s

func (s *ReleaseSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*ReleaseSelect) Float64sX

func (s *ReleaseSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*ReleaseSelect) Int

func (s *ReleaseSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*ReleaseSelect) IntX

func (s *ReleaseSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*ReleaseSelect) Ints

func (s *ReleaseSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*ReleaseSelect) IntsX

func (s *ReleaseSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*ReleaseSelect) Scan

func (_s *ReleaseSelect) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*ReleaseSelect) ScanX

func (s *ReleaseSelect) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*ReleaseSelect) String

func (s *ReleaseSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*ReleaseSelect) StringX

func (s *ReleaseSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*ReleaseSelect) Strings

func (s *ReleaseSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*ReleaseSelect) StringsX

func (s *ReleaseSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type ReleaseUpdate

type ReleaseUpdate struct {
	// contains filtered or unexported fields
}

ReleaseUpdate is the builder for updating Release entities.

func (*ReleaseUpdate) AddProgress

func (_u *ReleaseUpdate) AddProgress(v float64) *ReleaseUpdate

AddProgress adds value to the "progress" field.

func (*ReleaseUpdate) ClearMetadata

func (_u *ReleaseUpdate) ClearMetadata() *ReleaseUpdate

ClearMetadata clears the value of the "metadata" field.

func (*ReleaseUpdate) ClearName

func (_u *ReleaseUpdate) ClearName() *ReleaseUpdate

ClearName clears the value of the "name" field.

func (*ReleaseUpdate) ClearProgress

func (_u *ReleaseUpdate) ClearProgress() *ReleaseUpdate

ClearProgress clears the value of the "progress" field.

func (*ReleaseUpdate) ClearReleaseDate

func (_u *ReleaseUpdate) ClearReleaseDate() *ReleaseUpdate

ClearReleaseDate clears the value of the "release_date" field.

func (*ReleaseUpdate) ClearSourceRef

func (_u *ReleaseUpdate) ClearSourceRef() *ReleaseUpdate

ClearSourceRef clears the value of the "source_ref" field.

func (*ReleaseUpdate) ClearSourceURL

func (_u *ReleaseUpdate) ClearSourceURL() *ReleaseUpdate

ClearSourceURL clears the value of the "source_url" field.

func (*ReleaseUpdate) ClearStartDate

func (_u *ReleaseUpdate) ClearStartDate() *ReleaseUpdate

ClearStartDate clears the value of the "start_date" field.

func (*ReleaseUpdate) ClearStatusCategory

func (_u *ReleaseUpdate) ClearStatusCategory() *ReleaseUpdate

ClearStatusCategory clears the value of the "status_category" field.

func (*ReleaseUpdate) ClearStatusID

func (_u *ReleaseUpdate) ClearStatusID() *ReleaseUpdate

ClearStatusID clears the value of the "status_id" field.

func (*ReleaseUpdate) ClearStatusName

func (_u *ReleaseUpdate) ClearStatusName() *ReleaseUpdate

ClearStatusName clears the value of the "status_name" field.

func (*ReleaseUpdate) Exec

func (_u *ReleaseUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*ReleaseUpdate) ExecX

func (_u *ReleaseUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ReleaseUpdate) Mutation

func (_u *ReleaseUpdate) Mutation() *ReleaseMutation

Mutation returns the ReleaseMutation object of the builder.

func (*ReleaseUpdate) Save

func (_u *ReleaseUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*ReleaseUpdate) SaveX

func (_u *ReleaseUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*ReleaseUpdate) SetMetadata

func (_u *ReleaseUpdate) SetMetadata(v map[string]interface{}) *ReleaseUpdate

SetMetadata sets the "metadata" field.

func (*ReleaseUpdate) SetName

func (_u *ReleaseUpdate) SetName(v string) *ReleaseUpdate

SetName sets the "name" field.

func (*ReleaseUpdate) SetNillableName

func (_u *ReleaseUpdate) SetNillableName(v *string) *ReleaseUpdate

SetNillableName sets the "name" field if the given value is not nil.

func (*ReleaseUpdate) SetNillableProgress

func (_u *ReleaseUpdate) SetNillableProgress(v *float64) *ReleaseUpdate

SetNillableProgress sets the "progress" field if the given value is not nil.

func (*ReleaseUpdate) SetNillableProvider

func (_u *ReleaseUpdate) SetNillableProvider(v *string) *ReleaseUpdate

SetNillableProvider sets the "provider" field if the given value is not nil.

func (*ReleaseUpdate) SetNillableReleaseDate

func (_u *ReleaseUpdate) SetNillableReleaseDate(v *time.Time) *ReleaseUpdate

SetNillableReleaseDate sets the "release_date" field if the given value is not nil.

func (*ReleaseUpdate) SetNillableReleased

func (_u *ReleaseUpdate) SetNillableReleased(v *bool) *ReleaseUpdate

SetNillableReleased sets the "released" field if the given value is not nil.

func (*ReleaseUpdate) SetNillableSourceID

func (_u *ReleaseUpdate) SetNillableSourceID(v *string) *ReleaseUpdate

SetNillableSourceID sets the "source_id" field if the given value is not nil.

func (*ReleaseUpdate) SetNillableSourceRef

func (_u *ReleaseUpdate) SetNillableSourceRef(v *string) *ReleaseUpdate

SetNillableSourceRef sets the "source_ref" field if the given value is not nil.

func (*ReleaseUpdate) SetNillableSourceURL

func (_u *ReleaseUpdate) SetNillableSourceURL(v *string) *ReleaseUpdate

SetNillableSourceURL sets the "source_url" field if the given value is not nil.

func (*ReleaseUpdate) SetNillableStartDate

func (_u *ReleaseUpdate) SetNillableStartDate(v *time.Time) *ReleaseUpdate

SetNillableStartDate sets the "start_date" field if the given value is not nil.

func (*ReleaseUpdate) SetNillableStatusCategory

func (_u *ReleaseUpdate) SetNillableStatusCategory(v *string) *ReleaseUpdate

SetNillableStatusCategory sets the "status_category" field if the given value is not nil.

func (*ReleaseUpdate) SetNillableStatusID

func (_u *ReleaseUpdate) SetNillableStatusID(v *string) *ReleaseUpdate

SetNillableStatusID sets the "status_id" field if the given value is not nil.

func (*ReleaseUpdate) SetNillableStatusName

func (_u *ReleaseUpdate) SetNillableStatusName(v *string) *ReleaseUpdate

SetNillableStatusName sets the "status_name" field if the given value is not nil.

func (*ReleaseUpdate) SetNillableSyncedAt

func (_u *ReleaseUpdate) SetNillableSyncedAt(v *time.Time) *ReleaseUpdate

SetNillableSyncedAt sets the "synced_at" field if the given value is not nil.

func (*ReleaseUpdate) SetProgress

func (_u *ReleaseUpdate) SetProgress(v float64) *ReleaseUpdate

SetProgress sets the "progress" field.

func (*ReleaseUpdate) SetProvider

func (_u *ReleaseUpdate) SetProvider(v string) *ReleaseUpdate

SetProvider sets the "provider" field.

func (*ReleaseUpdate) SetReleaseDate

func (_u *ReleaseUpdate) SetReleaseDate(v time.Time) *ReleaseUpdate

SetReleaseDate sets the "release_date" field.

func (*ReleaseUpdate) SetReleased

func (_u *ReleaseUpdate) SetReleased(v bool) *ReleaseUpdate

SetReleased sets the "released" field.

func (*ReleaseUpdate) SetSourceID

func (_u *ReleaseUpdate) SetSourceID(v string) *ReleaseUpdate

SetSourceID sets the "source_id" field.

func (*ReleaseUpdate) SetSourceRef

func (_u *ReleaseUpdate) SetSourceRef(v string) *ReleaseUpdate

SetSourceRef sets the "source_ref" field.

func (*ReleaseUpdate) SetSourceURL

func (_u *ReleaseUpdate) SetSourceURL(v string) *ReleaseUpdate

SetSourceURL sets the "source_url" field.

func (*ReleaseUpdate) SetStartDate

func (_u *ReleaseUpdate) SetStartDate(v time.Time) *ReleaseUpdate

SetStartDate sets the "start_date" field.

func (*ReleaseUpdate) SetStatusCategory

func (_u *ReleaseUpdate) SetStatusCategory(v string) *ReleaseUpdate

SetStatusCategory sets the "status_category" field.

func (*ReleaseUpdate) SetStatusID

func (_u *ReleaseUpdate) SetStatusID(v string) *ReleaseUpdate

SetStatusID sets the "status_id" field.

func (*ReleaseUpdate) SetStatusName

func (_u *ReleaseUpdate) SetStatusName(v string) *ReleaseUpdate

SetStatusName sets the "status_name" field.

func (*ReleaseUpdate) SetSyncedAt

func (_u *ReleaseUpdate) SetSyncedAt(v time.Time) *ReleaseUpdate

SetSyncedAt sets the "synced_at" field.

func (*ReleaseUpdate) Where

func (_u *ReleaseUpdate) Where(ps ...predicate.Release) *ReleaseUpdate

Where appends a list predicates to the ReleaseUpdate builder.

type ReleaseUpdateOne

type ReleaseUpdateOne struct {
	// contains filtered or unexported fields
}

ReleaseUpdateOne is the builder for updating a single Release entity.

func (*ReleaseUpdateOne) AddProgress

func (_u *ReleaseUpdateOne) AddProgress(v float64) *ReleaseUpdateOne

AddProgress adds value to the "progress" field.

func (*ReleaseUpdateOne) ClearMetadata

func (_u *ReleaseUpdateOne) ClearMetadata() *ReleaseUpdateOne

ClearMetadata clears the value of the "metadata" field.

func (*ReleaseUpdateOne) ClearName

func (_u *ReleaseUpdateOne) ClearName() *ReleaseUpdateOne

ClearName clears the value of the "name" field.

func (*ReleaseUpdateOne) ClearProgress

func (_u *ReleaseUpdateOne) ClearProgress() *ReleaseUpdateOne

ClearProgress clears the value of the "progress" field.

func (*ReleaseUpdateOne) ClearReleaseDate

func (_u *ReleaseUpdateOne) ClearReleaseDate() *ReleaseUpdateOne

ClearReleaseDate clears the value of the "release_date" field.

func (*ReleaseUpdateOne) ClearSourceRef

func (_u *ReleaseUpdateOne) ClearSourceRef() *ReleaseUpdateOne

ClearSourceRef clears the value of the "source_ref" field.

func (*ReleaseUpdateOne) ClearSourceURL

func (_u *ReleaseUpdateOne) ClearSourceURL() *ReleaseUpdateOne

ClearSourceURL clears the value of the "source_url" field.

func (*ReleaseUpdateOne) ClearStartDate

func (_u *ReleaseUpdateOne) ClearStartDate() *ReleaseUpdateOne

ClearStartDate clears the value of the "start_date" field.

func (*ReleaseUpdateOne) ClearStatusCategory

func (_u *ReleaseUpdateOne) ClearStatusCategory() *ReleaseUpdateOne

ClearStatusCategory clears the value of the "status_category" field.

func (*ReleaseUpdateOne) ClearStatusID

func (_u *ReleaseUpdateOne) ClearStatusID() *ReleaseUpdateOne

ClearStatusID clears the value of the "status_id" field.

func (*ReleaseUpdateOne) ClearStatusName

func (_u *ReleaseUpdateOne) ClearStatusName() *ReleaseUpdateOne

ClearStatusName clears the value of the "status_name" field.

func (*ReleaseUpdateOne) Exec

func (_u *ReleaseUpdateOne) Exec(ctx context.Context) error

Exec executes the query on the entity.

func (*ReleaseUpdateOne) ExecX

func (_u *ReleaseUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ReleaseUpdateOne) Mutation

func (_u *ReleaseUpdateOne) Mutation() *ReleaseMutation

Mutation returns the ReleaseMutation object of the builder.

func (*ReleaseUpdateOne) Save

func (_u *ReleaseUpdateOne) Save(ctx context.Context) (*Release, error)

Save executes the query and returns the updated Release entity.

func (*ReleaseUpdateOne) SaveX

func (_u *ReleaseUpdateOne) SaveX(ctx context.Context) *Release

SaveX is like Save, but panics if an error occurs.

func (*ReleaseUpdateOne) Select

func (_u *ReleaseUpdateOne) Select(field string, fields ...string) *ReleaseUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*ReleaseUpdateOne) SetMetadata

func (_u *ReleaseUpdateOne) SetMetadata(v map[string]interface{}) *ReleaseUpdateOne

SetMetadata sets the "metadata" field.

func (*ReleaseUpdateOne) SetName

func (_u *ReleaseUpdateOne) SetName(v string) *ReleaseUpdateOne

SetName sets the "name" field.

func (*ReleaseUpdateOne) SetNillableName

func (_u *ReleaseUpdateOne) SetNillableName(v *string) *ReleaseUpdateOne

SetNillableName sets the "name" field if the given value is not nil.

func (*ReleaseUpdateOne) SetNillableProgress

func (_u *ReleaseUpdateOne) SetNillableProgress(v *float64) *ReleaseUpdateOne

SetNillableProgress sets the "progress" field if the given value is not nil.

func (*ReleaseUpdateOne) SetNillableProvider

func (_u *ReleaseUpdateOne) SetNillableProvider(v *string) *ReleaseUpdateOne

SetNillableProvider sets the "provider" field if the given value is not nil.

func (*ReleaseUpdateOne) SetNillableReleaseDate

func (_u *ReleaseUpdateOne) SetNillableReleaseDate(v *time.Time) *ReleaseUpdateOne

SetNillableReleaseDate sets the "release_date" field if the given value is not nil.

func (*ReleaseUpdateOne) SetNillableReleased

func (_u *ReleaseUpdateOne) SetNillableReleased(v *bool) *ReleaseUpdateOne

SetNillableReleased sets the "released" field if the given value is not nil.

func (*ReleaseUpdateOne) SetNillableSourceID

func (_u *ReleaseUpdateOne) SetNillableSourceID(v *string) *ReleaseUpdateOne

SetNillableSourceID sets the "source_id" field if the given value is not nil.

func (*ReleaseUpdateOne) SetNillableSourceRef

func (_u *ReleaseUpdateOne) SetNillableSourceRef(v *string) *ReleaseUpdateOne

SetNillableSourceRef sets the "source_ref" field if the given value is not nil.

func (*ReleaseUpdateOne) SetNillableSourceURL

func (_u *ReleaseUpdateOne) SetNillableSourceURL(v *string) *ReleaseUpdateOne

SetNillableSourceURL sets the "source_url" field if the given value is not nil.

func (*ReleaseUpdateOne) SetNillableStartDate

func (_u *ReleaseUpdateOne) SetNillableStartDate(v *time.Time) *ReleaseUpdateOne

SetNillableStartDate sets the "start_date" field if the given value is not nil.

func (*ReleaseUpdateOne) SetNillableStatusCategory

func (_u *ReleaseUpdateOne) SetNillableStatusCategory(v *string) *ReleaseUpdateOne

SetNillableStatusCategory sets the "status_category" field if the given value is not nil.

func (*ReleaseUpdateOne) SetNillableStatusID

func (_u *ReleaseUpdateOne) SetNillableStatusID(v *string) *ReleaseUpdateOne

SetNillableStatusID sets the "status_id" field if the given value is not nil.

func (*ReleaseUpdateOne) SetNillableStatusName

func (_u *ReleaseUpdateOne) SetNillableStatusName(v *string) *ReleaseUpdateOne

SetNillableStatusName sets the "status_name" field if the given value is not nil.

func (*ReleaseUpdateOne) SetNillableSyncedAt

func (_u *ReleaseUpdateOne) SetNillableSyncedAt(v *time.Time) *ReleaseUpdateOne

SetNillableSyncedAt sets the "synced_at" field if the given value is not nil.

func (*ReleaseUpdateOne) SetProgress

func (_u *ReleaseUpdateOne) SetProgress(v float64) *ReleaseUpdateOne

SetProgress sets the "progress" field.

func (*ReleaseUpdateOne) SetProvider

func (_u *ReleaseUpdateOne) SetProvider(v string) *ReleaseUpdateOne

SetProvider sets the "provider" field.

func (*ReleaseUpdateOne) SetReleaseDate

func (_u *ReleaseUpdateOne) SetReleaseDate(v time.Time) *ReleaseUpdateOne

SetReleaseDate sets the "release_date" field.

func (*ReleaseUpdateOne) SetReleased

func (_u *ReleaseUpdateOne) SetReleased(v bool) *ReleaseUpdateOne

SetReleased sets the "released" field.

func (*ReleaseUpdateOne) SetSourceID

func (_u *ReleaseUpdateOne) SetSourceID(v string) *ReleaseUpdateOne

SetSourceID sets the "source_id" field.

func (*ReleaseUpdateOne) SetSourceRef

func (_u *ReleaseUpdateOne) SetSourceRef(v string) *ReleaseUpdateOne

SetSourceRef sets the "source_ref" field.

func (*ReleaseUpdateOne) SetSourceURL

func (_u *ReleaseUpdateOne) SetSourceURL(v string) *ReleaseUpdateOne

SetSourceURL sets the "source_url" field.

func (*ReleaseUpdateOne) SetStartDate

func (_u *ReleaseUpdateOne) SetStartDate(v time.Time) *ReleaseUpdateOne

SetStartDate sets the "start_date" field.

func (*ReleaseUpdateOne) SetStatusCategory

func (_u *ReleaseUpdateOne) SetStatusCategory(v string) *ReleaseUpdateOne

SetStatusCategory sets the "status_category" field.

func (*ReleaseUpdateOne) SetStatusID

func (_u *ReleaseUpdateOne) SetStatusID(v string) *ReleaseUpdateOne

SetStatusID sets the "status_id" field.

func (*ReleaseUpdateOne) SetStatusName

func (_u *ReleaseUpdateOne) SetStatusName(v string) *ReleaseUpdateOne

SetStatusName sets the "status_name" field.

func (*ReleaseUpdateOne) SetSyncedAt

func (_u *ReleaseUpdateOne) SetSyncedAt(v time.Time) *ReleaseUpdateOne

SetSyncedAt sets the "synced_at" field.

func (*ReleaseUpdateOne) Where

Where appends a list predicates to the ReleaseUpdate builder.

type ReleaseUpsert

type ReleaseUpsert struct {
	*sql.UpdateSet
}

ReleaseUpsert is the "OnConflict" setter.

func (*ReleaseUpsert) AddProgress

func (u *ReleaseUpsert) AddProgress(v float64) *ReleaseUpsert

AddProgress adds v to the "progress" field.

func (*ReleaseUpsert) ClearMetadata

func (u *ReleaseUpsert) ClearMetadata() *ReleaseUpsert

ClearMetadata clears the value of the "metadata" field.

func (*ReleaseUpsert) ClearName

func (u *ReleaseUpsert) ClearName() *ReleaseUpsert

ClearName clears the value of the "name" field.

func (*ReleaseUpsert) ClearProgress

func (u *ReleaseUpsert) ClearProgress() *ReleaseUpsert

ClearProgress clears the value of the "progress" field.

func (*ReleaseUpsert) ClearReleaseDate

func (u *ReleaseUpsert) ClearReleaseDate() *ReleaseUpsert

ClearReleaseDate clears the value of the "release_date" field.

func (*ReleaseUpsert) ClearSourceRef

func (u *ReleaseUpsert) ClearSourceRef() *ReleaseUpsert

ClearSourceRef clears the value of the "source_ref" field.

func (*ReleaseUpsert) ClearSourceURL

func (u *ReleaseUpsert) ClearSourceURL() *ReleaseUpsert

ClearSourceURL clears the value of the "source_url" field.

func (*ReleaseUpsert) ClearStartDate

func (u *ReleaseUpsert) ClearStartDate() *ReleaseUpsert

ClearStartDate clears the value of the "start_date" field.

func (*ReleaseUpsert) ClearStatusCategory

func (u *ReleaseUpsert) ClearStatusCategory() *ReleaseUpsert

ClearStatusCategory clears the value of the "status_category" field.

func (*ReleaseUpsert) ClearStatusID

func (u *ReleaseUpsert) ClearStatusID() *ReleaseUpsert

ClearStatusID clears the value of the "status_id" field.

func (*ReleaseUpsert) ClearStatusName

func (u *ReleaseUpsert) ClearStatusName() *ReleaseUpsert

ClearStatusName clears the value of the "status_name" field.

func (*ReleaseUpsert) SetMetadata

func (u *ReleaseUpsert) SetMetadata(v map[string]interface{}) *ReleaseUpsert

SetMetadata sets the "metadata" field.

func (*ReleaseUpsert) SetName

func (u *ReleaseUpsert) SetName(v string) *ReleaseUpsert

SetName sets the "name" field.

func (*ReleaseUpsert) SetProgress

func (u *ReleaseUpsert) SetProgress(v float64) *ReleaseUpsert

SetProgress sets the "progress" field.

func (*ReleaseUpsert) SetProvider

func (u *ReleaseUpsert) SetProvider(v string) *ReleaseUpsert

SetProvider sets the "provider" field.

func (*ReleaseUpsert) SetReleaseDate

func (u *ReleaseUpsert) SetReleaseDate(v time.Time) *ReleaseUpsert

SetReleaseDate sets the "release_date" field.

func (*ReleaseUpsert) SetReleased

func (u *ReleaseUpsert) SetReleased(v bool) *ReleaseUpsert

SetReleased sets the "released" field.

func (*ReleaseUpsert) SetSourceID

func (u *ReleaseUpsert) SetSourceID(v string) *ReleaseUpsert

SetSourceID sets the "source_id" field.

func (*ReleaseUpsert) SetSourceRef

func (u *ReleaseUpsert) SetSourceRef(v string) *ReleaseUpsert

SetSourceRef sets the "source_ref" field.

func (*ReleaseUpsert) SetSourceURL

func (u *ReleaseUpsert) SetSourceURL(v string) *ReleaseUpsert

SetSourceURL sets the "source_url" field.

func (*ReleaseUpsert) SetStartDate

func (u *ReleaseUpsert) SetStartDate(v time.Time) *ReleaseUpsert

SetStartDate sets the "start_date" field.

func (*ReleaseUpsert) SetStatusCategory

func (u *ReleaseUpsert) SetStatusCategory(v string) *ReleaseUpsert

SetStatusCategory sets the "status_category" field.

func (*ReleaseUpsert) SetStatusID

func (u *ReleaseUpsert) SetStatusID(v string) *ReleaseUpsert

SetStatusID sets the "status_id" field.

func (*ReleaseUpsert) SetStatusName

func (u *ReleaseUpsert) SetStatusName(v string) *ReleaseUpsert

SetStatusName sets the "status_name" field.

func (*ReleaseUpsert) SetSyncedAt

func (u *ReleaseUpsert) SetSyncedAt(v time.Time) *ReleaseUpsert

SetSyncedAt sets the "synced_at" field.

func (*ReleaseUpsert) UpdateMetadata

func (u *ReleaseUpsert) UpdateMetadata() *ReleaseUpsert

UpdateMetadata sets the "metadata" field to the value that was provided on create.

func (*ReleaseUpsert) UpdateName

func (u *ReleaseUpsert) UpdateName() *ReleaseUpsert

UpdateName sets the "name" field to the value that was provided on create.

func (*ReleaseUpsert) UpdateProgress

func (u *ReleaseUpsert) UpdateProgress() *ReleaseUpsert

UpdateProgress sets the "progress" field to the value that was provided on create.

func (*ReleaseUpsert) UpdateProvider

func (u *ReleaseUpsert) UpdateProvider() *ReleaseUpsert

UpdateProvider sets the "provider" field to the value that was provided on create.

func (*ReleaseUpsert) UpdateReleaseDate

func (u *ReleaseUpsert) UpdateReleaseDate() *ReleaseUpsert

UpdateReleaseDate sets the "release_date" field to the value that was provided on create.

func (*ReleaseUpsert) UpdateReleased

func (u *ReleaseUpsert) UpdateReleased() *ReleaseUpsert

UpdateReleased sets the "released" field to the value that was provided on create.

func (*ReleaseUpsert) UpdateSourceID

func (u *ReleaseUpsert) UpdateSourceID() *ReleaseUpsert

UpdateSourceID sets the "source_id" field to the value that was provided on create.

func (*ReleaseUpsert) UpdateSourceRef

func (u *ReleaseUpsert) UpdateSourceRef() *ReleaseUpsert

UpdateSourceRef sets the "source_ref" field to the value that was provided on create.

func (*ReleaseUpsert) UpdateSourceURL

func (u *ReleaseUpsert) UpdateSourceURL() *ReleaseUpsert

UpdateSourceURL sets the "source_url" field to the value that was provided on create.

func (*ReleaseUpsert) UpdateStartDate

func (u *ReleaseUpsert) UpdateStartDate() *ReleaseUpsert

UpdateStartDate sets the "start_date" field to the value that was provided on create.

func (*ReleaseUpsert) UpdateStatusCategory

func (u *ReleaseUpsert) UpdateStatusCategory() *ReleaseUpsert

UpdateStatusCategory sets the "status_category" field to the value that was provided on create.

func (*ReleaseUpsert) UpdateStatusID

func (u *ReleaseUpsert) UpdateStatusID() *ReleaseUpsert

UpdateStatusID sets the "status_id" field to the value that was provided on create.

func (*ReleaseUpsert) UpdateStatusName

func (u *ReleaseUpsert) UpdateStatusName() *ReleaseUpsert

UpdateStatusName sets the "status_name" field to the value that was provided on create.

func (*ReleaseUpsert) UpdateSyncedAt

func (u *ReleaseUpsert) UpdateSyncedAt() *ReleaseUpsert

UpdateSyncedAt sets the "synced_at" field to the value that was provided on create.

type ReleaseUpsertBulk

type ReleaseUpsertBulk struct {
	// contains filtered or unexported fields
}

ReleaseUpsertBulk is the builder for "upsert"-ing a bulk of Release nodes.

func (*ReleaseUpsertBulk) AddProgress

func (u *ReleaseUpsertBulk) AddProgress(v float64) *ReleaseUpsertBulk

AddProgress adds v to the "progress" field.

func (*ReleaseUpsertBulk) ClearMetadata

func (u *ReleaseUpsertBulk) ClearMetadata() *ReleaseUpsertBulk

ClearMetadata clears the value of the "metadata" field.

func (*ReleaseUpsertBulk) ClearName

func (u *ReleaseUpsertBulk) ClearName() *ReleaseUpsertBulk

ClearName clears the value of the "name" field.

func (*ReleaseUpsertBulk) ClearProgress

func (u *ReleaseUpsertBulk) ClearProgress() *ReleaseUpsertBulk

ClearProgress clears the value of the "progress" field.

func (*ReleaseUpsertBulk) ClearReleaseDate

func (u *ReleaseUpsertBulk) ClearReleaseDate() *ReleaseUpsertBulk

ClearReleaseDate clears the value of the "release_date" field.

func (*ReleaseUpsertBulk) ClearSourceRef

func (u *ReleaseUpsertBulk) ClearSourceRef() *ReleaseUpsertBulk

ClearSourceRef clears the value of the "source_ref" field.

func (*ReleaseUpsertBulk) ClearSourceURL

func (u *ReleaseUpsertBulk) ClearSourceURL() *ReleaseUpsertBulk

ClearSourceURL clears the value of the "source_url" field.

func (*ReleaseUpsertBulk) ClearStartDate

func (u *ReleaseUpsertBulk) ClearStartDate() *ReleaseUpsertBulk

ClearStartDate clears the value of the "start_date" field.

func (*ReleaseUpsertBulk) ClearStatusCategory

func (u *ReleaseUpsertBulk) ClearStatusCategory() *ReleaseUpsertBulk

ClearStatusCategory clears the value of the "status_category" field.

func (*ReleaseUpsertBulk) ClearStatusID

func (u *ReleaseUpsertBulk) ClearStatusID() *ReleaseUpsertBulk

ClearStatusID clears the value of the "status_id" field.

func (*ReleaseUpsertBulk) ClearStatusName

func (u *ReleaseUpsertBulk) ClearStatusName() *ReleaseUpsertBulk

ClearStatusName clears the value of the "status_name" field.

func (*ReleaseUpsertBulk) DoNothing

func (u *ReleaseUpsertBulk) DoNothing() *ReleaseUpsertBulk

DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.

func (*ReleaseUpsertBulk) Exec

func (u *ReleaseUpsertBulk) Exec(ctx context.Context) error

Exec executes the query.

func (*ReleaseUpsertBulk) ExecX

func (u *ReleaseUpsertBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ReleaseUpsertBulk) Ignore

func (u *ReleaseUpsertBulk) Ignore() *ReleaseUpsertBulk

Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:

client.Release.Create().
	OnConflict(sql.ResolveWithIgnore()).
	Exec(ctx)

func (*ReleaseUpsertBulk) SetMetadata

func (u *ReleaseUpsertBulk) SetMetadata(v map[string]interface{}) *ReleaseUpsertBulk

SetMetadata sets the "metadata" field.

func (*ReleaseUpsertBulk) SetName

SetName sets the "name" field.

func (*ReleaseUpsertBulk) SetProgress

func (u *ReleaseUpsertBulk) SetProgress(v float64) *ReleaseUpsertBulk

SetProgress sets the "progress" field.

func (*ReleaseUpsertBulk) SetProvider

func (u *ReleaseUpsertBulk) SetProvider(v string) *ReleaseUpsertBulk

SetProvider sets the "provider" field.

func (*ReleaseUpsertBulk) SetReleaseDate

func (u *ReleaseUpsertBulk) SetReleaseDate(v time.Time) *ReleaseUpsertBulk

SetReleaseDate sets the "release_date" field.

func (*ReleaseUpsertBulk) SetReleased

func (u *ReleaseUpsertBulk) SetReleased(v bool) *ReleaseUpsertBulk

SetReleased sets the "released" field.

func (*ReleaseUpsertBulk) SetSourceID

func (u *ReleaseUpsertBulk) SetSourceID(v string) *ReleaseUpsertBulk

SetSourceID sets the "source_id" field.

func (*ReleaseUpsertBulk) SetSourceRef

func (u *ReleaseUpsertBulk) SetSourceRef(v string) *ReleaseUpsertBulk

SetSourceRef sets the "source_ref" field.

func (*ReleaseUpsertBulk) SetSourceURL

func (u *ReleaseUpsertBulk) SetSourceURL(v string) *ReleaseUpsertBulk

SetSourceURL sets the "source_url" field.

func (*ReleaseUpsertBulk) SetStartDate

func (u *ReleaseUpsertBulk) SetStartDate(v time.Time) *ReleaseUpsertBulk

SetStartDate sets the "start_date" field.

func (*ReleaseUpsertBulk) SetStatusCategory

func (u *ReleaseUpsertBulk) SetStatusCategory(v string) *ReleaseUpsertBulk

SetStatusCategory sets the "status_category" field.

func (*ReleaseUpsertBulk) SetStatusID

func (u *ReleaseUpsertBulk) SetStatusID(v string) *ReleaseUpsertBulk

SetStatusID sets the "status_id" field.

func (*ReleaseUpsertBulk) SetStatusName

func (u *ReleaseUpsertBulk) SetStatusName(v string) *ReleaseUpsertBulk

SetStatusName sets the "status_name" field.

func (*ReleaseUpsertBulk) SetSyncedAt

func (u *ReleaseUpsertBulk) SetSyncedAt(v time.Time) *ReleaseUpsertBulk

SetSyncedAt sets the "synced_at" field.

func (*ReleaseUpsertBulk) Update

func (u *ReleaseUpsertBulk) Update(set func(*ReleaseUpsert)) *ReleaseUpsertBulk

Update allows overriding fields `UPDATE` values. See the ReleaseCreateBulk.OnConflict documentation for more info.

func (*ReleaseUpsertBulk) UpdateMetadata

func (u *ReleaseUpsertBulk) UpdateMetadata() *ReleaseUpsertBulk

UpdateMetadata sets the "metadata" field to the value that was provided on create.

func (*ReleaseUpsertBulk) UpdateName

func (u *ReleaseUpsertBulk) UpdateName() *ReleaseUpsertBulk

UpdateName sets the "name" field to the value that was provided on create.

func (*ReleaseUpsertBulk) UpdateNewValues

func (u *ReleaseUpsertBulk) UpdateNewValues() *ReleaseUpsertBulk

UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:

client.Release.Create().
	OnConflict(
		sql.ResolveWithNewValues(),
		sql.ResolveWith(func(u *sql.UpdateSet) {
			u.SetIgnore(release.FieldID)
		}),
	).
	Exec(ctx)

func (*ReleaseUpsertBulk) UpdateProgress

func (u *ReleaseUpsertBulk) UpdateProgress() *ReleaseUpsertBulk

UpdateProgress sets the "progress" field to the value that was provided on create.

func (*ReleaseUpsertBulk) UpdateProvider

func (u *ReleaseUpsertBulk) UpdateProvider() *ReleaseUpsertBulk

UpdateProvider sets the "provider" field to the value that was provided on create.

func (*ReleaseUpsertBulk) UpdateReleaseDate

func (u *ReleaseUpsertBulk) UpdateReleaseDate() *ReleaseUpsertBulk

UpdateReleaseDate sets the "release_date" field to the value that was provided on create.

func (*ReleaseUpsertBulk) UpdateReleased

func (u *ReleaseUpsertBulk) UpdateReleased() *ReleaseUpsertBulk

UpdateReleased sets the "released" field to the value that was provided on create.

func (*ReleaseUpsertBulk) UpdateSourceID

func (u *ReleaseUpsertBulk) UpdateSourceID() *ReleaseUpsertBulk

UpdateSourceID sets the "source_id" field to the value that was provided on create.

func (*ReleaseUpsertBulk) UpdateSourceRef

func (u *ReleaseUpsertBulk) UpdateSourceRef() *ReleaseUpsertBulk

UpdateSourceRef sets the "source_ref" field to the value that was provided on create.

func (*ReleaseUpsertBulk) UpdateSourceURL

func (u *ReleaseUpsertBulk) UpdateSourceURL() *ReleaseUpsertBulk

UpdateSourceURL sets the "source_url" field to the value that was provided on create.

func (*ReleaseUpsertBulk) UpdateStartDate

func (u *ReleaseUpsertBulk) UpdateStartDate() *ReleaseUpsertBulk

UpdateStartDate sets the "start_date" field to the value that was provided on create.

func (*ReleaseUpsertBulk) UpdateStatusCategory

func (u *ReleaseUpsertBulk) UpdateStatusCategory() *ReleaseUpsertBulk

UpdateStatusCategory sets the "status_category" field to the value that was provided on create.

func (*ReleaseUpsertBulk) UpdateStatusID

func (u *ReleaseUpsertBulk) UpdateStatusID() *ReleaseUpsertBulk

UpdateStatusID sets the "status_id" field to the value that was provided on create.

func (*ReleaseUpsertBulk) UpdateStatusName

func (u *ReleaseUpsertBulk) UpdateStatusName() *ReleaseUpsertBulk

UpdateStatusName sets the "status_name" field to the value that was provided on create.

func (*ReleaseUpsertBulk) UpdateSyncedAt

func (u *ReleaseUpsertBulk) UpdateSyncedAt() *ReleaseUpsertBulk

UpdateSyncedAt sets the "synced_at" field to the value that was provided on create.

type ReleaseUpsertOne

type ReleaseUpsertOne struct {
	// contains filtered or unexported fields
}

ReleaseUpsertOne is the builder for "upsert"-ing

one Release node.

func (*ReleaseUpsertOne) AddProgress

func (u *ReleaseUpsertOne) AddProgress(v float64) *ReleaseUpsertOne

AddProgress adds v to the "progress" field.

func (*ReleaseUpsertOne) ClearMetadata

func (u *ReleaseUpsertOne) ClearMetadata() *ReleaseUpsertOne

ClearMetadata clears the value of the "metadata" field.

func (*ReleaseUpsertOne) ClearName

func (u *ReleaseUpsertOne) ClearName() *ReleaseUpsertOne

ClearName clears the value of the "name" field.

func (*ReleaseUpsertOne) ClearProgress

func (u *ReleaseUpsertOne) ClearProgress() *ReleaseUpsertOne

ClearProgress clears the value of the "progress" field.

func (*ReleaseUpsertOne) ClearReleaseDate

func (u *ReleaseUpsertOne) ClearReleaseDate() *ReleaseUpsertOne

ClearReleaseDate clears the value of the "release_date" field.

func (*ReleaseUpsertOne) ClearSourceRef

func (u *ReleaseUpsertOne) ClearSourceRef() *ReleaseUpsertOne

ClearSourceRef clears the value of the "source_ref" field.

func (*ReleaseUpsertOne) ClearSourceURL

func (u *ReleaseUpsertOne) ClearSourceURL() *ReleaseUpsertOne

ClearSourceURL clears the value of the "source_url" field.

func (*ReleaseUpsertOne) ClearStartDate

func (u *ReleaseUpsertOne) ClearStartDate() *ReleaseUpsertOne

ClearStartDate clears the value of the "start_date" field.

func (*ReleaseUpsertOne) ClearStatusCategory

func (u *ReleaseUpsertOne) ClearStatusCategory() *ReleaseUpsertOne

ClearStatusCategory clears the value of the "status_category" field.

func (*ReleaseUpsertOne) ClearStatusID

func (u *ReleaseUpsertOne) ClearStatusID() *ReleaseUpsertOne

ClearStatusID clears the value of the "status_id" field.

func (*ReleaseUpsertOne) ClearStatusName

func (u *ReleaseUpsertOne) ClearStatusName() *ReleaseUpsertOne

ClearStatusName clears the value of the "status_name" field.

func (*ReleaseUpsertOne) DoNothing

func (u *ReleaseUpsertOne) DoNothing() *ReleaseUpsertOne

DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.

func (*ReleaseUpsertOne) Exec

func (u *ReleaseUpsertOne) Exec(ctx context.Context) error

Exec executes the query.

func (*ReleaseUpsertOne) ExecX

func (u *ReleaseUpsertOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ReleaseUpsertOne) ID

func (u *ReleaseUpsertOne) ID(ctx context.Context) (id string, err error)

Exec executes the UPSERT query and returns the inserted/updated ID.

func (*ReleaseUpsertOne) IDX

func (u *ReleaseUpsertOne) IDX(ctx context.Context) string

IDX is like ID, but panics if an error occurs.

func (*ReleaseUpsertOne) Ignore

func (u *ReleaseUpsertOne) Ignore() *ReleaseUpsertOne

Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:

client.Release.Create().
    OnConflict(sql.ResolveWithIgnore()).
    Exec(ctx)

func (*ReleaseUpsertOne) SetMetadata

func (u *ReleaseUpsertOne) SetMetadata(v map[string]interface{}) *ReleaseUpsertOne

SetMetadata sets the "metadata" field.

func (*ReleaseUpsertOne) SetName

func (u *ReleaseUpsertOne) SetName(v string) *ReleaseUpsertOne

SetName sets the "name" field.

func (*ReleaseUpsertOne) SetProgress

func (u *ReleaseUpsertOne) SetProgress(v float64) *ReleaseUpsertOne

SetProgress sets the "progress" field.

func (*ReleaseUpsertOne) SetProvider

func (u *ReleaseUpsertOne) SetProvider(v string) *ReleaseUpsertOne

SetProvider sets the "provider" field.

func (*ReleaseUpsertOne) SetReleaseDate

func (u *ReleaseUpsertOne) SetReleaseDate(v time.Time) *ReleaseUpsertOne

SetReleaseDate sets the "release_date" field.

func (*ReleaseUpsertOne) SetReleased

func (u *ReleaseUpsertOne) SetReleased(v bool) *ReleaseUpsertOne

SetReleased sets the "released" field.

func (*ReleaseUpsertOne) SetSourceID

func (u *ReleaseUpsertOne) SetSourceID(v string) *ReleaseUpsertOne

SetSourceID sets the "source_id" field.

func (*ReleaseUpsertOne) SetSourceRef

func (u *ReleaseUpsertOne) SetSourceRef(v string) *ReleaseUpsertOne

SetSourceRef sets the "source_ref" field.

func (*ReleaseUpsertOne) SetSourceURL

func (u *ReleaseUpsertOne) SetSourceURL(v string) *ReleaseUpsertOne

SetSourceURL sets the "source_url" field.

func (*ReleaseUpsertOne) SetStartDate

func (u *ReleaseUpsertOne) SetStartDate(v time.Time) *ReleaseUpsertOne

SetStartDate sets the "start_date" field.

func (*ReleaseUpsertOne) SetStatusCategory

func (u *ReleaseUpsertOne) SetStatusCategory(v string) *ReleaseUpsertOne

SetStatusCategory sets the "status_category" field.

func (*ReleaseUpsertOne) SetStatusID

func (u *ReleaseUpsertOne) SetStatusID(v string) *ReleaseUpsertOne

SetStatusID sets the "status_id" field.

func (*ReleaseUpsertOne) SetStatusName

func (u *ReleaseUpsertOne) SetStatusName(v string) *ReleaseUpsertOne

SetStatusName sets the "status_name" field.

func (*ReleaseUpsertOne) SetSyncedAt

func (u *ReleaseUpsertOne) SetSyncedAt(v time.Time) *ReleaseUpsertOne

SetSyncedAt sets the "synced_at" field.

func (*ReleaseUpsertOne) Update

func (u *ReleaseUpsertOne) Update(set func(*ReleaseUpsert)) *ReleaseUpsertOne

Update allows overriding fields `UPDATE` values. See the ReleaseCreate.OnConflict documentation for more info.

func (*ReleaseUpsertOne) UpdateMetadata

func (u *ReleaseUpsertOne) UpdateMetadata() *ReleaseUpsertOne

UpdateMetadata sets the "metadata" field to the value that was provided on create.

func (*ReleaseUpsertOne) UpdateName

func (u *ReleaseUpsertOne) UpdateName() *ReleaseUpsertOne

UpdateName sets the "name" field to the value that was provided on create.

func (*ReleaseUpsertOne) UpdateNewValues

func (u *ReleaseUpsertOne) UpdateNewValues() *ReleaseUpsertOne

UpdateNewValues updates the mutable fields using the new values that were set on create except the ID field. Using this option is equivalent to using:

client.Release.Create().
	OnConflict(
		sql.ResolveWithNewValues(),
		sql.ResolveWith(func(u *sql.UpdateSet) {
			u.SetIgnore(release.FieldID)
		}),
	).
	Exec(ctx)

func (*ReleaseUpsertOne) UpdateProgress

func (u *ReleaseUpsertOne) UpdateProgress() *ReleaseUpsertOne

UpdateProgress sets the "progress" field to the value that was provided on create.

func (*ReleaseUpsertOne) UpdateProvider

func (u *ReleaseUpsertOne) UpdateProvider() *ReleaseUpsertOne

UpdateProvider sets the "provider" field to the value that was provided on create.

func (*ReleaseUpsertOne) UpdateReleaseDate

func (u *ReleaseUpsertOne) UpdateReleaseDate() *ReleaseUpsertOne

UpdateReleaseDate sets the "release_date" field to the value that was provided on create.

func (*ReleaseUpsertOne) UpdateReleased

func (u *ReleaseUpsertOne) UpdateReleased() *ReleaseUpsertOne

UpdateReleased sets the "released" field to the value that was provided on create.

func (*ReleaseUpsertOne) UpdateSourceID

func (u *ReleaseUpsertOne) UpdateSourceID() *ReleaseUpsertOne

UpdateSourceID sets the "source_id" field to the value that was provided on create.

func (*ReleaseUpsertOne) UpdateSourceRef

func (u *ReleaseUpsertOne) UpdateSourceRef() *ReleaseUpsertOne

UpdateSourceRef sets the "source_ref" field to the value that was provided on create.

func (*ReleaseUpsertOne) UpdateSourceURL

func (u *ReleaseUpsertOne) UpdateSourceURL() *ReleaseUpsertOne

UpdateSourceURL sets the "source_url" field to the value that was provided on create.

func (*ReleaseUpsertOne) UpdateStartDate

func (u *ReleaseUpsertOne) UpdateStartDate() *ReleaseUpsertOne

UpdateStartDate sets the "start_date" field to the value that was provided on create.

func (*ReleaseUpsertOne) UpdateStatusCategory

func (u *ReleaseUpsertOne) UpdateStatusCategory() *ReleaseUpsertOne

UpdateStatusCategory sets the "status_category" field to the value that was provided on create.

func (*ReleaseUpsertOne) UpdateStatusID

func (u *ReleaseUpsertOne) UpdateStatusID() *ReleaseUpsertOne

UpdateStatusID sets the "status_id" field to the value that was provided on create.

func (*ReleaseUpsertOne) UpdateStatusName

func (u *ReleaseUpsertOne) UpdateStatusName() *ReleaseUpsertOne

UpdateStatusName sets the "status_name" field to the value that was provided on create.

func (*ReleaseUpsertOne) UpdateSyncedAt

func (u *ReleaseUpsertOne) UpdateSyncedAt() *ReleaseUpsertOne

UpdateSyncedAt sets the "synced_at" field to the value that was provided on create.

type Releases

type Releases []*Release

Releases is a parsable slice of Release.

type ReportDataset

type ReportDataset struct {

	// ID of the ent.
	ID string `json:"id,omitempty"`
	// GeneratedAt holds the value of the "generated_at" field.
	GeneratedAt time.Time `json:"generated_at,omitempty"`
	// RankingPolicyID holds the value of the "ranking_policy_id" field.
	RankingPolicyID string `json:"ranking_policy_id,omitempty"`
	// RankingPolicyVersion holds the value of the "ranking_policy_version" field.
	RankingPolicyVersion string `json:"ranking_policy_version,omitempty"`
	// Status holds the value of the "status" field.
	Status string `json:"status,omitempty"`
	// Canonical holds the value of the "canonical" field.
	Canonical assessment.ReportDataset `json:"canonical,omitempty"`
	// CreatedAt holds the value of the "created_at" field.
	CreatedAt time.Time `json:"created_at,omitempty"`
	// contains filtered or unexported fields
}

ReportDataset is the model entity for the ReportDataset schema.

func (*ReportDataset) String

func (_m *ReportDataset) String() string

String implements the fmt.Stringer.

func (*ReportDataset) Unwrap

func (_m *ReportDataset) Unwrap() *ReportDataset

Unwrap unwraps the ReportDataset entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*ReportDataset) Update

func (_m *ReportDataset) Update() *ReportDatasetUpdateOne

Update returns a builder for updating this ReportDataset. Note that you need to call ReportDataset.Unwrap() before calling this method if this ReportDataset was returned from a transaction, and the transaction was committed or rolled back.

func (*ReportDataset) Value

func (_m *ReportDataset) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the ReportDataset. This includes values selected through modifiers, order, etc.

type ReportDatasetClient

type ReportDatasetClient struct {
	// contains filtered or unexported fields
}

ReportDatasetClient is a client for the ReportDataset schema.

func NewReportDatasetClient

func NewReportDatasetClient(c config) *ReportDatasetClient

NewReportDatasetClient returns a client for the ReportDataset from the given config.

func (*ReportDatasetClient) Create

Create returns a builder for creating a ReportDataset entity.

func (*ReportDatasetClient) CreateBulk

CreateBulk returns a builder for creating a bulk of ReportDataset entities.

func (*ReportDatasetClient) Delete

Delete returns a delete builder for ReportDataset.

func (*ReportDatasetClient) DeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*ReportDatasetClient) DeleteOneID

DeleteOneID returns a builder for deleting the given entity by its id.

func (*ReportDatasetClient) Get

Get returns a ReportDataset entity by its id.

func (*ReportDatasetClient) GetX

GetX is like Get, but panics if an error occurs.

func (*ReportDatasetClient) Hooks

func (c *ReportDatasetClient) Hooks() []Hook

Hooks returns the client hooks.

func (*ReportDatasetClient) Intercept

func (c *ReportDatasetClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `reportdataset.Intercept(f(g(h())))`.

func (*ReportDatasetClient) Interceptors

func (c *ReportDatasetClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*ReportDatasetClient) MapCreateBulk

func (c *ReportDatasetClient) MapCreateBulk(slice any, setFunc func(*ReportDatasetCreate, int)) *ReportDatasetCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*ReportDatasetClient) Query

Query returns a query builder for ReportDataset.

func (*ReportDatasetClient) Update

Update returns an update builder for ReportDataset.

func (*ReportDatasetClient) UpdateOne

UpdateOne returns an update builder for the given entity.

func (*ReportDatasetClient) UpdateOneID

UpdateOneID returns an update builder for the given id.

func (*ReportDatasetClient) Use

func (c *ReportDatasetClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `reportdataset.Hooks(f(g(h())))`.

type ReportDatasetCreate

type ReportDatasetCreate struct {
	// contains filtered or unexported fields
}

ReportDatasetCreate is the builder for creating a ReportDataset entity.

func (*ReportDatasetCreate) Exec

func (_c *ReportDatasetCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*ReportDatasetCreate) ExecX

func (_c *ReportDatasetCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ReportDatasetCreate) Mutation

Mutation returns the ReportDatasetMutation object of the builder.

func (*ReportDatasetCreate) OnConflict

OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:

client.ReportDataset.Create().
	SetGeneratedAt(v).
	OnConflict(
		// Update the row with the new values
		// the was proposed for insertion.
		sql.ResolveWithNewValues(),
	).
	// Override some of the fields with custom
	// update values.
	Update(func(u *ent.ReportDatasetUpsert) {
		SetGeneratedAt(v+v).
	}).
	Exec(ctx)

func (*ReportDatasetCreate) OnConflictColumns

func (_c *ReportDatasetCreate) OnConflictColumns(columns ...string) *ReportDatasetUpsertOne

OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:

client.ReportDataset.Create().
	OnConflict(sql.ConflictColumns(columns...)).
	Exec(ctx)

func (*ReportDatasetCreate) Save

Save creates the ReportDataset in the database.

func (*ReportDatasetCreate) SaveX

SaveX calls Save and panics if Save returns an error.

func (*ReportDatasetCreate) SetCanonical

SetCanonical sets the "canonical" field.

func (*ReportDatasetCreate) SetCreatedAt

func (_c *ReportDatasetCreate) SetCreatedAt(v time.Time) *ReportDatasetCreate

SetCreatedAt sets the "created_at" field.

func (*ReportDatasetCreate) SetGeneratedAt

func (_c *ReportDatasetCreate) SetGeneratedAt(v time.Time) *ReportDatasetCreate

SetGeneratedAt sets the "generated_at" field.

func (*ReportDatasetCreate) SetID

SetID sets the "id" field.

func (*ReportDatasetCreate) SetNillableCreatedAt

func (_c *ReportDatasetCreate) SetNillableCreatedAt(v *time.Time) *ReportDatasetCreate

SetNillableCreatedAt sets the "created_at" field if the given value is not nil.

func (*ReportDatasetCreate) SetNillableStatus

func (_c *ReportDatasetCreate) SetNillableStatus(v *string) *ReportDatasetCreate

SetNillableStatus sets the "status" field if the given value is not nil.

func (*ReportDatasetCreate) SetRankingPolicyID

func (_c *ReportDatasetCreate) SetRankingPolicyID(v string) *ReportDatasetCreate

SetRankingPolicyID sets the "ranking_policy_id" field.

func (*ReportDatasetCreate) SetRankingPolicyVersion

func (_c *ReportDatasetCreate) SetRankingPolicyVersion(v string) *ReportDatasetCreate

SetRankingPolicyVersion sets the "ranking_policy_version" field.

func (*ReportDatasetCreate) SetStatus

SetStatus sets the "status" field.

type ReportDatasetCreateBulk

type ReportDatasetCreateBulk struct {
	// contains filtered or unexported fields
}

ReportDatasetCreateBulk is the builder for creating many ReportDataset entities in bulk.

func (*ReportDatasetCreateBulk) Exec

Exec executes the query.

func (*ReportDatasetCreateBulk) ExecX

func (_c *ReportDatasetCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ReportDatasetCreateBulk) OnConflict

OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:

client.ReportDataset.CreateBulk(builders...).
	OnConflict(
		// Update the row with the new values
		// the was proposed for insertion.
		sql.ResolveWithNewValues(),
	).
	// Override some of the fields with custom
	// update values.
	Update(func(u *ent.ReportDatasetUpsert) {
		SetGeneratedAt(v+v).
	}).
	Exec(ctx)

func (*ReportDatasetCreateBulk) OnConflictColumns

func (_c *ReportDatasetCreateBulk) OnConflictColumns(columns ...string) *ReportDatasetUpsertBulk

OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:

client.ReportDataset.Create().
	OnConflict(sql.ConflictColumns(columns...)).
	Exec(ctx)

func (*ReportDatasetCreateBulk) Save

Save creates the ReportDataset entities in the database.

func (*ReportDatasetCreateBulk) SaveX

SaveX is like Save, but panics if an error occurs.

type ReportDatasetDelete

type ReportDatasetDelete struct {
	// contains filtered or unexported fields
}

ReportDatasetDelete is the builder for deleting a ReportDataset entity.

func (*ReportDatasetDelete) Exec

func (_d *ReportDatasetDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*ReportDatasetDelete) ExecX

func (_d *ReportDatasetDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*ReportDatasetDelete) Where

Where appends a list predicates to the ReportDatasetDelete builder.

type ReportDatasetDeleteOne

type ReportDatasetDeleteOne struct {
	// contains filtered or unexported fields
}

ReportDatasetDeleteOne is the builder for deleting a single ReportDataset entity.

func (*ReportDatasetDeleteOne) Exec

Exec executes the deletion query.

func (*ReportDatasetDeleteOne) ExecX

func (_d *ReportDatasetDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ReportDatasetDeleteOne) Where

Where appends a list predicates to the ReportDatasetDelete builder.

type ReportDatasetGroupBy

type ReportDatasetGroupBy struct {
	// contains filtered or unexported fields
}

ReportDatasetGroupBy is the group-by builder for ReportDataset entities.

func (*ReportDatasetGroupBy) Aggregate

Aggregate adds the given aggregation functions to the group-by query.

func (*ReportDatasetGroupBy) Bool

func (s *ReportDatasetGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*ReportDatasetGroupBy) BoolX

func (s *ReportDatasetGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*ReportDatasetGroupBy) Bools

func (s *ReportDatasetGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*ReportDatasetGroupBy) BoolsX

func (s *ReportDatasetGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*ReportDatasetGroupBy) Float64

func (s *ReportDatasetGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*ReportDatasetGroupBy) Float64X

func (s *ReportDatasetGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*ReportDatasetGroupBy) Float64s

func (s *ReportDatasetGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*ReportDatasetGroupBy) Float64sX

func (s *ReportDatasetGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*ReportDatasetGroupBy) Int

func (s *ReportDatasetGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*ReportDatasetGroupBy) IntX

func (s *ReportDatasetGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*ReportDatasetGroupBy) Ints

func (s *ReportDatasetGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*ReportDatasetGroupBy) IntsX

func (s *ReportDatasetGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*ReportDatasetGroupBy) Scan

func (_g *ReportDatasetGroupBy) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*ReportDatasetGroupBy) ScanX

func (s *ReportDatasetGroupBy) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*ReportDatasetGroupBy) String

func (s *ReportDatasetGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*ReportDatasetGroupBy) StringX

func (s *ReportDatasetGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*ReportDatasetGroupBy) Strings

func (s *ReportDatasetGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*ReportDatasetGroupBy) StringsX

func (s *ReportDatasetGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type ReportDatasetMutation

type ReportDatasetMutation struct {
	// contains filtered or unexported fields
}

ReportDatasetMutation represents an operation that mutates the ReportDataset nodes in the graph.

func (*ReportDatasetMutation) AddField

func (m *ReportDatasetMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*ReportDatasetMutation) AddedEdges

func (m *ReportDatasetMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*ReportDatasetMutation) AddedField

func (m *ReportDatasetMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*ReportDatasetMutation) AddedFields

func (m *ReportDatasetMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*ReportDatasetMutation) AddedIDs

func (m *ReportDatasetMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*ReportDatasetMutation) Canonical

func (m *ReportDatasetMutation) Canonical() (r assessment.ReportDataset, exists bool)

Canonical returns the value of the "canonical" field in the mutation.

func (*ReportDatasetMutation) ClearEdge

func (m *ReportDatasetMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*ReportDatasetMutation) ClearField

func (m *ReportDatasetMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*ReportDatasetMutation) ClearedEdges

func (m *ReportDatasetMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*ReportDatasetMutation) ClearedFields

func (m *ReportDatasetMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (ReportDatasetMutation) Client

func (m ReportDatasetMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*ReportDatasetMutation) CreatedAt

func (m *ReportDatasetMutation) CreatedAt() (r time.Time, exists bool)

CreatedAt returns the value of the "created_at" field in the mutation.

func (*ReportDatasetMutation) EdgeCleared

func (m *ReportDatasetMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*ReportDatasetMutation) Field

func (m *ReportDatasetMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*ReportDatasetMutation) FieldCleared

func (m *ReportDatasetMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*ReportDatasetMutation) Fields

func (m *ReportDatasetMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*ReportDatasetMutation) GeneratedAt

func (m *ReportDatasetMutation) GeneratedAt() (r time.Time, exists bool)

GeneratedAt returns the value of the "generated_at" field in the mutation.

func (*ReportDatasetMutation) ID

func (m *ReportDatasetMutation) ID() (id string, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*ReportDatasetMutation) IDs

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*ReportDatasetMutation) OldCanonical

func (m *ReportDatasetMutation) OldCanonical(ctx context.Context) (v assessment.ReportDataset, err error)

OldCanonical returns the old "canonical" field's value of the ReportDataset entity. If the ReportDataset object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ReportDatasetMutation) OldCreatedAt

func (m *ReportDatasetMutation) OldCreatedAt(ctx context.Context) (v time.Time, err error)

OldCreatedAt returns the old "created_at" field's value of the ReportDataset entity. If the ReportDataset object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ReportDatasetMutation) OldField

func (m *ReportDatasetMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*ReportDatasetMutation) OldGeneratedAt

func (m *ReportDatasetMutation) OldGeneratedAt(ctx context.Context) (v time.Time, err error)

OldGeneratedAt returns the old "generated_at" field's value of the ReportDataset entity. If the ReportDataset object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ReportDatasetMutation) OldRankingPolicyID

func (m *ReportDatasetMutation) OldRankingPolicyID(ctx context.Context) (v string, err error)

OldRankingPolicyID returns the old "ranking_policy_id" field's value of the ReportDataset entity. If the ReportDataset object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ReportDatasetMutation) OldRankingPolicyVersion

func (m *ReportDatasetMutation) OldRankingPolicyVersion(ctx context.Context) (v string, err error)

OldRankingPolicyVersion returns the old "ranking_policy_version" field's value of the ReportDataset entity. If the ReportDataset object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ReportDatasetMutation) OldStatus

func (m *ReportDatasetMutation) OldStatus(ctx context.Context) (v string, err error)

OldStatus returns the old "status" field's value of the ReportDataset entity. If the ReportDataset object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*ReportDatasetMutation) Op

func (m *ReportDatasetMutation) Op() Op

Op returns the operation name.

func (*ReportDatasetMutation) RankingPolicyID

func (m *ReportDatasetMutation) RankingPolicyID() (r string, exists bool)

RankingPolicyID returns the value of the "ranking_policy_id" field in the mutation.

func (*ReportDatasetMutation) RankingPolicyVersion

func (m *ReportDatasetMutation) RankingPolicyVersion() (r string, exists bool)

RankingPolicyVersion returns the value of the "ranking_policy_version" field in the mutation.

func (*ReportDatasetMutation) RemovedEdges

func (m *ReportDatasetMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*ReportDatasetMutation) RemovedIDs

func (m *ReportDatasetMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*ReportDatasetMutation) ResetCanonical

func (m *ReportDatasetMutation) ResetCanonical()

ResetCanonical resets all changes to the "canonical" field.

func (*ReportDatasetMutation) ResetCreatedAt

func (m *ReportDatasetMutation) ResetCreatedAt()

ResetCreatedAt resets all changes to the "created_at" field.

func (*ReportDatasetMutation) ResetEdge

func (m *ReportDatasetMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*ReportDatasetMutation) ResetField

func (m *ReportDatasetMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*ReportDatasetMutation) ResetGeneratedAt

func (m *ReportDatasetMutation) ResetGeneratedAt()

ResetGeneratedAt resets all changes to the "generated_at" field.

func (*ReportDatasetMutation) ResetRankingPolicyID

func (m *ReportDatasetMutation) ResetRankingPolicyID()

ResetRankingPolicyID resets all changes to the "ranking_policy_id" field.

func (*ReportDatasetMutation) ResetRankingPolicyVersion

func (m *ReportDatasetMutation) ResetRankingPolicyVersion()

ResetRankingPolicyVersion resets all changes to the "ranking_policy_version" field.

func (*ReportDatasetMutation) ResetStatus

func (m *ReportDatasetMutation) ResetStatus()

ResetStatus resets all changes to the "status" field.

func (*ReportDatasetMutation) SetCanonical

func (m *ReportDatasetMutation) SetCanonical(ad assessment.ReportDataset)

SetCanonical sets the "canonical" field.

func (*ReportDatasetMutation) SetCreatedAt

func (m *ReportDatasetMutation) SetCreatedAt(t time.Time)

SetCreatedAt sets the "created_at" field.

func (*ReportDatasetMutation) SetField

func (m *ReportDatasetMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*ReportDatasetMutation) SetGeneratedAt

func (m *ReportDatasetMutation) SetGeneratedAt(t time.Time)

SetGeneratedAt sets the "generated_at" field.

func (*ReportDatasetMutation) SetID

func (m *ReportDatasetMutation) SetID(id string)

SetID sets the value of the id field. Note that this operation is only accepted on creation of ReportDataset entities.

func (*ReportDatasetMutation) SetOp

func (m *ReportDatasetMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*ReportDatasetMutation) SetRankingPolicyID

func (m *ReportDatasetMutation) SetRankingPolicyID(s string)

SetRankingPolicyID sets the "ranking_policy_id" field.

func (*ReportDatasetMutation) SetRankingPolicyVersion

func (m *ReportDatasetMutation) SetRankingPolicyVersion(s string)

SetRankingPolicyVersion sets the "ranking_policy_version" field.

func (*ReportDatasetMutation) SetStatus

func (m *ReportDatasetMutation) SetStatus(s string)

SetStatus sets the "status" field.

func (*ReportDatasetMutation) Status

func (m *ReportDatasetMutation) Status() (r string, exists bool)

Status returns the value of the "status" field in the mutation.

func (ReportDatasetMutation) Tx

func (m ReportDatasetMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*ReportDatasetMutation) Type

func (m *ReportDatasetMutation) Type() string

Type returns the node type of this mutation (ReportDataset).

func (*ReportDatasetMutation) Where

Where appends a list predicates to the ReportDatasetMutation builder.

func (*ReportDatasetMutation) WhereP

func (m *ReportDatasetMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the ReportDatasetMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

type ReportDatasetQuery

type ReportDatasetQuery struct {
	// contains filtered or unexported fields
}

ReportDatasetQuery is the builder for querying ReportDataset entities.

func (*ReportDatasetQuery) Aggregate

func (_q *ReportDatasetQuery) Aggregate(fns ...AggregateFunc) *ReportDatasetSelect

Aggregate returns a ReportDatasetSelect configured with the given aggregations.

func (*ReportDatasetQuery) All

All executes the query and returns a list of ReportDatasets.

func (*ReportDatasetQuery) AllX

AllX is like All, but panics if an error occurs.

func (*ReportDatasetQuery) Clone

Clone returns a duplicate of the ReportDatasetQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*ReportDatasetQuery) Count

func (_q *ReportDatasetQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*ReportDatasetQuery) CountX

func (_q *ReportDatasetQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*ReportDatasetQuery) Exist

func (_q *ReportDatasetQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*ReportDatasetQuery) ExistX

func (_q *ReportDatasetQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*ReportDatasetQuery) First

First returns the first ReportDataset entity from the query. Returns a *NotFoundError when no ReportDataset was found.

func (*ReportDatasetQuery) FirstID

func (_q *ReportDatasetQuery) FirstID(ctx context.Context) (id string, err error)

FirstID returns the first ReportDataset ID from the query. Returns a *NotFoundError when no ReportDataset ID was found.

func (*ReportDatasetQuery) FirstIDX

func (_q *ReportDatasetQuery) FirstIDX(ctx context.Context) string

FirstIDX is like FirstID, but panics if an error occurs.

func (*ReportDatasetQuery) FirstX

FirstX is like First, but panics if an error occurs.

func (*ReportDatasetQuery) GroupBy

func (_q *ReportDatasetQuery) GroupBy(field string, fields ...string) *ReportDatasetGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	GeneratedAt time.Time `json:"generated_at,omitempty"`
	Count int `json:"count,omitempty"`
}

client.ReportDataset.Query().
	GroupBy(reportdataset.FieldGeneratedAt).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*ReportDatasetQuery) IDs

func (_q *ReportDatasetQuery) IDs(ctx context.Context) (ids []string, err error)

IDs executes the query and returns a list of ReportDataset IDs.

func (*ReportDatasetQuery) IDsX

func (_q *ReportDatasetQuery) IDsX(ctx context.Context) []string

IDsX is like IDs, but panics if an error occurs.

func (*ReportDatasetQuery) Limit

func (_q *ReportDatasetQuery) Limit(limit int) *ReportDatasetQuery

Limit the number of records to be returned by this query.

func (*ReportDatasetQuery) Offset

func (_q *ReportDatasetQuery) Offset(offset int) *ReportDatasetQuery

Offset to start from.

func (*ReportDatasetQuery) Only

Only returns a single ReportDataset entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one ReportDataset entity is found. Returns a *NotFoundError when no ReportDataset entities are found.

func (*ReportDatasetQuery) OnlyID

func (_q *ReportDatasetQuery) OnlyID(ctx context.Context) (id string, err error)

OnlyID is like Only, but returns the only ReportDataset ID in the query. Returns a *NotSingularError when more than one ReportDataset ID is found. Returns a *NotFoundError when no entities are found.

func (*ReportDatasetQuery) OnlyIDX

func (_q *ReportDatasetQuery) OnlyIDX(ctx context.Context) string

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*ReportDatasetQuery) OnlyX

OnlyX is like Only, but panics if an error occurs.

func (*ReportDatasetQuery) Order

Order specifies how the records should be ordered.

func (*ReportDatasetQuery) Select

func (_q *ReportDatasetQuery) Select(fields ...string) *ReportDatasetSelect

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	GeneratedAt time.Time `json:"generated_at,omitempty"`
}

client.ReportDataset.Query().
	Select(reportdataset.FieldGeneratedAt).
	Scan(ctx, &v)

func (*ReportDatasetQuery) Unique

func (_q *ReportDatasetQuery) Unique(unique bool) *ReportDatasetQuery

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*ReportDatasetQuery) Where

Where adds a new predicate for the ReportDatasetQuery builder.

type ReportDatasetSelect

type ReportDatasetSelect struct {
	*ReportDatasetQuery
	// contains filtered or unexported fields
}

ReportDatasetSelect is the builder for selecting fields of ReportDataset entities.

func (*ReportDatasetSelect) Aggregate

func (_s *ReportDatasetSelect) Aggregate(fns ...AggregateFunc) *ReportDatasetSelect

Aggregate adds the given aggregation functions to the selector query.

func (*ReportDatasetSelect) Bool

func (s *ReportDatasetSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*ReportDatasetSelect) BoolX

func (s *ReportDatasetSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*ReportDatasetSelect) Bools

func (s *ReportDatasetSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*ReportDatasetSelect) BoolsX

func (s *ReportDatasetSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*ReportDatasetSelect) Float64

func (s *ReportDatasetSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*ReportDatasetSelect) Float64X

func (s *ReportDatasetSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*ReportDatasetSelect) Float64s

func (s *ReportDatasetSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*ReportDatasetSelect) Float64sX

func (s *ReportDatasetSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*ReportDatasetSelect) Int

func (s *ReportDatasetSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*ReportDatasetSelect) IntX

func (s *ReportDatasetSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*ReportDatasetSelect) Ints

func (s *ReportDatasetSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*ReportDatasetSelect) IntsX

func (s *ReportDatasetSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*ReportDatasetSelect) Scan

func (_s *ReportDatasetSelect) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*ReportDatasetSelect) ScanX

func (s *ReportDatasetSelect) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*ReportDatasetSelect) String

func (s *ReportDatasetSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*ReportDatasetSelect) StringX

func (s *ReportDatasetSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*ReportDatasetSelect) Strings

func (s *ReportDatasetSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*ReportDatasetSelect) StringsX

func (s *ReportDatasetSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type ReportDatasetUpdate

type ReportDatasetUpdate struct {
	// contains filtered or unexported fields
}

ReportDatasetUpdate is the builder for updating ReportDataset entities.

func (*ReportDatasetUpdate) Exec

func (_u *ReportDatasetUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*ReportDatasetUpdate) ExecX

func (_u *ReportDatasetUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ReportDatasetUpdate) Mutation

Mutation returns the ReportDatasetMutation object of the builder.

func (*ReportDatasetUpdate) Save

func (_u *ReportDatasetUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*ReportDatasetUpdate) SaveX

func (_u *ReportDatasetUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*ReportDatasetUpdate) SetCanonical

SetCanonical sets the "canonical" field.

func (*ReportDatasetUpdate) SetGeneratedAt

func (_u *ReportDatasetUpdate) SetGeneratedAt(v time.Time) *ReportDatasetUpdate

SetGeneratedAt sets the "generated_at" field.

func (*ReportDatasetUpdate) SetNillableCanonical

func (_u *ReportDatasetUpdate) SetNillableCanonical(v *assessment.ReportDataset) *ReportDatasetUpdate

SetNillableCanonical sets the "canonical" field if the given value is not nil.

func (*ReportDatasetUpdate) SetNillableGeneratedAt

func (_u *ReportDatasetUpdate) SetNillableGeneratedAt(v *time.Time) *ReportDatasetUpdate

SetNillableGeneratedAt sets the "generated_at" field if the given value is not nil.

func (*ReportDatasetUpdate) SetNillableRankingPolicyID

func (_u *ReportDatasetUpdate) SetNillableRankingPolicyID(v *string) *ReportDatasetUpdate

SetNillableRankingPolicyID sets the "ranking_policy_id" field if the given value is not nil.

func (*ReportDatasetUpdate) SetNillableRankingPolicyVersion

func (_u *ReportDatasetUpdate) SetNillableRankingPolicyVersion(v *string) *ReportDatasetUpdate

SetNillableRankingPolicyVersion sets the "ranking_policy_version" field if the given value is not nil.

func (*ReportDatasetUpdate) SetNillableStatus

func (_u *ReportDatasetUpdate) SetNillableStatus(v *string) *ReportDatasetUpdate

SetNillableStatus sets the "status" field if the given value is not nil.

func (*ReportDatasetUpdate) SetRankingPolicyID

func (_u *ReportDatasetUpdate) SetRankingPolicyID(v string) *ReportDatasetUpdate

SetRankingPolicyID sets the "ranking_policy_id" field.

func (*ReportDatasetUpdate) SetRankingPolicyVersion

func (_u *ReportDatasetUpdate) SetRankingPolicyVersion(v string) *ReportDatasetUpdate

SetRankingPolicyVersion sets the "ranking_policy_version" field.

func (*ReportDatasetUpdate) SetStatus

SetStatus sets the "status" field.

func (*ReportDatasetUpdate) Where

Where appends a list predicates to the ReportDatasetUpdate builder.

type ReportDatasetUpdateOne

type ReportDatasetUpdateOne struct {
	// contains filtered or unexported fields
}

ReportDatasetUpdateOne is the builder for updating a single ReportDataset entity.

func (*ReportDatasetUpdateOne) Exec

Exec executes the query on the entity.

func (*ReportDatasetUpdateOne) ExecX

func (_u *ReportDatasetUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ReportDatasetUpdateOne) Mutation

Mutation returns the ReportDatasetMutation object of the builder.

func (*ReportDatasetUpdateOne) Save

Save executes the query and returns the updated ReportDataset entity.

func (*ReportDatasetUpdateOne) SaveX

SaveX is like Save, but panics if an error occurs.

func (*ReportDatasetUpdateOne) Select

func (_u *ReportDatasetUpdateOne) Select(field string, fields ...string) *ReportDatasetUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*ReportDatasetUpdateOne) SetCanonical

SetCanonical sets the "canonical" field.

func (*ReportDatasetUpdateOne) SetGeneratedAt

func (_u *ReportDatasetUpdateOne) SetGeneratedAt(v time.Time) *ReportDatasetUpdateOne

SetGeneratedAt sets the "generated_at" field.

func (*ReportDatasetUpdateOne) SetNillableCanonical

SetNillableCanonical sets the "canonical" field if the given value is not nil.

func (*ReportDatasetUpdateOne) SetNillableGeneratedAt

func (_u *ReportDatasetUpdateOne) SetNillableGeneratedAt(v *time.Time) *ReportDatasetUpdateOne

SetNillableGeneratedAt sets the "generated_at" field if the given value is not nil.

func (*ReportDatasetUpdateOne) SetNillableRankingPolicyID

func (_u *ReportDatasetUpdateOne) SetNillableRankingPolicyID(v *string) *ReportDatasetUpdateOne

SetNillableRankingPolicyID sets the "ranking_policy_id" field if the given value is not nil.

func (*ReportDatasetUpdateOne) SetNillableRankingPolicyVersion

func (_u *ReportDatasetUpdateOne) SetNillableRankingPolicyVersion(v *string) *ReportDatasetUpdateOne

SetNillableRankingPolicyVersion sets the "ranking_policy_version" field if the given value is not nil.

func (*ReportDatasetUpdateOne) SetNillableStatus

func (_u *ReportDatasetUpdateOne) SetNillableStatus(v *string) *ReportDatasetUpdateOne

SetNillableStatus sets the "status" field if the given value is not nil.

func (*ReportDatasetUpdateOne) SetRankingPolicyID

func (_u *ReportDatasetUpdateOne) SetRankingPolicyID(v string) *ReportDatasetUpdateOne

SetRankingPolicyID sets the "ranking_policy_id" field.

func (*ReportDatasetUpdateOne) SetRankingPolicyVersion

func (_u *ReportDatasetUpdateOne) SetRankingPolicyVersion(v string) *ReportDatasetUpdateOne

SetRankingPolicyVersion sets the "ranking_policy_version" field.

func (*ReportDatasetUpdateOne) SetStatus

SetStatus sets the "status" field.

func (*ReportDatasetUpdateOne) Where

Where appends a list predicates to the ReportDatasetUpdate builder.

type ReportDatasetUpsert

type ReportDatasetUpsert struct {
	*sql.UpdateSet
}

ReportDatasetUpsert is the "OnConflict" setter.

func (*ReportDatasetUpsert) SetCanonical

SetCanonical sets the "canonical" field.

func (*ReportDatasetUpsert) SetGeneratedAt

func (u *ReportDatasetUpsert) SetGeneratedAt(v time.Time) *ReportDatasetUpsert

SetGeneratedAt sets the "generated_at" field.

func (*ReportDatasetUpsert) SetRankingPolicyID

func (u *ReportDatasetUpsert) SetRankingPolicyID(v string) *ReportDatasetUpsert

SetRankingPolicyID sets the "ranking_policy_id" field.

func (*ReportDatasetUpsert) SetRankingPolicyVersion

func (u *ReportDatasetUpsert) SetRankingPolicyVersion(v string) *ReportDatasetUpsert

SetRankingPolicyVersion sets the "ranking_policy_version" field.

func (*ReportDatasetUpsert) SetStatus

SetStatus sets the "status" field.

func (*ReportDatasetUpsert) UpdateCanonical

func (u *ReportDatasetUpsert) UpdateCanonical() *ReportDatasetUpsert

UpdateCanonical sets the "canonical" field to the value that was provided on create.

func (*ReportDatasetUpsert) UpdateGeneratedAt

func (u *ReportDatasetUpsert) UpdateGeneratedAt() *ReportDatasetUpsert

UpdateGeneratedAt sets the "generated_at" field to the value that was provided on create.

func (*ReportDatasetUpsert) UpdateRankingPolicyID

func (u *ReportDatasetUpsert) UpdateRankingPolicyID() *ReportDatasetUpsert

UpdateRankingPolicyID sets the "ranking_policy_id" field to the value that was provided on create.

func (*ReportDatasetUpsert) UpdateRankingPolicyVersion

func (u *ReportDatasetUpsert) UpdateRankingPolicyVersion() *ReportDatasetUpsert

UpdateRankingPolicyVersion sets the "ranking_policy_version" field to the value that was provided on create.

func (*ReportDatasetUpsert) UpdateStatus

func (u *ReportDatasetUpsert) UpdateStatus() *ReportDatasetUpsert

UpdateStatus sets the "status" field to the value that was provided on create.

type ReportDatasetUpsertBulk

type ReportDatasetUpsertBulk struct {
	// contains filtered or unexported fields
}

ReportDatasetUpsertBulk is the builder for "upsert"-ing a bulk of ReportDataset nodes.

func (*ReportDatasetUpsertBulk) DoNothing

DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.

func (*ReportDatasetUpsertBulk) Exec

Exec executes the query.

func (*ReportDatasetUpsertBulk) ExecX

func (u *ReportDatasetUpsertBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ReportDatasetUpsertBulk) Ignore

Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:

client.ReportDataset.Create().
	OnConflict(sql.ResolveWithIgnore()).
	Exec(ctx)

func (*ReportDatasetUpsertBulk) SetCanonical

SetCanonical sets the "canonical" field.

func (*ReportDatasetUpsertBulk) SetGeneratedAt

SetGeneratedAt sets the "generated_at" field.

func (*ReportDatasetUpsertBulk) SetRankingPolicyID

func (u *ReportDatasetUpsertBulk) SetRankingPolicyID(v string) *ReportDatasetUpsertBulk

SetRankingPolicyID sets the "ranking_policy_id" field.

func (*ReportDatasetUpsertBulk) SetRankingPolicyVersion

func (u *ReportDatasetUpsertBulk) SetRankingPolicyVersion(v string) *ReportDatasetUpsertBulk

SetRankingPolicyVersion sets the "ranking_policy_version" field.

func (*ReportDatasetUpsertBulk) SetStatus

SetStatus sets the "status" field.

func (*ReportDatasetUpsertBulk) Update

Update allows overriding fields `UPDATE` values. See the ReportDatasetCreateBulk.OnConflict documentation for more info.

func (*ReportDatasetUpsertBulk) UpdateCanonical

func (u *ReportDatasetUpsertBulk) UpdateCanonical() *ReportDatasetUpsertBulk

UpdateCanonical sets the "canonical" field to the value that was provided on create.

func (*ReportDatasetUpsertBulk) UpdateGeneratedAt

func (u *ReportDatasetUpsertBulk) UpdateGeneratedAt() *ReportDatasetUpsertBulk

UpdateGeneratedAt sets the "generated_at" field to the value that was provided on create.

func (*ReportDatasetUpsertBulk) UpdateNewValues

func (u *ReportDatasetUpsertBulk) UpdateNewValues() *ReportDatasetUpsertBulk

UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:

client.ReportDataset.Create().
	OnConflict(
		sql.ResolveWithNewValues(),
		sql.ResolveWith(func(u *sql.UpdateSet) {
			u.SetIgnore(reportdataset.FieldID)
		}),
	).
	Exec(ctx)

func (*ReportDatasetUpsertBulk) UpdateRankingPolicyID

func (u *ReportDatasetUpsertBulk) UpdateRankingPolicyID() *ReportDatasetUpsertBulk

UpdateRankingPolicyID sets the "ranking_policy_id" field to the value that was provided on create.

func (*ReportDatasetUpsertBulk) UpdateRankingPolicyVersion

func (u *ReportDatasetUpsertBulk) UpdateRankingPolicyVersion() *ReportDatasetUpsertBulk

UpdateRankingPolicyVersion sets the "ranking_policy_version" field to the value that was provided on create.

func (*ReportDatasetUpsertBulk) UpdateStatus

UpdateStatus sets the "status" field to the value that was provided on create.

type ReportDatasetUpsertOne

type ReportDatasetUpsertOne struct {
	// contains filtered or unexported fields
}

ReportDatasetUpsertOne is the builder for "upsert"-ing

one ReportDataset node.

func (*ReportDatasetUpsertOne) DoNothing

DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.

func (*ReportDatasetUpsertOne) Exec

Exec executes the query.

func (*ReportDatasetUpsertOne) ExecX

func (u *ReportDatasetUpsertOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*ReportDatasetUpsertOne) ID

func (u *ReportDatasetUpsertOne) ID(ctx context.Context) (id string, err error)

Exec executes the UPSERT query and returns the inserted/updated ID.

func (*ReportDatasetUpsertOne) IDX

IDX is like ID, but panics if an error occurs.

func (*ReportDatasetUpsertOne) Ignore

Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:

client.ReportDataset.Create().
    OnConflict(sql.ResolveWithIgnore()).
    Exec(ctx)

func (*ReportDatasetUpsertOne) SetCanonical

SetCanonical sets the "canonical" field.

func (*ReportDatasetUpsertOne) SetGeneratedAt

SetGeneratedAt sets the "generated_at" field.

func (*ReportDatasetUpsertOne) SetRankingPolicyID

func (u *ReportDatasetUpsertOne) SetRankingPolicyID(v string) *ReportDatasetUpsertOne

SetRankingPolicyID sets the "ranking_policy_id" field.

func (*ReportDatasetUpsertOne) SetRankingPolicyVersion

func (u *ReportDatasetUpsertOne) SetRankingPolicyVersion(v string) *ReportDatasetUpsertOne

SetRankingPolicyVersion sets the "ranking_policy_version" field.

func (*ReportDatasetUpsertOne) SetStatus

SetStatus sets the "status" field.

func (*ReportDatasetUpsertOne) Update

Update allows overriding fields `UPDATE` values. See the ReportDatasetCreate.OnConflict documentation for more info.

func (*ReportDatasetUpsertOne) UpdateCanonical

func (u *ReportDatasetUpsertOne) UpdateCanonical() *ReportDatasetUpsertOne

UpdateCanonical sets the "canonical" field to the value that was provided on create.

func (*ReportDatasetUpsertOne) UpdateGeneratedAt

func (u *ReportDatasetUpsertOne) UpdateGeneratedAt() *ReportDatasetUpsertOne

UpdateGeneratedAt sets the "generated_at" field to the value that was provided on create.

func (*ReportDatasetUpsertOne) UpdateNewValues

func (u *ReportDatasetUpsertOne) UpdateNewValues() *ReportDatasetUpsertOne

UpdateNewValues updates the mutable fields using the new values that were set on create except the ID field. Using this option is equivalent to using:

client.ReportDataset.Create().
	OnConflict(
		sql.ResolveWithNewValues(),
		sql.ResolveWith(func(u *sql.UpdateSet) {
			u.SetIgnore(reportdataset.FieldID)
		}),
	).
	Exec(ctx)

func (*ReportDatasetUpsertOne) UpdateRankingPolicyID

func (u *ReportDatasetUpsertOne) UpdateRankingPolicyID() *ReportDatasetUpsertOne

UpdateRankingPolicyID sets the "ranking_policy_id" field to the value that was provided on create.

func (*ReportDatasetUpsertOne) UpdateRankingPolicyVersion

func (u *ReportDatasetUpsertOne) UpdateRankingPolicyVersion() *ReportDatasetUpsertOne

UpdateRankingPolicyVersion sets the "ranking_policy_version" field to the value that was provided on create.

func (*ReportDatasetUpsertOne) UpdateStatus

UpdateStatus sets the "status" field to the value that was provided on create.

type ReportDatasets

type ReportDatasets []*ReportDataset

ReportDatasets is a parsable slice of ReportDataset.

type RollbackFunc

type RollbackFunc func(context.Context, *Tx) error

The RollbackFunc type is an adapter to allow the use of ordinary function as a Rollbacker. If f is a function with the appropriate signature, RollbackFunc(f) is a Rollbacker that calls f.

func (RollbackFunc) Rollback

func (f RollbackFunc) Rollback(ctx context.Context, tx *Tx) error

Rollback calls f(ctx, m).

type RollbackHook

type RollbackHook func(Rollbacker) Rollbacker

RollbackHook defines the "rollback middleware". A function that gets a Rollbacker and returns a Rollbacker. For example:

hook := func(next ent.Rollbacker) ent.Rollbacker {
	return ent.RollbackFunc(func(ctx context.Context, tx *ent.Tx) error {
		// Do some stuff before.
		if err := next.Rollback(ctx, tx); err != nil {
			return err
		}
		// Do some stuff after.
		return nil
	})
}

type Rollbacker

type Rollbacker interface {
	Rollback(context.Context, *Tx) error
}

Rollbacker is the interface that wraps the Rollback method.

type SyncMeta

type SyncMeta struct {

	// ID of the ent.
	ID int `json:"id,omitempty"`
	// Provider holds the value of the "provider" field.
	Provider string `json:"provider,omitempty"`
	// Kind holds the value of the "kind" field.
	Kind string `json:"kind,omitempty"`
	// LastSync holds the value of the "last_sync" field.
	LastSync time.Time `json:"last_sync,omitempty"`
	// RecordCount holds the value of the "record_count" field.
	RecordCount int `json:"record_count,omitempty"`
	// contains filtered or unexported fields
}

SyncMeta is the model entity for the SyncMeta schema.

func (*SyncMeta) String

func (_m *SyncMeta) String() string

String implements the fmt.Stringer.

func (*SyncMeta) Unwrap

func (_m *SyncMeta) Unwrap() *SyncMeta

Unwrap unwraps the SyncMeta entity that was returned from a transaction after it was closed, so that all future queries will be executed through the driver which created the transaction.

func (*SyncMeta) Update

func (_m *SyncMeta) Update() *SyncMetaUpdateOne

Update returns a builder for updating this SyncMeta. Note that you need to call SyncMeta.Unwrap() before calling this method if this SyncMeta was returned from a transaction, and the transaction was committed or rolled back.

func (*SyncMeta) Value

func (_m *SyncMeta) Value(name string) (ent.Value, error)

Value returns the ent.Value that was dynamically selected and assigned to the SyncMeta. This includes values selected through modifiers, order, etc.

type SyncMetaClient

type SyncMetaClient struct {
	// contains filtered or unexported fields
}

SyncMetaClient is a client for the SyncMeta schema.

func NewSyncMetaClient

func NewSyncMetaClient(c config) *SyncMetaClient

NewSyncMetaClient returns a client for the SyncMeta from the given config.

func (*SyncMetaClient) Create

func (c *SyncMetaClient) Create() *SyncMetaCreate

Create returns a builder for creating a SyncMeta entity.

func (*SyncMetaClient) CreateBulk

func (c *SyncMetaClient) CreateBulk(builders ...*SyncMetaCreate) *SyncMetaCreateBulk

CreateBulk returns a builder for creating a bulk of SyncMeta entities.

func (*SyncMetaClient) Delete

func (c *SyncMetaClient) Delete() *SyncMetaDelete

Delete returns a delete builder for SyncMeta.

func (*SyncMetaClient) DeleteOne

func (c *SyncMetaClient) DeleteOne(_m *SyncMeta) *SyncMetaDeleteOne

DeleteOne returns a builder for deleting the given entity.

func (*SyncMetaClient) DeleteOneID

func (c *SyncMetaClient) DeleteOneID(id int) *SyncMetaDeleteOne

DeleteOneID returns a builder for deleting the given entity by its id.

func (*SyncMetaClient) Get

func (c *SyncMetaClient) Get(ctx context.Context, id int) (*SyncMeta, error)

Get returns a SyncMeta entity by its id.

func (*SyncMetaClient) GetX

func (c *SyncMetaClient) GetX(ctx context.Context, id int) *SyncMeta

GetX is like Get, but panics if an error occurs.

func (*SyncMetaClient) Hooks

func (c *SyncMetaClient) Hooks() []Hook

Hooks returns the client hooks.

func (*SyncMetaClient) Intercept

func (c *SyncMetaClient) Intercept(interceptors ...Interceptor)

Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `syncmeta.Intercept(f(g(h())))`.

func (*SyncMetaClient) Interceptors

func (c *SyncMetaClient) Interceptors() []Interceptor

Interceptors returns the client interceptors.

func (*SyncMetaClient) MapCreateBulk

func (c *SyncMetaClient) MapCreateBulk(slice any, setFunc func(*SyncMetaCreate, int)) *SyncMetaCreateBulk

MapCreateBulk creates a bulk creation builder from the given slice. For each item in the slice, the function creates a builder and applies setFunc on it.

func (*SyncMetaClient) Query

func (c *SyncMetaClient) Query() *SyncMetaQuery

Query returns a query builder for SyncMeta.

func (*SyncMetaClient) Update

func (c *SyncMetaClient) Update() *SyncMetaUpdate

Update returns an update builder for SyncMeta.

func (*SyncMetaClient) UpdateOne

func (c *SyncMetaClient) UpdateOne(_m *SyncMeta) *SyncMetaUpdateOne

UpdateOne returns an update builder for the given entity.

func (*SyncMetaClient) UpdateOneID

func (c *SyncMetaClient) UpdateOneID(id int) *SyncMetaUpdateOne

UpdateOneID returns an update builder for the given id.

func (*SyncMetaClient) Use

func (c *SyncMetaClient) Use(hooks ...Hook)

Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `syncmeta.Hooks(f(g(h())))`.

type SyncMetaCreate

type SyncMetaCreate struct {
	// contains filtered or unexported fields
}

SyncMetaCreate is the builder for creating a SyncMeta entity.

func (*SyncMetaCreate) Exec

func (_c *SyncMetaCreate) Exec(ctx context.Context) error

Exec executes the query.

func (*SyncMetaCreate) ExecX

func (_c *SyncMetaCreate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*SyncMetaCreate) Mutation

func (_c *SyncMetaCreate) Mutation() *SyncMetaMutation

Mutation returns the SyncMetaMutation object of the builder.

func (*SyncMetaCreate) OnConflict

func (_c *SyncMetaCreate) OnConflict(opts ...sql.ConflictOption) *SyncMetaUpsertOne

OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:

client.SyncMeta.Create().
	SetProvider(v).
	OnConflict(
		// Update the row with the new values
		// the was proposed for insertion.
		sql.ResolveWithNewValues(),
	).
	// Override some of the fields with custom
	// update values.
	Update(func(u *ent.SyncMetaUpsert) {
		SetProvider(v+v).
	}).
	Exec(ctx)

func (*SyncMetaCreate) OnConflictColumns

func (_c *SyncMetaCreate) OnConflictColumns(columns ...string) *SyncMetaUpsertOne

OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:

client.SyncMeta.Create().
	OnConflict(sql.ConflictColumns(columns...)).
	Exec(ctx)

func (*SyncMetaCreate) Save

func (_c *SyncMetaCreate) Save(ctx context.Context) (*SyncMeta, error)

Save creates the SyncMeta in the database.

func (*SyncMetaCreate) SaveX

func (_c *SyncMetaCreate) SaveX(ctx context.Context) *SyncMeta

SaveX calls Save and panics if Save returns an error.

func (*SyncMetaCreate) SetKind

func (_c *SyncMetaCreate) SetKind(v string) *SyncMetaCreate

SetKind sets the "kind" field.

func (*SyncMetaCreate) SetLastSync

func (_c *SyncMetaCreate) SetLastSync(v time.Time) *SyncMetaCreate

SetLastSync sets the "last_sync" field.

func (*SyncMetaCreate) SetNillableRecordCount

func (_c *SyncMetaCreate) SetNillableRecordCount(v *int) *SyncMetaCreate

SetNillableRecordCount sets the "record_count" field if the given value is not nil.

func (*SyncMetaCreate) SetProvider

func (_c *SyncMetaCreate) SetProvider(v string) *SyncMetaCreate

SetProvider sets the "provider" field.

func (*SyncMetaCreate) SetRecordCount

func (_c *SyncMetaCreate) SetRecordCount(v int) *SyncMetaCreate

SetRecordCount sets the "record_count" field.

type SyncMetaCreateBulk

type SyncMetaCreateBulk struct {
	// contains filtered or unexported fields
}

SyncMetaCreateBulk is the builder for creating many SyncMeta entities in bulk.

func (*SyncMetaCreateBulk) Exec

func (_c *SyncMetaCreateBulk) Exec(ctx context.Context) error

Exec executes the query.

func (*SyncMetaCreateBulk) ExecX

func (_c *SyncMetaCreateBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*SyncMetaCreateBulk) OnConflict

func (_c *SyncMetaCreateBulk) OnConflict(opts ...sql.ConflictOption) *SyncMetaUpsertBulk

OnConflict allows configuring the `ON CONFLICT` / `ON DUPLICATE KEY` clause of the `INSERT` statement. For example:

client.SyncMeta.CreateBulk(builders...).
	OnConflict(
		// Update the row with the new values
		// the was proposed for insertion.
		sql.ResolveWithNewValues(),
	).
	// Override some of the fields with custom
	// update values.
	Update(func(u *ent.SyncMetaUpsert) {
		SetProvider(v+v).
	}).
	Exec(ctx)

func (*SyncMetaCreateBulk) OnConflictColumns

func (_c *SyncMetaCreateBulk) OnConflictColumns(columns ...string) *SyncMetaUpsertBulk

OnConflictColumns calls `OnConflict` and configures the columns as conflict target. Using this option is equivalent to using:

client.SyncMeta.Create().
	OnConflict(sql.ConflictColumns(columns...)).
	Exec(ctx)

func (*SyncMetaCreateBulk) Save

func (_c *SyncMetaCreateBulk) Save(ctx context.Context) ([]*SyncMeta, error)

Save creates the SyncMeta entities in the database.

func (*SyncMetaCreateBulk) SaveX

func (_c *SyncMetaCreateBulk) SaveX(ctx context.Context) []*SyncMeta

SaveX is like Save, but panics if an error occurs.

type SyncMetaDelete

type SyncMetaDelete struct {
	// contains filtered or unexported fields
}

SyncMetaDelete is the builder for deleting a SyncMeta entity.

func (*SyncMetaDelete) Exec

func (_d *SyncMetaDelete) Exec(ctx context.Context) (int, error)

Exec executes the deletion query and returns how many vertices were deleted.

func (*SyncMetaDelete) ExecX

func (_d *SyncMetaDelete) ExecX(ctx context.Context) int

ExecX is like Exec, but panics if an error occurs.

func (*SyncMetaDelete) Where

func (_d *SyncMetaDelete) Where(ps ...predicate.SyncMeta) *SyncMetaDelete

Where appends a list predicates to the SyncMetaDelete builder.

type SyncMetaDeleteOne

type SyncMetaDeleteOne struct {
	// contains filtered or unexported fields
}

SyncMetaDeleteOne is the builder for deleting a single SyncMeta entity.

func (*SyncMetaDeleteOne) Exec

func (_d *SyncMetaDeleteOne) Exec(ctx context.Context) error

Exec executes the deletion query.

func (*SyncMetaDeleteOne) ExecX

func (_d *SyncMetaDeleteOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*SyncMetaDeleteOne) Where

Where appends a list predicates to the SyncMetaDelete builder.

type SyncMetaGroupBy

type SyncMetaGroupBy struct {
	// contains filtered or unexported fields
}

SyncMetaGroupBy is the group-by builder for SyncMeta entities.

func (*SyncMetaGroupBy) Aggregate

func (_g *SyncMetaGroupBy) Aggregate(fns ...AggregateFunc) *SyncMetaGroupBy

Aggregate adds the given aggregation functions to the group-by query.

func (*SyncMetaGroupBy) Bool

func (s *SyncMetaGroupBy) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*SyncMetaGroupBy) BoolX

func (s *SyncMetaGroupBy) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*SyncMetaGroupBy) Bools

func (s *SyncMetaGroupBy) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*SyncMetaGroupBy) BoolsX

func (s *SyncMetaGroupBy) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*SyncMetaGroupBy) Float64

func (s *SyncMetaGroupBy) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*SyncMetaGroupBy) Float64X

func (s *SyncMetaGroupBy) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*SyncMetaGroupBy) Float64s

func (s *SyncMetaGroupBy) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*SyncMetaGroupBy) Float64sX

func (s *SyncMetaGroupBy) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*SyncMetaGroupBy) Int

func (s *SyncMetaGroupBy) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*SyncMetaGroupBy) IntX

func (s *SyncMetaGroupBy) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*SyncMetaGroupBy) Ints

func (s *SyncMetaGroupBy) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*SyncMetaGroupBy) IntsX

func (s *SyncMetaGroupBy) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*SyncMetaGroupBy) Scan

func (_g *SyncMetaGroupBy) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*SyncMetaGroupBy) ScanX

func (s *SyncMetaGroupBy) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*SyncMetaGroupBy) String

func (s *SyncMetaGroupBy) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*SyncMetaGroupBy) StringX

func (s *SyncMetaGroupBy) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*SyncMetaGroupBy) Strings

func (s *SyncMetaGroupBy) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*SyncMetaGroupBy) StringsX

func (s *SyncMetaGroupBy) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type SyncMetaMutation

type SyncMetaMutation struct {
	// contains filtered or unexported fields
}

SyncMetaMutation represents an operation that mutates the SyncMeta nodes in the graph.

func (*SyncMetaMutation) AddField

func (m *SyncMetaMutation) AddField(name string, value ent.Value) error

AddField adds the value to the field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*SyncMetaMutation) AddRecordCount

func (m *SyncMetaMutation) AddRecordCount(i int)

AddRecordCount adds i to the "record_count" field.

func (*SyncMetaMutation) AddedEdges

func (m *SyncMetaMutation) AddedEdges() []string

AddedEdges returns all edge names that were set/added in this mutation.

func (*SyncMetaMutation) AddedField

func (m *SyncMetaMutation) AddedField(name string) (ent.Value, bool)

AddedField returns the numeric value that was incremented/decremented on a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*SyncMetaMutation) AddedFields

func (m *SyncMetaMutation) AddedFields() []string

AddedFields returns all numeric fields that were incremented/decremented during this mutation.

func (*SyncMetaMutation) AddedIDs

func (m *SyncMetaMutation) AddedIDs(name string) []ent.Value

AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.

func (*SyncMetaMutation) AddedRecordCount

func (m *SyncMetaMutation) AddedRecordCount() (r int, exists bool)

AddedRecordCount returns the value that was added to the "record_count" field in this mutation.

func (*SyncMetaMutation) ClearEdge

func (m *SyncMetaMutation) ClearEdge(name string) error

ClearEdge clears the value of the edge with the given name. It returns an error if that edge is not defined in the schema.

func (*SyncMetaMutation) ClearField

func (m *SyncMetaMutation) ClearField(name string) error

ClearField clears the value of the field with the given name. It returns an error if the field is not defined in the schema.

func (*SyncMetaMutation) ClearedEdges

func (m *SyncMetaMutation) ClearedEdges() []string

ClearedEdges returns all edge names that were cleared in this mutation.

func (*SyncMetaMutation) ClearedFields

func (m *SyncMetaMutation) ClearedFields() []string

ClearedFields returns all nullable fields that were cleared during this mutation.

func (SyncMetaMutation) Client

func (m SyncMetaMutation) Client() *Client

Client returns a new `ent.Client` from the mutation. If the mutation was executed in a transaction (ent.Tx), a transactional client is returned.

func (*SyncMetaMutation) EdgeCleared

func (m *SyncMetaMutation) EdgeCleared(name string) bool

EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.

func (*SyncMetaMutation) Field

func (m *SyncMetaMutation) Field(name string) (ent.Value, bool)

Field returns the value of a field with the given name. The second boolean return value indicates that this field was not set, or was not defined in the schema.

func (*SyncMetaMutation) FieldCleared

func (m *SyncMetaMutation) FieldCleared(name string) bool

FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.

func (*SyncMetaMutation) Fields

func (m *SyncMetaMutation) Fields() []string

Fields returns all fields that were changed during this mutation. Note that in order to get all numeric fields that were incremented/decremented, call AddedFields().

func (*SyncMetaMutation) ID

func (m *SyncMetaMutation) ID() (id int, exists bool)

ID returns the ID value in the mutation. Note that the ID is only available if it was provided to the builder or after it was returned from the database.

func (*SyncMetaMutation) IDs

func (m *SyncMetaMutation) IDs(ctx context.Context) ([]int, error)

IDs queries the database and returns the entity ids that match the mutation's predicate. That means, if the mutation is applied within a transaction with an isolation level such as sql.LevelSerializable, the returned ids match the ids of the rows that will be updated or updated by the mutation.

func (*SyncMetaMutation) Kind

func (m *SyncMetaMutation) Kind() (r string, exists bool)

Kind returns the value of the "kind" field in the mutation.

func (*SyncMetaMutation) LastSync

func (m *SyncMetaMutation) LastSync() (r time.Time, exists bool)

LastSync returns the value of the "last_sync" field in the mutation.

func (*SyncMetaMutation) OldField

func (m *SyncMetaMutation) OldField(ctx context.Context, name string) (ent.Value, error)

OldField returns the old value of the field from the database. An error is returned if the mutation operation is not UpdateOne, or the query to the database failed.

func (*SyncMetaMutation) OldKind

func (m *SyncMetaMutation) OldKind(ctx context.Context) (v string, err error)

OldKind returns the old "kind" field's value of the SyncMeta entity. If the SyncMeta object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*SyncMetaMutation) OldLastSync

func (m *SyncMetaMutation) OldLastSync(ctx context.Context) (v time.Time, err error)

OldLastSync returns the old "last_sync" field's value of the SyncMeta entity. If the SyncMeta object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*SyncMetaMutation) OldProvider

func (m *SyncMetaMutation) OldProvider(ctx context.Context) (v string, err error)

OldProvider returns the old "provider" field's value of the SyncMeta entity. If the SyncMeta object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*SyncMetaMutation) OldRecordCount

func (m *SyncMetaMutation) OldRecordCount(ctx context.Context) (v int, err error)

OldRecordCount returns the old "record_count" field's value of the SyncMeta entity. If the SyncMeta object wasn't provided to the builder, the object is fetched from the database. An error is returned if the mutation operation is not UpdateOne, or the database query fails.

func (*SyncMetaMutation) Op

func (m *SyncMetaMutation) Op() Op

Op returns the operation name.

func (*SyncMetaMutation) Provider

func (m *SyncMetaMutation) Provider() (r string, exists bool)

Provider returns the value of the "provider" field in the mutation.

func (*SyncMetaMutation) RecordCount

func (m *SyncMetaMutation) RecordCount() (r int, exists bool)

RecordCount returns the value of the "record_count" field in the mutation.

func (*SyncMetaMutation) RemovedEdges

func (m *SyncMetaMutation) RemovedEdges() []string

RemovedEdges returns all edge names that were removed in this mutation.

func (*SyncMetaMutation) RemovedIDs

func (m *SyncMetaMutation) RemovedIDs(name string) []ent.Value

RemovedIDs returns all IDs (to other nodes) that were removed for the edge with the given name in this mutation.

func (*SyncMetaMutation) ResetEdge

func (m *SyncMetaMutation) ResetEdge(name string) error

ResetEdge resets all changes to the edge with the given name in this mutation. It returns an error if the edge is not defined in the schema.

func (*SyncMetaMutation) ResetField

func (m *SyncMetaMutation) ResetField(name string) error

ResetField resets all changes in the mutation for the field with the given name. It returns an error if the field is not defined in the schema.

func (*SyncMetaMutation) ResetKind

func (m *SyncMetaMutation) ResetKind()

ResetKind resets all changes to the "kind" field.

func (*SyncMetaMutation) ResetLastSync

func (m *SyncMetaMutation) ResetLastSync()

ResetLastSync resets all changes to the "last_sync" field.

func (*SyncMetaMutation) ResetProvider

func (m *SyncMetaMutation) ResetProvider()

ResetProvider resets all changes to the "provider" field.

func (*SyncMetaMutation) ResetRecordCount

func (m *SyncMetaMutation) ResetRecordCount()

ResetRecordCount resets all changes to the "record_count" field.

func (*SyncMetaMutation) SetField

func (m *SyncMetaMutation) SetField(name string, value ent.Value) error

SetField sets the value of a field with the given name. It returns an error if the field is not defined in the schema, or if the type mismatched the field type.

func (*SyncMetaMutation) SetKind

func (m *SyncMetaMutation) SetKind(s string)

SetKind sets the "kind" field.

func (*SyncMetaMutation) SetLastSync

func (m *SyncMetaMutation) SetLastSync(t time.Time)

SetLastSync sets the "last_sync" field.

func (*SyncMetaMutation) SetOp

func (m *SyncMetaMutation) SetOp(op Op)

SetOp allows setting the mutation operation.

func (*SyncMetaMutation) SetProvider

func (m *SyncMetaMutation) SetProvider(s string)

SetProvider sets the "provider" field.

func (*SyncMetaMutation) SetRecordCount

func (m *SyncMetaMutation) SetRecordCount(i int)

SetRecordCount sets the "record_count" field.

func (SyncMetaMutation) Tx

func (m SyncMetaMutation) Tx() (*Tx, error)

Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.

func (*SyncMetaMutation) Type

func (m *SyncMetaMutation) Type() string

Type returns the node type of this mutation (SyncMeta).

func (*SyncMetaMutation) Where

func (m *SyncMetaMutation) Where(ps ...predicate.SyncMeta)

Where appends a list predicates to the SyncMetaMutation builder.

func (*SyncMetaMutation) WhereP

func (m *SyncMetaMutation) WhereP(ps ...func(*sql.Selector))

WhereP appends storage-level predicates to the SyncMetaMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.

type SyncMetaQuery

type SyncMetaQuery struct {
	// contains filtered or unexported fields
}

SyncMetaQuery is the builder for querying SyncMeta entities.

func (*SyncMetaQuery) Aggregate

func (_q *SyncMetaQuery) Aggregate(fns ...AggregateFunc) *SyncMetaSelect

Aggregate returns a SyncMetaSelect configured with the given aggregations.

func (*SyncMetaQuery) All

func (_q *SyncMetaQuery) All(ctx context.Context) ([]*SyncMeta, error)

All executes the query and returns a list of SyncMetaSlice.

func (*SyncMetaQuery) AllX

func (_q *SyncMetaQuery) AllX(ctx context.Context) []*SyncMeta

AllX is like All, but panics if an error occurs.

func (*SyncMetaQuery) Clone

func (_q *SyncMetaQuery) Clone() *SyncMetaQuery

Clone returns a duplicate of the SyncMetaQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.

func (*SyncMetaQuery) Count

func (_q *SyncMetaQuery) Count(ctx context.Context) (int, error)

Count returns the count of the given query.

func (*SyncMetaQuery) CountX

func (_q *SyncMetaQuery) CountX(ctx context.Context) int

CountX is like Count, but panics if an error occurs.

func (*SyncMetaQuery) Exist

func (_q *SyncMetaQuery) Exist(ctx context.Context) (bool, error)

Exist returns true if the query has elements in the graph.

func (*SyncMetaQuery) ExistX

func (_q *SyncMetaQuery) ExistX(ctx context.Context) bool

ExistX is like Exist, but panics if an error occurs.

func (*SyncMetaQuery) First

func (_q *SyncMetaQuery) First(ctx context.Context) (*SyncMeta, error)

First returns the first SyncMeta entity from the query. Returns a *NotFoundError when no SyncMeta was found.

func (*SyncMetaQuery) FirstID

func (_q *SyncMetaQuery) FirstID(ctx context.Context) (id int, err error)

FirstID returns the first SyncMeta ID from the query. Returns a *NotFoundError when no SyncMeta ID was found.

func (*SyncMetaQuery) FirstIDX

func (_q *SyncMetaQuery) FirstIDX(ctx context.Context) int

FirstIDX is like FirstID, but panics if an error occurs.

func (*SyncMetaQuery) FirstX

func (_q *SyncMetaQuery) FirstX(ctx context.Context) *SyncMeta

FirstX is like First, but panics if an error occurs.

func (*SyncMetaQuery) GroupBy

func (_q *SyncMetaQuery) GroupBy(field string, fields ...string) *SyncMetaGroupBy

GroupBy is used to group vertices by one or more fields/columns. It is often used with aggregate functions, like: count, max, mean, min, sum.

Example:

var v []struct {
	Provider string `json:"provider,omitempty"`
	Count int `json:"count,omitempty"`
}

client.SyncMeta.Query().
	GroupBy(syncmeta.FieldProvider).
	Aggregate(ent.Count()).
	Scan(ctx, &v)

func (*SyncMetaQuery) IDs

func (_q *SyncMetaQuery) IDs(ctx context.Context) (ids []int, err error)

IDs executes the query and returns a list of SyncMeta IDs.

func (*SyncMetaQuery) IDsX

func (_q *SyncMetaQuery) IDsX(ctx context.Context) []int

IDsX is like IDs, but panics if an error occurs.

func (*SyncMetaQuery) Limit

func (_q *SyncMetaQuery) Limit(limit int) *SyncMetaQuery

Limit the number of records to be returned by this query.

func (*SyncMetaQuery) Offset

func (_q *SyncMetaQuery) Offset(offset int) *SyncMetaQuery

Offset to start from.

func (*SyncMetaQuery) Only

func (_q *SyncMetaQuery) Only(ctx context.Context) (*SyncMeta, error)

Only returns a single SyncMeta entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one SyncMeta entity is found. Returns a *NotFoundError when no SyncMeta entities are found.

func (*SyncMetaQuery) OnlyID

func (_q *SyncMetaQuery) OnlyID(ctx context.Context) (id int, err error)

OnlyID is like Only, but returns the only SyncMeta ID in the query. Returns a *NotSingularError when more than one SyncMeta ID is found. Returns a *NotFoundError when no entities are found.

func (*SyncMetaQuery) OnlyIDX

func (_q *SyncMetaQuery) OnlyIDX(ctx context.Context) int

OnlyIDX is like OnlyID, but panics if an error occurs.

func (*SyncMetaQuery) OnlyX

func (_q *SyncMetaQuery) OnlyX(ctx context.Context) *SyncMeta

OnlyX is like Only, but panics if an error occurs.

func (*SyncMetaQuery) Order

Order specifies how the records should be ordered.

func (*SyncMetaQuery) Select

func (_q *SyncMetaQuery) Select(fields ...string) *SyncMetaSelect

Select allows the selection one or more fields/columns for the given query, instead of selecting all fields in the entity.

Example:

var v []struct {
	Provider string `json:"provider,omitempty"`
}

client.SyncMeta.Query().
	Select(syncmeta.FieldProvider).
	Scan(ctx, &v)

func (*SyncMetaQuery) Unique

func (_q *SyncMetaQuery) Unique(unique bool) *SyncMetaQuery

Unique configures the query builder to filter duplicate records on query. By default, unique is set to true, and can be disabled using this method.

func (*SyncMetaQuery) Where

func (_q *SyncMetaQuery) Where(ps ...predicate.SyncMeta) *SyncMetaQuery

Where adds a new predicate for the SyncMetaQuery builder.

type SyncMetaSelect

type SyncMetaSelect struct {
	*SyncMetaQuery
	// contains filtered or unexported fields
}

SyncMetaSelect is the builder for selecting fields of SyncMeta entities.

func (*SyncMetaSelect) Aggregate

func (_s *SyncMetaSelect) Aggregate(fns ...AggregateFunc) *SyncMetaSelect

Aggregate adds the given aggregation functions to the selector query.

func (*SyncMetaSelect) Bool

func (s *SyncMetaSelect) Bool(ctx context.Context) (_ bool, err error)

Bool returns a single bool from a selector. It is only allowed when selecting one field.

func (*SyncMetaSelect) BoolX

func (s *SyncMetaSelect) BoolX(ctx context.Context) bool

BoolX is like Bool, but panics if an error occurs.

func (*SyncMetaSelect) Bools

func (s *SyncMetaSelect) Bools(ctx context.Context) ([]bool, error)

Bools returns list of bools from a selector. It is only allowed when selecting one field.

func (*SyncMetaSelect) BoolsX

func (s *SyncMetaSelect) BoolsX(ctx context.Context) []bool

BoolsX is like Bools, but panics if an error occurs.

func (*SyncMetaSelect) Float64

func (s *SyncMetaSelect) Float64(ctx context.Context) (_ float64, err error)

Float64 returns a single float64 from a selector. It is only allowed when selecting one field.

func (*SyncMetaSelect) Float64X

func (s *SyncMetaSelect) Float64X(ctx context.Context) float64

Float64X is like Float64, but panics if an error occurs.

func (*SyncMetaSelect) Float64s

func (s *SyncMetaSelect) Float64s(ctx context.Context) ([]float64, error)

Float64s returns list of float64s from a selector. It is only allowed when selecting one field.

func (*SyncMetaSelect) Float64sX

func (s *SyncMetaSelect) Float64sX(ctx context.Context) []float64

Float64sX is like Float64s, but panics if an error occurs.

func (*SyncMetaSelect) Int

func (s *SyncMetaSelect) Int(ctx context.Context) (_ int, err error)

Int returns a single int from a selector. It is only allowed when selecting one field.

func (*SyncMetaSelect) IntX

func (s *SyncMetaSelect) IntX(ctx context.Context) int

IntX is like Int, but panics if an error occurs.

func (*SyncMetaSelect) Ints

func (s *SyncMetaSelect) Ints(ctx context.Context) ([]int, error)

Ints returns list of ints from a selector. It is only allowed when selecting one field.

func (*SyncMetaSelect) IntsX

func (s *SyncMetaSelect) IntsX(ctx context.Context) []int

IntsX is like Ints, but panics if an error occurs.

func (*SyncMetaSelect) Scan

func (_s *SyncMetaSelect) Scan(ctx context.Context, v any) error

Scan applies the selector query and scans the result into the given value.

func (*SyncMetaSelect) ScanX

func (s *SyncMetaSelect) ScanX(ctx context.Context, v any)

ScanX is like Scan, but panics if an error occurs.

func (*SyncMetaSelect) String

func (s *SyncMetaSelect) String(ctx context.Context) (_ string, err error)

String returns a single string from a selector. It is only allowed when selecting one field.

func (*SyncMetaSelect) StringX

func (s *SyncMetaSelect) StringX(ctx context.Context) string

StringX is like String, but panics if an error occurs.

func (*SyncMetaSelect) Strings

func (s *SyncMetaSelect) Strings(ctx context.Context) ([]string, error)

Strings returns list of strings from a selector. It is only allowed when selecting one field.

func (*SyncMetaSelect) StringsX

func (s *SyncMetaSelect) StringsX(ctx context.Context) []string

StringsX is like Strings, but panics if an error occurs.

type SyncMetaSlice

type SyncMetaSlice []*SyncMeta

SyncMetaSlice is a parsable slice of SyncMeta.

type SyncMetaUpdate

type SyncMetaUpdate struct {
	// contains filtered or unexported fields
}

SyncMetaUpdate is the builder for updating SyncMeta entities.

func (*SyncMetaUpdate) AddRecordCount

func (_u *SyncMetaUpdate) AddRecordCount(v int) *SyncMetaUpdate

AddRecordCount adds value to the "record_count" field.

func (*SyncMetaUpdate) Exec

func (_u *SyncMetaUpdate) Exec(ctx context.Context) error

Exec executes the query.

func (*SyncMetaUpdate) ExecX

func (_u *SyncMetaUpdate) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*SyncMetaUpdate) Mutation

func (_u *SyncMetaUpdate) Mutation() *SyncMetaMutation

Mutation returns the SyncMetaMutation object of the builder.

func (*SyncMetaUpdate) Save

func (_u *SyncMetaUpdate) Save(ctx context.Context) (int, error)

Save executes the query and returns the number of nodes affected by the update operation.

func (*SyncMetaUpdate) SaveX

func (_u *SyncMetaUpdate) SaveX(ctx context.Context) int

SaveX is like Save, but panics if an error occurs.

func (*SyncMetaUpdate) SetKind

func (_u *SyncMetaUpdate) SetKind(v string) *SyncMetaUpdate

SetKind sets the "kind" field.

func (*SyncMetaUpdate) SetLastSync

func (_u *SyncMetaUpdate) SetLastSync(v time.Time) *SyncMetaUpdate

SetLastSync sets the "last_sync" field.

func (*SyncMetaUpdate) SetNillableKind

func (_u *SyncMetaUpdate) SetNillableKind(v *string) *SyncMetaUpdate

SetNillableKind sets the "kind" field if the given value is not nil.

func (*SyncMetaUpdate) SetNillableLastSync

func (_u *SyncMetaUpdate) SetNillableLastSync(v *time.Time) *SyncMetaUpdate

SetNillableLastSync sets the "last_sync" field if the given value is not nil.

func (*SyncMetaUpdate) SetNillableProvider

func (_u *SyncMetaUpdate) SetNillableProvider(v *string) *SyncMetaUpdate

SetNillableProvider sets the "provider" field if the given value is not nil.

func (*SyncMetaUpdate) SetNillableRecordCount

func (_u *SyncMetaUpdate) SetNillableRecordCount(v *int) *SyncMetaUpdate

SetNillableRecordCount sets the "record_count" field if the given value is not nil.

func (*SyncMetaUpdate) SetProvider

func (_u *SyncMetaUpdate) SetProvider(v string) *SyncMetaUpdate

SetProvider sets the "provider" field.

func (*SyncMetaUpdate) SetRecordCount

func (_u *SyncMetaUpdate) SetRecordCount(v int) *SyncMetaUpdate

SetRecordCount sets the "record_count" field.

func (*SyncMetaUpdate) Where

func (_u *SyncMetaUpdate) Where(ps ...predicate.SyncMeta) *SyncMetaUpdate

Where appends a list predicates to the SyncMetaUpdate builder.

type SyncMetaUpdateOne

type SyncMetaUpdateOne struct {
	// contains filtered or unexported fields
}

SyncMetaUpdateOne is the builder for updating a single SyncMeta entity.

func (*SyncMetaUpdateOne) AddRecordCount

func (_u *SyncMetaUpdateOne) AddRecordCount(v int) *SyncMetaUpdateOne

AddRecordCount adds value to the "record_count" field.

func (*SyncMetaUpdateOne) Exec

func (_u *SyncMetaUpdateOne) Exec(ctx context.Context) error

Exec executes the query on the entity.

func (*SyncMetaUpdateOne) ExecX

func (_u *SyncMetaUpdateOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*SyncMetaUpdateOne) Mutation

func (_u *SyncMetaUpdateOne) Mutation() *SyncMetaMutation

Mutation returns the SyncMetaMutation object of the builder.

func (*SyncMetaUpdateOne) Save

func (_u *SyncMetaUpdateOne) Save(ctx context.Context) (*SyncMeta, error)

Save executes the query and returns the updated SyncMeta entity.

func (*SyncMetaUpdateOne) SaveX

func (_u *SyncMetaUpdateOne) SaveX(ctx context.Context) *SyncMeta

SaveX is like Save, but panics if an error occurs.

func (*SyncMetaUpdateOne) Select

func (_u *SyncMetaUpdateOne) Select(field string, fields ...string) *SyncMetaUpdateOne

Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.

func (*SyncMetaUpdateOne) SetKind

func (_u *SyncMetaUpdateOne) SetKind(v string) *SyncMetaUpdateOne

SetKind sets the "kind" field.

func (*SyncMetaUpdateOne) SetLastSync

func (_u *SyncMetaUpdateOne) SetLastSync(v time.Time) *SyncMetaUpdateOne

SetLastSync sets the "last_sync" field.

func (*SyncMetaUpdateOne) SetNillableKind

func (_u *SyncMetaUpdateOne) SetNillableKind(v *string) *SyncMetaUpdateOne

SetNillableKind sets the "kind" field if the given value is not nil.

func (*SyncMetaUpdateOne) SetNillableLastSync

func (_u *SyncMetaUpdateOne) SetNillableLastSync(v *time.Time) *SyncMetaUpdateOne

SetNillableLastSync sets the "last_sync" field if the given value is not nil.

func (*SyncMetaUpdateOne) SetNillableProvider

func (_u *SyncMetaUpdateOne) SetNillableProvider(v *string) *SyncMetaUpdateOne

SetNillableProvider sets the "provider" field if the given value is not nil.

func (*SyncMetaUpdateOne) SetNillableRecordCount

func (_u *SyncMetaUpdateOne) SetNillableRecordCount(v *int) *SyncMetaUpdateOne

SetNillableRecordCount sets the "record_count" field if the given value is not nil.

func (*SyncMetaUpdateOne) SetProvider

func (_u *SyncMetaUpdateOne) SetProvider(v string) *SyncMetaUpdateOne

SetProvider sets the "provider" field.

func (*SyncMetaUpdateOne) SetRecordCount

func (_u *SyncMetaUpdateOne) SetRecordCount(v int) *SyncMetaUpdateOne

SetRecordCount sets the "record_count" field.

func (*SyncMetaUpdateOne) Where

Where appends a list predicates to the SyncMetaUpdate builder.

type SyncMetaUpsert

type SyncMetaUpsert struct {
	*sql.UpdateSet
}

SyncMetaUpsert is the "OnConflict" setter.

func (*SyncMetaUpsert) AddRecordCount

func (u *SyncMetaUpsert) AddRecordCount(v int) *SyncMetaUpsert

AddRecordCount adds v to the "record_count" field.

func (*SyncMetaUpsert) SetKind

func (u *SyncMetaUpsert) SetKind(v string) *SyncMetaUpsert

SetKind sets the "kind" field.

func (*SyncMetaUpsert) SetLastSync

func (u *SyncMetaUpsert) SetLastSync(v time.Time) *SyncMetaUpsert

SetLastSync sets the "last_sync" field.

func (*SyncMetaUpsert) SetProvider

func (u *SyncMetaUpsert) SetProvider(v string) *SyncMetaUpsert

SetProvider sets the "provider" field.

func (*SyncMetaUpsert) SetRecordCount

func (u *SyncMetaUpsert) SetRecordCount(v int) *SyncMetaUpsert

SetRecordCount sets the "record_count" field.

func (*SyncMetaUpsert) UpdateKind

func (u *SyncMetaUpsert) UpdateKind() *SyncMetaUpsert

UpdateKind sets the "kind" field to the value that was provided on create.

func (*SyncMetaUpsert) UpdateLastSync

func (u *SyncMetaUpsert) UpdateLastSync() *SyncMetaUpsert

UpdateLastSync sets the "last_sync" field to the value that was provided on create.

func (*SyncMetaUpsert) UpdateProvider

func (u *SyncMetaUpsert) UpdateProvider() *SyncMetaUpsert

UpdateProvider sets the "provider" field to the value that was provided on create.

func (*SyncMetaUpsert) UpdateRecordCount

func (u *SyncMetaUpsert) UpdateRecordCount() *SyncMetaUpsert

UpdateRecordCount sets the "record_count" field to the value that was provided on create.

type SyncMetaUpsertBulk

type SyncMetaUpsertBulk struct {
	// contains filtered or unexported fields
}

SyncMetaUpsertBulk is the builder for "upsert"-ing a bulk of SyncMeta nodes.

func (*SyncMetaUpsertBulk) AddRecordCount

func (u *SyncMetaUpsertBulk) AddRecordCount(v int) *SyncMetaUpsertBulk

AddRecordCount adds v to the "record_count" field.

func (*SyncMetaUpsertBulk) DoNothing

func (u *SyncMetaUpsertBulk) DoNothing() *SyncMetaUpsertBulk

DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.

func (*SyncMetaUpsertBulk) Exec

func (u *SyncMetaUpsertBulk) Exec(ctx context.Context) error

Exec executes the query.

func (*SyncMetaUpsertBulk) ExecX

func (u *SyncMetaUpsertBulk) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*SyncMetaUpsertBulk) Ignore

Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:

client.SyncMeta.Create().
	OnConflict(sql.ResolveWithIgnore()).
	Exec(ctx)

func (*SyncMetaUpsertBulk) SetKind

SetKind sets the "kind" field.

func (*SyncMetaUpsertBulk) SetLastSync

func (u *SyncMetaUpsertBulk) SetLastSync(v time.Time) *SyncMetaUpsertBulk

SetLastSync sets the "last_sync" field.

func (*SyncMetaUpsertBulk) SetProvider

func (u *SyncMetaUpsertBulk) SetProvider(v string) *SyncMetaUpsertBulk

SetProvider sets the "provider" field.

func (*SyncMetaUpsertBulk) SetRecordCount

func (u *SyncMetaUpsertBulk) SetRecordCount(v int) *SyncMetaUpsertBulk

SetRecordCount sets the "record_count" field.

func (*SyncMetaUpsertBulk) Update

func (u *SyncMetaUpsertBulk) Update(set func(*SyncMetaUpsert)) *SyncMetaUpsertBulk

Update allows overriding fields `UPDATE` values. See the SyncMetaCreateBulk.OnConflict documentation for more info.

func (*SyncMetaUpsertBulk) UpdateKind

func (u *SyncMetaUpsertBulk) UpdateKind() *SyncMetaUpsertBulk

UpdateKind sets the "kind" field to the value that was provided on create.

func (*SyncMetaUpsertBulk) UpdateLastSync

func (u *SyncMetaUpsertBulk) UpdateLastSync() *SyncMetaUpsertBulk

UpdateLastSync sets the "last_sync" field to the value that was provided on create.

func (*SyncMetaUpsertBulk) UpdateNewValues

func (u *SyncMetaUpsertBulk) UpdateNewValues() *SyncMetaUpsertBulk

UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:

client.SyncMeta.Create().
	OnConflict(
		sql.ResolveWithNewValues(),
	).
	Exec(ctx)

func (*SyncMetaUpsertBulk) UpdateProvider

func (u *SyncMetaUpsertBulk) UpdateProvider() *SyncMetaUpsertBulk

UpdateProvider sets the "provider" field to the value that was provided on create.

func (*SyncMetaUpsertBulk) UpdateRecordCount

func (u *SyncMetaUpsertBulk) UpdateRecordCount() *SyncMetaUpsertBulk

UpdateRecordCount sets the "record_count" field to the value that was provided on create.

type SyncMetaUpsertOne

type SyncMetaUpsertOne struct {
	// contains filtered or unexported fields
}

SyncMetaUpsertOne is the builder for "upsert"-ing

one SyncMeta node.

func (*SyncMetaUpsertOne) AddRecordCount

func (u *SyncMetaUpsertOne) AddRecordCount(v int) *SyncMetaUpsertOne

AddRecordCount adds v to the "record_count" field.

func (*SyncMetaUpsertOne) DoNothing

func (u *SyncMetaUpsertOne) DoNothing() *SyncMetaUpsertOne

DoNothing configures the conflict_action to `DO NOTHING`. Supported only by SQLite and PostgreSQL.

func (*SyncMetaUpsertOne) Exec

func (u *SyncMetaUpsertOne) Exec(ctx context.Context) error

Exec executes the query.

func (*SyncMetaUpsertOne) ExecX

func (u *SyncMetaUpsertOne) ExecX(ctx context.Context)

ExecX is like Exec, but panics if an error occurs.

func (*SyncMetaUpsertOne) ID

func (u *SyncMetaUpsertOne) ID(ctx context.Context) (id int, err error)

Exec executes the UPSERT query and returns the inserted/updated ID.

func (*SyncMetaUpsertOne) IDX

func (u *SyncMetaUpsertOne) IDX(ctx context.Context) int

IDX is like ID, but panics if an error occurs.

func (*SyncMetaUpsertOne) Ignore

func (u *SyncMetaUpsertOne) Ignore() *SyncMetaUpsertOne

Ignore sets each column to itself in case of conflict. Using this option is equivalent to using:

client.SyncMeta.Create().
    OnConflict(sql.ResolveWithIgnore()).
    Exec(ctx)

func (*SyncMetaUpsertOne) SetKind

SetKind sets the "kind" field.

func (*SyncMetaUpsertOne) SetLastSync

func (u *SyncMetaUpsertOne) SetLastSync(v time.Time) *SyncMetaUpsertOne

SetLastSync sets the "last_sync" field.

func (*SyncMetaUpsertOne) SetProvider

func (u *SyncMetaUpsertOne) SetProvider(v string) *SyncMetaUpsertOne

SetProvider sets the "provider" field.

func (*SyncMetaUpsertOne) SetRecordCount

func (u *SyncMetaUpsertOne) SetRecordCount(v int) *SyncMetaUpsertOne

SetRecordCount sets the "record_count" field.

func (*SyncMetaUpsertOne) Update

func (u *SyncMetaUpsertOne) Update(set func(*SyncMetaUpsert)) *SyncMetaUpsertOne

Update allows overriding fields `UPDATE` values. See the SyncMetaCreate.OnConflict documentation for more info.

func (*SyncMetaUpsertOne) UpdateKind

func (u *SyncMetaUpsertOne) UpdateKind() *SyncMetaUpsertOne

UpdateKind sets the "kind" field to the value that was provided on create.

func (*SyncMetaUpsertOne) UpdateLastSync

func (u *SyncMetaUpsertOne) UpdateLastSync() *SyncMetaUpsertOne

UpdateLastSync sets the "last_sync" field to the value that was provided on create.

func (*SyncMetaUpsertOne) UpdateNewValues

func (u *SyncMetaUpsertOne) UpdateNewValues() *SyncMetaUpsertOne

UpdateNewValues updates the mutable fields using the new values that were set on create. Using this option is equivalent to using:

client.SyncMeta.Create().
	OnConflict(
		sql.ResolveWithNewValues(),
	).
	Exec(ctx)

func (*SyncMetaUpsertOne) UpdateProvider

func (u *SyncMetaUpsertOne) UpdateProvider() *SyncMetaUpsertOne

UpdateProvider sets the "provider" field to the value that was provided on create.

func (*SyncMetaUpsertOne) UpdateRecordCount

func (u *SyncMetaUpsertOne) UpdateRecordCount() *SyncMetaUpsertOne

UpdateRecordCount sets the "record_count" field to the value that was provided on create.

type TraverseFunc

type TraverseFunc = ent.TraverseFunc

ent aliases to avoid import conflicts in user's code.

type Traverser

type Traverser = ent.Traverser

ent aliases to avoid import conflicts in user's code.

type Tx

type Tx struct {

	// CustomFieldDef is the client for interacting with the CustomFieldDef builders.
	CustomFieldDef *CustomFieldDefClient
	// DimensionOption is the client for interacting with the DimensionOption builders.
	DimensionOption *DimensionOptionClient
	// Evidence is the client for interacting with the Evidence builders.
	Evidence *EvidenceClient
	// Item is the client for interacting with the Item builders.
	Item *ItemClient
	// ItemAugment is the client for interacting with the ItemAugment builders.
	ItemAugment *ItemAugmentClient
	// OpportunityAssessment is the client for interacting with the OpportunityAssessment builders.
	OpportunityAssessment *OpportunityAssessmentClient
	// OpportunitySpec is the client for interacting with the OpportunitySpec builders.
	OpportunitySpec *OpportunitySpecClient
	// PortfolioDimension is the client for interacting with the PortfolioDimension builders.
	PortfolioDimension *PortfolioDimensionClient
	// ProfileAssignment is the client for interacting with the ProfileAssignment builders.
	ProfileAssignment *ProfileAssignmentClient
	// RankOverride is the client for interacting with the RankOverride builders.
	RankOverride *RankOverrideClient
	// Release is the client for interacting with the Release builders.
	Release *ReleaseClient
	// ReportDataset is the client for interacting with the ReportDataset builders.
	ReportDataset *ReportDatasetClient
	// SyncMeta is the client for interacting with the SyncMeta builders.
	SyncMeta *SyncMetaClient
	// contains filtered or unexported fields
}

Tx is a transactional client that is created by calling Client.Tx().

func TxFromContext

func TxFromContext(ctx context.Context) *Tx

TxFromContext returns a Tx stored inside a context, or nil if there isn't one.

func (*Tx) Client

func (tx *Tx) Client() *Client

Client returns a Client that binds to current transaction.

func (*Tx) Commit

func (tx *Tx) Commit() error

Commit commits the transaction.

func (*Tx) OnCommit

func (tx *Tx) OnCommit(f CommitHook)

OnCommit adds a hook to call on commit.

func (*Tx) OnRollback

func (tx *Tx) OnRollback(f RollbackHook)

OnRollback adds a hook to call on rollback.

func (*Tx) Rollback

func (tx *Tx) Rollback() error

Rollback rollbacks the transaction.

type ValidationError

type ValidationError struct {
	Name string // Field or edge name.
	// contains filtered or unexported fields
}

ValidationError returns when validating a field or edge fails.

func (*ValidationError) Error

func (e *ValidationError) Error() string

Error implements the error interface.

func (*ValidationError) Unwrap

func (e *ValidationError) Unwrap() error

Unwrap implements the errors.Wrapper interface.

type Value

type Value = ent.Value

ent aliases to avoid import conflicts in user's code.

Jump to

Keyboard shortcuts

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