I have a quiz which doesn't includes pass/fail status (pass rate set to 0) however in the statistics tab i could see pie chart showing 100% pass , 0% incomplete and 0% fail. For instance see the snapshot http://imm.io/media/1j/1jv0.png

Pass/fail status chart should not be displayed when the pass rate set to 0.

Comments

sivaji_ganesh_jojodae’s picture

Fix.

function _get_quiz_status_chart($vid, $uid = 0) {
  // get the pass rate of the given quiz by vid
  $pass_rate = db_result(db_query("SELECT pass_rate FROM {quiz_node_properties} WHERE vid = %d", intval($vid)));
  if (!$pass_rate) {
    return ;
  }
falcon’s picture

Status: Active » Closed (fixed)

Thanks! (Why didn't you commit this yourself?)

sivaji_ganesh_jojodae’s picture

Sure. I want to keep you informed before committing any changes.