New answers tagged

0

Ok, i figured this one out. The magic lines are in /core/modules/migrate/src/Plugin/migrate/process/FileCopy.php First, make sure source_base_path is correct in your config: Check drush mmsg d7_file after migrate-upgrade d7_node --limit=1 to see whether it is correctly finding the files. Use drush config:export and config:import to modify it til that works....


0

Follow these steps modify your migration code first of all - run a select query to fetch all the nids of that content type or bundle for which you are migrating the data next, run migration identify the nodes which are not part of migration but exist in your select query in while loop, load these nodes mark them as unpublished save these nodes done!


1

I resolved my problem when I identified a mistake in my @MigrateSource annotation on my plugin. I had included my own custom migration module in the source_module entry of the plugin annotation. Here is what I did wrong: /** * The 'mymodule_migrate_entityform' source plugin. * * @MigrateSource( * id = "mymodule_migrate_entityform", * ...


0

It seems that the path to drush was wrong when the script was running by cron. Lesson learned - I should be using full paths when working with cron.


1

This was quite easy by adding a $query->condition() to public function query() using IN and NOT IN in dynamic queries This worked to exclude certain id's: $products = [1, 2, 3,]; $query->condition('product_id', $products, 'NOT IN'); This worked to include only certain id's: $products = [1, 2, 3,]; $query->condition('product_id', $products, 'IN'); ...


0

You can try to access like this? http://[domain-name]/~[user-name]/user/login some check userDir directive in your apache configuration ... https://www.drupal.org/project/drupal/issues/359540


0

There's no such process plugin in core or migrate_plus. If you can't find what you need in those lists, you'll probably have to write a custom solution. You may want to check out SubProcess process plugin which may be able to work with your decoded array with minimal changes.


0

You can achieve that by adopting the below snippet to your use case. source: constants: PROFILE_PICTURES_FILE_DIRECTORY: 'public://profile_pictures/' process: profile_picture_destination_filename_base: - plugin: concat source: - title - field_account_id delimiter: '-' profile_picture_destination_filename: ...


0

I've found the solution. I don't need to create a Media entity and append it to the User entity, since the profile picture field type is Image, so I just need to add the file->id() to the specific field. Here is the code: $replaced = str_replace("\\", "", $user["picture"]); $imageData = file_get_contents($replaced); $...


0

This issue has been reported at https://github.com/mglaman/drupal-check/issues/202


Top 50 recent answers are included