OSDN Git Service

Reannotated
authorrandx <dmitriy.zaporozhets@gmail.com>
Tue, 26 Jun 2012 18:23:09 +0000 (21:23 +0300)
committerrandx <dmitriy.zaporozhets@gmail.com>
Tue, 26 Jun 2012 18:23:09 +0000 (21:23 +0300)
26 files changed:
app/models/event.rb
app/models/issue.rb
app/models/key.rb
app/models/merge_request.rb
app/models/milestone.rb
app/models/note.rb
app/models/project.rb
app/models/protected_branch.rb
app/models/snippet.rb
app/models/user.rb
app/models/users_project.rb
app/models/web_hook.rb
app/models/wiki.rb
spec/models/event_spec.rb
spec/models/issue_spec.rb
spec/models/key_spec.rb
spec/models/merge_request_spec.rb
spec/models/milestone_spec.rb
spec/models/note_spec.rb
spec/models/project_spec.rb
spec/models/protected_branch_spec.rb
spec/models/snippet_spec.rb
spec/models/user_spec.rb
spec/models/users_project_spec.rb
spec/models/web_hook_spec.rb
spec/models/wiki_spec.rb

index 3f1ff3e..dc7dfa1 100644 (file)
@@ -110,14 +110,15 @@ end
 #
 # Table name: events
 #
-#  id          :integer         not null, primary key
+#  id          :integer(4)      not null, primary key
 #  target_type :string(255)
-#  target_id   :integer
+#  target_id   :integer(4)
 #  title       :string(255)
 #  data        :text
-#  project_id  :integer
+#  project_id  :integer(4)
 #  created_at  :datetime        not null
 #  updated_at  :datetime        not null
-#  action      :integer
+#  action      :integer(4)
+#  author_id   :integer(4)
 #
 
index 844d418..fa2aa2f 100644 (file)
@@ -72,17 +72,18 @@ end
 #
 # Table name: issues
 #
-#  id          :integer         not null, primary key
-#  title       :string(255)
-#  description :text
-#  assignee_id :integer
-#  author_id   :integer
-#  project_id  :integer
-#  created_at  :datetime
-#  updated_at  :datetime
-#  closed      :boolean         default(FALSE), not null
-#  position    :integer         default(0)
-#  critical    :boolean         default(FALSE), not null
-#  branch_name :string(255)
+#  id           :integer(4)      not null, primary key
+#  title        :string(255)
+#  assignee_id  :integer(4)
+#  author_id    :integer(4)
+#  project_id   :integer(4)
+#  created_at   :datetime        not null
+#  updated_at   :datetime        not null
+#  closed       :boolean(1)      default(FALSE), not null
+#  position     :integer(4)      default(0)
+#  critical     :boolean(1)      default(FALSE), not null
+#  branch_name  :string(255)
+#  description  :text
+#  milestone_id :integer(4)
 #
 
index 2b05ef5..6b90b31 100644 (file)
@@ -55,13 +55,13 @@ end
 #
 # Table name: keys
 #
-#  id         :integer         not null, primary key
-#  user_id    :integer
-#  created_at :datetime
-#  updated_at :datetime
+#  id         :integer(4)      not null, primary key
+#  user_id    :integer(4)
+#  created_at :datetime        not null
+#  updated_at :datetime        not null
 #  key        :text
 #  title      :string(255)
 #  identifier :string(255)
-#  project_id :integer
+#  project_id :integer(4)
 #
 
index 12365b0..19999af 100644 (file)
@@ -198,15 +198,19 @@ end
 #
 # Table name: merge_requests
 #
-#  id            :integer         not null, primary key
+#  id            :integer(4)      not null, primary key
 #  target_branch :string(255)     not null
 #  source_branch :string(255)     not null
-#  project_id    :integer         not null
-#  author_id     :integer
-#  assignee_id   :integer
+#  project_id    :integer(4)      not null
+#  author_id     :integer(4)
+#  assignee_id   :integer(4)
 #  title         :string(255)
-#  closed        :boolean         default(FALSE), not null
-#  created_at    :datetime
-#  updated_at    :datetime
+#  closed        :boolean(1)      default(FALSE), not null
+#  created_at    :datetime        not null
+#  updated_at    :datetime        not null
+#  st_commits    :text(2147483647
+#  st_diffs      :text(2147483647
+#  merged        :boolean(1)      default(FALSE), not null
+#  state         :integer(4)      default(1), not null
 #
 
