Skip to content
  • There are no suggestions because the search field is empty.

How to Set Up Dependencies for Custom Fields

Automate filling out custom fields and ensure the entered data is correct with the help of dependencies.

TABLE OF CONTENTS

When to Use Custom Field Dependencies

Custom field dependencies allow you to set up dynamic connections between different custom fields. You can filter choices in one field based on what's selected in another, helping guide users through complex forms. It's a simple way to keep data relevant, accurate, and easy to enter.

A dependency is established for the options of two fields:

  • The controlling field
  • The dependent field

The controlling field's values determine the dependent field's available options.

A picture explaining which field is dependent and which is controlling in an established dependency

Setting up dependencies will help you:

  • Speed up document creation and minimize mistakes by only suggesting relevant options.
  • Automatically fill out fields if only one option is available based on other choices.
  • Fill out custom item fields that mirror document-level fields.

How to Create Custom Field Dependencies

In Precoro, you can create two types of dependencies:

  • Custom document field that depends on another custom document field;
  • Custom item field that depends on a custom document field.

You can create dependencies for fields with the Drop-down list type, as they are set up for existing options.

Learn how to set up custom fields in these articles: How to Create and Manage Custom Fields for Items and How to Create and Manage Custom Fields for Documents.

Step 1: Choose a Dependent Field and Option

Go to the Configuration page, open the Custom Fields for Items or Custom Fields for Documents tab, and open the field you want to set as dependent.

To start establishing a dependency, select an option and click the Edit button (pencil icon), which opens the editing sidebar.

Step 2: Select Controlling Fields

In the Dependencies section, click Add to create a new dependency. You will see the list of custom fields for documents that are active and required to select in documents. Check the ones you want to set as controlling fields.

Please note: If you add multiple dependencies to a custom field option, the AND rule applies. The option will appear in the document only if you’ve selected one of the allowed values in each controlling field. If even one controlling field doesn’t match, the option will not be shown.

An image showing how to correctly fill out the controlling fields when two dependencies are created for one dependent field's option

Step 3: Select Options for the Dependencies and Save

For each controlling field, you will see a drop-down menu with available options.

Choose the options that should trigger the dependent field’s option to appear. You can select one or more.

Once ready, click Save to confirm the changes.

Step 4: Add Dependencies for All Limited Options

You can create dependencies for as many options of this field as necessary. If there are options without configured dependencies, they will be available regardless of other fields’ values.

 

 

💡Pro tip: With dependencies, you can automate filling out item fields that duplicate document fields. Here’s how you can do so:

  1. Ensure you have a custom document field and a custom item field with identical or corresponding options.
  2. Open the custom item field editing page.
  3. For every option, add a dependency on the corresponding option of the custom document field.
  4. When creating a document, select the necessary value in the document field. When you add items, the dependent field will only have one available option, speeding up your work.
  5. If you edit the controlling document field, the values of the dependent field in items will automatically adjust.

How to Manage Fields with Established Dependencies

Viewing Dependencies in Option Lists 

When you edit a dependent field, there are two ways the dependencies are displayed in the option list:

  1. Next to each sub-option, you’ll see which selections in the controlling fields make it appear.
  2. Next to the main options, you’ll see how many dependencies are set up in sub-options.

For instance, if sub-options are dependent on the same field and enabled by different options, you will see the structure displayed in the screenshot below. If you configure dependencies on two fields, the highlighted marker will show “2 dependencies”.

A screenshot highlighting the parent option if children are dependent on one field

Adding Dependencies to Sub-Options

To add the same dependencies to all sub-options under one parent option, just set the dependency for the parent. It will apply to all current and future sub-options.

After that, you can change the dependencies for each sub-option without changing the parent.

Deactivating Fields with Established Dependencies

If you deactivate an option of a controlling field, the options that depend on it become available regardless of the controlling field’s value.

If you deactivate a dependent field’s option, the dependency is saved and will be enabled if you reactivate the option.

For example, a dependency can be configured between two fields: Admin-required (dependent custom item field) and Departments (controlling custom document field). The Yes option in the Admin-required field can only be selected in items if the Administration department is selected for the document; otherwise, you can choose only No.

If you deactivate the Administration option, the dependency will be deleted, making the Yes option in the Admin-required field available for any department.

How to Fill Out Fields with Established Dependencies

Custom Document Fields

When creating a document, you will see a prompt to select the controlling field’s values before you can fill out the dependent fields. 

Once you fill out the controlling fields, select from the options available in the dependent fields. If only one option fits the criteria, it will be entered automatically.

If you change the value of a controlling field, the dependent field will be cleared, allowing you to select newly available options.

Custom Item Fields

If you make a custom item field dependent on a custom document field, you will only see filtered options when editing the items added to the document. Limiting options will help you enter item details faster and more correctly.

If you edit the controlling document field after adding the items, the dependent fields’ values will be highlighted in red, signaling that you need to select a new option.