Sha256: 7d0afe464dd8dbfb7760321159aa8b171fbc138e2f5c5cbdd96ff76274b9accb
Contents?: true
Size: 1.57 KB
Versions: 10
Compression:
Stored size: 1.57 KB
Contents
module = angular.module('maestrano.dashboard.dashboard-marketplace',['maestrano.assets']) #============================================ # #============================================ module.controller('DashboardMarketplaceCtrl',[ '$scope', 'MarketplaceSvc', 'AssetPath' ($scope, MarketplaceSvc, AssetPath) -> #==================================== # Pre-Initialization #==================================== $scope.assetPath = AssetPath $scope.isLoading = true $scope.selectedCategory = '' $scope.searchTerm = '' $scope.appFilter = '' #==================================== # Scope Management #==================================== $scope.initialize = (marketplace)-> $scope.categories = marketplace.categories $scope.apps = marketplace.apps $scope.isLoading = false $scope.linkFor = (app) -> "#/marketplace/#{app.id}" $scope.appsFilter = (app) -> if ($scope.searchTerm? && $scope.searchTerm.length > 0) || !$scope.selectedCategory return true else return _.contains(app.categories,$scope.selectedCategory) #==================================== # Post-Initialization #==================================== MarketplaceSvc.load().then (marketplace)-> $scope.initialize(marketplace) ]) module.directive('dashboardMarketplace', ['TemplatePath', (TemplatePath) -> return { restrict: 'A', scope: {}, templateUrl: TemplatePath['mno_enterprise/dashboard/marketplace/index.html'], controller: 'DashboardMarketplaceCtrl' } ])
Version data entries
10 entries across 10 versions & 1 rubygems