index 733c6a8..7fdfe29 100644 (file)
@@ -1,3 +1,17 @@
+# == Schema Information
+#
+# Table name: milestones
+#
+#  id          :integer(4)      not null, primary key
+#  title       :string(255)     not null
+#  project_id  :integer(4)      not null
+#  description :text
+#  due_date    :date
+#  closed      :boolean(1)      default(FALSE), not null
+#  created_at  :datetime        not null
+#  updated_at  :datetime        not null
+#
+
 class Milestone < ActiveRecord::Base
   belongs_to :project
   has_many :issues
index aa034ef..8a26cd0 100644 (file)
@@ -110,14 +110,14 @@ end
 #
 # Table name: notes
 #
-#  id            :integer         not null, primary key
+#  id            :integer(4)      not null, primary key
 #  note          :text
 #  noteable_id   :string(255)
 #  noteable_type :string(255)
-#  author_id     :integer
-#  created_at    :datetime
-#  updated_at    :datetime
-#  project_id    :integer
+#  author_id     :integer(4)
+#  created_at    :datetime        not null
+#  updated_at    :datetime        not null
+#  project_id    :integer(4)
 #  attachment    :string(255)
 #  line_code     :string(255)
 #
index 2e4b12e..9a4da19 100644 (file)
@@ -161,19 +161,19 @@ end
 #
 # Table name: projects
 #
-#  id                     :integer         not null, primary key
+#  id                     :integer(4)      not null, primary key
 #  name                   :string(255)
 #  path                   :string(255)
 #  description            :text
-#  created_at             :datetime
-#  updated_at             :datetime
-#  private_flag           :boolean         default(TRUE), not null
+#  created_at             :datetime        not null
+#  updated_at             :datetime        not null
+#  private_flag           :boolean(1)      default(TRUE), not null
 #  code                   :string(255)
-#  owner_id               :integer
+#  owner_id               :integer(4)
 #  default_branch         :string(255)     default("master"), not null
-#  issues_enabled         :boolean         default(TRUE), not null
-#  wall_enabled           :boolean         default(TRUE), not null
-#  merge_requests_enabled :boolean         default(TRUE), not null
-#  wiki_enabled           :boolean         default(TRUE), not null
+#  issues_enabled         :boolean(1)      default(TRUE), not null
+#  wall_enabled           :boolean(1)      default(TRUE), not null
+#  merge_requests_enabled :boolean(1)      default(TRUE), not null
+#  wiki_enabled           :boolean(1)      default(TRUE), not null
 #
 
index e24412b..4da1432 100644 (file)
@@ -18,8 +18,8 @@ end
 #
 # Table name: protected_branches
 #
-#  id         :integer         not null, primary key
-#  project_id :integer         not null
+#  id         :integer(4)      not null, primary key
+#  project_id :integer(4)      not null
 #  name       :string(255)     not null
 #  created_at :datetime        not null
 #  updated_at :datetime        not null
index 17d2341..e5f04bb 100644 (file)
@@ -62,13 +62,13 @@ end
 #
 # Table name: snippets
 #
-#  id         :integer         not null, primary key
+#  id         :integer(4)      not null, primary key
 #  title      :string(255)
 #  content    :text
-#  author_id  :integer         not null
-#  project_id :integer         not null
-#  created_at :datetime
-#  updated_at :datetime
+#  author_id  :integer(4)      not null
+#  project_id :integer(4)      not null
+#  created_at :datetime        not null
+#  updated_at :datetime        not null
 #  file_name  :string(255)
 #  expires_at :datetime
 #
index 69d5ec7..39aea3e 100644 (file)
@@ -92,25 +92,29 @@ end
 #
 # Table name: users
 #
-#  id                     :integer         not null, primary key
+#  id                     :integer(4)      not null, primary key
 #  email                  :string(255)     default(""), not null
 #  encrypted_password     :string(128)     default(""), not null
 #  reset_password_token   :string(255)
 #  reset_password_sent_at :datetime
 #  remember_created_at    :datetime
