basic setup
This commit is contained in:
34
app/service/orderService/orderService.go
Normal file
34
app/service/orderService/orderService.go
Normal file
@@ -0,0 +1,34 @@
|
||||
package orderService
|
||||
|
||||
import (
|
||||
"git.ma-al.com/goc_daniel/b2b/app/model"
|
||||
"git.ma-al.com/goc_daniel/b2b/app/repos/ordersRepo"
|
||||
"git.ma-al.com/goc_daniel/b2b/app/utils/query/filters"
|
||||
"git.ma-al.com/goc_daniel/b2b/app/utils/query/find"
|
||||
)
|
||||
|
||||
type OrderService struct {
|
||||
ordersRepo ordersRepo.UIOrdersRepo
|
||||
}
|
||||
|
||||
func New() *OrderService {
|
||||
return &OrderService{
|
||||
ordersRepo: ordersRepo.New(),
|
||||
}
|
||||
}
|
||||
|
||||
func (s *OrderService) Find(user *model.Customer, p find.Paging, filt *filters.FiltersList) (find.Found[model.CustomerOrder], error) {
|
||||
return s.ordersRepo.Find(user.ID, p, filt)
|
||||
}
|
||||
|
||||
func (s *OrderService) PlaceNewOrder(user_id uint, cart_id uint, country_id uint, address_info string) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (s *OrderService) ChangeOrderAddress(user *model.Customer, order_id uint, country_id uint, address_info string) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (s *OrderService) ChangeOrderStatus(user *model.Customer, order_id uint, status string) error {
|
||||
return nil
|
||||
}
|
||||
Reference in New Issue
Block a user