1
|
module ForemanPipeline
|
2
|
class JenkinsProject < Katello::Model
|
3
|
self.include_root_in_json = false
|
4
|
|
5
|
include Katello::Glue
|
6
|
include Glue::ElasticSearch::JenkinsProject
|
7
|
include ForemanPipeline::Authorization::JenkinsProject
|
8
|
|
9
|
belongs_to :organization
|
10
|
|
11
|
has_many :job_jenkins_projects, :dependent => :destroy
|
12
|
has_many :jobs, :through => :job_jenkins_projects, :class_name => 'ForemanPipeline::Job'
|
13
|
|
14
|
has_many :jenkins_project_params, :class_name => 'ForemanPipeline::JenkinsProjectParam', :dependent => :destroy
|
15
|
|
16
|
accepts_nested_attributes_for :jenkins_project_params
|
17
|
end
|
18
|
end
|