DDC-1111: EntityGenerator duplicates attributes, getters and setters in mapped subclasses #1709

Closed
doctrinebot opened this Issue Apr 12, 2011 · 2 comments

2 participants

@doctrinebot

Jira issue originally created by user stoefln:

when I want to generate getters and setters for my entity which subclasses another entity-base-class, my properties are duplicated.

before generating:

/****
 * @orm:Entity
 */
class User extends BaseUser
{
    /****
     * @orm:Id
     * @orm:Column(type="integer")
     * @orm:generatedValue(strategy="AUTO")
     */
    protected $id;
}

after generating:

/****
 * @orm:Entity
 */
class User extends BaseUser
{
    /****
     * @orm:Id
     * @orm:Column(type="integer")
     * @orm:generatedValue(strategy="AUTO")
     */
    protected $id;


    /****
     * @var integer $id
     */
    private $id;


    /****
     * Get id
     *
     * @return integer $id
     */
    public function getId()
    {
        return $this->id;
    }
}

SuperSuperClass (there are multiple levels of inheritance...):

abstract class User implements UserInterface
{
    protected $id;
   //...
}
@doctrinebot

Comment created by @beberlei:

Duplicate of DDC-1134, fixed

@doctrinebot

Issue was closed with resolution "Duplicate"

@beberlei beberlei was assigned by doctrinebot Dec 6, 2015
@doctrinebot doctrinebot added this to the 2.0.5 milestone Dec 6, 2015
@doctrinebot doctrinebot closed this Dec 6, 2015
@doctrinebot doctrinebot added the Bug label Dec 7, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment