SkyBlue
SkyBlue

Reputation: 277

How to access alfresco global property from a share client-side javascript?

I have the following property in my alfresco-global-properties file.

customAction.enabled=true

I want to access this value from custom-actions.js file in share. What is the best and easiest way to do achieve this? Can I use rootScope variable in this case?

Upvotes: 1

Views: 363

Answers (1)

Heiko Robert
Heiko Robert

Reputation: 2707

You can't access alfresco-global-properties from the javascript api for security reasons. Either you implement your custom getter in Java and expose that to javascript or you store your required config in a specific content node which will be accessable from javascript.

Upvotes: 2

Related Questions