-#  sign_in_count          :integer         default(0)
+#  sign_in_count          :integer(4)      default(0)
 #  current_sign_in_at     :datetime
 #  last_sign_in_at        :datetime
 #  current_sign_in_ip     :string(255)
 #  last_sign_in_ip        :string(255)
-#  created_at             :datetime
-#  updated_at             :datetime
+#  created_at             :datetime        not null
+#  updated_at             :datetime        not null
 #  name                   :string(255)
-#  admin                  :boolean         default(FALSE), not null
-#  projects_limit         :integer         default(10)
+#  admin                  :boolean(1)      default(FALSE), not null
+#  projects_limit         :integer(4)      default(10)
 #  skype                  :string(255)     default(""), not null
 #  linkedin               :string(255)     default(""), not null
 #  twitter                :string(255)     default(""), not null
 #  authentication_token   :string(255)
-#  dark_scheme            :boolean         default(FALSE), not null
+#  dark_scheme            :boolean(1)      default(FALSE), not null
+#  theme_id               :integer(4)      default(1), not null
+#  bio                    :string(255)
+#  blocked                :boolean(1)      default(FALSE), not null
 #
+
index 808ed64..6ba7237 100644 (file)
@@ -75,11 +75,11 @@ end
 #
 # Table name: users_projects
 #
-#  id             :integer         not null, primary key
-#  user_id        :integer         not null
-#  project_id     :integer         not null
-#  created_at     :datetime
-#  updated_at     :datetime
-#  project_access :integer         default(0), not null
+#  id             :integer(4)      not null, primary key
+#  user_id        :integer(4)      not null
+#  project_id     :integer(4)      not null
+#  created_at     :datetime        not null
+#  updated_at     :datetime        not null
+#  project_access :integer(4)      default(0), not null
 #
 
index b0b1e0b..2628847 100644 (file)
@@ -22,10 +22,10 @@ end
 #
 # Table name: web_hooks
 #
-#  id         :integer         not null, primary key
+#  id         :integer(4)      not null, primary key
 #  url        :string(255)
-#  project_id :integer
-#  created_at :datetime
-#  updated_at :datetime
+#  project_id :integer(4)
+#  created_at :datetime        not null
+#  updated_at :datetime        not null
 #
 
index 3315488..ecc46fb 100644 (file)
@@ -34,13 +34,13 @@ end
 #
 # Table name: wikis
 #
-#  id         :integer         not null, primary key
+#  id         :integer(4)      not null, primary key
 #  title      :string(255)
 #  content    :text
-#  project_id :integer
+#  project_id :integer(4)
 #  created_at :datetime        not null
 #  updated_at :datetime        not null
 #  slug       :string(255)
-#  user_id    :integer
+#  user_id    :integer(4)
 #
 
index 04604dd..a295e28 100644 (file)
@@ -2,15 +2,16 @@
 #
 # Table name: events
 #
-#  id          :integer         not null, primary key
+#  id          :integer(4)      not null, primary key
 #  target_type :string(255)
-#  target_id   :integer
+#  target_id   :integer(4)
 #  title       :string(255)
 #  data        :text
-#  project_id  :integer
+#  project_id  :integer(4)
 #  created_at  :datetime        not null
 #  updated_at  :datetime        not null
-#  action      :integer
+#  action      :integer(4)
+#  author_id   :integer(4)
 #
 
 require 'spec_helper'
index fd3af62..486b9f6 100644 (file)
@@ -112,16 +112,18 @@ end
 #
 # Table name: issues
 #
-#  id          :integer         not null, primary key
-#  title       :string(255)
-#  assignee_id :integer
-#  author_id   :integer
-#  project_id  :integer
-#  created_at  :datetime
-#  updated_at  :datetime
-#  closed      :boolean         default(FALSE), not null
-#  position    :integer         default(0)
-#  critical    :boolean         default(FALSE), not null
-#  branch_name :string(255)
+#  id           :integer(4)      not null, primary key
+#  title        :string(255)
+#  assignee_id  :integer(4)
+#  author_id    :integer(4)
+#  project_id   :integer(4)
+#  created_at   :datetime        not null
+#  updated_at   :datetime        not null
+#  closed       :boolean(1)      default(FALSE), not null
+#  position     :integer(4)      default(0)
+#  critical     :boolean(1)      default(FALSE), not null
+#  branch_name  :string(255)
+#  description  :text
+#  milestone_id :integer(4)
 #
 
