Documentation
¶
Index ¶
- Constants
- Variables
- func Asc(fields ...string) func(*sql.Selector)
- func Desc(fields ...string) func(*sql.Selector)
- func IsConstraintError(err error) bool
- func IsNotFound(err error) bool
- func IsNotLoaded(err error) bool
- func IsNotSingular(err error) bool
- func IsValidationError(err error) bool
- func MaskNotFound(err error) error
- func NewContext(parent context.Context, c *Client) context.Context
- func NewTxContext(parent context.Context, tx *Tx) context.Context
- type ActionLogEntries
- type ActionLogEntry
- type ActionLogEntryClient
- func (c *ActionLogEntryClient) Create() *ActionLogEntryCreate
- func (c *ActionLogEntryClient) CreateBulk(builders ...*ActionLogEntryCreate) *ActionLogEntryCreateBulk
- func (c *ActionLogEntryClient) Delete() *ActionLogEntryDelete
- func (c *ActionLogEntryClient) DeleteOne(_m *ActionLogEntry) *ActionLogEntryDeleteOne
- func (c *ActionLogEntryClient) DeleteOneID(id int) *ActionLogEntryDeleteOne
- func (c *ActionLogEntryClient) Get(ctx context.Context, id int) (*ActionLogEntry, error)
- func (c *ActionLogEntryClient) GetX(ctx context.Context, id int) *ActionLogEntry
- func (c *ActionLogEntryClient) Hooks() []Hook
- func (c *ActionLogEntryClient) Intercept(interceptors ...Interceptor)
- func (c *ActionLogEntryClient) Interceptors() []Interceptor
- func (c *ActionLogEntryClient) MapCreateBulk(slice any, setFunc func(*ActionLogEntryCreate, int)) *ActionLogEntryCreateBulk
- func (c *ActionLogEntryClient) Query() *ActionLogEntryQuery
- func (c *ActionLogEntryClient) Update() *ActionLogEntryUpdate
- func (c *ActionLogEntryClient) UpdateOne(_m *ActionLogEntry) *ActionLogEntryUpdateOne
- func (c *ActionLogEntryClient) UpdateOneID(id int) *ActionLogEntryUpdateOne
- func (c *ActionLogEntryClient) Use(hooks ...Hook)
- type ActionLogEntryCreate
- func (_c *ActionLogEntryCreate) Exec(ctx context.Context) error
- func (_c *ActionLogEntryCreate) ExecX(ctx context.Context)
- func (_c *ActionLogEntryCreate) Mutation() *ActionLogEntryMutation
- func (_c *ActionLogEntryCreate) Save(ctx context.Context) (*ActionLogEntry, error)
- func (_c *ActionLogEntryCreate) SaveX(ctx context.Context) *ActionLogEntry
- func (_c *ActionLogEntryCreate) SetActionGroup(v string) *ActionLogEntryCreate
- func (_c *ActionLogEntryCreate) SetActorID(v int) *ActionLogEntryCreate
- func (_c *ActionLogEntryCreate) SetActorName(v string) *ActionLogEntryCreate
- func (_c *ActionLogEntryCreate) SetChanges(v string) *ActionLogEntryCreate
- func (_c *ActionLogEntryCreate) SetCreatedAt(v time.Time) *ActionLogEntryCreate
- func (_c *ActionLogEntryCreate) SetID(v int) *ActionLogEntryCreate
- func (_c *ActionLogEntryCreate) SetIP(v string) *ActionLogEntryCreate
- func (_c *ActionLogEntryCreate) SetNillableActorID(v *int) *ActionLogEntryCreate
- func (_c *ActionLogEntryCreate) SetNillableActorName(v *string) *ActionLogEntryCreate
- func (_c *ActionLogEntryCreate) SetNillableChanges(v *string) *ActionLogEntryCreate
- func (_c *ActionLogEntryCreate) SetNillableIP(v *string) *ActionLogEntryCreate
- func (_c *ActionLogEntryCreate) SetNillableObjectID(v *string) *ActionLogEntryCreate
- func (_c *ActionLogEntryCreate) SetNillableObjectKind(v *string) *ActionLogEntryCreate
- func (_c *ActionLogEntryCreate) SetNillableObjectLabel(v *string) *ActionLogEntryCreate
- func (_c *ActionLogEntryCreate) SetNillableObjectType(v *string) *ActionLogEntryCreate
- func (_c *ActionLogEntryCreate) SetNillableObjectURL(v *string) *ActionLogEntryCreate
- func (_c *ActionLogEntryCreate) SetObjectID(v string) *ActionLogEntryCreate
- func (_c *ActionLogEntryCreate) SetObjectKind(v string) *ActionLogEntryCreate
- func (_c *ActionLogEntryCreate) SetObjectLabel(v string) *ActionLogEntryCreate
- func (_c *ActionLogEntryCreate) SetObjectType(v string) *ActionLogEntryCreate
- func (_c *ActionLogEntryCreate) SetObjectURL(v string) *ActionLogEntryCreate
- func (_c *ActionLogEntryCreate) SetType(v string) *ActionLogEntryCreate
- type ActionLogEntryCreateBulk
- func (_c *ActionLogEntryCreateBulk) Exec(ctx context.Context) error
- func (_c *ActionLogEntryCreateBulk) ExecX(ctx context.Context)
- func (_c *ActionLogEntryCreateBulk) Save(ctx context.Context) ([]*ActionLogEntry, error)
- func (_c *ActionLogEntryCreateBulk) SaveX(ctx context.Context) []*ActionLogEntry
- type ActionLogEntryDelete
- type ActionLogEntryDeleteOne
- type ActionLogEntryGroupBy
- func (_g *ActionLogEntryGroupBy) Aggregate(fns ...AggregateFunc) *ActionLogEntryGroupBy
- func (s *ActionLogEntryGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (s *ActionLogEntryGroupBy) BoolX(ctx context.Context) bool
- func (s *ActionLogEntryGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (s *ActionLogEntryGroupBy) BoolsX(ctx context.Context) []bool
- func (s *ActionLogEntryGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (s *ActionLogEntryGroupBy) Float64X(ctx context.Context) float64
- func (s *ActionLogEntryGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (s *ActionLogEntryGroupBy) Float64sX(ctx context.Context) []float64
- func (s *ActionLogEntryGroupBy) Int(ctx context.Context) (_ int, err error)
- func (s *ActionLogEntryGroupBy) IntX(ctx context.Context) int
- func (s *ActionLogEntryGroupBy) Ints(ctx context.Context) ([]int, error)
- func (s *ActionLogEntryGroupBy) IntsX(ctx context.Context) []int
- func (_g *ActionLogEntryGroupBy) Scan(ctx context.Context, v any) error
- func (s *ActionLogEntryGroupBy) ScanX(ctx context.Context, v any)
- func (s *ActionLogEntryGroupBy) String(ctx context.Context) (_ string, err error)
- func (s *ActionLogEntryGroupBy) StringX(ctx context.Context) string
- func (s *ActionLogEntryGroupBy) Strings(ctx context.Context) ([]string, error)
- func (s *ActionLogEntryGroupBy) StringsX(ctx context.Context) []string
- type ActionLogEntryMutation
- func (m *ActionLogEntryMutation) ActionGroup() (r string, exists bool)
- func (m *ActionLogEntryMutation) ActorID() (r int, exists bool)
- func (m *ActionLogEntryMutation) ActorIDCleared() bool
- func (m *ActionLogEntryMutation) ActorName() (r string, exists bool)
- func (m *ActionLogEntryMutation) AddActorID(i int)
- func (m *ActionLogEntryMutation) AddField(name string, value ent.Value) error
- func (m *ActionLogEntryMutation) AddedActorID() (r int, exists bool)
- func (m *ActionLogEntryMutation) AddedEdges() []string
- func (m *ActionLogEntryMutation) AddedField(name string) (ent.Value, bool)
- func (m *ActionLogEntryMutation) AddedFields() []string
- func (m *ActionLogEntryMutation) AddedIDs(name string) []ent.Value
- func (m *ActionLogEntryMutation) Changes() (r string, exists bool)
- func (m *ActionLogEntryMutation) ClearActorID()
- func (m *ActionLogEntryMutation) ClearEdge(name string) error
- func (m *ActionLogEntryMutation) ClearField(name string) error
- func (m *ActionLogEntryMutation) ClearedEdges() []string
- func (m *ActionLogEntryMutation) ClearedFields() []string
- func (m ActionLogEntryMutation) Client() *Client
- func (m *ActionLogEntryMutation) CreatedAt() (r time.Time, exists bool)
- func (m *ActionLogEntryMutation) EdgeCleared(name string) bool
- func (m *ActionLogEntryMutation) Field(name string) (ent.Value, bool)
- func (m *ActionLogEntryMutation) FieldCleared(name string) bool
- func (m *ActionLogEntryMutation) Fields() []string
- func (m *ActionLogEntryMutation) GetType() (r string, exists bool)
- func (m *ActionLogEntryMutation) ID() (id int, exists bool)
- func (m *ActionLogEntryMutation) IDs(ctx context.Context) ([]int, error)
- func (m *ActionLogEntryMutation) IP() (r string, exists bool)
- func (m *ActionLogEntryMutation) ObjectID() (r string, exists bool)
- func (m *ActionLogEntryMutation) ObjectKind() (r string, exists bool)
- func (m *ActionLogEntryMutation) ObjectLabel() (r string, exists bool)
- func (m *ActionLogEntryMutation) ObjectType() (r string, exists bool)
- func (m *ActionLogEntryMutation) ObjectURL() (r string, exists bool)
- func (m *ActionLogEntryMutation) OldActionGroup(ctx context.Context) (v string, err error)
- func (m *ActionLogEntryMutation) OldActorID(ctx context.Context) (v *int, err error)
- func (m *ActionLogEntryMutation) OldActorName(ctx context.Context) (v string, err error)
- func (m *ActionLogEntryMutation) OldChanges(ctx context.Context) (v string, err error)
- func (m *ActionLogEntryMutation) OldCreatedAt(ctx context.Context) (v time.Time, err error)
- func (m *ActionLogEntryMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *ActionLogEntryMutation) OldIP(ctx context.Context) (v string, err error)
- func (m *ActionLogEntryMutation) OldObjectID(ctx context.Context) (v string, err error)
- func (m *ActionLogEntryMutation) OldObjectKind(ctx context.Context) (v string, err error)
- func (m *ActionLogEntryMutation) OldObjectLabel(ctx context.Context) (v string, err error)
- func (m *ActionLogEntryMutation) OldObjectType(ctx context.Context) (v string, err error)
- func (m *ActionLogEntryMutation) OldObjectURL(ctx context.Context) (v string, err error)
- func (m *ActionLogEntryMutation) OldType(ctx context.Context) (v string, err error)
- func (m *ActionLogEntryMutation) Op() Op
- func (m *ActionLogEntryMutation) RemovedEdges() []string
- func (m *ActionLogEntryMutation) RemovedIDs(name string) []ent.Value
- func (m *ActionLogEntryMutation) ResetActionGroup()
- func (m *ActionLogEntryMutation) ResetActorID()
- func (m *ActionLogEntryMutation) ResetActorName()
- func (m *ActionLogEntryMutation) ResetChanges()
- func (m *ActionLogEntryMutation) ResetCreatedAt()
- func (m *ActionLogEntryMutation) ResetEdge(name string) error
- func (m *ActionLogEntryMutation) ResetField(name string) error
- func (m *ActionLogEntryMutation) ResetIP()
- func (m *ActionLogEntryMutation) ResetObjectID()
- func (m *ActionLogEntryMutation) ResetObjectKind()
- func (m *ActionLogEntryMutation) ResetObjectLabel()
- func (m *ActionLogEntryMutation) ResetObjectType()
- func (m *ActionLogEntryMutation) ResetObjectURL()
- func (m *ActionLogEntryMutation) ResetType()
- func (m *ActionLogEntryMutation) SetActionGroup(s string)
- func (m *ActionLogEntryMutation) SetActorID(i int)
- func (m *ActionLogEntryMutation) SetActorName(s string)
- func (m *ActionLogEntryMutation) SetChanges(s string)
- func (m *ActionLogEntryMutation) SetCreatedAt(t time.Time)
- func (m *ActionLogEntryMutation) SetField(name string, value ent.Value) error
- func (m *ActionLogEntryMutation) SetID(id int)
- func (m *ActionLogEntryMutation) SetIP(s string)
- func (m *ActionLogEntryMutation) SetObjectID(s string)
- func (m *ActionLogEntryMutation) SetObjectKind(s string)
- func (m *ActionLogEntryMutation) SetObjectLabel(s string)
- func (m *ActionLogEntryMutation) SetObjectType(s string)
- func (m *ActionLogEntryMutation) SetObjectURL(s string)
- func (m *ActionLogEntryMutation) SetOp(op Op)
- func (m *ActionLogEntryMutation) SetType(s string)
- func (m ActionLogEntryMutation) Tx() (*Tx, error)
- func (m *ActionLogEntryMutation) Type() string
- func (m *ActionLogEntryMutation) Where(ps ...predicate.ActionLogEntry)
- func (m *ActionLogEntryMutation) WhereP(ps ...func(*sql.Selector))
- type ActionLogEntryQuery
- func (_q *ActionLogEntryQuery) Aggregate(fns ...AggregateFunc) *ActionLogEntrySelect
- func (_q *ActionLogEntryQuery) All(ctx context.Context) ([]*ActionLogEntry, error)
- func (_q *ActionLogEntryQuery) AllX(ctx context.Context) []*ActionLogEntry
- func (_q *ActionLogEntryQuery) Clone() *ActionLogEntryQuery
- func (_q *ActionLogEntryQuery) Count(ctx context.Context) (int, error)
- func (_q *ActionLogEntryQuery) CountX(ctx context.Context) int
- func (_q *ActionLogEntryQuery) Exist(ctx context.Context) (bool, error)
- func (_q *ActionLogEntryQuery) ExistX(ctx context.Context) bool
- func (_q *ActionLogEntryQuery) First(ctx context.Context) (*ActionLogEntry, error)
- func (_q *ActionLogEntryQuery) FirstID(ctx context.Context) (id int, err error)
- func (_q *ActionLogEntryQuery) FirstIDX(ctx context.Context) int
- func (_q *ActionLogEntryQuery) FirstX(ctx context.Context) *ActionLogEntry
- func (_q *ActionLogEntryQuery) GroupBy(field string, fields ...string) *ActionLogEntryGroupBy
- func (_q *ActionLogEntryQuery) IDs(ctx context.Context) (ids []int, err error)
- func (_q *ActionLogEntryQuery) IDsX(ctx context.Context) []int
- func (_q *ActionLogEntryQuery) Limit(limit int) *ActionLogEntryQuery
- func (_q *ActionLogEntryQuery) Offset(offset int) *ActionLogEntryQuery
- func (_q *ActionLogEntryQuery) Only(ctx context.Context) (*ActionLogEntry, error)
- func (_q *ActionLogEntryQuery) OnlyID(ctx context.Context) (id int, err error)
- func (_q *ActionLogEntryQuery) OnlyIDX(ctx context.Context) int
- func (_q *ActionLogEntryQuery) OnlyX(ctx context.Context) *ActionLogEntry
- func (_q *ActionLogEntryQuery) Order(o ...actionlogentry.OrderOption) *ActionLogEntryQuery
- func (_q *ActionLogEntryQuery) Select(fields ...string) *ActionLogEntrySelect
- func (_q *ActionLogEntryQuery) Unique(unique bool) *ActionLogEntryQuery
- func (_q *ActionLogEntryQuery) Where(ps ...predicate.ActionLogEntry) *ActionLogEntryQuery
- type ActionLogEntrySelect
- func (_s *ActionLogEntrySelect) Aggregate(fns ...AggregateFunc) *ActionLogEntrySelect
- func (s *ActionLogEntrySelect) Bool(ctx context.Context) (_ bool, err error)
- func (s *ActionLogEntrySelect) BoolX(ctx context.Context) bool
- func (s *ActionLogEntrySelect) Bools(ctx context.Context) ([]bool, error)
- func (s *ActionLogEntrySelect) BoolsX(ctx context.Context) []bool
- func (s *ActionLogEntrySelect) Float64(ctx context.Context) (_ float64, err error)
- func (s *ActionLogEntrySelect) Float64X(ctx context.Context) float64
- func (s *ActionLogEntrySelect) Float64s(ctx context.Context) ([]float64, error)
- func (s *ActionLogEntrySelect) Float64sX(ctx context.Context) []float64
- func (s *ActionLogEntrySelect) Int(ctx context.Context) (_ int, err error)
- func (s *ActionLogEntrySelect) IntX(ctx context.Context) int
- func (s *ActionLogEntrySelect) Ints(ctx context.Context) ([]int, error)
- func (s *ActionLogEntrySelect) IntsX(ctx context.Context) []int
- func (_s *ActionLogEntrySelect) Scan(ctx context.Context, v any) error
- func (s *ActionLogEntrySelect) ScanX(ctx context.Context, v any)
- func (s *ActionLogEntrySelect) String(ctx context.Context) (_ string, err error)
- func (s *ActionLogEntrySelect) StringX(ctx context.Context) string
- func (s *ActionLogEntrySelect) Strings(ctx context.Context) ([]string, error)
- func (s *ActionLogEntrySelect) StringsX(ctx context.Context) []string
- type ActionLogEntryUpdate
- func (_u *ActionLogEntryUpdate) AddActorID(v int) *ActionLogEntryUpdate
- func (_u *ActionLogEntryUpdate) ClearActorID() *ActionLogEntryUpdate
- func (_u *ActionLogEntryUpdate) Exec(ctx context.Context) error
- func (_u *ActionLogEntryUpdate) ExecX(ctx context.Context)
- func (_u *ActionLogEntryUpdate) Mutation() *ActionLogEntryMutation
- func (_u *ActionLogEntryUpdate) Save(ctx context.Context) (int, error)
- func (_u *ActionLogEntryUpdate) SaveX(ctx context.Context) int
- func (_u *ActionLogEntryUpdate) SetActionGroup(v string) *ActionLogEntryUpdate
- func (_u *ActionLogEntryUpdate) SetActorID(v int) *ActionLogEntryUpdate
- func (_u *ActionLogEntryUpdate) SetActorName(v string) *ActionLogEntryUpdate
- func (_u *ActionLogEntryUpdate) SetChanges(v string) *ActionLogEntryUpdate
- func (_u *ActionLogEntryUpdate) SetCreatedAt(v time.Time) *ActionLogEntryUpdate
- func (_u *ActionLogEntryUpdate) SetIP(v string) *ActionLogEntryUpdate
- func (_u *ActionLogEntryUpdate) SetNillableActionGroup(v *string) *ActionLogEntryUpdate
- func (_u *ActionLogEntryUpdate) SetNillableActorID(v *int) *ActionLogEntryUpdate
- func (_u *ActionLogEntryUpdate) SetNillableActorName(v *string) *ActionLogEntryUpdate
- func (_u *ActionLogEntryUpdate) SetNillableChanges(v *string) *ActionLogEntryUpdate
- func (_u *ActionLogEntryUpdate) SetNillableCreatedAt(v *time.Time) *ActionLogEntryUpdate
- func (_u *ActionLogEntryUpdate) SetNillableIP(v *string) *ActionLogEntryUpdate
- func (_u *ActionLogEntryUpdate) SetNillableObjectID(v *string) *ActionLogEntryUpdate
- func (_u *ActionLogEntryUpdate) SetNillableObjectKind(v *string) *ActionLogEntryUpdate
- func (_u *ActionLogEntryUpdate) SetNillableObjectLabel(v *string) *ActionLogEntryUpdate
- func (_u *ActionLogEntryUpdate) SetNillableObjectType(v *string) *ActionLogEntryUpdate
- func (_u *ActionLogEntryUpdate) SetNillableObjectURL(v *string) *ActionLogEntryUpdate
- func (_u *ActionLogEntryUpdate) SetNillableType(v *string) *ActionLogEntryUpdate
- func (_u *ActionLogEntryUpdate) SetObjectID(v string) *ActionLogEntryUpdate
- func (_u *ActionLogEntryUpdate) SetObjectKind(v string) *ActionLogEntryUpdate
- func (_u *ActionLogEntryUpdate) SetObjectLabel(v string) *ActionLogEntryUpdate
- func (_u *ActionLogEntryUpdate) SetObjectType(v string) *ActionLogEntryUpdate
- func (_u *ActionLogEntryUpdate) SetObjectURL(v string) *ActionLogEntryUpdate
- func (_u *ActionLogEntryUpdate) SetType(v string) *ActionLogEntryUpdate
- func (_u *ActionLogEntryUpdate) Where(ps ...predicate.ActionLogEntry) *ActionLogEntryUpdate
- type ActionLogEntryUpdateOne
- func (_u *ActionLogEntryUpdateOne) AddActorID(v int) *ActionLogEntryUpdateOne
- func (_u *ActionLogEntryUpdateOne) ClearActorID() *ActionLogEntryUpdateOne
- func (_u *ActionLogEntryUpdateOne) Exec(ctx context.Context) error
- func (_u *ActionLogEntryUpdateOne) ExecX(ctx context.Context)
- func (_u *ActionLogEntryUpdateOne) Mutation() *ActionLogEntryMutation
- func (_u *ActionLogEntryUpdateOne) Save(ctx context.Context) (*ActionLogEntry, error)
- func (_u *ActionLogEntryUpdateOne) SaveX(ctx context.Context) *ActionLogEntry
- func (_u *ActionLogEntryUpdateOne) Select(field string, fields ...string) *ActionLogEntryUpdateOne
- func (_u *ActionLogEntryUpdateOne) SetActionGroup(v string) *ActionLogEntryUpdateOne
- func (_u *ActionLogEntryUpdateOne) SetActorID(v int) *ActionLogEntryUpdateOne
- func (_u *ActionLogEntryUpdateOne) SetActorName(v string) *ActionLogEntryUpdateOne
- func (_u *ActionLogEntryUpdateOne) SetChanges(v string) *ActionLogEntryUpdateOne
- func (_u *ActionLogEntryUpdateOne) SetCreatedAt(v time.Time) *ActionLogEntryUpdateOne
- func (_u *ActionLogEntryUpdateOne) SetIP(v string) *ActionLogEntryUpdateOne
- func (_u *ActionLogEntryUpdateOne) SetNillableActionGroup(v *string) *ActionLogEntryUpdateOne
- func (_u *ActionLogEntryUpdateOne) SetNillableActorID(v *int) *ActionLogEntryUpdateOne
- func (_u *ActionLogEntryUpdateOne) SetNillableActorName(v *string) *ActionLogEntryUpdateOne
- func (_u *ActionLogEntryUpdateOne) SetNillableChanges(v *string) *ActionLogEntryUpdateOne
- func (_u *ActionLogEntryUpdateOne) SetNillableCreatedAt(v *time.Time) *ActionLogEntryUpdateOne
- func (_u *ActionLogEntryUpdateOne) SetNillableIP(v *string) *ActionLogEntryUpdateOne
- func (_u *ActionLogEntryUpdateOne) SetNillableObjectID(v *string) *ActionLogEntryUpdateOne
- func (_u *ActionLogEntryUpdateOne) SetNillableObjectKind(v *string) *ActionLogEntryUpdateOne
- func (_u *ActionLogEntryUpdateOne) SetNillableObjectLabel(v *string) *ActionLogEntryUpdateOne
- func (_u *ActionLogEntryUpdateOne) SetNillableObjectType(v *string) *ActionLogEntryUpdateOne
- func (_u *ActionLogEntryUpdateOne) SetNillableObjectURL(v *string) *ActionLogEntryUpdateOne
- func (_u *ActionLogEntryUpdateOne) SetNillableType(v *string) *ActionLogEntryUpdateOne
- func (_u *ActionLogEntryUpdateOne) SetObjectID(v string) *ActionLogEntryUpdateOne
- func (_u *ActionLogEntryUpdateOne) SetObjectKind(v string) *ActionLogEntryUpdateOne
- func (_u *ActionLogEntryUpdateOne) SetObjectLabel(v string) *ActionLogEntryUpdateOne
- func (_u *ActionLogEntryUpdateOne) SetObjectType(v string) *ActionLogEntryUpdateOne
- func (_u *ActionLogEntryUpdateOne) SetObjectURL(v string) *ActionLogEntryUpdateOne
- func (_u *ActionLogEntryUpdateOne) SetType(v string) *ActionLogEntryUpdateOne
- func (_u *ActionLogEntryUpdateOne) Where(ps ...predicate.ActionLogEntry) *ActionLogEntryUpdateOne
- type ActionLogSettings
- type ActionLogSettingsClient
- func (c *ActionLogSettingsClient) Create() *ActionLogSettingsCreate
- func (c *ActionLogSettingsClient) CreateBulk(builders ...*ActionLogSettingsCreate) *ActionLogSettingsCreateBulk
- func (c *ActionLogSettingsClient) Delete() *ActionLogSettingsDelete
- func (c *ActionLogSettingsClient) DeleteOne(_m *ActionLogSettings) *ActionLogSettingsDeleteOne
- func (c *ActionLogSettingsClient) DeleteOneID(id int) *ActionLogSettingsDeleteOne
- func (c *ActionLogSettingsClient) Get(ctx context.Context, id int) (*ActionLogSettings, error)
- func (c *ActionLogSettingsClient) GetX(ctx context.Context, id int) *ActionLogSettings
- func (c *ActionLogSettingsClient) Hooks() []Hook
- func (c *ActionLogSettingsClient) Intercept(interceptors ...Interceptor)
- func (c *ActionLogSettingsClient) Interceptors() []Interceptor
- func (c *ActionLogSettingsClient) MapCreateBulk(slice any, setFunc func(*ActionLogSettingsCreate, int)) *ActionLogSettingsCreateBulk
- func (c *ActionLogSettingsClient) Query() *ActionLogSettingsQuery
- func (c *ActionLogSettingsClient) Update() *ActionLogSettingsUpdate
- func (c *ActionLogSettingsClient) UpdateOne(_m *ActionLogSettings) *ActionLogSettingsUpdateOne
- func (c *ActionLogSettingsClient) UpdateOneID(id int) *ActionLogSettingsUpdateOne
- func (c *ActionLogSettingsClient) Use(hooks ...Hook)
- type ActionLogSettingsCreate
- func (_c *ActionLogSettingsCreate) Exec(ctx context.Context) error
- func (_c *ActionLogSettingsCreate) ExecX(ctx context.Context)
- func (_c *ActionLogSettingsCreate) Mutation() *ActionLogSettingsMutation
- func (_c *ActionLogSettingsCreate) Save(ctx context.Context) (*ActionLogSettings, error)
- func (_c *ActionLogSettingsCreate) SaveX(ctx context.Context) *ActionLogSettings
- func (_c *ActionLogSettingsCreate) SetGroupsOff(v string) *ActionLogSettingsCreate
- func (_c *ActionLogSettingsCreate) SetID(v int) *ActionLogSettingsCreate
- func (_c *ActionLogSettingsCreate) SetKeepDays(v int) *ActionLogSettingsCreate
- func (_c *ActionLogSettingsCreate) SetLogIP(v bool) *ActionLogSettingsCreate
- func (_c *ActionLogSettingsCreate) SetNillableGroupsOff(v *string) *ActionLogSettingsCreate
- func (_c *ActionLogSettingsCreate) SetNillableKeepDays(v *int) *ActionLogSettingsCreate
- func (_c *ActionLogSettingsCreate) SetNillableLogIP(v *bool) *ActionLogSettingsCreate
- type ActionLogSettingsCreateBulk
- func (_c *ActionLogSettingsCreateBulk) Exec(ctx context.Context) error
- func (_c *ActionLogSettingsCreateBulk) ExecX(ctx context.Context)
- func (_c *ActionLogSettingsCreateBulk) Save(ctx context.Context) ([]*ActionLogSettings, error)
- func (_c *ActionLogSettingsCreateBulk) SaveX(ctx context.Context) []*ActionLogSettings
- type ActionLogSettingsDelete
- type ActionLogSettingsDeleteOne
- type ActionLogSettingsGroupBy
- func (_g *ActionLogSettingsGroupBy) Aggregate(fns ...AggregateFunc) *ActionLogSettingsGroupBy
- func (s *ActionLogSettingsGroupBy) Bool(ctx context.Context) (_ bool, err error)
- func (s *ActionLogSettingsGroupBy) BoolX(ctx context.Context) bool
- func (s *ActionLogSettingsGroupBy) Bools(ctx context.Context) ([]bool, error)
- func (s *ActionLogSettingsGroupBy) BoolsX(ctx context.Context) []bool
- func (s *ActionLogSettingsGroupBy) Float64(ctx context.Context) (_ float64, err error)
- func (s *ActionLogSettingsGroupBy) Float64X(ctx context.Context) float64
- func (s *ActionLogSettingsGroupBy) Float64s(ctx context.Context) ([]float64, error)
- func (s *ActionLogSettingsGroupBy) Float64sX(ctx context.Context) []float64
- func (s *ActionLogSettingsGroupBy) Int(ctx context.Context) (_ int, err error)
- func (s *ActionLogSettingsGroupBy) IntX(ctx context.Context) int
- func (s *ActionLogSettingsGroupBy) Ints(ctx context.Context) ([]int, error)
- func (s *ActionLogSettingsGroupBy) IntsX(ctx context.Context) []int
- func (_g *ActionLogSettingsGroupBy) Scan(ctx context.Context, v any) error
- func (s *ActionLogSettingsGroupBy) ScanX(ctx context.Context, v any)
- func (s *ActionLogSettingsGroupBy) String(ctx context.Context) (_ string, err error)
- func (s *ActionLogSettingsGroupBy) StringX(ctx context.Context) string
- func (s *ActionLogSettingsGroupBy) Strings(ctx context.Context) ([]string, error)
- func (s *ActionLogSettingsGroupBy) StringsX(ctx context.Context) []string
- type ActionLogSettingsMutation
- func (m *ActionLogSettingsMutation) AddField(name string, value ent.Value) error
- func (m *ActionLogSettingsMutation) AddKeepDays(i int)
- func (m *ActionLogSettingsMutation) AddedEdges() []string
- func (m *ActionLogSettingsMutation) AddedField(name string) (ent.Value, bool)
- func (m *ActionLogSettingsMutation) AddedFields() []string
- func (m *ActionLogSettingsMutation) AddedIDs(name string) []ent.Value
- func (m *ActionLogSettingsMutation) AddedKeepDays() (r int, exists bool)
- func (m *ActionLogSettingsMutation) ClearEdge(name string) error
- func (m *ActionLogSettingsMutation) ClearField(name string) error
- func (m *ActionLogSettingsMutation) ClearedEdges() []string
- func (m *ActionLogSettingsMutation) ClearedFields() []string
- func (m ActionLogSettingsMutation) Client() *Client
- func (m *ActionLogSettingsMutation) EdgeCleared(name string) bool
- func (m *ActionLogSettingsMutation) Field(name string) (ent.Value, bool)
- func (m *ActionLogSettingsMutation) FieldCleared(name string) bool
- func (m *ActionLogSettingsMutation) Fields() []string
- func (m *ActionLogSettingsMutation) GroupsOff() (r string, exists bool)
- func (m *ActionLogSettingsMutation) ID() (id int, exists bool)
- func (m *ActionLogSettingsMutation) IDs(ctx context.Context) ([]int, error)
- func (m *ActionLogSettingsMutation) KeepDays() (r int, exists bool)
- func (m *ActionLogSettingsMutation) LogIP() (r bool, exists bool)
- func (m *ActionLogSettingsMutation) OldField(ctx context.Context, name string) (ent.Value, error)
- func (m *ActionLogSettingsMutation) OldGroupsOff(ctx context.Context) (v string, err error)
- func (m *ActionLogSettingsMutation) OldKeepDays(ctx context.Context) (v int, err error)
- func (m *ActionLogSettingsMutation) OldLogIP(ctx context.Context) (v bool, err error)
- func (m *ActionLogSettingsMutation) Op() Op
- func (m *ActionLogSettingsMutation) RemovedEdges() []string
- func (m *ActionLogSettingsMutation) RemovedIDs(name string) []ent.Value
- func (m *ActionLogSettingsMutation) ResetEdge(name string) error
- func (m *ActionLogSettingsMutation) ResetField(name string) error
- func (m *ActionLogSettingsMutation) ResetGroupsOff()
- func (m *ActionLogSettingsMutation) ResetKeepDays()
- func (m *ActionLogSettingsMutation) ResetLogIP()
- func (m *ActionLogSettingsMutation) SetField(name string, value ent.Value) error
- func (m *ActionLogSettingsMutation) SetGroupsOff(s string)
- func (m *ActionLogSettingsMutation) SetID(id int)
- func (m *ActionLogSettingsMutation) SetKeepDays(i int)
- func (m *ActionLogSettingsMutation) SetLogIP(b bool)
- func (m *ActionLogSettingsMutation) SetOp(op Op)
- func (m ActionLogSettingsMutation) Tx() (*Tx, error)
- func (m *ActionLogSettingsMutation) Type() string
- func (m *ActionLogSettingsMutation) Where(ps ...predicate.ActionLogSettings)
- func (m *ActionLogSettingsMutation) WhereP(ps ...func(*sql.Selector))
- type ActionLogSettingsQuery
- func (_q *ActionLogSettingsQuery) Aggregate(fns ...AggregateFunc) *ActionLogSettingsSelect
- func (_q *ActionLogSettingsQuery) All(ctx context.Context) ([]*ActionLogSettings, error)
- func (_q *ActionLogSettingsQuery) AllX(ctx context.Context) []*ActionLogSettings
- func (_q *ActionLogSettingsQuery) Clone() *ActionLogSettingsQuery
- func (_q *ActionLogSettingsQuery) Count(ctx context.Context) (int, error)
- func (_q *ActionLogSettingsQuery) CountX(ctx context.Context) int
- func (_q *ActionLogSettingsQuery) Exist(ctx context.Context) (bool, error)
- func (_q *ActionLogSettingsQuery) ExistX(ctx context.Context) bool
- func (_q *ActionLogSettingsQuery) First(ctx context.Context) (*ActionLogSettings, error)
- func (_q *ActionLogSettingsQuery) FirstID(ctx context.Context) (id int, err error)
- func (_q *ActionLogSettingsQuery) FirstIDX(ctx context.Context) int
- func (_q *ActionLogSettingsQuery) FirstX(ctx context.Context) *ActionLogSettings
- func (_q *ActionLogSettingsQuery) GroupBy(field string, fields ...string) *ActionLogSettingsGroupBy
- func (_q *ActionLogSettingsQuery) IDs(ctx context.Context) (ids []int, err error)
- func (_q *ActionLogSettingsQuery) IDsX(ctx context.Context) []int
- func (_q *ActionLogSettingsQuery) Limit(limit int) *ActionLogSettingsQuery
- func (_q *ActionLogSettingsQuery) Offset(offset int) *ActionLogSettingsQuery
- func (_q *ActionLogSettingsQuery) Only(ctx context.Context) (*ActionLogSettings, error)
- func (_q *ActionLogSettingsQuery) OnlyID(ctx context.Context) (id int, err error)
- func (_q *ActionLogSettingsQuery) OnlyIDX(ctx context.Context) int
- func (_q *ActionLogSettingsQuery) OnlyX(ctx context.Context) *ActionLogSettings
- func (_q *ActionLogSettingsQuery) Order(o ...actionlogsettings.OrderOption) *ActionLogSettingsQuery
- func (_q *ActionLogSettingsQuery) Select(fields ...string) *ActionLogSettingsSelect
- func (_q *ActionLogSettingsQuery) Unique(unique bool) *ActionLogSettingsQuery
- func (_q *ActionLogSettingsQuery) Where(ps ...predicate.ActionLogSettings) *ActionLogSettingsQuery
- type ActionLogSettingsSelect
- func (_s *ActionLogSettingsSelect) Aggregate(fns ...AggregateFunc) *ActionLogSettingsSelect
- func (s *ActionLogSettingsSelect) Bool(ctx context.Context) (_ bool, err error)
- func (s *ActionLogSettingsSelect) BoolX(ctx context.Context) bool
- func (s *ActionLogSettingsSelect) Bools(ctx context.Context) ([]bool, error)
- func (s *ActionLogSettingsSelect) BoolsX(ctx context.Context) []bool
- func (s *ActionLogSettingsSelect) Float64(ctx context.Context) (_ float64, err error)
- func (s *ActionLogSettingsSelect) Float64X(ctx context.Context) float64
- func (s *ActionLogSettingsSelect) Float64s(ctx context.Context) ([]float64, error)
- func (s *ActionLogSettingsSelect) Float64sX(ctx context.Context) []float64
- func (s *ActionLogSettingsSelect) Int(ctx context.Context) (_ int, err error)
- func (s *ActionLogSettingsSelect) IntX(ctx context.Context) int
- func (s *ActionLogSettingsSelect) Ints(ctx context.Context) ([]int, error)
- func (s *ActionLogSettingsSelect) IntsX(ctx context.Context) []int
- func (_s *ActionLogSettingsSelect) Scan(ctx context.Context, v any) error
- func (s *ActionLogSettingsSelect) ScanX(ctx context.Context, v any)
- func (s *ActionLogSettingsSelect) String(ctx context.Context) (_ string, err error)
- func (s *ActionLogSettingsSelect) StringX(ctx context.Context) string
- func (s *ActionLogSettingsSelect) Strings(ctx context.Context) ([]string, error)
- func (s *ActionLogSettingsSelect) StringsX(ctx context.Context) []string
- type ActionLogSettingsSlice
- type ActionLogSettingsUpdate
- func (_u *ActionLogSettingsUpdate) AddKeepDays(v int) *ActionLogSettingsUpdate
- func (_u *ActionLogSettingsUpdate) Exec(ctx context.Context) error
- func (_u *ActionLogSettingsUpdate) ExecX(ctx context.Context)
- func (_u *ActionLogSettingsUpdate) Mutation() *ActionLogSettingsMutation
- func (_u *ActionLogSettingsUpdate) Save(ctx context.Context) (int, error)
- func (_u *ActionLogSettingsUpdate) SaveX(ctx context.Context) int
- func (_u *ActionLogSettingsUpdate) SetGroupsOff(v string) *ActionLogSettingsUpdate
- func (_u *ActionLogSettingsUpdate) SetKeepDays(v int) *ActionLogSettingsUpdate
- func (_u *ActionLogSettingsUpdate) SetLogIP(v bool) *ActionLogSettingsUpdate
- func (_u *ActionLogSettingsUpdate) SetNillableGroupsOff(v *string) *ActionLogSettingsUpdate
- func (_u *ActionLogSettingsUpdate) SetNillableKeepDays(v *int) *ActionLogSettingsUpdate
- func (_u *ActionLogSettingsUpdate) SetNillableLogIP(v *bool) *ActionLogSettingsUpdate
- func (_u *ActionLogSettingsUpdate) Where(ps ...predicate.ActionLogSettings) *ActionLogSettingsUpdate
- type ActionLogSettingsUpdateOne
- func (_u *ActionLogSettingsUpdateOne) AddKeepDays(v int) *ActionLogSettingsUpdateOne
- func (_u *ActionLogSettingsUpdateOne) Exec(ctx context.Context) error
- func (_u *ActionLogSettingsUpdateOne) ExecX(ctx context.Context)
- func (_u *ActionLogSettingsUpdateOne) Mutation() *ActionLogSettingsMutation
- func (_u *ActionLogSettingsUpdateOne) Save(ctx context.Context) (*ActionLogSettings, error)
- func (_u *ActionLogSettingsUpdateOne) SaveX(ctx context.Context) *ActionLogSettings
- func (_u *ActionLogSettingsUpdateOne) Select(field string, fields ...string) *ActionLogSettingsUpdateOne
- func (_u *ActionLogSettingsUpdateOne) SetGroupsOff(v string) *ActionLogSettingsUpdateOne
- func (_u *ActionLogSettingsUpdateOne) SetKeepDays(v int) *ActionLogSettingsUpdateOne
- func (_u *ActionLogSettingsUpdateOne) SetLogIP(v bool) *ActionLogSettingsUpdateOne
- func (_u *ActionLogSettingsUpdateOne) SetNillableGroupsOff(v *string) *ActionLogSettingsUpdateOne
- func (_u *ActionLogSettingsUpdateOne) SetNillableKeepDays(v *int) *ActionLogSettingsUpdateOne
- func (_u *ActionLogSettingsUpdateOne) SetNillableLogIP(v *bool) *ActionLogSettingsUpdateOne
- func (_u *ActionLogSettingsUpdateOne) Where(ps ...predicate.ActionLogSettings) *ActionLogSettingsUpdateOne
- type AggregateFunc
- type Client
- func (c *Client) BeginTx(ctx context.Context, opts *sql.TxOptions) (*Tx, error)
- func (c *Client) Close() error
- func (c *Client) Debug() *Client
- func (c *Client) Intercept(interceptors ...Interceptor)
- func (c *Client) Mutate(ctx context.Context, m Mutation) (Value, error)
- func (c *Client) Tx(ctx context.Context) (*Tx, error)
- func (c *Client) Use(hooks ...Hook)
- type CommitFunc
- type CommitHook
- type Committer
- type ConstraintError
- type Hook
- type InterceptFunc
- type Interceptor
- type MutateFunc
- type Mutation
- type Mutator
- type NotFoundError
- type NotLoadedError
- type NotSingularError
- type Op
- type Option
- type OrderFunc
- type Policy
- type Querier
- type QuerierFunc
- type Query
- type QueryContext
- type RollbackFunc
- type RollbackHook
- type Rollbacker
- type TraverseFunc
- type Traverser
- type Tx
- type ValidationError
- type Value
Constants ¶
const ( // Operation types. OpCreate = ent.OpCreate OpDelete = ent.OpDelete OpDeleteOne = ent.OpDeleteOne OpUpdate = ent.OpUpdate OpUpdateOne = ent.OpUpdateOne // Node types. TypeActionLogEntry = "ActionLogEntry" TypeActionLogSettings = "ActionLogSettings" )
Variables ¶
var ErrTxStarted = errors.New("generated: cannot start a transaction within a transaction")
ErrTxStarted is returned when trying to start a new transaction from a transactional client.
Functions ¶
func IsConstraintError ¶
IsConstraintError returns a boolean indicating whether the error is a constraint failure.
func IsNotFound ¶
IsNotFound returns a boolean indicating whether the error is a not found error.
func IsNotLoaded ¶
IsNotLoaded returns a boolean indicating whether the error is a not loaded error.
func IsNotSingular ¶
IsNotSingular returns a boolean indicating whether the error is a not singular error.
func IsValidationError ¶
IsValidationError returns a boolean indicating whether the error is a validation error.
func NewContext ¶
NewContext returns a new context with the given Client attached.
Types ¶
type ActionLogEntries ¶
type ActionLogEntries []*ActionLogEntry
ActionLogEntries is a parsable slice of ActionLogEntry.
type ActionLogEntry ¶
type ActionLogEntry struct {
// ID of the ent.
ID int `json:"id,omitempty"`
// CreatedAt holds the value of the "created_at" field.
CreatedAt time.Time `json:"created_at,omitempty"`
// Type holds the value of the "type" field.
Type string `json:"type,omitempty"`
// ActionGroup holds the value of the "action_group" field.
ActionGroup string `json:"action_group,omitempty"`
// ActorID holds the value of the "actor_id" field.
ActorID *int `json:"actor_id,omitempty"`
// ActorName holds the value of the "actor_name" field.
ActorName string `json:"actor_name,omitempty"`
// IP holds the value of the "ip" field.
IP string `json:"ip,omitempty"`
// ObjectKind holds the value of the "object_kind" field.
ObjectKind string `json:"object_kind,omitempty"`
// ObjectID holds the value of the "object_id" field.
ObjectID string `json:"object_id,omitempty"`
// ObjectLabel holds the value of the "object_label" field.
ObjectLabel string `json:"object_label,omitempty"`
// ObjectType holds the value of the "object_type" field.
ObjectType string `json:"object_type,omitempty"`
// ObjectURL holds the value of the "object_url" field.
ObjectURL string `json:"object_url,omitempty"`
// Changes holds the value of the "changes" field.
Changes string `json:"changes,omitempty"`
// contains filtered or unexported fields
}
ActionLogEntry is the model entity for the ActionLogEntry schema.
func (*ActionLogEntry) String ¶
func (_m *ActionLogEntry) String() string
String implements the fmt.Stringer.
func (*ActionLogEntry) Unwrap ¶
func (_m *ActionLogEntry) Unwrap() *ActionLogEntry
Unwrap unwraps the ActionLogEntry 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 (*ActionLogEntry) Update ¶
func (_m *ActionLogEntry) Update() *ActionLogEntryUpdateOne
Update returns a builder for updating this ActionLogEntry. Note that you need to call ActionLogEntry.Unwrap() before calling this method if this ActionLogEntry was returned from a transaction, and the transaction was committed or rolled back.
type ActionLogEntryClient ¶
type ActionLogEntryClient struct {
// contains filtered or unexported fields
}
ActionLogEntryClient is a client for the ActionLogEntry schema.
func NewActionLogEntryClient ¶
func NewActionLogEntryClient(c config) *ActionLogEntryClient
NewActionLogEntryClient returns a client for the ActionLogEntry from the given config.
func (*ActionLogEntryClient) Create ¶
func (c *ActionLogEntryClient) Create() *ActionLogEntryCreate
Create returns a builder for creating a ActionLogEntry entity.
func (*ActionLogEntryClient) CreateBulk ¶
func (c *ActionLogEntryClient) CreateBulk(builders ...*ActionLogEntryCreate) *ActionLogEntryCreateBulk
CreateBulk returns a builder for creating a bulk of ActionLogEntry entities.
func (*ActionLogEntryClient) Delete ¶
func (c *ActionLogEntryClient) Delete() *ActionLogEntryDelete
Delete returns a delete builder for ActionLogEntry.
func (*ActionLogEntryClient) DeleteOne ¶
func (c *ActionLogEntryClient) DeleteOne(_m *ActionLogEntry) *ActionLogEntryDeleteOne
DeleteOne returns a builder for deleting the given entity.
func (*ActionLogEntryClient) DeleteOneID ¶
func (c *ActionLogEntryClient) DeleteOneID(id int) *ActionLogEntryDeleteOne
DeleteOneID returns a builder for deleting the given entity by its id.
func (*ActionLogEntryClient) Get ¶
func (c *ActionLogEntryClient) Get(ctx context.Context, id int) (*ActionLogEntry, error)
Get returns a ActionLogEntry entity by its id.
func (*ActionLogEntryClient) GetX ¶
func (c *ActionLogEntryClient) GetX(ctx context.Context, id int) *ActionLogEntry
GetX is like Get, but panics if an error occurs.
func (*ActionLogEntryClient) Hooks ¶
func (c *ActionLogEntryClient) Hooks() []Hook
Hooks returns the client hooks.
func (*ActionLogEntryClient) Intercept ¶
func (c *ActionLogEntryClient) Intercept(interceptors ...Interceptor)
Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `actionlogentry.Intercept(f(g(h())))`.
func (*ActionLogEntryClient) Interceptors ¶
func (c *ActionLogEntryClient) Interceptors() []Interceptor
Interceptors returns the client interceptors.
func (*ActionLogEntryClient) MapCreateBulk ¶
func (c *ActionLogEntryClient) MapCreateBulk(slice any, setFunc func(*ActionLogEntryCreate, int)) *ActionLogEntryCreateBulk
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 (*ActionLogEntryClient) Query ¶
func (c *ActionLogEntryClient) Query() *ActionLogEntryQuery
Query returns a query builder for ActionLogEntry.
func (*ActionLogEntryClient) Update ¶
func (c *ActionLogEntryClient) Update() *ActionLogEntryUpdate
Update returns an update builder for ActionLogEntry.
func (*ActionLogEntryClient) UpdateOne ¶
func (c *ActionLogEntryClient) UpdateOne(_m *ActionLogEntry) *ActionLogEntryUpdateOne
UpdateOne returns an update builder for the given entity.
func (*ActionLogEntryClient) UpdateOneID ¶
func (c *ActionLogEntryClient) UpdateOneID(id int) *ActionLogEntryUpdateOne
UpdateOneID returns an update builder for the given id.
func (*ActionLogEntryClient) Use ¶
func (c *ActionLogEntryClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `actionlogentry.Hooks(f(g(h())))`.
type ActionLogEntryCreate ¶
type ActionLogEntryCreate struct {
// contains filtered or unexported fields
}
ActionLogEntryCreate is the builder for creating a ActionLogEntry entity.
func (*ActionLogEntryCreate) Exec ¶
func (_c *ActionLogEntryCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*ActionLogEntryCreate) ExecX ¶
func (_c *ActionLogEntryCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ActionLogEntryCreate) Mutation ¶
func (_c *ActionLogEntryCreate) Mutation() *ActionLogEntryMutation
Mutation returns the ActionLogEntryMutation object of the builder.
func (*ActionLogEntryCreate) Save ¶
func (_c *ActionLogEntryCreate) Save(ctx context.Context) (*ActionLogEntry, error)
Save creates the ActionLogEntry in the database.
func (*ActionLogEntryCreate) SaveX ¶
func (_c *ActionLogEntryCreate) SaveX(ctx context.Context) *ActionLogEntry
SaveX calls Save and panics if Save returns an error.
func (*ActionLogEntryCreate) SetActionGroup ¶
func (_c *ActionLogEntryCreate) SetActionGroup(v string) *ActionLogEntryCreate
SetActionGroup sets the "action_group" field.
func (*ActionLogEntryCreate) SetActorID ¶
func (_c *ActionLogEntryCreate) SetActorID(v int) *ActionLogEntryCreate
SetActorID sets the "actor_id" field.
func (*ActionLogEntryCreate) SetActorName ¶
func (_c *ActionLogEntryCreate) SetActorName(v string) *ActionLogEntryCreate
SetActorName sets the "actor_name" field.
func (*ActionLogEntryCreate) SetChanges ¶
func (_c *ActionLogEntryCreate) SetChanges(v string) *ActionLogEntryCreate
SetChanges sets the "changes" field.
func (*ActionLogEntryCreate) SetCreatedAt ¶
func (_c *ActionLogEntryCreate) SetCreatedAt(v time.Time) *ActionLogEntryCreate
SetCreatedAt sets the "created_at" field.
func (*ActionLogEntryCreate) SetID ¶
func (_c *ActionLogEntryCreate) SetID(v int) *ActionLogEntryCreate
SetID sets the "id" field.
func (*ActionLogEntryCreate) SetIP ¶
func (_c *ActionLogEntryCreate) SetIP(v string) *ActionLogEntryCreate
SetIP sets the "ip" field.
func (*ActionLogEntryCreate) SetNillableActorID ¶
func (_c *ActionLogEntryCreate) SetNillableActorID(v *int) *ActionLogEntryCreate
SetNillableActorID sets the "actor_id" field if the given value is not nil.
func (*ActionLogEntryCreate) SetNillableActorName ¶
func (_c *ActionLogEntryCreate) SetNillableActorName(v *string) *ActionLogEntryCreate
SetNillableActorName sets the "actor_name" field if the given value is not nil.
func (*ActionLogEntryCreate) SetNillableChanges ¶
func (_c *ActionLogEntryCreate) SetNillableChanges(v *string) *ActionLogEntryCreate
SetNillableChanges sets the "changes" field if the given value is not nil.
func (*ActionLogEntryCreate) SetNillableIP ¶
func (_c *ActionLogEntryCreate) SetNillableIP(v *string) *ActionLogEntryCreate
SetNillableIP sets the "ip" field if the given value is not nil.
func (*ActionLogEntryCreate) SetNillableObjectID ¶
func (_c *ActionLogEntryCreate) SetNillableObjectID(v *string) *ActionLogEntryCreate
SetNillableObjectID sets the "object_id" field if the given value is not nil.
func (*ActionLogEntryCreate) SetNillableObjectKind ¶
func (_c *ActionLogEntryCreate) SetNillableObjectKind(v *string) *ActionLogEntryCreate
SetNillableObjectKind sets the "object_kind" field if the given value is not nil.
func (*ActionLogEntryCreate) SetNillableObjectLabel ¶
func (_c *ActionLogEntryCreate) SetNillableObjectLabel(v *string) *ActionLogEntryCreate
SetNillableObjectLabel sets the "object_label" field if the given value is not nil.
func (*ActionLogEntryCreate) SetNillableObjectType ¶
func (_c *ActionLogEntryCreate) SetNillableObjectType(v *string) *ActionLogEntryCreate
SetNillableObjectType sets the "object_type" field if the given value is not nil.
func (*ActionLogEntryCreate) SetNillableObjectURL ¶
func (_c *ActionLogEntryCreate) SetNillableObjectURL(v *string) *ActionLogEntryCreate
SetNillableObjectURL sets the "object_url" field if the given value is not nil.
func (*ActionLogEntryCreate) SetObjectID ¶
func (_c *ActionLogEntryCreate) SetObjectID(v string) *ActionLogEntryCreate
SetObjectID sets the "object_id" field.
func (*ActionLogEntryCreate) SetObjectKind ¶
func (_c *ActionLogEntryCreate) SetObjectKind(v string) *ActionLogEntryCreate
SetObjectKind sets the "object_kind" field.
func (*ActionLogEntryCreate) SetObjectLabel ¶
func (_c *ActionLogEntryCreate) SetObjectLabel(v string) *ActionLogEntryCreate
SetObjectLabel sets the "object_label" field.
func (*ActionLogEntryCreate) SetObjectType ¶
func (_c *ActionLogEntryCreate) SetObjectType(v string) *ActionLogEntryCreate
SetObjectType sets the "object_type" field.
func (*ActionLogEntryCreate) SetObjectURL ¶
func (_c *ActionLogEntryCreate) SetObjectURL(v string) *ActionLogEntryCreate
SetObjectURL sets the "object_url" field.
func (*ActionLogEntryCreate) SetType ¶
func (_c *ActionLogEntryCreate) SetType(v string) *ActionLogEntryCreate
SetType sets the "type" field.
type ActionLogEntryCreateBulk ¶
type ActionLogEntryCreateBulk struct {
// contains filtered or unexported fields
}
ActionLogEntryCreateBulk is the builder for creating many ActionLogEntry entities in bulk.
func (*ActionLogEntryCreateBulk) Exec ¶
func (_c *ActionLogEntryCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*ActionLogEntryCreateBulk) ExecX ¶
func (_c *ActionLogEntryCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ActionLogEntryCreateBulk) Save ¶
func (_c *ActionLogEntryCreateBulk) Save(ctx context.Context) ([]*ActionLogEntry, error)
Save creates the ActionLogEntry entities in the database.
func (*ActionLogEntryCreateBulk) SaveX ¶
func (_c *ActionLogEntryCreateBulk) SaveX(ctx context.Context) []*ActionLogEntry
SaveX is like Save, but panics if an error occurs.
type ActionLogEntryDelete ¶
type ActionLogEntryDelete struct {
// contains filtered or unexported fields
}
ActionLogEntryDelete is the builder for deleting a ActionLogEntry entity.
func (*ActionLogEntryDelete) Exec ¶
func (_d *ActionLogEntryDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*ActionLogEntryDelete) ExecX ¶
func (_d *ActionLogEntryDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*ActionLogEntryDelete) Where ¶
func (_d *ActionLogEntryDelete) Where(ps ...predicate.ActionLogEntry) *ActionLogEntryDelete
Where appends a list predicates to the ActionLogEntryDelete builder.
type ActionLogEntryDeleteOne ¶
type ActionLogEntryDeleteOne struct {
// contains filtered or unexported fields
}
ActionLogEntryDeleteOne is the builder for deleting a single ActionLogEntry entity.
func (*ActionLogEntryDeleteOne) Exec ¶
func (_d *ActionLogEntryDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*ActionLogEntryDeleteOne) ExecX ¶
func (_d *ActionLogEntryDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ActionLogEntryDeleteOne) Where ¶
func (_d *ActionLogEntryDeleteOne) Where(ps ...predicate.ActionLogEntry) *ActionLogEntryDeleteOne
Where appends a list predicates to the ActionLogEntryDelete builder.
type ActionLogEntryGroupBy ¶
type ActionLogEntryGroupBy struct {
// contains filtered or unexported fields
}
ActionLogEntryGroupBy is the group-by builder for ActionLogEntry entities.
func (*ActionLogEntryGroupBy) Aggregate ¶
func (_g *ActionLogEntryGroupBy) Aggregate(fns ...AggregateFunc) *ActionLogEntryGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*ActionLogEntryGroupBy) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*ActionLogEntryGroupBy) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*ActionLogEntryGroupBy) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*ActionLogEntryGroupBy) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*ActionLogEntryGroupBy) Float64sX ¶
Float64sX is like Float64s, but panics if an error occurs.
func (*ActionLogEntryGroupBy) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*ActionLogEntryGroupBy) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*ActionLogEntryGroupBy) Scan ¶
func (_g *ActionLogEntryGroupBy) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*ActionLogEntryGroupBy) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type ActionLogEntryMutation ¶
type ActionLogEntryMutation struct {
// contains filtered or unexported fields
}
ActionLogEntryMutation represents an operation that mutates the ActionLogEntry nodes in the graph.
func (*ActionLogEntryMutation) ActionGroup ¶
func (m *ActionLogEntryMutation) ActionGroup() (r string, exists bool)
ActionGroup returns the value of the "action_group" field in the mutation.
func (*ActionLogEntryMutation) ActorID ¶
func (m *ActionLogEntryMutation) ActorID() (r int, exists bool)
ActorID returns the value of the "actor_id" field in the mutation.
func (*ActionLogEntryMutation) ActorIDCleared ¶
func (m *ActionLogEntryMutation) ActorIDCleared() bool
ActorIDCleared returns if the "actor_id" field was cleared in this mutation.
func (*ActionLogEntryMutation) ActorName ¶
func (m *ActionLogEntryMutation) ActorName() (r string, exists bool)
ActorName returns the value of the "actor_name" field in the mutation.
func (*ActionLogEntryMutation) AddActorID ¶
func (m *ActionLogEntryMutation) AddActorID(i int)
AddActorID adds i to the "actor_id" field.
func (*ActionLogEntryMutation) AddField ¶
func (m *ActionLogEntryMutation) 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 (*ActionLogEntryMutation) AddedActorID ¶
func (m *ActionLogEntryMutation) AddedActorID() (r int, exists bool)
AddedActorID returns the value that was added to the "actor_id" field in this mutation.
func (*ActionLogEntryMutation) AddedEdges ¶
func (m *ActionLogEntryMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*ActionLogEntryMutation) AddedField ¶
func (m *ActionLogEntryMutation) 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 (*ActionLogEntryMutation) AddedFields ¶
func (m *ActionLogEntryMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*ActionLogEntryMutation) AddedIDs ¶
func (m *ActionLogEntryMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*ActionLogEntryMutation) Changes ¶
func (m *ActionLogEntryMutation) Changes() (r string, exists bool)
Changes returns the value of the "changes" field in the mutation.
func (*ActionLogEntryMutation) ClearActorID ¶
func (m *ActionLogEntryMutation) ClearActorID()
ClearActorID clears the value of the "actor_id" field.
func (*ActionLogEntryMutation) ClearEdge ¶
func (m *ActionLogEntryMutation) 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 (*ActionLogEntryMutation) ClearField ¶
func (m *ActionLogEntryMutation) 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 (*ActionLogEntryMutation) ClearedEdges ¶
func (m *ActionLogEntryMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*ActionLogEntryMutation) ClearedFields ¶
func (m *ActionLogEntryMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (ActionLogEntryMutation) Client ¶
func (m ActionLogEntryMutation) 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 (*ActionLogEntryMutation) CreatedAt ¶
func (m *ActionLogEntryMutation) CreatedAt() (r time.Time, exists bool)
CreatedAt returns the value of the "created_at" field in the mutation.
func (*ActionLogEntryMutation) EdgeCleared ¶
func (m *ActionLogEntryMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*ActionLogEntryMutation) Field ¶
func (m *ActionLogEntryMutation) 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 (*ActionLogEntryMutation) FieldCleared ¶
func (m *ActionLogEntryMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*ActionLogEntryMutation) Fields ¶
func (m *ActionLogEntryMutation) 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 (*ActionLogEntryMutation) GetType ¶
func (m *ActionLogEntryMutation) GetType() (r string, exists bool)
GetType returns the value of the "type" field in the mutation.
func (*ActionLogEntryMutation) ID ¶
func (m *ActionLogEntryMutation) 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 (*ActionLogEntryMutation) IDs ¶
func (m *ActionLogEntryMutation) 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 (*ActionLogEntryMutation) IP ¶
func (m *ActionLogEntryMutation) IP() (r string, exists bool)
IP returns the value of the "ip" field in the mutation.
func (*ActionLogEntryMutation) ObjectID ¶
func (m *ActionLogEntryMutation) ObjectID() (r string, exists bool)
ObjectID returns the value of the "object_id" field in the mutation.
func (*ActionLogEntryMutation) ObjectKind ¶
func (m *ActionLogEntryMutation) ObjectKind() (r string, exists bool)
ObjectKind returns the value of the "object_kind" field in the mutation.
func (*ActionLogEntryMutation) ObjectLabel ¶
func (m *ActionLogEntryMutation) ObjectLabel() (r string, exists bool)
ObjectLabel returns the value of the "object_label" field in the mutation.
func (*ActionLogEntryMutation) ObjectType ¶
func (m *ActionLogEntryMutation) ObjectType() (r string, exists bool)
ObjectType returns the value of the "object_type" field in the mutation.
func (*ActionLogEntryMutation) ObjectURL ¶
func (m *ActionLogEntryMutation) ObjectURL() (r string, exists bool)
ObjectURL returns the value of the "object_url" field in the mutation.
func (*ActionLogEntryMutation) OldActionGroup ¶
func (m *ActionLogEntryMutation) OldActionGroup(ctx context.Context) (v string, err error)
OldActionGroup returns the old "action_group" field's value of the ActionLogEntry entity. If the ActionLogEntry 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 (*ActionLogEntryMutation) OldActorID ¶
func (m *ActionLogEntryMutation) OldActorID(ctx context.Context) (v *int, err error)
OldActorID returns the old "actor_id" field's value of the ActionLogEntry entity. If the ActionLogEntry 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 (*ActionLogEntryMutation) OldActorName ¶
func (m *ActionLogEntryMutation) OldActorName(ctx context.Context) (v string, err error)
OldActorName returns the old "actor_name" field's value of the ActionLogEntry entity. If the ActionLogEntry 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 (*ActionLogEntryMutation) OldChanges ¶
func (m *ActionLogEntryMutation) OldChanges(ctx context.Context) (v string, err error)
OldChanges returns the old "changes" field's value of the ActionLogEntry entity. If the ActionLogEntry 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 (*ActionLogEntryMutation) OldCreatedAt ¶
OldCreatedAt returns the old "created_at" field's value of the ActionLogEntry entity. If the ActionLogEntry 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 (*ActionLogEntryMutation) 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 (*ActionLogEntryMutation) OldIP ¶
func (m *ActionLogEntryMutation) OldIP(ctx context.Context) (v string, err error)
OldIP returns the old "ip" field's value of the ActionLogEntry entity. If the ActionLogEntry 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 (*ActionLogEntryMutation) OldObjectID ¶
func (m *ActionLogEntryMutation) OldObjectID(ctx context.Context) (v string, err error)
OldObjectID returns the old "object_id" field's value of the ActionLogEntry entity. If the ActionLogEntry 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 (*ActionLogEntryMutation) OldObjectKind ¶
func (m *ActionLogEntryMutation) OldObjectKind(ctx context.Context) (v string, err error)
OldObjectKind returns the old "object_kind" field's value of the ActionLogEntry entity. If the ActionLogEntry 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 (*ActionLogEntryMutation) OldObjectLabel ¶
func (m *ActionLogEntryMutation) OldObjectLabel(ctx context.Context) (v string, err error)
OldObjectLabel returns the old "object_label" field's value of the ActionLogEntry entity. If the ActionLogEntry 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 (*ActionLogEntryMutation) OldObjectType ¶
func (m *ActionLogEntryMutation) OldObjectType(ctx context.Context) (v string, err error)
OldObjectType returns the old "object_type" field's value of the ActionLogEntry entity. If the ActionLogEntry 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 (*ActionLogEntryMutation) OldObjectURL ¶
func (m *ActionLogEntryMutation) OldObjectURL(ctx context.Context) (v string, err error)
OldObjectURL returns the old "object_url" field's value of the ActionLogEntry entity. If the ActionLogEntry 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 (*ActionLogEntryMutation) OldType ¶
func (m *ActionLogEntryMutation) OldType(ctx context.Context) (v string, err error)
OldType returns the old "type" field's value of the ActionLogEntry entity. If the ActionLogEntry 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 (*ActionLogEntryMutation) Op ¶
func (m *ActionLogEntryMutation) Op() Op
Op returns the operation name.
func (*ActionLogEntryMutation) RemovedEdges ¶
func (m *ActionLogEntryMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*ActionLogEntryMutation) RemovedIDs ¶
func (m *ActionLogEntryMutation) 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 (*ActionLogEntryMutation) ResetActionGroup ¶
func (m *ActionLogEntryMutation) ResetActionGroup()
ResetActionGroup resets all changes to the "action_group" field.
func (*ActionLogEntryMutation) ResetActorID ¶
func (m *ActionLogEntryMutation) ResetActorID()
ResetActorID resets all changes to the "actor_id" field.
func (*ActionLogEntryMutation) ResetActorName ¶
func (m *ActionLogEntryMutation) ResetActorName()
ResetActorName resets all changes to the "actor_name" field.
func (*ActionLogEntryMutation) ResetChanges ¶
func (m *ActionLogEntryMutation) ResetChanges()
ResetChanges resets all changes to the "changes" field.
func (*ActionLogEntryMutation) ResetCreatedAt ¶
func (m *ActionLogEntryMutation) ResetCreatedAt()
ResetCreatedAt resets all changes to the "created_at" field.
func (*ActionLogEntryMutation) ResetEdge ¶
func (m *ActionLogEntryMutation) 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 (*ActionLogEntryMutation) ResetField ¶
func (m *ActionLogEntryMutation) 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 (*ActionLogEntryMutation) ResetIP ¶
func (m *ActionLogEntryMutation) ResetIP()
ResetIP resets all changes to the "ip" field.
func (*ActionLogEntryMutation) ResetObjectID ¶
func (m *ActionLogEntryMutation) ResetObjectID()
ResetObjectID resets all changes to the "object_id" field.
func (*ActionLogEntryMutation) ResetObjectKind ¶
func (m *ActionLogEntryMutation) ResetObjectKind()
ResetObjectKind resets all changes to the "object_kind" field.
func (*ActionLogEntryMutation) ResetObjectLabel ¶
func (m *ActionLogEntryMutation) ResetObjectLabel()
ResetObjectLabel resets all changes to the "object_label" field.
func (*ActionLogEntryMutation) ResetObjectType ¶
func (m *ActionLogEntryMutation) ResetObjectType()
ResetObjectType resets all changes to the "object_type" field.
func (*ActionLogEntryMutation) ResetObjectURL ¶
func (m *ActionLogEntryMutation) ResetObjectURL()
ResetObjectURL resets all changes to the "object_url" field.
func (*ActionLogEntryMutation) ResetType ¶
func (m *ActionLogEntryMutation) ResetType()
ResetType resets all changes to the "type" field.
func (*ActionLogEntryMutation) SetActionGroup ¶
func (m *ActionLogEntryMutation) SetActionGroup(s string)
SetActionGroup sets the "action_group" field.
func (*ActionLogEntryMutation) SetActorID ¶
func (m *ActionLogEntryMutation) SetActorID(i int)
SetActorID sets the "actor_id" field.
func (*ActionLogEntryMutation) SetActorName ¶
func (m *ActionLogEntryMutation) SetActorName(s string)
SetActorName sets the "actor_name" field.
func (*ActionLogEntryMutation) SetChanges ¶
func (m *ActionLogEntryMutation) SetChanges(s string)
SetChanges sets the "changes" field.
func (*ActionLogEntryMutation) SetCreatedAt ¶
func (m *ActionLogEntryMutation) SetCreatedAt(t time.Time)
SetCreatedAt sets the "created_at" field.
func (*ActionLogEntryMutation) SetField ¶
func (m *ActionLogEntryMutation) 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 (*ActionLogEntryMutation) SetID ¶
func (m *ActionLogEntryMutation) SetID(id int)
SetID sets the value of the id field. Note that this operation is only accepted on creation of ActionLogEntry entities.
func (*ActionLogEntryMutation) SetIP ¶
func (m *ActionLogEntryMutation) SetIP(s string)
SetIP sets the "ip" field.
func (*ActionLogEntryMutation) SetObjectID ¶
func (m *ActionLogEntryMutation) SetObjectID(s string)
SetObjectID sets the "object_id" field.
func (*ActionLogEntryMutation) SetObjectKind ¶
func (m *ActionLogEntryMutation) SetObjectKind(s string)
SetObjectKind sets the "object_kind" field.
func (*ActionLogEntryMutation) SetObjectLabel ¶
func (m *ActionLogEntryMutation) SetObjectLabel(s string)
SetObjectLabel sets the "object_label" field.
func (*ActionLogEntryMutation) SetObjectType ¶
func (m *ActionLogEntryMutation) SetObjectType(s string)
SetObjectType sets the "object_type" field.
func (*ActionLogEntryMutation) SetObjectURL ¶
func (m *ActionLogEntryMutation) SetObjectURL(s string)
SetObjectURL sets the "object_url" field.
func (*ActionLogEntryMutation) SetOp ¶
func (m *ActionLogEntryMutation) SetOp(op Op)
SetOp allows setting the mutation operation.
func (*ActionLogEntryMutation) SetType ¶
func (m *ActionLogEntryMutation) SetType(s string)
SetType sets the "type" field.
func (ActionLogEntryMutation) Tx ¶
func (m ActionLogEntryMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*ActionLogEntryMutation) Type ¶
func (m *ActionLogEntryMutation) Type() string
Type returns the node type of this mutation (ActionLogEntry).
func (*ActionLogEntryMutation) Where ¶
func (m *ActionLogEntryMutation) Where(ps ...predicate.ActionLogEntry)
Where appends a list predicates to the ActionLogEntryMutation builder.
func (*ActionLogEntryMutation) WhereP ¶
func (m *ActionLogEntryMutation) WhereP(ps ...func(*sql.Selector))
WhereP appends storage-level predicates to the ActionLogEntryMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.
type ActionLogEntryQuery ¶
type ActionLogEntryQuery struct {
// contains filtered or unexported fields
}
ActionLogEntryQuery is the builder for querying ActionLogEntry entities.
func (*ActionLogEntryQuery) Aggregate ¶
func (_q *ActionLogEntryQuery) Aggregate(fns ...AggregateFunc) *ActionLogEntrySelect
Aggregate returns a ActionLogEntrySelect configured with the given aggregations.
func (*ActionLogEntryQuery) All ¶
func (_q *ActionLogEntryQuery) All(ctx context.Context) ([]*ActionLogEntry, error)
All executes the query and returns a list of ActionLogEntries.
func (*ActionLogEntryQuery) AllX ¶
func (_q *ActionLogEntryQuery) AllX(ctx context.Context) []*ActionLogEntry
AllX is like All, but panics if an error occurs.
func (*ActionLogEntryQuery) Clone ¶
func (_q *ActionLogEntryQuery) Clone() *ActionLogEntryQuery
Clone returns a duplicate of the ActionLogEntryQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*ActionLogEntryQuery) Count ¶
func (_q *ActionLogEntryQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*ActionLogEntryQuery) CountX ¶
func (_q *ActionLogEntryQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*ActionLogEntryQuery) Exist ¶
func (_q *ActionLogEntryQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*ActionLogEntryQuery) ExistX ¶
func (_q *ActionLogEntryQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*ActionLogEntryQuery) First ¶
func (_q *ActionLogEntryQuery) First(ctx context.Context) (*ActionLogEntry, error)
First returns the first ActionLogEntry entity from the query. Returns a *NotFoundError when no ActionLogEntry was found.
func (*ActionLogEntryQuery) FirstID ¶
func (_q *ActionLogEntryQuery) FirstID(ctx context.Context) (id int, err error)
FirstID returns the first ActionLogEntry ID from the query. Returns a *NotFoundError when no ActionLogEntry ID was found.
func (*ActionLogEntryQuery) FirstIDX ¶
func (_q *ActionLogEntryQuery) FirstIDX(ctx context.Context) int
FirstIDX is like FirstID, but panics if an error occurs.
func (*ActionLogEntryQuery) FirstX ¶
func (_q *ActionLogEntryQuery) FirstX(ctx context.Context) *ActionLogEntry
FirstX is like First, but panics if an error occurs.
func (*ActionLogEntryQuery) GroupBy ¶
func (_q *ActionLogEntryQuery) GroupBy(field string, fields ...string) *ActionLogEntryGroupBy
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 {
CreatedAt time.Time `json:"created_at,omitempty"`
Count int `json:"count,omitempty"`
}
client.ActionLogEntry.Query().
GroupBy(actionlogentry.FieldCreatedAt).
Aggregate(generated.Count()).
Scan(ctx, &v)
func (*ActionLogEntryQuery) IDs ¶
func (_q *ActionLogEntryQuery) IDs(ctx context.Context) (ids []int, err error)
IDs executes the query and returns a list of ActionLogEntry IDs.
func (*ActionLogEntryQuery) IDsX ¶
func (_q *ActionLogEntryQuery) IDsX(ctx context.Context) []int
IDsX is like IDs, but panics if an error occurs.
func (*ActionLogEntryQuery) Limit ¶
func (_q *ActionLogEntryQuery) Limit(limit int) *ActionLogEntryQuery
Limit the number of records to be returned by this query.
func (*ActionLogEntryQuery) Offset ¶
func (_q *ActionLogEntryQuery) Offset(offset int) *ActionLogEntryQuery
Offset to start from.
func (*ActionLogEntryQuery) Only ¶
func (_q *ActionLogEntryQuery) Only(ctx context.Context) (*ActionLogEntry, error)
Only returns a single ActionLogEntry entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one ActionLogEntry entity is found. Returns a *NotFoundError when no ActionLogEntry entities are found.
func (*ActionLogEntryQuery) OnlyID ¶
func (_q *ActionLogEntryQuery) OnlyID(ctx context.Context) (id int, err error)
OnlyID is like Only, but returns the only ActionLogEntry ID in the query. Returns a *NotSingularError when more than one ActionLogEntry ID is found. Returns a *NotFoundError when no entities are found.
func (*ActionLogEntryQuery) OnlyIDX ¶
func (_q *ActionLogEntryQuery) OnlyIDX(ctx context.Context) int
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*ActionLogEntryQuery) OnlyX ¶
func (_q *ActionLogEntryQuery) OnlyX(ctx context.Context) *ActionLogEntry
OnlyX is like Only, but panics if an error occurs.
func (*ActionLogEntryQuery) Order ¶
func (_q *ActionLogEntryQuery) Order(o ...actionlogentry.OrderOption) *ActionLogEntryQuery
Order specifies how the records should be ordered.
func (*ActionLogEntryQuery) Select ¶
func (_q *ActionLogEntryQuery) Select(fields ...string) *ActionLogEntrySelect
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 {
CreatedAt time.Time `json:"created_at,omitempty"`
}
client.ActionLogEntry.Query().
Select(actionlogentry.FieldCreatedAt).
Scan(ctx, &v)
func (*ActionLogEntryQuery) Unique ¶
func (_q *ActionLogEntryQuery) Unique(unique bool) *ActionLogEntryQuery
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 (*ActionLogEntryQuery) Where ¶
func (_q *ActionLogEntryQuery) Where(ps ...predicate.ActionLogEntry) *ActionLogEntryQuery
Where adds a new predicate for the ActionLogEntryQuery builder.
type ActionLogEntrySelect ¶
type ActionLogEntrySelect struct {
*ActionLogEntryQuery
// contains filtered or unexported fields
}
ActionLogEntrySelect is the builder for selecting fields of ActionLogEntry entities.
func (*ActionLogEntrySelect) Aggregate ¶
func (_s *ActionLogEntrySelect) Aggregate(fns ...AggregateFunc) *ActionLogEntrySelect
Aggregate adds the given aggregation functions to the selector query.
func (*ActionLogEntrySelect) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*ActionLogEntrySelect) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*ActionLogEntrySelect) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*ActionLogEntrySelect) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*ActionLogEntrySelect) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*ActionLogEntrySelect) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*ActionLogEntrySelect) Scan ¶
func (_s *ActionLogEntrySelect) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*ActionLogEntrySelect) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type ActionLogEntryUpdate ¶
type ActionLogEntryUpdate struct {
// contains filtered or unexported fields
}
ActionLogEntryUpdate is the builder for updating ActionLogEntry entities.
func (*ActionLogEntryUpdate) AddActorID ¶
func (_u *ActionLogEntryUpdate) AddActorID(v int) *ActionLogEntryUpdate
AddActorID adds value to the "actor_id" field.
func (*ActionLogEntryUpdate) ClearActorID ¶
func (_u *ActionLogEntryUpdate) ClearActorID() *ActionLogEntryUpdate
ClearActorID clears the value of the "actor_id" field.
func (*ActionLogEntryUpdate) Exec ¶
func (_u *ActionLogEntryUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*ActionLogEntryUpdate) ExecX ¶
func (_u *ActionLogEntryUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ActionLogEntryUpdate) Mutation ¶
func (_u *ActionLogEntryUpdate) Mutation() *ActionLogEntryMutation
Mutation returns the ActionLogEntryMutation object of the builder.
func (*ActionLogEntryUpdate) Save ¶
func (_u *ActionLogEntryUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*ActionLogEntryUpdate) SaveX ¶
func (_u *ActionLogEntryUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*ActionLogEntryUpdate) SetActionGroup ¶
func (_u *ActionLogEntryUpdate) SetActionGroup(v string) *ActionLogEntryUpdate
SetActionGroup sets the "action_group" field.
func (*ActionLogEntryUpdate) SetActorID ¶
func (_u *ActionLogEntryUpdate) SetActorID(v int) *ActionLogEntryUpdate
SetActorID sets the "actor_id" field.
func (*ActionLogEntryUpdate) SetActorName ¶
func (_u *ActionLogEntryUpdate) SetActorName(v string) *ActionLogEntryUpdate
SetActorName sets the "actor_name" field.
func (*ActionLogEntryUpdate) SetChanges ¶
func (_u *ActionLogEntryUpdate) SetChanges(v string) *ActionLogEntryUpdate
SetChanges sets the "changes" field.
func (*ActionLogEntryUpdate) SetCreatedAt ¶
func (_u *ActionLogEntryUpdate) SetCreatedAt(v time.Time) *ActionLogEntryUpdate
SetCreatedAt sets the "created_at" field.
func (*ActionLogEntryUpdate) SetIP ¶
func (_u *ActionLogEntryUpdate) SetIP(v string) *ActionLogEntryUpdate
SetIP sets the "ip" field.
func (*ActionLogEntryUpdate) SetNillableActionGroup ¶
func (_u *ActionLogEntryUpdate) SetNillableActionGroup(v *string) *ActionLogEntryUpdate
SetNillableActionGroup sets the "action_group" field if the given value is not nil.
func (*ActionLogEntryUpdate) SetNillableActorID ¶
func (_u *ActionLogEntryUpdate) SetNillableActorID(v *int) *ActionLogEntryUpdate
SetNillableActorID sets the "actor_id" field if the given value is not nil.
func (*ActionLogEntryUpdate) SetNillableActorName ¶
func (_u *ActionLogEntryUpdate) SetNillableActorName(v *string) *ActionLogEntryUpdate
SetNillableActorName sets the "actor_name" field if the given value is not nil.
func (*ActionLogEntryUpdate) SetNillableChanges ¶
func (_u *ActionLogEntryUpdate) SetNillableChanges(v *string) *ActionLogEntryUpdate
SetNillableChanges sets the "changes" field if the given value is not nil.
func (*ActionLogEntryUpdate) SetNillableCreatedAt ¶
func (_u *ActionLogEntryUpdate) SetNillableCreatedAt(v *time.Time) *ActionLogEntryUpdate
SetNillableCreatedAt sets the "created_at" field if the given value is not nil.
func (*ActionLogEntryUpdate) SetNillableIP ¶
func (_u *ActionLogEntryUpdate) SetNillableIP(v *string) *ActionLogEntryUpdate
SetNillableIP sets the "ip" field if the given value is not nil.
func (*ActionLogEntryUpdate) SetNillableObjectID ¶
func (_u *ActionLogEntryUpdate) SetNillableObjectID(v *string) *ActionLogEntryUpdate
SetNillableObjectID sets the "object_id" field if the given value is not nil.
func (*ActionLogEntryUpdate) SetNillableObjectKind ¶
func (_u *ActionLogEntryUpdate) SetNillableObjectKind(v *string) *ActionLogEntryUpdate
SetNillableObjectKind sets the "object_kind" field if the given value is not nil.
func (*ActionLogEntryUpdate) SetNillableObjectLabel ¶
func (_u *ActionLogEntryUpdate) SetNillableObjectLabel(v *string) *ActionLogEntryUpdate
SetNillableObjectLabel sets the "object_label" field if the given value is not nil.
func (*ActionLogEntryUpdate) SetNillableObjectType ¶
func (_u *ActionLogEntryUpdate) SetNillableObjectType(v *string) *ActionLogEntryUpdate
SetNillableObjectType sets the "object_type" field if the given value is not nil.
func (*ActionLogEntryUpdate) SetNillableObjectURL ¶
func (_u *ActionLogEntryUpdate) SetNillableObjectURL(v *string) *ActionLogEntryUpdate
SetNillableObjectURL sets the "object_url" field if the given value is not nil.
func (*ActionLogEntryUpdate) SetNillableType ¶
func (_u *ActionLogEntryUpdate) SetNillableType(v *string) *ActionLogEntryUpdate
SetNillableType sets the "type" field if the given value is not nil.
func (*ActionLogEntryUpdate) SetObjectID ¶
func (_u *ActionLogEntryUpdate) SetObjectID(v string) *ActionLogEntryUpdate
SetObjectID sets the "object_id" field.
func (*ActionLogEntryUpdate) SetObjectKind ¶
func (_u *ActionLogEntryUpdate) SetObjectKind(v string) *ActionLogEntryUpdate
SetObjectKind sets the "object_kind" field.
func (*ActionLogEntryUpdate) SetObjectLabel ¶
func (_u *ActionLogEntryUpdate) SetObjectLabel(v string) *ActionLogEntryUpdate
SetObjectLabel sets the "object_label" field.
func (*ActionLogEntryUpdate) SetObjectType ¶
func (_u *ActionLogEntryUpdate) SetObjectType(v string) *ActionLogEntryUpdate
SetObjectType sets the "object_type" field.
func (*ActionLogEntryUpdate) SetObjectURL ¶
func (_u *ActionLogEntryUpdate) SetObjectURL(v string) *ActionLogEntryUpdate
SetObjectURL sets the "object_url" field.
func (*ActionLogEntryUpdate) SetType ¶
func (_u *ActionLogEntryUpdate) SetType(v string) *ActionLogEntryUpdate
SetType sets the "type" field.
func (*ActionLogEntryUpdate) Where ¶
func (_u *ActionLogEntryUpdate) Where(ps ...predicate.ActionLogEntry) *ActionLogEntryUpdate
Where appends a list predicates to the ActionLogEntryUpdate builder.
type ActionLogEntryUpdateOne ¶
type ActionLogEntryUpdateOne struct {
// contains filtered or unexported fields
}
ActionLogEntryUpdateOne is the builder for updating a single ActionLogEntry entity.
func (*ActionLogEntryUpdateOne) AddActorID ¶
func (_u *ActionLogEntryUpdateOne) AddActorID(v int) *ActionLogEntryUpdateOne
AddActorID adds value to the "actor_id" field.
func (*ActionLogEntryUpdateOne) ClearActorID ¶
func (_u *ActionLogEntryUpdateOne) ClearActorID() *ActionLogEntryUpdateOne
ClearActorID clears the value of the "actor_id" field.
func (*ActionLogEntryUpdateOne) Exec ¶
func (_u *ActionLogEntryUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*ActionLogEntryUpdateOne) ExecX ¶
func (_u *ActionLogEntryUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ActionLogEntryUpdateOne) Mutation ¶
func (_u *ActionLogEntryUpdateOne) Mutation() *ActionLogEntryMutation
Mutation returns the ActionLogEntryMutation object of the builder.
func (*ActionLogEntryUpdateOne) Save ¶
func (_u *ActionLogEntryUpdateOne) Save(ctx context.Context) (*ActionLogEntry, error)
Save executes the query and returns the updated ActionLogEntry entity.
func (*ActionLogEntryUpdateOne) SaveX ¶
func (_u *ActionLogEntryUpdateOne) SaveX(ctx context.Context) *ActionLogEntry
SaveX is like Save, but panics if an error occurs.
func (*ActionLogEntryUpdateOne) Select ¶
func (_u *ActionLogEntryUpdateOne) Select(field string, fields ...string) *ActionLogEntryUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*ActionLogEntryUpdateOne) SetActionGroup ¶
func (_u *ActionLogEntryUpdateOne) SetActionGroup(v string) *ActionLogEntryUpdateOne
SetActionGroup sets the "action_group" field.
func (*ActionLogEntryUpdateOne) SetActorID ¶
func (_u *ActionLogEntryUpdateOne) SetActorID(v int) *ActionLogEntryUpdateOne
SetActorID sets the "actor_id" field.
func (*ActionLogEntryUpdateOne) SetActorName ¶
func (_u *ActionLogEntryUpdateOne) SetActorName(v string) *ActionLogEntryUpdateOne
SetActorName sets the "actor_name" field.
func (*ActionLogEntryUpdateOne) SetChanges ¶
func (_u *ActionLogEntryUpdateOne) SetChanges(v string) *ActionLogEntryUpdateOne
SetChanges sets the "changes" field.
func (*ActionLogEntryUpdateOne) SetCreatedAt ¶
func (_u *ActionLogEntryUpdateOne) SetCreatedAt(v time.Time) *ActionLogEntryUpdateOne
SetCreatedAt sets the "created_at" field.
func (*ActionLogEntryUpdateOne) SetIP ¶
func (_u *ActionLogEntryUpdateOne) SetIP(v string) *ActionLogEntryUpdateOne
SetIP sets the "ip" field.
func (*ActionLogEntryUpdateOne) SetNillableActionGroup ¶
func (_u *ActionLogEntryUpdateOne) SetNillableActionGroup(v *string) *ActionLogEntryUpdateOne
SetNillableActionGroup sets the "action_group" field if the given value is not nil.
func (*ActionLogEntryUpdateOne) SetNillableActorID ¶
func (_u *ActionLogEntryUpdateOne) SetNillableActorID(v *int) *ActionLogEntryUpdateOne
SetNillableActorID sets the "actor_id" field if the given value is not nil.
func (*ActionLogEntryUpdateOne) SetNillableActorName ¶
func (_u *ActionLogEntryUpdateOne) SetNillableActorName(v *string) *ActionLogEntryUpdateOne
SetNillableActorName sets the "actor_name" field if the given value is not nil.
func (*ActionLogEntryUpdateOne) SetNillableChanges ¶
func (_u *ActionLogEntryUpdateOne) SetNillableChanges(v *string) *ActionLogEntryUpdateOne
SetNillableChanges sets the "changes" field if the given value is not nil.
func (*ActionLogEntryUpdateOne) SetNillableCreatedAt ¶
func (_u *ActionLogEntryUpdateOne) SetNillableCreatedAt(v *time.Time) *ActionLogEntryUpdateOne
SetNillableCreatedAt sets the "created_at" field if the given value is not nil.
func (*ActionLogEntryUpdateOne) SetNillableIP ¶
func (_u *ActionLogEntryUpdateOne) SetNillableIP(v *string) *ActionLogEntryUpdateOne
SetNillableIP sets the "ip" field if the given value is not nil.
func (*ActionLogEntryUpdateOne) SetNillableObjectID ¶
func (_u *ActionLogEntryUpdateOne) SetNillableObjectID(v *string) *ActionLogEntryUpdateOne
SetNillableObjectID sets the "object_id" field if the given value is not nil.
func (*ActionLogEntryUpdateOne) SetNillableObjectKind ¶
func (_u *ActionLogEntryUpdateOne) SetNillableObjectKind(v *string) *ActionLogEntryUpdateOne
SetNillableObjectKind sets the "object_kind" field if the given value is not nil.
func (*ActionLogEntryUpdateOne) SetNillableObjectLabel ¶
func (_u *ActionLogEntryUpdateOne) SetNillableObjectLabel(v *string) *ActionLogEntryUpdateOne
SetNillableObjectLabel sets the "object_label" field if the given value is not nil.
func (*ActionLogEntryUpdateOne) SetNillableObjectType ¶
func (_u *ActionLogEntryUpdateOne) SetNillableObjectType(v *string) *ActionLogEntryUpdateOne
SetNillableObjectType sets the "object_type" field if the given value is not nil.
func (*ActionLogEntryUpdateOne) SetNillableObjectURL ¶
func (_u *ActionLogEntryUpdateOne) SetNillableObjectURL(v *string) *ActionLogEntryUpdateOne
SetNillableObjectURL sets the "object_url" field if the given value is not nil.
func (*ActionLogEntryUpdateOne) SetNillableType ¶
func (_u *ActionLogEntryUpdateOne) SetNillableType(v *string) *ActionLogEntryUpdateOne
SetNillableType sets the "type" field if the given value is not nil.
func (*ActionLogEntryUpdateOne) SetObjectID ¶
func (_u *ActionLogEntryUpdateOne) SetObjectID(v string) *ActionLogEntryUpdateOne
SetObjectID sets the "object_id" field.
func (*ActionLogEntryUpdateOne) SetObjectKind ¶
func (_u *ActionLogEntryUpdateOne) SetObjectKind(v string) *ActionLogEntryUpdateOne
SetObjectKind sets the "object_kind" field.
func (*ActionLogEntryUpdateOne) SetObjectLabel ¶
func (_u *ActionLogEntryUpdateOne) SetObjectLabel(v string) *ActionLogEntryUpdateOne
SetObjectLabel sets the "object_label" field.
func (*ActionLogEntryUpdateOne) SetObjectType ¶
func (_u *ActionLogEntryUpdateOne) SetObjectType(v string) *ActionLogEntryUpdateOne
SetObjectType sets the "object_type" field.
func (*ActionLogEntryUpdateOne) SetObjectURL ¶
func (_u *ActionLogEntryUpdateOne) SetObjectURL(v string) *ActionLogEntryUpdateOne
SetObjectURL sets the "object_url" field.
func (*ActionLogEntryUpdateOne) SetType ¶
func (_u *ActionLogEntryUpdateOne) SetType(v string) *ActionLogEntryUpdateOne
SetType sets the "type" field.
func (*ActionLogEntryUpdateOne) Where ¶
func (_u *ActionLogEntryUpdateOne) Where(ps ...predicate.ActionLogEntry) *ActionLogEntryUpdateOne
Where appends a list predicates to the ActionLogEntryUpdate builder.
type ActionLogSettings ¶
type ActionLogSettings struct {
// ID of the ent.
ID int `json:"id,omitempty"`
// KeepDays holds the value of the "keep_days" field.
KeepDays int `json:"keep_days,omitempty"`
// LogIP holds the value of the "log_ip" field.
LogIP bool `json:"log_ip,omitempty"`
// GroupsOff holds the value of the "groups_off" field.
GroupsOff string `json:"groups_off,omitempty"`
// contains filtered or unexported fields
}
ActionLogSettings is the model entity for the ActionLogSettings schema.
func (*ActionLogSettings) String ¶
func (_m *ActionLogSettings) String() string
String implements the fmt.Stringer.
func (*ActionLogSettings) Unwrap ¶
func (_m *ActionLogSettings) Unwrap() *ActionLogSettings
Unwrap unwraps the ActionLogSettings 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 (*ActionLogSettings) Update ¶
func (_m *ActionLogSettings) Update() *ActionLogSettingsUpdateOne
Update returns a builder for updating this ActionLogSettings. Note that you need to call ActionLogSettings.Unwrap() before calling this method if this ActionLogSettings was returned from a transaction, and the transaction was committed or rolled back.
type ActionLogSettingsClient ¶
type ActionLogSettingsClient struct {
// contains filtered or unexported fields
}
ActionLogSettingsClient is a client for the ActionLogSettings schema.
func NewActionLogSettingsClient ¶
func NewActionLogSettingsClient(c config) *ActionLogSettingsClient
NewActionLogSettingsClient returns a client for the ActionLogSettings from the given config.
func (*ActionLogSettingsClient) Create ¶
func (c *ActionLogSettingsClient) Create() *ActionLogSettingsCreate
Create returns a builder for creating a ActionLogSettings entity.
func (*ActionLogSettingsClient) CreateBulk ¶
func (c *ActionLogSettingsClient) CreateBulk(builders ...*ActionLogSettingsCreate) *ActionLogSettingsCreateBulk
CreateBulk returns a builder for creating a bulk of ActionLogSettings entities.
func (*ActionLogSettingsClient) Delete ¶
func (c *ActionLogSettingsClient) Delete() *ActionLogSettingsDelete
Delete returns a delete builder for ActionLogSettings.
func (*ActionLogSettingsClient) DeleteOne ¶
func (c *ActionLogSettingsClient) DeleteOne(_m *ActionLogSettings) *ActionLogSettingsDeleteOne
DeleteOne returns a builder for deleting the given entity.
func (*ActionLogSettingsClient) DeleteOneID ¶
func (c *ActionLogSettingsClient) DeleteOneID(id int) *ActionLogSettingsDeleteOne
DeleteOneID returns a builder for deleting the given entity by its id.
func (*ActionLogSettingsClient) Get ¶
func (c *ActionLogSettingsClient) Get(ctx context.Context, id int) (*ActionLogSettings, error)
Get returns a ActionLogSettings entity by its id.
func (*ActionLogSettingsClient) GetX ¶
func (c *ActionLogSettingsClient) GetX(ctx context.Context, id int) *ActionLogSettings
GetX is like Get, but panics if an error occurs.
func (*ActionLogSettingsClient) Hooks ¶
func (c *ActionLogSettingsClient) Hooks() []Hook
Hooks returns the client hooks.
func (*ActionLogSettingsClient) Intercept ¶
func (c *ActionLogSettingsClient) Intercept(interceptors ...Interceptor)
Intercept adds a list of query interceptors to the interceptors stack. A call to `Intercept(f, g, h)` equals to `actionlogsettings.Intercept(f(g(h())))`.
func (*ActionLogSettingsClient) Interceptors ¶
func (c *ActionLogSettingsClient) Interceptors() []Interceptor
Interceptors returns the client interceptors.
func (*ActionLogSettingsClient) MapCreateBulk ¶
func (c *ActionLogSettingsClient) MapCreateBulk(slice any, setFunc func(*ActionLogSettingsCreate, int)) *ActionLogSettingsCreateBulk
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 (*ActionLogSettingsClient) Query ¶
func (c *ActionLogSettingsClient) Query() *ActionLogSettingsQuery
Query returns a query builder for ActionLogSettings.
func (*ActionLogSettingsClient) Update ¶
func (c *ActionLogSettingsClient) Update() *ActionLogSettingsUpdate
Update returns an update builder for ActionLogSettings.
func (*ActionLogSettingsClient) UpdateOne ¶
func (c *ActionLogSettingsClient) UpdateOne(_m *ActionLogSettings) *ActionLogSettingsUpdateOne
UpdateOne returns an update builder for the given entity.
func (*ActionLogSettingsClient) UpdateOneID ¶
func (c *ActionLogSettingsClient) UpdateOneID(id int) *ActionLogSettingsUpdateOne
UpdateOneID returns an update builder for the given id.
func (*ActionLogSettingsClient) Use ¶
func (c *ActionLogSettingsClient) Use(hooks ...Hook)
Use adds a list of mutation hooks to the hooks stack. A call to `Use(f, g, h)` equals to `actionlogsettings.Hooks(f(g(h())))`.
type ActionLogSettingsCreate ¶
type ActionLogSettingsCreate struct {
// contains filtered or unexported fields
}
ActionLogSettingsCreate is the builder for creating a ActionLogSettings entity.
func (*ActionLogSettingsCreate) Exec ¶
func (_c *ActionLogSettingsCreate) Exec(ctx context.Context) error
Exec executes the query.
func (*ActionLogSettingsCreate) ExecX ¶
func (_c *ActionLogSettingsCreate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ActionLogSettingsCreate) Mutation ¶
func (_c *ActionLogSettingsCreate) Mutation() *ActionLogSettingsMutation
Mutation returns the ActionLogSettingsMutation object of the builder.
func (*ActionLogSettingsCreate) Save ¶
func (_c *ActionLogSettingsCreate) Save(ctx context.Context) (*ActionLogSettings, error)
Save creates the ActionLogSettings in the database.
func (*ActionLogSettingsCreate) SaveX ¶
func (_c *ActionLogSettingsCreate) SaveX(ctx context.Context) *ActionLogSettings
SaveX calls Save and panics if Save returns an error.
func (*ActionLogSettingsCreate) SetGroupsOff ¶
func (_c *ActionLogSettingsCreate) SetGroupsOff(v string) *ActionLogSettingsCreate
SetGroupsOff sets the "groups_off" field.
func (*ActionLogSettingsCreate) SetID ¶
func (_c *ActionLogSettingsCreate) SetID(v int) *ActionLogSettingsCreate
SetID sets the "id" field.
func (*ActionLogSettingsCreate) SetKeepDays ¶
func (_c *ActionLogSettingsCreate) SetKeepDays(v int) *ActionLogSettingsCreate
SetKeepDays sets the "keep_days" field.
func (*ActionLogSettingsCreate) SetLogIP ¶
func (_c *ActionLogSettingsCreate) SetLogIP(v bool) *ActionLogSettingsCreate
SetLogIP sets the "log_ip" field.
func (*ActionLogSettingsCreate) SetNillableGroupsOff ¶
func (_c *ActionLogSettingsCreate) SetNillableGroupsOff(v *string) *ActionLogSettingsCreate
SetNillableGroupsOff sets the "groups_off" field if the given value is not nil.
func (*ActionLogSettingsCreate) SetNillableKeepDays ¶
func (_c *ActionLogSettingsCreate) SetNillableKeepDays(v *int) *ActionLogSettingsCreate
SetNillableKeepDays sets the "keep_days" field if the given value is not nil.
func (*ActionLogSettingsCreate) SetNillableLogIP ¶
func (_c *ActionLogSettingsCreate) SetNillableLogIP(v *bool) *ActionLogSettingsCreate
SetNillableLogIP sets the "log_ip" field if the given value is not nil.
type ActionLogSettingsCreateBulk ¶
type ActionLogSettingsCreateBulk struct {
// contains filtered or unexported fields
}
ActionLogSettingsCreateBulk is the builder for creating many ActionLogSettings entities in bulk.
func (*ActionLogSettingsCreateBulk) Exec ¶
func (_c *ActionLogSettingsCreateBulk) Exec(ctx context.Context) error
Exec executes the query.
func (*ActionLogSettingsCreateBulk) ExecX ¶
func (_c *ActionLogSettingsCreateBulk) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ActionLogSettingsCreateBulk) Save ¶
func (_c *ActionLogSettingsCreateBulk) Save(ctx context.Context) ([]*ActionLogSettings, error)
Save creates the ActionLogSettings entities in the database.
func (*ActionLogSettingsCreateBulk) SaveX ¶
func (_c *ActionLogSettingsCreateBulk) SaveX(ctx context.Context) []*ActionLogSettings
SaveX is like Save, but panics if an error occurs.
type ActionLogSettingsDelete ¶
type ActionLogSettingsDelete struct {
// contains filtered or unexported fields
}
ActionLogSettingsDelete is the builder for deleting a ActionLogSettings entity.
func (*ActionLogSettingsDelete) Exec ¶
func (_d *ActionLogSettingsDelete) Exec(ctx context.Context) (int, error)
Exec executes the deletion query and returns how many vertices were deleted.
func (*ActionLogSettingsDelete) ExecX ¶
func (_d *ActionLogSettingsDelete) ExecX(ctx context.Context) int
ExecX is like Exec, but panics if an error occurs.
func (*ActionLogSettingsDelete) Where ¶
func (_d *ActionLogSettingsDelete) Where(ps ...predicate.ActionLogSettings) *ActionLogSettingsDelete
Where appends a list predicates to the ActionLogSettingsDelete builder.
type ActionLogSettingsDeleteOne ¶
type ActionLogSettingsDeleteOne struct {
// contains filtered or unexported fields
}
ActionLogSettingsDeleteOne is the builder for deleting a single ActionLogSettings entity.
func (*ActionLogSettingsDeleteOne) Exec ¶
func (_d *ActionLogSettingsDeleteOne) Exec(ctx context.Context) error
Exec executes the deletion query.
func (*ActionLogSettingsDeleteOne) ExecX ¶
func (_d *ActionLogSettingsDeleteOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ActionLogSettingsDeleteOne) Where ¶
func (_d *ActionLogSettingsDeleteOne) Where(ps ...predicate.ActionLogSettings) *ActionLogSettingsDeleteOne
Where appends a list predicates to the ActionLogSettingsDelete builder.
type ActionLogSettingsGroupBy ¶
type ActionLogSettingsGroupBy struct {
// contains filtered or unexported fields
}
ActionLogSettingsGroupBy is the group-by builder for ActionLogSettings entities.
func (*ActionLogSettingsGroupBy) Aggregate ¶
func (_g *ActionLogSettingsGroupBy) Aggregate(fns ...AggregateFunc) *ActionLogSettingsGroupBy
Aggregate adds the given aggregation functions to the group-by query.
func (*ActionLogSettingsGroupBy) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*ActionLogSettingsGroupBy) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*ActionLogSettingsGroupBy) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*ActionLogSettingsGroupBy) Float64X ¶
Float64X is like Float64, but panics if an error occurs.
func (*ActionLogSettingsGroupBy) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*ActionLogSettingsGroupBy) Float64sX ¶
Float64sX is like Float64s, but panics if an error occurs.
func (*ActionLogSettingsGroupBy) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*ActionLogSettingsGroupBy) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*ActionLogSettingsGroupBy) Scan ¶
func (_g *ActionLogSettingsGroupBy) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*ActionLogSettingsGroupBy) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type ActionLogSettingsMutation ¶
type ActionLogSettingsMutation struct {
// contains filtered or unexported fields
}
ActionLogSettingsMutation represents an operation that mutates the ActionLogSettings nodes in the graph.
func (*ActionLogSettingsMutation) AddField ¶
func (m *ActionLogSettingsMutation) 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 (*ActionLogSettingsMutation) AddKeepDays ¶
func (m *ActionLogSettingsMutation) AddKeepDays(i int)
AddKeepDays adds i to the "keep_days" field.
func (*ActionLogSettingsMutation) AddedEdges ¶
func (m *ActionLogSettingsMutation) AddedEdges() []string
AddedEdges returns all edge names that were set/added in this mutation.
func (*ActionLogSettingsMutation) AddedField ¶
func (m *ActionLogSettingsMutation) 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 (*ActionLogSettingsMutation) AddedFields ¶
func (m *ActionLogSettingsMutation) AddedFields() []string
AddedFields returns all numeric fields that were incremented/decremented during this mutation.
func (*ActionLogSettingsMutation) AddedIDs ¶
func (m *ActionLogSettingsMutation) AddedIDs(name string) []ent.Value
AddedIDs returns all IDs (to other nodes) that were added for the given edge name in this mutation.
func (*ActionLogSettingsMutation) AddedKeepDays ¶
func (m *ActionLogSettingsMutation) AddedKeepDays() (r int, exists bool)
AddedKeepDays returns the value that was added to the "keep_days" field in this mutation.
func (*ActionLogSettingsMutation) ClearEdge ¶
func (m *ActionLogSettingsMutation) 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 (*ActionLogSettingsMutation) ClearField ¶
func (m *ActionLogSettingsMutation) 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 (*ActionLogSettingsMutation) ClearedEdges ¶
func (m *ActionLogSettingsMutation) ClearedEdges() []string
ClearedEdges returns all edge names that were cleared in this mutation.
func (*ActionLogSettingsMutation) ClearedFields ¶
func (m *ActionLogSettingsMutation) ClearedFields() []string
ClearedFields returns all nullable fields that were cleared during this mutation.
func (ActionLogSettingsMutation) Client ¶
func (m ActionLogSettingsMutation) 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 (*ActionLogSettingsMutation) EdgeCleared ¶
func (m *ActionLogSettingsMutation) EdgeCleared(name string) bool
EdgeCleared returns a boolean which indicates if the edge with the given name was cleared in this mutation.
func (*ActionLogSettingsMutation) Field ¶
func (m *ActionLogSettingsMutation) 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 (*ActionLogSettingsMutation) FieldCleared ¶
func (m *ActionLogSettingsMutation) FieldCleared(name string) bool
FieldCleared returns a boolean indicating if a field with the given name was cleared in this mutation.
func (*ActionLogSettingsMutation) Fields ¶
func (m *ActionLogSettingsMutation) 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 (*ActionLogSettingsMutation) GroupsOff ¶
func (m *ActionLogSettingsMutation) GroupsOff() (r string, exists bool)
GroupsOff returns the value of the "groups_off" field in the mutation.
func (*ActionLogSettingsMutation) ID ¶
func (m *ActionLogSettingsMutation) 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 (*ActionLogSettingsMutation) IDs ¶
func (m *ActionLogSettingsMutation) 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 (*ActionLogSettingsMutation) KeepDays ¶
func (m *ActionLogSettingsMutation) KeepDays() (r int, exists bool)
KeepDays returns the value of the "keep_days" field in the mutation.
func (*ActionLogSettingsMutation) LogIP ¶
func (m *ActionLogSettingsMutation) LogIP() (r bool, exists bool)
LogIP returns the value of the "log_ip" field in the mutation.
func (*ActionLogSettingsMutation) 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 (*ActionLogSettingsMutation) OldGroupsOff ¶
func (m *ActionLogSettingsMutation) OldGroupsOff(ctx context.Context) (v string, err error)
OldGroupsOff returns the old "groups_off" field's value of the ActionLogSettings entity. If the ActionLogSettings 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 (*ActionLogSettingsMutation) OldKeepDays ¶
func (m *ActionLogSettingsMutation) OldKeepDays(ctx context.Context) (v int, err error)
OldKeepDays returns the old "keep_days" field's value of the ActionLogSettings entity. If the ActionLogSettings 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 (*ActionLogSettingsMutation) OldLogIP ¶
func (m *ActionLogSettingsMutation) OldLogIP(ctx context.Context) (v bool, err error)
OldLogIP returns the old "log_ip" field's value of the ActionLogSettings entity. If the ActionLogSettings 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 (*ActionLogSettingsMutation) Op ¶
func (m *ActionLogSettingsMutation) Op() Op
Op returns the operation name.
func (*ActionLogSettingsMutation) RemovedEdges ¶
func (m *ActionLogSettingsMutation) RemovedEdges() []string
RemovedEdges returns all edge names that were removed in this mutation.
func (*ActionLogSettingsMutation) RemovedIDs ¶
func (m *ActionLogSettingsMutation) 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 (*ActionLogSettingsMutation) ResetEdge ¶
func (m *ActionLogSettingsMutation) 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 (*ActionLogSettingsMutation) ResetField ¶
func (m *ActionLogSettingsMutation) 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 (*ActionLogSettingsMutation) ResetGroupsOff ¶
func (m *ActionLogSettingsMutation) ResetGroupsOff()
ResetGroupsOff resets all changes to the "groups_off" field.
func (*ActionLogSettingsMutation) ResetKeepDays ¶
func (m *ActionLogSettingsMutation) ResetKeepDays()
ResetKeepDays resets all changes to the "keep_days" field.
func (*ActionLogSettingsMutation) ResetLogIP ¶
func (m *ActionLogSettingsMutation) ResetLogIP()
ResetLogIP resets all changes to the "log_ip" field.
func (*ActionLogSettingsMutation) SetField ¶
func (m *ActionLogSettingsMutation) 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 (*ActionLogSettingsMutation) SetGroupsOff ¶
func (m *ActionLogSettingsMutation) SetGroupsOff(s string)
SetGroupsOff sets the "groups_off" field.
func (*ActionLogSettingsMutation) SetID ¶
func (m *ActionLogSettingsMutation) SetID(id int)
SetID sets the value of the id field. Note that this operation is only accepted on creation of ActionLogSettings entities.
func (*ActionLogSettingsMutation) SetKeepDays ¶
func (m *ActionLogSettingsMutation) SetKeepDays(i int)
SetKeepDays sets the "keep_days" field.
func (*ActionLogSettingsMutation) SetLogIP ¶
func (m *ActionLogSettingsMutation) SetLogIP(b bool)
SetLogIP sets the "log_ip" field.
func (*ActionLogSettingsMutation) SetOp ¶
func (m *ActionLogSettingsMutation) SetOp(op Op)
SetOp allows setting the mutation operation.
func (ActionLogSettingsMutation) Tx ¶
func (m ActionLogSettingsMutation) Tx() (*Tx, error)
Tx returns an `ent.Tx` for mutations that were executed in transactions; it returns an error otherwise.
func (*ActionLogSettingsMutation) Type ¶
func (m *ActionLogSettingsMutation) Type() string
Type returns the node type of this mutation (ActionLogSettings).
func (*ActionLogSettingsMutation) Where ¶
func (m *ActionLogSettingsMutation) Where(ps ...predicate.ActionLogSettings)
Where appends a list predicates to the ActionLogSettingsMutation builder.
func (*ActionLogSettingsMutation) WhereP ¶
func (m *ActionLogSettingsMutation) WhereP(ps ...func(*sql.Selector))
WhereP appends storage-level predicates to the ActionLogSettingsMutation builder. Using this method, users can use type-assertion to append predicates that do not depend on any generated package.
type ActionLogSettingsQuery ¶
type ActionLogSettingsQuery struct {
// contains filtered or unexported fields
}
ActionLogSettingsQuery is the builder for querying ActionLogSettings entities.
func (*ActionLogSettingsQuery) Aggregate ¶
func (_q *ActionLogSettingsQuery) Aggregate(fns ...AggregateFunc) *ActionLogSettingsSelect
Aggregate returns a ActionLogSettingsSelect configured with the given aggregations.
func (*ActionLogSettingsQuery) All ¶
func (_q *ActionLogSettingsQuery) All(ctx context.Context) ([]*ActionLogSettings, error)
All executes the query and returns a list of ActionLogSettingsSlice.
func (*ActionLogSettingsQuery) AllX ¶
func (_q *ActionLogSettingsQuery) AllX(ctx context.Context) []*ActionLogSettings
AllX is like All, but panics if an error occurs.
func (*ActionLogSettingsQuery) Clone ¶
func (_q *ActionLogSettingsQuery) Clone() *ActionLogSettingsQuery
Clone returns a duplicate of the ActionLogSettingsQuery builder, including all associated steps. It can be used to prepare common query builders and use them differently after the clone is made.
func (*ActionLogSettingsQuery) Count ¶
func (_q *ActionLogSettingsQuery) Count(ctx context.Context) (int, error)
Count returns the count of the given query.
func (*ActionLogSettingsQuery) CountX ¶
func (_q *ActionLogSettingsQuery) CountX(ctx context.Context) int
CountX is like Count, but panics if an error occurs.
func (*ActionLogSettingsQuery) Exist ¶
func (_q *ActionLogSettingsQuery) Exist(ctx context.Context) (bool, error)
Exist returns true if the query has elements in the graph.
func (*ActionLogSettingsQuery) ExistX ¶
func (_q *ActionLogSettingsQuery) ExistX(ctx context.Context) bool
ExistX is like Exist, but panics if an error occurs.
func (*ActionLogSettingsQuery) First ¶
func (_q *ActionLogSettingsQuery) First(ctx context.Context) (*ActionLogSettings, error)
First returns the first ActionLogSettings entity from the query. Returns a *NotFoundError when no ActionLogSettings was found.
func (*ActionLogSettingsQuery) FirstID ¶
func (_q *ActionLogSettingsQuery) FirstID(ctx context.Context) (id int, err error)
FirstID returns the first ActionLogSettings ID from the query. Returns a *NotFoundError when no ActionLogSettings ID was found.
func (*ActionLogSettingsQuery) FirstIDX ¶
func (_q *ActionLogSettingsQuery) FirstIDX(ctx context.Context) int
FirstIDX is like FirstID, but panics if an error occurs.
func (*ActionLogSettingsQuery) FirstX ¶
func (_q *ActionLogSettingsQuery) FirstX(ctx context.Context) *ActionLogSettings
FirstX is like First, but panics if an error occurs.
func (*ActionLogSettingsQuery) GroupBy ¶
func (_q *ActionLogSettingsQuery) GroupBy(field string, fields ...string) *ActionLogSettingsGroupBy
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 {
KeepDays int `json:"keep_days,omitempty"`
Count int `json:"count,omitempty"`
}
client.ActionLogSettings.Query().
GroupBy(actionlogsettings.FieldKeepDays).
Aggregate(generated.Count()).
Scan(ctx, &v)
func (*ActionLogSettingsQuery) IDs ¶
func (_q *ActionLogSettingsQuery) IDs(ctx context.Context) (ids []int, err error)
IDs executes the query and returns a list of ActionLogSettings IDs.
func (*ActionLogSettingsQuery) IDsX ¶
func (_q *ActionLogSettingsQuery) IDsX(ctx context.Context) []int
IDsX is like IDs, but panics if an error occurs.
func (*ActionLogSettingsQuery) Limit ¶
func (_q *ActionLogSettingsQuery) Limit(limit int) *ActionLogSettingsQuery
Limit the number of records to be returned by this query.
func (*ActionLogSettingsQuery) Offset ¶
func (_q *ActionLogSettingsQuery) Offset(offset int) *ActionLogSettingsQuery
Offset to start from.
func (*ActionLogSettingsQuery) Only ¶
func (_q *ActionLogSettingsQuery) Only(ctx context.Context) (*ActionLogSettings, error)
Only returns a single ActionLogSettings entity found by the query, ensuring it only returns one. Returns a *NotSingularError when more than one ActionLogSettings entity is found. Returns a *NotFoundError when no ActionLogSettings entities are found.
func (*ActionLogSettingsQuery) OnlyID ¶
func (_q *ActionLogSettingsQuery) OnlyID(ctx context.Context) (id int, err error)
OnlyID is like Only, but returns the only ActionLogSettings ID in the query. Returns a *NotSingularError when more than one ActionLogSettings ID is found. Returns a *NotFoundError when no entities are found.
func (*ActionLogSettingsQuery) OnlyIDX ¶
func (_q *ActionLogSettingsQuery) OnlyIDX(ctx context.Context) int
OnlyIDX is like OnlyID, but panics if an error occurs.
func (*ActionLogSettingsQuery) OnlyX ¶
func (_q *ActionLogSettingsQuery) OnlyX(ctx context.Context) *ActionLogSettings
OnlyX is like Only, but panics if an error occurs.
func (*ActionLogSettingsQuery) Order ¶
func (_q *ActionLogSettingsQuery) Order(o ...actionlogsettings.OrderOption) *ActionLogSettingsQuery
Order specifies how the records should be ordered.
func (*ActionLogSettingsQuery) Select ¶
func (_q *ActionLogSettingsQuery) Select(fields ...string) *ActionLogSettingsSelect
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 {
KeepDays int `json:"keep_days,omitempty"`
}
client.ActionLogSettings.Query().
Select(actionlogsettings.FieldKeepDays).
Scan(ctx, &v)
func (*ActionLogSettingsQuery) Unique ¶
func (_q *ActionLogSettingsQuery) Unique(unique bool) *ActionLogSettingsQuery
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 (*ActionLogSettingsQuery) Where ¶
func (_q *ActionLogSettingsQuery) Where(ps ...predicate.ActionLogSettings) *ActionLogSettingsQuery
Where adds a new predicate for the ActionLogSettingsQuery builder.
type ActionLogSettingsSelect ¶
type ActionLogSettingsSelect struct {
*ActionLogSettingsQuery
// contains filtered or unexported fields
}
ActionLogSettingsSelect is the builder for selecting fields of ActionLogSettings entities.
func (*ActionLogSettingsSelect) Aggregate ¶
func (_s *ActionLogSettingsSelect) Aggregate(fns ...AggregateFunc) *ActionLogSettingsSelect
Aggregate adds the given aggregation functions to the selector query.
func (*ActionLogSettingsSelect) Bool ¶
Bool returns a single bool from a selector. It is only allowed when selecting one field.
func (*ActionLogSettingsSelect) Bools ¶
Bools returns list of bools from a selector. It is only allowed when selecting one field.
func (*ActionLogSettingsSelect) Float64 ¶
Float64 returns a single float64 from a selector. It is only allowed when selecting one field.
func (*ActionLogSettingsSelect) Float64s ¶
Float64s returns list of float64s from a selector. It is only allowed when selecting one field.
func (*ActionLogSettingsSelect) Float64sX ¶
Float64sX is like Float64s, but panics if an error occurs.
func (*ActionLogSettingsSelect) Int ¶
Int returns a single int from a selector. It is only allowed when selecting one field.
func (*ActionLogSettingsSelect) Ints ¶
Ints returns list of ints from a selector. It is only allowed when selecting one field.
func (*ActionLogSettingsSelect) Scan ¶
func (_s *ActionLogSettingsSelect) Scan(ctx context.Context, v any) error
Scan applies the selector query and scans the result into the given value.
func (*ActionLogSettingsSelect) String ¶
String returns a single string from a selector. It is only allowed when selecting one field.
type ActionLogSettingsSlice ¶
type ActionLogSettingsSlice []*ActionLogSettings
ActionLogSettingsSlice is a parsable slice of ActionLogSettings.
type ActionLogSettingsUpdate ¶
type ActionLogSettingsUpdate struct {
// contains filtered or unexported fields
}
ActionLogSettingsUpdate is the builder for updating ActionLogSettings entities.
func (*ActionLogSettingsUpdate) AddKeepDays ¶
func (_u *ActionLogSettingsUpdate) AddKeepDays(v int) *ActionLogSettingsUpdate
AddKeepDays adds value to the "keep_days" field.
func (*ActionLogSettingsUpdate) Exec ¶
func (_u *ActionLogSettingsUpdate) Exec(ctx context.Context) error
Exec executes the query.
func (*ActionLogSettingsUpdate) ExecX ¶
func (_u *ActionLogSettingsUpdate) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ActionLogSettingsUpdate) Mutation ¶
func (_u *ActionLogSettingsUpdate) Mutation() *ActionLogSettingsMutation
Mutation returns the ActionLogSettingsMutation object of the builder.
func (*ActionLogSettingsUpdate) Save ¶
func (_u *ActionLogSettingsUpdate) Save(ctx context.Context) (int, error)
Save executes the query and returns the number of nodes affected by the update operation.
func (*ActionLogSettingsUpdate) SaveX ¶
func (_u *ActionLogSettingsUpdate) SaveX(ctx context.Context) int
SaveX is like Save, but panics if an error occurs.
func (*ActionLogSettingsUpdate) SetGroupsOff ¶
func (_u *ActionLogSettingsUpdate) SetGroupsOff(v string) *ActionLogSettingsUpdate
SetGroupsOff sets the "groups_off" field.
func (*ActionLogSettingsUpdate) SetKeepDays ¶
func (_u *ActionLogSettingsUpdate) SetKeepDays(v int) *ActionLogSettingsUpdate
SetKeepDays sets the "keep_days" field.
func (*ActionLogSettingsUpdate) SetLogIP ¶
func (_u *ActionLogSettingsUpdate) SetLogIP(v bool) *ActionLogSettingsUpdate
SetLogIP sets the "log_ip" field.
func (*ActionLogSettingsUpdate) SetNillableGroupsOff ¶
func (_u *ActionLogSettingsUpdate) SetNillableGroupsOff(v *string) *ActionLogSettingsUpdate
SetNillableGroupsOff sets the "groups_off" field if the given value is not nil.
func (*ActionLogSettingsUpdate) SetNillableKeepDays ¶
func (_u *ActionLogSettingsUpdate) SetNillableKeepDays(v *int) *ActionLogSettingsUpdate
SetNillableKeepDays sets the "keep_days" field if the given value is not nil.
func (*ActionLogSettingsUpdate) SetNillableLogIP ¶
func (_u *ActionLogSettingsUpdate) SetNillableLogIP(v *bool) *ActionLogSettingsUpdate
SetNillableLogIP sets the "log_ip" field if the given value is not nil.
func (*ActionLogSettingsUpdate) Where ¶
func (_u *ActionLogSettingsUpdate) Where(ps ...predicate.ActionLogSettings) *ActionLogSettingsUpdate
Where appends a list predicates to the ActionLogSettingsUpdate builder.
type ActionLogSettingsUpdateOne ¶
type ActionLogSettingsUpdateOne struct {
// contains filtered or unexported fields
}
ActionLogSettingsUpdateOne is the builder for updating a single ActionLogSettings entity.
func (*ActionLogSettingsUpdateOne) AddKeepDays ¶
func (_u *ActionLogSettingsUpdateOne) AddKeepDays(v int) *ActionLogSettingsUpdateOne
AddKeepDays adds value to the "keep_days" field.
func (*ActionLogSettingsUpdateOne) Exec ¶
func (_u *ActionLogSettingsUpdateOne) Exec(ctx context.Context) error
Exec executes the query on the entity.
func (*ActionLogSettingsUpdateOne) ExecX ¶
func (_u *ActionLogSettingsUpdateOne) ExecX(ctx context.Context)
ExecX is like Exec, but panics if an error occurs.
func (*ActionLogSettingsUpdateOne) Mutation ¶
func (_u *ActionLogSettingsUpdateOne) Mutation() *ActionLogSettingsMutation
Mutation returns the ActionLogSettingsMutation object of the builder.
func (*ActionLogSettingsUpdateOne) Save ¶
func (_u *ActionLogSettingsUpdateOne) Save(ctx context.Context) (*ActionLogSettings, error)
Save executes the query and returns the updated ActionLogSettings entity.
func (*ActionLogSettingsUpdateOne) SaveX ¶
func (_u *ActionLogSettingsUpdateOne) SaveX(ctx context.Context) *ActionLogSettings
SaveX is like Save, but panics if an error occurs.
func (*ActionLogSettingsUpdateOne) Select ¶
func (_u *ActionLogSettingsUpdateOne) Select(field string, fields ...string) *ActionLogSettingsUpdateOne
Select allows selecting one or more fields (columns) of the returned entity. The default is selecting all fields defined in the entity schema.
func (*ActionLogSettingsUpdateOne) SetGroupsOff ¶
func (_u *ActionLogSettingsUpdateOne) SetGroupsOff(v string) *ActionLogSettingsUpdateOne
SetGroupsOff sets the "groups_off" field.
func (*ActionLogSettingsUpdateOne) SetKeepDays ¶
func (_u *ActionLogSettingsUpdateOne) SetKeepDays(v int) *ActionLogSettingsUpdateOne
SetKeepDays sets the "keep_days" field.
func (*ActionLogSettingsUpdateOne) SetLogIP ¶
func (_u *ActionLogSettingsUpdateOne) SetLogIP(v bool) *ActionLogSettingsUpdateOne
SetLogIP sets the "log_ip" field.
func (*ActionLogSettingsUpdateOne) SetNillableGroupsOff ¶
func (_u *ActionLogSettingsUpdateOne) SetNillableGroupsOff(v *string) *ActionLogSettingsUpdateOne
SetNillableGroupsOff sets the "groups_off" field if the given value is not nil.
func (*ActionLogSettingsUpdateOne) SetNillableKeepDays ¶
func (_u *ActionLogSettingsUpdateOne) SetNillableKeepDays(v *int) *ActionLogSettingsUpdateOne
SetNillableKeepDays sets the "keep_days" field if the given value is not nil.
func (*ActionLogSettingsUpdateOne) SetNillableLogIP ¶
func (_u *ActionLogSettingsUpdateOne) SetNillableLogIP(v *bool) *ActionLogSettingsUpdateOne
SetNillableLogIP sets the "log_ip" field if the given value is not nil.
func (*ActionLogSettingsUpdateOne) Where ¶
func (_u *ActionLogSettingsUpdateOne) Where(ps ...predicate.ActionLogSettings) *ActionLogSettingsUpdateOne
Where appends a list predicates to the ActionLogSettingsUpdate builder.
type AggregateFunc ¶
AggregateFunc applies an aggregation step on the group-by traversal/selector.
func As ¶
func As(fn AggregateFunc, end string) AggregateFunc
As is a pseudo aggregation function for renaming another other functions with custom names. For example:
GroupBy(field1, field2). Aggregate(generated.As(generated.Sum(field1), "sum_field1"), (generated.As(generated.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
// ActionLogEntry is the client for interacting with the ActionLogEntry builders.
ActionLogEntry *ActionLogEntryClient
// ActionLogSettings is the client for interacting with the ActionLogSettings builders.
ActionLogSettings *ActionLogSettingsClient
// contains filtered or unexported fields
}
Client is the client that holds all ent builders.
func FromContext ¶
FromContext returns a Client stored inside a context, or nil if there isn't one.
func Open ¶
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) Debug ¶
Debug returns a new debug-client. It's used to get verbose logging on specific operations.
client.Debug(). ActionLogEntry. 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(...)`.
type CommitFunc ¶
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.
type CommitHook ¶
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 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 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 MutateFunc ¶
type MutateFunc = ent.MutateFunc
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 OrderFunc ¶
OrderFunc applies an ordering on the sql selector. Deprecated: Use Asc/Desc functions or the package builders instead.
type QuerierFunc ¶
type QuerierFunc = ent.QuerierFunc
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 RollbackFunc ¶
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.
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 ¶
Rollbacker is the interface that wraps the Rollback method.
type TraverseFunc ¶
type TraverseFunc = ent.TraverseFunc
ent aliases to avoid import conflicts in user's code.
type Tx ¶
type Tx struct {
// ActionLogEntry is the client for interacting with the ActionLogEntry builders.
ActionLogEntry *ActionLogEntryClient
// ActionLogSettings is the client for interacting with the ActionLogSettings builders.
ActionLogSettings *ActionLogSettingsClient
// contains filtered or unexported fields
}
Tx is a transactional client that is created by calling Client.Tx().
func TxFromContext ¶
TxFromContext returns a Tx stored inside a context, or nil if there isn't one.
func (*Tx) OnRollback ¶
func (tx *Tx) OnRollback(f RollbackHook)
OnRollback adds a hook to call on rollback.
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.