parent/child relation + postgresql array support

Example usage:
class Inventory extends CActiveRecord
{
 public $elasticType =
'inventory';
....
public function getParent() {
  return $this->product_id;
 }