Hi, it seems that when I convert from a book page to another type, the node looses its book outline.

CommentFileSizeAuthor
#5 book-outline-lost-895566-5.patch2.38 KBkevin.dutra

Comments

ukrdrupal’s picture

Wouldn't you expect that to happen?

...I had imported an HTML "site" of mine, using the html_import module, to make a book in Drupal. The files got imported as "page" type, but I needed them as "book page" type. I did have all of the "page"s properly linked together and I correctly assigned them to the right book page structure. However, as far as Drupal node's and types are concerned, they were not a true "book page" type. This was causing me a problem with search features. So, I took a "risk" to use this module, to convert all of my "page" types over to "book page" type. It worked! and the whole book kept it's outline.

One of the things you notice in the module is that if there are any fields in one type and not the other, then it has to find a way to assign them. If you did not correctly assign them, when making the conversion, I imagine these fields would be lost. That is apparently what happened? ...Did you try to convert the "page" types back to "book page" type and see if the outline was retained?

LarsKramer’s picture

Hi, Drupal allows for any content type to be part of a book structure, and so the child pages don't need to be of the same type as the parent pages. After converting a book page to another type, it looses its book relationship, but you are able to reassign it manually.

I don't think it has anything to do with CCK fields as my book pages didn't have any.

ukrdrupal’s picture

I think I understand more clearly the problem you are addressing. I haven't tried that scenario yet. Maybe someone else can chime in and help or maybe a fix is needed.

R-H’s picture

Yes, I have the same problem. Converting from Book to Blog, I lose my book outline association.

kevin.dutra’s picture

StatusFileSize
new2.38 KB

A little late to the party, but same issue here.

The feature for inserting converted nodes into a book is what causes the issue with losing book structure. The code for that needs to be rethought in order for it to work as intended because, as LarsKramer points out, any content type can be part of a book.

Attaching a patch that removes the feature, which will at least solve the loss of book outline until such time as the feature can be reworked.