Home  >   Using Vtiger   >  Creating Custom Print Templates

Creating Custom Print Templates

Different functions that are available in Vtiger CRM for creating custom print templates.
B
Bindu Rekha Babu
12 Jul, 2022 - Updated 2 years ago
Table of Contents

Introduction

You can use Custom Functions in the Print Templates feature to insert function merge tags. Function merge tags help you perform specific actions based on the parameters specified.

Adding Custom Functions in Print Templates

You can add the following list of essential functions: 

  1. IF function
  2. NOT EMPTY Function
  3. EMPTY Function
  4. Expressions
 

Now let’s discuss each function broadly.

  1. IF function: The if function is a conventional if-else statement in programming in which we compare one value with other.
    merge-tag : #CF|IF|param1|param2|operator|return1|return2|CF#
    1. param1, param2 : Parameters to compare. The values should be any of (A-Z, a-z, 0-9).
    2. operator : Operator to compare parameters. The value should be of any (<,>,<=,>=,!=, ==).
    3. return1 : Return value, if the comparison is true.
    4. return2 : Return value, if the comparison is false.
  2. NOT EMPTY Function: This function checks if the value is non-empty or not.
    merge-tag : #CF|NOTEMPTY|param|return1|return2|CF#
    1. param : Value to check for non-emptiness.
    2. return1 : Value to return “if value” is not empty(True condition)
    3. return2 : Value to return “if value” is empty(False condition)
  3. EMPTY Function: This function is the reverse of above function(NOT EMPTY).
    merge-tag : #CF|EMPTY|param|return1|return2|CF#
    1. param : value to check non-emptiness.
    2. return1 : Value to return “if value” if empty(True condition)
    3. return2 : Value to return “if value” is non-empty(False condition)
  4. Expressions: Computes values while generating PDF by adding expressions in Print Templates.
    merge-tag : #CF|EXPRESSION|({param1}(arithmetic operator){|param2})|CF#
    1. param1, param2: Parameters to compare. The values should be any of (0-9).
    2. arithmetic operator: Arithmetic operators such as +,-,/,* and %.
Was this article helpful?
0  out of  3  found this helpful.
Comments 0
Be the first to comment
© Copyright 2023 Vtiger. All rights reserved.