hide dups when loading + fix list display

This commit is contained in:
Gabriel Augendre 2016-04-17 16:13:45 +02:00
parent 2bec110f3b
commit 3d32a436ac

View file

@ -103,7 +103,7 @@
<script id="playlists-template" type="text/x-handlebars-template"> <script id="playlists-template" type="text/x-handlebars-template">
<h2>Playlists</h2> <h2>Playlists</h2>
{{#list playlists}} {{#list playlists}}
<a class="pl_item list-group-item btn has-spinner" href="/pl/{{pl_uid}}/{{pl_id}}"> <a class="pl_item list-group-item has-spinner" href="/pl/{{pl_uid}}/{{pl_id}}">
{{pl_name}} {{pl_name}}
<span class="spinner"><i class="icon-spin icon-refresh"></i></span> <span class="spinner"><i class="icon-spin icon-refresh"></i></span>
<i class="glyphicon glyphicon-chevron-right"></i> <i class="glyphicon glyphicon-chevron-right"></i>
@ -226,6 +226,7 @@
var currentElement = $(this); var currentElement = $(this);
currentElement.addClass('active'); currentElement.addClass('active');
currentElement.addClass('loading'); currentElement.addClass('loading');
$('#dups').toggleClass('hide');
$.ajax({ $.ajax({
url: $(this).attr('href'), url: $(this).attr('href'),
data: { data: {
@ -252,6 +253,7 @@
pl_name: pl_name pl_name: pl_name
}); });
} }
$('#dups').toggleClass('hide');
}) })
}); });