Skip to content

search+facets working, but results not displayed #7

@petercsmith

Description

@petercsmith

I have facetview2 working against my ES index. The debug window shows results coming back from ES, but they refuse to display correctly in the results! The javascript debugger shows a bunch of empty 'td' tags, but I see results coming back from ES in the debugging console. See below for screenshot and code:

image

<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8" />
  <title>FacetView</title>

  <script type="text/javascript" src="vendor/jquery/1.7.1/jquery-1.7.1.min.js"></script>

  <link rel="stylesheet" href="vendor/bootstrap/css/bootstrap.min.css">
  <script type="text/javascript" src="vendor/bootstrap/js/bootstrap.min.js"></script>  

  <link rel="stylesheet" href="vendor/jquery-ui-1.8.18.custom/jquery-ui-1.8.18.custom.css">
  <script type="text/javascript" src="vendor/jquery-ui-1.8.18.custom/jquery-ui-1.8.18.custom.min.js"></script>

  <!-- note that we require the es.js integration, the bootstrap2 facetview and the facetview core -->
  <script type="text/javascript" src="es.js"></script>
  <script type="text/javascript" src="bootstrap2.facetview.theme.js"></script>
  <script type="text/javascript" src="jquery.facetview2.js"></script>

  <link rel="stylesheet" href="css/facetview.css">

  <script type="text/javascript">
jQuery(document).ready(function($) {
    $('.facet-view-simple').each(function() {
        $(this).facetview({
            search_url: 'http://services:9200/flow/_search',
            facets: [
                {'field': 'euid', 'size': 2, 'order':'term', 'display': 'EUID'},
                {'field': 'srcPort', 'size': 2, 'order':'term', 'display': 'Source Port'},
                {'field': 'protocol', 'size': 2, 'order':'term', 'display': 'protocol'},
                {'field': 'action', 'size': 2, 'order':'term', 'display': 'action'}, ],
            debug: true,
        });
    });
});
  </script>

<style type="text/css">
.facet-view-simple{
    width:1170px;
    height:600px;
    margin:20px auto 0 auto;
}
</style>

</head>
<body>

    <div class="facet-view-simple"></div>

</body>
</html>

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions