DataObjects/Office.php
authorChris <chris@roojs.com>
Tue, 8 Jan 2013 08:52:06 +0000 (16:52 +0800)
committerChris <chris@roojs.com>
Tue, 8 Jan 2013 08:52:06 +0000 (16:52 +0800)
DataObjects/Office.php

index c9575c7..f50c578 100644 (file)
@@ -32,6 +32,7 @@ class Pman_Core_DataObjects_Office extends DB_DataObject
         //$this->selectAdd(" i18n_translate('c' , 'CN', 'en') as country_name");
         $p = DB_DataObject::factory('Person');
         $p->whereAdd("Person.office_id > 0");
+        $p->selectAdd();
         $p->selectAdd("DISTINECT(office_id) as office_id");
         $officeIds = $p->fetchAll('office_id');
         $this->whereAddIn('id', $officeIds, 'INT');