switched to using state repo & separate package repos

This commit is contained in:
2023-05-20 17:31:14 +02:00
parent 786b70b842
commit e079526d4c
25 changed files with 1534 additions and 2378 deletions

View File

@@ -9,16 +9,16 @@ import (
"somegit.dev/ALHP/ALHP.GO/ent"
)
// The DbPackageFunc type is an adapter to allow the use of ordinary
// function as DbPackage mutator.
type DbPackageFunc func(context.Context, *ent.DbPackageMutation) (ent.Value, error)
// The DBPackageFunc type is an adapter to allow the use of ordinary
// function as DBPackage mutator.
type DBPackageFunc func(context.Context, *ent.DBPackageMutation) (ent.Value, error)
// Mutate calls f(ctx, m).
func (f DbPackageFunc) Mutate(ctx context.Context, m ent.Mutation) (ent.Value, error) {
if mv, ok := m.(*ent.DbPackageMutation); ok {
func (f DBPackageFunc) Mutate(ctx context.Context, m ent.Mutation) (ent.Value, error) {
if mv, ok := m.(*ent.DBPackageMutation); ok {
return f(ctx, mv)
}
return nil, fmt.Errorf("unexpected mutation type %T. expect *ent.DbPackageMutation", m)
return nil, fmt.Errorf("unexpected mutation type %T. expect *ent.DBPackageMutation", m)
}
// Condition is a hook condition function.