add status to expense

This commit is contained in:
2026-05-29 15:44:59 +07:00
parent 1b7bec4f81
commit d26f5c5354
13 changed files with 65 additions and 0 deletions
@@ -84,6 +84,10 @@ func (r *ExpenseRepositoryImpl) List(ctx context.Context, organizationID uuid.UU
if outletID, ok := value.(uuid.UUID); ok {
query = query.Where("outlet_id = ?", outletID)
}
case "status":
if status, ok := value.(string); ok && status != "" {
query = query.Where("status = ?", status)
}
case "start_date":
if startDate, ok := value.(time.Time); ok {
query = query.Where("transaction_date >= ?", startDate)