You are here

public function MerciTaxonomyRestrictionsMigration::__construct in MERCI (Manage Equipment Reservations, Checkout and Inventory) 7.3

General initialization of a Migration object.

Overrides Migration::__construct

File

merci_migrate/merci_restrictions.inc, line 4
Support for node destinations.

Class

MerciTaxonomyRestrictionsMigration

Code

public function __construct($arguments) {
  parent::__construct($arguments);
  $this->source = new MerciContentTypesMigrateSource();
  $this->destination = new MigrateDestinationRestrictions('merci_restrictions');
  $this->map = new MigrateSQLMap($this->machineName, array(
    'merci_item_grouping' => array(
      'type' => 'varchar',
      'length' => 32,
      'not null' => TRUE,
    ),
  ), MigrateDestinationRestrictions::getKeySchema());
  $this
    ->addFieldMapping('field_max_length_of_checkout', 'merci_max_hours_per_reservation');
  $this
    ->addFieldMapping('field_allow_overnight', 'merci_allow_overnight');
  $this
    ->addFieldMapping('field_allow_weekends', 'merci_allow_weekends');
  $this
    ->addFieldMapping('title', 'merci_item_grouping');
}