Project

General

Profile

Revision abf1341e

Added by Ondřej Pražák almost 8 years ago

working widgets

View differences:

app/views/foreman_pipeline/api/environments/show.json.rabl
6 6

  
7 7
extends 'katello/api/v2/common/timestamps'
8 8

  
9
node :prior do |env|
10
  if env.prior
11
    {name: env.prior.name, :id => env.prior.id}
12
  end
13
end
14

  
15
node :successor do |env|
16
  if !env.library && env.successor
17
    {name: env.successor.name, :id => env.successor.id}
18
  end
9
child :successors => :successors do |env|
10
  attributes :name, :id, :label, :library
19 11
end

Also available in: Unified diff