/**
  * Filter the items_browse_sql to return only items that have a non-empty
  * value for the DC:Date field, when using the neatlinetime-json context.
  * Uses the ItemSearch model (models/ItemSearch.php) to add the check for
  * a non-empty DC:Date.
  *
  * @param Omeka_Db_Select $select
  */
 public function hookItemBrowseSql()
 {
     $context = Zend_Controller_Action_HelperBroker::getStaticHelper('ContextSwitch')->getCurrentContext();
     if ($context == 'neatlinetime-json') {
         $search = new ItemSearch($select);
         $newParams[0]['element_id'] = neatlinetime_get_option('item_date');
         $newParams[0]['type'] = 'is not empty';
         $search->advanced($newParams);
     }
 }