refactor survery cmd
move package files to pkg
This commit is contained in:
17
pkg/task/types.go
Normal file
17
pkg/task/types.go
Normal file
@@ -0,0 +1,17 @@
|
||||
package task
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
"github.com/LazyBachelor/LazyPM/internal/service"
|
||||
)
|
||||
|
||||
type TaskConfig = service.Config
|
||||
|
||||
type Interface interface {
|
||||
Run(context.Context, TaskConfig) error
|
||||
}
|
||||
|
||||
type ConfigFunc func() TaskConfig
|
||||
type ValidateFunc func(context.Context, *service.Services) (ok bool, err error)
|
||||
type DbStateFunc func(context.Context, *service.Services) error
|
||||
Reference in New Issue
Block a user