Orchard 1.9 - Migrate BodyPart to LayoutPart

Topics: Administration, Core, General
Jun 15, 2015 at 9:17 AM
Hi there

Is there an upgrade process available which converts all bodyparts to template parts and then removes the bodyparts? If I am enabling the layout feature (since we enabled dynamic forms) we now have both parts enabled on the pages type. Since we have a lot of content, we need something automated to migrate to the new layout feature.

Thank you for your Response.

Jun 15, 2015 at 9:20 PM
Edited Jun 15, 2015 at 9:20 PM
You don't have to use the LayoutPart if you don't need it for the Page type - simply remove that part from the content type.
If you do want to migrate, then I'm afraid there's currently nothing that automates that for you. If you want to write something for that, let me know know if you need any input on how that could work.
Jun 16, 2015 at 6:22 AM
Thank you for your answer. Currently I think we will just remove the LayoutPart and re-add it later on. An automated migration would be nice to enable the layout feature for large existing sites. Is there a Roadmap to provide something like this?

How would you do the migration? Can the body Content "just be copied" to the layout content as plain HTML without any layouting?
Jun 17, 2015 at 11:04 AM
There's nothing on the roadmap to provide for an automated migration I'm afraid. Perhaps if there is enough demand for it someone will do it.
One could migrate the BodyPart to a LayoutPart by copying the HTML from the body to an Html element on the canvas. This does not require any layouting in terms of adding grids and such. All one would need is a single Html element on the layout editor canvas.