What is referencing or @-mentioning in BRYTER?
Referencing is a commonly used technique to transfer values from one node to another. For example, let's say you want to use the user's response to a node in the content of another node. You can do this by referencing that first node which "stores" the value of the user's response.
How does referencing work?
The variable browser or 'picker' as displayed below helps to find the relevant value you want to reference easier and quicker. The variable picker opens after selecting "@ value" in the insert dropdown or typing the "@" symbol into any content field in the editor.
The icons represent the various node types. You can search for the relevant value in the search bar of the value picker. The value picker will automatically filter all available values and display only those containing the search term.
Example use cases
Use a previously entered name
Let's say you want to create a question that includes the name of your user's company. After all, this adds a personalized touch. Previously in your module, you asked your user to enter the company's name as a response to a particular node. You can then reference the node which contains the previously entered name when you build your question.
Add clauses to a Word document
Let's say you want to generate a contract. This contract contains a clause from the Textblock actions in your module. Each Textblock action represents a different clause and based on the user response, you can decide which clauses to include in your contract. In this case, you can reference your Textblock action in your Word document template. Note that since you're implementing referencing in a template, you have to use curly brackets " {{ }} ". Inside these brackets, include the name of your Textblock actions, such as {{Placeholder1}}, {{clause two}}, etc. to find them easier when mapping the values to the placeholders in the Create Document Action.
Procedure
There are two places you can use referencing: in your BRYTER module and in Word document (DOCX) templates you upload to your BRYTER module. The two processes are a bit different. Follow the steps below to learn how to use @-referencing in your module as well as in a Word document.
Referencing in your module
To use referencing in your module, follow the directions below.
- From the text input area of the desired node, simply type in " @ ".
- Once you start typing, a list of possible nodes or actions you can reference will appear.
- Click on the appropriate node or action from the dropdown menu.
Note that it is important to give your nodes and actions recognizable names. This way, you can easily select the appropriate node when you reference them. Note also that referencing is case-sensitive.
For example, if you want to reference the volume of transactions that are stored in a Number node named "Volume of transaction", you have to reference it like this: @Volume of transaction. The referenced node will be replaced by the number from the Number node.
Referencing other places
You can reference values in basically any place including hyperlinks, answer options, and conditions. Follow the same procedure as described above.
Referencing in Word documents
Referencing in a Word document is a bit different from referencing in your module.
To reference a node, use the curly brackets "{{ }}". Inside of the curly brackets, type the name of the node or a generic term so you can later map the relevant.
For example, if you want to reference the volume of transactions which is stored in a Number node named "Volume of transaction", you have to reference it like this: {{Volume of transaction}}. The referenced node in the curly brackets will be replaced by the number from the Number node once you map it into the placeholder (BRYTER can do this automatically if the placeholder and the value names match exactly) that appears in your Create Document action node. Find out more about document generation here.
Keywords: {}; {{}}; brakets; {{; }};