title: AngularJS - Using .Then Instead of .Success is not working with HTTP function
body: <p>I've been searching a lot about the topic but couldn't find a solution still. I believe I am not handling the promise properly. I have a AngularJS MVC model working fine when I handle my API call with the .success but when I changed to .then ( because the other is depreciated ) it doesn't work. I can see in my http-server log that with the code below I still get the json file and I am using a simple json file for testing so I believe I did not forgot to define the view properly (like this <a href="https://stackoverflow.com/questions/22260031/angularjs-cant-access-retrieved-json-data-in-the-view">AngularJS - Can&#39;t access retrieved JSON data in the view</a> )</p>
  
  <p>I also tested with the complete http.get syntax in the controller only but its also not working. </p>
  
  <p>services.js</p>
  
  <pre><code> angular.module('myApp.services', [])
   .factory('APIservice', function($http, $q) {
  
      var myAPIs = {};
  
      myAPIs.getFullList = function() {
          return $http.get("myFile.json", {timeout: 30000, cache:false});
      };
  
      //(...) more APIs here
  
      return myAPIs;
  });
  </code></pre>
  
  <p>controllers.js</p>
  
  <pre><code>  angular.module('myApp.controllers', [])
    .controller("Tablectrl", function($scope, $http, $q, APIservice) {
  
      var promise = APIservice.getFullList();
          promise.then(
              function(response) {
                  $scope.myTable = response.records;
              },
              function(reason) { console.log('Error: ' + reason); }
          );
  </code></pre>
  
  <p>view</p>
  
  <pre><code>&lt;div ng-controller="Tablectrl"&gt;
          &lt;table border="0" style="width:100%" class="table table-striped table-condensed table-hover"&gt;
              &lt;tr&gt;
                  &lt;th&gt;ID &amp;nbsp&lt;/th&gt;
              &lt;/tr&gt;
              &lt;tr ng-repeat="myTable in myTable&gt;
                  &lt;td&gt;{{myTable.id}}&lt;/td&gt;
              &lt;/tr&gt;
          &lt;/table&gt;
  
      &lt;/div&gt;
  </code></pre>
  
  <p>My JSON</p>
  
  <pre><code>  {  "records" : [
  {
    "id" : "500006",
    (...)
  },
   (...)
  ]
  }
  </code></pre>
  
  <p>Thanks for your time!</p>