1
0
mirror of synced 2024-12-15 07:36:03 +03:00
doctrine2/models/Song.php

17 lines
463 B
PHP
Raw Normal View History

<?php
class Song extends Doctrine_Record
{
public function setUp()
{
$this->hasOne('Album', array('local' => 'album_id',
'foreign' => 'id',
'onDelete' => 'CASCADE'));
}
public function setTableDefinition()
{
$this->hasColumn('album_id', 'integer');
$this->hasColumn('genre', 'string',20);
$this->hasColumn('title', 'string',30);
}
}