index b24f22c..0f9b317 100644 (file)
@@ -53,13 +53,13 @@ end
 #
 # Table name: keys
 #
-#  id         :integer         not null, primary key
-#  user_id    :integer
-#  created_at :datetime
-#  updated_at :datetime
+#  id         :integer(4)      not null, primary key
+#  user_id    :integer(4)
+#  created_at :datetime        not null
+#  updated_at :datetime        not null
 #  key        :text
 #  title      :string(255)
 #  identifier :string(255)
-#  project_id :integer
+#  project_id :integer(4)
 #
 
index 63996e2..8d750be 100644 (file)
@@ -62,15 +62,19 @@ end
 #
 # Table name: merge_requests
 #
-#  id            :integer         not null, primary key
+#  id            :integer(4)      not null, primary key
 #  target_branch :string(255)     not null
 #  source_branch :string(255)     not null
-#  project_id    :integer         not null
-#  author_id     :integer
-#  assignee_id   :integer
+#  project_id    :integer(4)      not null
+#  author_id     :integer(4)
+#  assignee_id   :integer(4)
 #  title         :string(255)
-#  closed        :boolean         default(FALSE), not null
-#  created_at    :datetime
-#  updated_at    :datetime
+#  closed        :boolean(1)      default(FALSE), not null
+#  created_at    :datetime        not null
+#  updated_at    :datetime        not null
+#  st_commits    :text(2147483647
+#  st_diffs      :text(2147483647
+#  merged        :boolean(1)      default(FALSE), not null
+#  state         :integer(4)      default(1), not null
 #
 
index ba11798..bb71ca9 100644 (file)
@@ -1,3 +1,17 @@
+# == Schema Information
+#
+# Table name: milestones
+#
+#  id          :integer(4)      not null, primary key
+#  title       :string(255)     not null
+#  project_id  :integer(4)      not null
+#  description :text
+#  due_date    :date
+#  closed      :boolean(1)      default(FALSE), not null
+#  created_at  :datetime        not null
+#  updated_at  :datetime        not null
+#
+
 require 'spec_helper'
 
 describe Milestone do
index af6ee9b..f2dfcab 100644 (file)
@@ -139,14 +139,14 @@ end
 #
 # Table name: notes
 #
-#  id            :integer         not null, primary key
+#  id            :integer(4)      not null, primary key
 #  note          :text
 #  noteable_id   :string(255)
 #  noteable_type :string(255)
-#  author_id     :integer
-#  created_at    :datetime
-#  updated_at    :datetime
-#  project_id    :integer
+#  author_id     :integer(4)
+#  created_at    :datetime        not null
+#  updated_at    :datetime        not null
+#  project_id    :integer(4)
 #  attachment    :string(255)
 #  line_code     :string(255)
 #
index d28668b..ab1baf0 100644 (file)
@@ -206,19 +206,19 @@ end
 #
 # Table name: projects
 #
-#  id                     :integer         not null, primary key
+#  id                     :integer(4)      not null, primary key
 #  name                   :string(255)
 #  path                   :string(255)
 #  description            :text
-#  created_at             :datetime
-#  updated_at             :datetime
-#  private_flag           :boolean         default(TRUE), not null
+#  created_at             :datetime        not null
+#  updated_at             :datetime        not null
+#  private_flag           :boolean(1)      default(TRUE), not null
 #  code                   :string(255)
-#  owner_id               :integer
+#  owner_id               :integer(4)
 #  default_branch         :string(255)     default("master"), not null
-#  issues_enabled         :boolean         default(TRUE), not null
-#  wall_enabled           :boolean         default(TRUE), not null
-#  merge_requests_enabled :boolean         default(TRUE), not null
-#  wiki_enabled           :boolean         default(TRUE), not null
+#  issues_enabled         :boolean(1)      default(TRUE), not null
+#  wall_enabled           :boolean(1)      default(TRUE), not null
+#  merge_requests_enabled :boolean(1)      default(TRUE), not null
+#  wiki_enabled           :boolean(1)      default(TRUE), not null
 #
 
index 024b45f..becc1be 100644 (file)
@@ -2,8 +2,8 @@
 #
 # Table name: protected_branches
 #
