sqlx
This commit is contained in:
@@ -29,5 +29,15 @@ func (b *auditLogService) BatchCreate(ctx context.Context, objs []*system.AuditL
|
||||
}
|
||||
|
||||
func (b *auditLogService) List(ctx context.Context, q dto.SearchDto) ([]*system.AuditLog, int64, error) {
|
||||
return b.repo.List(ctx, q)
|
||||
count, err := b.repo.Count(ctx, q)
|
||||
if err != nil {
|
||||
return nil, 0, err
|
||||
}
|
||||
|
||||
res, err := b.repo.List(ctx, q)
|
||||
if err != nil {
|
||||
return nil, 0, err
|
||||
}
|
||||
|
||||
return res, count, nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user