Hi,
Simple question, I tried to understand, to use and implement NodeOrder usage through some migration (using migrate module).
But I can't find a way to correctly use it through the code. I tried to simply create $node->nodeorder as an array (tid->order) but migrate doesn't understand, probably because it's not a field.
So, I ended up having tid and position, but unable to save those pieces of information to the node.
I was hoping to find a function like nodeorder_set_node_position($node, $tid), but nothing like that seems to exist (maybe I'm not so good at reading code).
Any idea how I could do this? I can implement a nodeorder_set_node_position function if maintainers are ok.
Thanks.
Comments
Comment #2
davps commentedHello @qudec,
Check nodeorder_node_update() function it should helps to you.
Here is an example steps:
After node will migrated and inserted should be triggered hook_node_update and new weight should be processed by nodeorder module.
Or you can update weights in complete() method and re-save node, as another solution.
I hope this helps to solve the problem.