setTableName('cviceni'); $this->hasColumn('id', 'integer', null, array( 'type' => 'integer', 'primary' => true, 'autoincrement' => true, )); $this->hasColumn('admin_id', 'integer', null, array( 'type' => 'integer', )); $this->hasColumn('specifikace_spolecnost', 'string', 255, array( 'type' => 'string', 'length' => '255', )); $this->hasColumn('specifikace_pokrocilost', 'string', 255, array( 'type' => 'string', 'length' => '255', )); $this->hasColumn('specifikace_specializace', 'string', 255, array( 'type' => 'string', 'length' => '255', )); $this->hasColumn('specifikace_gramatika', 'string', 255, array( 'type' => 'string', 'length' => '255', )); $this->hasColumn('specifikace_fraze', 'string', 255, array( 'type' => 'string', 'length' => '255', )); $this->hasColumn('typ', 'integer', 1, array( 'type' => 'integer', 'length' => '1', )); $this->hasColumn('nazev', 'string', 255, array( 'type' => 'string', 'notnull' => true, 'unique' => true, 'length' => '255', )); $this->hasColumn('zadani', 'clob', null, array( 'type' => 'clob', )); $this->option('type', 'InnoDB'); $this->option('collate', 'utf8_unicode_ci'); $this->option('charset', 'utf8'); } public function setUp() { parent::setUp(); $this->hasOne('Admin', array( 'local' => 'admin_id', 'foreign' => 'id')); $this->hasMany('Test_cviceni as Testy', array( 'local' => 'id', 'foreign' => 'cviceni_id')); $this->hasMany('Otazky', array( 'local' => 'id', 'foreign' => 'cviceni_id')); $this->hasMany('Uchazec_text', array( 'local' => 'id', 'foreign' => 'cviceni_id')); $timestampable0 = new Doctrine_Template_Timestampable(); $softdelete0 = new Doctrine_Template_SoftDelete(); $this->actAs($timestampable0); $this->actAs($softdelete0); } }