geerlingguy / jeffgeerling-com

Drupal Codebase for JeffGeerling.com
https://www.jeffgeerling.com
GNU General Public License v2.0
40 stars 2 forks source link

Migrate main menu from Drupal 7 to Drupal 8? #33

Closed geerlingguy closed 4 years ago

geerlingguy commented 4 years ago

Right now, the main menu is just empty, which is kind of sad:

Screen Shot 2020-03-17 at 9 42 44 AM

It would be nice if, after installing the site and running migrations, a main menu were populated and present. Right now I have to manually add links after a reinstall/migration :(

geerlingguy commented 4 years ago

It looks like I might have to build a menu migration by hand? https://drupal.stackexchange.com/q/278990/26

geerlingguy commented 4 years ago

Just noting that after porting the Blog view from D7 to D8, and adding a 'Blog' main menu link, there is now a 'Blog' item.

And I may do the same after porting the Projects view...

geerlingguy commented 4 years ago

At this point I have the 'Projects' link as well. The only link that's not in the mix at this point is the 'About' page link. I wonder why the migration doesn't migrate menu settings for nodes? It's set up that way in the Drupal 7 site:

Screen Shot 2020-04-07 at 2 05 28 PM
geerlingguy commented 4 years ago

Current state of the menu:

Screen Shot 2020-04-07 at 2 10 52 PM
geerlingguy commented 4 years ago

It looks like in Drupal 8, there is no 'Menu settings' for a node? I just checked the node 1 edit page and didn't see any menu settings.

geerlingguy commented 4 years ago

Checking further, there are menu settings but they were not enabled for the 'Page' content type on my site. It's definitely set up correctly on the Drupal 7 site, so not sure why that configuration didn't migrate across on the Drupal 8 site. I've manually enabled the Main menu for being available for Drupal 8 page nodes, and will try re-migrating the page nodes and see if that fixes it.

geerlingguy commented 4 years ago

After:

docker-compose exec drupal bash -c 'drush migrate-import --update upgrade_d7_node_page'

It still didn't migrate the 'Provide a menu link' setting. So... for now I'll just do that manually. Might be able to automate it later. Sigh.

geerlingguy commented 4 years ago

Going to add that 'About' link in a manual migration step after #55.