adjust softdelete daily checklist; add empty kandang

This commit is contained in:
giovanni
2026-04-22 16:24:31 +07:00
parent 2a141a96d1
commit 91d51bf1b8
8 changed files with 287 additions and 63 deletions
@@ -40,7 +40,8 @@ func (r *DailyChecklistRepositoryImpl) ListScopedChecklistIDs(c *fiber.Ctx, ids
Joins("JOIN kandang_groups k ON k.id = dc.kandang_id").
Joins("JOIN locations loc ON loc.id = k.location_id").
Joins("JOIN areas a ON a.id = loc.area_id").
Where("dc.id IN ?", ids)
Where("dc.id IN ?", ids).
Where("dc.deleted_at IS NULL")
db, err := m.ApplyLocationAreaScope(c, db, "loc.id", "a.id")
if err != nil {