From d4b9b0f416a78478e732288b3832dbce2533da18 Mon Sep 17 00:00:00 2001 From: Belen Barros Pena Date: Mon, 26 Jan 2015 15:37:30 +0000 Subject: bitbake: toastergui: add 'show all' link to no results page When you search for targets or machines in the layer details page and your search returns no results, you should see a 'show all' link that you can click to clear the search and display all table entries. [YOCTO #7218] (Bitbake rev: 70486fc36c5b6bd6b7b8e846e23ad4062d583877) Signed-off-by: Belen Barros Pena Signed-off-by: Richard Purdie --- bitbake/lib/toaster/toastergui/static/js/layerdetails.js | 4 ++-- bitbake/lib/toaster/toastergui/templates/layerdetails.html | 10 ++++++++-- 2 files changed, 10 insertions(+), 4 deletions(-) (limited to 'bitbake') diff --git a/bitbake/lib/toaster/toastergui/static/js/layerdetails.js b/bitbake/lib/toaster/toastergui/static/js/layerdetails.js index 2addecd357..2793225d0c 100644 --- a/bitbake/lib/toaster/toastergui/static/js/layerdetails.js +++ b/bitbake/lib/toaster/toastergui/static/js/layerdetails.js @@ -381,12 +381,12 @@ function layerDetailsPageInit (ctx) { }); /* Clear the current search selection and reload the results */ - $("#target-search-clear").click(function(){ + $(".target-search-clear").click(function(){ $("#target-search").val(""); $(this).parents("form").submit(); }); - $("#machine-search-clear").click(function(){ + $(".machine-search-clear").click(function(){ $("#machine-search").val(""); $(this).parents("form").submit(); }); diff --git a/bitbake/lib/toaster/toastergui/templates/layerdetails.html b/bitbake/lib/toaster/toastergui/templates/layerdetails.html index a89ffb0312..f8f2d7ab87 100644 --- a/bitbake/lib/toaster/toastergui/templates/layerdetails.html +++ b/bitbake/lib/toaster/toastergui/templates/layerdetails.html @@ -205,11 +205,14 @@ {% if request.GET.targets_search %} - + {% endif %} + {% if targets.paginator.count == 0 %} + + {% if machines.paginator.count == 0 %} +