<?php

class m130801_060413_add_indexes_on_event_reporting extends MyDbMigration
{
  public function up()
  {
    $this->createIndex('gate_index', 'event_reporting', 'gate');
    $this->createIndex('taken_index', 'event_reporting', 'taken_in_charge_by');
    $this->createIndex('managed_index', 'event_reporting', 'managed_by');
    $this->createIndex('type_index', 'event_reporting', 'type');
    $this->createIndex('status_index', 'event_reporting', 'status');
    $this->createIndex('epoch_index', 'event_reporting', 'epoch');

  }

  public function down()
  {
    $this->dropIndex('gate_index', 'event_reporting');
    $this->dropIndex('taken_index', 'event_reporting');
    $this->dropIndex('managed_index', 'event_reporting');
    $this->dropIndex('type_index', 'event_reporting');
    $this->dropIndex('status_index', 'event_reporting');
    $this->dropIndex('epoch_index', 'event_reporting');
  }

}
