Display user movies.

This commit is contained in:
2019-01-15 07:17:06 +01:00
parent 0e3aee13bd
commit f9c1f37ac6
3 changed files with 56 additions and 1 deletions

View File

@ -0,0 +1,30 @@
/**
* Movies category
*
* @author Pierre HUBERT
*/
/**
* Apply the list of movies of the user
*/
function ApplyMovies(){
let target = document.querySelector("#full-movie-list-table tbody");
//Process the list of movies
data.movies.forEach(movie => {
createElem2({
appendTo: target,
type: "tr",
innerHTML:
"<td>" + movie.id + "</td>" +
"<td>" + movie.name + "</td>" +
"<td>" + movie.file_type + "</td>" +
"<td>" + movie.size + "</td>" +
"<td> <a href='"+getFilePathFromURL(movie.url)+"'>Open</a></td>"
});
});
}

View File

@ -79,6 +79,7 @@ xhr.onload = function(){
ApplyCommentsList();
ApplyUserLikes();
ApplySurveyResponses();
ApplyMovies();
}
xhr.send(null);