Templates Nesting
  • 20 Nov 2023
  • 1 Minute to read
  • PDF

Templates Nesting

  • PDF

Article Summary

N3uron allows users to set up templates nesting, whereby one template is placed inside another. The template is nested as an instance within another template. This facilitates quicker development of projects, since you're able to piece together multiple template definitions as needed, without having to build everything from the ground up, as with each template definition. This is particularly useful as it promotes rapid development, especially if you are expanding a plant or facility where all you have to do is make a few tag changes to existing custom properties and settings.

For example, you may have a power plant that is built out of several different cabins. In this case, you don't need to re-create an inverter for each cabin, instead, you can simply create it once and use it in every cabin.

In the following example, let's use the inverter and tracker templates. We are going to create a third template called cabin, that will contain the inverter and tracker templates. 

  • Step 1: Click on the menu on the left-hand side of the Templates header, select New Group->Group, and enter a name for the template (in this example Cabin).
  • Step 2: Inside the Cabin template, create two new instances, one for Inverter and the other for Tracker.
    • Click on the ellipsis button, on the right-hand side of the Tags label, select New Group->Inverter, and enter a name (in this example Inverter1). You can repeat this step in case you need to add more than one inverter to the cabin template.
    • Click on the ellipsis button, on the right-hand side of the Tags label, select New Group->Tracker, and enter a name (in this example Tracker1). You can repeat this step whenever you need to add more than one tracker to the cabin template.

Figure 20 - New Cabin Template(2)Figure 20. New Cabin Template

 

  • Step 3: For every template that you add within another template, these template instances have custom properties that need to be specified. In this example, the Inverter Template has the Inverter Number custom property and the Tracker Template has the TrackerNumber custom property as well as the scan_rate property. You must pass a value into each of these templates (Inverter and Tracker) from the parent template (Cabin). To view the custom properties for each template instance, select each template instance (Inverter and Tracker), and expand them.
  • Step 4: Now we are going to pass the values of the Cabin's custom properties to the nested instances by adding the corresponding references, as shown in the image below.

Figure 21- Referencing Custom PropertiesFigure 21. Referencing Custom Properties

 


Was this article helpful?