I have a form submit by regular javascript outsite angular. The form is successfuly submit and update the database. I have a $http inside angularjs to query the data.
My question is once submit the form, how can I refresh data inside angularjs?
sample javascript submit:
$.getJSON('/Api/Cbs/setPost', inputPost, function(rsp){
  if(rsp.status > 0){alert('submited');
}
here is my code in angularjs
$http.get('echo U('Api/Cbs/getPostList')')
.then(function(rsp){
  console.log('angular-getPost', rsp);
  $scope.postList = rsp.data;
});
the $http.get() fire only once on page load, not keep watching the API data update.
 
    