feat: news router

This commit is contained in:
ericprd
2025-03-02 04:36:17 +08:00
parent f4ae93bc48
commit 915f12eaf7
49 changed files with 863 additions and 132 deletions
+2 -1
View File
@@ -3,5 +3,6 @@ package tagsvc
import tagdomain "legalgo-BE-go/internal/domain/tag"
func (i *impl) Create(spec tagdomain.TagReq) error {
return i.tagRepo.Create(spec)
// return i.tagRepo.Create(spec)
return i.tagRepo.CreateModel(spec)
}
+9
View File
@@ -0,0 +1,9 @@
package tagsvc
import (
"legalgo-BE-go/database"
)
func (i *impl) GetAllModel() ([]database.TagModel, error) {
return i.tagRepo.GetAllModel()
}
+2
View File
@@ -1,6 +1,7 @@
package tagsvc
import (
"legalgo-BE-go/database"
tagrepository "legalgo-BE-go/internal/accessor/tag"
tagdomain "legalgo-BE-go/internal/domain/tag"
)
@@ -12,6 +13,7 @@ type impl struct {
type TagIntf interface {
Create(tagdomain.TagReq) error
GetAll() ([]tagdomain.Tag, error)
GetAllModel() ([]database.TagModel, error)
}
func New(