Skip to content

Commit ac9845c

Browse files
committed
show author
1 parent 08a4741 commit ac9845c

File tree

4 files changed

+18
-1
lines changed

4 files changed

+18
-1
lines changed

client-translations.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,8 @@
114114
"allLanguages": "All languages",
115115
"confirmPlaylistDeletion": "Are you sure you want to delete this playlist?",
116116
"latestTracks": "Latest tracks",
117-
"instrumental": "Instrumental"
117+
"instrumental": "Instrumental",
118+
"by": "by"
118119
},
119120
"notify": {
120121
"play": "Play",

client/app/scripts/controllers/playlist.js

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,8 @@ angular.module('bmmApp')
3939
$scope.zip = {};
4040
$scope.zip.show = false;
4141
$scope.showFollow = false;
42+
$scope.authorName = null;
43+
$scope.showAuthor = false;
4244
$scope.follow = null;
4345
$scope.albums = [];
4446
$scope.albumCount = 0;
@@ -231,6 +233,10 @@ angular.module('bmmApp')
231233
$scope.zip.url = _api.addAuthorizationQueryString(_api.getserverUrli()+'track_collection'+'/'+$routeParams.id+'/download');
232234
$scope.zip.show = true;
233235
$scope.private = true;
236+
$scope.authorName = data.authorName;
237+
if ($scope.authorName) {
238+
$scope.showAuthor = true;
239+
}
234240
_api.userTrackCollectionGet($routeParams.id).done(function(data) {
235241

236242
$scope.title = data.name;
@@ -280,6 +286,10 @@ angular.module('bmmApp')
280286
_api.playlistSharedGet($routeParams.id).done(function(data) {
281287
resolveTracks(data.tracks);
282288
$scope.title = data.name;
289+
$scope.authorName = data.authorName;
290+
if ($scope.authorName) {
291+
$scope.showAuthor = true;
292+
}
283293
});
284294
break;
285295
case 'podcast':

client/app/views/pages/playlist.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
</div>
55
<h3><span ng-bind="::title"></span></h3>
66
</div>
7+
<span class="playlist-author" ng-show="showAuthor">{{init.translation.playlist.by}} {{authorName}}</span>
78
<span ng-bind="tracks + ' ' + init.translation.playlist.tracks"></span>
89
<br ng-show="tracks>0&&albumCount>0">
910
<span ng-hide="albumCount<1"><span ng-bind="albumCount + ' ' + init.translation.playlist.albums"></span></span>

common/app/styles/partials/_viewer-client.scss

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -260,6 +260,11 @@
260260
height: 1.1em;
261261
}
262262

263+
.playlist-author {
264+
display: block;
265+
margin-bottom: 4px;
266+
}
267+
263268
.actionButtons .actionButton {
264269
margin-top: 1em;
265270
margin-right: .5em;

0 commit comments

Comments
 (0)