1
0
mirror of synced 2024-12-14 07:06:04 +03:00
doctrine2/tests/Doctrine/Tests/Models/Company/CompanyEvent.php
Roman S. Borschel 01c2c06bbf [DDC-512] Fixed.
2010-04-15 18:36:17 +02:00

36 lines
869 B
PHP

<?php
namespace Doctrine\Tests\Models\Company;
/**
* @Entity @Table(name="company_events")
* @InheritanceType("JOINED")
* @DiscriminatorColumn(name="event_type", type="string")
* @DiscriminatorMap({"auction"="CompanyAuction", "raffle"="CompanyRaffle"})
*/
abstract class CompanyEvent {
/**
* @Id @Column(type="integer")
* @GeneratedValue
*/
private $id;
/**
* @ManyToOne(targetEntity="CompanyOrganization", inversedBy="events", cascade={"persist"})
* @JoinColumn(name="org_id", referencedColumnName="id")
*/
private $organization;
public function getId() {
return $this->id;
}
public function getOrganization() {
return $this->organization;
}
public function setOrganization(CompanyOrganization $org) {
$this->organization = $org;
}
}