diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-05-07 15:09:46 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-05-07 15:09:46 +0300 |
commit | 896b68514b43b9646d763e67f63fbe8f9ef2f723 (patch) | |
tree | b0b21f37cbbc809782532e6d6180677c7c4c9e30 /app/models/resource_milestone_event.rb | |
parent | d8803c7e40bd35d883ef007ddc56907bd837a748 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/models/resource_milestone_event.rb')
-rw-r--r-- | app/models/resource_milestone_event.rb | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/app/models/resource_milestone_event.rb b/app/models/resource_milestone_event.rb index a0655c3a4ab..039f26d8e3f 100644 --- a/app/models/resource_milestone_event.rb +++ b/app/models/resource_milestone_event.rb @@ -2,14 +2,11 @@ class ResourceMilestoneEvent < ResourceEvent include IgnorableColumns + include IssueResourceEvent + include MergeRequestResourceEvent - belongs_to :issue - belongs_to :merge_request belongs_to :milestone - scope :by_issue, ->(issue) { where(issue_id: issue.id) } - scope :by_merge_request, ->(merge_request) { where(merge_request_id: merge_request.id) } - validate :exactly_one_issuable enum action: { |