Advertisement
Guest User

Docmarten

a guest
May 29th, 2015
255
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. /* my app is using tabs, everytime the user moves away from the tab and goes back to it, i want the content to refresh but currently its not working. At the same time, i want to give the user a button to force a refresh, but that too is not working. A) I am creating the "doRefresh" function to both be called for auto refresh and for when the user clicks the button, however I am getting the following error upon execution: doRefresh is not defined
  2. */
  3.  
  4. .controller('TabsCtrl', function($scope,Tabs) {
  5. $scope.tabs= Tabs.all();
  6. $scope.doRefresh = function() {
  7. $scope.tabs= Tabs.all();
  8. }
  9. })
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement