mirror of
https://github.com/hay-kot/homebox.git
synced 2025-06-28 06:38:36 +00:00
feat: add scheduled maintenance tasks (#320)
* add scheduled maintenance tasks * fix failing typecheck
This commit is contained in:
parent
70297b9d27
commit
025521431e
25 changed files with 521 additions and 121 deletions
|
@ -1,8 +1,6 @@
|
|||
package schema
|
||||
|
||||
import (
|
||||
"time"
|
||||
|
||||
"entgo.io/ent"
|
||||
"entgo.io/ent/schema/edge"
|
||||
"entgo.io/ent/schema/field"
|
||||
|
@ -24,7 +22,9 @@ func (MaintenanceEntry) Fields() []ent.Field {
|
|||
return []ent.Field{
|
||||
field.UUID("item_id", uuid.UUID{}),
|
||||
field.Time("date").
|
||||
Default(time.Now),
|
||||
Optional(),
|
||||
field.Time("scheduled_date").
|
||||
Optional(),
|
||||
field.String("name").
|
||||
MaxLen(255).
|
||||
NotEmpty(),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue