mirror of
https://gitlab.com/mbugroup/lti-api.git
synced 2026-05-20 13:31:56 +00:00
add filter by kandang id sapronak
This commit is contained in:
@@ -59,7 +59,6 @@ func (r *productionResultRepositoryImpl) GetRecordingsByProjectFlockKandang(
|
||||
dataQuery := r.db.WithContext(ctx).
|
||||
Model(&entity.Recording{}).
|
||||
Where("project_flock_kandangs_id = ?", projectFlockKandangID).
|
||||
Preload("BodyWeights").
|
||||
Preload("Eggs", func(db *gorm.DB) *gorm.DB {
|
||||
return db.Select("recording_eggs.*, f.name AS product_flag_name").
|
||||
Joins("LEFT JOIN product_warehouses pw ON pw.id = recording_eggs.product_warehouse_id").
|
||||
|
||||
Reference in New Issue
Block a user