You are here

function merci_restrictions_instances in MERCI (Manage Equipment Reservations, Checkout and Inventory) 7.3

1 call to merci_restrictions_instances()
merci_restrictions_merci_fields_info in merci_restrictions/merci_restrictions.module
Implements hook_merci_fields_info().

File

merci_restrictions/merci_restrictions_fields.inc, line 145

Code

function merci_restrictions_instances() {
  $field_instances = array();

  // Exported field_instance: MERCI_CHECKOUT_OFFSITE
  $field_instances[MERCI_CHECKOUT_OFFSITE] = array(
    'default_value' => array(
      0 => array(
        'value' => 0,
      ),
    ),
    'deleted' => 0,
    'description' => '',
    'display' => array(
      'default' => array(
        'label' => 'above',
        'module' => 'boolean_formatter',
        'settings' => array(
          'custom_off' => '',
          'custom_on' => '',
          'format' => 'yes-no',
          'reverse' => 0,
        ),
        'type' => 'boolean_yes_no',
        'weight' => 2,
      ),
    ),
    'label' => 'Checkout Offsite',
    'required' => 0,
    'settings' => array(
      'user_register_form' => FALSE,
    ),
    'widget' => array(
      'active' => 1,
      'module' => 'options',
      'settings' => array(
        'display_label' => 1,
      ),
      'type' => 'options_onoff',
      'weight' => 2,
    ),
  );

  // Exported field_instance: MERCI_CHECKOUT_MAX_LENGTH
  $field_instances[MERCI_CHECKOUT_MAX_LENGTH] = array(
    'default_value' => NULL,
    'deleted' => 0,
    'description' => '',
    'display' => array(
      'default' => array(
        'label' => 'above',
        'module' => 'text',
        'settings' => array(),
        'type' => 'text_default',
        'weight' => 1,
      ),
    ),
    'label' => 'Max Length of Checkout',
    'required' => 0,
    'settings' => array(
      'text_processing' => 0,
      'user_register_form' => FALSE,
    ),
    'widget' => array(
      'active' => 1,
      'module' => 'text',
      'settings' => array(
        'size' => 60,
      ),
      'type' => 'text_textfield',
      'weight' => 1,
    ),
  );

  // Exported field_instance: MERCI_OVERRIDE_RESTRICTIONS
  $field_instances[MERCI_OVERRIDE_RESTRICTIONS] = array(
    'default_value' => NULL,
    'deleted' => 0,
    'description' => '',
    'display' => array(
      'add_form' => array(
        'label' => 'above',
        'module' => 'entityreference',
        'settings' => array(
          'grid_field_formatter' => array(
            'columns' => 1,
            'grid_enable' => FALSE,
          ),
          'link' => FALSE,
        ),
        'type' => 'entityreference_label',
        'weight' => 6,
      ),
      'default' => array(
        'label' => 'above',
        'module' => 'entityreference',
        'settings' => array(
          'grid_field_formatter' => array(
            'columns' => 1,
            'grid_enable' => FALSE,
          ),
          'link' => FALSE,
        ),
        'type' => 'entityreference_label',
        'weight' => 12,
      ),
      'list' => array(
        'label' => 'above',
        'module' => 'entityreference',
        'settings' => array(
          'grid_field_formatter' => array(
            'columns' => 1,
            'grid_enable' => FALSE,
          ),
          'link' => FALSE,
        ),
        'type' => 'entityreference_label',
        'weight' => 6,
      ),
    ),
    'label' => 'Override Restrictions',
    'required' => 0,
    'settings' => array(
      'user_register_form' => FALSE,
    ),
    'widget' => array(
      'active' => 1,
      'module' => 'entityreference',
      'settings' => array(
        'match_operator' => 'CONTAINS',
        'path' => '',
        'size' => 60,
      ),
      'type' => 'entityreference_autocomplete',
      'weight' => 10,
    ),
  );

  // Exported field_instance: MERCI_RESTRICTIONS
  $field_instances[MERCI_RESTRICTIONS] = array(
    'deleted' => 0,
    'description' => '',
    'display' => array(
      'default' => array(
        'label' => 'above',
        'module' => 'entityreference',
        'settings' => array(
          'grid_field_formatter' => array(
            'columns' => 1,
            'grid_enable' => FALSE,
          ),
          'link' => FALSE,
        ),
        'type' => 'entityreference_label',
        'weight' => 3,
      ),
    ),
    'label' => 'Restrictions',
    'required' => 0,
    'settings' => array(
      'user_register_form' => FALSE,
    ),
    'widget' => array(
      'active' => 1,
      'module' => 'inline_entity_form',
      'settings' => array(
        'fields' => array(),
        'type_settings' => array(
          'allow_existing' => FALSE,
          'delete_references' => 1,
          'label_plural' => 'merci restrictions',
          'label_singular' => 'merci restriction',
          'match_operator' => 'CONTAINS',
          'override_labels' => 0,
        ),
      ),
      'type' => 'inline_entity_form',
      'weight' => 7,
    ),
  );
  return $field_instances;
}