has_moderated 0.0.14 → 0.0.15

Sign up to get free protection for your applications and to get access to all the features.
data/README.rdoc CHANGED
@@ -99,7 +99,7 @@ in the root directory.
99
99
  == TODO
100
100
 
101
101
  Amend moderations... Eg if you create a new record and save it, then change something additionally and save again.
102
-
102
+ Hook for "moderation_creating" where you can add extra information on the moderation
103
103
  == Problems
104
104
 
105
105
  You may encounter problems with models that have some sort of non-serializable attributes. This might be something like file attachments, you'll have to try it to see.
@@ -49,7 +49,7 @@ module HasModerated
49
49
  end
50
50
  arec.send(fk.to_s+"=", rec.id) # set association to the newly created record
51
51
  attrs.each_pair do |key, val|
52
- arec.send(key.to_s+"=", val) unless key.to_s == 'id'
52
+ arec.send(key.to_s+"=", val) unless key.to_s == 'id' || key.to_s == fk.to_s
53
53
  end
54
54
  # disable moderation for associated model (if moderated)
55
55
  arec.has_moderated_updating = true if arec.respond_to?("has_moderated_updating=")
@@ -1,3 +1,3 @@
1
1
  module HasModerated
2
- VERSION = "0.0.14"
2
+ VERSION = "0.0.15"
3
3
  end
data/lib/has_moderated.rb CHANGED
@@ -56,6 +56,11 @@ module HasModerated
56
56
  end
57
57
  end
58
58
 
59
+ def moderation_creating &block
60
+ cattr_accessor :moderation_creating_hook
61
+ self.moderation_creating_hook = block
62
+ end
63
+
59
64
  def has_moderated_create *options
60
65
  # Lazily include the instance methods so we don't clutter up
61
66
  # any more ActiveRecord models than we have to.
@@ -101,9 +106,22 @@ module HasModerated
101
106
  true
102
107
  end
103
108
  end
109
+
110
+ def call_creating_hook moderation
111
+ if self.class.respond_to?(:moderation_creating_hook)
112
+ self.class.moderation_creating_hook.call(moderation)
113
+ end
114
+ end
115
+
116
+ def create_moderation_with_hooks!(*args)
117
+ m = Moderation.new(*args)
118
+ call_creating_hook(m)
119
+ m.save!
120
+ m
121
+ end
104
122
 
105
123
  def to_moderation_destroyed
