Background: We develop a managed package and are auditing the code for hardcoded references to the namespace. We want to use static/resolved references of objects/fields/pages/custom settings instead of the hardcoded namespace strings in order to support a multi-org/developer lifecycle.
I'm having trouble finding an alternative to referencing a hierarchy custom settings in a VF page without having to use the namespace for the field name.
Example:
Custom Settings (type = hierarchy): System_Preferences__c
Field Name: Default_Email__c
Namespace: abc
//within javascript
var defaultEmail = '{!$Setup.System_Preferences__c.abc__Default_Email__c}'; // works
var defaultEmail = '{!$Setup.System_Preferences__c.Default_Email__c}'; // returns null
Is there another way to do this? Or is this a current limitation?
Thanks,
Brian