<% if key_performance_indicators.any? %> ## Executive Summary <% key_performance_indicators.each do |kpi| %> <% end %>
KPI Maturity Health Reason(s)
<%= kpi.name %> <%= color_code_maturity(pi_maturity_level(kpi))%> <%= color_code_health kpi.health.level %>
    <% kpi.health.reasons.each do |reason| %>
  • <%= reason %>
  • <% end %>
<% end %> <% if key_performance_indicators.any? %> ## Key Performance Indicators <% key_performance_indicators.each do |kpi| %> <%= partial 'includes/performance_indicator', locals: { performance_indicator: kpi } %> <% end %> <% end %> <% if regular_performance_indicators.any? %> ## Regular Performance Indicators <% regular_performance_indicators.each do |rpi| %> <%= partial 'includes/performance_indicator', locals: { performance_indicator: rpi } %> <% end %> <% end %> ## Other PI Pages <%= partial 'includes/performance_indicator_links' %> ## Legends ### Maturity <%= partial 'includes/performance_indicator_maturities' %> ### Health | Level | Meaning | | ------|---------| | <%= color_code_health(3) %> | The KPI is at an acceptable level compared to the threshold | | <%= color_code_health(2) %> | This is a blip, or we’re going to watch it, or we just need to enact a proven intervention | | <%= color_code_health(1) %> | We'll prioritize our efforts here | | <%= color_code_health(0) %> | Unknown | ## How to work with pages like this ### Data The heart of pages like this is a data file called `/data/performance_indicators.yml` which is in [YAML](https://yaml.org/) format. Almost everything you need to do will involve edits to this file. Here are some tips: * Avoid `:` in strings as it's an important character in YAML and will confuse the data parsing process. Put the string in "quotes" if you really need to use a `:` * `urls:` should be an array (indented lines starting with dashes) even if you only have one url * Both `maturity.level` and `health.level` take a number between 0 and 3 (inclusive) Two flags to note: * `parent` can be used when a PI or KPI is a subset of another PI. For example, we might care about Hiring vs Plan at the company level. The child would be the division and department levels, which would have the parent flag. * `public` can be set to `false` where a PI or KPI meets our not public guidelines. ### Pages Pages like `/handbook/engineering/performance-indicators/` are rendered by and [ERB](https://en.wikipedia.org/wiki/ERuby) template. These ERB templates call the helper function `performance_indicators()` that is defined in `/helpers/custom_helpers.rb`. This helper function calls in several partial templates to do it's work. This function takes a required argument named `org` in string format that limits the scope of the page to a portion of the data file. Possible valid values for this `org` argument are listed in the `org` property of each element in the array in `/data/performance_indicators.yml`.