setTableName('attach'); $this->hasColumn('estate_id', 'integer', null, array( 'type' => 'integer', 'notnull' => true, )); $this->hasColumn('name', 'string', 255, array( 'type' => 'string', 'notnull' => true, 'length' => 255, )); $this->hasColumn('type', 'string', 255, array( 'type' => 'string', 'notnull' => true, 'length' => 255, )); $this->hasColumn('filename', 'string', 255, array( 'type' => 'string', 'notnull' => true, 'length' => 255, )); $this->option('collate', 'utf8_czech_ci'); $this->option('charset', 'utf8'); } public function setUp() { parent::setUp(); $this->hasOne('Estate', array( 'local' => 'estate_id', 'foreign' => 'id', 'onDelete' => 'CASCADE')); $timestampable0 = new Doctrine_Template_Timestampable(); $this->actAs($timestampable0); } }