1
0
mirror of https://github.com/jcwimer/wrestlingApp synced 2026-03-25 01:14:43 +00:00
Files
wrestlingdev.com/frontend/app/js/controllers/tournaments-controller.js
jcwimer 5b9f64b3f9 Created basic viewing pages in angular
Can now search and view tournaments. Can now view team scores, weights and seeds, mats and bout board
2016-04-12 21:11:18 +00:00

19 lines
541 B
JavaScript

'use strict';
app.controller("tournamentsController", function($scope, tournamentsService) {
tournamentsService.getAllTournaments().then(function(data) {
//this will execute when the
//AJAX call completes.
$scope.allTournaments = data;
});
$scope.searchTournaments = function (){
tournamentsService.searchTournaments($scope.searchTerms).then(function(data) {
//this will execute when the
//AJAX call completes.
$scope.allTournaments = data;
});
};
});