예제 #1
0
파일: Division.php 프로젝트: mediasadc/alba
 public function toArrayInforme($keyType = BasePeer::TYPE_PHPNAME)
 {
     $keys = DivisionPeer::getFieldNames($keyType);
     $result = array($keys[0] => $this->getId(), 'Año' => $this->getAnio() ? $this->getAnio()->getDescripcion() : '', $keys[2] => $this->getDescripcion(), 'Turno' => $this->getTurno() ? $this->getTurno()->getDescripcion() : '', 'Orientacion' => $this->getOrientacion() ? $this->getOrientacion()->getDescripcion() : '', $keys[5] => $this->getOrden());
     return $result;
 }
예제 #2
0
 public function fromArray($arr, $keyType = BasePeer::TYPE_PHPNAME)
 {
     $keys = DivisionPeer::getFieldNames($keyType);
     if (array_key_exists($keys[0], $arr)) {
         $this->setId($arr[$keys[0]]);
     }
     if (array_key_exists($keys[1], $arr)) {
         $this->setFkAnioId($arr[$keys[1]]);
     }
     if (array_key_exists($keys[2], $arr)) {
         $this->setDescripcion($arr[$keys[2]]);
     }
     if (array_key_exists($keys[3], $arr)) {
         $this->setFkTurnoId($arr[$keys[3]]);
     }
     if (array_key_exists($keys[4], $arr)) {
         $this->setFkOrientacionId($arr[$keys[4]]);
     }
     if (array_key_exists($keys[5], $arr)) {
         $this->setOrden($arr[$keys[5]]);
     }
 }