+ Start a Discussion
Trinath ReddyTrinath Reddy 

Lightning with Custom settings

<td><a href=" http://sites/operations/id=" target="_blank" style="font-size:15px">Link</a></td>Lightning 
Can anyone help me how to replace "http://sites/operations/id=" the url with Custom settings in  lightning.
Tej PalTej Pal
Hi Trinath,

Create one attribue in lightening component and then use like ​ below example.

var action = component.get("c.getHiearchySettings");

    action.setCallback(this, function(response){
        if(component.isValid() && response !== null && response.getState() == 'SUCCESS'){
            //saving custom setting to attribute
            component.set("v.settings", response);
            console.debug(response.Use_Big_Data_Mode__c );//Check the output
            //... rest of your code

Apex class
public class MyController{
    public static MyHiearchy__c getHiearchySettings(){
        return MyHiearchy__c.getInstance();
If this answers your question mark Best Answer it as solution and then hit Like!