You are here

function pmproject_migrate_create_fields in Drupal PM (Project Management) 7.2

Same name and namespace in other branches
  1. 8 pmproject/includes/pmproject.migrate.inc \pmproject_migrate_create_fields()
  2. 7.3 pmproject/includes/pmproject.migrate.inc \pmproject_migrate_create_fields()

Creates and attaches fields to Drupal user.

2 calls to pmproject_migrate_create_fields()
pmproject_install in pmproject/pmproject.install
Implements hook_install().
pmproject_migrate in pmproject/includes/pmproject.migrate.inc
Helper function for migrating between pmproject to drupal fields.

File

pmproject/includes/pmproject.migrate.inc, line 53
Migration functions for the PM Project module.

Code

function pmproject_migrate_create_fields(&$sandbox) {
  module_load_include('inc', 'pmproject', 'includes/pmproject.field_base');
  module_load_include('inc', 'pmproject', 'includes/pmproject.field_instance');
  module_load_include('inc', 'pm', 'includes/pm.field');
  $field_bases = pmproject_default_field_bases();
  pm_field_bases_create_if_required($field_bases);
  $field_instances = pmproject_default_field_instances();
  pm_field_instances_create_if_required($field_instances);
  return TRUE;
}