Articles in this section
Authenticate Emails with SPF, DKIM, and SenderID Auto-forwarding your emails to Vtiger Automate Outgoing Emails in Email Settings Automation - Approvals Automation - Assignment Rules Automation - Multi-path Workflows Automation - Scheduled Workflows Automation - Scheduler Automation - Standard Workflows Automation - Webforms Automation - Workflow Action - Create Event Automation - Workflow Action - Create Records Automation - Workflow Action - Create Task Automation - Workflow Action - SMS Task Automation - Workflow Action - Send Mail Automation - Workflow Action - Update Fields Automation - Workflow Action - Webhook Automation - Workflows - Vtiger Expressions Configuration - Business Hours Configuration - Company Details Configuration - Consents Configuration - Customer Portal Configuration - Maps Configuration - Usage Details Configure Encrypted data fields in Vtiger CRM Configure Picklist Dependencies Considerations for Deactivating Vtiger Users Control Fields and Record Displays using Configuration Editor Create Reminders for Records and Inbox Create a field of a Grid type Customize your self-service portal theme using CSS styles Dealing with Currencies and Taxes Enable Desktop Notifications on Chrome Web Browsers Extensions - Extension Store IMAP Configuration - 2-way sync between Vtiger and IMAP providers Inventory - Payments and Subscriptions Inventory - Tax Management Inventory - Terms and Conditions Login to Vtiger on SSO SAML using ADFS Mailroom Functionality in Different Scenarios Manage Multiple Currencies Marketing & Sales - Forecast and Quota Settings Marketing & Sales - Pipelines and Stages Marketing and Sales - Deal to Project Mapping Marketing and Sales - Lead Conversion Data Mapping Marketing and Sales - Profile Scoring Module Management - Labels Editor Module Management - Module Numbering My Preferences My Preferences - Calendar Settings My Preferences - My Tags My Preferences - Notification Preferences SAML Support in Vtiger CRM Set up Mailroom Settings - Configure Module Settings Settings - Create Dynamic Fields and Layouts Module Management - Creating a Relationship Between Modules Settings - Customize Records and Fields for your Business Settings - How to set email autoresponder to Webform submission? Settings - Left Menu Settings - Manage Global Picklists in Vtiger Settings - Set up your Support Team Settings - Start Up Page Settings - Working with Picklist Values Module Management - Module Builder Support - SLA Policies Troubleshooting Login Issues Unsubscribe your Email User Management - Authentication User Management - Encrypted Field Access Logs User Management - Groups User Management - Login History User Management - Profiles User Management - Roles User Management - Settings Log User Management - Sharing Rules User Management - Users User Management - Vtiger Support Access Vtiger Buzz - Chrome Extension for Notifications Vtiger Implementation wizard Vtiger Language Support Websense - Trackers Websense - Widgets Configuration - Storage Guard Adding a local DNS Entry Adding Additional Hidden Fields to a Webform Configuring Dependent Fields and Blocks for Modules Duplicate Prevention in Modules Module Management - Modules Module Management - Module Layouts & Fields

Automation - Workflow Action - Invoke Custom Function

Sabqat Ruba
9 Mar, 2021 - Updated 6 months ago

Invoke Custom Function - A Workflow Action

The Workflows module provides you a simple interface to add custom actions that execute on saving an entity.


Vtiger has a Custom Task function of entity method tasks that calls certain methods on Vtiger entity objects. Custom Tasks provides a way for developers to add custom actions to workflows. Let us walk through creating a Custom Task.


For example, if you want to compute natural Math Log as a custom operation, then first we need to register a method that will perform the operation. The method needs an operation name, file path (can be anywhere, even in a custom module), and a function name.


Let’s say you have a custom module called Deals. You can register a method in the postinstall event(vtlib_handler API of Deals.php file) of the module. The event is triggered after the module is installed. 


For more details on how to write a module, click here.


Note: We have taken the example of the Deals module only for better understanding. Deals is a default Vtiger module and is available in the Sales and All-in-one editions. To learn about Deals, click here.


Setting up the workflow

Follow these steps to set up the workflow with a custom function:

Accessing the workflow page:

  1. Click the User Menu on the top right corner of the screen
  2. Click the Settings button
  3. Look for the Automation section
  4. Select Workflows
  5. Click the +New Workflow button
  6. Select Standard

Entering the basic information:

  1. Select the Target Module 
  2. Enter workflow name, status, etc

Select the workflow trigger:

  1. Select the Workflow Trigger

Set up the workflow entry criteria:

  1. Click the +Add Condition button
  2. Enter the condition that must satisfy for the workflow to execute

Note: To learn about the basic information, trigger, entry criteria, click here.


Set up the action:

  1. Click the Add Action drop-down
  2. Select Invoke Custom Function
    • This opens a window where you must enter the Action Title
  3. Enter the Action Title
  4. Click Save to save the action
  5. Click Save to save the workflow

Home Privacy Policy Terms of Service Security Center Policy & Legal Center Contact Us
© Copyright 2021 Vtiger. All rights reserved.
Powered by Vtiger
Facebook Twitter Linkedin Youtube