Ver Mensaje Individual
  #6 (permalink)  
Antiguo 28/06/2013, 16:12
mauro89x
 
Fecha de Ingreso: junio-2013
Mensajes: 14
Antigüedad: 10 años, 10 meses
Puntos: 0
Respuesta: Problema con sobrecarga del profileFormType en FOSUserBundle Symfony2

Buenas! sisi, ahi te paso mi entidad usuario

<?php

namespace P2012\SistemaCvBundle\Entity;

use FOS\UserBundle\Model\User as BaseUser;
use Doctrine\ORM\Mapping as ORM;

/**
* @ORM\Entity
* @ORM\Table(name="fos_user")
*/

class Usuario extends BaseUser
{
/**
* @ORM\Id
* @ORM\Column(type="integer")
* @ORM\GeneratedValue(strategy="AUTO")
*/
protected $id;

/**
* @var string
*
* @ORM\Column(name="nombre", type="string",length=255, nullable=true)
*/
protected $nombre;

/**
* @var string
*
* @ORM\Column(name="telefono", type="string", length=255, nullable=true)
*/
protected $telefono;

/**
* @var boolean
*
* @ORM\Column(name="cvpublico", type="boolean", nullable=true)
*/
protected $cvpublico;


public function getId()
{
return $this->id;
}
public function getNombre()
{
return $this->nombre;
}
public function getTelefono()
{
return $this->telefono;
}
public function getCvPublico()
{
return $this->cvpublico;
}
public function setNombre($nom)
{
$this->nombre = $nom;
}
public function setTelefono($tel)
{
$this->telefono = $tel;
}
public function setCvPublico($bool)
{
$this->cvpublico = $bool;
}
public function _construct()
{
parent::_construct();
}

}
Los campos están bien definidos. Sobrecargue el ProfileFormType y me agrega los campos pero vacíos, solamente me completa el del username e email (osea los definidos en FOSUserBundle). los que agrego yo no me los llena
El link que me pasaste lo hice paso a paso pero sigue sin completarme los campos.
gracias por tu tiempo masterpuppet saludos !