_performance_indicator.erb 2.95 KB
Newer Older
1
<%= performance_indicator.name %>
Eric Johnson's avatar
Eric Johnson committed
2

3 4 5 6 7

<% if performance_indicator.parent %>
   <p>This is a subset of an existing KPI. Please see <a href="<%=performance_indicator.parent=%>">the definition for the parent KPI.</a></p>
<% end %>

8
<p><%= performance_indicator.definition %></p>
Eric Johnson's avatar
Eric Johnson committed
9

Jerome Ng's avatar
Jerome Ng committed
10 11 12 13 14 15 16 17 18 19 20 21
<% if performance_indicator.plan_type %>
  <p><b>Free/Paid:</b> <%= performance_indicator.plan_type %></p>
<% end %>

<% if performance_indicator.telemetry_type %>
  <p><b>SaaS/SM:</b> <%= performance_indicator.telemetry_type %></p>
<% end %>

<% if performance_indicator.pi_workflow %>
  <p><b>PI Workflow:</b> <%= performance_indicator.pi_workflow %></p>
<% end %>

Eric Johnson's avatar
Eric Johnson committed
22 23 24
<% if performance_indicator.target %>
  <p><b>Target:</b> <%= performance_indicator.target %></p>
<% end %>
Jerome Ng's avatar
Jerome Ng committed
25 26 27 28 29 30 31 32

<% if performance_indicator.is_key %>
  <p><b>Is KPI:</b> <%= performance_indicator.is_key %></p>
<% end %>

<% if performance_indicator.is_primary %>
  <p><b>Is Primary PI:</b> <%= performance_indicator.is_primary %></p>
<% end %>
Eric Johnson's avatar
Eric Johnson committed
33

emilie's avatar
emilie committed
34
<% if performance_indicator.public == false %>
emilie's avatar
emilie committed
35
  <p><b>This KPI cannot be public.</b> </p>
emilie's avatar
emilie committed
36 37
<% end %>

38 39 40 41 42
<% if performance_indicator.urls %>
  <b>URL(s)</b>
  <ul>
  <% performance_indicator.urls.each do |url| %>
    <li><a href="<%= url %>"><%= url %></a></li>
Kathleen Tam's avatar
Kathleen Tam committed
43
  <% end %>
44
  </ul>
45 46
<% end %>

47
<% if performance_indicator.sisense_data %>
emilie's avatar
emilie committed
48 49 50 51 52 53
  <b>Chart</b>
    <% if performance_indicator.sisense_data.shared_dashboard%>
      (<a href="https://app.periscopedata.com/shared/<%= performance_indicator.sisense_data.shared_dashboard %>">Sisense↗</a>)
    <% elsif performance_indicator.sisense_data.chart && performance_indicator.sisense_data.dashboard%>
      (<a href="https://app.periscopedata.com/app/gitlab/<%= performance_indicator.sisense_data.dashboard %>/?widget=<%= performance_indicator.sisense_data.chart %>">Sisense↗</a>)
    <% end %>
54
  <% if ENV['PERISCOPE_EMBED_API_KEY'] %>
emilie's avatar
emilie committed
55
    <embed width="100%" height="100%" style="min-height:300px;" src="<%= signed_periscope_url(performance_indicator.sisense_data) %>">
56
  <% else %>
emilie's avatar
emilie committed
57
    <p>You must set a <code>PERISCOPE_EMBED_API_KEY</code> environment variable to render this chart.</p>
58
  <% end %>
59 60
<% end %>

61
<b>Status: <%= color_code_health(performance_indicator.health.level) %></b>
62

63
<% performance_indicator.health.reasons.each do |reason| %>
64
<%="  * #{reason}"%>
Eric Johnson's avatar
Eric Johnson committed
65
<% end %>
66

67

68
<% if performance_indicator.instrumentation %>
69 70 71 72
<b>Instrumentation: <%= color_code_instrumentation(performance_indicator.instrumentation.level) %></b>

<% performance_indicator.instrumentation.reasons.each do |reason| %>
<%="  * #{reason}"%>
73
<% end %>
David DeSanto's avatar
David DeSanto committed
74
<% end %>
75

76

77
<% if performance_indicator.lessons %>
David DeSanto's avatar
David DeSanto committed
78
<b>Lessons Learned (<%= Date::MONTHNAMES[Date.today.prev_month.month] %>):</b>
79

80
<% performance_indicator.lessons.learned.each do |reason| %>
81 82
<%="  * #{reason}"%>
<% end %>
David DeSanto's avatar
David DeSanto committed
83
<% end %>
84 85


86
<% if performance_indicator.monthly_focus %>
David DeSanto's avatar
David DeSanto committed
87
<b>Focus This Month (<%= Date::MONTHNAMES[Date.today.month] %>):</b>
88

89
<% performance_indicator.monthly_focus.goals.each do |reason| %>
90
<%="  * #{reason}"%>
David DeSanto's avatar
David DeSanto committed
91 92
<% end %>
<% end %>