0
을 수 없습니다주석이 "@Gedmo 슬러그가 존재하지 않는, 또는 자동로드 모든 것이 잘 작동하지만 프로젝트 번째 배포 한 후 나는이 오류를 얻을 로컬 호스트에서
[Semantical Error] The annotation "@Gedmo\Mapping\Annotation\slug" in property
AppBundle\Entity\Product::$slug does not exist, or could not be auto-loaded.
이 클래스 제품입니다
use Gedmo\Mapping\Annotation as Gedmo;
다음로 사용 : 당신이 주석에 대한 별명을 정의하기 때문이다
use Gedmo\Mapping\Annotation as Gedmo;
abstract class Prodcut
{
/**
* @var int
*
* @ORM\Column(name="id", type="integer")
* @ORM\Id
* @ORM\GeneratedValue(strategy="AUTO")
*/
protected $id;
/**
* @var string
*
* @ORM\Column(name="name", type="string", length=255)
*/
private $name;
/**
* @var string
* @Gedmo\slug(fields={"name"})
* @ORM\Column(name="slug", type="string", length=255, unique=true)
*/
private $slug;