2007-06-27 21:45:05 +04:00
|
|
|
<?php
|
|
|
|
class Blog extends Doctrine_Record
|
|
|
|
{
|
|
|
|
public function setTableDefinition()
|
|
|
|
{
|
|
|
|
|
|
|
|
}
|
|
|
|
public function setUp()
|
|
|
|
{
|
|
|
|
$this->loadTemplate('Taggable');
|
|
|
|
}
|
|
|
|
}
|
|
|
|
class Taggable extends Doctrine_Template
|
|
|
|
{
|
|
|
|
public function setUp()
|
|
|
|
{
|
2007-09-21 02:02:45 +04:00
|
|
|
//$this->hasMany('[Component]TagTemplate as Tag');
|
2007-06-27 21:45:05 +04:00
|
|
|
}
|
|
|
|
}
|
2007-09-21 00:31:49 +04:00
|
|
|
class TagTemplate extends Doctrine_Record
|
2007-06-27 21:45:05 +04:00
|
|
|
{
|
|
|
|
public function setTableDefinition()
|
|
|
|
{
|
|
|
|
$this->hasColumn('name', 'string', 100);
|
|
|
|
$this->hasColumn('description', 'string');
|
|
|
|
}
|
2007-09-21 00:31:49 +04:00
|
|
|
|
2007-06-27 21:45:05 +04:00
|
|
|
public function setUp()
|
|
|
|
{
|
2007-09-21 02:02:45 +04:00
|
|
|
//$this->hasOne('[Component]', array('onDelete' => 'CASCADE'));
|
2007-06-27 21:45:05 +04:00
|
|
|
}
|
|
|
|
}
|