Skip to content

Commit d159d4d

Browse files
committed
feat: add query dependency to AppService
The query dependency was added to the AppService to enable database query operations through the query.Use() function, allowing the service to interact with the database more effectively.
1 parent 6247060 commit d159d4d

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

  • backend/internal/services

backend/internal/services/fx.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import (
66
"go.uber.org/fx"
77

88
"github.com/fdddf/opentrans/internal/auth"
9+
"github.com/fdddf/opentrans/internal/dao/query"
910
"github.com/fdddf/opentrans/internal/database"
1011
)
1112

@@ -70,6 +71,7 @@ type QueueServiceDeps struct {
7071
func NewAppService(deps AppServiceDeps) *AppService {
7172
return &AppService{
7273
DB: deps.DB,
74+
Query: query.Use(deps.DB.DB),
7375
AppLocalizationService: deps.AppLocalizationService,
7476
}
7577
}

0 commit comments

Comments
 (0)