From be560d4eb61dba43ab94e3371c104e02bb71e541 Mon Sep 17 00:00:00 2001 From: Sam <sam.saffron@gmail.com> Date: Fri, 7 Feb 2014 11:07:36 +1100 Subject: [PATCH] Update annotations --- app/models/category.rb | 3 +++ app/models/category_user.rb | 10 +++++++++ app/models/group.rb | 14 ++++++------- app/models/invite.rb | 22 ++++++++++---------- app/models/post.rb | 4 +++- app/models/post_revision.rb | 18 ++++++++++++++++ app/models/top_topic.rb | 40 ++++++++++++++++++++++++++++++++++++ app/models/topic.rb | 1 + app/models/topic_embed.rb | 17 +++++++++++++++ app/models/topic_revision.rb | 18 ++++++++++++++++ app/models/topic_user.rb | 2 +- app/models/user.rb | 3 ++- app/models/user_visit.rb | 2 +- 13 files changed, 132 insertions(+), 22 deletions(-) diff --git a/app/models/category.rb b/app/models/category.rb index 50c7f0f7f..33f27808f 100644 --- a/app/models/category.rb +++ b/app/models/category.rb @@ -370,6 +370,9 @@ end # latest_topic_id :integer # position :integer # parent_category_id :integer +# posts_year :integer +# posts_month :integer +# posts_week :integer # # Indexes # diff --git a/app/models/category_user.rb b/app/models/category_user.rb index 17fa8299e..abbef8fbf 100644 --- a/app/models/category_user.rb +++ b/app/models/category_user.rb @@ -67,3 +67,13 @@ SQL end end + +# == Schema Information +# +# Table name: category_users +# +# id :integer not null, primary key +# category_id :integer not null +# user_id :integer not null +# notification_level :integer not null +# diff --git a/app/models/group.rb b/app/models/group.rb index 15ce94871..b83144b6f 100644 --- a/app/models/group.rb +++ b/app/models/group.rb @@ -214,15 +214,15 @@ end # # Table name: groups # -# id :integer not null, primary key -# name :string(255) not null -# created_at :datetime not null -# updated_at :datetime not null -# automatic :boolean default(FALSE), not null -# user_count :integer default(0), not null +# id :integer not null, primary key +# name :string(255) not null +# created_at :datetime not null +# updated_at :datetime not null +# automatic :boolean default(FALSE), not null +# user_count :integer default(0), not null +# alias_level :integer default(0) # # Indexes # # index_groups_on_name (name) UNIQUE # - diff --git a/app/models/invite.rb b/app/models/invite.rb index 63aa45be4..d2da1c383 100644 --- a/app/models/invite.rb +++ b/app/models/invite.rb @@ -121,20 +121,20 @@ end # # Table name: invites # -# id :integer not null, primary key -# invite_key :string(32) not null -# email :string(255) not null -# invited_by_id :integer not null -# user_id :integer -# redeemed_at :datetime -# created_at :datetime not null -# updated_at :datetime not null -# deleted_at :datetime -# deleted_by_id :integer +# id :integer not null, primary key +# invite_key :string(32) not null +# email :string(255) not null +# invited_by_id :integer not null +# user_id :integer +# redeemed_at :datetime +# created_at :datetime not null +# updated_at :datetime not null +# deleted_at :datetime +# deleted_by_id :integer +# invalidated_at :datetime # # Indexes # # index_invites_on_email_and_invited_by_id (email,invited_by_id) UNIQUE # index_invites_on_invite_key (invite_key) UNIQUE # - diff --git a/app/models/post.rb b/app/models/post.rb index 0fd495965..8c4364064 100644 --- a/app/models/post.rb +++ b/app/models/post.rb @@ -488,7 +488,6 @@ end # created_at :datetime not null # updated_at :datetime not null # reply_to_post_number :integer -# version :integer default(1), not null # reply_count :integer default(0), not null # quote_count :integer default(0), not null # deleted_at :datetime @@ -517,6 +516,9 @@ end # like_score :integer default(0), not null # deleted_by_id :integer # edit_reason :string(255) +# word_count :integer +# version :integer default(1), not null +# cook_method :integer default(1), not null # # Indexes # diff --git a/app/models/post_revision.rb b/app/models/post_revision.rb index 280c7aea9..fd46c90e7 100644 --- a/app/models/post_revision.rb +++ b/app/models/post_revision.rb @@ -4,3 +4,21 @@ class PostRevision < ActiveRecord::Base serialize :modifications, Hash end + +# == Schema Information +# +# Table name: post_revisions +# +# id :integer not null, primary key +# user_id :integer +# post_id :integer +# modifications :text +# number :integer +# created_at :datetime +# updated_at :datetime +# +# Indexes +# +# index_post_revisions_on_post_id (post_id) +# index_post_revisions_on_post_id_and_number (post_id,number) +# diff --git a/app/models/top_topic.rb b/app/models/top_topic.rb index d55f22f1b..cf8858874 100644 --- a/app/models/top_topic.rb +++ b/app/models/top_topic.rb @@ -95,3 +95,43 @@ class TopTopic < ActiveRecord::Base end end + +# == Schema Information +# +# Table name: top_topics +# +# id :integer not null, primary key +# topic_id :integer +# yearly_posts_count :integer default(0), not null +# yearly_views_count :integer default(0), not null +# yearly_likes_count :integer default(0), not null +# monthly_posts_count :integer default(0), not null +# monthly_views_count :integer default(0), not null +# monthly_likes_count :integer default(0), not null +# weekly_posts_count :integer default(0), not null +# weekly_views_count :integer default(0), not null +# weekly_likes_count :integer default(0), not null +# daily_posts_count :integer default(0), not null +# daily_views_count :integer default(0), not null +# daily_likes_count :integer default(0), not null +# yearly_score :float +# monthly_score :float +# weekly_score :float +# daily_score :float +# +# Indexes +# +# index_top_topics_on_daily_likes_count (daily_likes_count) +# index_top_topics_on_daily_posts_count (daily_posts_count) +# index_top_topics_on_daily_views_count (daily_views_count) +# index_top_topics_on_monthly_likes_count (monthly_likes_count) +# index_top_topics_on_monthly_posts_count (monthly_posts_count) +# index_top_topics_on_monthly_views_count (monthly_views_count) +# index_top_topics_on_topic_id (topic_id) UNIQUE +# index_top_topics_on_weekly_likes_count (weekly_likes_count) +# index_top_topics_on_weekly_posts_count (weekly_posts_count) +# index_top_topics_on_weekly_views_count (weekly_views_count) +# index_top_topics_on_yearly_likes_count (yearly_likes_count) +# index_top_topics_on_yearly_posts_count (yearly_posts_count) +# index_top_topics_on_yearly_views_count (yearly_views_count) +# diff --git a/app/models/topic.rb b/app/models/topic.rb index bde22db0d..f084897dd 100644 --- a/app/models/topic.rb +++ b/app/models/topic.rb @@ -759,6 +759,7 @@ end # auto_close_started_at :datetime # deleted_by_id :integer # participant_count :integer default(1) +# word_count :integer # # Indexes # diff --git a/app/models/topic_embed.rb b/app/models/topic_embed.rb index 889abb726..99498db26 100644 --- a/app/models/topic_embed.rb +++ b/app/models/topic_embed.rb @@ -85,3 +85,20 @@ class TopicEmbed < ActiveRecord::Base end end + +# == Schema Information +# +# Table name: topic_embeds +# +# id :integer not null, primary key +# topic_id :integer not null +# post_id :integer not null +# embed_url :string(255) not null +# content_sha1 :string(40) not null +# created_at :datetime +# updated_at :datetime +# +# Indexes +# +# index_topic_embeds_on_embed_url (embed_url) UNIQUE +# diff --git a/app/models/topic_revision.rb b/app/models/topic_revision.rb index c8e7c12da..5190881e4 100644 --- a/app/models/topic_revision.rb +++ b/app/models/topic_revision.rb @@ -4,3 +4,21 @@ class TopicRevision < ActiveRecord::Base serialize :modifications, Hash end + +# == Schema Information +# +# Table name: topic_revisions +# +# id :integer not null, primary key +# user_id :integer +# topic_id :integer +# modifications :text +# number :integer +# created_at :datetime +# updated_at :datetime +# +# Indexes +# +# index_topic_revisions_on_topic_id (topic_id) +# index_topic_revisions_on_topic_id_and_number (topic_id,number) +# diff --git a/app/models/topic_user.rb b/app/models/topic_user.rb index ba64e2238..4e508c058 100644 --- a/app/models/topic_user.rb +++ b/app/models/topic_user.rb @@ -276,9 +276,9 @@ end # cleared_pinned_at :datetime # unstarred_at :datetime # id :integer not null, primary key +# last_emailed_post_number :integer # # Indexes # # index_forum_thread_users_on_forum_thread_id_and_user_id (topic_id,user_id) UNIQUE # - diff --git a/app/models/user.rb b/app/models/user.rb index bcef4f532..5d5c6b52a 100644 --- a/app/models/user.rb +++ b/app/models/user.rb @@ -680,7 +680,7 @@ end # flag_level :integer default(0), not null # ip_address :inet # new_topic_duration_minutes :integer -# external_links_in_new_tab :boolean default(FALSE), not null +# external_links_in_new_tab :boolean not null # enable_quoting :boolean default(TRUE), not null # moderator :boolean default(FALSE) # blocked :boolean default(FALSE) @@ -690,6 +690,7 @@ end # uploaded_avatar_template :string(255) # uploaded_avatar_id :integer # email_always :boolean default(FALSE), not null +# mailing_list_mode :boolean default(FALSE), not null # # Indexes # diff --git a/app/models/user_visit.rb b/app/models/user_visit.rb index 4683bd7be..6af6bf8ef 100644 --- a/app/models/user_visit.rb +++ b/app/models/user_visit.rb @@ -26,9 +26,9 @@ end # id :integer not null, primary key # user_id :integer not null # visited_at :date not null +# posts_read :integer default(0) # # Indexes # # index_user_visits_on_user_id_and_visited_at (user_id,visited_at) UNIQUE # -