1
0
mirror of synced 2024-12-14 23:26:04 +03:00
doctrine2/tests/Doctrine/Tests/Models/Company/CompanyEvent.php

36 lines
864 B
PHP
Raw Normal View History

2009-09-15 16:24:38 +04:00
<?php
namespace Doctrine\Tests\Models\Company;
/**
* @Entity @Table(name="company_events")
* @InheritanceType("JOINED")
* @DiscriminatorColumn(name="event_type", type="string")
* @DiscriminatorMap({"auction" = "CompanyAuction", "raffle" = "CompanyRaffle"})
*/
class CompanyEvent {
/**
* @Id @Column(type="integer")
2010-04-10 02:00:36 +04:00
* @GeneratedValue
2009-09-15 16:24:38 +04:00
*/
private $id;
/**
2010-04-10 02:00:36 +04:00
* @ManyToOne(targetEntity="CompanyOrganization", inversedBy="events", cascade={"persist"})
2009-09-15 16:24:38 +04:00
* @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;
}
2009-09-15 16:24:38 +04:00
}