You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

home.controller.js 881B

1234567891011121314151617181920212223242526
  1. angular.module('app')
  2. .controller('HomeController', ['$scope', '$state', '$mdDialog', 'articlesBusiness', 'luBusyBusiness',
  3. 'AppUtilsBusiness', 'feedBusiness',
  4. function($scope, $state, $mdDialog, articlesBusiness, luBusyBusiness,
  5. AppUtilsBusiness, feedBusiness) {
  6. $scope.busy = luBusyBusiness.reset();
  7. $scope.item = null;
  8. $scope.feed = null;
  9. $scope.appUtils = AppUtilsBusiness;
  10. $scope.load = function()
  11. {
  12. articlesBusiness.getMultiple('id', 'type: home', 0, 1, 'home.home').then(function(data)
  13. {
  14. $scope.item = data.data[0];
  15. }, function (error) {});
  16. feedBusiness.get('home.feed').then(function(data)
  17. {
  18. $scope.feed = data;
  19. }, function (error) {});
  20. };
  21. $scope.load();
  22. }]);