debian-mirror-gitlab/app/models/ci/application_record.rb
2023-04-23 21:23:45 +05:30

19 lines
396 B
Ruby

# frozen_string_literal: true
module Ci
class ApplicationRecord < ::ApplicationRecord
self.abstract_class = true
if Gitlab::Database.has_config?(:ci)
connects_to database: { writing: :ci, reading: :ci }
end
def self.table_name_prefix
'ci_'
end
def self.model_name
@model_name ||= ActiveModel::Name.new(self, nil, name.demodulize)
end
end
end