Ejemplo n.º 1
0
 public function actionMoveToChild($moveItemId, $droppedOnItemId)
 {
     return ['success' => Nav::moveToChild($moveItemId, $droppedOnItemId)];
 }
Ejemplo n.º 2
0
 public function actionMoveToChild($moveItemId, $droppedOnItemId)
 {
     if (!($result = Nav::moveToChild($moveItemId, $droppedOnItemId))) {
         Yii::$app->response->setStatusCode(422, 'Found URL alias duplication in target parent nav id.');
     }
     return ['success' => $result];
 }
Ejemplo n.º 3
0
 public function actionMoveToChild($moveItemId, $droppedOnItemId)
 {
     $result = Nav::moveToChild($moveItemId, $droppedOnItemId);
     if ($result !== true) {
         Yii::$app->response->setStatusCode(422, 'Found URL alias duplication in drop target "' . $result['title'] . '".');
     }
     return ['success' => $result];
 }