var auth = 'Basic WjhlYWYyam1ZOEY1TG90WnJaZHQxbVlKdUVWUStuN1hyckUzL3RTT05tODpaOGVhZjJqbVk4RjVMb3RaclpkdDFtWUp1RVZRK243WHJyRTMvdFNPTm04';

$('body').bind('touchmove', function(e) {
  e.preventDefault()
});

angular.module('hottrade', ['gajus.swing', 'ui.router'])

.config(function($stateProvider, $urlRouterProvider) {

})

.controller('MainCtrl', function($scope, $http) {

  $scope.sectors = ["Consumer, Cyclical", "Financial", "Consumer, Non-cyclical", "Energy", "Technology", "Industrial", "Utilities", "Communications", "Basic Materials", "Diversified"];
  $scope.survey = {};

  $scope.matches = [];

  $scope.matchStocks = function() {
    $http.get('/api/industry/' + $scope.surveey.sector).success(function(data) {
      $scope.matches = _.first(data, 20);
      $('#workLink').click();
    });
  };

  $scope.picked = [];

  $scope.swipeLeft = function(index) {
    console.log(index);
    $scope.matches.splice(index, 1);
    $scope.$apply();
  };

  $scope.swipeRight = function(index) {
    console.log(index);
    $scope.picked.push($scope.matches.splice(index, 1)[0]);
    $scope.$apply();
  };

  $scope.nextWindow = function() {
    if ($scope.matches.length > 0) {
      return;
    }
    $('#nextLink').click();
  };

});

@@ -572,16 +572,67 @@
 rvey = %7B
+%0A    sector: $scope.sectors%5B0%5D,%0A    risk: 'safe'%0A  
 %7D;%0A%0A  $s

fix defualts