Files
validator/OmCTF-2025/services/block_game/backend/schema/setting.go

28 lines
430 B
Go

package schema
import (
"entgo.io/ent"
"entgo.io/ent/schema/field"
)
// Setting holds the schema definition for the Setting entity.
type Setting struct {
ent.Schema
}
// Fields of the Setting.
func (Setting) Fields() []ent.Field {
return []ent.Field{
field.String("key").
Unique().
NotEmpty(),
field.String("value").
NotEmpty(),
}
}
// Edges of the Setting.
func (Setting) Edges() []ent.Edge {
return nil
}