diff options
author | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2013-06-19 15:40:33 +0300 |
---|---|---|
committer | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2013-06-19 15:40:33 +0300 |
commit | 6e35aceff29ddeae6282de31e81e48446ab927fa (patch) | |
tree | 34e777e35797f2d55ce82a3e807323523dda74be | |
parent | 78680a81774d67997fa0abece4dc1d4a5ec12ce6 (diff) | |
download | gitlab-ce-6e35aceff29ddeae6282de31e81e48446ab927fa.tar.gz |
Annotated
42 files changed, 198 insertions, 68 deletions
diff --git a/app/models/campfire_service.rb b/app/models/campfire_service.rb index 6450ffe7318..fb2a49fd586 100644 --- a/app/models/campfire_service.rb +++ b/app/models/campfire_service.rb @@ -11,6 +11,8 @@ # updated_at :datetime not null # active :boolean default(FALSE), not null # project_url :string(255) +# subdomain :string(255) +# room :string(255) # class CampfireService < Service diff --git a/app/models/deploy_key.rb b/app/models/deploy_key.rb index 548ef4f9a27..f983198085c 100644 --- a/app/models/deploy_key.rb +++ b/app/models/deploy_key.rb @@ -1,3 +1,17 @@ +# == Schema Information +# +# Table name: keys +# +# id :integer not null, primary key +# user_id :integer +# created_at :datetime +# updated_at :datetime +# key :text +# title :string(255) +# identifier :string(255) +# type :string(255) +# + class DeployKey < Key has_many :deploy_keys_projects, dependent: :destroy has_many :projects, through: :deploy_keys_projects diff --git a/app/models/deploy_keys_project.rb b/app/models/deploy_keys_project.rb index 48350a3e4d9..6f109e48314 100644 --- a/app/models/deploy_keys_project.rb +++ b/app/models/deploy_keys_project.rb @@ -1,3 +1,14 @@ +# == Schema Information +# +# Table name: deploy_keys_projects +# +# id :integer not null, primary key +# deploy_key_id :integer not null +# project_id :integer not null +# created_at :datetime not null +# updated_at :datetime not null +# + class DeployKeysProject < ActiveRecord::Base attr_accessible :key_id, :project_id diff --git a/app/models/forked_project_link.rb b/app/models/forked_project_link.rb index c3199ca264e..aaa527a1145 100644 --- a/app/models/forked_project_link.rb +++ b/app/models/forked_project_link.rb @@ -1,3 +1,14 @@ +# == Schema Information +# +# Table name: forked_project_links +# +# id :integer not null, primary key +# forked_to_project_id :integer not null +# forked_from_project_id :integer not null +# created_at :datetime not null +# updated_at :datetime not null +# + class ForkedProjectLink < ActiveRecord::Base attr_accessible :forked_from_project_id, :forked_to_project_id diff --git a/app/models/gitlab_ci_service.rb b/app/models/gitlab_ci_service.rb index bdbe7724be0..7f5380a4551 100644 --- a/app/models/gitlab_ci_service.rb +++ b/app/models/gitlab_ci_service.rb @@ -11,6 +11,8 @@ # updated_at :datetime not null # active :boolean default(FALSE), not null # project_url :string(255) +# subdomain :string(255) +# room :string(255) # class GitlabCiService < Service diff --git a/app/models/hipchat_service.rb b/app/models/hipchat_service.rb index 13429fa83b4..c3fb4826334 100644 --- a/app/models/hipchat_service.rb +++ b/app/models/hipchat_service.rb @@ -11,6 +11,8 @@ # updated_at :datetime not null # active :boolean default(FALSE), not null # project_url :string(255) +# subdomain :string(255) +# room :string(255) # class HipchatService < Service @@ -70,4 +72,4 @@ class HipchatService < Service message end -end
\ No newline at end of file +end diff --git a/app/models/issue.rb b/app/models/issue.rb index de6e015c68e..f56928891dc 100644 --- a/app/models/issue.rb +++ b/app/models/issue.rb @@ -7,8 +7,8 @@ # assignee_id :integer # author_id :integer # project_id :integer -# created_at :datetime not null -# updated_at :datetime not null +# created_at :datetime +# updated_at :datetime # position :integer default(0) # branch_name :string(255) # description :text diff --git a/app/models/key.rb b/app/models/key.rb index 185aef46e9e..a87ea4943e9 100644 --- a/app/models/key.rb +++ b/app/models/key.rb @@ -4,12 +4,12 @@ # # id :integer not null, primary key # user_id :integer -# created_at :datetime not null -# updated_at :datetime not null +# created_at :datetime +# updated_at :datetime # key :text # title :string(255) # identifier :string(255) -# project_id :integer +# type :string(255) # require 'digest/md5' diff --git a/app/models/merge_request.rb b/app/models/merge_request.rb index f41473336bc..c45af9f713e 100644 --- a/app/models/merge_request.rb +++ b/app/models/merge_request.rb @@ -9,8 +9,8 @@ # author_id :integer # assignee_id :integer # title :string(255) -# created_at :datetime not null -# updated_at :datetime not null +# created_at :datetime +# updated_at :datetime # st_commits :text(2147483647) # st_diffs :text(2147483647) # milestone_id :integer diff --git a/app/models/note.rb b/app/models/note.rb index 9a3481faaaa..c2e664d1bcd 100644 --- a/app/models/note.rb +++ b/app/models/note.rb @@ -6,8 +6,8 @@ # note :text # noteable_type :string(255) # author_id :integer -# created_at :datetime not null -# updated_at :datetime not null +# created_at :datetime +# updated_at :datetime # project_id :integer # attachment :string(255) # line_code :string(255) diff --git a/app/models/personal_snippet.rb b/app/models/personal_snippet.rb index d581c6092aa..a3c0d201ee5 100644 --- a/app/models/personal_snippet.rb +++ b/app/models/personal_snippet.rb @@ -6,13 +6,14 @@ # title :string(255) # content :text # author_id :integer not null -# project_id :integer not null -# created_at :datetime not null -# updated_at :datetime not null +# project_id :integer +# created_at :datetime +# updated_at :datetime # file_name :string(255) # expires_at :datetime +# private :boolean default(TRUE), not null # type :string(255) -# private :boolean +# class PersonalSnippet < Snippet end diff --git a/app/models/project.rb b/app/models/project.rb index 234d5e98b4f..ff61eca60de 100644 --- a/app/models/project.rb +++ b/app/models/project.rb @@ -6,8 +6,8 @@ # name :string(255) # path :string(255) # description :text -# created_at :datetime not null -# updated_at :datetime not null +# created_at :datetime +# updated_at :datetime # creator_id :integer # default_branch :string(255) # issues_enabled :boolean default(TRUE), not null @@ -20,6 +20,7 @@ # issues_tracker_id :string(255) # snippets_enabled :boolean default(TRUE), not null # last_activity_at :datetime +# imported :boolean default(FALSE), not null # require "grit" diff --git a/app/models/project_hook.rb b/app/models/project_hook.rb index 2576fc979d4..b82e1ffd4ab 100644 --- a/app/models/project_hook.rb +++ b/app/models/project_hook.rb @@ -5,8 +5,8 @@ # id :integer not null, primary key # url :string(255) # project_id :integer -# created_at :datetime not null -# updated_at :datetime not null +# created_at :datetime +# updated_at :datetime # type :string(255) default("ProjectHook") # service_id :integer # diff --git a/app/models/project_snippet.rb b/app/models/project_snippet.rb index a86f2e7a32f..14c88046423 100644 --- a/app/models/project_snippet.rb +++ b/app/models/project_snippet.rb @@ -6,13 +6,14 @@ # title :string(255) # content :text # author_id :integer not null -# project_id :integer not null -# created_at :datetime not null -# updated_at :datetime not null +# project_id :integer +# created_at :datetime +# updated_at :datetime # file_name :string(255) # expires_at :datetime +# private :boolean default(TRUE), not null # type :string(255) -# private :boolean +# class ProjectSnippet < Snippet belongs_to :project diff --git a/app/models/service.rb b/app/models/service.rb index 3e945aa898c..d21e8a2c567 100644 --- a/app/models/service.rb +++ b/app/models/service.rb @@ -11,6 +11,8 @@ # updated_at :datetime not null # active :boolean default(FALSE), not null # project_url :string(255) +# subdomain :string(255) +# room :string(255) # # To add new service you should build a class inherited from Service diff --git a/app/models/service_hook.rb b/app/models/service_hook.rb index 4cd2b272eec..433e8059788 100644 --- a/app/models/service_hook.rb +++ b/app/models/service_hook.rb @@ -5,8 +5,8 @@ # id :integer not null, primary key # url :string(255) # project_id :integer -# created_at :datetime not null -# updated_at :datetime not null +# created_at :datetime +# updated_at :datetime # type :string(255) default("ProjectHook") # service_id :integer # diff --git a/app/models/snippet.rb b/app/models/snippet.rb index 1b37ffe8339..3a2fc17e59c 100644 --- a/app/models/snippet.rb +++ b/app/models/snippet.rb @@ -6,13 +6,14 @@ # title :string(255) # content :text # author_id :integer not null -# project_id :integer not null -# created_at :datetime not null -# updated_at :datetime not null +# project_id :integer +# created_at :datetime +# updated_at :datetime # file_name :string(255) # expires_at :datetime +# private :boolean default(TRUE), not null # type :string(255) -# private :boolean +# class Snippet < ActiveRecord::Base include Linguist::BlobHelper diff --git a/app/models/system_hook.rb b/app/models/system_hook.rb index 5cdf046644f..2d28f4cd452 100644 --- a/app/models/system_hook.rb +++ b/app/models/system_hook.rb @@ -5,8 +5,8 @@ # id :integer not null, primary key # url :string(255) # project_id :integer -# created_at :datetime not null -# updated_at :datetime not null +# created_at :datetime +# updated_at :datetime # type :string(255) default("ProjectHook") # service_id :integer # diff --git a/app/models/user.rb b/app/models/user.rb index d8c9ac647b5..6a5411b222d 100644 --- a/app/models/user.rb +++ b/app/models/user.rb @@ -4,7 +4,7 @@ # # id :integer not null, primary key # email :string(255) default(""), not null -# encrypted_password :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 @@ -13,8 +13,8 @@ # last_sign_in_at :datetime # current_sign_in_ip :string(255) # last_sign_in_ip :string(255) -# created_at :datetime not null -# updated_at :datetime not null +# created_at :datetime +# updated_at :datetime # name :string(255) # admin :boolean default(FALSE), not null # projects_limit :integer default(10) @@ -34,6 +34,8 @@ # state :string(255) # color_scheme_id :integer default(1), not null # notification_level :integer default(1), not null +# password_expires_at :datetime +# created_by_id :integer # class User < ActiveRecord::Base diff --git a/app/models/users_group.rb b/app/models/users_group.rb index 0cb26854f9c..d70f56f681f 100644 --- a/app/models/users_group.rb +++ b/app/models/users_group.rb @@ -1,3 +1,15 @@ +# == Schema Information +# +# Table name: users_groups +# +# id :integer not null, primary key +# group_access :integer not null +# group_id :integer not null +# user_id :integer not null +# created_at :datetime not null +# updated_at :datetime not null +# + class UsersGroup < ActiveRecord::Base GUEST = 10 REPORTER = 20 diff --git a/app/models/users_project.rb b/app/models/users_project.rb index 4c58b009380..58d05fbe077 100644 --- a/app/models/users_project.rb +++ b/app/models/users_project.rb @@ -5,8 +5,8 @@ # id :integer not null, primary key # user_id :integer not null # project_id :integer not null -# created_at :datetime not null -# updated_at :datetime not null +# created_at :datetime +# updated_at :datetime # project_access :integer default(0), not null # notification_level :integer default(3), not null # diff --git a/app/models/web_hook.rb b/app/models/web_hook.rb index 3f22b1082fb..1e6ea885ea9 100644 --- a/app/models/web_hook.rb +++ b/app/models/web_hook.rb @@ -5,8 +5,8 @@ # id :integer not null, primary key # url :string(255) # project_id :integer -# created_at :datetime not null -# updated_at :datetime not null +# created_at :datetime +# updated_at :datetime # type :string(255) default("ProjectHook") # service_id :integer # diff --git a/spec/factories/forked_project_links.rb b/spec/factories/forked_project_links.rb index 64bcdf09429..2f9b91acf2c 100644 --- a/spec/factories/forked_project_links.rb +++ b/spec/factories/forked_project_links.rb @@ -1,3 +1,14 @@ +# == Schema Information +# +# Table name: forked_project_links +# +# id :integer not null, primary key +# forked_to_project_id :integer not null +# forked_from_project_id :integer not null +# created_at :datetime not null +# updated_at :datetime not null +# + # Read about factories at https://github.com/thoughtbot/factory_girl FactoryGirl.define do diff --git a/spec/factories/users_groups.rb b/spec/factories/users_groups.rb index cb272e35c92..654bb2caee8 100644 --- a/spec/factories/users_groups.rb +++ b/spec/factories/users_groups.rb @@ -1,3 +1,15 @@ +# == Schema Information +# +# Table name: users_groups +# +# id :integer not null, primary key +# group_access :integer not null +# group_id :integer not null +# user_id :integer not null +# created_at :datetime not null +# updated_at :datetime not null +# + FactoryGirl.define do factory :users_group do group_access { UsersGroup::OWNER } diff --git a/spec/models/deploy_key_spec.rb b/spec/models/deploy_key_spec.rb index 3658a6ff1d0..ec1f5d2c4e2 100644 --- a/spec/models/deploy_key_spec.rb +++ b/spec/models/deploy_key_spec.rb @@ -4,12 +4,12 @@ # # id :integer not null, primary key # user_id :integer -# created_at :datetime not null -# updated_at :datetime not null +# created_at :datetime +# updated_at :datetime # key :text # title :string(255) # identifier :string(255) -# project_id :integer +# type :string(255) # require 'spec_helper' diff --git a/spec/models/deploy_keys_project_spec.rb b/spec/models/deploy_keys_project_spec.rb index bb62c48bbcc..aeec1713558 100644 --- a/spec/models/deploy_keys_project_spec.rb +++ b/spec/models/deploy_keys_project_spec.rb @@ -1,3 +1,14 @@ +# == Schema Information +# +# Table name: deploy_keys_projects +# +# id :integer not null, primary key +# deploy_key_id :integer not null +# project_id :integer not null +# created_at :datetime not null +# updated_at :datetime not null +# + require 'spec_helper' describe DeployKeysProject do diff --git a/spec/models/forked_project_link_spec.rb b/spec/models/forked_project_link_spec.rb index c362b21f088..5f25e2abd23 100644 --- a/spec/models/forked_project_link_spec.rb +++ b/spec/models/forked_project_link_spec.rb @@ -1,3 +1,14 @@ +# == Schema Information +# +# Table name: forked_project_links +# +# id :integer not null, primary key +# forked_to_project_id :integer not null +# forked_from_project_id :integer not null +# created_at :datetime not null +# updated_at :datetime not null +# + require 'spec_helper' describe ForkedProjectLink, "add link on fork" do diff --git a/spec/models/gitlab_ci_service_spec.rb b/spec/models/gitlab_ci_service_spec.rb index b86588af1ac..56efa9df457 100644 --- a/spec/models/gitlab_ci_service_spec.rb +++ b/spec/models/gitlab_ci_service_spec.rb @@ -11,6 +11,8 @@ # updated_at :datetime not null # active :boolean default(FALSE), not null # project_url :string(255) +# subdomain :string(255) +# room :string(255) # require 'spec_helper' diff --git a/spec/models/issue_spec.rb b/spec/models/issue_spec.rb index 1bc794dcd77..ed0a725add6 100644 --- a/spec/models/issue_spec.rb +++ b/spec/models/issue_spec.rb @@ -7,8 +7,8 @@ # assignee_id :integer # author_id :integer # project_id :integer -# created_at :datetime not null -# updated_at :datetime not null +# created_at :datetime +# updated_at :datetime # position :integer default(0) # branch_name :string(255) # description :text diff --git a/spec/models/key_spec.rb b/spec/models/key_spec.rb index 9ccad18248c..6c06f5268b3 100644 --- a/spec/models/key_spec.rb +++ b/spec/models/key_spec.rb @@ -4,12 +4,12 @@ # # id :integer not null, primary key # user_id :integer -# created_at :datetime not null -# updated_at :datetime not null +# created_at :datetime +# updated_at :datetime # key :text # title :string(255) # identifier :string(255) -# project_id :integer +# type :string(255) # require 'spec_helper' diff --git a/spec/models/merge_request_spec.rb b/spec/models/merge_request_spec.rb index a4660806cca..a0a43fbb815 100644 --- a/spec/models/merge_request_spec.rb +++ b/spec/models/merge_request_spec.rb @@ -9,8 +9,8 @@ # author_id :integer # assignee_id :integer # title :string(255) -# created_at :datetime not null -# updated_at :datetime not null +# created_at :datetime +# updated_at :datetime # st_commits :text(2147483647) # st_diffs :text(2147483647) # milestone_id :integer diff --git a/spec/models/note_spec.rb b/spec/models/note_spec.rb index 52e24a78eb4..ba94f940dc8 100644 --- a/spec/models/note_spec.rb +++ b/spec/models/note_spec.rb @@ -6,8 +6,8 @@ # note :text # noteable_type :string(255) # author_id :integer -# created_at :datetime not null -# updated_at :datetime not null +# created_at :datetime +# updated_at :datetime # project_id :integer # attachment :string(255) # line_code :string(255) diff --git a/spec/models/project_snippet_spec.rb b/spec/models/project_snippet_spec.rb index 716fd81c91b..42147179387 100644 --- a/spec/models/project_snippet_spec.rb +++ b/spec/models/project_snippet_spec.rb @@ -6,11 +6,13 @@ # title :string(255) # content :text # author_id :integer not null -# project_id :integer not null -# created_at :datetime not null -# updated_at :datetime not null +# project_id :integer +# created_at :datetime +# updated_at :datetime # file_name :string(255) # expires_at :datetime +# private :boolean default(TRUE), not null +# type :string(255) # require 'spec_helper' diff --git a/spec/models/project_spec.rb b/spec/models/project_spec.rb index 2e3870b1b65..0845d2edea3 100644 --- a/spec/models/project_spec.rb +++ b/spec/models/project_spec.rb @@ -6,8 +6,8 @@ # name :string(255) # path :string(255) # description :text -# created_at :datetime not null -# updated_at :datetime not null +# created_at :datetime +# updated_at :datetime # creator_id :integer # default_branch :string(255) # issues_enabled :boolean default(TRUE), not null @@ -20,6 +20,7 @@ # issues_tracker_id :string(255) # snippets_enabled :boolean default(TRUE), not null # last_activity_at :datetime +# imported :boolean default(FALSE), not null # require 'spec_helper' diff --git a/spec/models/service_hook_spec.rb b/spec/models/service_hook_spec.rb index 0b0262c97f1..e5ba59c0d65 100644 --- a/spec/models/service_hook_spec.rb +++ b/spec/models/service_hook_spec.rb @@ -5,8 +5,8 @@ # id :integer not null, primary key # url :string(255) # project_id :integer -# created_at :datetime not null -# updated_at :datetime not null +# created_at :datetime +# updated_at :datetime # type :string(255) default("ProjectHook") # service_id :integer # diff --git a/spec/models/service_spec.rb b/spec/models/service_spec.rb index 1a58f680baf..55ef1914730 100644 --- a/spec/models/service_spec.rb +++ b/spec/models/service_spec.rb @@ -11,6 +11,8 @@ # updated_at :datetime not null # active :boolean default(FALSE), not null # project_url :string(255) +# subdomain :string(255) +# room :string(255) # require 'spec_helper' diff --git a/spec/models/snippet_spec.rb b/spec/models/snippet_spec.rb index 52355c38f0c..a77c594aaf1 100644 --- a/spec/models/snippet_spec.rb +++ b/spec/models/snippet_spec.rb @@ -6,11 +6,13 @@ # title :string(255) # content :text # author_id :integer not null -# project_id :integer not null -# created_at :datetime not null -# updated_at :datetime not null +# project_id :integer +# created_at :datetime +# updated_at :datetime # file_name :string(255) # expires_at :datetime +# private :boolean default(TRUE), not null +# type :string(255) # require 'spec_helper' diff --git a/spec/models/system_hook_spec.rb b/spec/models/system_hook_spec.rb index a9ed6a5fa7c..7f11f9ec247 100644 --- a/spec/models/system_hook_spec.rb +++ b/spec/models/system_hook_spec.rb @@ -5,8 +5,8 @@ # id :integer not null, primary key # url :string(255) # project_id :integer -# created_at :datetime not null -# updated_at :datetime not null +# created_at :datetime +# updated_at :datetime # type :string(255) default("ProjectHook") # service_id :integer # diff --git a/spec/models/user_spec.rb b/spec/models/user_spec.rb index f0a6012d0c2..4c37a48c4d1 100644 --- a/spec/models/user_spec.rb +++ b/spec/models/user_spec.rb @@ -4,7 +4,7 @@ # # id :integer not null, primary key # email :string(255) default(""), not null -# encrypted_password :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 @@ -13,8 +13,8 @@ # last_sign_in_at :datetime # current_sign_in_ip :string(255) # last_sign_in_ip :string(255) -# created_at :datetime not null -# updated_at :datetime not null +# created_at :datetime +# updated_at :datetime # name :string(255) # admin :boolean default(FALSE), not null # projects_limit :integer default(10) @@ -34,6 +34,8 @@ # state :string(255) # color_scheme_id :integer default(1), not null # notification_level :integer default(1), not null +# password_expires_at :datetime +# created_by_id :integer # require 'spec_helper' diff --git a/spec/models/users_group_spec.rb b/spec/models/users_group_spec.rb index c802b8213d5..4da31a55fcb 100644 --- a/spec/models/users_group_spec.rb +++ b/spec/models/users_group_spec.rb @@ -1,3 +1,15 @@ +# == Schema Information +# +# Table name: users_groups +# +# id :integer not null, primary key +# group_access :integer not null +# group_id :integer not null +# user_id :integer not null +# created_at :datetime not null +# updated_at :datetime not null +# + require 'spec_helper' describe UsersGroup do diff --git a/spec/models/users_project_spec.rb b/spec/models/users_project_spec.rb index e289a592b03..aa4b8cb449b 100644 --- a/spec/models/users_project_spec.rb +++ b/spec/models/users_project_spec.rb @@ -5,8 +5,8 @@ # id :integer not null, primary key # user_id :integer not null # project_id :integer not null -# created_at :datetime not null -# updated_at :datetime not null +# created_at :datetime +# updated_at :datetime # project_access :integer default(0), not null # notification_level :integer default(3), not null # diff --git a/spec/models/web_hook_spec.rb b/spec/models/web_hook_spec.rb index 2d9301732dd..4f88ed849e0 100644 --- a/spec/models/web_hook_spec.rb +++ b/spec/models/web_hook_spec.rb @@ -5,8 +5,8 @@ # id :integer not null, primary key # url :string(255) # project_id :integer -# created_at :datetime not null -# updated_at :datetime not null +# created_at :datetime +# updated_at :datetime # type :string(255) default("ProjectHook") # service_id :integer # |