Versions in this module Expand all Collapse all v1 v1.0.0 Jan 24, 2023 Changes in this version + var File_crud_crud_proto protoreflect.FileDescriptor + func LookupCrudModelColumn(field string) string + func LookupCrudModelColumns(paths []string) (cols []string) + type Crud struct + BoolField bool + Int32Field int32 + StringField string + Uuid string + func (*Crud) Descriptor() ([]byte, []int) + func (*Crud) ProtoMessage() + func (x *Crud) AsModel() (*CrudModel, error) + func (x *Crud) GetBoolField() bool + func (x *Crud) GetInt32Field() int32 + func (x *Crud) GetStringField() string + func (x *Crud) GetUuid() string + func (x *Crud) ProtoReflect() protoreflect.Message + func (x *Crud) Reset() + func (x *Crud) String() string + func (x *Crud) WithDB(db *gorm.DB) CrudWithDB + type CrudGetOption func(tx *gorm.DB) *gorm.DB + func WithCrudGetFieldMask(mask *fieldmaskpb.FieldMask) CrudGetOption + type CrudListOption func(tx *gorm.DB) *gorm.DB + func WithCrudListFieldMask(mask *fieldmaskpb.FieldMask) CrudListOption + func WithCrudListFilter(filter string) CrudListOption + func WithCrudListLimit(n int) CrudListOption + func WithCrudListOffset(n int) CrudListOption + func WithCrudListOrder(order string) CrudListOption + type CrudModel struct + BoolField bool + Int32Field int32 + StringField string + Uuid string + func (m *CrudModel) AsProto() (*Crud, error) + type CrudWithDB struct + func (c CrudWithDB) Create(ctx context.Context) (*Crud, error) + func (c CrudWithDB) Delete(ctx context.Context) error + func (c CrudWithDB) Get(ctx context.Context, opts ...CrudGetOption) (*Crud, error) + func (c CrudWithDB) List(ctx context.Context, opts ...CrudListOption) ([]*Crud, error) + func (c CrudWithDB) Patch(ctx context.Context, mask *fieldmaskpb.FieldMask) error + func (c CrudWithDB) Update(ctx context.Context) (*Crud, error)