private function MapRelationshipToJoinRow($Relationship) { if ($this->RelatesToTableTwo) { return $this->JoinTable->JoinRow($Relationship->GetParentPrimaryKey(), $Relationship->GetRelatedPrimaryKey()); } else { return $this->JoinTable->JoinRow($Relationship->GetRelatedPrimaryKey(), $Relationship->GetParentPrimaryKey()); } }
public function __construct($Name, Relational\ITable $Table1, Relational\ITable $Table2) { $this->Name = $Name; $this->Table1 = $Table1; $this->Table2 = $Table2; $this->AddColumns($Table1, $this->ForeignKey1Map); $this->AddColumns($Table2, $this->ForeignKey2Map); parent::__construct(); }
protected function OnInitializeStructure(Relational\Database $Context) { $this->CreateTableStructure($Context->GetPlatform()->GetColumnSet()); parent::OnInitializeStructure($Context); }