1
0
mirror of synced 2024-12-13 22:56:04 +03:00
doctrine2/models/Author.php

16 lines
411 B
PHP
Raw Normal View History

<?php
class Author extends Doctrine_Record
{
public function setUp()
{
$this->hasOne('Book', array('local' => 'book_id',
'foreign' => 'id',
'onDelete' => 'CASCADE'));
}
public function setTableDefinition()
{
$this->hasColumn('book_id', 'integer');
$this->hasColumn('name', 'string',20);
}
}