nigel_john nigel_john

How can a "related" field be made Read-Only?

Discussion created by nigel_john nigel_john on Mar 20, 2014
Latest reply on Mar 22, 2014 by nigel_john nigel_john
Hey there,

I know how to make a field read-only as per Conditionally make a field readonly

However how does one make a related field read-only.
I have a field "Lead Owner" in Leads field(see attached screen-shot)
I know the logic for custom/modules/Leads/views/view.edit.php

I wanted the logic for custom/modules/Leads/metadata/editviewdefs.php

I can see this in editviewdefs.php
 'panels' =>
    array (
      'lbl_contact_information' =>
      array (
        0 =>
        array (
          0 =>
          array (
            'name' => 'leadowner_c',
            'studio' => 'visible',
            'label' => 'LBL_LEADOWNER',
So based on ACL the "select/un-select" option needs to visible or invisible, however contents of the field must be visible to all users.

I'm presuming some 'customCode' with 'html_options' are required?

Thanx in advance.