Skip to content

Commit 356e1a1

Browse files
committed
fix: fix common_dao remove bug
1 parent 259d3bb commit 356e1a1

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

gplus/common_dao.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ import (
2323

2424
type CommonDao[T any] struct{}
2525

26-
func NewCommonDao[T any](pk string) *CommonDao[T] {
26+
func NewCommonDao[T any]() *CommonDao[T] {
2727
return &CommonDao[T]{}
2828
}
2929

@@ -47,7 +47,7 @@ func (service CommonDao[T]) RemoveById(id any) *gorm.DB {
4747
return DeleteById[T](id)
4848
}
4949

50-
func (service CommonDao[T]) RemoveByIds(ids []any) *gorm.DB {
50+
func (service CommonDao[T]) RemoveByIds(ids any) *gorm.DB {
5151
return DeleteByIds[T](ids)
5252
}
5353

@@ -79,7 +79,7 @@ func (service CommonDao[T]) List(q *Query[T]) ([]*T, *gorm.DB) {
7979
return SelectList[T](q)
8080
}
8181

82-
func (service CommonDao[T]) ListByIds(ids []any) ([]*T, *gorm.DB) {
82+
func (service CommonDao[T]) ListByIds(ids any) ([]*T, *gorm.DB) {
8383
return SelectByIds[T](ids)
8484
}
8585

0 commit comments

Comments
 (0)