_performance_indicator.erb 3.89 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 %>

Jerome Ng's avatar
Jerome Ng committed
61 62 63 64 65 66 67 68 69 70 71 72 73 74 75
<% if performance_indicator.sisense_data_secondary %>
  <b>Secondary Chart</b>
    <% if performance_indicator.sisense_data_secondary.shared_dashboard%>
      (<a href="https://app.periscopedata.com/shared/<%= performance_indicator.sisense_data_secondary.shared_dashboard %>">Sisense↗</a>)
    <% elsif performance_indicator.sisense_data_secondary.chart && performance_indicator.sisense_data_secondary.dashboard%>
      (<a href="https://app.periscopedata.com/app/gitlab/<%= performance_indicator.sisense_data_secondary.dashboard %>/?widget=<%= performance_indicator.sisense_data_secondary.chart %>">Sisense↗</a>)
    <% end %>
  <% if ENV['PERISCOPE_EMBED_API_KEY'] %>
    <embed width="100%" height="100%" style="min-height:300px;" src="<%= signed_periscope_url(performance_indicator.sisense_data_secondary) %>">
  <% else %>
    <p>You must set a <code>PERISCOPE_EMBED_API_KEY</code> environment variable to render this chart.</p>
  <% end %>
<% end %>

<b>Health: <%= color_code_health(performance_indicator.health.level) %></b>
76

77
<% performance_indicator.health.reasons.each do |reason| %>
78
<%="  * #{reason}"%>
Eric Johnson's avatar
Eric Johnson committed
79
<% end %>
80

81

82
<% if performance_indicator.instrumentation %>
83 84 85 86
<b>Instrumentation: <%= color_code_instrumentation(performance_indicator.instrumentation.level) %></b>

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

90

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

94
<% performance_indicator.lessons.learned.each do |reason| %>
95 96
<%="  * #{reason}"%>
<% end %>
David DeSanto's avatar
David DeSanto committed
97
<% end %>
98 99


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

103
<% performance_indicator.monthly_focus.goals.each do |reason| %>
104
<%="  * #{reason}"%>
David DeSanto's avatar
David DeSanto committed
105 106
<% end %>
<% end %>