Knowledge Base

Dynamic Link Fields

  • 86views
  • February 7, 2024

Dynamic Link Fields

Below are the steps to insert Custom Dynamic Field. For instance, we will insert Dynamic Link Field in Journal Entry.

First, we’ll establish a link field that will be associated with the specified DocType.

When we refer to the “DocType” mentioned in the Option field, we are referring to the parent DocType. For instance, consider “Quotation” as a DocType, which may have multiple Quotation records associated with it. Similarly, “DocType” itself is a DocType that encompasses records like Sales Order, Purchase Order, and other related documents.

DocType
—- Sales Order
—- Purchase Invoice
—- Quotation
—- Sales Invoice
—- Employee
—- Work Order
.. and so on.

So linking this field with parent DocType will list all the DocType records.

This custom field will be of type “Dynamic Link.” The Option field will specify the name of the linked DocType field.

With this field, you can select a document ID based on the value chosen in the linked DocType field. For instance, if “Sales Order” is selected in the preceding field, the Dynamic Link field will display all the IDs of Sales Orders.

Customizing options in the Doctype Link field

By default, the DocType link field will provide all the forms/docTypes for selection. If you wish this field to show certain specific docTypes in the search result, you will need to write Custom Script for it.