Can SugarBean access custom fields without using the "_c" ending?

I have an after_save logic hook in a custom module where I'm setting the value of a field called rate_actual equal to the value of a custom field called engineer_rate_c. But, there is a typo in the code where I forgot the "_c" ending, like this:

$bean->rate_actual = $bean->engineer_rate;

Despite this error, the value gets set correctly. Does SugarBean have the ability to access custom fields without including "_c" in the name?

Parents
  • Hi Yury Voloshin,

    What version of sugar you are on? I haven't seen this working in upto version 8.x.

    Also, are you sure you got this working as in after_save hook, you also need to use $bean->save() at the end.

    Also, verify the custom field name from cache/<module_name>/<module_name>vardefs.php

    Regards.

Reply
  • Hi Yury Voloshin,

    What version of sugar you are on? I haven't seen this working in upto version 8.x.

    Also, are you sure you got this working as in after_save hook, you also need to use $bean->save() at the end.

    Also, verify the custom field name from cache/<module_name>/<module_name>vardefs.php

    Regards.

Children