Closed ivanche closed 9 years ago
После дебагов выяснил, что в методе NestedSet::correctCachedOnMoveBetweenTrees() обе ноды прогоняются по 2 раза. То есть при первой итерации он правильно выстраивает, при второй не правильно. Как я дебагал и результат: https://gist.github.com/ivanche/cb84723c496f2d7f8758
There is no more internal cache inside behavior for Yii 2 release version. Its planned, but behavior can be used without this with tree integrity garantee.
Была такая иерархия:
Хочу такую:
Но получаю вообще:
После обновления страницы всё норм становится. Перемещаю методом $model->moveAsLast($parent). Кусок кода из контроллера