fixed import bugs and filter

This commit is contained in:
Luca Haid
2025-07-17 13:57:20 +02:00
parent fc7bf317aa
commit 246e6551b9
2 changed files with 9 additions and 0 deletions

View File

@@ -428,6 +428,10 @@ class ConstructionConsent extends mfBaseModel {
COUNT(cwo.id) AS total_owners,
CASE
WHEN ConstructionConsent.approve_override = 1 THEN 'green'
WHEN COALESCE(SUM(CASE
WHEN approve_override = 1 THEN 0
ELSE (cwo.result = 'open' AND cwo.status = 'new')
END), 0) > 0 THEN 'blue'
WHEN COALESCE(SUM(CASE
WHEN approve_override = 1 THEN 0
ELSE (cwo.result = 'denied')