fix: some api bug

This commit is contained in:
wwweww
2026-03-31 22:12:06 +08:00
parent c5ff4f0216
commit e7970ac25f
219 changed files with 16195 additions and 2126 deletions
@@ -0,0 +1,31 @@
package schema
import (
"time"
"entgo.io/ent"
"entgo.io/ent/schema/field"
)
// UserPreferences holds the schema definition for the UserPreferences entity.
type UserPreferences struct {
ent.Schema
}
// Fields of the UserPreferences.
func (UserPreferences) Fields() []ent.Field {
return []ent.Field{
field.Int64("user_id"),
field.Bool("notification_order").Default(true),
field.Bool("notification_community").Default(true),
field.Bool("notification_system").Default(true),
field.String("theme").Default("light"),
field.String("language").Default("zh-CN"),
field.Time("updated_at").Default(time.Now),
}
}
// Edges of the UserPreferences.
func (UserPreferences) Edges() []ent.Edge {
return nil
}