public function getProvincia(PropelPDO $con = null) { if ($this->aProvincia === null && $this->fk_provincia_id !== null) { $c = new Criteria(ProvinciaPeer::DATABASE_NAME); $c->add(ProvinciaPeer::ID, $this->fk_provincia_id); $this->aProvincia = ProvinciaPeer::doSelectOne($c, $con); } return $this->aProvincia; }
/** * Get the associated Provincia object * * @param PropelPDO Optional Connection object. * @return Provincia The associated Provincia object. * @throws PropelException */ public function getProvincia(PropelPDO $con = null) { if ($this->aProvincia === null && $this->id_provincia !== null) { $c = new Criteria(ProvinciaPeer::DATABASE_NAME); $c->add(ProvinciaPeer::ID_PROVINCIA, $this->id_provincia); $this->aProvincia = ProvinciaPeer::doSelectOne($c, $con); /* The following can be used additionally to guarantee the related object contains a reference to this object. This level of coupling may, however, be undesirable since it could result in an only partially populated collection in the referenced object. $this->aProvincia->addUsuarios($this); */ } return $this->aProvincia; }
?> <br /> <input id="cp_pais0" type="text" name="cp_0" size="5" maxlength="5" class="cp text required" value="<?php echo $notificacion->dec_cp; ?> " /> </div> <div id="provincia_pais0_div" class="fcell"><?php echo __('Provincia'); ?> <br /><?php if (isset($solicitud) && $solicitud) { if ($notificacion->dec_provincia != '') { $c = new Criteria(); $c->add(ProvinciaPeer::ID_PROVINCIA, $notificacion->dec_provincia); $provincia = ProvinciaPeer::doSelectOne($c); echo input_tag('provincia', $provincia->getNombre()); } else { echo input_tag('provincia', ''); } } else { ?> <select id="provincia_pais0" name="provincia_0" class="prov list required"><?php include_partial('options_provincias', array('id_provincia' => $notificacion->dec_provincia)); ?> </select><?php } ?> </div> <div id="pais0_div" class="fcell"><?php echo __('País');