rrs: fix recipe/maintainer count showing at top

We were using the main badge class as a selector here to show the recipe
or maintainer count, and that meant that it also showed up at the top
next to the login button if there were some layers to review. Use a
proper id to stop that from happening.

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
This commit is contained in:
Paul Eggleton 2018-08-21 17:56:32 +12:00
parent b3e9cb05d2
commit a1b7fdacdb
2 changed files with 6 additions and 6 deletions

View File

@ -23,7 +23,7 @@
<div class="navbar-inner table-controls"> <div class="navbar-inner table-controls">
<ul class="nav"> <ul class="nav">
<li class="dropdown"> <li class="dropdown">
<span class="badge" style="margin-top:11px;"></span> <span class="badge" id="maintainer-count" style="margin-top:11px;"></span>
</li> </li>
</ul> </ul>
<form id="form-search" class="pull-right input-append"> <form id="form-search" class="pull-right input-append">
@ -188,9 +188,9 @@ $(document).ready(function() {
} }
if (count == 2) { if (count == 2) {
$('.badge').html("1 maintainer"); $('#maintainer-count').html("1 maintainer");
} else { } else {
$('.badge').html((count - 1) + " maintainers") $('#maintainer-count').html((count - 1) + " maintainers")
} }
updateTotals() updateTotals()
} }

View File

@ -23,7 +23,7 @@
<div class="navbar-inner table-controls"> <div class="navbar-inner table-controls">
<ul class="nav"> <ul class="nav">
<li class="dropdown"> <li class="dropdown">
<span class="badge"></span> <span class="badge" id="recipe-count"></span>
</li> </li>
<li class="dropdown"> <li class="dropdown">
<a data-toggle="dropdown" href="#" class="dropdown-toggle" id="selected-status"> <a data-toggle="dropdown" href="#" class="dropdown-toggle" id="selected-status">
@ -203,9 +203,9 @@ $(document).ready(function() {
} }
if (count == 2) { if (count == 2) {
$('.badge').html("1 recipe"); $('#recipe-count').html("1 recipe");
} else { } else {
$('.badge').html((count - 1) + " recipes"); $('#recipe-count').html((count - 1) + " recipes");
} }
} }