38 lines
1.1 KiB
Go
38 lines
1.1 KiB
Go
// ==========================================================================
|
||
// GFast自动生成service操作代码。
|
||
// 生成日期:2025-08-11 10:15:42
|
||
// 生成路径: internal/app/businesses/service/prevention.go
|
||
// 生成人:gfast
|
||
// desc:防控措施
|
||
// company:云南奇讯科技有限公司
|
||
// ==========================================================================
|
||
|
||
package service
|
||
|
||
import (
|
||
"context"
|
||
|
||
"github.com/tiger1103/gfast/v3/internal/app/businesses/model"
|
||
)
|
||
|
||
type IPrevention interface {
|
||
List(ctx context.Context, req *model.PreventionSearchReq) (res *model.PreventionSearchRes, err error)
|
||
GetById(ctx context.Context, Id int) (res *model.PreventionInfoRes, err error)
|
||
Add(ctx context.Context, req *model.PreventionAddReq) (err error)
|
||
Edit(ctx context.Context, req *model.PreventionEditReq) (err error)
|
||
Delete(ctx context.Context, Id []int) (err error)
|
||
}
|
||
|
||
var localPrevention IPrevention
|
||
|
||
func Prevention() IPrevention {
|
||
if localPrevention == nil {
|
||
panic("implement not found for interface IPrevention, forgot register?")
|
||
}
|
||
return localPrevention
|
||
}
|
||
|
||
func RegisterPrevention(i IPrevention) {
|
||
localPrevention = i
|
||
}
|