-#  id         :integer         not null, primary key
-#  project_id :integer         not null
+#  id         :integer(4)      not null, primary key
+#  project_id :integer(4)      not null
 #  name       :string(255)     not null
 #  created_at :datetime        not null
 #  updated_at :datetime        not null
index 037287a..9b4aaa1 100644 (file)
@@ -18,13 +18,13 @@ end
 #
 # Table name: snippets
 #
-#  id         :integer         not null, primary key
+#  id         :integer(4)      not null, primary key
 #  title      :string(255)
 #  content    :text
-#  author_id  :integer         not null
-#  project_id :integer         not null
-#  created_at :datetime
-#  updated_at :datetime
+#  author_id  :integer(4)      not null
+#  project_id :integer(4)      not null
+#  created_at :datetime        not null
+#  updated_at :datetime        not null
 #  file_name  :string(255)
 #  expires_at :datetime
 #
index 6fe9628..c2721dd 100644 (file)
@@ -46,25 +46,29 @@ end
 #
 # Table name: users
 #
-#  id                     :integer         not null, primary key
+#  id                     :integer(4)      not null, primary key
 #  email                  :string(255)     default(""), not null
 #  encrypted_password     :string(128)     default(""), not null
 #  reset_password_token   :string(255)
 #  reset_password_sent_at :datetime
 #  remember_created_at    :datetime
-#  sign_in_count          :integer         default(0)
+#  sign_in_count          :integer(4)      default(0)
 #  current_sign_in_at     :datetime
 #  last_sign_in_at        :datetime
 #  current_sign_in_ip     :string(255)
 #  last_sign_in_ip        :string(255)
-#  created_at             :datetime
-#  updated_at             :datetime
+#  created_at             :datetime        not null
+#  updated_at             :datetime        not null
 #  name                   :string(255)
-#  admin                  :boolean         default(FALSE), not null
-#  projects_limit         :integer         default(10)
+#  admin                  :boolean(1)      default(FALSE), not null
+#  projects_limit         :integer(4)      default(10)
 #  skype                  :string(255)     default(""), not null
 #  linkedin               :string(255)     default(""), not null
 #  twitter                :string(255)     default(""), not null
 #  authentication_token   :string(255)
-#  dark_scheme            :boolean         default(FALSE), not null
+#  dark_scheme            :boolean(1)      default(FALSE), not null
+#  theme_id               :integer(4)      default(1), not null
+#  bio                    :string(255)
+#  blocked                :boolean(1)      default(FALSE), not null
 #
+
index 85bc4d3..87fbfbf 100644 (file)
@@ -20,11 +20,11 @@ end
 #
 # Table name: users_projects
 #
-#  id             :integer         not null, primary key
-#  user_id        :integer         not null
-#  project_id     :integer         not null
-#  created_at     :datetime
-#  updated_at     :datetime
-#  project_access :integer         default(0), not null
+#  id             :integer(4)      not null, primary key
+#  user_id        :integer(4)      not null
+#  project_id     :integer(4)      not null
+#  created_at     :datetime        not null
+#  updated_at     :datetime        not null
+#  project_access :integer(4)      default(0), not null
 #
 
index 309bfc0..9971bd5 100644 (file)
@@ -56,10 +56,10 @@ end
 #
 # Table name: web_hooks
 #
-#  id         :integer         not null, primary key
+#  id         :integer(4)      not null, primary key
 #  url        :string(255)
-#  project_id :integer
-#  created_at :datetime
-#  updated_at :datetime
+#  project_id :integer(4)
+#  created_at :datetime        not null
+#  updated_at :datetime        not null
 #
 
index 05dbc97..892d0e8 100644 (file)
@@ -16,16 +16,15 @@ describe Wiki do
 end
 # == Schema Information
 #
-# Table name: snippets
+# Table name: wikis
 #
-#  id         :integer         not null, primary key
+#  id         :integer(4)      not null, primary key
 #  title      :string(255)
 #  content    :text
-#  author_id  :integer         not null
-#  project_id :integer         not null
-#  created_at :datetime
-#  updated_at :datetime
-#  file_name  :string(255)
-#  expires_at :datetime
+#  project_id :integer(4)
+#  created_at :datetime        not null
+#  updated_at :datetime        not null
+#  slug       :string(255)
+#  user_id    :integer(4)
 #