// Don't show Batch display column and filter unless batches are being used
$this->_closedBatches = CRM_Batch_BAO_Batch::getBatches();
if (!empty($this->_closedBatches)) {
$this->_columns['civicrm_batch']['dao'] = 'CRM_Batch_DAO_Batch';
$this->_columns['civicrm_batch']['fields']['batch_id'] = array(
'name' => 'id',
// Don't show Batch display column and filter unless batches are being used
$this->_closedBatches = CRM_Batch_BAO_Batch::getBatches();
if (!empty($this->_closedBatches)) {
$this->_columns['civicrm_batch']['dao'] = 'CRM_Batch_DAO_Batch';
$this->_columns['civicrm_batch']['fields']['batch_id'] = array(
'name' => 'id',