Compare commits
2 commits
12ca71e643
...
fe3bdafb63
Author | SHA1 | Date | |
---|---|---|---|
fe3bdafb63 | |||
a3c03a1569 |
3 changed files with 7 additions and 5 deletions
|
@ -242,7 +242,9 @@ class Albums extends Pages {
|
||||||
|
|
||||||
const item = {
|
const item = {
|
||||||
...album.toJSON(),
|
...album.toJSON(),
|
||||||
released: formatDate(album.released, "MM/dd/yyyy"),
|
released: album.released
|
||||||
|
? formatDate(album.released, "MM/dd/yyyy")
|
||||||
|
: null,
|
||||||
};
|
};
|
||||||
|
|
||||||
this.setPageContent("item", item);
|
this.setPageContent("item", item);
|
||||||
|
|
|
@ -175,10 +175,10 @@
|
||||||
|
|
||||||
let url = `/api/v1/albums?userId=${this.userId}&page=${this.page}&limit=${this.limit}&sort=${this.sort}&order=${this.order}`;
|
let url = `/api/v1/albums?userId=${this.userId}&page=${this.page}&limit=${this.limit}&sort=${this.sort}&order=${this.order}`;
|
||||||
if ( this.artist ) {
|
if ( this.artist ) {
|
||||||
url += `&artists_sort=${this.artist}`;
|
url += `&artists_sort=${this.artist.replace('&', '%26')}`;
|
||||||
}
|
}
|
||||||
if ( this.format ) {
|
if ( this.format ) {
|
||||||
url += `&format=${this.format}`;
|
url += `&format=${this.format.replace('&', '%26')}`;
|
||||||
}
|
}
|
||||||
if ( this.year ) {
|
if ( this.year ) {
|
||||||
url += `&year=${this.year}`;
|
url += `&year=${this.year}`;
|
||||||
|
|
|
@ -229,10 +229,10 @@
|
||||||
|
|
||||||
let url = `/api/v1/albums?page=${this.page}&limit=${this.limit}&sort=${this.sort}&order=${this.order}`;
|
let url = `/api/v1/albums?page=${this.page}&limit=${this.limit}&sort=${this.sort}&order=${this.order}`;
|
||||||
if ( this.artist ) {
|
if ( this.artist ) {
|
||||||
url += `&artists_sort=${this.artist}`;
|
url += `&artists_sort=${this.artist.replace('&', '%26')}`;
|
||||||
}
|
}
|
||||||
if ( this.format ) {
|
if ( this.format ) {
|
||||||
url += `&format=${this.format}`;
|
url += `&format=${this.format.replace('&', '%26')}`;
|
||||||
}
|
}
|
||||||
if ( this.year ) {
|
if ( this.year ) {
|
||||||
url += `&year=${this.year}`;
|
url += `&year=${this.year}`;
|
||||||
|
|
Loading…
Reference in a new issue