Explorar el Código

bugfix: Switch to first dashboard if actions page is empty

jamesread hace 2 años
padre
commit
29fe38eff4
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      webui.dev/js/marshaller.js

+ 1 - 1
webui.dev/js/marshaller.js

@@ -170,7 +170,7 @@ function marshalDashboardStructureToHtml (json) {
     document.getElementById('navigation-links').appendChild(navigationLi)
   }
 
-  if (document.getElementById('root-group').children.length === 0 && json.dashboards.length > 0) {
+  if (document.getElementById('root-group').querySelectorAll('action-button').length === 0 && json.dashboards.length > 0) {
     showSection(json.dashboards[0].title)
   } else {
     showSection('Actions')