Skip to content
Permalink
Browse files

Add and delete tracks to playlists works

  • Loading branch information
sec11008 committed Dec 9, 2015
1 parent 78fe596 commit d3faf96b0a2fa5dbc224e6de805ea933881294f4
Showing with 2 additions and 2 deletions.
  1. +2 −2 TeamDBAwesome/TeamDBAwesome/js/adminController.js
@@ -132,7 +132,7 @@ angular.module('routerApp').controller('adminController', function ($scope, $htt

}

$scope.addTrack = function (trackID) {
$scope.addToPlaylist = function (trackID) {
console.log(trackID);
$http.get("http://localhost:50031/api/AddTrackPlaylist?PlaylistID=" + $scope.currentPlaylist + "&TrackID=" + trackID)
.success(function (response) {
@@ -158,7 +158,7 @@ angular.module('routerApp').controller('adminController', function ($scope, $htt
$scope.searchGridOptions = {
enableSorting: true,
columnDefs: [
{ field: 'TrackId', displayName: ' ', width: "30%", cellTemplate: '<center><button ng-click="console.log(row.entity.TrackId); grid.appScope.addToPlaylist(row.entity.TrackId);" class="btn btn-success btn-xs"> + </button></center>' },
{ field: 'TrackId', displayName: ' ', width: "5%", cellTemplate: '<center><button ng-click="grid.appScope.addToPlaylist(row.entity.TrackId);" class="btn btn-success btn-xs"> + </button></center>' },
{ field: 'TrackName', displayName: ' Track Name', width: "20%" },
{ field: 'artist', displayName: ' Artist Name', width: "20%" },
{ field: 'AlbumTitle', displayName: ' Album ', width: "15%" },

0 comments on commit d3faf96

Please sign in to comment.
You can’t perform that action at this time.