Got the data to pass into the js file from the controller