The node type form allows changing a node to using Drupal comments from node comments and vice versa. When this happens we need to translate comment data to nodecomment data and vice versa, preferably using batch API.
We should also ensure that it's documented that if uninstalling nodecomment this operation needs to be performed.
| Comment | File | Size | Author |
|---|---|---|---|
| #3 | nodecomment_convert.patch | 19.98 KB | quicksketch |
Comments
Comment #1
merlinofchaos commentedtagging
Comment #2
quicksketchI'm working on this currently.
Comment #3
quicksketchI've committed the attached patch which adds this functionality. Because I didn't want to get into making the node type form multiple pages, I made a separate menu callback that the user is redirected to if they've made changes to the comment settings that require conversion. The process uses Batch API and can convert between pretty much any two comment types: Comment to Node, Node to Comment, and Node to Node. It can potentially leave behind residual data for nodes if converting between two node types that have different fields, but it's close enough for an initial pass at this functionality.
Comment #4
merlinofchaos commentedWow, great job! Suddenly nodecomment module has gone from something that was kind of sketchy to something that is *really* useful!