* @version SVN: $Id: Builder.php 7490 2010-03-29 19:53:27Z jwage $ */ abstract class BaseJobStylePrice extends sfDoctrineRecord { public function setTableDefinition() { $this->setTableName('job_style_price'); $this->hasColumn('country_id', 'integer', null, array( 'type' => 'integer', 'notnull' => true, )); $this->hasColumn('style_id', 'integer', null, array( 'type' => 'integer', 'notnull' => true, )); $this->hasColumn('currency', 'char', 3, array( 'type' => 'char', 'notnull' => false, 'length' => 3, )); $this->hasColumn('row_price', 'float', null, array( 'type' => 'float', 'notnull' => true, 'default' => 0, )); $this->option('collate', 'utf8_czech_ci'); $this->option('charset', 'utf8'); } public function setUp() { parent::setUp(); $this->hasOne('Country', array( 'local' => 'country_id', 'foreign' => 'id', 'onDelete' => 'CASCADE')); $this->hasOne('JobStyle', array( 'local' => 'style_id', 'foreign' => 'id', 'onDelete' => 'CASCADE')); } }