summaryrefslogtreecommitdiffstats
path: root/bitbake/lib
diff options
context:
space:
mode:
authorElliot Smith <elliot.smith@intel.com>2016-01-15 13:00:56 +0200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-01-15 16:30:00 +0000
commitf9c46f5e5e68229454b28adfe1a793d6b75f3096 (patch)
tree7c8f948607128d4d49a1fc05705560b6e72c0f25 /bitbake/lib
parenteaae82a19acaf786b866043ea80107f28e8206b2 (diff)
downloadpoky-f9c46f5e5e68229454b28adfe1a793d6b75f3096.tar.gz
bitbake: toastergui: don't hide all elements with .col class
Disabling the "project" column in a ToasterTable for builds causes the recent builds area to be hidden. This is because the column hiding code hides all elements with a class matching ".<column>", regardless of where they occur on the page; and the recent builds area was using the ".project-name" class, which means it is included in the set of elements which are hidden. Scope the element search to the table so that only elements within the table are hidden or shown. [YOCTO #8792] (Bitbake rev: 151bc20daf51e0ab8baf11ea29244b7fec1f8a22) Signed-off-by: Elliot Smith <elliot.smith@intel.com> Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib')
-rw-r--r--bitbake/lib/toaster/toastergui/static/js/table.js8
1 files changed, 4 insertions, 4 deletions
diff --git a/bitbake/lib/toaster/toastergui/static/js/table.js b/bitbake/lib/toaster/toastergui/static/js/table.js
index 7ac4ed5859..c154844820 100644
--- a/bitbake/lib/toaster/toastergui/static/js/table.js
+++ b/bitbake/lib/toaster/toastergui/static/js/table.js
@@ -316,7 +316,7 @@ function tableInit(ctx){
316 $("#"+ctx.tableName+" th").each(function(){ 316 $("#"+ctx.tableName+" th").each(function(){
317 for (var i in cols_hidden){ 317 for (var i in cols_hidden){
318 if ($(this).hasClass(cols_hidden[i])){ 318 if ($(this).hasClass(cols_hidden[i])){
319 $("."+cols_hidden[i]).hide(); 319 table.find("."+cols_hidden[i]).hide();
320 $("#checkbox-"+cols_hidden[i]).removeAttr("checked"); 320 $("#checkbox-"+cols_hidden[i]).removeAttr("checked");
321 } 321 }
322 } 322 }
@@ -326,7 +326,7 @@ function tableInit(ctx){
326 * user setting. 326 * user setting.
327 */ 327 */
328 for (var i in defaultHiddenCols) { 328 for (var i in defaultHiddenCols) {
329 $("."+defaultHiddenCols[i]).hide(); 329 table.find("."+defaultHiddenCols[i]).hide();
330 $("#checkbox-"+defaultHiddenCols[i]).removeAttr("checked"); 330 $("#checkbox-"+defaultHiddenCols[i]).removeAttr("checked");
331 } 331 }
332 } 332 }
@@ -370,9 +370,9 @@ function tableInit(ctx){
370 var disabled_cols = []; 370 var disabled_cols = [];
371 371
372 if ($(this).prop("checked")) { 372 if ($(this).prop("checked")) {
373 $("."+col).show(); 373 table.find("."+col).show();
374 } else { 374 } else {
375 $("."+col).hide(); 375 table.find("."+col).hide();
376 /* If we're ordered by the column we're hiding remove the order by */ 376 /* If we're ordered by the column we're hiding remove the order by */
377 if (col === tableParams.orderby || 377 if (col === tableParams.orderby ||
378 '-' + col === tableParams.orderby){ 378 '-' + col === tableParams.orderby){