2
0
mirror of https://github.com/ACSPRI/queXS synced 2024-04-02 12:12:16 +00:00

Count self completes towards quotas

This commit is contained in:
Adam Zammit
2019-05-13 14:41:20 +10:00
parent d1c76edea0
commit 972d23b750
2 changed files with 13 additions and 13 deletions

View File

@@ -1825,7 +1825,7 @@ function update_single_row_quota($qsqri,$case_id = false)
}
$sql2 .= " WHERE c.questionnaire_id = '$questionnaire_id'
AND c.current_outcome_id = 10"; //check completions by outcome
AND c.current_outcome_id in (10,40)"; //check completions by outcome
$completions = $db->GetOne($sql2);
}
@@ -2253,7 +2253,7 @@ function end_case($operator_id)
$lastcall = $a['call_id'];
//if the outcome is complete, then update the quota's for this questionnaire (if any)
if ($outcome == 10)
if ($outcome == 10 || $outcome == 40)
update_quotas($questionnaire_id,$case_id);
}