From 88fe60e38f1fd0c9d445682a6b4930db89b90f7f Mon Sep 17 00:00:00 2001 From: Adam Zammit Date: Fri, 20 Nov 2015 14:12:25 +1100 Subject: [PATCH] Fixes lp:1510369 When survey completed as "Self completed online", quotas based on either sample or data inputs, are not counted as completed Dev: Were not being reported as completed in the quota report but added as completions for calculating the quota Dev: Will need to be running the system sort process to make sure the quotas are updated when using a self complete sample --- admin/quotareport.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/admin/quotareport.php b/admin/quotareport.php index f1068f5b..63b45214 100644 --- a/admin/quotareport.php +++ b/admin/quotareport.php @@ -295,7 +295,7 @@ if ($questionnaire_id) $sql = "SELECT count(*) as count FROM `case` as c, sample as s - WHERE c.current_outcome_id = 10 + WHERE c.current_outcome_id IN (10,40) AND s.import_id = '$sample_import_id' AND s.sample_id = c.sample_id AND c.questionnaire_id = '$questionnaire_id'";