106
- Moderation.create!({
124
+ create_moderation_with_hooks!({
107
125
  :moderatable_type => self.class.to_s,
108
126
  :moderatable_id => self.id,
109
127
  :attr_name => "-",
@@ -159,7 +177,7 @@ module HasModerated
159
177
  :associations => assoc_attrs
160
178
  }
161
179
 
162
- Moderation.create!({
180
+ create_moderation_with_hooks!({
163
181
  :moderatable_type => self.class.to_s,
164
182
  :moderatable_id => self.id,
165
183
  :attr_name => "-",
@@ -172,7 +190,7 @@ module HasModerated
172
190
  self.changes.each_pair do |att_name, values|
173
191
  att_name = att_name.to_s
174
192
  if self.class.moderated_attributes.include?(att_name) && !(values[0].blank? && values[1].blank?)
175
- moderations.push(Moderation.create!({
193
+ moderations.push(create_moderation_with_hooks!({
176
194
  :moderatable_type => self.class.to_s,
177
195
  :moderatable_id => self.id,
178
196
  :attr_name => att_name,
@@ -203,7 +221,7 @@ module HasModerated
203
221
 
204
222
  moderations = []
205
223
  if !assoc_attrs.empty?
206
- moderations.push(Moderation.create!({
224
+ moderations.push(create_moderation_with_hooks!({
207
225
  :moderatable_type => self.class.to_s,
208
226
  :moderatable_id => self.id,
209
227
  :attr_name => "-",
@@ -0,0 +1,8 @@
1
+ class HookTest < ActiveRecord::Base
2
+ has_moderated_create
3
+ has_moderated :title
4
+
5
+ moderation_creating do |m|
6
+ m.attr_value = " " + m.attr_value # just add 2 spaces
7
+ end
8
+ end
Binary file
@@ -0,0 +1,10 @@
1
+ class CreateHookTests < ActiveRecord::Migration
2
+ def change
3
+ create_table :hook_tests do |t|
4
+ t.string :title
5
+ t.string :foo
6
+
7
+ t.timestamps
8
+ end
9
+ end
10
+ end
@@ -10,7 +10,14 @@
10
10
  #
11
11
  # It's strongly recommended to check this file into your version control system.
12
12
 
13
- ActiveRecord::Schema.define(:version => 20111003234101) do
13
+ ActiveRecord::Schema.define(:version => 20111004153147) do
14
+
15
+ create_table "hook_tests", :force => true do |t|
16
+ t.string "title"
17
+ t.string "foo"
18
+ t.datetime "created_at"
19
+ t.datetime "updated_at"
20
+ end
14
21
 
15
22
  create_table "moderations", :force => true do |t|
16
23
  t.integer "moderatable_id"
Binary file
@@ -670,3 +670,325 @@ Migrating to CreateTaskPhotos (20111003234101)
670
670
   (1.6ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025410')
671
671
   (3.1ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025606')
672
672
   (1.3ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003205633')
673
+  (0.1ms) SELECT "schema_migrations"."version" FROM "schema_migrations" 
674
+  (0.1ms) select sqlite_version(*)
675
+  (3.3ms) CREATE TABLE "moderations" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "moderatable_id" integer, "moderatable_type" varchar(255) NOT NULL, "attr_name" varchar(60) NOT NULL, "attr_value" text NOT NULL, "created_at" datetime, "updated_at" datetime) 
676
+  (3.2ms) CREATE TABLE "photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "created_at" datetime, "updated_at" datetime)
677
+  (1.4ms) CREATE TABLE "subtasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "task_id" integer, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime, "task_all_id" integer) 
678
+  (1.4ms) CREATE TABLE "task_alls" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "value" varchar(255), "created_at" datetime, "updated_at" datetime)
679
+  (1.3ms) CREATE TABLE "task_photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "task_id" integer, "created_at" datetime, "updated_at" datetime) 
680
+  (4.7ms) CREATE TABLE "tasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime)
681
+  (1.3ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL) 
682
+  (0.0ms) PRAGMA index_list("schema_migrations")
683
+  (1.6ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")
684
+  (0.1ms) SELECT version FROM "schema_migrations"
685
+  (2.4ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003234101')
686
+  (2.1ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013205')
687
+  (4.0ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013228')
688
+  (1.7ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013618')
689
+  (2.3ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025410')
690
+  (2.2ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025606')
691
+  (1.4ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003205633')
692
+  (0.1ms) SELECT "schema_migrations"."version" FROM "schema_migrations" 
693
+  (0.1ms) select sqlite_version(*)
694
+  (2.8ms) CREATE TABLE "moderations" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "moderatable_id" integer, "moderatable_type" varchar(255) NOT NULL, "attr_name" varchar(60) NOT NULL, "attr_value" text NOT NULL, "created_at" datetime, "updated_at" datetime) 
695
+  (1.4ms) CREATE TABLE "photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "created_at" datetime, "updated_at" datetime)
696
+  (1.4ms) CREATE TABLE "subtasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "task_id" integer, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime, "task_all_id" integer) 
697
+  (1.3ms) CREATE TABLE "task_alls" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "value" varchar(255), "created_at" datetime, "updated_at" datetime)
698
+  (1.6ms) CREATE TABLE "task_photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "task_id" integer, "created_at" datetime, "updated_at" datetime) 
699
+  (1.4ms) CREATE TABLE "tasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime)
700
+  (1.5ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL) 
701
+  (0.1ms) PRAGMA index_list("schema_migrations")
702
+  (1.6ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")
703
+  (0.1ms) SELECT version FROM "schema_migrations"
704
+  (1.6ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003234101')
705
+  (1.4ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013205')
706
+  (1.5ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013228')
707
+  (1.5ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013618')
708
+  (1.2ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025410')
709
+  (1.1ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025606')
710
+  (2.2ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003205633')
711
+  (0.1ms) SELECT "schema_migrations"."version" FROM "schema_migrations" 
712
+  (0.1ms) select sqlite_version(*)
713
+  (2.8ms) CREATE TABLE "moderations" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "moderatable_id" integer, "moderatable_type" varchar(255) NOT NULL, "attr_name" varchar(60) NOT NULL, "attr_value" text NOT NULL, "created_at" datetime, "updated_at" datetime) 
714
+  (1.5ms) CREATE TABLE "photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "created_at" datetime, "updated_at" datetime)
715
+  (1.8ms) CREATE TABLE "subtasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "task_id" integer, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime, "task_all_id" integer) 
716
+  (1.4ms) CREATE TABLE "task_alls" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "value" varchar(255), "created_at" datetime, "updated_at" datetime)
717
+  (1.4ms) CREATE TABLE "task_photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "task_id" integer, "created_at" datetime, "updated_at" datetime) 
718
+  (1.4ms) CREATE TABLE "tasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime)
719
+  (1.6ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL) 
720
+  (0.0ms) PRAGMA index_list("schema_migrations")
721
+  (1.2ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")
722
+  (0.1ms) SELECT version FROM "schema_migrations"
723
+  (1.4ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003234101')
724
+  (1.3ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013205')
725
+  (1.3ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013228')
726
+  (2.3ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013618')
727
+  (1.7ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025410')
728
+  (1.2ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025606')
729
+  (1.5ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003205633')
730
+  (0.1ms) SELECT "schema_migrations"."version" FROM "schema_migrations" 
731
+  (0.1ms) select sqlite_version(*)
732
+  (2.8ms) CREATE TABLE "moderations" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "moderatable_id" integer, "moderatable_type" varchar(255) NOT NULL, "attr_name" varchar(60) NOT NULL, "attr_value" text NOT NULL, "created_at" datetime, "updated_at" datetime) 
733
+  (1.5ms) CREATE TABLE "photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "created_at" datetime, "updated_at" datetime)
734
+  (1.7ms) CREATE TABLE "subtasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "task_id" integer, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime, "task_all_id" integer) 
735
+  (1.3ms) CREATE TABLE "task_alls" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "value" varchar(255), "created_at" datetime, "updated_at" datetime)
736
+  (1.3ms) CREATE TABLE "task_photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "task_id" integer, "created_at" datetime, "updated_at" datetime) 
737
+  (1.6ms) CREATE TABLE "tasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime)
738
+  (1.4ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL) 
739
+  (0.1ms) PRAGMA index_list("schema_migrations")
740
+  (1.7ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")
741
+  (0.1ms) SELECT version FROM "schema_migrations"
742
+  (1.8ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003234101')
743
+  (1.6ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013205')
744
+  (1.2ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013228')
745
+  (1.3ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013618')
746
+  (1.7ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025410')
747
+  (1.4ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025606')
748
+  (1.2ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003205633')
749
+  (0.1ms) SELECT "schema_migrations"."version" FROM "schema_migrations" 
750
+  (0.1ms) select sqlite_version(*)
751
+  (2.7ms) CREATE TABLE "moderations" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "moderatable_id" integer, "moderatable_type" varchar(255) NOT NULL, "attr_name" varchar(60) NOT NULL, "attr_value" text NOT NULL, "created_at" datetime, "updated_at" datetime) 
752
+  (1.5ms) CREATE TABLE "photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "created_at" datetime, "updated_at" datetime)
753
+  (1.4ms) CREATE TABLE "subtasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "task_id" integer, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime, "task_all_id" integer) 
754
+  (1.3ms) CREATE TABLE "task_alls" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "value" varchar(255), "created_at" datetime, "updated_at" datetime)
755
+  (1.7ms) CREATE TABLE "task_photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "task_id" integer, "created_at" datetime, "updated_at" datetime) 
756
+  (1.4ms) CREATE TABLE "tasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime)
757
+  (1.6ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL) 
758
+  (0.0ms) PRAGMA index_list("schema_migrations")
759
+  (1.3ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")
760
+  (0.1ms) SELECT version FROM "schema_migrations"
761
+  (2.2ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003234101')
762
+  (1.3ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013205')
763
+  (1.5ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013228')
764
+  (1.5ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013618')
765
+  (1.5ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025410')
766
+  (1.4ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025606')
767
+  (1.3ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003205633')
768
+  (0.1ms) SELECT "schema_migrations"."version" FROM "schema_migrations" 
769
+  (0.1ms) select sqlite_version(*)
770
+  (1.6ms) CREATE TABLE "moderations" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "moderatable_id" integer, "moderatable_type" varchar(255) NOT NULL, "attr_name" varchar(60) NOT NULL, "attr_value" text NOT NULL, "created_at" datetime, "updated_at" datetime) 
771
+  (1.7ms) CREATE TABLE "photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "created_at" datetime, "updated_at" datetime)
772
+  (1.3ms) CREATE TABLE "subtasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "task_id" integer, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime, "task_all_id" integer) 
773
+  (112.2ms) CREATE TABLE "task_alls" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "value" varchar(255), "created_at" datetime, "updated_at" datetime)
774
+  (1.7ms) CREATE TABLE "task_photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "task_id" integer, "created_at" datetime, "updated_at" datetime) 
775
+  (1.8ms) CREATE TABLE "tasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime)
776
+  (2.1ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL) 
777
+  (0.1ms) PRAGMA index_list("schema_migrations")
778
+  (5.2ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")
779
+  (0.1ms) SELECT version FROM "schema_migrations"
780
+  (1.6ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003234101')
781
+  (2.2ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013205')
782
+  (1.8ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013228')
783
+  (2.0ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013618')
784
+  (1.8ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025410')
785
+  (2.4ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025606')
786
+  (1.5ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003205633')
787
+  (0.1ms) SELECT "schema_migrations"."version" FROM "schema_migrations" 
788
+  (0.1ms) select sqlite_version(*)
789
+  (2.7ms) CREATE TABLE "moderations" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "moderatable_id" integer, "moderatable_type" varchar(255) NOT NULL, "attr_name" varchar(60) NOT NULL, "attr_value" text NOT NULL, "created_at" datetime, "updated_at" datetime) 
790
+  (1.6ms) CREATE TABLE "photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "created_at" datetime, "updated_at" datetime)
791
+  (1.5ms) CREATE TABLE "subtasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "task_id" integer, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime, "task_all_id" integer) 
792
+  (1.6ms) CREATE TABLE "task_alls" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "value" varchar(255), "created_at" datetime, "updated_at" datetime)
793
+  (1.5ms) CREATE TABLE "task_photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "task_id" integer, "created_at" datetime, "updated_at" datetime) 
794
+  (2.2ms) CREATE TABLE "tasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime)
795
+  (1.5ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL) 
796
+  (0.0ms) PRAGMA index_list("schema_migrations")
797
+  (2.0ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")
798
+  (0.1ms) SELECT version FROM "schema_migrations"
799
+  (1.3ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003234101')
800
+  (1.6ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013205')
801
+  (2.4ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013228')
802
+  (1.7ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013618')
803
+  (1.3ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025410')
804
+  (1.6ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025606')
805
+  (1.6ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003205633')
806
+  (0.1ms) SELECT "schema_migrations"."version" FROM "schema_migrations" 
807
+ Migrating to CreateTasks (20110901013205)
808
+ Migrating to CreateSubtasks (20110901013228)
809
+ Migrating to CreateModerations (20110901013618)
810
+ Migrating to CreateTaskAlls (20110908025410)
811
+ Migrating to AddTaskAllIdToSubtasks (20110908025606)
812
+ Migrating to CreatePhotos (20111003205633)
813
+ Migrating to CreateTaskPhotos (20111003234101)
814
+ Migrating to CreateHookTests (20111004153147)
815
+  (0.0ms) select sqlite_version(*)
816
+  (0.4ms) CREATE TABLE "hook_tests" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "foo" varchar(255), "created_at" datetime, "updated_at" datetime) 
817
+  (0.1ms) INSERT INTO "schema_migrations" ("version") VALUES ('20111004153147')
818
+  (0.1ms) select sqlite_version(*)
819
+  (0.1ms) SELECT "schema_migrations"."version" FROM "schema_migrations"
820
+  (0.0ms) PRAGMA index_list("hook_tests")
821
+  (0.0ms) PRAGMA index_list("moderations")
822
+  (0.0ms) PRAGMA index_list("photos")
823
+  (0.0ms) PRAGMA index_list("subtasks")
824
+  (0.0ms) PRAGMA index_list("task_alls")
825
+  (0.0ms) PRAGMA index_list("task_photos")
826
+  (0.0ms) PRAGMA index_list("tasks")
827
+  (0.1ms) SELECT "schema_migrations"."version" FROM "schema_migrations" 
828
+  (0.1ms) select sqlite_version(*)
829
+  (2.7ms) CREATE TABLE "hook_tests" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "foo" varchar(255), "created_at" datetime, "updated_at" datetime) 
830
+  (1.6ms) CREATE TABLE "moderations" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "moderatable_id" integer, "moderatable_type" varchar(255) NOT NULL, "attr_name" varchar(60) NOT NULL, "attr_value" text NOT NULL, "created_at" datetime, "updated_at" datetime)
831
+  (1.7ms) CREATE TABLE "photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "created_at" datetime, "updated_at" datetime) 
832
+  (1.6ms) CREATE TABLE "subtasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "task_id" integer, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime, "task_all_id" integer)
833
+  (1.6ms) CREATE TABLE "task_alls" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "value" varchar(255), "created_at" datetime, "updated_at" datetime) 
834
+  (1.4ms) CREATE TABLE "task_photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "task_id" integer, "created_at" datetime, "updated_at" datetime)
835
+  (2.2ms) CREATE TABLE "tasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime) 
836
+  (1.6ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
837
+  (0.0ms) PRAGMA index_list("schema_migrations")
838
+  (1.5ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")
839
+  (0.1ms) SELECT version FROM "schema_migrations"
840
+  (1.5ms) INSERT INTO "schema_migrations" (version) VALUES ('20111004153147')
841
+  (1.6ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013205')
842
+  (2.6ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013228')
843
+  (1.6ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013618')
844
+  (1.4ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025410')
845
+  (1.6ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025606')
846
+  (1.9ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003205633')
847
+  (1.7ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003234101')
848
+  (0.1ms) SELECT "schema_migrations"."version" FROM "schema_migrations" 
849
+  (0.1ms) select sqlite_version(*)
850
+  (2.6ms) CREATE TABLE "hook_tests" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "foo" varchar(255), "created_at" datetime, "updated_at" datetime) 
851
+  (1.4ms) CREATE TABLE "moderations" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "moderatable_id" integer, "moderatable_type" varchar(255) NOT NULL, "attr_name" varchar(60) NOT NULL, "attr_value" text NOT NULL, "created_at" datetime, "updated_at" datetime)
852
+  (1.4ms) CREATE TABLE "photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "created_at" datetime, "updated_at" datetime) 
853
+  (1.2ms) CREATE TABLE "subtasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "task_id" integer, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime, "task_all_id" integer)
854
+  (1.7ms) CREATE TABLE "task_alls" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "value" varchar(255), "created_at" datetime, "updated_at" datetime) 
855
+  (1.5ms) CREATE TABLE "task_photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "task_id" integer, "created_at" datetime, "updated_at" datetime)
856
+  (1.7ms) CREATE TABLE "tasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime) 
857
+  (1.5ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
858
+  (0.0ms) PRAGMA index_list("schema_migrations")
859
+  (1.5ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")
860
+  (0.1ms) SELECT version FROM "schema_migrations"
861
+  (1.5ms) INSERT INTO "schema_migrations" (version) VALUES ('20111004153147')
862
+  (1.5ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013205')
863
+  (1.9ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013228')
864
+  (1.6ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013618')
865
+  (1.9ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025410')
866
+  (1.4ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025606')
867
+  (1.4ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003205633')
868
+  (1.6ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003234101')
869
+  (0.1ms) SELECT "schema_migrations"."version" FROM "schema_migrations" 
870
+  (0.1ms) select sqlite_version(*)
871
+  (2.7ms) CREATE TABLE "hook_tests" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "foo" varchar(255), "created_at" datetime, "updated_at" datetime) 
872
+  (1.5ms) CREATE TABLE "moderations" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "moderatable_id" integer, "moderatable_type" varchar(255) NOT NULL, "attr_name" varchar(60) NOT NULL, "attr_value" text NOT NULL, "created_at" datetime, "updated_at" datetime)
873
+  (1.4ms) CREATE TABLE "photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "created_at" datetime, "updated_at" datetime) 
874
+  (1.4ms) CREATE TABLE "subtasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "task_id" integer, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime, "task_all_id" integer)
875
+  (1.7ms) CREATE TABLE "task_alls" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "value" varchar(255), "created_at" datetime, "updated_at" datetime) 
876
+  (1.4ms) CREATE TABLE "task_photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "task_id" integer, "created_at" datetime, "updated_at" datetime)
877
+  (1.4ms) CREATE TABLE "tasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime) 
878
+  (1.9ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
879
+  (0.0ms) PRAGMA index_list("schema_migrations")
880
+  (1.4ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")
881
+  (0.1ms) SELECT version FROM "schema_migrations"
882
+  (1.3ms) INSERT INTO "schema_migrations" (version) VALUES ('20111004153147')
883
+  (1.3ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013205')
884
+  (1.7ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013228')
885
+  (1.9ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013618')
886
+  (2.2ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025410')
887
+  (1.3ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025606')
888
+  (1.6ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003205633')
889
+  (1.9ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003234101')
890
+  (0.1ms) SELECT "schema_migrations"."version" FROM "schema_migrations" 
891
+  (0.1ms) select sqlite_version(*)
892
+  (2.7ms) CREATE TABLE "hook_tests" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "foo" varchar(255), "created_at" datetime, "updated_at" datetime) 
893
+  (1.6ms) CREATE TABLE "moderations" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "moderatable_id" integer, "moderatable_type" varchar(255) NOT NULL, "attr_name" varchar(60) NOT NULL, "attr_value" text NOT NULL, "created_at" datetime, "updated_at" datetime)
894
+  (1.9ms) CREATE TABLE "photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "created_at" datetime, "updated_at" datetime) 
895
+  (1.6ms) CREATE TABLE "subtasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "task_id" integer, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime, "task_all_id" integer)
896
+  (1.9ms) CREATE TABLE "task_alls" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "value" varchar(255), "created_at" datetime, "updated_at" datetime) 
897
+  (1.6ms) CREATE TABLE "task_photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "task_id" integer, "created_at" datetime, "updated_at" datetime)
898
+  (2.7ms) CREATE TABLE "tasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime) 
899
+  (1.7ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
900
+  (0.1ms) PRAGMA index_list("schema_migrations")
901
+  (1.3ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")
902
+  (0.1ms) SELECT version FROM "schema_migrations"
903
+  (1.3ms) INSERT INTO "schema_migrations" (version) VALUES ('20111004153147')
904
+  (1.7ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013205')
905
+  (2.5ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013228')
906
+  (1.5ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013618')
907
+  (1.6ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025410')
908
+  (1.5ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025606')
909
+  (1.5ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003205633')
910
+  (1.9ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003234101')
911
+  (0.1ms) SELECT "schema_migrations"."version" FROM "schema_migrations" 
912
+  (0.1ms) select sqlite_version(*)
913
+  (2.7ms) CREATE TABLE "hook_tests" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "foo" varchar(255), "created_at" datetime, "updated_at" datetime) 
914
+  (1.4ms) CREATE TABLE "moderations" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "moderatable_id" integer, "moderatable_type" varchar(255) NOT NULL, "attr_name" varchar(60) NOT NULL, "attr_value" text NOT NULL, "created_at" datetime, "updated_at" datetime)
915
+  (1.6ms) CREATE TABLE "photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "created_at" datetime, "updated_at" datetime) 
916
+  (1.4ms) CREATE TABLE "subtasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "task_id" integer, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime, "task_all_id" integer)
917
+  (1.5ms) CREATE TABLE "task_alls" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "value" varchar(255), "created_at" datetime, "updated_at" datetime) 
918
+  (1.5ms) CREATE TABLE "task_photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "task_id" integer, "created_at" datetime, "updated_at" datetime)
919
+  (1.5ms) CREATE TABLE "tasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime) 
920
+  (1.2ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
921
+  (0.0ms) PRAGMA index_list("schema_migrations")
922
+  (1.6ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")
923
+  (0.1ms) SELECT version FROM "schema_migrations"
924
+  (2.3ms) INSERT INTO "schema_migrations" (version) VALUES ('20111004153147')
925
+  (1.7ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013205')
926
+  (1.6ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013228')
927
+  (1.2ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013618')
928
+  (1.6ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025410')
929
+  (1.8ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025606')
930
+  (2.5ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003205633')
931
+  (1.7ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003234101')
932
+  (0.1ms) SELECT "schema_migrations"."version" FROM "schema_migrations" 
933
+  (0.1ms) select sqlite_version(*)
934
+  (2.7ms) CREATE TABLE "hook_tests" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "foo" varchar(255), "created_at" datetime, "updated_at" datetime) 
935
+  (1.4ms) CREATE TABLE "moderations" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "moderatable_id" integer, "moderatable_type" varchar(255) NOT NULL, "attr_name" varchar(60) NOT NULL, "attr_value" text NOT NULL, "created_at" datetime, "updated_at" datetime)
936
+  (1.4ms) CREATE TABLE "photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "created_at" datetime, "updated_at" datetime) 
937
+  (1.5ms) CREATE TABLE "subtasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "task_id" integer, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime, "task_all_id" integer)
938
+  (1.8ms) CREATE TABLE "task_alls" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "value" varchar(255), "created_at" datetime, "updated_at" datetime) 
939
+  (1.4ms) CREATE TABLE "task_photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "task_id" integer, "created_at" datetime, "updated_at" datetime)
940
+  (1.7ms) CREATE TABLE "tasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime) 
941
+  (1.5ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
942
+  (0.1ms) PRAGMA index_list("schema_migrations")
943
+  (1.5ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")
944
+  (0.1ms) SELECT version FROM "schema_migrations"
945
+  (1.7ms) INSERT INTO "schema_migrations" (version) VALUES ('20111004153147')
946
+  (1.8ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013205')
947
+  (1.5ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013228')
948
+  (1.7ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013618')
949
+  (1.6ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025410')
950
+  (1.6ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025606')
951
+  (1.8ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003205633')
952
+  (1.6ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003234101')
953
+  (0.1ms) SELECT "schema_migrations"."version" FROM "schema_migrations" 
954
+  (0.1ms) select sqlite_version(*)
955
+  (2.8ms) CREATE TABLE "hook_tests" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "foo" varchar(255), "created_at" datetime, "updated_at" datetime) 
956
+  (1.6ms) CREATE TABLE "moderations" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "moderatable_id" integer, "moderatable_type" varchar(255) NOT NULL, "attr_name" varchar(60) NOT NULL, "attr_value" text NOT NULL, "created_at" datetime, "updated_at" datetime)
957
+  (1.3ms) CREATE TABLE "photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "created_at" datetime, "updated_at" datetime) 
958
+  (1.5ms) CREATE TABLE "subtasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "task_id" integer, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime, "task_all_id" integer)
959
+  (1.4ms) CREATE TABLE "task_alls" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "value" varchar(255), "created_at" datetime, "updated_at" datetime) 
960
+  (1.2ms) CREATE TABLE "task_photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "task_id" integer, "created_at" datetime, "updated_at" datetime)
961
+  (1.8ms) CREATE TABLE "tasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime) 
962
+  (1.6ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
963
+  (0.0ms) PRAGMA index_list("schema_migrations")
964
+  (2.5ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")
965
+  (0.1ms) SELECT version FROM "schema_migrations"
966
+  (1.5ms) INSERT INTO "schema_migrations" (version) VALUES ('20111004153147')
967
+  (1.6ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013205')
968
+  (1.4ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013228')
969
+  (1.8ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013618')
970
+  (1.2ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025410')
971
+  (2.4ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025606')
972
+  (1.6ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003205633')
973
+  (1.3ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003234101')
974
+  (0.1ms) SELECT "schema_migrations"."version" FROM "schema_migrations" 
975
+  (0.1ms) select sqlite_version(*)
976
+  (2.6ms) CREATE TABLE "hook_tests" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "foo" varchar(255), "created_at" datetime, "updated_at" datetime) 
977
+  (1.6ms) CREATE TABLE "moderations" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "moderatable_id" integer, "moderatable_type" varchar(255) NOT NULL, "attr_name" varchar(60) NOT NULL, "attr_value" text NOT NULL, "created_at" datetime, "updated_at" datetime)
978
+  (1.5ms) CREATE TABLE "photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "created_at" datetime, "updated_at" datetime) 
979
+  (1.9ms) CREATE TABLE "subtasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "task_id" integer, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime, "task_all_id" integer)
980
+  (1.5ms) CREATE TABLE "task_alls" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "value" varchar(255), "created_at" datetime, "updated_at" datetime) 
981
+  (1.4ms) CREATE TABLE "task_photos" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "photo" varchar(255), "task_id" integer, "created_at" datetime, "updated_at" datetime)
982
+  (1.6ms) CREATE TABLE "tasks" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "title" varchar(255), "desc" varchar(255), "created_at" datetime, "updated_at" datetime) 
983
+  (1.6ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)
984
+  (0.0ms) PRAGMA index_list("schema_migrations")
985
+  (1.4ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")
986
+  (0.1ms) SELECT version FROM "schema_migrations"
987
+  (1.4ms) INSERT INTO "schema_migrations" (version) VALUES ('20111004153147')
988
+  (1.7ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013205')
989
+  (1.7ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013228')
990
+  (1.9ms) INSERT INTO "schema_migrations" (version) VALUES ('20110901013618')
991
+  (2.1ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025410')
992
+  (1.7ms) INSERT INTO "schema_migrations" (version) VALUES ('20110908025606')
993
+  (1.6ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003205633')
994
+  (1.9ms) INSERT INTO "schema_migrations" (version) VALUES ('20111003234101')