feat(playlist): shortens urls

This commit is contained in:
bergquist 2016-01-12 14:36:04 +01:00
parent 458d15063d
commit 1ec97e5199
3 changed files with 4 additions and 4 deletions

View File

@ -176,8 +176,8 @@ func Register(r *macaron.Macaron) {
r.Group("/playlists", func() {
r.Get("/", wrap(SearchPlaylists))
r.Get("/:id", ValidateOrgPlaylist, wrap(GetPlaylist))
r.Get("/:id/playlistitems", ValidateOrgPlaylist, wrap(GetPlaylistItems))
r.Get("/:id/playlistdashboards", ValidateOrgPlaylist, wrap(GetPlaylistDashboards))
r.Get("/:id/items", ValidateOrgPlaylist, wrap(GetPlaylistItems))
r.Get("/:id/dashboards", ValidateOrgPlaylist, wrap(GetPlaylistDashboards))
r.Delete("/:id", reqEditorRole, ValidateOrgPlaylist, wrap(DeletePlaylist))
r.Put("/:id", reqEditorRole, bind(m.UpdatePlaylistQuery{}), ValidateOrgPlaylist, wrap(UpdatePlaylist))
r.Post("/", reqEditorRole, bind(m.CreatePlaylistQuery{}), wrap(CreatePlaylist))

View File

@ -25,7 +25,7 @@ function (angular, config, _) {
$scope.playlist = result;
});
backendSrv.get('/api/playlists/' + playlistId + '/playlistitems')
backendSrv.get('/api/playlists/' + playlistId + '/items')
.then(function(result) {
$scope.playlistItems = result;
});

View File

@ -31,7 +31,7 @@ function (angular) {
return backendSrv.get('/api/playlists/' + playlistId)
.then(function(playlist) {
return backendSrv.get('/api/playlists/' + playlistId + '/playlistdashboards')
return backendSrv.get('/api/playlists/' + playlistId + '/dashboards')
.then(function(dashboards) {
playlistSrv.start(dashboards, playlist.timespan);
});