From 3f0d5bf01e0c5b84e23ba1dfe93fc1718d097b1a Mon Sep 17 00:00:00 2001 From: "Jonathan.Wage" Date: Sat, 20 Oct 2007 06:13:13 +0000 Subject: [PATCH] Removed. --- sandbox/data/fixtures/contact.yml | 4 - sandbox/data/fixtures/user.yml | 6 - .../008_add_self_reference.class.php | 57 --------- sandbox/migrations/009_add_user.class.php | 60 ---------- sandbox/migrations/010_add_user_car.class.php | 38 ------ .../migrations/011_add_user_group.class.php | 38 ------ ...12_apply_foreign_key_constraints.class.php | 112 ------------------ 7 files changed, 315 deletions(-) delete mode 100644 sandbox/data/fixtures/contact.yml delete mode 100644 sandbox/data/fixtures/user.yml delete mode 100644 sandbox/migrations/008_add_self_reference.class.php delete mode 100644 sandbox/migrations/009_add_user.class.php delete mode 100644 sandbox/migrations/010_add_user_car.class.php delete mode 100644 sandbox/migrations/011_add_user_group.class.php delete mode 100644 sandbox/migrations/012_apply_foreign_key_constraints.class.php diff --git a/sandbox/data/fixtures/contact.yml b/sandbox/data/fixtures/contact.yml deleted file mode 100644 index 252df3bb4..000000000 --- a/sandbox/data/fixtures/contact.yml +++ /dev/null @@ -1,4 +0,0 @@ ---- -Contact: - Contact_1: - name: Jonathan H. Wage diff --git a/sandbox/data/fixtures/user.yml b/sandbox/data/fixtures/user.yml deleted file mode 100644 index fb1346b85..000000000 --- a/sandbox/data/fixtures/user.yml +++ /dev/null @@ -1,6 +0,0 @@ ---- -User: - User_1: - username: jonwage - hair_color: brown - Contact: Contact_1 diff --git a/sandbox/migrations/008_add_self_reference.class.php b/sandbox/migrations/008_add_self_reference.class.php deleted file mode 100644 index 3b10ad78e..000000000 --- a/sandbox/migrations/008_add_self_reference.class.php +++ /dev/null @@ -1,57 +0,0 @@ -createTable('self_reference', array ( - 'id' => - array ( - 'primary' => true, - 'autoincrement' => true, - 'type' => 'integer', - 'length' => 11, - ), - 'name' => - array ( - 'type' => 'string', - 'length' => 255, - ), - 'user_id1' => - array ( - 'type' => 'integer', - 'length' => 11, - ), - 'user_id2' => - array ( - 'type' => 'integer', - 'length' => 11, - ), - 'parent_self_reference_id' => - array ( - 'type' => 'integer', - 'length' => 11, - ), - 'parent_self_reference_id2' => - array ( - 'type' => 'integer', - 'length' => 11, - ), -), array ( - 'indexes' => - array ( - ), - 'primary' => - array ( - 0 => 'id', - ), -)); - } - - public function down() - { - $this->dropTable('self_reference'); - } -} \ No newline at end of file diff --git a/sandbox/migrations/009_add_user.class.php b/sandbox/migrations/009_add_user.class.php deleted file mode 100644 index 488e4fb08..000000000 --- a/sandbox/migrations/009_add_user.class.php +++ /dev/null @@ -1,60 +0,0 @@ -createTable('user', array ( - 'id' => - array ( - 'primary' => true, - 'autoincrement' => true, - 'type' => 'integer', - 'length' => 11, - ), - 'username' => - array ( - 'type' => 'string', - 'length' => 255, - ), - 'hair_color' => - array ( - 'type' => 'string', - 'length' => 255, - ), - 'contact_id' => - array ( - 'type' => 'integer', - 'length' => 11, - ), -), array ( - 'indexes' => - array ( - 'name_x' => - array ( - 'fields' => - array ( - 'username' => - array ( - 'sorting' => 'ASC', - 'length' => '11', - 'primary' => true, - ), - ), - 'type' => 'unique', - ), - ), - 'primary' => - array ( - 0 => 'id', - ), -)); - } - - public function down() - { - $this->dropTable('user'); - } -} \ No newline at end of file diff --git a/sandbox/migrations/010_add_user_car.class.php b/sandbox/migrations/010_add_user_car.class.php deleted file mode 100644 index aa2acd412..000000000 --- a/sandbox/migrations/010_add_user_car.class.php +++ /dev/null @@ -1,38 +0,0 @@ -createTable('user_car', array ( - 'user_id' => - array ( - 'primary' => true, - 'type' => 'integer', - 'length' => 11, - ), - 'car_id' => - array ( - 'primary' => true, - 'type' => 'integer', - 'length' => 11, - ), -), array ( - 'indexes' => - array ( - ), - 'primary' => - array ( - 0 => 'user_id', - 1 => 'car_id', - ), -)); - } - - public function down() - { - $this->dropTable('user_car'); - } -} \ No newline at end of file diff --git a/sandbox/migrations/011_add_user_group.class.php b/sandbox/migrations/011_add_user_group.class.php deleted file mode 100644 index 8777a5e27..000000000 --- a/sandbox/migrations/011_add_user_group.class.php +++ /dev/null @@ -1,38 +0,0 @@ -createTable('user_group', array ( - 'user_id' => - array ( - 'primary' => true, - 'type' => 'integer', - 'length' => 11, - ), - 'group_id' => - array ( - 'primary' => true, - 'type' => 'integer', - 'length' => 11, - ), -), array ( - 'indexes' => - array ( - ), - 'primary' => - array ( - 0 => 'user_id', - 1 => 'group_id', - ), -)); - } - - public function down() - { - $this->dropTable('user_group'); - } -} \ No newline at end of file diff --git a/sandbox/migrations/012_apply_foreign_key_constraints.class.php b/sandbox/migrations/012_apply_foreign_key_constraints.class.php deleted file mode 100644 index d5b64196a..000000000 --- a/sandbox/migrations/012_apply_foreign_key_constraints.class.php +++ /dev/null @@ -1,112 +0,0 @@ -createForeignKey('adult', array ( - 'local' => 'contact_id', - 'foreign' => 'id', - 'foreignTable' => 'contact', - 'onUpdate' => NULL, - 'onDelete' => NULL, - 'name' => 'adult_contact_contact_id_id', -)); $this->createForeignKey('child', array ( - 'local' => 'adult_id', - 'foreign' => 'id', - 'foreignTable' => 'adult', - 'onUpdate' => NULL, - 'onDelete' => NULL, - 'name' => 'child_adult_adult_id_id', -)); $this->createForeignKey('dog', array ( - 'local' => 'user_id', - 'foreign' => 'id', - 'foreignTable' => 'user', - 'onUpdate' => NULL, - 'onDelete' => NULL, - 'name' => 'dog_user_user_id_id', -)); $this->createForeignKey('self_reference', array ( - 'local' => 'user_id1', - 'foreign' => 'id', - 'foreignTable' => 'user', - 'onUpdate' => NULL, - 'onDelete' => NULL, - 'name' => 'self_reference_user_user_id1_id', -)); $this->createForeignKey('self_reference', array ( - 'local' => 'user_id2', - 'foreign' => 'id', - 'foreignTable' => 'user', - 'onUpdate' => NULL, - 'onDelete' => NULL, - 'name' => 'self_reference_user_user_id2_id', -)); $this->createForeignKey('self_reference', array ( - 'local' => 'parent_self_reference_id', - 'foreign' => 'id', - 'foreignTable' => 'self_reference', - 'onUpdate' => NULL, - 'onDelete' => NULL, - 'name' => 'self_reference_self_reference_parent_self_reference_id_id', -)); $this->createForeignKey('self_reference', array ( - 'local' => 'parent_self_reference_id2', - 'foreign' => 'id', - 'foreignTable' => 'self_reference', - 'onUpdate' => NULL, - 'onDelete' => NULL, - 'name' => 'self_reference_self_reference_parent_self_reference_id2_id', -)); $this->createForeignKey('user', array ( - 'local' => 'contact_id', - 'foreign' => 'id', - 'foreignTable' => 'contact', - 'onUpdate' => NULL, - 'onDelete' => NULL, - 'name' => 'user_contact_contact_id_id', -)); $this->createForeignKey('user_car', array ( - 'local' => 'user_id', - 'foreign' => 'id', - 'foreignTable' => 'user', - 'onUpdate' => NULL, - 'onDelete' => NULL, - 'name' => 'user_car_user_user_id_id', -)); $this->createForeignKey('user_car', array ( - 'local' => 'car_id', - 'foreign' => 'id', - 'foreignTable' => 'car', - 'onUpdate' => NULL, - 'onDelete' => NULL, - 'name' => 'user_car_car_car_id_id', -)); $this->createForeignKey('user_group', array ( - 'local' => 'user_id', - 'foreign' => 'id', - 'foreignTable' => 'user', - 'onUpdate' => NULL, - 'onDelete' => NULL, - 'name' => 'user_group_user_user_id_id', -)); $this->createForeignKey('user_group', array ( - 'local' => 'group_id', - 'foreign' => 'id', - 'foreignTable' => 'groups', - 'onUpdate' => NULL, - 'onDelete' => NULL, - 'name' => 'user_group_groups_group_id_id', -)); - } - - public function down() - { - $this->dropForeignKey('adult', 'adult_contact_contact_id_id'); - $this->dropForeignKey('child', 'child_adult_adult_id_id'); - $this->dropForeignKey('dog', 'dog_user_user_id_id'); - $this->dropForeignKey('self_reference', 'self_reference_user_user_id1_id'); - $this->dropForeignKey('self_reference', 'self_reference_user_user_id2_id'); - $this->dropForeignKey('self_reference', 'self_reference_self_reference_parent_self_reference_id_id'); - $this->dropForeignKey('self_reference', 'self_reference_self_reference_parent_self_reference_id2_id'); - $this->dropForeignKey('user', 'user_contact_contact_id_id'); - $this->dropForeignKey('user_car', 'user_car_user_user_id_id'); - $this->dropForeignKey('user_car', 'user_car_car_car_id_id'); - $this->dropForeignKey('user_group', 'user_group_user_user_id_id'); - $this->dropForeignKey('user_group', 'user_group_groups_group_id_id'); - - } -} \ No newline at end of file