Bug 11232: retrieve facets from Zebra's indexes in DOM

This patch adds two routines.
1) _get_facet_from_result_set:
   Given a result set and a facet index name, retrieve the facets
   for the given index, and build the result for rendering.
2) _get_facets_from_result_set:
   Given a result set, loop through all defined facets in C4::Koha::getFacets
   and call _get_facet_from_result_set for each, to build the facets
   information.

TODO:
 - mocked unit tests
 - indexes defined for NORMARC and UNIMARC
 - Move all munging code into separate and testable subroutines.