MCPcopy Create free account
hub / github.com/chainloop-dev/chainloop / Fields

Method Fields

app/controlplane/pkg/data/ent/schema/group.go:34–50  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

32}
33
34func (Group) Fields() []ent.Field {
35 return []ent.Field{
36 field.UUID("id", uuid.UUID{}).Default(uuid.New).Unique(),
37 field.String("name").NotEmpty(),
38 field.String("description").Optional(),
39 field.UUID("organization_id", uuid.UUID{}),
40 field.Time("created_at").
41 Default(time.Now).
42 Immutable().
43 Annotations(&entsql.Annotation{Default: "CURRENT_TIMESTAMP"}),
44 field.Time("updated_at").
45 Default(time.Now).
46 Annotations(&entsql.Annotation{Default: "CURRENT_TIMESTAMP"}),
47 field.Time("deleted_at").Optional(),
48 field.Int("member_count").Default(0),
49 }
50}
51
52func (Group) Edges() []ent.Edge {
53 return []ent.Edge{

Callers 1

IndexesMethod · 0.45

Calls 5

DefaultMethod · 0.80
AnnotationsMethod · 0.80
IntMethod · 0.80
StringMethod · 0.65
UniqueMethod · 0.45

Tested by

no test coverage detected