From: Tim H. <tj...@us...> - 2010-11-30 15:45:45
|
Update of /cvsroot/stack/stack-dev/lib/database In directory sfp-cvsdas-3.v30.ch3.sourceforge.com:/tmp/cvs-serv12186/lib/database Modified Files: StackDBItem.php MoodleDB.php Log Message: Fix a whole bunch of notices encountered while importing questions. Index: MoodleDB.php =================================================================== RCS file: /cvsroot/stack/stack-dev/lib/database/MoodleDB.php,v retrieving revision 1.17 retrieving revision 1.18 diff -C2 -d -r1.17 -r1.18 *** MoodleDB.php 12 Nov 2010 10:11:06 -0000 1.17 --- MoodleDB.php 30 Nov 2010 15:45:35 -0000 1.18 *************** *** 580,583 **** --- 580,584 ---- $this->query($sql); + $return = array(); $no = $this->noRows(); for($i =0; $i < $no; $i++) Index: StackDBItem.php =================================================================== RCS file: /cvsroot/stack/stack-dev/lib/database/StackDBItem.php,v retrieving revision 1.38 retrieving revision 1.39 diff -C2 -d -r1.38 -r1.39 *** StackDBItem.php 1 Nov 2010 18:18:29 -0000 1.38 --- StackDBItem.php 30 Nov 2010 15:45:35 -0000 1.39 *************** *** 622,626 **** $qList[$i]['published'] = $this->result($i,'published'); $qList[$i]['status'] = $this->result($i,'status'); ! $qList[$i]['nodeployed'] = $deployCount[$qList[$i]['id']];//TOO MANY QUERIES --> $dbc->countInstances($qList[$i]['id']); if(!isset($qList[$i]['nodeployed'])) $qList[$i]['nodeployed'] = 0; $i++; --- 622,630 ---- $qList[$i]['published'] = $this->result($i,'published'); $qList[$i]['status'] = $this->result($i,'status'); ! if (isset($deployCount[$qList[$i]['id']])) { ! $qList[$i]['nodeployed'] = $deployCount[$qList[$i]['id']];//TOO MANY QUERIES --> $dbc->countInstances($qList[$i]['id']); ! } else { ! $qList[$i]['nodeployed'] = 0; ! } if(!isset($qList[$i]['nodeployed'])) $qList[$i]['nodeployed'] = 0; $i++; |