Fixed issue 168, code review shows wrong commits.

This commit is contained in:
Ciaran Gultnieks 2009-03-26 12:28:03 +01:00 committed by Loic d'Anterroches
parent dd2dda1895
commit c16962e5f5

View File

@ -59,8 +59,10 @@ class IDF_Form_ReviewCreate extends Pluf_Form
'rows' => 7, 'rows' => 7,
), ),
)); ));
$sql = new Pluf_SQL('project=%s', array($this->project->id));
$commits = Pluf::factory('IDF_Commit')->getList(array('order' => 'creation_dtime DESC', $commits = Pluf::factory('IDF_Commit')->getList(array('order' => 'creation_dtime DESC',
'nb' => 10)); 'nb' => 10,
'filter' => $sql->gen()));
$choices = array(); $choices = array();
foreach ($commits as $c) { foreach ($commits as $c) {
$id = (strlen($c->scm_id) > 10) ? substr($c->scm_id, 0, 10) : $c->scm_id; $id = (strlen($c->scm_id) > 10) ? substr($c->scm_id, 0, 10) : $c->scm_id;