Kaizen #63 - Layout Rules in Zoho CRM

Kaizen #63 - Layout Rules in Zoho CRM

Hello and welcome to another week of Kaizen!

This week, we will be discussing Layout Rules in Zoho CRM.
If you need to modify the layout of a module based on user inputs, or to show or hide sections based on the value of a specific field, we have got just the perfect solution for you.

What is a Page Layout?

In simple terms, a page layout is a template where you can add, choose and arrange the fields and sections that will be displayed in a module. Depending on your application requirement, you can either edit the standard layout, or create custom layouts.

What are Layout Rules and why you need them?

Layout rules are a set of criteria that you define to modify the layout of a module. These rules help you keep your layouts clean and clutter-free. Often, you may need to set up dynamic layouts, where the value selected for one field determines the subsequent sections and fields. 
For example, in an automobile rental company, the field requirements for a two-wheeler will differ from the ones for a car. By using layout rules, you can display only the relevant sections and fields based on the type of vehicle being rented. This article will use an automobile rental company as an example to explain Layout Rules.

Who can access Layout Rules feature?

Only users with permission to Customize Zoho CRM profile can access this feature.

How and when are Layout rules triggered?

You can trigger the rule when the chosen primary field meets one of the following conditions.
  • is
  • isn't
  • contains
  • doesn't contain
  • starts with
  • ends with
  • is empty
  • is not empty
You can trigger the following actions when the criteria are met:
  • Show Fields - To show specific fields. For example, show the Number of Helmets field only if the Helmets Required is YES.
  • Show Sections - To show specific sections. For example, display the Four wheeler section only if the vehicle type is Four wheeler. 
  • Set Mandatory Fields - To set specific fields mandatory. For instance, make the car type field mandatory if the vehicle type is Four wheeler.
  • Show Subforms - To show specific subforms. For example, to show the Accessories Required only if the user chooses to rent accessories.

How to create Layout Rules?

  1. Go to Setup > Customization > Modules.
  2. Select the module.
  3. Go to the Layout Rules section and + New Layout Rule.
  4. In the New Layout Rule pop-up, enter the following details:
    1. Rule Name
    2. Rule Description
    3. Select the Layout to which the rule is applicable.
    4. Choose the primary field that controls the rule.
    5. Choose a condition to initiate the rule.
  5. Click Next.
  6. In the Rule Page, click + Trigger an action.
  7. Select the action and choose the corresponding section/field/subform according to the action you have selected.
  8. Click Save.


How to trigger more than one action with a condition?

With a single condition, you can trigger more than one action by repeating steps 6 to 8. For instance, if the vehicle type is two-wheeler, you can show the two-wheeler section, and make the bike-type field mandatory.

How to add more criteria to a condition?

To add more than one criteria to the condition, click on Edit Condition after initiating the rule. For example, you can show the Number of seating rows field only if the car type is MUV/SUV AND the seating capacity is greater than 4.



Note : You can add a maximum of five criteria in each condition, combined using AND or OR. You can use the primary field for only one criterion, and this criterion can only have AND operator with others.

How to add more conditions?

To add more conditions and actions depending on the same primary field, click on Choose an option and add them. For example, if the Vehicle Type is Four-wheeler, show the Four wheeler section of the layout.



How to make a field mandatory?

Apart from showing specific fields, sections or subforms, you can also make a field mandatory depending on a condition. For example, you can make the Number of Helmets field mandatory if the Helmets Required field is checked.



Layout Rules in action


The image illustrates the effects of the layout rules. Two-wheeler or Four-wheeler sections are shown depending on the value of the Vehicle Type field. The Number of Helmets required field becomes mandatory if Helmet Required field is checked. If the car type is MUV or SUV, AND the Maximum seating capacity is more than 5, then the Number of seating rows field is displayed.

API support for Layouts and Layout Rules

If you do not specify the layout while creating a record using API call, the standard layout will be applied by default. If you specify a layout, the record will be assigned to it along with mandatory field check configured for that specific layout. In either scenario, the Show Field/Section/Subform layout rules applicable will be applied to the view record page in the UI. 

Mandatory Field Layout Rules

In order to apply the mandatory field rules, you must include the apply_feature_execution key in the input JSON. This is supported for Insert, Update and Upsert Records API from v2.
Currently API support is only available for Mandatory Field Layout Rules, during inserting or updating a record. 
Here is the sample JSON to create a record applying the layout rules.


 {
    "data": [
        {
            "Email": "patricia.boyle@zoho.com", 
            "Name": "Patricia",
            "Name1" : "Matt",
            "Mobile_Number" : "999999999",
            "Vehicle_Type": "Two wheeler",
            "Bike_Type": "Standard",
            "Helmets_Required": true,
             "Layout": {
                "name": "Standard",
                "id": "4876876000002670001"
            }
        }
    ],
     "apply_feature_execution": [
       {
           "name": "layout_rules"
       }
   ]
 }


In this example, the system will throw the following MANDATORY_NOT_FOUND error since we have made the Number of Helmets field mandatory if the Helmets Required field is True.


 {
    "data": [
        {
            "code": "MANDATORY_NOT_FOUND",
            "details": {
                "layout_rule": {
                    "name": "Helmet Mandatory Rule",
                    "id": "4876876000002695023"
                },
                "api_name": "No_of_Helmets"
            },
            "message": "required field not found",
            "status": "error"
        }
    ]
 }


You can use apply_feature_execution key in the Update and Upsert Record APIs to apply mandatory field rules to those records created without apply_feature_execution key.

Show Field/Section/Subform Rules 

API support is currently not extended to these rules. When using API calls, you can add values to all fields, even if they are hidden by layout rules.  Get Records API returns all the fields in the layout. In other words, using APIs bypasses layout rules for Show Field/Section/Subform.

Points to remember

  • You can include the primary field of one layout rule in the "Show Field" and "Set Mandatory Fields" actions for other layout rules, but not as a primary field for another rule.
  • The Record Owner field or a multi-select picklist field cannot be the primary field for a rule.
  • Layout rules are active when creating a record manually and when creating a record through the API. However, when using the API, only mandatory field rules are applied. Layout rules are not available for records generated via import, webforms or lead convert page. Refer to Layout Rule Exceptions for more details.
  • When you edit a primary field associated with a layout rule, and if the actions triggered include making one or more fields mandatory, the system will capture these mandatory fields via a pop-up prompt. For example, when you edit a record, and change the Helmets Required from No to Yes, the Number of Helmets Required field will be captured via a pop-up prompt.
  • You cannot use Layout Rules on Auto Number, Lookup, Multi Select Lookup, User Lookup, Formula, File Upload and Multi Line field types.
  • Layout Rules are applicable for create, edit and view pages.
We hope you found this post useful. We will meet you next week with another interesting topic!
If you have any questions let us know in the comment section.

Related Links



    Nederlandse Hulpbronnen


      • Recent Topics

      • Truesync for Linux

        Is Truesync available on linux ?
      • Subforms and automation

        If a user updates a field how do we create an automation etc. We have a field for returned parts and i want to get an email when that field is ticked. How please as Zoho tells me no automation on subforms. The Reason- Why having waited for ever for FSM
      • Kaizen #193: Creating different fields in Zoho CRM through API

        🎊 Nearing 200th Kaizen Post – We want to hear from you! Do you have any questions, suggestions, or topics you would like us to cover in future posts? Your insights and suggestions help us shape future content and make this series better for everyone.
      • Flex Your Creativity – A New component to Canvas in Zoho CRM

        Hello Everyone We’re excited to introduce Flex, a new component for Canvas in Zoho CRM! Flex is here to give you greater control over how your data is displayed in your layouts. This component enables responsive layouts that adapt across different screen
      • When will Sales Order and Invoice Synchronisation with Zoho CRM be Available?

        When will Sales Orders and Invoices, created in Zoho Books or Inventory be made available in Zoho CRM? John Legg Owner: The Debug Store
      • Feature Requests and enhancements: Subform

        By The Grace of G-D. Hi, It would make it much easier to use if we could have some more features in subforms: More Columns/Fields Set the size of a column Show the subform in Full Page Width Sorting By Column Please consider The above suggestions. T
      • Clone a Module??

        I am giong to repurpose the Vendors module but would like to have a separate but very similar module for another group of contacts called Buyers. I have already repurposed Contacts to Sellers. Is it possible to clone (make a duplicate) module of Vendors
      • Empowered Custom Views: Cross-Module Criteria Now Supported in Zoho CRM

        Hello everyone, We’re excited to introduce cross-module criteria support in custom views! Custom views provide personalized perspectives on your data and that you can save for future use. You can share these views with all users or specific individuals
      • Unapplied AP Credits not showing up on AP Detail Aging

        I am new to using Zoho Books. I was reconciling some accounts and found differences from the GL balance and AP Aging and it came down to unapplied vendor credits. Is there an option to include that on the report, so I can pull a matching AP Aging to the
      • Add Entry and Subform Record from Deluge Scripts

        Hi all,  I would like to know how do I add a new entry and also subform records from a deluge scripts.  I can use the insert into to add a new entry to a form, but how do i insert a collection into the subform of the entry? I am using a deluge script
      • i keep see there is a connetion issue connecting 3rd party api on zoho when using zia

        hi there , i have set up open ai api to zoho zia (copied and pasted to zoho zia) but I keep getting notificaiton "there is a connetion issue connecting 3rd party api on zoho" when using zia on top when click zia and try to type in word there
      • Finding draft ticket replies

        Is there a way to see all tickets which have draft replies?
      • How to apply a tag to a ticket based on the to email address?

        I need to assign a tag to a ticket if the ticket was sent to a specific email address. For example, we have the email accounting[at]company.com forwarding into Zoho Desk. We would like all emails that were sent to this address to be tagged with an Accounting
      • Engineering Change Order Process using Tickets?

        Hi Zoho Community, I'm working with my company to create an Engineering Change Order/Request (ECO/ECR) process where engineers can internally create tickets for changes in a product that must be reviewed, approved and implemented by people or teams in
      • Allow Changing Appointment Status from "Completed" to "No Show" or Other Valid States

        Hi Zoho Bookings Team, We hope you're doing well. We would like to submit a feature request regarding appointment status management in Zoho Bookings. 🎯 Use Case Sometimes, an appointment is mistakenly marked as Completed, but later we realize that the
      • How can I move a ticket from Department A to Department B?

        Hi there, how do I move ticket from Department A to Department B? I went in the ticket and tried to scroll down the menu under the "department" but it won't let me, I am a support admin. Did I do anything wrong? or am I doing it in the wrong place?
      • Validation Rules Trigger on Untouched Fields

        In Zoho Desk, validation rules trigger for ALL fields during an update—even fields that weren't modified in the current edit. This behavior is fundamentally different from Zoho CRM and other Zoho products, where validation rules only apply to fields actually
      • How to work with getFieldNames formdata functions ,Any Examples

        I don't find any example showing usage of getFieldNames. Where do i find .is there any Help documents available
      • Zoho Notifications - Received two notifications for one message and none for the other

        We had a client reply to a ticket twice in one minute. The ticket owner received two emails for the second message but none for the first (which was crucial content and unfortunately was therefore missed). I'm assuming this created a race condition -
      • Can we have Backorder Management ?

        Can we have Backorder Management ?
      • Better integration between Zoho CRM and Zoho Bookings

        I've noticed that when a meeting which was created in Zoho Bookings is updated by a sales person in Zoho CRM, the change is not reflected back into Zoho Bookings. I have raised this with support who advised that meetings created in Bookings need to be
      • What is the difference between "Reply" and "Public Comment" in a ticket?

        Hey, my company is thinking about switching to Zoho Desk but we do not understand the difference between the "Reply" and the "Public Comment" feature. When should we use which? And why? What is the difference between them? Thank you for your help! Kindest
      • Tasks View for Opportunity/Jobs does not indicate "Related To" account

        How can ZoHo be setup so that when a task is created for an Opportunity, the subject automatically lists the underlying account? Right now, it's impossible to link the Account to the task when the task is created from the Job.  Therefore, the open task view is inadequate.  And it's a lot of maintenance to have to manually add the account to the subject...defeating the purpose of "Automated" workflow. 
      • Writing SQL Queries - After Comma Auto Suggesting Column

        When writing SQL Queries, does anyone else get super annoyed that after you type a comma and try to return to a new line it is automatically suggest a new column, so hitting return just inputs this suggested column instead of going to a new line? Anyone
      • can i show alert when i finish running the function?

        how i can show alert inside the custom function or popup notification. when i use alert inside the custom function it show this error Error at line number:  2 'ALERT' task can be used only in on load, on validate and on change actions ​
      • CRM calendar not syncing with Zoho Calendar

        The sync is not happening: This is my Zoho Calendar CalDAV synced with Outlook This is my Zoho CRM Calendar (sadly empty ...) I have enabled CalDAV Access. In Zoho Calendar, I have set up APP Calendar sync like this: What else can I check? Thank
      • Pipeline in Custom Modules

        I love the way the Sales Pipeline looks and functions with reports. I would like to add the save pipeline features and visualization to a custom module, however, I only see that these pipelines are only available for the Deals module. Is there a way to add pipelines to custom modules?
      • Ecommerce integration with prestashop

        Development of campaigns integration with prestahop. When???
      • Cannot associate event with other objects when creating?

        I am attempting to associate an Event with one or more other objects when creating it via the API. According to the API docs, the "Related_To" property is a jsonobject even though the description says "Provide the details about the entities the event
      • Zoho Cliq not working on airplanes

        Hi, My team and I have been having this constant issue of cliq not working when connected to an airplane's wifi. Is there a reason for this? We have tried on different Airlines and it doesn't work on any of them. We need assistance here since we are constantly
      • Departments in Zoho

        I'm trying to set up a department. It looks like Departments have been removed from Zoho One. Is there another option? We have our main account setup, but want to set up a separate small department that can't see our tabs.
      • How to disable subform records dynamically

        Hi Everyone I have a requirement to dynamically disable or hide subform fields based on certain criteria. However, the code I tried didn't work as expected. It either disabled or hid all the fields in all subform records or none at all. What I actually
      • Client Script Operate Timeout

        Hi Zoho, I have set a client script that use for ( i =1; length < i , i++) to fetch all of the product in order I have an order have 30+ products, seems this script will be stopped when it is checking rough 10 + products because of timeout (may be). May
      • Why and When to Manually Regenerate Reports?

        What is the protocol for needing to regenerate reports?  It is very confusing when data in reports pulls correctly sometimes, but are inaccurate other times.   Why is report regenerating necessary at all - can the report function not read the live data as inputted into the forms?  We have built lots of reports and it is very tedious and time consuming to have to regenerate the report before each use of that data to make sure it is accurate.  Is there a way to know when a report should or shouldn't
      • Import template from Zoho Writer

        I am trying to import a mail merge template - tried to import direct from my .docx file on my hard drive and the formatting went all over the place. I then imported the .docx file in my Zoho Docs and then fixed up the formatting within Zoho Writer. Can
      • CRM for Everyone - More Actions Option to Create Record

        Please consider the option create a new record for the module from the More Actions menu. I know there is an "Add New" icon further down the menu to create a record for any module, but this just seems more intuitive and could reduce the need for the "Add
      • Configuración

        Hola acabo de instalar Zoho CRM y quiero configurarlo correctamente. Al respecto me surgen algunas dudas tales como la diferencia entre: Cuentas, posibles Clientes y Contactos. ¿Conceptualmente que son cada uno? ¿Como se se relacionan entre ellos? Si
      • Is there a way to request a password?

        We add customers info into the vaults and I wanted to see if we could do some sort of "file request" like how dropbox offers with files. It would be awesome if a customer could go to a link and input a "title, username, password, url" all securely and it then shows up in our team vault or something. Not sure if that is safe, but it's the best I can think of to be semi scalable and obviously better than sending emails. I am open to another idea, just thought this would be a great feature.  Thanks,
      • Enhancements to Custom Connectors in Zoho Creator

        Hello everyone, At Zoho Creator, we believe in providing you with the necessary tools to achieve a well connected ecosystem of apps. Our Custom Connectors feature is a testament to this, enabling you to integrate with a wide range of external services
      • AutoScan Not Working Since April -Support says it with engineering

        Hi there, Autoscan has not been working on my account since April. Without this feature, completing expenses reports is laborious and error-prone. I keep asking for updates seeing as this is a critical feature, but told that it's being looked into and
      • Next Page