feat: 新增 AgvPoint 点位表及客户端,支持点位编码与接驳台绑定

This commit is contained in:
SunYF
2026-11-03 10:17:49 +08:00
parent fd2f0e2767
commit 2ccf9bb9ca
62 changed files with 5501 additions and 238 deletions
+12
View File
@@ -8,6 +8,18 @@ import (
"fmt"
)
// The AgvPointFunc type is an adapter to allow the use of ordinary
// function as AgvPoint mutator.
type AgvPointFunc func(context.Context, *ent.AgvPointMutation) (ent.Value, error)
// Mutate calls f(ctx, m).
func (f AgvPointFunc) Mutate(ctx context.Context, m ent.Mutation) (ent.Value, error) {
if mv, ok := m.(*ent.AgvPointMutation); ok {
return f(ctx, mv)
}
return nil, fmt.Errorf("unexpected mutation type %T. expect *ent.AgvPointMutation", m)
}
// The AgvTaskFunc type is an adapter to allow the use of ordinary
// function as AgvTask mutator.
type AgvTaskFunc func(context.Context, *ent.AgvTaskMutation) (ent.Value, error)