DEV: Automatically annotate plugin models alongside core models
This commit is contained in:
parent
fb1da53dff
commit
5605dba85c
|
@ -15,7 +15,7 @@ if (Rails.env.development? || Rails.env.test?)
|
|||
'position_in_factory' => "before",
|
||||
'show_indexes' => "true",
|
||||
'simple_indexes' => "false",
|
||||
'model_dir' => "app/models",
|
||||
'model_dir' => ["app/models"] + Dir.glob("plugins/**/app/models"),
|
||||
'include_version' => "false",
|
||||
'require' => "",
|
||||
'exclude_tests' => "true",
|
||||
|
|
|
@ -56,8 +56,8 @@ end
|
|||
#
|
||||
# Table name: polls
|
||||
#
|
||||
# id :bigint(8) not null, primary key
|
||||
# post_id :bigint(8)
|
||||
# id :bigint not null, primary key
|
||||
# post_id :bigint
|
||||
# name :string default("poll"), not null
|
||||
# close_at :datetime
|
||||
# type :integer default("regular"), not null
|
||||
|
@ -76,3 +76,7 @@ end
|
|||
# index_polls_on_post_id (post_id)
|
||||
# index_polls_on_post_id_and_name (post_id,name) UNIQUE
|
||||
#
|
||||
# Foreign Keys
|
||||
#
|
||||
# fk_rails_... (post_id => posts.id)
|
||||
#
|
||||
|
|
|
@ -9,8 +9,8 @@ end
|
|||
#
|
||||
# Table name: poll_options
|
||||
#
|
||||
# id :bigint(8) not null, primary key
|
||||
# poll_id :bigint(8)
|
||||
# id :bigint not null, primary key
|
||||
# poll_id :bigint
|
||||
# digest :string not null
|
||||
# html :text not null
|
||||
# anonymous_votes :integer
|
||||
|
@ -22,3 +22,7 @@ end
|
|||
# index_poll_options_on_poll_id (poll_id)
|
||||
# index_poll_options_on_poll_id_and_digest (poll_id,digest) UNIQUE
|
||||
#
|
||||
# Foreign Keys
|
||||
#
|
||||
# fk_rails_... (poll_id => polls.id)
|
||||
#
|
||||
|
|
|
@ -10,9 +10,9 @@ end
|
|||
#
|
||||
# Table name: poll_votes
|
||||
#
|
||||
# poll_id :bigint(8)
|
||||
# poll_option_id :bigint(8)
|
||||
# user_id :bigint(8)
|
||||
# poll_id :bigint
|
||||
# poll_option_id :bigint
|
||||
# user_id :bigint
|
||||
# created_at :datetime not null
|
||||
# updated_at :datetime not null
|
||||
#
|
||||
|
@ -23,3 +23,9 @@ end
|
|||
# index_poll_votes_on_poll_option_id (poll_option_id)
|
||||
# index_poll_votes_on_user_id (user_id)
|
||||
#
|
||||
# Foreign Keys
|
||||
#
|
||||
# fk_rails_... (poll_id => polls.id)
|
||||
# fk_rails_... (poll_option_id => poll_options.id)
|
||||
# fk_rails_... (user_id => users.id)
|
||||
#
|
||||
|
|
Loading…
Reference in New Issue