mirror of
https://gitlab.com/mbugroup/lti-api.git
synced 2026-05-20 13:31:56 +00:00
feat(BE-74-76-78-278):adjustment project flock,recording,purchase getall
This commit is contained in:
@@ -133,6 +133,7 @@ func (s *purchaseService) GetAll(c *fiber.Ctx, params *validation.Query) ([]enti
|
||||
|
||||
purchases, total, err := s.PurchaseRepo.GetAll(c.Context(), offset, params.Limit, func(db *gorm.DB) *gorm.DB {
|
||||
db = s.withRelations(db)
|
||||
db = db.Where("purchases.deleted_at IS NULL")
|
||||
|
||||
if params.SupplierID > 0 {
|
||||
db = db.Where("supplier_id = ?", params.SupplierID)
|
||||
|
||||
Reference in New Issue
Block a user