G
G
GSmaster2015-02-09 17:08:48
PHP
GSmaster, 2015-02-09 17:08:48

How to move nested Nested Set records?

Actually inherited a site on yii in which the rubricator is implemented using the CDBTree class
With the help of the enumChildrenAll() function, it made it possible to move any branch with children to any branch, the nesting is saved correctly.
But the records themselves naturally do not move anywhere. are in another table.
I understand that it is necessary to change clevel1 clevel2 clevel3 clevel4 pid - (these are fields in the table of records - 4 levels, just a large depth is unnecessary)
but here's how to automate it - I'll never know - tell me please

Answer the question

In order to leave comments, you need to log in

1 answer(s)
V
Vicom, 2016-08-25
@vicom

I don't know if they looked.. scroll down and right there on your topic:
Is there a php library for working with nested sets?
I want to understand the algorithm for moving a node in the nes tree ... I
myself just started to study the issue, the topic is interesting, if there is a significant gain in the ratio "scalability - complexity", or performance, then I also think to implement it in Yii2)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question