This commit is contained in:
parent
d4e3567ab9
commit
bea3d56374
@ -14,16 +14,17 @@ class Taggable extends Doctrine_Template
|
||||
{
|
||||
public function setUp()
|
||||
{
|
||||
$this->hasMany('[Component]Tag as Tag');
|
||||
$this->hasMany('[Component]TagTemplate as Tag');
|
||||
}
|
||||
}
|
||||
class TagTemplate extends Doctrine_Template
|
||||
class TagTemplate extends Doctrine_Record
|
||||
{
|
||||
public function setTableDefinition()
|
||||
{
|
||||
$this->hasColumn('name', 'string', 100);
|
||||
$this->hasColumn('description', 'string');
|
||||
}
|
||||
|
||||
public function setUp()
|
||||
{
|
||||
$this->hasOne('[Component]', array('onDelete' => 'CASCADE'));
|
||||
|
@ -1,10 +1,13 @@
|
||||
<?php
|
||||
class BlogTag extends Doctrine_Record
|
||||
{
|
||||
public function setUp() {
|
||||
$this->hasMany('Photo', 'Phototag.photo_id');
|
||||
}
|
||||
public function setTableDefinition() {
|
||||
$this->hasColumn('tag', 'string', 100);
|
||||
}
|
||||
public function setTableDefinition()
|
||||
{
|
||||
$this->hasColumn('name', 'string', 100);
|
||||
$this->hasColumn('description', 'string');
|
||||
}
|
||||
public function setUp()
|
||||
{
|
||||
$this->hasOne('Blog', array('onDelete' => 'CASCADE'));
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user