I am attempting to migrate data from MSSQL into Drupal 6 using the Migrate module. In the legacy database that I am importing, there is taxonomy data that has extra fields that I want to migrate in, so I have installed the Term Fields module to hold the data related to the term. I'm not sure how to get the other data into the term_fields_term table.
In Migrate UI, I see a warning that one of the destination fields isn't being mapped.
I tried to address this with a class that extends MigrateDestinationHandler (modeled off the FlagDestinationHandler class in migrate_extras) and implements the fields() method, and added this class as a dependency, but it didn't seem to make a difference.
Can anyone give some pointers?
Comments
Comment #1
ebeyrent commentedIt looks like the easiest way to accomplish what I am trying to do is to implement the complete() method in my Migration class, and use the Term Fields api to create the new records.
Is there a better way?
Comment #2
drewish commentedCreating a MigrateDestinationHandler that adds the field should be the right way to do it. Could you post that code?
Comment #3
drewish commentedOh, okay for the destination handler to work you'd need to have a migration that had terms as a destination. Then have another migration that creates nodes that depends on the term migration. Then you could reference the term migration on the field mapping by calling the sourceMigration().
Comment #4
moshe weitzman commentedShould we add any more tests for backend or --pipe? Even if we stub them out as TODO that would be helpful.
Comment #5
moshe weitzman commentedoops - posted to wrong issue. sorry
Comment #6
mikeryanSupport for contrib modules like Term Fields goes into the Migrate extras module.
Comment #7
mikeryanThese days, migration support for contrib modules should go into the module in question.
Comment #8
b-prod commentedIf somebody provides a patch against Term Fields module to add such functionality, I could port it in a future release. So only if you suggest a patch for review, you are welcome to reopen the issue.
But I will not work on that, since there will not be more developments on Term Fields module, but only maintenance for bug fixes.