Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ****Helper class*****
- component.set("v.searching", true);
- var action = component.get("c.runCompanySearch");
- // Mark the action as abortable, this is to prevent multiple events from the keyup executing
- action.setAbortable();
- action.setParams({
- "siteID": component.get("v.siteID"),
- "searchString": component.get("v.searchString")
- });
- action.setCallback(this, function(response) {
- var state = response.getState();
- if (component.isValid() && state == "SUCCESS") {
- component.set("v.searching", false);
- component.set("v.SECompanies", response.getReturnValue());
- **************Here I am accessing the variable********
- component.set("v.seColumns",seColumns);
- component.find("seTable").initialize({
- "order":[0,"desc"]
- });
- ******************************************************
- console.log(response.getReturnValue());
- } else if (state === "ERROR") { // Handle any error by reporting it
- var errors = response.getError();
- if (errors) {
- if (errors[0] && errors[0].message) {
- this.displayToast('Error', errors[0].message);
- }
- } else {
- this.displayToast('Error', 'Unknown error.');
- }
- }
- });
- $A.enqueueAction(action);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement