mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
FEATURE: show the user's flagged/deleted posts
This commit is contained in:
@@ -23,6 +23,7 @@ class Post < ActiveRecord::Base
|
||||
|
||||
belongs_to :user
|
||||
belongs_to :topic, counter_cache: :posts_count
|
||||
|
||||
belongs_to :reply_to_user, class_name: "User"
|
||||
|
||||
has_many :post_replies
|
||||
@@ -40,6 +41,8 @@ class Post < ActiveRecord::Base
|
||||
has_many :post_revisions
|
||||
has_many :revisions, foreign_key: :post_id, class_name: 'PostRevision'
|
||||
|
||||
has_many :user_actions, foreign_key: :target_post_id
|
||||
|
||||
validates_with ::Validators::PostValidator
|
||||
|
||||
# We can pass several creating options to a post via attributes
|
||||
|
||||
Reference in New Issue
Block a user