Rename the previously changed subsonic controller, service and related tests.
In order to better follow the google naming convention. See https://docs.google.com/document/d/1XXMvReO8-Awi1EZXAXS4PzDzdNvV6pGcuaF4Q9821Es/pub
This commit is contained in:
parent
f57b969e55
commit
a2747a633d
7 changed files with 67 additions and 81 deletions
52
js/services/model-service.js
Normal file
52
js/services/model-service.js
Normal file
|
@ -0,0 +1,52 @@
|
|||
'use strict';
|
||||
|
||||
var jamstash = angular.module('JamStash');
|
||||
|
||||
jamstash.service('model', function (utils) {
|
||||
this.Index = function (name, artist) {
|
||||
this.name = name;
|
||||
this.artist = artist;
|
||||
};
|
||||
this.Artist = function (id, name) {
|
||||
this.id = id;
|
||||
this.name = name;
|
||||
};
|
||||
this.Album = function (id, parentid, name, artist, artistId, coverartthumb, coverartfull, date, starred, description, url, type) {
|
||||
this.id = id;
|
||||
this.parentid = parentid;
|
||||
this.name = name;
|
||||
this.artist = artist;
|
||||
this.artistId = artistId;
|
||||
this.coverartthumb = coverartthumb;
|
||||
this.coverartfull = coverartfull;
|
||||
this.date = date;
|
||||
this.starred = starred;
|
||||
this.description = description;
|
||||
this.url = url;
|
||||
this.type = type;
|
||||
};
|
||||
this.Song = function (id, parentid, track, name, artist, artistId, album, albumId, coverartthumb, coverartfull, duration, rating, starred, suffix, specs, url, position, description) {
|
||||
this.id = id;
|
||||
this.parentid = parentid;
|
||||
this.track = track;
|
||||
this.name = name;
|
||||
this.artist = artist;
|
||||
this.artistId = artistId;
|
||||
this.album = album;
|
||||
this.albumId = albumId;
|
||||
this.coverartthumb = coverartthumb;
|
||||
this.coverartfull = coverartfull;
|
||||
this.duration = duration;
|
||||
this.time = duration === '' ? '00:00' : utils.secondsToTime(duration);
|
||||
this.rating = rating;
|
||||
this.starred = starred;
|
||||
this.suffix = suffix;
|
||||
this.specs = specs;
|
||||
this.url = url;
|
||||
this.position = position;
|
||||
this.selected = false;
|
||||
this.playing = false;
|
||||
this.description = description;
|
||||
this.displayName = this.name + " - " + this.album + " - " + this.artist;
|
||||
};
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue