Last updated Dec 11, 2024

Use custom fields with scorecards

You can use scorecards to set policies on custom field values that are important for tracking and measuring component health. It’s possible to use custom fields as criteria when building scorecards, allowing you to construct precisely the policy you require.

A custom field becomes available to add to a scorecard criterion when its component type matches that of the scorecard. The custom field criterion, along with any other criteria defined in the scorecard, appears on the scorecard on relevant components. The value in the custom field on the component determines whether the scorecard criterion is met or unmet for that component.

Add a custom field as a scorecard criterion

Before you begin

  • If your site uses a restricted permission policy, you must be the owner of the scorecard you're changing or a product admin.

You can add a custom field as a scorecard criterion when its component type(s) match that of the scorecard.

Before you begin, make sure the custom field is available on your Compass site, and its component type matches with the scorecard’s component type. If you don’t see the custom field you expect, create a new one or edit an existing one to match the component type. Learn how to create or edit custom fields

To add a custom field as a scorecard criterion:

  1. Create a new scorecard or edit an existing one.

  2. Fill in the required scorecard details or make any desired changes to the existing scorecard you selected. Learn more about creating and managing scorecards

  3. When you’re on the page to select the scorecard criterion:

    • In the Criterion type menu, select Field.

    • In the Field menu, find and select the custom field you want to add as a criterion.

  4. Depending on the custom field’s type, select additional values:

    • for a number custom field, select a numerical operator and enter a corresponding value

    • for a checkbox custom field, select a value True or False

    • for a text custom field, you don’t need to select any additional value

  5. Add or remove any additional criterion and adjust the weight percentages.

  6. Select Save.

The custom field scorecard criterion applies to relevant components as per the scorecard’s settings. The component’s custom field value determines whether the scorecard criterion is met or unmet, adding up to the scorecard’s score.

Different custom field types as scorecard criteria

Each custom field's type enables you to construct the scorecard criterion differently:

  • Text custom field — The criterion checks for the presence of a value in a component’s custom field. The criterion is met when a value exists in the component's custom field, or else it is unmet.

  • Number custom field — The criterion defines a threshold the custom field value must fall over, under, equal, or not equal to in order to be met. The threshold is defined in the scorecard criterion and doesn’t appear on the component’s custom field. The scorecard checks the value you enter in the component's custom field. If it satisfies the threshold condition, the criterion is met, or else it is unmet.

  • Checkbox custom field — The criterion compares the state of the checkbox (True if selected and False if unselected) on the component to the value (True or False) specified in the scorecard. The criterion is met when the value matches, or else it is unmet.

  • Dropdown custom field - The criterion compares the state of the custom field on the component to the value(s) specified in the scorecard, based on the comparator. The criterion is met when the comparator is true, or else is it unmet.

The user custom field isn't available to use with scorecards yet. We're working to add this feature soon.

Rate this page: