AnsweredAssumed Answered

Readonly dependency is not working with dropdown type fields

Question asked by Ajay Kumar on Sep 20, 2017
Latest reply on Sep 21, 2017 by André Lopes

Hi All,


I dont know what is wrong in below dependency code.We are using two fields(status and queue) for our customizations.

Our objective is when the case status becomes "Closed",Queue field should become readonly automatically.So i tried to achieve it with dependency.But it didnt work.Below is my code.


Note : status and queue_c is dropdown type fields


Path : custom/Extension/modules/Cases/Ext/Dependencies/closed_cases.php

$dependencies['Cases']['queue_readonly'] = array(
          'hooks' => array("edit"),
          //Trigger formula for the dependency. Defaults to 'true'.
          'trigger' => 'true',
          'triggerFields' => array('status'),
          'onload' => true,
          //Actions is a list of actions to fire when the trigger is true
          'actions' => array(
               'name' => 'ReadOnly', //Action type
               //The parameters passed in depend on the action type
               'params' => array(
               'target' => 'queue_c',
               'label' => 'queue_c_label', //normally <field>_label
               'value' => 'equal($status,"Closed")',


Please advice me.


With Best Regards

Ajay Kumar B