I wanted to be able to run a Migration from a task in an install profile, and it would be nice if the code in migrate_ui.pages.inc had been abstract so I could re-use it. This is my first attempt. It's nice since I can start a batch just using the following:

$batch = new MigrateImportBatch();
$batch->addGroupMigration('my_migration_group');
$result = $batch->getBatch();
batch_set($result);
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Dave Reid’s picture

Status: Active » Needs review
FileSize
13.72 KB

Status: Needs review » Needs work

The last submitted patch, 1: 2229113-batch-helper.patch, failed testing.

Dave Reid’s picture

Status: Needs work » Needs review
FileSize
0 bytes

With 100% less syntax errors now.

Dave Reid’s picture

FileSize
13.72 KB

Now with 500% more actual patch.

Dave Reid’s picture

Dave Reid’s picture

FileSize
13.83 KB

Fixed error with rollback processing and added drush_log() support.

Dave Reid’s picture

FileSize
10.19 KB

Re-rolled for 7.x-2.x.

Dave Reid’s picture

FileSize
15.27 KB

Last patch regressed on removing code. Updated patch fixes regression and uses new batch code in the migrate UI wizard.

mikeryan’s picture

Status: Needs review » Needs work

Looks good, but the new classes/methods need documentation.