Created
December 28, 2019 16:38
-
-
Save arun12209/52ca85b19ced89581f7d97d424178509 to your computer and use it in GitHub Desktop.
companyProfileHelper
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
({ | |
fetchCompanyProfile : function(component,event,helper) { | |
var action=component.get("c.getAccountDetails"); | |
action.setParams({ | |
"rec_id": component.get("v.recordId") | |
}); | |
action.setCallback(this, function(response) { | |
var state = response.getState(); | |
if (state === "SUCCESS") { | |
if(response.getReturnValue() == 'Enter website to see the company profile'){ | |
component.set("v.err",'Enter website to see the company profile'); | |
}else{ | |
var data = JSON.parse(response.getReturnValue()); | |
component.set("v.details",data); | |
component.set("v.err",''); | |
} | |
} | |
}); | |
$A.enqueueAction(action); | |
} | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment