diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-03-06 21:08:08 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-03-06 21:08:08 +0300 |
commit | 83731155d997ae24c7e0cd5ffa6f0dba41bec6dc (patch) | |
tree | 31f785012137fda4ac9a470f4f07c961b42d0299 /lib/gitlab/background_migration | |
parent | 57a37ce99f297cddae12cb4d982b6d572f932bb4 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'lib/gitlab/background_migration')
-rw-r--r-- | lib/gitlab/background_migration/user_mentions/models/snippet.rb | 43 | ||||
-rw-r--r-- | lib/gitlab/background_migration/user_mentions/models/snippet_user_mention.rb | 18 |
2 files changed, 0 insertions, 61 deletions
diff --git a/lib/gitlab/background_migration/user_mentions/models/snippet.rb b/lib/gitlab/background_migration/user_mentions/models/snippet.rb deleted file mode 100644 index cdbada76429..00000000000 --- a/lib/gitlab/background_migration/user_mentions/models/snippet.rb +++ /dev/null @@ -1,43 +0,0 @@ -# frozen_string_literal: true -# rubocop:disable Style/Documentation - -module Gitlab - module BackgroundMigration - module UserMentions - module Models - class Snippet < ActiveRecord::Base - include Concerns::IsolatedMentionable - include Concerns::MentionableMigrationMethods - include CacheMarkdownField - - attr_mentionable :title, pipeline: :single_line - attr_mentionable :description - cache_markdown_field :title, pipeline: :single_line - cache_markdown_field :description - - self.table_name = 'snippets' - self.inheritance_column = :_type_disabled - - belongs_to :author, class_name: "User" - belongs_to :project - - def self.user_mention_model - Gitlab::BackgroundMigration::UserMentions::Models::SnippetUserMention - end - - def user_mention_model - self.class.user_mention_model - end - - def user_mention_resource_id - id - end - - def user_mention_note_id - 'NULL' - end - end - end - end - end -end diff --git a/lib/gitlab/background_migration/user_mentions/models/snippet_user_mention.rb b/lib/gitlab/background_migration/user_mentions/models/snippet_user_mention.rb deleted file mode 100644 index a856a53626e..00000000000 --- a/lib/gitlab/background_migration/user_mentions/models/snippet_user_mention.rb +++ /dev/null @@ -1,18 +0,0 @@ -# frozen_string_literal: true -# rubocop:disable Style/Documentation - -module Gitlab - module BackgroundMigration - module UserMentions - module Models - class SnippetUserMention < ActiveRecord::Base - self.table_name = 'snippet_user_mentions' - - def self.resource_foreign_key - :snippet_id - end - end - end - end - end -end |