DataObjects/Person.php
authorAlan Knowles <alan@akbkhome.com>
Fri, 25 Feb 2011 08:55:44 +0000 (16:55 +0800)
committerAlan Knowles <alan@akbkhome.com>
Fri, 25 Feb 2011 08:55:44 +0000 (16:55 +0800)
DataObjects/Person.php

index 6ef661d..b8d1f76 100644 (file)
@@ -458,8 +458,9 @@ class Pman_Core_DataObjects_Person extends DB_DataObject
                // this is also a flag to return if they are a member..
             DB_DataObject::debugLevel(1);
             $do = DB_DataObject::factory('ProjectDirectory');
-            $this->joinAdd($do,array('joinType' => 'LEFT', 'useWhereAsOn' => true));
             $do->project_id = $q['query']['project_member_of'];
+            
+            $this->joinAdd($do,array('joinType' => 'LEFT', 'useWhereAsOn' => true));
             $this->selectAdd('IF(ProjectDirectory.id IS NULL, 0,  ProjectDirectory.id )  as is_member');